Docs/Developers & integrations/Single SMS API Reference

Single SMS API Reference

Send a single SMS through ValueText's REST API and get the delivery status back right away. The same API family includes a Bulk SMS endpoint for sending a list of messages in one call. ValueText also builds custom APIs to fit specific customer needs.

Last updated 28 Nov 2025

Send a single message

Endpoint: https://valuetext.io/valuetext/rest/message/single/rest

Method: GET

Parameters

ParameterDescriptionRequired
mobileNumberMobile number of the receiver. The country code is mandatory before the number, for example +91-xxxxxxxxx, +1-xxx-xxx-xxxx, or 1xxxxx.Yes
smsThe message content. Must be URL encoded and use the UTF-8 character set.Yes
senderIdAlphanumeric string or number that sets the FROM address of the message.Yes
clientIdOptional. Your own ID, up to 40 characters, echoed back in the response.No

Headers

ValueText authenticates single SMS requests with an API key and secret key, sent as headers:

  • apiKey: myApiKey
  • secretKey: mySecretKey

To find your account's API key and secret key: log in to valuetext.io, click your name, then click Settings.

Sample request

Example
https://valuetext.io/valuetext/rest/message/single/rest?mobileNumber=918019350891&sms=Dear%20Nancy%2C%20your%20payment%20is%20successful&senderId=VLUTXT&clientId=879635

Important: the sms body of the message must be URL encoded and use the UTF-8 character set for the Single SMS API.

Sample response

json
{
  "balance": 0.9151,
  "result": [
    {
      "sms": "Dear Nancy, your payment is successful",
      "senderId": "VLUTXT",
      "smsId": "VT-456-1481563405645",
      "statusCode": 7003,
      "statusMsg": "Delivered",
      "statusDescription": "Message delivered successfully",
      "mobileNumber": "91-xxx-xxx-xx",
      "clientId": "123",
      "messageCount": 1,
      "messageCost": 0.0012
    }
  ]
}

The response fields and status codes match the Bulk SMS API's, covered in Response parameters and Response status codes below.

Send a bulk message

The Bulk SMS API sends a list of messages in a single call, built to deliver messages quickly. ValueText also offers custom APIs to fit specific integration needs.

Endpoint: https://valuetext.io/valuetext/rest/message/bulk/rest

Method: POST

Parameters

ParameterDescriptionRequired
mobileNumberMobile number of the receiver. The country code is mandatory before the number, for example +91-xxxxxxxxx, +1-xxx-xxx-xxxx, or 1xxxxx.Yes
smsThe message content, in UTF-8 character set.Yes
senderIdAlphanumeric string or number that sets the FROM address of the message.Yes
clientIdOptional. Your own ID, up to 40 characters, echoed back in the response.No

Headers

Set the content type based on the request you're sending:

  • content-type: application/json

Authentication parameters: ValueText authenticates bulk requests the same way, with an API key and secret key sent as headers:

  • apiKey: myApiKey
  • secretKey: mySecretKey

To find your account's API key and secret key: log in to valuetext.io, click your name, then click Settings.

Sample request (content-type: application/json)

json
[
  {
    "sms": "Dear Avinash, Thank you for your payment.",
    "senderId": "VluTxt",
    "mobileNumber": "91xxxxxxxxx",
    "clientId": "123454b",
    "deliveryModes": "SMS"
  },
  {
    "sms": "Dear Nancy, Thank you for your payment.",
    "senderId": "VluTxt",
    "mobileNumber": "91xxxxxxxx",
    "clientId": "",
    "deliveryModes": "WHATSAPP"
  }
]

deliveryModes accepts SMS, WHATSAPP, or WHATSAPP,SMS. The combined value tries WhatsApp first: if the customer isn't reachable on WhatsApp, or has no WhatsApp field, the message falls back to SMS.

Sample response

The response is always JSON:

json
{
  "balance": "0.9018",
  "result": [
    {
      "sms": "Dear Avinash, Thank you for your payment.",
      "senderId": "VluTxt",
      "smsId": "VT-499-1481622882333",
      "statusCode": "7001",
      "statusMsg": "Queued ",
      "statusDescription": "Placed your request",
      "mobileNumber": "91-xxxxxxxxxx",
      "clientId": "123454b",
      "messageCount": "1",
      "messageCost": "0.0019"
    },
    {
      "sms": "Dear Nancy, Thank you for your payment.",
      "senderId": "VluTxt",
      "smsId": "VT-853-1481622882332",
      "statusCode": "7001",
      "statusMsg": "Queued ",
      "statusDescription": "Placed your request",
      "mobileNumber": "91-xxxxxxxxx",
      "clientId": "",
      "messageCount": "1",
      "messageCost": "0.0019"
    }
  ]
}

