Skip to main content
The Credentials API lets you create and manage username/password pairs for SIP digest authentication on outbound trunks.

API Endpoint


The Credentials Object

A credentials object contains username and password for SIP digest authentication when your PBX sends calls to Plivo.

Attributes

credential_uuid
string
Unique identifier for the credentials.
name
string
Friendly name for the credentials.
username
string
Username for SIP authentication. Must be 5 to 20 characters, containing only alphanumeric characters.
password
string
Password for SIP authentication (only set on create/update, never returned in responses). Must be 5 to 20 characters, containing only alphanumeric characters and the special characters ~!@#$%^&*()_+, with at least one special character.

Example Object

The password is never returned in API responses for security. It is only used when creating or updating credentials.

List All Credentials

Get all credentials for your account.

HTTP Request

GET https://api.plivo.com/v1/Account/{auth_id}/Zentrunk/Credential/

Query Parameters

Response

api_id
string
Unique identifier for the API request.
meta
object
Pagination metadata: limit (results per page), offset (items skipped), total_count (total matching credentials).
objects
array
Array of credentials objects — see The Credentials Object.

Example

cURL

Retrieve Credentials

Get details of specific credentials.

HTTP Request

GET https://api.plivo.com/v1/Account/{auth_id}/Zentrunk/Credential/{credential_uuid}/

Response

credential_uuid
string
Unique identifier for the credentials.
name
string
Friendly name for the credentials.
username
string
Username for SIP authentication.

Example

cURL

Create Credentials

Create a new credential set for SIP digest authentication.

HTTP Request

POST https://api.plivo.com/v1/Account/{auth_id}/Zentrunk/Credential/

Request Parameters

Response

api_id
string
Unique identifier for the API request.
message
string
Status of the request. Returns credential created successfully. on a successful creation.
credential_uuid
string
Unique identifier for the credentials.

Error Codes

Example

cURL

Update Credentials

Modify an existing credential’s name, username, or password.

HTTP Request

POST https://api.plivo.com/v1/Account/{auth_id}/Zentrunk/Credential/{credential_uuid}/

Request Parameters

Response

api_id
string
Unique identifier for the API request.
message
string
Status of the request. Returns Credential updated successfully. on a successful update.
credential_uuid
string
Unique identifier for the credentials.

Example

cURL

Delete Credentials

Permanently delete credentials.

HTTP Request

DELETE https://api.plivo.com/v1/Account/{auth_id}/Zentrunk/Credential/{credential_uuid}/

Response

HTTP 204 No Content
Deleting credentials that are attached to an active trunk will break authentication for that trunk.

Example

cURL

Usage with Trunks

After creating credentials, attach them to an outbound trunk.

Example

cURL