SMS Campaigns (1.0.0)

Everything about SMS Campaign

Send SMS Campaign

SMS Campaign Endpoint

You can post to a list with up to 20000 recipients with each API call. You can only send to a single list containing up to 20,000 recipients. The response is far less detailed than the normal Send SMS endpoint. Use the SMS Send endpoint if you would like to send to less than 1000 recipients at once.

You are required to add an opt-out message to the end of your message body if you are sending marketing message. This can be in the form of asking users to reply STOP to opt-out or by including StopMsg.me/xxxxx which is a placeholder that will add a link that can be clicked to out-out.

Properties

Name Type Required Restrictions Description
list_id integer(int32) true none Your list id.
name string true none Your campaign name.
body string true none Your campaign message.
from string true yes Your sender id
schedule integer(int32) false none Your schedule timestamp.

Refer to Status Codes for definitions of HTTP status code responses.

This endpoint requires authentication, more info...
Request
header Parameters
Content-Type
string
Example: application/json
Request Body schema: application/json
object
Responses
200

Successful response

post/v3/sms-campaigns/send
Request samples
application/json
{
  • "list_id": "{{listId}}",
  • "name": "My Campaign",
  • "from": "+6141111111",
  • "body": "Hey (First Name), I want to ask if this is your lastname: (Last Name)? Visit http://smsg.io/xxxxx for more details.",
  • "url_to_shorten": "http://www.google.com/",
  • "subject": "New sms campaign test"
}
Response samples
application/json
{
  • "http_code": 200,
  • "response_code": "SUCCESS",
  • "response_msg": "Your new campaign has been added.",
  • "data": {
    }
}

Calculate SMS Campaign Price

Calculate price for sms campaign

Properties

Name Type Required Restrictions Description
list_id integer(int32) true none Your list id.
name string true none Your campaign name.
body string true none Your campaign message.
from string true yes Your sender id
schedule integer(int32) false none Your schedule timestamp.

Refer to Status Codes for definitions of HTTP status code responses.

This endpoint requires authentication, more info...
Request
header Parameters
Content-Type
string
Example: application/json
Request Body schema: application/json
object
Responses
200

Successful response

post/v3/sms-campaigns/price
Request samples
application/json
{
  • "list_id": "{{listId}}",
  • "name": "My Campaign",
  • "from": "+61411111111",
  • "body": "Hey (First Name), I want to ask if this is your lastname: (Last Name)?"
}
Response samples
application/json
{
  • "http_code": 200,
  • "response_code": "SUCCESS",
  • "response_msg": "Here is your price for your SMS Campaign.",
  • "data": {
    }
}

Update SMS Campaign

Update sms campaign

Parameters

Parameter In Type Required Description
sms_campaign_id path integer(int32) true ID of SMS campaign to update

Properties

Name Type Required Restrictions Description
list_id integer(int32) true none Your list id.
name string true none Your campaign name.
body string true none Your campaign message.
from string true yes Your sender id
schedule integer(int32) false none Your schedule timestamp.

Refer to Status Codes for definitions of HTTP status code responses.

This endpoint requires authentication, more info...
Request
path Parameters
sms_campaign_id
required
string
header Parameters
Content-Type
string
Example: application/json
Request Body schema: application/json
object
Responses
200

Successful response

put/v3/sms-campaigns/{sms_campaign_id}
Request samples
application/json
{
  • "list_id": "{{listId}}",
  • "name": "My Campaign2",
  • "from": "+61411111111",
  • "body": "Hey (First Name), I want to ask if this is your lastname: (Last Name)?"
}
Response samples
application/json
{
  • "http_code": 200,
  • "response_code": "SUCCESS",
  • "response_msg": "Your SMS Campaign has been updated.",
  • "data": {
    }
}

View Specific SMS Campaign

Get specific sms campaign

Parameters

Parameter In Type Required Description
sms_campaign_id path integer(int32) true ID of SMS campaign to retrieve

Refer to Status Codes for definitions of HTTP status code responses.

This endpoint requires authentication, more info...
Request
path Parameters
sms_campaign_id
required
string
header Parameters
Content-Type
string
Example: application/json
Responses
200

Successful response

get/v3/sms-campaigns/{sms_campaign_id}
Request samples
curl --include \
     --header "Authorization: Basic YXBpLXVzZXJuYW1lOmFwaS1wYXNzd29yZA=="  \

'https://rest.clicksend.com/v3/sms-campaigns/{sms_campaign_id}'
Response samples
application/json
{
  • "http_code": 200,
  • "response_code": "SUCCESS",
  • "response_msg": "Your SMS Campaign.",
  • "data": {
    }
}

Cancel SMS Campaign

Cancel sms campaign

Parameters

Parameter In Type Required Description
sms_campaign_id path integer(int32) true ID of SMS Campaign to cancel

Refer to Status Codes for definitions of HTTP status code responses.

This endpoint requires authentication, more info...
Request
path Parameters
sms_campaign_id
required
string
header Parameters
Content-Type
string
Example: application/json
Request Body schema: application/json
object
Responses
200

Successful response

put/v3/sms-campaigns/{sms_campaign_id}/cancel
Request samples
application/json
{
  • "list_id": "{{listId}}",
  • "name": "My Campaign2",
  • "from": "+61411111111",
  • "body": "Hey (First Name), I want to ask if this is your lastname: (Last Name)?"
}
Response samples
application/json
{
  • "http_code": 200,
  • "response_code": "SUCCESS",
  • "response_msg": "Your SMS Campaign has been cancelled.",
  • "data": {
    }
}

View SMS Campaigns

Get list of sms campaigns

Parameters

Parameter In Type Required Description
page query integer(int32) false Page number
limit query integer(int32) false Number of records per page

Refer to Status Codes for definitions of HTTP status code responses.

This endpoint requires authentication, more info...
Request
header Parameters
Content-Type
string
Example: application/json
Responses
200

Successful response

get/v3/sms-campaigns
Request samples
curl --include \
     --header "Authorization: Basic YXBpLXVzZXJuYW1lOmFwaS1wYXNzd29yZA=="  \

'https://rest.clicksend.com/v3/sms-campaigns'
Response samples
application/json
{
  • "http_code": 200,
  • "response_code": "SUCCESS",
  • "response_msg": "Here are your SMS campaigns.",
  • "data": [
    ]
}
Copyright © ClickSend 2024. All right reserved.