Update Scripts and Roles for the Concurrency Limit API Changes

For the complete documentation index, see llms.txt. For a full content snapshot, see llms-full.txt. Append .md to any kestra.io/docs/* URL for plain Markdown.

Kestra 2.1.0 changes the API behind the Concurrency Limits page and, in Enterprise Edition, opens the page to tenant users.

What changed

  • Update endpoint: PUT /api/v1/{tenant}/concurrency-limit/{namespace}/{flowId} is replaced by PUT /api/v1/{tenant}/concurrency-limit. The scope moves from the path to the request body, so the same endpoint now sets flow, namespace, and tenant counters.
  • Search endpoint: GET /api/v1/{tenant}/concurrency-limit/search is paged with the page and size query parameters. It returns 25 results by default, sorted by namespace, then by flow ID. Each result also has a queued field with the number of executions waiting in that scope’s queue.
  • Enterprise Edition access: the page moves from the Instance Owner console to Tenant > Concurrency Limits. Users see the counters of the namespaces where they have FLOW VIEW. Resetting a counter requires the new FLOW UPDATE_CONCURRENCY_LIMIT permission. Instance Owners keep full access.

Update API calls

Replace calls to the old path with the new endpoint, and send the scope in the body:

curl -X PUT "https://kestra.example.com/api/v1/main/concurrency-limit" \
-H "Authorization: Bearer $KESTRA_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{"namespace": "company.team", "flowId": "my_flow", "running": 0}'

Omit flowId to set a namespace counter, and omit both namespace and flowId to set the tenant counter.

Scripts that read every counter from the search endpoint must follow the pages or pass a larger size. Otherwise, they get only the first 25 counters.

Grant the reset permission

Of the managed roles, only Admin includes UPDATE_CONCURRENCY_LIMIT. To let other users reset counters, add UPDATE_CONCURRENCY_LIMIT to the FLOW permissions of a custom role and bind it on the namespaces they manage. To reset the tenant counter, bind the role to the whole tenant.

Was this page helpful?