@micheal thanks for your suggestion. they were very insightful. I was able to resolve the issue by using the below in request template body:
this work for post:
{
"KEY": "$esc.jsonString($input.key)",
"Name": "$esc.jsonString($input.Name)"
}

Original Message:
Sent: 09-04-2025 08:27
From: Michael McEwen
Subject: Trying to use data action to create record in inbound message flow
Hello Teslim,
I believe your Request Body Template is formed incorrectly,
If you are using the POST on that endpoint to create a new datatable row then according to the documentation it "should be a json-ized' stream of key -> value pairs { "Field1": "XYZZY", "Field2": false, "KEY": "27272" }"
So instead of having what i saw in the screenshot you should have something like this:
{
"key": "${input.email}",
"name": "${input.name}"
}
I believe the UI on the API explorer may be a little buggy on this.
------------------------------
Michael McEwen
Application Developer
Original Message:
Sent: 09-03-2025 09:45
From: Teslim Oyedotun
Subject: Trying to use data action to create record in inbound message flow
thanks @Jason Mathison.
corrected it but now faced with execution error:



{
"message": "Bad Request",
"code": "bad.request",
"status": 400,
"messageParams": {},
"contextId": "3926f966-a368-4771-a18e-9293add6aa02",
"details": [
{
"errorCode": "ACTION.REMOTE_ENDPOINT"
}
],
"errors": [
{
"message": "REST call for action execute failed. Message: Request to backend service failed. Response from web service: [3926f966-a368-4771-a18e-9293add6aa02]",
"code": "BAD_REQUEST",
"status": 400,
"messageParams": {},
"details": [],
"errors": []
}
]
}
------------------------------
Teslim Oyedotun
Original Message:
Sent: 09-03-2025 09:33
From: Jason Mathison
Subject: Trying to use data action to create record in inbound message flow
In the URL template the datatableId should be something like ${input.dataTableId} or whatever the name of the input variable is.
------------------------------
--Jason
Original Message:
Sent: 09-02-2025 12:13
From: Teslim Oyedotun
Subject: Trying to use data action to create record in inbound message flow
I want to configure a digital flow that will be use in my messenger. The digital bot will first ask cx his prefer language between English and Arabic. If the choice is English, the bot should greet cx in English. otherwise he should write the greeting in Arabic. Regardless of the choice, the next question is to ask cx if he is new or existing customer (do this for both English and Arabic). If cx pick existing, use the necessary action to collect cx response and compare it with what we have in the database. Note: we want to use cx email to verify if he is an existing cx. if the email not found in our database, tell cx no record found and prompt him to provide hie email, and fullname so that we can store it as new customer. If cx pick option of new customer, prompt him to provide is email and fullname so as to store them in our table. use necessary action , including expression at every point in time. I use data table to store information


Try to test my data action:

i got this error when run the test:
{
"message": "Bad Request",
"code": "bad.request",
"status": 400,
"messageParams": {},
"contextId": "61651ce2-60b6-44f9-a877-92497d60429c",
"details": [
{
"errorCode": "ACTION.PROCESSING"
}
],
"errors": [
{
"code": "BAD_REQUEST",
"status": 400,
"messageParams": {},
"details": [],
"errors": []
}
]
}
#Architect
#Integrations
#PlatformAPI
------------------------------
Teslim Oyedotun
------------------------------