- Contents
Interaction Scripter Developer's Guide
IS_Event_ManualOutboundCallStatus
Definition
The IS_Event_ManualOutboundCallStatus event is a predictive event that is specifically designed for use with the IS_Action_ManualOutboundCall predictive action. When Dialer has finished processing the Manual Outbound Call, it will send the IS_Event_ManualOutboundCallStatus event to a custom script.
Attributes
The IS_Event_ManualOutboundCallStatus event has four attributes that are passed in as an argument object.
- Identity
-
This is a string that holds the unique identifier of the record as defined in the contact list table, I3_IDENTITY.
- StatusName
-
A string that indicates the status of manual outbound call processing:
CallPlaced, CallComplete, PolicyCompleted, CallBlocked, PreviouslyDialed, ContactBlocked, ContactNotFound, ContactUncallable, InvalidPhoneNumber, InvalidCampaign, InvalidAgent, AgentNotIdle, InternalError, or PlaceCallFailed
. - Status
-
Status returns a number corresponding to the StatusName string.
- UncallableStatus
-
This is the status value stored in the contact table if the status is ContactUncallable.
- CallBlockedDescriptionString
-
If the call is blocked, then this string will indicate the reason the call was blocked as a localized string that you can pass to your script.
- BlockedFlag
-
This is the value of the flag that was blocked.
Dec
Hex
Meaning
1
0x01
Blocked by Filter
2
0x02
Blocked by Query Time Filter
4
0x04
Blocked by Time Zone
8
0x08
Blocked by skills
16
0x10
Blocked by the Daily Limit value
32
0x20
Blocked by minimum spacing between dials
64
0x40
Blocked by Do Not Call rules
128
0x80
Blocked by campaign ownership
This value can be passed back to IS_Action_ManualOutboundCall as the overridemask in order to make the call again, but to ignore the rule that was just blocked. If you OR multiple Flags together, you can override multiple checks against the number.
Example
var OverrideCode = { "None": 0x00, "Filter": 0x01, "QueryTimeFilter": 0x02, "Zone": 0x04, "Skills": 0x08, "DailyLimit": 0x10, "MinimumSpacing": 0x20, "PNDStatus": 0x40, "DNC": 0x80, "CampaignOwndership": 0x100 };
var TraceLevel = { Error: 0, Warning: 1, Status: 2, Note: 3 };
var overrideAccumulator = 0x0; var lastWrapUpCode = ""; var dialedNumber; var calledNumberArray = [];
function EndCall(WrapUpCode) { if (WrapUpCode == 'Failure') { var answer = confirm("Would you like to call another number?") if (answer) { calledNumberArray.push(); lastWrapUpCode = WrapUpCode; IS_Action_RequestContactData.click(); scripter.trace("ContactDataRequested", TraceLevel.Note); // Once RequestContactData is called, a response will // trigger IS_Event_ContactDataLoaded return; } } CalledNumberArray = []; CompleteCall(WrapUpCode); }
function CompleteCall(WrapUpCode) { IS_Action_CallComplete.WrapUpCode = WrapUpCode; IS_Action_CallComplete.click(); IS_Action_Disconnect.click(); }
function IS_Event_ContactDataLoaded(args) { scripter.trace(args, TraceLevel.Note) // Raw json string will be traced to the log. var contactDataObject; try { JSON.parse(args, contactDataObject); // This does not work in older IE browsers; } catch (err) { contactDataObject = eval("(" + args + ")"); // JSON is not supported in older iE browsers. } // If there is an error on the server, the result object will have an error property. if (contactDataObject.error) { scripter.trace('error= ' + contactDataObject.error, TraceLevel.StatusName); } var NextContactToCall; for (var i = 0; i < contactDataObject.length; i++) { if ($.inArray(contactDataObject[i].PHONENUMBER, calledNumberArray)) continue; if (contactDataObject[i].OVERRIDECODE & OverrideCode.Zone == OverrideCode.Zone) { var answer = confirm("This number is blocked by Time Zone Rules, would you still like to dial it?") if (!answer) continue; else overrideAccumulator = overrideAccumulator | OverrideCode.Zone } if (contactDataObject[i].OVERRIDECODE & OverrideCode.DNC == OverrideCode.DNC) { var answer = ok("This number is on the Do Not Call List, would you still like to dial it?") if (!answer) continue; } NextContactToCall = contactDataObject[i]; continue; } }