Notifications

Create and send an SMS message to the consumer

Request

  • Base URL
    https://api.paynearme-sandbox.com/json-api
  • Auth
    • OAuth 2
      Client credentials
      Token URLhttps://login.paynearme.com/oauth/token
    • or API key in query parameter signature

Request body

site_identifierstring required

Identifies your client site.

timestampstring required

The Unix Epoch time of the call

versionstring required

The version of the API. This version must match the version associated with your API key pair.

signaturestring

The HMAC signature that is calculated by running your API Secret Key and the alphabetized, concatenated parameters of the request payload through the SHA256 message digest algorithm.

NOTE: This field is required when authenticating with the HMAC signature method; it is not required when authenticating with OAuth 2.0.

recipientsstring required

The mobile phone number where you are sending the text. Use commas to separate numbers when sending the message to multiple recipients. <b>NOTE:</b> Upon request, PayNearMe can configure the <code>/send_sms</code> endpoint to return an error response for numbers blocked due to <code>STOP</code> opt-outs. Contact your Technical Account Manager for configuration details.

body_textstring required

The text of the SMS message. This parameter does not support HTML or special characters like emojis.

body_spanishstring

The text of the SMS message in Spanish. This parameter does not support HTML

language'en' | 'sp'

Indicates which version of the SMS message should be sent to the specified recipient. Options include <ul><li><code>en</code> - English</li><li><code>sp</code>- Spanish</li></ul><br/>If sending the message in Spanish, the <code>body_spanish</code> parameter must be included.

Response

SMS Sent

OR

Example response

{
  "status": "ok"
}

Changes

    • breaking

      removed the success response with the status

    • info

      api operation id send_sms was added

    • info

      the request property signature became optional

    3 more changes in this revision