Activate version
curl --request POST \
--url https://api.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate \
--header 'Authorization: <api-key>'import requests
url = "https://api.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate"
headers = {"Authorization": "<api-key>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: '<api-key>'}};
fetch('https://api.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate', 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.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "<api-key>")
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.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"agentId": "ag_7f2c91",
"name": "Support Agent",
"status": "active",
"deploymentId": "dp_44b1e0",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"versionId": "cm_31d0ba",
"config": {
"name": "Support Agent",
"languages": {
"english": {
"prompt": "You are a support agent for an online store. Keep replies to one or two sentences.",
"greeting": {
"text": "Hi! How can I help you today?",
"interruptible": false
},
"stt": [
{
"model": "deepgram/nova-3-general",
"language": "en"
}
],
"llm": [
{
"model": "openai/gpt-4o",
"apiKey": "••••••••••••••••AbCd"
}
],
"tts": [
{
"model": "cartesia/sonic-3",
"voice": "faf0731e-dfb9-4cfc-8119-259a79b27e12"
}
]
}
},
"defaultLanguage": "english",
"voiceProcessing": {
"vad": {
"sensitivity": "low",
"threshold": 0.5,
"minSpeechDuration": 1,
"minSilenceDuration": 1
},
"interruption": {
"mode": "hybrid",
"minDuration": 1,
"minWords": 1
},
"noiseCancellation": {
"model": "aicoustics/quail-l-16khz",
"provider": "<string>"
}
},
"knowledgeBaseIds": [
"<string>"
],
"callSummary": {
"enabled": true,
"llm": {
"model": "cartesia/sonic-3",
"voice": "<string>",
"language": "<string>",
"apiKey": "sk-proj-…"
},
"instruction": "<string>",
"webhook": {
"url": "<string>"
}
},
"tools": [
"<string>"
],
"advanced": {}
}
}{
"status": "error",
"errors": [
{
"path": "languages.english.tts[0].voice",
"code": "UNKNOWN_VOICE",
"message": "Sonic 3 has no voice called \"jacqueline\". Pick one from its voice list."
}
]
}{
"error": "<string>"
}{
"error": "<string>"
}Versions
Activate version
Makes an older version current by copying it into a new version. Nothing is deleted: activating v3 while you’re on v7 creates v8 with v3’s content.
Activating doesn’t change the running agent. Call Deploy agent to put the new version live.
POST
/
v1
/
agents
/
{agentId}
/
versions
/
{versionId}
/
activate
Activate version
curl --request POST \
--url https://api.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate \
--header 'Authorization: <api-key>'import requests
url = "https://api.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate"
headers = {"Authorization": "<api-key>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: '<api-key>'}};
fetch('https://api.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate', 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.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "<api-key>")
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.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.zeroruntime.ai/v1/agents/{agentId}/versions/{versionId}/activate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"agentId": "ag_7f2c91",
"name": "Support Agent",
"status": "active",
"deploymentId": "dp_44b1e0",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"versionId": "cm_31d0ba",
"config": {
"name": "Support Agent",
"languages": {
"english": {
"prompt": "You are a support agent for an online store. Keep replies to one or two sentences.",
"greeting": {
"text": "Hi! How can I help you today?",
"interruptible": false
},
"stt": [
{
"model": "deepgram/nova-3-general",
"language": "en"
}
],
"llm": [
{
"model": "openai/gpt-4o",
"apiKey": "••••••••••••••••AbCd"
}
],
"tts": [
{
"model": "cartesia/sonic-3",
"voice": "faf0731e-dfb9-4cfc-8119-259a79b27e12"
}
]
}
},
"defaultLanguage": "english",
"voiceProcessing": {
"vad": {
"sensitivity": "low",
"threshold": 0.5,
"minSpeechDuration": 1,
"minSilenceDuration": 1
},
"interruption": {
"mode": "hybrid",
"minDuration": 1,
"minWords": 1
},
"noiseCancellation": {
"model": "aicoustics/quail-l-16khz",
"provider": "<string>"
}
},
"knowledgeBaseIds": [
"<string>"
],
"callSummary": {
"enabled": true,
"llm": {
"model": "cartesia/sonic-3",
"voice": "<string>",
"language": "<string>",
"apiKey": "sk-proj-…"
},
"instruction": "<string>",
"webhook": {
"url": "<string>"
}
},
"tools": [
"<string>"
],
"advanced": {}
}
}{
"status": "error",
"errors": [
{
"path": "languages.english.tts[0].voice",
"code": "UNKNOWN_VOICE",
"message": "Sonic 3 has no voice called \"jacqueline\". Pick one from its voice list."
}
]
}{
"error": "<string>"
}{
"error": "<string>"
}Authorizations
Your API token, sent raw (no Bearer prefix).
Response
The new version.
Example:
"ag_7f2c91"
Example:
"Support Agent"
active once deployed. A new agent stays inactive only if its first deploy couldn't run, for example when the account has no active API key. Call Deploy agent yourself then.
Available options:
inactive, active Example:
"active"
Example:
"dp_44b1e0"
Example:
"cm_31d0ba"
The config as stored, with names resolved.
Show child attributes
Show child attributes