Skip to content

ClickSend REST API v3 API

by clicksend.com

HTTP BasicHTTPSEmail
Open documentation ↗

Overview

This is the official API documentation for ClickSend.com Below you will find a current list of the available methods for clicksend. **NOTE**: You will need to create a free account to use the API. You can [**Register Here**](https://dashboard.clicksend.com/#/signup/step1/). # API URL The API should always be accessed over SSL. Base URL: `https://rest.clicksend.com/v3/` # Authentication Basic HTTP authentication should be used in the header. **Either:** `username`: Your API username `password`: Your API key ``` You can get your API credentials by clicking 'API Credentials' on the top right of the dashboard. ``` **OR** `username`: Your account username `password`: Your account password ``` These are the same credentials that you use to login to the dashboard. ``` ### Authorization Header The Authorization header is constructed as follows: 1. Username and password are combined into a string `username:password` 1. The resulting string is then encoded using Base64 encoding 1. The authorization method and a space i.e. "Basic " is then put before the encoded string. For example, if the user uses `Aladdin` as the username and `open sesame` as the password then the header is formed as follows: `Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==` ### PHP Authentication Header Example (using cURL) `curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: Basic ' . base64_encode("$username:$password")]);` # Verbs The API uses restful verbs. | Verb | Description | |---|---| | `GET` | Select one or more items. Success returns `200` status code. | | `POST` | Create a new item. Success returns `200` status code. | | `PUT` | Update an item. Success returns `200` status code. | | `DELETE` | Delete an item. Success returns `200` status code. | # Status Codes The API will respond with one of the following HTTP status codes. | Code | Response | Description | |---|---|---| | `200` | `SUCCESS` | Request completed successfully. | | `400` | `BAD_REQUEST` | The request was invalid or cannot be otherwise served. An accompanying error message will explain further. | | `401` | `UNAUTHORIZED` | Authentication credentials were missing or incorrect. | | `403` | `FORBIDDEN` | The request is understood, but it has been refused or access is not allowed. An accompanying error message will explain why. | | `404` | `NOT_FOUND` | The URI requested is invalid or the resource requested does not exists. | | `405` | `NOT_FOUND` | Method doesn't exist or is not allowed. | | `429` | `TOO_MANY_REQUESTS` | Rate Limit Exceeded. Returned when a request cannot be served due to the application’s rate limit having been exhausted for the resource. See Rate Limiting. | | `500` | `INTERNAL_SERVER_ERROR` | Something is broken | # Application Status Codes The following status codes can be returned in addition to the HTTP status code. For example, when using the Send SMS endpoint: | Response | Description | |---|---| | `SUCCESS` | Message added to queue OK. Use delivery reports to get an update on the delivery status.| | `MISSING_CREDENTIALS` | Not enough information has been supplied for authentication. Please ensure that your Username and Unique Key are supplied in your request.| | `ACCOUNT_NOT_ACTIVATED` | Your account has not been activated.| | `INVALID_RECIPIENT` | The destination mobile number is invalid.| | `THROTTLED` | Identical message body recently sent to the same recipient. Please try again in a few seconds.| | `INVALID_SENDER_ID` | Invalid Sender ID. Please ensure Sender ID is no longer than 11 characters (if alphanumeric), and contains no spaces.| | `INSUFFICIENT_CREDIT` | You have reached the end of your message credits. You will need to purchase more message credits.| | `INVALID_CREDENTIALS` | Your Username or Unique Key is incorrect.| | `ALREADY_EXISTS` | The resource you're trying to add already exists.| | `EMPTY_MESSAGE` | Message is empty.| | `TOO_MANY_RECIPIENTS` | Too many recipients.| | `MISSING_REQUIRED_FIELDS` | Some required fields are missing.| | `INVALID_SCHE

ClickSend REST API v3 is an email API from clicksend.com. Requests are authenticated with HTTP Basic auth. It is served over HTTPS. Its OpenAPI description documents 205 endpoints.

At a glance

Authentication
HTTP Basic
HTTPS
Yes
CORS
Unknown
Category
Email
Base URL
https://rest.clicksend.com/v3
Version
1.0.0
Endpoints
205
Spec updated
2021-07-12

Make a first request

Replace the placeholders; the documentation says exactly where credentials go.

cURL
curl -X GET "https://rest.clicksend.com/v3/account" \
  -H "Accept: application/json" \
  -H "Authorization: Basic BASE64_USER_PASSWORD"
JavaScript
const response = await fetch("https://rest.clicksend.com/v3/account", {
  method: "GET",
  headers: {
    "Accept": "application/json",
    "Authorization": "Basic BASE64_USER_PASSWORD",
  },
});
const data = await response.json();
console.log(data);
Python
import requests

response = requests.request(
    "GET",
    "https://rest.clicksend.com/v3/account",
    headers={
    "Accept": "application/json",
    "Authorization": "Basic BASE64_USER_PASSWORD",
    },
    timeout=30,
)
print(response.json())

Endpoints

MethodPathWhat it does
GET/accountGet account
POST/accountCreate a new account
PUT/accountUpdate Account
PUT/account-verify/sendSend account activation token
PUT/account-verify/verify/{activation_token}Verify new account
GET/account/usage/{year}/{month}/{type}Account Usage
GET/automations/email/receiptList Rules
POST/automations/email/receiptCreate a New Rule
GET/automations/email/receipt/{rule_id}Get a Specific Rule
PUT/automations/email/receipt/{rule_id}Update a Rule
DELETE/automations/email/receipt/{rule_id}Delete a Rule
GET/automations/fax/inboundList rules
POST/automations/fax/inboundCreate a new rule
GET/automations/fax/inbound/{inbound_rule_id}Get a specific rule
PUT/automations/fax/inbound/{inbound_rule_id}Update a rule
DELETE/automations/fax/inbound/{inbound_rule_id}Delete a rule
GET/automations/fax/receiptsList Rules
POST/automations/fax/receiptsCreate a New Rule
GET/automations/fax/receipts/{rule_id}Get a Specific Rule
PUT/automations/fax/receipts/{rule_id}Update a Rule
DELETE/automations/fax/receipts/{rule_id}Delete a Rule
GET/automations/sms/inboundList rules
POST/automations/sms/inbound/Create a new rule
GET/automations/sms/inbound/{inbound_rule_id}Get a specific rule
PUT/automations/sms/inbound/{inbound_rule_id}Update a rule
DELETE/automations/sms/inbound/{inbound_rule_id}Delete a rule
GET/automations/sms/receiptsList rules
POST/automations/sms/receiptsCreate a new rule
GET/automations/sms/receipts/{receipt_rule_id}Get a specific rule
PUT/automations/sms/receipts/{receipt_rule_id}Update a rule
DELETE/automations/sms/receipts/{receipt_rule_id}Delete a rule
GET/automations/voice/receiptsList rules
POST/automations/voice/receiptsCreate a new rule
GET/automations/voice/receipts/{receipt_rule_id}Get a specific rule
PUT/automations/voice/receipts/{receipt_rule_id}Update a rule
DELETE/automations/voice/receipts/{receipt_rule_id}Delete a rule
GET/contact-suggestionsList Contact Suggestions
GET/countriesGet all Countries
GET/delivery-issuesGet Delivery Issues
POST/delivery-issuesCreate Delivery Issue
GET/email-campaignsGet All Email Campaigns
POST/email-campaigns/priceCalculate Price
POST/email-campaigns/sendCreate Email Campaign
GET/email-campaigns/{campaign_id}/historyGet Specific Email Campaign History
GET/email-campaigns/{email_campaign_id}Get Specific Email Campaign
PUT/email-campaigns/{email_campaign_id}Update Email Campaign
PUT/email-campaigns/{email_campaign_id}/cancelCancel Email Campaign
PUT/email/address-verify/{email_address_id}/sendSend Verification Token
PUT/email/address-verify/{email_address_id}/verify/{activation_token}Verify Allowed Email Address
GET/email/addressesGet All Allowed Email Addresses
POST/email/addressesCreate Allowed Email Address
GET/email/addresses/{email_address_id}Get Specific Allowed Email Address
DELETE/email/addresses/{email_address_id}Delete Allowed Email Address
GET/email/historyEmail History
GET/email/history/export?filename={filename}Export History
GET/email/master-templatesGet All Master Email Templates
GET/email/master-templates-categoriesGet All Master Template Categories
GET/email/master-templates-categories/{category_id}Get Specific Email Template Category
GET/email/master-templates-categories/{category_id}/master-templatesGet All Templates For Category
GET/email/master-templates/{template_id}Get Specific Master Template
POST/email/priceEmail Price
POST/email/receiptsAdd a Test Delivery Receipt
POST/email/sendEmail Send
GET/email/templatesGet All Email Templates
POST/email/templatesCreate New Email Template from Master Template
POST/email/templates-images/{template_id}Upload Image to Specific Template
GET/email/templates/{template_id}Get Specific Email Template
PUT/email/templates/{template_id}Update an Email Template
DELETE/email/templates/{template_id}Delete Email Template
GET/fax/history/export?filename={filename}Export Fax History
GET/fax/history?date_from={date_from}&date_to={date_to}&q={q}&order_by={order_by}Get Fax History
POST/fax/priceCalculate Price
GET/fax/receiptsList of Fax Delivery Receipts
POST/fax/receiptsAdd a Test Delivery Receipt
PUT/fax/receipts-readMark Fax Delivery Receipts as read
GET/fax/receipts/{message_id}Get a Specific Fax Delivery Receipt
POST/fax/sendSend Fax
PUT/forgot-passwordForgot Password
PUT/forgot-password/verifyVerify Forgot Password
PUT/forgot-usernameForgot Username
GET/listsGet all Contact Lists
POST/listsCreate a new contact list
PUT/lists/{from_list_id}/contacts/{contact_id}/{to_list_id}Transfer a Contact
GET/lists/{list_id}Get a specific contact list
PUT/lists/{list_id}Update a specific contact list
DELETE/lists/{list_id}Delete a specific contact list
GET/lists/{list_id}/contactsGet all Contacts in a List
POST/lists/{list_id}/contactsCreate a new contact
GET/lists/{list_id}/contacts/{contact_id}Get a specific contact
PUT/lists/{list_id}/contacts/{contact_id}Update a specific contact
DELETE/lists/{list_id}/contacts/{contact_id}Delete a specific contact
GET/lists/{list_id}/export?filename={filename}Export Contacts List
POST/lists/{list_id}/importImport Contacts to List
POST/lists/{list_id}/import-csv-previewShow CSV Import File Preview
GET/lists/{list_id}/import-fieldsGet List of Acceptable Import Fields
PUT/lists/{list_id}/remove-duplicatesRemove Duplicate Contacts
PUT/lists/{list_id}/remove-opted-out-contacts/{opt_out_list_id}Remove Opted Out Contacts
PUT/mms/cancel-allCancel All MMS
GET/mms/history/export?filename={filename}Export MMS History
GET/mms/history?q={q}&order_by={order_by}&date_from={date_from}&date_to={date_to}Get MMS History

Showing the first 100 of 205 endpoints; the full list is in the documentation.

Questions

Does the ClickSend REST API v3 API need an API key?

Yes. The ClickSend REST API v3 API uses HTTP Basic authentication; the documentation explains how to get credentials.

Does the ClickSend REST API v3 API support HTTPS?

Yes, the ClickSend REST API v3 API is served over HTTPS.

How many endpoints does the ClickSend REST API v3 API have?

Its OpenAPI description lists 205 endpoints in version 1.0.0. The first 100 are shown on this page.

What are alternatives to the ClickSend REST API v3 API?

Other Email APIs include Sendgrid, Sendinblue, mail.tm, Mandrill, Guerrilla Mail.

Compare alternatives →

Listed from APIs.guru (CC0).