Response parameters

ParameterDescription
smsContent of the message. Must be URL encoded and use the UTF-8 character set.
senderIdAlphanumeric string indicating the FROM address of the message.
smsIdA unique ID generated for each message request.
statusCodeStatus code for the message.
statusMsgStatus of the message, for example Sent, Delivered, Fail.
statusDescriptionDetailed description of the message's status.
mobileNumberContact number the message was delivered to.
clientIdThe ID you set on the SMS request.
messageCountBody/text of the SMS. 160 characters equals 1 SMS count.
messageCostCost per message sent. Example: a messageCount of 2 at 0.0012 each gives a messageCost of 0.0024 (2 x 0.0012).
balanceBalance available to send messages, for all countries excluding India.

Response status codes

Possible values for statusCode, status, and statusMsg on the response:

statusCodestatusstatusMsg
7000SubmittedAccepted the message to send
7001QueuedPlaced your request
7002SentMessage sent and waiting for an operator response
7003DeliveredMessage delivered successfully
7004UndeliveredUndelivered, unknown reasons
7005UndeliveredNumber barred or unsupported number
7006UndeliveredMessage content is invalid
7007UnknownUnknown status
7008FAILInvalid parameters
7009FAILInvalid sender ID, or sender ID activation pending
7010FAILInvalid mobile number
7011FAILInvalid message body or template
7012FAILExceeds the maximum limit of 650 characters
7013FAILUnsupported country, or unable to identify the country code
7014FAILTrial account can send messages only to registered, trusted numbers
7015FAILAuthentication failed
7016FAILInternal process error
7017FAILInsufficient funds
7018FAILThrottled, exceeding limit
7019FAILOpted-out mobile number
7020FAILDo Not Disturb rules accounted
7022FAILUnsupported sender ID for the receiving country
7021HoldHeld by the user

Set up a webhook

ValueText sends an HTTP POST request to your webhook to deliver updated status about each message. You can configure your webhook on the settings page after you log in.

Sample webhook request

json
[
  {
    "sms": "Dear Avinash, Thank you for your payment.",
    "senderId": "VluTxt",
    "smsId": "VT-499-1481622882333",
    "statusCode": "7003",
    "statusMsg": "Delivered ",
    "statusDescription": "Message delivered successfully",
    "mobileNumber": "91-xxxxxxxxxx",
    "clientId": "123454b",
    "messageCount": "1",
    "messageCost": "0.0019"
  },
  {
    "sms": "Dear Nancy, Thank you for your payment.",
    "senderId": "VluTxt",
    "smsId": "VT-853-1481622882332",
    "statusCode": "7003",
    "statusMsg": "Delivered ",
    "statusDescription": "Message delivered successfully",
    "mobileNumber": "91-xxxxxxxxx",
    "clientId": "",
    "messageCount": "1",
    "messageCost": "0.0019"
  }
]
Was this helpful?
← PreviousRecord Linking for First Incoming Messages Next →Send Bulk or Single SMS via Apex
Docs/Developers & integrations/Single SMS API Reference

Single SMS API Reference

Send a single SMS through ValueText's REST API and get the delivery status back right away. The same API family includes a Bulk SMS endpoint for sending a list of messages in one call. ValueText also builds custom APIs to fit specific customer needs.

Last updated 28 Nov 2025

Send a single message

Endpoint: https://valuetext.io/valuetext/rest/message/single/rest

Method: GET

Parameters

ParameterDescriptionRequired
mobileNumberMobile number of the receiver. The country code is mandatory before the number, for example +91-xxxxxxxxx, +1-xxx-xxx-xxxx, or 1xxxxx.Yes
smsThe message content. Must be URL encoded and use the UTF-8 character set.Yes
senderIdAlphanumeric string or number that sets the FROM address of the message.Yes
clientIdOptional. Your own ID, up to 40 characters, echoed back in the response.No

Headers

ValueText authenticates single SMS requests with an API key and secret key, sent as headers:

  • apiKey: myApiKey
  • secretKey: mySecretKey

To find your account's API key and secret key: log in to valuetext.io, click your name, then click Settings.

