Data Action test returning empty

Hi All,

I need to create an integration and action to call a client application API end point to send the call logs from Genesys cloud.
I have created web service data actions integration and actions, when testing the data action I get Action successfully run, with response empty.

I have the below details and steps to access their API's

Username, Password, Secret key, IV

  1. Convert Secret key to AES 256 HEX key
  2. Using the AES 256 HEX Key, IV, username and password value, encrypt it
  3. In postman enter the above encrypted string in body raw data
  4. Generate Nonce value and add Nonce Header with the value, send the request post method to https://abc.com/restapi/oauth2/token
  5. Received output is an encrypted value, decrypt this encrypted value to see the token.
  6. In Postman select the bearer token authtype, enter the token from above step.
  7. Encrypt the Request body and enter the encrypted value in the body of postman
  8. Generate Nonce value and add Nonce header with the value and send the request post method to https://abc.com/xxx/Object
  9. Response body will be an encrypted value, again decrypt to see the decrypted response

I think the integration and actions created is not proper, so we get a blank response.
Can you please guide me what credential type I need to use while creating the integration for the above case and also I have pasted my data action for the same and how do I manage the encryption, decryption and Nonce header in this case?

{
"name": "Dev Client - Exported 2024-05-21 @ 21:39",
"integrationType": "custom-rest-actions",
"actionType": "custom",
"config": {
"request": {
"requestUrlTemplate": "https://abc.com/xxx/Object",
"requestType": "POST",
"headers": {
"Nonce": "Basic $encoding.base64("${credentials.username}:${credentials.password}")"
},
"requestTemplate": "${input.rawRequest}"
},
"response": {
"translationMap": {},
"translationMapDefaults": {},
"successTemplate": "${rawResult}"
}
},
"contract": {
"input": {
"inputSchema": {
"title": "Input",
"type": "object",
"properties": {
"CallStartTime": {
"type": "string"
},
"CallEndTime": {
"type": "string"
},
"SourcePhone": {
"type": "string"
},
"DestinationPhone": {
"type": "string"
}
},
"additionalProperties": true
}
},
"output": {
"successSchema": {
"type": "object",
"properties": {
"ActivityId": {
"type": "string"
}
},
"additionalProperties": true
}
}
},
"secure": false
}

Hi ShivLing,

The authentication requirements for that endpoint appear to be beyond what we provide built-in support for in Data Actions. I would suggest having your data action connect to an AWS Lambda, Google Function, or possibly our Functions beta:

--Jason

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.