Skip to main content
GET
/
instances
/
{instanceId}
/
token
/
{token}
/
device
Device info
curl --request GET \
  --url https://api.z-api.io/instances/{instanceId}/token/{token}/device \
  --header 'Client-Token: <api-key>'
{
  "phone": "<string>",
  "imgUrl": "<string>",
  "about": "<string>",
  "name": "<string>",
  "device": {
    "sessionName": "<string>",
    "device_model": "<string>"
  },
  "originalDevice": "<string>",
  "sessionId": 123,
  "isBusiness": true
}

Overview

This method is responsible for returning information about the connected device/phone.

Attributes

instanceId
string
required
Your instance ID. Available in the Z-API panel under Instances.
token
string
required
Your Z-API instance token.

Response

200

phone
string
Phone number of the connected device
imgUrl
string
URL of the user’s profile picture
about
string
Profile status message
name
string
Account owner’s name
device
object
Device information
originalDevice
string
Original device type: “iphone”, “android”, “smbi” or “smba”
sessionId
number
Unique numeric session identifier
isBusiness
boolean
Indicates whether it is a business account
{
  "phone": "5511999999999",
  "imgUrl": "https://...",
  "about": "Profile status message",
  "name": "User name",
  "device": {
    "sessionName": "Z-API",
    "device_model": "Z-API"
  },
  "originalDevice": "iphone",
  "sessionId": 175,
  "isBusiness": false
}

405

Make sure you are correctly sending the method specification, that is, verify that you sent POST or GET as specified at the beginning of this topic.

415

If you receive a 415 error, make sure to add the “Content-Type” header to your request, which in most cases is “application/json”.