OAuth 2-0
OAuth 2.0
Optimizely Web Experimentation provides the OAuth 2. 0 protocol to let you authorize third-party applications to access your data with the REST API.
Grant types
Optimizely Web Experimentation supports both the authorization code and implicit grant types, as described in the OAuth 2. 0 spec https //tools.
Personal access token
Optimizely's REST API lets you create and manage Optimizely Web Experimentation projects and experiments and analyze results from other applications. For example, Optimizely's partners and technology partners use the REST API to Create audiences https //docs.
Registration
You must be an Administrator of an Optimizely account to register an application. Registering an application requires the following inputs An application name that identifies your application to Optimizely Web Experimentation customers.
Redirection
If the user accepts (or rejects) authorization, Optimizely Web Experimentation sends an HTTP GET request to the redirect URI provided during authorization with the values described below. If you are using the implicit grant flow, this information is provided in the URL fragment.
Authorization code
After you obtain an authorization code, you can exchange this authorization code for an access token by issuing an HTTPS POST request to Optimizely's authorization server. The following examples show an example request and a successful response.
Refresh tokens
After the authorization code exchange, you can exchange a refresh token for an access token by issuing an HTTPS POST request to Optimizely's authorization server. The following examples show an example request and a successful response.
Authentication
Using the access token provided in the authorization response, your application can now access the REST API on behalf of the authorizing user. You can use the REST API as outlined in this documentation, except you should use a header in the format Authorization Bearer \[token] instead of Token \[token] , as shown in the following example.
Deletion
You can edit or delete your application anytime in your Optimizely account settings. To delete a registered application, go to your Optimizely App's Account Settings https //app.