Skip to main content

Get SIP Information

Method#

/sip-info#

GET https://api.z-api.io/instances/{INSTANCE_ID}/token/{INSTANCE_TOKEN}/sip-info

Header#

KeyValue
Client-TokenACCOUNT SECURITY TOKEN

Concept#

This method is used to retrieve SIP information for the instance.

It allows you to check if a SIP token has already been configured and whether the service is active.


Attention

To use this feature, the call functionality must be enabled and contracted for your account.
This endpoint should be used in the backend to avoid exposing sensitive credentials.


Request Params#

Method

GET https://api.z-api.io/instances/YOUR_INSTANCE/token/YOUR_TOKEN/sip-info


Request Body#

This endpoint does not require a request body.


Response#

200#

Returns SIP information for the instance.

When a token is already configured:#

AttributeTypeDescription
hoststringSIP server
userstringSIP user identifier
tokenstringMasked token
activebooleanIndicates if SIP is active

Example

{
"host": "sip.z-api.io",
"user": "3C67AB641C8AA0412F6A2242B4E23AC7",
"token": "BZ9***",
"active": true
}

When no token is configured:#

AttributeTypeDescription
hoststringSIP server
userstringSIP user identifier
activebooleanIndicates that SIP is not active

Example

{
"host": "sip.z-api.io",
"user": "3C67AB641C8AA0412F6A2242B4E23AC7",
"active": false
}

405#

In this case certify that you are sending the correct specification of the method. This means, verify if you sent a GET or GET as specified at the beginning of this topic.

415#

In case you receive 415 error, make sure to add the “Content-Type” of the object you are sending in the request headers, mostly “application/json”