DID SMS Callback (Unsigned) - nxtele/nxcloud-doc-en GitHub Wiki

Brief Description:

Will be used for:

  • Receiving SMS via DID number
  • The Delivery Report of sending SMS via DID number

Request URL:

  • The webhook must be written in the following format
  • Example: http://did.nxcloud.com/didsms/smsUpPushTest

Request Method:

  • POST, submitted in HTTP form format
  • Content-Type: application/x-www-form-urlencoded

Parameters:

Parameter Name Required Type Description
messageId Yes string SMS ID
type Yes string SMS type: 0 for upstream, 1 for downstream
toPhone Yes string Receiving number (DID number)
fromPhone Yes string Sending number
content Yes string Received SMS content
size Yes string Billing count
price Yes string Unit price
receiveTime Yes string Receive time
smsStatus Yes string SMS status: DELIVRD (delivered), UNDELIVR (undelivered)

Push Example

messageId=fcf3432fd1834ccdac807a7cfb2d1fdf&toPhone=%2B18184505018&fromPhone=%2B12347200160&content=test+from+wang+haha&size=1&price=0.0360&receiveTime=2021-02-07+14%3A54%3A00&smsStatus=DELIVRD

User Response:

  • Return "success" for success
  • Return "error" for failure