REST ClientQueues

list

View as MarkdownOpen in Claude

List queues in the project.

Response

datalist of objectsOptional
List of queues.

Response Example

Response
{
"links": {
"self": "string",
"first": "string",
"next": "string",
"prev": "string"
},
"data": [
{
"id": "aae131db-214c-46f5-88b6-92004f8467cf",
"project_id": "c6c4679b-716a-456a-9e41-a03821005005",
"friendly_name": "test",
"max_size": 5,
"current_size": 0,
"average_wait_time": 0,
"uri": "/api/relay/rest/queues/aae131db-214c-46f5-88b6-92004f8467cf",
"date_created": "2024-01-15T09:30:00Z",
"date_updated": "2024-01-15T09:30:00Z"
}
]
}

Example

from signalwire.rest import RestClient
client = RestClient(
project="your-project-id",
token="your-api-token",
host="your-space.signalwire.com",
)
result = client.queues.list()
for q in result.get("data", []):
print(q["name"], q.get("current_size"))