# Token Manager

This tutorial guides you through generating and managing authentication tokens in the Data Center Designer (DCD).

{% hint style="info" %}
**Note:** The **API/SDK Authentication Token Manager** can be used by any user but is mandatory for **2FA enabled** and **forced accounts**.
{% endhint %}

## Generate authentication token

In the DCD, you can now generate the authentication token to securely access IONOS Cloud APIs and SDKs by using the **API/SDK Authentication Token Manager**. Along with improved user security, the **Token Manager** offers a seamless user experience to generate tokens in a simplified way and use the token several times to access the APIs and SDKs. You can generate up to **100** authentication tokens and use any of these token values for authorizing access to APIs and SDKs.

To create a secure authentication token for authorizing to use APIs and SDKs, follow these steps:

1. In the **DCD**, go to **Menu** > **Management** > **Token Manager**.

![Token Manager option in the drop-down](https://1737632334-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MifAzdGvKLDTtvJP8sm%2Fuploads%2Fgit-blob-e43e0771ec96ddc69c8a371c9eae08a6e14a4be7%2Ftoken-management.png?alt=media)

2. In the **API/SDK Authentication Token Manager**, select **Generate Token**.
3. Copy the **Token ID** and **Close** the **token-generated** window.

{% hint style="warning" %}
**Warning:** You must save the token value for future uses. You will not be able to see the token value again due to security reasons.
{% endhint %}

{% hint style="info" %}
**Note:** You can download the token value as a text file for future uses by selecting the **Download** option next to the **Token Value**.
{% endhint %}

![Generate authentication token](https://1737632334-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MifAzdGvKLDTtvJP8sm%2Fuploads%2Fgit-blob-3d9ea7dbc826444d1cfd124712a97d901f627197%2Fgenerate-auth-token.png?alt=media)

{% hint style="success" %}
**Result:** An authentication token is generated and listed in the **API/SDK Authentication Token Manager** screen.
{% endhint %}

![Authentication token generated in the API/SDK Authentication Token Manager screen](https://1737632334-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MifAzdGvKLDTtvJP8sm%2Fuploads%2Fgit-blob-5f72f138a263f2d5b72037e21d124143078f89b9%2Ftoken-manager-attributes.png?alt=media)

### Authentication token attributes

* Each token has a **Time To Live (TTL)**, which is the duration for which a token is valid before it expires and becomes inactive. Select a **TTL** value from the drop-down list. The following are the possible values:
  * 1 Hour
  * 4 Hours
  * 1 Day
  * 7 Days
  * 30 Days
  * 60 Days
  * 90 Days
  * 180 Days
  * 365 Days
* Each token consists of:
  * **ID:** This is the ID of the token which you can use in the [<mark style="color:blue;">Auth API</mark>](https://api.ionos.com/docs/authentication/v1/). For example, to [<mark style="color:blue;">delete the token</mark>](https://api.ionos.com/docs/authentication/v1/#tag/tokens/operation/tokensDeleteById) by ID.
  * **Creation Date:** The date and time stamp of the token.
  * **Expiration Date:** The date and time stamp when the token becomes invalid depending on the defined TTL at the time of token generation.
* The generated token is listed in the **API/SDK Authentication Token Manager** screen.
* The **Token Value** is displayed only once upon generation, and you must save this value for future use.
* The token is valid based on the defined **TTL field** at the time of token generation.

  ![Authentication token attributes](https://1737632334-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MifAzdGvKLDTtvJP8sm%2Fuploads%2Fgit-blob-5f72f138a263f2d5b72037e21d124143078f89b9%2Ftoken-manager-attributes.png?alt=media)

### Delete an authentication token

{% hint style="info" %}
**Note:** The deletion of a token in the Authentication Token Manager will result in the deactivation of the token even when it has not expired. It becomes invalid immediately.
{% endhint %}

To delete an authentication token, follow these steps:

1. In the **DCD**, go to **Menu** > **Management** > **Token Manager**.
2. In the **API/SDK Authentication Token Manager**, select the authentication token to delete and select the **Delete** option.
3. Select **Delete** to confirm.

![Deletion of an authentication token](https://1737632334-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MifAzdGvKLDTtvJP8sm%2Fuploads%2Fgit-blob-a9c05a8905db2e476f5fb9de03055b506b03cdbc%2Fdelete-token.png?alt=media)

{% hint style="success" %}
**Result:** The authentication token is successfully deleted and removed from the tokens list in the **API/SDK Authentication Token Manager**.
{% endhint %}
