APIHub
Back to Explore

BulkSMS JSON REST API

The BulkSMS JSON REST API lets you programmatically send, schedule, and retrieve SMS messages, manage blocked numbers, transfer credits, and configure webhook notifications, while also providing profile information and attachment uploads via signed URLs.

Telecom
basic
HTTPS
CORS: Unknown
Description enriched
Visit official documentation

Latency

681ms p95

Uptime

100.0% 30d

Playground

Verified

live

Endpoints

REST · JSON
GET

/blocked-numbers

List blocked numbers

  • min-id (query) — Records with an `id` that is greater or equal to min-id will be returned. The default value is `0`. You can add 1 to an id that you previously retrieved, to return subsequent records.
  • limit (query, limit) — The maximum number of records to return. The default value is `10000`. The value cannot be greater than 10000.
POST

/blocked-numbers

Create a blocked number

POST

/credit/transfer

Transfer credits to another account

GET

/messages

Retrieve Messages

  • limit (query, limit) — The maximum number of messages that are returned. The default is 1000. The value of `limit` is not a guarantee that a specific number of messages will be in the response, even if there are more messages available. Consider the case where you have 150 messages and you specify `limit=50`. It is possible that only 49 messages will be returned. The way to make sure that there are no more messages is to submit a new call using the `id` filter field with the `<` operator (described below).
  • filter (query) — See the message filtering for more information.
  • sortOrder (query) — The default value is DESCENDING If the `sortOrder` is DESCENDING, the newest messages be first in the result. ASCENDING places the oldest messages on top of the response.
POST

/messages

Send Messages

  • deduplication-id (query) — Safeguards against the possibility of sending the same messages more than once. If a communication failure occurs during a submission, you cannot be sure that the submission was processed; therefore you would have to submit it again. When you post the retry, you must use the `deduplication-id` of the original post. The BulkSMS system uses this ID to check that the request was not previously processed. (If it was previously processed, the submission will succeed, and the behaviour will be indistinguishable to you from a non-duplicated submission). The ID expires after about 12 hours.
  • auto-unicode (query) — Specifies how to deal with message text that contains characters not present in the GSM 03.38 character set. Messages that contain only GSM 03.38 characters are not affected by this setting. If the value is `true` then a message containing non-GSM 03.38 characters will be transmitted as a Unicode SMS (which is most likely more costly). Please note: when `auto-unicode` is `true` and the value of the `encoding` property is specified as `UNICODE`, the message will always be sent as `UNICODE`. If the value is `false` and the `encoding` property is `TEXT` then non-GSM 03.38 characters will be replaced by the `?` character. When using this setting on the API, you should take case to ensure that your message is _clean_. Invisible unicode and unexpected characters could unintentionally convert an message to `UNICODE`. A common mistake is to use the backtick character (\`) which is unicode and will turn your `TEXT` message into a `UNICODE` message.
  • schedule-date (query) — Allows you to send a message in the future. An example value is `2019-02-18T13:00:00+02:00`. It encodes to `2019-02-18T13%3A00%3A00%2B02%3A00`. Credits are deducted from your account immediately. Once submitted, scheduled messages cannot be changed or cancelled. The date can be a maximum of two years in the future. If the value is in the past, the message will be sent immediately. The date format requires you to supply an offset from UTC. You can decide to use the offset of your timezone, or maybe the zone of the recipient's location is more appropriate. If the destination is a group, the group members are determined at the time that you submit the message; not the time the message is scheduled to be sent.
  • schedule-description (query) — A note that is stored together with a scheduled submission, which could be used to more easily identify the scheduled submission at a later date. The value of this field is ignored if the `schedule-date` is not provided. A value that is longer than 256 characters is truncated.
GET

/messages/send

Send message by simple GET or POST

  • to (query, required) — The phone number of the recipient.
  • body (query, required) — The text you want to send.
  • deduplication-id (query) — Refer to the `deduplication-id` parameter.
GET

/messages/{id}

Show Message

  • id (path, required) — The `id` of the message you want to retrieve
GET

/messages/{id}/relatedReceivedMessages

List Related Messages

  • id (path, required) — The `id` of the sent message
GET

/profile

Get profile

POST

/rmm/pre-sign-attachment

Upload an attachment via a signed URL

GET

/webhooks

List webhooks

POST

/webhooks

Create a webhook

DELETE

/webhooks/{id}

Delete a webhook

GET

/webhooks/{id}

Read a webhook

POST

/webhooks/{id}

Update a webhook

15 endpoints auto-detected

Authentication

This API uses Basic authentication (a username and password).

curl -X GET \
  "https://api.bulksms.com/v1/blocked-numbers"

api.bulksms.com · HTTPS only