Queue
#
Method#
/queueGET
https://api.z-api.io/instances/YOUR_INSTANCE/token/YOUR_TOKEN/queue
#
HeaderKey | Value |
---|---|
Client-Token | ACCOUNT SECURITY TOKEN |
#
ConceptThis method is responsible for returning all messages that are in your queue waiting to be processed.
#
Attributes#
RequiredAttributes | Type | Description |
---|---|---|
page | integer | Used for pagination, you need to inform here the message page you want to retrieve |
pageSize | integer | Specify the size of the message return per page |
#
OptionalsAttributes | Type | Description |
---|---|---|
#
Request Params#
URL exampleMethod
GET
https://api.z-api.io/instances/YOUR_INSTANCE/token/YOUR_TOKEN/queue?page=1&pageSize=100
or
GET
https://api.z-api.io/instances/YOUR_INSTANCE/token/YOUR_TOKEN/queue/count
#
Response#
200Attributes | Type | Description |
---|---|---|
size | string | Number of messages in queue |
messages | array string | Array with queue messages |
Messages Array
Attributes | Type | Description |
---|---|---|
size | string | Number of messages in queue |
Message | string | Text message |
Phone | string | Recipients phone |
ZaapId | string | Z-API message ID |
Created | timetamp | Messages date |
MessageId | string | Message ID |
Example
#
405Neste caso certifique que esteja enviando o corretamente a especificação do método, ou seja verifique se você enviou o POST ou GET conforme especificado no inicio deste tópico.
#
415In 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”