The tokens described below only work for the v1 API. Use Personal Tokens for the v2 API authentication.
Visit app.optimizely.com/tokens to generate an API token.
To authenticate, use a token generated from the link above in the request header, as shown in the example below. All API request examples in this documentation use the same header.
-H "Token: abcdefghijklmnopqrstuvwxyz:123456" \
You can also write applications that authenticate with the REST API via OAuth 2.0. For more details on connecting applications via OAuth 2.0, refer to our OAuth 2.0 documentation.
Using the wrong token, or including the token in the request body rather than the header, will fail with the error Authentication Failed.
Updated about 1 year ago