Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

When sending a message with the messages api call you have some different options. On this page you can see some examples of how to use the different options.

Format

GSM

Sending a normal message

...

Code Block
javascript
javascript
{
  "message":{
    "recipients": "+4512345678",
    "sender": "TEST",
    "message": "CoolSMS",
    "format": "WAPPUSH",
    "pushurl": "http://coolsms.com"    
  }
}

MMS

To send a MMS you need to send an Array of attachments.

To send a presentation, the first attachment needs to be a SMIL document with the extension .smil
Sender should be a valid shortcode

Example of a simple MMS message with one image

Code Block
javascriptjavascript
{
  "message":{
    "recipients": "+4512345678",
    "sender": "1272",
    "message": "MMS test",
    "format": "MMS",
    "charset": "UTF-8",
    "attachment": [
        "http://coolsms.com/gfx/dk/sms-gateway.png"     ]
  }
}


Charged messages

If you have access to send charged messages you need to define a price and contenttype

...