Update Queue
queues.update(strqueue_id, QueueUpdateParams**kwargs) -> Queue
PUT/accounts/{account_id}/queues/{queue_id}
Updates a Queue. Note that this endpoint does not support partial updates. If successful, the Queue's configuration is overwritten with the supplied configuration.
Security
API Token
The preferred authorization scheme for interacting with the Cloudflare API. Create a token.
Example:
API Email + API Key
The previous authorization scheme for interacting with the Cloudflare API, used in conjunction with a Global API key.
Example:
The previous authorization scheme for interacting with the Cloudflare API. When possible, use API tokens instead of Global API keys.
Example:
Accepted Permissions (at least one required)
Parameters
Update Queue
import os
from cloudflare import Cloudflare
client = Cloudflare(
api_token=os.environ.get("CLOUDFLARE_API_TOKEN"), # This is the default and can be omitted
)
queue = client.queues.update(
queue_id="023e105f4ecef8ad9ca31a8372d0c353",
account_id="023e105f4ecef8ad9ca31a8372d0c353",
)
print(queue.queue_id){
"errors": [
{
"code": 7003,
"message": "No route for the URI",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"messages": [
"string"
],
"result": {
"consumers": [
{
"consumer_id": "023e105f4ecef8ad9ca31a8372d0c353",
"created_on": "2019-12-27T18:11:19.117Z",
"dead_letter_queue": "dead_letter_queue",
"queue_name": "example-queue",
"script_name": "my-consumer-worker",
"settings": {
"batch_size": 50,
"max_concurrency": 10,
"max_retries": 3,
"max_wait_time_ms": 5000,
"retry_delay": 10
},
"type": "worker"
}
],
"consumers_total_count": 0,
"created_on": "created_on",
"modified_on": "modified_on",
"producers": [
{
"script": "script",
"type": "worker"
}
],
"producers_total_count": 0,
"queue_id": "queue_id",
"queue_name": "example-queue",
"settings": {
"delivery_delay": 5,
"delivery_paused": true,
"message_retention_period": 345600
}
},
"success": true
}Returns Examples
{
"errors": [
{
"code": 7003,
"message": "No route for the URI",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"messages": [
"string"
],
"result": {
"consumers": [
{
"consumer_id": "023e105f4ecef8ad9ca31a8372d0c353",
"created_on": "2019-12-27T18:11:19.117Z",
"dead_letter_queue": "dead_letter_queue",
"queue_name": "example-queue",
"script_name": "my-consumer-worker",
"settings": {
"batch_size": 50,
"max_concurrency": 10,
"max_retries": 3,
"max_wait_time_ms": 5000,
"retry_delay": 10
},
"type": "worker"
}
],
"consumers_total_count": 0,
"created_on": "created_on",
"modified_on": "modified_on",
"producers": [
{
"script": "script",
"type": "worker"
}
],
"producers_total_count": 0,
"queue_id": "queue_id",
"queue_name": "example-queue",
"settings": {
"delivery_delay": 5,
"delivery_paused": true,
"message_retention_period": 345600
}
},
"success": true
}