Check out our upcoming events and meetups! View events →
Creates a new queue resource.
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});
const queue = await client.texml.accounts.queues.create('account_sid');
console.log(queue.account_sid);{
"account_sid": "4e71926f-8f13-450e-b91c-23c2ef786aa6",
"average_wait_time": 30,
"current_size": 3,
"date_created": "Fri, 27 Oct 2023 07:41:58 +0000",
"date_updated": "Fri, 27 Oct 2023 07:41:58 +0000",
"max_size": 10,
"sid": "my-queue",
"uri": "/Accounts/4e71926f-8f13-450e-b91c-23c2ef786aa6/Queues/my-queue.json",
"subresource_uris": {
"members": "/Accounts/4e71926f-8f13-450e-b91c-23c2ef786aa6/Queues/my-queue/Members.json"
}
}Documentation Index
Fetch the complete documentation index at: https://developers.telnyx.com/llms.txt
Use this file to discover all available pages before exploring further.
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
The id of the account the resource belongs to.
Create Queue request object
Queue resource.
The id of the account the resource belongs to.
"4e71926f-8f13-450e-b91c-23c2ef786aa6"
The average wait time in seconds for members in the queue.
30
The current number of members in the queue.
3
The timestamp of when the resource was created.
"Fri, 27 Oct 2023 07:41:58 +0000"
The timestamp of when the resource was last updated.
"Fri, 27 Oct 2023 07:41:58 +0000"
The maximum size of the queue.
10
The unique identifier of the queue.
"my-queue"
The relative URI for this queue.
"/Accounts/4e71926f-8f13-450e-b91c-23c2ef786aa6/Queues/my-queue.json"
A list of related resources identified by their relative URIs.
{
"members": "/Accounts/4e71926f-8f13-450e-b91c-23c2ef786aa6/Queues/my-queue/Members.json"
}
Was this page helpful?
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});
const queue = await client.texml.accounts.queues.create('account_sid');
console.log(queue.account_sid);{
"account_sid": "4e71926f-8f13-450e-b91c-23c2ef786aa6",
"average_wait_time": 30,
"current_size": 3,
"date_created": "Fri, 27 Oct 2023 07:41:58 +0000",
"date_updated": "Fri, 27 Oct 2023 07:41:58 +0000",
"max_size": 10,
"sid": "my-queue",
"uri": "/Accounts/4e71926f-8f13-450e-b91c-23c2ef786aa6/Queues/my-queue.json",
"subresource_uris": {
"members": "/Accounts/4e71926f-8f13-450e-b91c-23c2ef786aa6/Queues/my-queue/Members.json"
}
}