Sample request

Example
https://valuetext.io/valuetext/rest/message/single/rest?mobileNumber=918019350891&sms=Dear%20Nancy%2C%20your%20payment%20is%20successful&senderId=VLUTXT&clientId=879635

Important: the sms body of the message must be URL encoded and use the UTF-8 character set for the Single SMS API.

Sample response

json
{
  "balance": 0.9151,
  "result": [
    {
      "sms": "Dear Nancy, your payment is successful",
      "senderId": "VLUTXT",
      "smsId": "VT-456-1481563405645",
      "statusCode": 7003,
      "statusMsg": "Delivered",
      "statusDescription": "Message delivered successfully",
      "mobileNumber": "91-xxx-xxx-xx",
      "clientId": "123",
      "messageCount": 1,
      "messageCost": 0.0012
    }
  ]
}

The response fields and status codes match the Bulk SMS API's, covered in Response parameters and Response status codes below.

Send a bulk message

The Bulk SMS API sends a list of messages in a single call, built to deliver messages quickly. ValueText also offers custom APIs to fit specific integration needs.

Endpoint: https://valuetext.io/valuetext/rest/message/bulk/rest

Method: POST

Parameters

ParameterDescriptionRequired
mobileNumberMobile number of the receiver. The country code is mandatory before the number, for example +91-xxxxxxxxx, +1-xxx-xxx-xxxx, or 1xxxxx.Yes
smsThe message content, in UTF-8 character set.Yes
senderIdAlphanumeric string or number that sets the FROM address of the message.Yes
clientIdOptional. Your own ID, up to 40 characters, echoed back in the response.No

Headers

Set the content type based on the request you're sending:

  • content-type: application/json

Authentication parameters: ValueText authenticates bulk requests the same way, with an API key and secret key sent as headers:

  • apiKey: myApiKey
  • secretKey: mySecretKey

To find your account's API key and secret key: log in to valuetext.io, click your name, then click Settings.

Sample request (content-type: application/json)

json
[
  {
    "sms": "Dear Avinash, Thank you for your payment.",
    "senderId": "VluTxt",
    "mobileNumber": "91xxxxxxxxx",
    "clientId": "123454b",
    "deliveryModes": "SMS"
  },
  {
    "sms": "Dear Nancy, Thank you for your payment.",
    "senderId": "VluTxt",
    "mobileNumber": "91xxxxxxxx",
    "clientId": "",
    "deliveryModes": "WHATSAPP"
  }
]

deliveryModes accepts SMS, WHATSAPP, or WHATSAPP,SMS. The combined value tries WhatsApp first: if the customer isn't reachable on WhatsApp, or has no WhatsApp field, the message falls back to SMS.

Sample response

The response is always JSON:

json
{
  "balance": "0.9018",
  "result": [
    {
      "sms": "Dear Avinash, Thank you for your payment.",
      "senderId": "VluTxt",
      "smsId": "VT-499-1481622882333",
      "statusCode": "7001",
      "statusMsg": "Queued ",
      "statusDescription": "Placed your request",
      "mobileNumber": "91-xxxxxxxxxx",
      "clientId": "123454b",
      "messageCount": "1",
      "messageCost": "0.0019"
    },
    {
      "sms": "Dear Nancy, Thank you for your payment.",
      "senderId": "VluTxt",
      "smsId": "VT-853-1481622882332",
      "statusCode": "7001",
      "statusMsg": "Queued ",
      "statusDescription": "Placed your request",
      "mobileNumber": "91-xxxxxxxxx",
      "clientId": "",
      "messageCount": "1",
      "messageCost": "0.0019"
    }
  ]
}

Response parameters

ParameterDescription
smsContent of the message. Must be URL encoded and use the UTF-8 character set.
senderIdAlphanumeric string indicating the FROM address of the message.
smsIdA unique ID generated for each message request.
statusCodeStatus code for the message.
statusMsgStatus of the message, for example Sent, Delivered, Fail.
statusDescriptionDetailed description of the message's status.
mobileNumberContact number the message was delivered to.
clientIdThe ID you set on the SMS request.
messageCountBody/text of the SMS. 160 characters equals 1 SMS count.
messageCostCost per message sent. Example: a messageCount of 2 at 0.0012 each gives a messageCost of 0.0024 (2 x 0.0012).
balanceBalance available to send messages, for all countries excluding India.

Response status codes

