Authentication to use the Broadcast API
In order to use the Broadcast API, you need to get an Access Token (API Key).
Creating an Access Token
By default, Broadcast creates an Access Token when you install the application.
This initial Access Token is set up so that you can send transactional emails.
However, you can create an unlimited number of additional Access Tokens, each with their own scope of permissions.
Here are the different scopes you can set for an Access Token:
- List and read broadcasts (Read)
- Send and update broadcasts (Write)
- List and read transactional emails (Read)
- Send transactional emails (Write)
- List and read subscribers (Read)
- Create and update subscribers (Write)
- List and read subscribers in sequences (Read)
- Add or remove subscribers from sequences (Write)
The labeling of the scopes should be self-explanatory.
Whenever possible, create a new access token with the exact permissions you need and not more
Using an Access Token
All requests to the Broadcast API need to include the Access Token in the HTTP header.
To use an Access Token, you need to include it in the Authorization
header of your HTTP requests:
Authorization: Bearer <YOUR_ACCESS_TOKEN>
If your Access Token tries to make a request that it is not authorized to make, you will get a 401 (Unauthorized) response code.
Managing Your Access Tokens
To view and manage your Access Tokens, click on Access Tokens in the left sidebar of the dashboard.