curl --request POST \
--url https://api.ryvo.so/v1/batch-calls \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "September follow-ups",
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"recipients": [
{
"phone_number": "+5215555550100",
"first_message": "<string>",
"language": "<string>",
"prompt": "<string>",
"dynamic_variables": {
"lead_name": "Juan García"
}
}
],
"phone_number_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"scheduled_at": "2023-11-07T05:31:56Z",
"concurrency": 25
}
'import requests
url = "https://api.ryvo.so/v1/batch-calls"
payload = {
"name": "September follow-ups",
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"recipients": [
{
"phone_number": "+5215555550100",
"first_message": "<string>",
"language": "<string>",
"prompt": "<string>",
"dynamic_variables": { "lead_name": "Juan García" }
}
],
"phone_number_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"scheduled_at": "2023-11-07T05:31:56Z",
"concurrency": 25
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'September follow-ups',
agent_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
recipients: [
{
phone_number: '+5215555550100',
first_message: '<string>',
language: '<string>',
prompt: '<string>',
dynamic_variables: {lead_name: 'Juan García'}
}
],
phone_number_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
scheduled_at: '2023-11-07T05:31:56Z',
concurrency: 25
})
};
fetch('https://api.ryvo.so/v1/batch-calls', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.ryvo.so/v1/batch-calls",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'September follow-ups',
'agent_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'recipients' => [
[
'phone_number' => '+5215555550100',
'first_message' => '<string>',
'language' => '<string>',
'prompt' => '<string>',
'dynamic_variables' => [
'lead_name' => 'Juan García'
]
]
],
'phone_number_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'scheduled_at' => '2023-11-07T05:31:56Z',
'concurrency' => 25
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.ryvo.so/v1/batch-calls"
payload := strings.NewReader("{\n \"name\": \"September follow-ups\",\n \"agent_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"recipients\": [\n {\n \"phone_number\": \"+5215555550100\",\n \"first_message\": \"<string>\",\n \"language\": \"<string>\",\n \"prompt\": \"<string>\",\n \"dynamic_variables\": {\n \"lead_name\": \"Juan García\"\n }\n }\n ],\n \"phone_number_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"scheduled_at\": \"2023-11-07T05:31:56Z\",\n \"concurrency\": 25\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.ryvo.so/v1/batch-calls")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"September follow-ups\",\n \"agent_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"recipients\": [\n {\n \"phone_number\": \"+5215555550100\",\n \"first_message\": \"<string>\",\n \"language\": \"<string>\",\n \"prompt\": \"<string>\",\n \"dynamic_variables\": {\n \"lead_name\": \"Juan García\"\n }\n }\n ],\n \"phone_number_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"scheduled_at\": \"2023-11-07T05:31:56Z\",\n \"concurrency\": 25\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ryvo.so/v1/batch-calls")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"September follow-ups\",\n \"agent_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"recipients\": [\n {\n \"phone_number\": \"+5215555550100\",\n \"first_message\": \"<string>\",\n \"language\": \"<string>\",\n \"prompt\": \"<string>\",\n \"dynamic_variables\": {\n \"lead_name\": \"Juan García\"\n }\n }\n ],\n \"phone_number_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"scheduled_at\": \"2023-11-07T05:31:56Z\",\n \"concurrency\": 25\n}"
response = http.request(request)
puts response.read_body{
"id": "2c3d4e5f-6a7b-4c8d-9e0f-1a2b3c4d5e6f",
"provider_batch_id": "btcal_01abcdef",
"name": "September follow-ups",
"status": "in_progress",
"agent": {
"id": "4d0f3c2a-6b7e-4a1c-9f2d-1e2b3c4d5e6f",
"name": "Sales assistant"
},
"provider_agent_id": "agent_8801kpabc123",
"phone_number_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"provider_phone_number_id": "phnum_01abcdef",
"scheduled_at": "2023-11-07T05:31:56Z",
"totals": {
"scheduled": 120,
"dispatched": 45,
"finished": 40
},
"created_at": "2023-11-07T05:31:56Z",
"last_synced_at": "2023-11-07T05:31:56Z"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "rate_limit_exceeded",
"message": "Rate limit exceeded. Retry in 32s (see the Retry-After header).",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "upstream_error",
"message": "Upstream provider unreachable.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}Create a batch call
Launches an outbound campaign with an agent on the ElevenLabs
runtime. Checks run in this order: plan includes batch calls, the
agent is yours and active, the wallet and subscription are in good
standing, then the provider. Without phone_number_id the number
assigned to the agent is used. concurrency is capped at the plan’s
batch concurrency.
curl --request POST \
--url https://api.ryvo.so/v1/batch-calls \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "September follow-ups",
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"recipients": [
{
"phone_number": "+5215555550100",
"first_message": "<string>",
"language": "<string>",
"prompt": "<string>",
"dynamic_variables": {
"lead_name": "Juan García"
}
}
],
"phone_number_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"scheduled_at": "2023-11-07T05:31:56Z",
"concurrency": 25
}
'import requests
url = "https://api.ryvo.so/v1/batch-calls"
payload = {
"name": "September follow-ups",
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"recipients": [
{
"phone_number": "+5215555550100",
"first_message": "<string>",
"language": "<string>",
"prompt": "<string>",
"dynamic_variables": { "lead_name": "Juan García" }
}
],
"phone_number_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"scheduled_at": "2023-11-07T05:31:56Z",
"concurrency": 25
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'September follow-ups',
agent_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
recipients: [
{
phone_number: '+5215555550100',
first_message: '<string>',
language: '<string>',
prompt: '<string>',
dynamic_variables: {lead_name: 'Juan García'}
}
],
phone_number_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
scheduled_at: '2023-11-07T05:31:56Z',
concurrency: 25
})
};
fetch('https://api.ryvo.so/v1/batch-calls', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.ryvo.so/v1/batch-calls",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'September follow-ups',
'agent_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'recipients' => [
[
'phone_number' => '+5215555550100',
'first_message' => '<string>',
'language' => '<string>',
'prompt' => '<string>',
'dynamic_variables' => [
'lead_name' => 'Juan García'
]
]
],
'phone_number_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'scheduled_at' => '2023-11-07T05:31:56Z',
'concurrency' => 25
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.ryvo.so/v1/batch-calls"
payload := strings.NewReader("{\n \"name\": \"September follow-ups\",\n \"agent_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"recipients\": [\n {\n \"phone_number\": \"+5215555550100\",\n \"first_message\": \"<string>\",\n \"language\": \"<string>\",\n \"prompt\": \"<string>\",\n \"dynamic_variables\": {\n \"lead_name\": \"Juan García\"\n }\n }\n ],\n \"phone_number_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"scheduled_at\": \"2023-11-07T05:31:56Z\",\n \"concurrency\": 25\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.ryvo.so/v1/batch-calls")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"September follow-ups\",\n \"agent_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"recipients\": [\n {\n \"phone_number\": \"+5215555550100\",\n \"first_message\": \"<string>\",\n \"language\": \"<string>\",\n \"prompt\": \"<string>\",\n \"dynamic_variables\": {\n \"lead_name\": \"Juan García\"\n }\n }\n ],\n \"phone_number_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"scheduled_at\": \"2023-11-07T05:31:56Z\",\n \"concurrency\": 25\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ryvo.so/v1/batch-calls")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"September follow-ups\",\n \"agent_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"recipients\": [\n {\n \"phone_number\": \"+5215555550100\",\n \"first_message\": \"<string>\",\n \"language\": \"<string>\",\n \"prompt\": \"<string>\",\n \"dynamic_variables\": {\n \"lead_name\": \"Juan García\"\n }\n }\n ],\n \"phone_number_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"scheduled_at\": \"2023-11-07T05:31:56Z\",\n \"concurrency\": 25\n}"
response = http.request(request)
puts response.read_body{
"id": "2c3d4e5f-6a7b-4c8d-9e0f-1a2b3c4d5e6f",
"provider_batch_id": "btcal_01abcdef",
"name": "September follow-ups",
"status": "in_progress",
"agent": {
"id": "4d0f3c2a-6b7e-4a1c-9f2d-1e2b3c4d5e6f",
"name": "Sales assistant"
},
"provider_agent_id": "agent_8801kpabc123",
"phone_number_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"provider_phone_number_id": "phnum_01abcdef",
"scheduled_at": "2023-11-07T05:31:56Z",
"totals": {
"scheduled": 120,
"dispatched": 45,
"finished": 40
},
"created_at": "2023-11-07T05:31:56Z",
"last_synced_at": "2023-11-07T05:31:56Z"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "unauthorized",
"message": "Invalid or revoked API key.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "rate_limit_exceeded",
"message": "Rate limit exceeded. Retry in 32s (see the Retry-After header).",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}{
"error": "upstream_error",
"message": "Upstream provider unreachable.",
"request_id": "f0c0a9d2-8b1e-4d8a-9c2f-6e5b7a1d2c3b"
}Autorizaciones
A Bearer token. Create keys in the portal under Settings > API keys
(https://app.ryvo.so/developers). The token has the form
ryvo_live_<64 hex characters> and is shown once.
Header: Authorization: Bearer ryvo_live_...
Cuerpo
1 - 200"September follow-ups"
An active agent of yours on the ElevenLabs runtime.
1 - 1000 elementsShow child attributes
Show child attributes
A number of yours on the ElevenLabs runtime. Defaults to the one assigned to the agent.
When to start. Omit to start now.
Capped at the plan's batch concurrency.
1 <= x <= 50Respuesta
The batch as the provider accepted it.
null only if the provider accepted the batch but Ryvo could not record it; use provider_batch_id to find it later.
"2c3d4e5f-6a7b-4c8d-9e0f-1a2b3c4d5e6f"
"btcal_01abcdef"
"September follow-ups"
pending, in_progress, completed, cancelled, failed "in_progress"
Show child attributes
Show child attributes
"agent_8801kpabc123"
"phnum_01abcdef"
Show child attributes
Show child attributes