Possible values for statusCode, status, and statusMsg on the response:

statusCodestatusstatusMsg
7000SubmittedAccepted the message to send
7001QueuedPlaced your request
7002SentMessage sent and waiting for an operator response
7003DeliveredMessage delivered successfully
7004UndeliveredUndelivered, unknown reasons
7005UndeliveredNumber barred or unsupported number
7006UndeliveredMessage content is invalid
7007UnknownUnknown status
7008FAILInvalid parameters
7009FAILInvalid sender ID, or sender ID activation pending
7010FAILInvalid mobile number
7011FAILInvalid message body or template
7012FAILExceeds the maximum limit of 650 characters
7013FAILUnsupported country, or unable to identify the country code
7014FAILTrial account can send messages only to registered, trusted numbers
7015FAILAuthentication failed
7016FAILInternal process error
7017FAILInsufficient funds
7018FAILThrottled, exceeding limit
7019FAILOpted-out mobile number
7020FAILDo Not Disturb rules accounted
7022FAILUnsupported sender ID for the receiving country
7021HoldHeld by the user

Set up a webhook

ValueText sends an HTTP POST request to your webhook to deliver updated status about each message. You can configure your webhook on the settings page after you log in.

Sample webhook request

json
[
  {
    "sms": "Dear Avinash, Thank you for your payment.",
    "senderId": "VluTxt",
    "smsId": "VT-499-1481622882333",
    "statusCode": "7003",
    "statusMsg": "Delivered ",
    "statusDescription": "Message delivered successfully",
    "mobileNumber": "91-xxxxxxxxxx",
    "clientId": "123454b",
    "messageCount": "1",
    "messageCost": "0.0019"
  },
  {
    "sms": "Dear Nancy, Thank you for your payment.",
    "senderId": "VluTxt",
    "smsId": "VT-853-1481622882332",
    "statusCode": "7003",
    "statusMsg": "Delivered ",
    "statusDescription": "Message delivered successfully",
    "mobileNumber": "91-xxxxxxxxx",
    "clientId": "",
    "messageCount": "1",
    "messageCost": "0.0019"
  }
]
Was this helpful?
← PreviousRecord Linking for First Incoming Messages Next →Send Bulk or Single SMS via Apex
Docs/Developers & integrations/Single SMS API Reference

Single SMS API Reference

Send a single SMS through ValueText's REST API and get the delivery status back right away. The same API family includes a Bulk SMS endpoint for sending a list of messages in one call. ValueText also builds custom APIs to fit specific customer needs.

Last updated 28 Nov 2025

Send a single message

Endpoint: https://valuetext.io/valuetext/rest/message/single/rest

Method: GET

Parameters

ParameterDescriptionRequired
mobileNumberMobile number of the receiver. The country code is mandatory before the number, for example +91-xxxxxxxxx, +1-xxx-xxx-xxxx, or 1xxxxx.Yes
smsThe message content. Must be URL encoded and use the UTF-8 character set.Yes
senderIdAlphanumeric string or number that sets the FROM address of the message.Yes
clientIdOptional. Your own ID, up to 40 characters, echoed back in the response.No

Headers

ValueText authenticates single SMS requests with an API key and secret key, sent as headers:

  • apiKey: myApiKey
  • secretKey: mySecretKey

To find your account's API key and secret key: log in to valuetext.io, click your name, then click Settings.

Sample request

Example
https://valuetext.io/valuetext/rest/message/single/rest?mobileNumber=918019350891&sms=Dear%20Nancy%2C%20your%20payment%20is%20successful&senderId=VLUTXT&clientId=879635

Important: the sms body of the message must be URL encoded and use the UTF-8 character set for the Single SMS API.

Sample response

json
{
  "balance": 0.9151,
  "result": [
    {
      "sms": "Dear Nancy, your payment is successful",
      "senderId": "VLUTXT",
      "smsId": "VT-456-1481563405645",
      "statusCode": 7003,
      "statusMsg": "Delivered",
      "statusDescription": "Message delivered successfully",
      "mobileNumber": "91-xxx-xxx-xx",
      "clientId": "123",
      "messageCount": 1,
      "messageCost": 0.0012
    }
  ]
}

The response fields and status codes match the Bulk SMS API's, covered in Response parameters and Response status codes below.

Send a bulk message

The Bulk SMS API sends a list of messages in a single call, built to deliver messages quickly. ValueText also offers custom APIs to fit specific integration needs.

