POST api/v1/sms/standardsmsmessages

Sends SMS messages to the destinations specified in the request. This method cannot send from the address book contacts or groups and it can only SMS messages only.

Request Information

URI Parameters

None.

Body Parameters

The list of the messages to be sent.

Collection of StandardSingleMessage
NameDescriptionTypeAdditional information
Destination

The number to send the message to.

string

Required

Text

The message to be sent.

string

Required

Reference

A reference for the message.

string

None.

DateToSend

Set the date and time the message is to be sent to the destination.

date

None.

Sender

Specify the header the message will come under. The header must be allocated to the account otherwise it will use the default header on the account.

string

None.

Repeat

Specify how often and for how long the message repeats.

RepeatSettings

None.

SrcPort

The source port of the message.

integer

None.

DstPort

The destination port that an application on the recipient's phone is listening for.

integer

None.

Request Formats

application/json, text/json

Sample:
[
  {
    "Destination": "sample string 1",
    "Text": "sample string 2",
    "Reference": "sample string 3",
    "DateToSend": "2018-01-22T10:19:38.7153705Z",
    "Sender": "sample string 4",
    "Repeat": {
      "Frequency": 1,
      "Repetitions": 2
    },
    "SrcPort": 1,
    "DstPort": 1
  },
  {
    "Destination": "sample string 1",
    "Text": "sample string 2",
    "Reference": "sample string 3",
    "DateToSend": "2018-01-22T10:19:38.7153705Z",
    "Sender": "sample string 4",
    "Repeat": {
      "Frequency": 1,
      "Repetitions": 2
    },
    "SrcPort": 1,
    "DstPort": 1
  }
]

application/xml, text/xml

Sample:
<ArrayOfStandardSingleMessage xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <StandardSingleMessage>
    <Destination>sample string 1</Destination>
    <Text>sample string 2</Text>
    <Reference>sample string 3</Reference>
    <DateToSend>2018-01-22T10:19:38.7153705Z</DateToSend>
    <Sender>sample string 4</Sender>
    <Repeat>
      <Frequency>1</Frequency>
      <Repetitions>2</Repetitions>
    </Repeat>
    <SrcPort>1</SrcPort>
    <DstPort>1</DstPort>
  </StandardSingleMessage>
  <StandardSingleMessage>
    <Destination>sample string 1</Destination>
    <Text>sample string 2</Text>
    <Reference>sample string 3</Reference>
    <DateToSend>2018-01-22T10:19:38.7153705Z</DateToSend>
    <Sender>sample string 4</Sender>
    <Repeat>
      <Frequency>1</Frequency>
      <Repetitions>2</Repetitions>
    </Repeat>
    <SrcPort>1</SrcPort>
    <DstPort>1</DstPort>
  </StandardSingleMessage>
</ArrayOfStandardSingleMessage>

Response Information

Resource Description

The detailed results of the send.

ResponseOfSMSSingleMessageResponse
NameDescriptionTypeAdditional information
Error

Error

None.

ResponseData

ResponseDataOfSMSSingleMessageResponse

None.

Response Formats

application/json, text/json

Sample:
{
  "Error": {
    "ErrorCode": "sample string 1",
    "ErrorReason": "sample string 2"
  },
  "ResponseData": {
    "Identification": {
      "UserId": "sample string 1"
    },
    "Result": "sample string 1",
    "Detail": {
      "Transactions": [
        {
          "MessageID": "sample string 1",
          "Destination": "sample string 2"
        },
        {
          "MessageID": "sample string 1",
          "Destination": "sample string 2"
        }
      ],
      "PreTransaction": "sample string 1",
      "PostTransaction": "sample string 2",
      "CreditsUsed": "sample string 3"
    }
  }
}

application/xml, text/xml

Sample:
<ResponseOfSMSSingleMessageResponse xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <Error>
    <ErrorCode>sample string 1</ErrorCode>
    <ErrorReason>sample string 2</ErrorReason>
  </Error>
  <ResponseData>
    <Result>sample string 1</Result>
    <Identification>
      <UserId>sample string 1</UserId>
    </Identification>
    <Detail>
      <Transactions>
        <SMSSingleTransaction>
          <MessageID>sample string 1</MessageID>
          <Destination>sample string 2</Destination>
        </SMSSingleTransaction>
        <SMSSingleTransaction>
          <MessageID>sample string 1</MessageID>
          <Destination>sample string 2</Destination>
        </SMSSingleTransaction>
      </Transactions>
      <PreTransaction>sample string 1</PreTransaction>
      <PostTransaction>sample string 2</PostTransaction>
      <CreditsUsed>sample string 3</CreditsUsed>
    </Detail>
  </ResponseData>
</ResponseOfSMSSingleMessageResponse>