You'll need to authenticate your requests to access any of the endpoints in the SaaS Custom Domains API. In this guide, we'll look at how authentication works.

Bearer authentication

When establishing a connection, you will need your API token — you will find it in the Settings » API. Here's how to add the token to the request header using cURL:

Example request with bearer token

curl \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"

Always keep your token safe and revoke it if you suspect it has been compromised. You can always create a new API token. You can also create multiple API tokens.