MENU navbar-image

Introduction

This documentation aims to provide all the information you need to work with our API.

Authenticating requests

To authenticate requests, include an Authorization header with the value "Bearer {YOUR_AUTH_KEY}".

All authenticated endpoints are marked with a requires authentication badge in the documentation below.

You can retrieve your token by visiting your dashboard and clicking Generate API token.

Auth V2

Login User and return JWT Token

Example request:
curl --request POST \
    "https://cloudwa.net/api/v2/auth/login" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"username\": \"whatsapp@aquadic.com\",
    \"password\": \"JamesBond007\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/auth/login"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "username": "whatsapp@aquadic.com",
    "password": "JamesBond007"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/auth/login';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'json' => [
            'username' => 'whatsapp@aquadic.com',
            'password' => 'JamesBond007',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/auth/login'
payload = {
    "username": "whatsapp@aquadic.com",
    "password": "JamesBond007"
}
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v2/auth/login

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Body Parameters

username   string   

User Email/Phone Example: whatsapp@aquadic.com

password   string   

User Password Example: JamesBond007

Get User Details

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/auth/user" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en"
const url = new URL(
    "https://cloudwa.net/api/v2/auth/user"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/auth/user';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/auth/user'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/auth/user

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Logging Out User.

requires authentication

Example request:
curl --request POST \
    "https://cloudwa.net/api/v2/auth/logout" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"from_all\": true
}"
const url = new URL(
    "https://cloudwa.net/api/v2/auth/logout"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "from_all": true
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/auth/logout';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'json' => [
            'from_all' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/auth/logout'
payload = {
    "from_all": true
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v2/auth/logout

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Body Parameters

from_all   boolean  optional  

optional send to logout from all devices. Example: true

Users/Devices

Get Devices.

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/devices" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en"
const url = new URL(
    "https://cloudwa.net/api/v2/devices"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/devices';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/devices'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/devices

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Add Or Update Devices

requires authentication

Example request:
curl --request POST \
    "https://cloudwa.net/api/v2/devices" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"device_type\": \"android\",
    \"device_token\": \"AQ-DEVICE-2022\",
    \"device_name\": \"AQ Best Device Ever\",
    \"notifiable_method\": \"firebase\",
    \"notifiable_token\": \"XXXXAAAAXXXXAAAAXXXX\",
    \"enabled\": false
}"
const url = new URL(
    "https://cloudwa.net/api/v2/devices"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "device_type": "android",
    "device_token": "AQ-DEVICE-2022",
    "device_name": "AQ Best Device Ever",
    "notifiable_method": "firebase",
    "notifiable_token": "XXXXAAAAXXXXAAAAXXXX",
    "enabled": false
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/devices';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'json' => [
            'device_type' => 'android',
            'device_token' => 'AQ-DEVICE-2022',
            'device_name' => 'AQ Best Device Ever',
            'notifiable_method' => 'firebase',
            'notifiable_token' => 'XXXXAAAAXXXXAAAAXXXX',
            'enabled' => false,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/devices'
payload = {
    "device_type": "android",
    "device_token": "AQ-DEVICE-2022",
    "device_name": "AQ Best Device Ever",
    "notifiable_method": "firebase",
    "notifiable_token": "XXXXAAAAXXXXAAAAXXXX",
    "enabled": false
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v2/devices

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Body Parameters

device_type   string   

should be ios,android,web. Example: android

device_token   string   

should be unique id to device. Example: AQ-DEVICE-2022

device_name   string  optional  

optional should be name of device. Example: AQ Best Device Ever

notifiable_method   string   

should be notifying method. Example: firebase

notifiable_token   string   

should be notifying token. Example: XXXXAAAAXXXXAAAAXXXX

enabled   boolean   

Example: false

Delete Device.

requires authentication

Example request:
curl --request DELETE \
    "https://cloudwa.net/api/v2/devices/5" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en"
const url = new URL(
    "https://cloudwa.net/api/v2/devices/5"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/devices/5';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/devices/5'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('DELETE', url, headers=headers)
response.json()

Request      

DELETE api/v2/devices/{id}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

URL Parameters

id   integer   

The ID of the device. Example: 5

Campaigns V2

Get Campaigns of Session.

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/campaigns" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en"
const url = new URL(
    "https://cloudwa.net/api/v2/campaigns"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/campaigns';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/campaigns'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/campaigns

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Get Campaign Details.

requires authentication

Example request:
curl --request POST \
    "https://cloudwa.net/api/v2/campaigns/details" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"campaign_id\": 46
}"
const url = new URL(
    "https://cloudwa.net/api/v2/campaigns/details"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "campaign_id": 46
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/campaigns/details';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'json' => [
            'campaign_id' => 46,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/campaigns/details'
payload = {
    "campaign_id": 46
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v2/campaigns/details

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Body Parameters

campaign_id   integer   

Must be at least 1. Example: 46

Get Campaign Messages.

requires authentication

Example request:
curl --request POST \
    "https://cloudwa.net/api/v2/campaigns/messages" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"campaign_id\": 17
}"
const url = new URL(
    "https://cloudwa.net/api/v2/campaigns/messages"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "campaign_id": 17
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/campaigns/messages';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'json' => [
            'campaign_id' => 17,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/campaigns/messages'
payload = {
    "campaign_id": 17
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v2/campaigns/messages

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Body Parameters

campaign_id   integer   

Must be at least 1. Example: 17

Create Campaign.

requires authentication

Example request:
curl --request POST \
    "https://cloudwa.net/api/v2/campaigns/create" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"name\": \"Campaign-2022\",
    \"description\": \"AQ-Campaign-2022\",
    \"session_uuids\": [
        \"udtygwmuazqycols\"
    ],
    \"phones\": [
        201101782890
    ],
    \"type\": \"TEXT\",
    \"starting_time\": \"2022-09-24T12:00:17\",
    \"ending_time\": \"2024-10-04T16:48:33\",
    \"typing_duration\": 11,
    \"daily_limit\": 2,
    \"message_interval\": \"earum\",
    \"add_ref\": false,
    \"session_uuid\": \"CLOUD-WA-SESSION-UUID-2022\",
    \"message\": \"Hello Test From AQ-APPS\",
    \"image\": \"https:\\/\\/static.facebook.com\\/images\\/whatsapp\\/www\\/whatsapp-promo.png\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/campaigns/create"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "name": "Campaign-2022",
    "description": "AQ-Campaign-2022",
    "session_uuids": [
        "udtygwmuazqycols"
    ],
    "phones": [
        201101782890
    ],
    "type": "TEXT",
    "starting_time": "2022-09-24T12:00:17",
    "ending_time": "2024-10-04T16:48:33",
    "typing_duration": 11,
    "daily_limit": 2,
    "message_interval": "earum",
    "add_ref": false,
    "session_uuid": "CLOUD-WA-SESSION-UUID-2022",
    "message": "Hello Test From AQ-APPS",
    "image": "https:\/\/static.facebook.com\/images\/whatsapp\/www\/whatsapp-promo.png"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/campaigns/create';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'json' => [
            'name' => 'Campaign-2022',
            'description' => 'AQ-Campaign-2022',
            'session_uuids' => [
                'udtygwmuazqycols',
            ],
            'phones' => [
                201101782890,
            ],
            'type' => 'TEXT',
            'starting_time' => '2022-09-24T12:00:17',
            'ending_time' => '2024-10-04T16:48:33',
            'typing_duration' => 11,
            'daily_limit' => 2,
            'message_interval' => 'earum',
            'add_ref' => false,
            'session_uuid' => 'CLOUD-WA-SESSION-UUID-2022',
            'message' => 'Hello Test From AQ-APPS',
            'image' => 'https://static.facebook.com/images/whatsapp/www/whatsapp-promo.png',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/campaigns/create'
payload = {
    "name": "Campaign-2022",
    "description": "AQ-Campaign-2022",
    "session_uuids": [
        "udtygwmuazqycols"
    ],
    "phones": [
        201101782890
    ],
    "type": "TEXT",
    "starting_time": "2022-09-24T12:00:17",
    "ending_time": "2024-10-04T16:48:33",
    "typing_duration": 11,
    "daily_limit": 2,
    "message_interval": "earum",
    "add_ref": false,
    "session_uuid": "CLOUD-WA-SESSION-UUID-2022",
    "message": "Hello Test From AQ-APPS",
    "image": "https:\/\/static.facebook.com\/images\/whatsapp\/www\/whatsapp-promo.png"
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v2/campaigns/create

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Body Parameters

name   string   

Name of Campaign. Example: Campaign-2022

description   string   

Description of Campaign. Example: AQ-Campaign-2022

session_uuids   string[]   

Must be at least 4 characters. Must not be greater than 191 characters.

phones   string[]   

Whatsapp numbers (max 1000).

type   string   

Message Type (TEXT/IMAGE). Example: TEXT

starting_time   date   

Starting time in [UTC] Format. Example: 2022-09-24T12:00:17

ending_time   string   

Must be a valid date. Example: 2024-10-04T16:48:33

typing_duration   integer  optional  

Example: 11

daily_limit   integer  optional  

Example: 2

message_interval   string  optional  

Example: earum

add_ref   boolean  optional  

Example: false

session_uuid   string   

Session UUID. Example: CLOUD-WA-SESSION-UUID-2022

message   string  optional  

optional Only With TYPE [IMAGE]. Example: Hello Test From AQ-APPS

image   string  optional  

optional Only Required With TYPE [IMAGE]. Example: https://static.facebook.com/images/whatsapp/www/whatsapp-promo.png

Chats V2

Get Chat of Session.

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/sessions/chat?session_uuid=CLOUD-WA-SESSION-UUID-2022" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"session_uuid\": \"cb17c915-a49b-39ca-a6c3-1d25da5df662\",
    \"chat_id\": \"fhoreiicrct\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/sessions/chat"
);

const params = {
    "session_uuid": "CLOUD-WA-SESSION-UUID-2022",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "session_uuid": "cb17c915-a49b-39ca-a6c3-1d25da5df662",
    "chat_id": "fhoreiicrct"
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/sessions/chat';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'query' => [
            'session_uuid' => 'CLOUD-WA-SESSION-UUID-2022',
        ],
        'json' => [
            'session_uuid' => 'cb17c915-a49b-39ca-a6c3-1d25da5df662',
            'chat_id' => 'fhoreiicrct',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/sessions/chat'
payload = {
    "session_uuid": "cb17c915-a49b-39ca-a6c3-1d25da5df662",
    "chat_id": "fhoreiicrct"
}
params = {
  'session_uuid': 'CLOUD-WA-SESSION-UUID-2022',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers, json=payload, params=params)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/sessions/chat

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Query Parameters

session_uuid   string   

Session UUID. Example: CLOUD-WA-SESSION-UUID-2022

Body Parameters

session_uuid   string   

Must be at least 4 characters. Must not be greater than 191 characters. Example: cb17c915-a49b-39ca-a6c3-1d25da5df662

chat_id   string   

Must be at least 5 characters. Must not be greater than 191 characters. Example: fhoreiicrct

Get Chats of Session.

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/sessions/chats?session_uuid=CLOUD-WA-SESSION-UUID-2022" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"session_uuid\": \"c729c74a-85cb-325c-ae6d-891df0844841\",
    \"type\": \"debitis\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/sessions/chats"
);

const params = {
    "session_uuid": "CLOUD-WA-SESSION-UUID-2022",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "session_uuid": "c729c74a-85cb-325c-ae6d-891df0844841",
    "type": "debitis"
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/sessions/chats';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'query' => [
            'session_uuid' => 'CLOUD-WA-SESSION-UUID-2022',
        ],
        'json' => [
            'session_uuid' => 'c729c74a-85cb-325c-ae6d-891df0844841',
            'type' => 'debitis',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/sessions/chats'
payload = {
    "session_uuid": "c729c74a-85cb-325c-ae6d-891df0844841",
    "type": "debitis"
}
params = {
  'session_uuid': 'CLOUD-WA-SESSION-UUID-2022',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers, json=payload, params=params)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/sessions/chats

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Query Parameters

session_uuid   string   

Session UUID. Example: CLOUD-WA-SESSION-UUID-2022

Body Parameters

session_uuid   string   

Must be at least 4 characters. Must not be greater than 191 characters. Example: c729c74a-85cb-325c-ae6d-891df0844841

type   string  optional  

Example: debitis

last_chat_id   string  optional  
direction   string  optional  

Get Labels of Session.

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/sessions/labels?session_uuid=CLOUD-WA-SESSION-UUID-2022" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"session_uuid\": \"f80a5098-1a86-3530-bfaa-b5faa34c991e\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/sessions/labels"
);

const params = {
    "session_uuid": "CLOUD-WA-SESSION-UUID-2022",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "session_uuid": "f80a5098-1a86-3530-bfaa-b5faa34c991e"
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/sessions/labels';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'query' => [
            'session_uuid' => 'CLOUD-WA-SESSION-UUID-2022',
        ],
        'json' => [
            'session_uuid' => 'f80a5098-1a86-3530-bfaa-b5faa34c991e',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/sessions/labels'
payload = {
    "session_uuid": "f80a5098-1a86-3530-bfaa-b5faa34c991e"
}
params = {
  'session_uuid': 'CLOUD-WA-SESSION-UUID-2022',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers, json=payload, params=params)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/sessions/labels

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Query Parameters

session_uuid   string   

Session UUID. Example: CLOUD-WA-SESSION-UUID-2022

Body Parameters

session_uuid   string   

Must be at least 4 characters. Must not be greater than 191 characters. Example: f80a5098-1a86-3530-bfaa-b5faa34c991e

Get Contacts of Session.

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/sessions/contacts?session_uuid=CLOUD-WA-SESSION-UUID-2022" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"session_uuid\": \"0291adb6-122b-3f3d-a6c1-cb86a2f0f92e\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/sessions/contacts"
);

const params = {
    "session_uuid": "CLOUD-WA-SESSION-UUID-2022",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "session_uuid": "0291adb6-122b-3f3d-a6c1-cb86a2f0f92e"
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/sessions/contacts';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'query' => [
            'session_uuid' => 'CLOUD-WA-SESSION-UUID-2022',
        ],
        'json' => [
            'session_uuid' => '0291adb6-122b-3f3d-a6c1-cb86a2f0f92e',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/sessions/contacts'
payload = {
    "session_uuid": "0291adb6-122b-3f3d-a6c1-cb86a2f0f92e"
}
params = {
  'session_uuid': 'CLOUD-WA-SESSION-UUID-2022',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers, json=payload, params=params)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/sessions/contacts

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Query Parameters

session_uuid   string   

Session UUID. Example: CLOUD-WA-SESSION-UUID-2022

Body Parameters

session_uuid   string   

Must be at least 4 characters. Must not be greater than 191 characters. Example: 0291adb6-122b-3f3d-a6c1-cb86a2f0f92e

Check if Phone Available to Chat.

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/sessions/check_availability?session_uuid=CLOUD-WA-SESSION-UUID-2022&chat_id=201101782890" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"session_uuid\": \"3b794b5a-c592-3377-980e-0898066cb29b\",
    \"chat_id\": \"qpcckzzamtkgjmlfdnciwojl\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/sessions/check_availability"
);

const params = {
    "session_uuid": "CLOUD-WA-SESSION-UUID-2022",
    "chat_id": "201101782890",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "session_uuid": "3b794b5a-c592-3377-980e-0898066cb29b",
    "chat_id": "qpcckzzamtkgjmlfdnciwojl"
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/sessions/check_availability';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'query' => [
            'session_uuid' => 'CLOUD-WA-SESSION-UUID-2022',
            'chat_id' => '201101782890',
        ],
        'json' => [
            'session_uuid' => '3b794b5a-c592-3377-980e-0898066cb29b',
            'chat_id' => 'qpcckzzamtkgjmlfdnciwojl',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/sessions/check_availability'
payload = {
    "session_uuid": "3b794b5a-c592-3377-980e-0898066cb29b",
    "chat_id": "qpcckzzamtkgjmlfdnciwojl"
}
params = {
  'session_uuid': 'CLOUD-WA-SESSION-UUID-2022',
  'chat_id': '201101782890',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers, json=payload, params=params)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/sessions/check_availability

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Query Parameters

session_uuid   string   

Session UUID. Example: CLOUD-WA-SESSION-UUID-2022

chat_id   integer   

numeric Whatsapp number. Example: 201101782890

Body Parameters

session_uuid   string   

Must be at least 4 characters. Must not be greater than 191 characters. Example: 3b794b5a-c592-3377-980e-0898066cb29b

chat_id   string   

Must be at least 5 characters. Must not be greater than 191 characters. Example: qpcckzzamtkgjmlfdnciwojl

Messages V2

Get Messages of Chat.

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/messages" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"session_uuid\": \"cc3289dd-7a8a-3869-9e07-991227bfdb80\",
    \"chat_id\": \"yaenrzhrtoccanafad\",
    \"include_notifications\": false
}"
const url = new URL(
    "https://cloudwa.net/api/v2/messages"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "session_uuid": "cc3289dd-7a8a-3869-9e07-991227bfdb80",
    "chat_id": "yaenrzhrtoccanafad",
    "include_notifications": false
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/messages';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'json' => [
            'session_uuid' => 'cc3289dd-7a8a-3869-9e07-991227bfdb80',
            'chat_id' => 'yaenrzhrtoccanafad',
            'include_notifications' => false,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/messages'
payload = {
    "session_uuid": "cc3289dd-7a8a-3869-9e07-991227bfdb80",
    "chat_id": "yaenrzhrtoccanafad",
    "include_notifications": false
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers, json=payload)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/messages

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Body Parameters

session_uuid   string   

Must be at least 4 characters. Must not be greater than 191 characters. Example: cc3289dd-7a8a-3869-9e07-991227bfdb80

chat_id   string   

Must be at least 5 characters. Must not be greater than 191 characters. Example: yaenrzhrtoccanafad

last_message_id   string  optional  
direction   string  optional  
include_notifications   boolean  optional  

Example: false

Send Message to Chat.

requires authentication

Example request:
curl --request POST \
    "https://cloudwa.net/api/v2/messages/send-message" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"session_uuid\": \"CLOUD-WA-SESSION-UUID-2022\",
    \"chat_id\": \"201101782890\",
    \"type\": \"TEXT\",
    \"schedule_at\": \"2022-09-24T12:00:17\",
    \"urgency\": \"2\",
    \"reply_to_message_id\": \"rqs\",
    \"message\": \"Hello Test From AQ-APPS\",
    \"image\": \"https:\\/\\/static.facebook.com\\/images\\/whatsapp\\/www\\/whatsapp-promo.png\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/messages/send-message"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "session_uuid": "CLOUD-WA-SESSION-UUID-2022",
    "chat_id": "201101782890",
    "type": "TEXT",
    "schedule_at": "2022-09-24T12:00:17",
    "urgency": "2",
    "reply_to_message_id": "rqs",
    "message": "Hello Test From AQ-APPS",
    "image": "https:\/\/static.facebook.com\/images\/whatsapp\/www\/whatsapp-promo.png"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/messages/send-message';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'json' => [
            'session_uuid' => 'CLOUD-WA-SESSION-UUID-2022',
            'chat_id' => '201101782890',
            'type' => 'TEXT',
            'schedule_at' => '2022-09-24T12:00:17',
            'urgency' => '2',
            'reply_to_message_id' => 'rqs',
            'message' => 'Hello Test From AQ-APPS',
            'image' => 'https://static.facebook.com/images/whatsapp/www/whatsapp-promo.png',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/messages/send-message'
payload = {
    "session_uuid": "CLOUD-WA-SESSION-UUID-2022",
    "chat_id": "201101782890",
    "type": "TEXT",
    "schedule_at": "2022-09-24T12:00:17",
    "urgency": "2",
    "reply_to_message_id": "rqs",
    "message": "Hello Test From AQ-APPS",
    "image": "https:\/\/static.facebook.com\/images\/whatsapp\/www\/whatsapp-promo.png"
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v2/messages/send-message

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Body Parameters

session_uuid   string   

Session UUID. Example: CLOUD-WA-SESSION-UUID-2022

chat_id   numeric   

Whatsapp number. Example: 201101782890

type   string   

Message Type (TEXT/IMAGE). Example: TEXT

schedule_at   string   

TIME IN UTC Format. Example: 2022-09-24T12:00:17

urgency   string   

Example: 2

Must be one of:
  • 0
  • 1
  • 2
reply_to_message_id   string  optional  

Must be at least 3 characters. Example: rqs

message   string  optional  

optional Only With TYPE [IMAGE]. Example: Hello Test From AQ-APPS

image   string  optional  

optional Only Required With TYPE [IMAGE]. Example: https://static.facebook.com/images/whatsapp/www/whatsapp-promo.png

Get Media of Message.

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/messages/get-media" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"session_uuid\": \"9fd1f4db-662f-37fd-80dd-bd64c399b770\",
    \"chat_id\": \"rnmvgoeuwxqju\",
    \"message_id\": \"rpiyzfnpclkcmonhxmhgdlpbrraxpnvwwobkjb\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/messages/get-media"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "session_uuid": "9fd1f4db-662f-37fd-80dd-bd64c399b770",
    "chat_id": "rnmvgoeuwxqju",
    "message_id": "rpiyzfnpclkcmonhxmhgdlpbrraxpnvwwobkjb"
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/messages/get-media';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'json' => [
            'session_uuid' => '9fd1f4db-662f-37fd-80dd-bd64c399b770',
            'chat_id' => 'rnmvgoeuwxqju',
            'message_id' => 'rpiyzfnpclkcmonhxmhgdlpbrraxpnvwwobkjb',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/messages/get-media'
payload = {
    "session_uuid": "9fd1f4db-662f-37fd-80dd-bd64c399b770",
    "chat_id": "rnmvgoeuwxqju",
    "message_id": "rpiyzfnpclkcmonhxmhgdlpbrraxpnvwwobkjb"
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers, json=payload)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/messages/get-media

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Body Parameters

session_uuid   string   

Must be at least 4 characters. Must not be greater than 191 characters. Example: 9fd1f4db-662f-37fd-80dd-bd64c399b770

chat_id   string   

Must be at least 5 characters. Must not be greater than 191 characters. Example: rnmvgoeuwxqju

message_id   string   

Must be at least 2 characters. Example: rpiyzfnpclkcmonhxmhgdlpbrraxpnvwwobkjb

Forward Message.

requires authentication

Example request:
curl --request POST \
    "https://cloudwa.net/api/v2/messages/forward-message" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"session_uuid\": \"ba84ae43-4419-3514-9b72-c73c9a0bd129\",
    \"chat_id\": \"hvutufaqvqrexpjmzpd\",
    \"message_id\": \"xfdgenocanzhamdlshaewwytmtnyzybl\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/messages/forward-message"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "session_uuid": "ba84ae43-4419-3514-9b72-c73c9a0bd129",
    "chat_id": "hvutufaqvqrexpjmzpd",
    "message_id": "xfdgenocanzhamdlshaewwytmtnyzybl"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/messages/forward-message';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'json' => [
            'session_uuid' => 'ba84ae43-4419-3514-9b72-c73c9a0bd129',
            'chat_id' => 'hvutufaqvqrexpjmzpd',
            'message_id' => 'xfdgenocanzhamdlshaewwytmtnyzybl',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/messages/forward-message'
payload = {
    "session_uuid": "ba84ae43-4419-3514-9b72-c73c9a0bd129",
    "chat_id": "hvutufaqvqrexpjmzpd",
    "message_id": "xfdgenocanzhamdlshaewwytmtnyzybl"
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v2/messages/forward-message

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Body Parameters

session_uuid   string   

Must be at least 4 characters. Must not be greater than 191 characters. Example: ba84ae43-4419-3514-9b72-c73c9a0bd129

chat_id   string   

Must be at least 5 characters. Must not be greater than 191 characters. Example: hvutufaqvqrexpjmzpd

message_id   string   

Must be at least 2 characters. Example: xfdgenocanzhamdlshaewwytmtnyzybl

Sessions V2

Returns All User Sessions.

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/sessions" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en"
const url = new URL(
    "https://cloudwa.net/api/v2/sessions"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/sessions';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/sessions'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/sessions

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Creates New Session.

requires authentication

Example request:
curl --request POST \
    "https://cloudwa.net/api/v2/sessions" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"name\": \"kpknxq\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/sessions"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "name": "kpknxq"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/sessions';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'json' => [
            'name' => 'kpknxq',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/sessions'
payload = {
    "name": "kpknxq"
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v2/sessions

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Body Parameters

name   string   

Must be at least 3 characters. Must not be greater than 191 characters. Example: kpknxq

Get Session Details.

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v2/sessions/status?session_uuid=CLOUD-WA-SESSION-UUID-2022" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en" \
    --data "{
    \"session_uuid\": \"e6d93768-7125-34cf-b3c5-0ba818124ecd\"
}"
const url = new URL(
    "https://cloudwa.net/api/v2/sessions/status"
);

const params = {
    "session_uuid": "CLOUD-WA-SESSION-UUID-2022",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

let body = {
    "session_uuid": "e6d93768-7125-34cf-b3c5-0ba818124ecd"
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v2/sessions/status';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
        'query' => [
            'session_uuid' => 'CLOUD-WA-SESSION-UUID-2022',
        ],
        'json' => [
            'session_uuid' => 'e6d93768-7125-34cf-b3c5-0ba818124ecd',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v2/sessions/status'
payload = {
    "session_uuid": "e6d93768-7125-34cf-b3c5-0ba818124ecd"
}
params = {
  'session_uuid': 'CLOUD-WA-SESSION-UUID-2022',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers, json=payload, params=params)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v2/sessions/status

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

Query Parameters

session_uuid   string   

Session UUID. Example: CLOUD-WA-SESSION-UUID-2022

Body Parameters

session_uuid   string   

Must be at least 4 characters. Must not be greater than 191 characters. Example: e6d93768-7125-34cf-b3c5-0ba818124ecd

OTPs V3

Register OTP in the System.

requires authentication

Example request:
curl --request POST \
    "https://cloudwa.net/api/v3/3/otps" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en"
const url = new URL(
    "https://cloudwa.net/api/v3/3/otps"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v3/3/otps';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v3/3/otps'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('POST', url, headers=headers)
response.json()

Request      

POST api/v3/{team_id}/otps

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

URL Parameters

team_id   integer   

The ID of the team. Example: 3

Returns Shared OTP Number to be used with generic otp validations (refer to customer service to subscribe)

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v3/optio/otps/shared-numbers" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en"
const url = new URL(
    "https://cloudwa.net/api/v3/optio/otps/shared-numbers"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v3/optio/otps/shared-numbers';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v3/optio/otps/shared-numbers'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

[
    "+201556031195",
    "+201153724102",
    "+201063685582"
]
 

Request      

GET api/v3/{team}/otps/shared-numbers

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

URL Parameters

team   string   

Example: optio

Get OTP From the System

requires authentication

Example request:
curl --request GET \
    --get "https://cloudwa.net/api/v3/3/otps/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --header "Accept-Language: en"
const url = new URL(
    "https://cloudwa.net/api/v3/3/otps/2"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Accept-Language": "en",
};

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'https://cloudwa.net/api/v3/3/otps/2';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
            'Accept-Language' => 'en',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://cloudwa.net/api/v3/3/otps/2'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_KEY}',
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Accept-Language': 'en'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated."
}
 

Request      

GET api/v3/{team_id}/otps/{OTP}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Accept-Language      

Example: en

URL Parameters

team_id   integer   

The ID of the team. Example: 3

OTP   integer   

Example: 2