Authentication
The Sender API uses tokens to authenticate requests. You can view and manage your auth tokens in the Sender account settings.
Request Requirements
Section titled “Request Requirements”- HTTPS Only: All API requests must be made over HTTPS. Calls made over plain HTTP will fail.
- Bearer Auth: Authentication is performed using bearer auth.
- Header Format: Use
-H "Authorization: Bearer {Your token}".
let url = "https://api.sender.net/v2/campaigns/";
let headers = { "Authorization": "Bearer [your-token]", "Content-Type": "application/json", "Accept": "application/json",};
fetch(url, { method: "GET", headers,}).then(response => response.json());$client = new \GuzzleHttp\Client();$response = $client->get( 'https://api.sender.net/v2/campaigns/', [ 'headers' => [ 'Authorization' => 'Bearer [your-token]', 'Content-Type' => 'application/json', 'Accept' => 'application/json', ], ]);$body = $response->getBody();import requestsimport json
url = "https://api.sender.net/v2/campaigns/"
headers = { "Authorization": "Bearer [your-token]", "Content-Type": "application/json", "Accept": "application/json",}
response = requests.request('GET', url, headers=headers)print(response.json())curl -X GET \"https://api.sender.net/v2/campaigns/" \-H "Authorization: Bearer [your-token]" \-H "Content-Type: application/json" \-H "Accept: application/json"