Most Voximplant Management API calls require authentication and authorization that connects API calls to your account. As there are multiple ways to authenticate and authorize, Service accounts and API keys are the main ones. Learn how to use them with our Management API.
A service account is a way to grant access to the Voximplant Management API on behalf of your developer account. You can manage the permissions of each service account by assigning one or more roles to it. If a service account has no assigned roles, it has access to the basic Management API methods only.
Go to the Service accounts section and click Add in the upper right corner. In the dialogue opened, click Add role and specify as many roles as you need. For example, if you want to enable this new account to just start cloud scenarios, add the Scenarios role. Put a short description (if needed), click Generate key, and specify where to save a private key.
Since Voximplant does not store the keys, save it securely on your side.
Next, form a JWT using RS256. The required fields are:
You can create tokens manually.
From now on, you should substitute this token in every HTTP request to the Voximplant HTTP Management API, e.g.:
API keys (deprecated)
Formally, API keys are deprecated since there is a new advanced functionality – Service accounts. However, it still works perfectly especially if you are the only person who has access to a Voximplant account.
Go to the API Keys section of the Control panel where you can obtain your account_id and api_key. Then just substitute them in a request to the HTTP Management API, e.g.:
The request is processed with maximum permissions.