https://retellai.com/?utm_source=discord&utm_medium=seo logo
How can I use the API to create a batch call, and ...
# ❓・ai-evy-support
e
@AI Evy How can I use the API to create a batch call, and assign the concurrent usage that batch call should use while it is in progress? for example, I only want it to use 5/20 concurrent calls during the campaign.
a
Thanks for tagging me @elders7130. I'll look through relevant sources and get back to you shortly.
### Answer --- You can create a batch call using the Create Batch Call API [(1) ]() . Here's how to do it:
Copy code
javascript
import Retell from 'retell-sdk';
const client = new Retell({
 apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const batchCallResponse = await client.batchCall.createBatchCall({
 from_number: '+14157774444',
 tasks: [{ to_number: '+12137774445' }],
}) ;
console.log(batchCallResponse.batch_call_id) ;
However, regarding your specific question about limiting concurrent usage for a batch call campaign (e.g., using only 5 out of 20 concurrent calls) , the Create Batch Call API does not include a parameter to control concurrency limits per batch . Based on the available documentation, batch calling queues your calls without hitting concurrency limits [(2) ]() . The platform has a default concurrency quota (20 concurrent calls for Pay-As-You-Go users) [(3) ]() , and there's a feature called "Reserved Concurrency" that lets you set the number of concurrency reserved for other calls [(4) ]() . If you need to limit a specific batch call to use only a portion of your total concurrency, you would need to implement your own throttling logic by: - Using the Create Phone Call API to make individual calls instead of batch calls [(5) ]() - Implementing throttling to ensure only your desired number of concurrent calls (e.g., 5) - Monitoring current usage before making new calls For direct API-level control of batch call concurrency, I'd recommend checking with Retell support, as this specific parameter isn't documented in the current API reference [(1) ]() . **
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
​ To learn more, see the sources I considered: [[1] Create Batch Call](https://docs.retellai.com/api-references/create-batch-call) [[2] Batch Calling, New Docs, and More Improvements!](https://www.retellai.com/changelog/batch-calling-new-docs-and-more-improvements) [[3] Understand concurrency & limits](https://docs.retellai.com/deploy/concurrency) [[4] Platform Changelogs | Retell AI](https://www.retellai.com/changelog) [[5] Newb Q: How to limit Retell's concurrency to 3 not the 20 default for SIP](https://discord.com/channels/1186424376300679209/1373220576235229214) ​
e
@AI Evy is concurrency shared between workspaces or does each workspace have its own concurrency limit?
a
Thanks for the follow-up, @elders7130. I'll get back to you soon.
### Answer Each workspace has its own concurrency limit [(1) ]() . Pay-As-You-Go users are allocated a quota of 20 concurrent calls per workspace . This means if you create multiple workspaces, each one gets its own separate 20 concurrent call allocation [(2) ](

▾

) [(3) ]() . For example, creating another workspace would give you an additional 20 concurrent calls in that new workspace [(3) ]() .
​ To learn more, see the sources I considered: [[1] Understand concurrency & limits](https://docs.retellai.com/deploy/concurrency) [[2] Personalization with Airtable](

https://www.youtube.com/watch?v=U8jdhkqOOhE▾

) [[3] Discord message from @maurizio_isendoorn on 2025-02-07](https://discord.com/channels/1186424376300679209/1186462578310910112/1337450035880919090) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.