curl --request PATCH \
--url https://prod-api.ringg.ai/ca/api/v0/workspace/sub/{sub_workspace_id}/concurrency \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"concurrency": 20
}
'import requests
url = "https://prod-api.ringg.ai/ca/api/v0/workspace/sub/{sub_workspace_id}/concurrency"
payload = { "concurrency": 20 }
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({concurrency: 20})
};
fetch('https://prod-api.ringg.ai/ca/api/v0/workspace/sub/{sub_workspace_id}/concurrency', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"message": "Mumbai Collections now has 20 concurrent calls",
"sub_workspace_id": "00000000-0000-4000-8000-000000000101",
"concurrency": 20,
"limit_concurrency": 20,
"primary": {
"id": "00000000-0000-4000-8000-000000000107",
"name": "Acme Collections HQ"
},
"family": {
"parent_concurrency": 50,
"allocated_total": 20
}
}{
"message": "Only 30 concurrent calls are available to allocate from the parent workspace (capacity 50, 20 already allocated to other sub-workspaces)."
}{
"message": "Invalid credentials"
}{
"message": "Sub-workspaces are not enabled for this workspace."
}{
"message": "Sub-workspace not found"
}{
"message": "An unexpected error occurred. Please try again later."
}Allocate Concurrency to a Ringg Space
Set how many concurrent calls one Ringg Space may run, out of the capacity bought on the primary; a new Ringg Space starts at 0 and cannot call.
curl --request PATCH \
--url https://prod-api.ringg.ai/ca/api/v0/workspace/sub/{sub_workspace_id}/concurrency \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"concurrency": 20
}
'import requests
url = "https://prod-api.ringg.ai/ca/api/v0/workspace/sub/{sub_workspace_id}/concurrency"
payload = { "concurrency": 20 }
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({concurrency: 20})
};
fetch('https://prod-api.ringg.ai/ca/api/v0/workspace/sub/{sub_workspace_id}/concurrency', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"message": "Mumbai Collections now has 20 concurrent calls",
"sub_workspace_id": "00000000-0000-4000-8000-000000000101",
"concurrency": 20,
"limit_concurrency": 20,
"primary": {
"id": "00000000-0000-4000-8000-000000000107",
"name": "Acme Collections HQ"
},
"family": {
"parent_concurrency": 50,
"allocated_total": 20
}
}{
"message": "Only 30 concurrent calls are available to allocate from the parent workspace (capacity 50, 20 already allocated to other sub-workspaces)."
}{
"message": "Invalid credentials"
}{
"message": "Sub-workspaces are not enabled for this workspace."
}{
"message": "Sub-workspace not found"
}{
"message": "An unexpected error occurred. Please try again later."
}Notes
concurrencyis absolute, not a delta. Lowering an allocation always succeeds; raising it must fitfamily.concurrency_availablefrom Get Ringg Spaces.limit_concurrencyin the response is the persisted ceiling. In an individual-billing family it equals the allocation. In a common-billing family it is the family total, because idle capacity is shared, so it can be larger thanconcurrency.- This is the only allocation endpoint that applies to common-billing families; money is pooled on the primary there.
- When
family.concurrency_availablereaches0, buy more capacity on the primary, then allocate the new slots here.
Errors
400:Only 30 concurrent calls are available to allocate from the parent workspace (capacity 50, 20 already allocated to other sub-workspaces).— the allocation does not fit.400:Sub-workspaces cannot have their own sub-workspaces.— the key belongs to a Ringg Space that has Ringg Spaces enabled.401: Invalid or missing API key.403:Sub-workspaces are not enabled for this workspace.— Ringg Spaces are not enabled on the primary, or the key belongs to a Ringg Space.404:Sub-workspace not found— no active Ringg Space with this ID under your primary.422:sub_workspace_idis not a UUID, orconcurrencyis negative or missing.
Authorizations
Headers
(Required) The API key of the PRIMARY workspace. A Ringg Space's own key is refused (403, or 400 if Ringg Spaces are enabled on it).
"rg_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
Path Parameters
(Required) ID of the Ringg Space.
"00000000-0000-4000-8000-000000000101"
Body
(Required) Concurrent calls to allocate to this Ringg Space. 0 stops it from calling.
x >= 020
Response
Successful Response: The new allocation and the family totals.
"Mumbai Collections now has 20 concurrent calls"
"00000000-0000-4000-8000-000000000101"
20
The persisted ceiling: equals concurrency in an individual-billing family, the family total in a common-billing family.
20
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Was this page helpful?