When I did this in a Script - I think you are working in Architect - I had to create a Data Action to use the Genesys Cloud API to get all the rows in a table. In the script, you can run the data action on load and assign the arrays that are an output of the Data Action to a list of strings variable. So, if you have two columns (e.g., Key, Value), you can create two list of strings variables to hold the Key values and the Value values.
The GET Request URL Template is /api/v2/flows/datatables/${input.datatableId}/rows?pageSize=500&showbrief=false
The input is the data table ID
The output is:
{
"type": "object",
"additionalProperties": true,
"properties": {
"QueueInfo": {
"type": "array",
"items": {
"type": "object",
"additionalProperties": true,
"properties": {
"Key": {
"type": "string"
},
"Valuel": {
"type": "string"
}
}
}
}
}
}
Admittedly, it has been a while since I built this, but please provide some additional details. Are you working in Architect or in Scripts?
------------------------------
Dan Fontaine
C1
------------------------------