Since each Twilio Region operates independently of other Regions, Twilio API credentials are a Region-specific resource. This means that any given Auth Token or API Key is only valid for the Twilio Region in which it was created. So, for example, in order to make API requests to the IE1 Region, the requests must use an Auth token or API Key that was created specifically for the IE1 region. Attempting to use credentials for another Region will result in an authentication failure.
This guide provides instructions for managing Region-specific API credentials using the Twilio Console or REST API.
To find your Auth Token and API Keys for a given Region in Twilio Console, navigate to the Keys & Credentials page:
The page displays your credentials for one Region at a time. To select which Region is displayed, find the Region select menu in the upper right-hand corner of the page.
To find your account's Auth Token for the currently selected Region, click the eyeball-shaped icon at the bottom of the box labeled "Live Credentials," near the bottom of the page.
API Keys are the preferred way to authenticate with Twilio APIs. You should only use your Auth Token for operations that cannot be accomplished with an API Key. Check out this blog post to learn more about authentication methods.
To create an API Key, click the Create API key button, enter a friendly name, and select a desired Region for the key.
When creating an API Key, always be sure to record the new API Key's SID and secret. The secret is only displayed once, when you first create the Key, and cannot be reviewed later.
To change the friendly name of an API Key, click on the friendly name or SID of the Key to view the Key's details page. Update the Friendly Name field, and click Save .
To delete an API Key, click on the friendly name or SID of the Key to view the Key's details page. Click the link titled Delete this API Key , near the bottom of the page.
Control which Region your API requests target by including the target Region name in your requests' hostnames, as described in our guide to using the REST API in non-US1 Regions.
For example, to create an API Key in the IE1 Region, first find your account's IE1 Auth Token, and use that credential to make a request to the Keys create endpoint in IE1:
_10curl -u $ACCOUNT_SID:$AUTH_TOKEN \_10 https://api.dublin.ie1.twilio.com/2010-04-01/Accounts/$ACCOUNT_SID/Keys.json \_10 --data-urlencode FriendlyName="ie1 API Key"