How to test Send SMS API in Sandbox testing.?

  • 1
  • Problem
  • Updated 2 years ago
  • (Edited)
We have created an application on developer account.

our application is under Sandbox..
we are facing issue at the API explore to test the callback and responses.

But still not get success in this due to some exception coming from API.


Using from number : +19045591097
To number : +14804523757
and Message Text: Hello good morning.

Getting error as below

"errorCode": "InvalidParameter",
"message": "Parameter [toNumber] value is invalid", "errors": [ { "errorCode": "CMN-101", "message": "Parameter [toNumber] value is invalid", "parameterName": "toNumber" } ], "parameterName": "toNumber" }

Number format is OK.

What exact error or issue not getting from body response..
Photo of Brian Ladouceur

Brian Ladouceur

  • 162 Points 100 badge 2x thumb
  • confused

Posted 2 years ago

  • 1
Photo of AK

AK, Official Rep

  • 4,412 Points 4k badge 2x thumb
Hi Brain,

Could you please provide us the API request? 

Just as a reference, the request body when you send the SMS should be as below:

"to": [{"phoneNumber": "To Number"}], // Should be an array
"from": {"phoneNumber": "From Number << Sandbox NUmber >>"},
"text": "Test SMS message from Platform server"
Could you please try again and confirm if it works.

If you still have problems sending the SMS using the sandbox number, please open a case by emailing the API request and response to and we shall take a look at it.
Photo of VB

VB, Official Rep

  • 1,510 Points 1k badge 2x thumb
Hi, Please make sure you click on Add Item under to number for the body of SMS in API explorer before sending the sms. Can you please send us the full Response from the console log if the test fails? 

PFA screenshot: