Watch this video for a step by step process on How to Create and Manage API Tokens in cPanel
API is a unique identifier or authentication that allows an application to access a service. It is possible to create and manage API Tokens in cPanel from version 80 onwards. The main function of the API token is to grant a user access to the server without logging in with a password.
So, by issuing API tokens, it is possible to grant permissions to resellers or third-party developers to carry API2 and UAPI operations.
1. Log in to your cPanel account.
2. Go to the SECURITY section and click on Manage API Tokens.
The Manage API Tokens panel will appear.
You will first have to create a new API token.
To Create API Tokens
- Enter the name for the API token in the API Token Name field.
- Choose the Specify an expiration date option.
- Select a date from the calendar in the API Token Expiration Date. The token will remain usable till that date.
- Click on Create.
A success message will appear as cPanel will create a new token.
5. Copy the API token someplace discreet to share it with your operator later.
6. Click on the Yes, I Saved My Token button.
The API token you created will now appear in the list for the active API tokens.
To Manage API Tokens
1. Click the Manage button for the API token you want to manage.
Here, there will be two sections-
- MANAGE API TOKEN: Here, you can change the name for the API Token.
- REVOKE API TOKEN: It allows you to discard the API token.
MANAGE API TOKEN
- Enter the new name for the API token in the New API Token Name field.
- Click the Update button.
The name of the API token will change to the new one you just updated.
REVOKE API TOKEN
1. Click on Revoke The Token.
A message will flash asking for your confirmation.
2. Click on the Yes, Revoke The Token button.
The system will turn the API Token invalid and remove it from the list of active tokens.
That is all there is to know about configuring API tokens in cPanel.