The platform I am using forces me to send POST requests with a body of JSON format or XML format, so to test I am using SOAPUI so I can specify exactly the body I need for testing. I am POSTing to the URL https://api.twilio.com/2010-04-01/Accounts/ACxxxxxxxxxxxxxxxxxxxx/Messages.json
with a JSON body of
{
"Body": "hi dear",
"To": "+1631xxxxxxx",
"From": "82xxx"
}
but it generates the error
{"code": 21604, "message": "A 'To' phone number is required.", "more_info": "https://www.twilio.com/docs/errors/21604", "status": 400}
but if the SOAP body is simple parameters
To=%2B1631xxxxxxx&From=82xxx&Body=Hi%20Dear
The message is send correctly and I get the Twilio response of
{
"sid": "SMxxxxxxxxxxxxxxxxxxxxx",
"date_created": "Tue, 06 Oct 2020 03:00:01 +0000",
"date_updated": "Tue, 06 Oct 2020 03:00:01 +0000",
...
}
Does Twilio have a messages API that I can POST with a formatted JSON or XML body.