# Authorization

### Create an access

In your Feature Experimentation account, go to [**Settings > Feature Experimentation > Remote Control API**](https://app2.abtasty.com/settings/feature-experimentation/remote-control-api)

<figure><img src="https://233132171-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FBWu23t7Qv6wLLh6Hl5b4%2Fuploads%2FS3K4lDxV7hzuK3BlpQtZ%2FCapture%20d%E2%80%99e%CC%81cran%202026-02-16%20a%CC%80%2011.35.35.png?alt=media&#x26;token=7efa7c9d-eeac-4f1e-bb07-4303453f7f7b" alt=""><figcaption></figcaption></figure>

You will need to fill :

* An access name
* Select one or several environments (or let empty to select all your environments)
* Select one or several actions to authorize

When you're done, click on Generate and you will see the following modal :

<figure><img src="https://233132171-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FBWu23t7Qv6wLLh6Hl5b4%2Fuploads%2FmuASbf5oHahCIZjUgvgS%2FCapture%20d%E2%80%99e%CC%81cran%202026-02-16%20a%CC%80%2011.38.06.png?alt=media&#x26;token=27bc681c-2473-40d5-9ffc-f402a4ab7307" alt=""><figcaption></figcaption></figure>

{% hint style="danger" %}
Save your Client id and Client secret now as they will be needed to generate a token.\
For security reasons, they cannot be retrieved again after you close this dialog.
{% endhint %}

### Generate a token

After generating your access credentials, you need to generate a token to authenticate your API calls.&#x20;

To generate a token you will need to do the following request. Or you can use the online generator [here](https://github.com/flagship-io/Gitbook/blob/main/remote-control-api/broken-reference/README.md):

You will find your **ACCOUNT\_ID** in Settings > Account section.

```curl
curl --location --request POST 'https://auth.flagship.io/{ACCOUNT_ID}/token?expires_in=0' \
--header 'Content-Type: application/json' \
--data-raw '{
    "grant_type": "client_credentials",
    "scope": "*",
    "client_id": "{CLIENT_ID}",
    "client_secret": "{CLIENT_SECRET}"
}'
```

**Expiration time :**

You can define the token expiration time. For example, to create a token with an expiration time of 1800 seconds, call :\
`POST https://auth.flagship.io/{ACCOUNT_ID}/token?expires_in=1800`

You now have a valid token with the list of actions you selected previously.

You can verify that your token is valid by making the following request :

```curl
curl --location --request GET 'https://auth.flagship.io/token?access_token={ACCESS_TOKEN}' \
--data-raw ''
```

### Revoke an access

You can preview or revoke your created access in the panel located below the access creation panel.

<figure><img src="https://233132171-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FBWu23t7Qv6wLLh6Hl5b4%2Fuploads%2FHtsRkkEWNkVVq14WNoxx%2FCapture%20d%E2%80%99e%CC%81cran%202026-02-16%20a%CC%80%2011.56.57.png?alt=media&#x26;token=aec4aa7a-3ede-4a45-b1ad-a3bfa1e53c9b" alt=""><figcaption></figcaption></figure>