Endpoint: https://valuetext.io/valuetext/rest/message/bulk/rest

Method: POST

Parameters

ParameterDescriptionRequired
mobileNumberMobile number of the receiver. The country code is mandatory before the number, for example +91-xxxxxxxxx, +1-xxx-xxx-xxxx, or 1xxxxx.Yes
smsThe message content, in UTF-8 character set.Yes
senderIdAlphanumeric string or number that sets the FROM address of the message.Yes
clientIdOptional. Your own ID, up to 40 characters, echoed back in the response.No

Headers

Set the content type based on the request you're sending:

  • content-type: application/json

Authentication parameters: ValueText authenticates bulk requests the same way, with an API key and secret key sent as headers:

  • apiKey: myApiKey
  • secretKey: mySecretKey

To find your account's API key and secret key: log in to valuetext.io, click your name, then click Settings.

Sample request (content-type: application/json)

json
[
  {
    "sms": "Dear Avinash, Thank you for your payment.",
    "senderId": "VluTxt",
    "mobileNumber": "91xxxxxxxxx",
    "clientId": "123454b",
    "deliveryModes": "SMS"
  },
  {
    "sms": "Dear Nancy, Thank you for your payment.",
    "senderId": "VluTxt",
    "mobileNumber": "91xxxxxxxx",
    "clientId": "",
    "deliveryModes": "WHATSAPP"
  }
]

deliveryModes accepts SMS, WHATSAPP, or WHATSAPP,SMS. The combined value tries WhatsApp first: if the customer isn't reachable on WhatsApp, or has no WhatsApp field, the message falls back to SMS.

Sample response

The response is always JSON:

json
{
  "balance": "0.9018",
  "result": [
    {
      "sms": "Dear Avinash, Thank you for your payment.",
      "senderId": "VluTxt",
      "smsId": "VT-499-1481622882333",
      "statusCode": "7001",
      "statusMsg": "Queued ",
      "statusDescription": "Placed your request",
      "mobileNumber": "91-xxxxxxxxxx",
      "clientId": "123454b",
      "messageCount": "1",
      "messageCost": "0.0019"
    },
    {
      "sms": "Dear Nancy, Thank you for your payment.",
      "senderId": "VluTxt",
      "smsId": "VT-853-1481622882332",
      "statusCode": "7001",
      "statusMsg": "Queued ",
      "statusDescription": "Placed your request",
      "mobileNumber": "91-xxxxxxxxx",
      "clientId": "",
      "messageCount": "1",
      "messageCost": "0.0019"
    }
  ]
}

Response parameters

ParameterDescription
smsContent of the message. Must be URL encoded and use the UTF-8 character set.
senderIdAlphanumeric string indicating the FROM address of the message.
smsIdA unique ID generated for each message request.
statusCodeStatus code for the message.
statusMsgStatus of the message, for example Sent, Delivered, Fail.
statusDescriptionDetailed description of the message's status.
mobileNumberContact number the message was delivered to.
clientIdThe ID you set on the SMS request.
messageCountBody/text of the SMS. 160 characters equals 1 SMS count.
messageCostCost per message sent. Example: a messageCount of 2 at 0.0012 each gives a messageCost of 0.0024 (2 x 0.0012).
balanceBalance available to send messages, for all countries excluding India.

Response status codes

Possible values for statusCode, status, and statusMsg on the response:

statusCodestatusstatusMsg
7000SubmittedAccepted the message to send
7001QueuedPlaced your request
7002SentMessage sent and waiting for an operator response
7003DeliveredMessage delivered successfully
7004UndeliveredUndelivered, unknown reasons
7005UndeliveredNumber barred or unsupported number
7006UndeliveredMessage content is invalid
7007UnknownUnknown status
7008FAILInvalid parameters
7009FAILInvalid sender ID, or sender ID activation pending
7010FAILInvalid mobile number
7011FAILInvalid message body or template
7012FAILExceeds the maximum limit of 650 characters
7013FAILUnsupported country, or unable to identify the country code
7014FAILTrial account can send messages only to registered, trusted numbers
7015FAILAuthentication failed
7016FAILInternal process error
7017FAILInsufficient funds
7018FAILThrottled, exceeding limit
7019FAILOpted-out mobile number
7020FAILDo Not Disturb rules accounted
7022FAILUnsupported sender ID for the receiving country
7021HoldHeld by the user

Set up a webhook

