Delete a client token
const url = 'https://api.siprtc.io/v1/Accounts/example/ClientToken/example';const options = {method: 'DELETE', headers: {Authorization: 'Basic <credentials>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request DELETE \ --url https://api.siprtc.io/v1/Accounts/example/ClientToken/example \ --header 'Authorization: Basic <credentials>'Deletes one of the client tokens of account {auth_id}, by the id returned when it was created or listed. A token of another account is not found (404). Deleting removes the token’s record; it does not shorten the lifetime of a token value already handed out.
{auth_id} must be the authenticated account or one of its direct sub-accounts; any other account gets 403.
Authorizations
Section titled “ Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “ Path Parameters ”Your Auth ID, or a direct sub-account’s.
The token’s id.
Responses
Section titled “ Responses ”Deleted successfully
object
What was done.
Always “success”.
Example
{ "message": "tenant updated successfully", "status": "success"}The token could not be deleted.
object
The underlying error text. Only some 400 responses of the tenant list carry it.
What went wrong, in English.
Always “failed”.
Example
{ "error": "sql: connection is already closed", "message": "Account Details not found", "status": "failed"}Authentication failed: wrong or missing credentials, a disabled account, or an {auth_id} that is neither you nor your direct sub-account.
Example generated
example{auth_id} is neither the authenticated account nor its direct sub-account.
object
The underlying error text. Only some 400 responses of the tenant list carry it.
What went wrong, in English.
Always “failed”.
Example
{ "error": "sql: connection is already closed", "message": "Account Details not found", "status": "failed"}The account has no token with this id.
object
The underlying error text. Only some 400 responses of the tenant list carry it.
What went wrong, in English.
Always “failed”.
Example
{ "error": "sql: connection is already closed", "message": "Account Details not found", "status": "failed"}The account could not be checked.
object
The underlying error text. Only some 400 responses of the tenant list carry it.
What went wrong, in English.
Always “failed”.
Example
{ "error": "sql: connection is already closed", "message": "Account Details not found", "status": "failed"}