View Single Post
  #4  
Old 01-13-2014, 02:40 AM
hergenmuelle hergenmuelle is offline
Hot Shot
.
 
Join Date: Jul 2012
Posts: 20
hergenmuelle has 13 reputation pointshergenmuelle has 13 reputation points
Default

The Contact Data is only available if it was part of the initial incoming CDN call.
There is a workaround by using the WebService function getIntrinsicByName (number 3):

Back-end AAEP example:
/* First collect the data from AAEP */

ASSIGN CONTACT DATA "SIP_FROM_ADDRESS" TO c_sip_from_add_cv

ASSIGN CONTACT DATA "SIP_TO_ADDRESS" TO c_sip_to_add_cv


ASSIGN c_sip_from_add_cv TO vxmlto


ASSIGN c_sip_to_add_cv TO vxmlfrom
ASSIGN "sip:__sip-xdialog@evnts.net" TO serviceuri
ASSIGN "invite" TO method
ASSIGN "ContextCreation" TO voicexml
ASSIGN "VXML" TO apptype
ASSIGN "contextcreation" TO treatmenttype

GIVE IVR SERVICE URI serviceuri WITH VXML TREATMENT voicexml
PARAMETERS vxmlto, vxmlfrom, method, apptype, treatmenttype
RETURNS ivr_result_cv

WHERE ivr_result_cv EQUALS
VALUE "FAILURE":
LOG "CONTEXT CREATION FAILURE"
VALUE "NODATA":
LOG "CONTEXT CREATION NODATA"
VALUE "SUCCESS":
LOG "CONTEXT CREATION SUCCESS"
END WHERE

ASSIGN CONTACT DATA "AVP_NAME" TO im

/* As the provided data is not available as CONTACT DATA use getIntrinsicByName to get it */
IF im = "BAD or INVALID KEY NAME" THEN
LOG "No AVP_NAME populated"
ASSIGN CONTACT DATA "ProviderContactID" TO externalCallId_cv
ASSIGN "3" TO HDX_QueryNum_cv
ASSIGN "AVP_NAME" TO im
SEND REQUEST HDX_AppId HDX_QueryNum_cv, externalCallId_cv, im, WS_username_gv, WS_password_gv
GET RESPONSE HDX_AppId HDX_Resp_cv, WSResult_cv, im
END IF

ASSIGN im to im_str
LOG im_str

QUEUE TO SKILLSETDefault_Skillset WITH PRIORITY 6
WAIT 2
Reply With Quote