ValueText sends an HTTP POST request to your webhook to deliver updated status about each message. You can configure your webhook on the settings page after you log in.

Sample webhook request

json
[
  {
    "sms": "Dear Avinash, Thank you for your payment.",
    "senderId": "VluTxt",
    "smsId": "VT-499-1481622882333",
    "statusCode": "7003",
    "statusMsg": "Delivered ",
    "statusDescription": "Message delivered successfully",
    "mobileNumber": "91-xxxxxxxxxx",
    "clientId": "123454b",
    "messageCount": "1",
    "messageCost": "0.0019"
  },
  {
    "sms": "Dear Nancy, Thank you for your payment.",
    "senderId": "VluTxt",
    "smsId": "VT-853-1481622882332",
    "statusCode": "7003",
    "statusMsg": "Delivered ",
    "statusDescription": "Message delivered successfully",
    "mobileNumber": "91-xxxxxxxxx",
    "clientId": "",
    "messageCount": "1",
    "messageCost": "0.0019"
  }
]
Was this helpful?
← PreviousRecord Linking for First Incoming Messages Next →Send Bulk or Single SMS via Apex
Docs/Developers & integrations/Single SMS API Reference

Single SMS API Reference

Send a single SMS through ValueText's REST API and get the delivery status back right away. The same API family includes a Bulk SMS endpoint for sending a list of messages in one call. ValueText also builds custom APIs to fit specific customer needs.

Last updated 28 Nov 2025

Send a single message

Endpoint: https://valuetext.io/valuetext/rest/message/single/rest

Method: GET

Parameters

ParameterDescriptionRequired
mobileNumberMobile number of the receiver. The country code is mandatory before the number, for example +91-xxxxxxxxx, +1-xxx-xxx-xxxx, or 1xxxxx.Yes
smsThe message content. Must be URL encoded and use the UTF-8 character set.Yes
senderIdAlphanumeric string or number that sets the FROM address of the message.Yes
clientIdOptional. Your own ID, up to 40 characters, echoed back in the response.No

Headers

ValueText authenticates single SMS requests with an API key and secret key, sent as headers:

  • apiKey: myApiKey
  • secretKey: mySecretKey

To find your account's API key and secret key: log in to valuetext.io, click your name, then click Settings.

Sample request

Example
https://valuetext.io/valuetext/rest/message/single/rest?mobileNumber=918019350891&sms=Dear%20Nancy%2C%20your%20payment%20is%20successful&senderId=VLUTXT&clientId=879635

Important: the sms body of the message must be URL encoded and use the UTF-8 character set for the Single SMS API.

Sample response

json
{
  "balance": 0.9151,
  "result": [
    {
      "sms": "Dear Nancy, your payment is successful",
      "senderId": "VLUTXT",
      "smsId": "VT-456-1481563405645",
      "statusCode": 7003,
      "statusMsg": "Delivered",
      "statusDescription": "Message delivered successfully",
      "mobileNumber": "91-xxx-xxx-xx",
      "clientId": "123",
      "messageCount": 1,
      "messageCost": 0.0012
    }
  ]
}

The response fields and status codes match the Bulk SMS API's, covered in Response parameters and Response status codes below.

Send a bulk message

The Bulk SMS API sends a list of messages in a single call, built to deliver messages quickly. ValueText also offers custom APIs to fit specific integration needs.

Endpoint: https://valuetext.io/valuetext/rest/message/bulk/rest

Method: POST

Parameters

ParameterDescriptionRequired
mobileNumberMobile number of the receiver. The country code is mandatory before the number, for example +91-xxxxxxxxx, +1-xxx-xxx-xxxx, or 1xxxxx.Yes
smsThe message content, in UTF-8 character set.Yes
senderIdAlphanumeric string or number that sets the FROM address of the message.Yes
clientIdOptional. Your own ID, up to 40 characters, echoed back in the response.No

Headers

Set the content type based on the request you're sending:

  • content-type: application/json

Authentication parameters: ValueText authenticates bulk requests the same way, with an API key and secret key sent as headers:

  • apiKey: myApiKey
  • secretKey: mySecretKey

To find your account's API key and secret key: log in to valuetext.io, click your name, then click Settings.

Sample request (content-type: application/json)

