Action Script Utils (au.com.noojee.actionscript.api.v1.ActionScriptUtils) is a static class which implements functionality shared across all action types.
ScheduledFuture<?> scheduleCallback(Date time, final String phoneNumber, final String callerId,final String didNumber, Object data, final Runnable completeCallback)
scheduleCallback allows scheduling a phone call at a future time.
time is the time at which the call will be initiated.
phoneNumber is the phone number that will be dialed.
callerId is the CallerID that will be presented when the call is made.
didNumber is the DID number that will be used when the call enters Routes.
data is an object that will be available to the call when it is routed via the getCallbackData() method.
completeCallback; the run() method will be called when the call has been initiated.
Returns a ScheduledFuture which allows cancelling the call before it has occurred.
When the call is initiated a guid will be created; the data will be stored by calling setCallbackData(guid,data) and the guid will be set as channel variable (nj-agi-callback-id) on the newly initiated call. In Routes this may be accessed by calling getCallbackData() as Routes has it's own method that knows about retrieving the guid from the channel variable.
Object getCallbackData(String guid)
guid a unique identifier to access the data store by calling setCallbackData(...)
Returns the Object that was provided to setCallbackData(...)
void setCallbackData(String guid, CallbackData data)
guid a unique identifier to access the data stored when calling getCallbackData(...)
data the Object to be stored