json
[
  {
    "sms": "Dear Avinash, Thank you for your payment.",
    "senderId": "VluTxt",
    "mobileNumber": "91xxxxxxxxx",
    "clientId": "123454b",
    "deliveryModes": "SMS"
  },
  {
    "sms": "Dear Nancy, Thank you for your payment.",
    "senderId": "VluTxt",
    "mobileNumber": "91xxxxxxxx",
    "clientId": "",
    "deliveryModes": "WHATSAPP"
  }
]

deliveryModes accepts SMS, WHATSAPP, or WHATSAPP,SMS. The combined value tries WhatsApp first: if the customer isn't reachable on WhatsApp, or has no WhatsApp field, the message falls back to SMS.

Sample response

The response is always JSON:

json
{
  "balance": "0.9018",
  "result": [
    {
      "sms": "Dear Avinash, Thank you for your payment.",
      "senderId": "VluTxt",
      "smsId": "VT-499-1481622882333",
      "statusCode": "7001",
      "statusMsg": "Queued ",
      "statusDescription": "Placed your request",
      "mobileNumber": "91-xxxxxxxxxx",
      "clientId": "123454b",
      "messageCount": "1",
      "messageCost": "0.0019"
    },
    {
      "sms": "Dear Nancy, Thank you for your payment.",
      "senderId": "VluTxt",
      "smsId": "VT-853-1481622882332",
      "statusCode": "7001",
      "statusMsg": "Queued ",
      "statusDescription": "Placed your request",
      "mobileNumber": "91-xxxxxxxxx",
      "clientId": "",
      "messageCount": "1",
      "messageCost": "0.0019"
    }
  ]
}

Response parameters

ParameterDescription
smsContent of the message. Must be URL encoded and use the UTF-8 character set.
senderIdAlphanumeric string indicating the FROM address of the message.
smsIdA unique ID generated for each message request.
statusCodeStatus code for the message.
statusMsgStatus of the message, for example Sent, Delivered, Fail.
statusDescriptionDetailed description of the message's status.
mobileNumberContact number the message was delivered to.
clientIdThe ID you set on the SMS request.
messageCountBody/text of the SMS. 160 characters equals 1 SMS count.
messageCostCost per message sent. Example: a messageCount of 2 at 0.0012 each gives a messageCost of 0.0024 (2 x 0.0012).
balanceBalance available to send messages, for all countries excluding India.

Response status codes

Possible values for statusCode, status, and statusMsg on the response:

statusCodestatusstatusMsg
7000SubmittedAccepted the message to send
7001QueuedPlaced your request
7002SentMessage sent and waiting for an operator response
7003DeliveredMessage delivered successfully
7004UndeliveredUndelivered, unknown reasons
7005UndeliveredNumber barred or unsupported number
7006UndeliveredMessage content is invalid
7007UnknownUnknown status
7008FAILInvalid parameters
7009FAILInvalid sender ID, or sender ID activation pending
7010FAILInvalid mobile number
7011FAILInvalid message body or template
7012FAILExceeds the maximum limit of 650 characters
7013FAILUnsupported country, or unable to identify the country code
7014FAILTrial account can send messages only to registered, trusted numbers
7015FAILAuthentication failed
7016FAILInternal process error
7017FAILInsufficient funds
7018FAILThrottled, exceeding limit
7019FAILOpted-out mobile number
7020FAILDo Not Disturb rules accounted
7022FAILUnsupported sender ID for the receiving country
7021HoldHeld by the user

Set up a webhook

ValueText sends an HTTP POST request to your webhook to deliver updated status about each message. You can configure your webhook on the settings page after you log in.

Sample webhook request

json
[
  {
    "sms": "Dear Avinash, Thank you for your payment.",
    "senderId": "VluTxt",
    "smsId": "VT-499-1481622882333",
    "statusCode": "7003",
    "statusMsg": "Delivered ",
    "statusDescription": "Message delivered successfully",
    "mobileNumber": "91-xxxxxxxxxx",
    "clientId": "123454b",
    "messageCount": "1",
    "messageCost": "0.0019"
  },
  {
    "sms": "Dear Nancy, Thank you for your payment.",
    "senderId": "VluTxt",
    "smsId": "VT-853-1481622882332",
    "statusCode": "7003",
    "statusMsg": "Delivered ",
    "statusDescription": "Message delivered successfully",
    "mobileNumber": "91-xxxxxxxxx",
    "clientId": "",
    "messageCount": "1",
    "messageCost": "0.0019"
  }
]
Was this helpful?
← PreviousRecord Linking for First Incoming Messages Next →Send Bulk or Single SMS via Apex