Restore saved agent version
curl --request POST \
--url 'https://api.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token=' \
--header 'Content-Type: application/json' \
--data '
{
"target": "staging"
}
'import requests
url = "https://api.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token="
payload = { "target": "staging" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({target: 'staging'})
};
fetch('https://api.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token=', 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.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token=",
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([
'target' => 'staging'
]),
CURLOPT_HTTPHEADER => [
"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.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token="
payload := strings.NewReader("{\n \"target\": \"staging\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token=")
.header("Content-Type", "application/json")
.body("{\n \"target\": \"staging\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token=")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"target\": \"staging\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"restored": {
"title": "<string>",
"description": "<string>",
"brandName": "<string>",
"agentInstructions": "<string>",
"welcomeMessage": "<string>",
"links": [
"<string>"
],
"keywords": [
"<string>"
],
"agentModel": "<string>",
"agentThinking": "low",
"agentThinkingModel": "<string>",
"postConvoForceThinking": true,
"timezone": "America/Chicago",
"agentVoice": "<string>",
"agentTtsEngine": "<string>",
"agentSttSmartFormatting": true,
"actions": [
{
"name": "<string>",
"instructions": "<string>",
"placeholder": "<string>",
"allowed": true,
"reason": "<string>",
"missingRequirement": "<string>"
}
],
"reportingFields": [
{
"key": "<string>",
"label": "<string>",
"instructions": "<string>",
"values": {
"choices": [
"<string>"
]
}
}
],
"apps": [
{
"appId": "<string>",
"version": "<string>",
"instructions": "<string>",
"enabled": true
}
],
"skills": [
{
"slug": "<string>",
"instructions": "<string>"
}
],
"computerDelegateAccountId": 123,
"heartbeatInstructions": "<string>",
"heartbeatEvery": "<string>",
"heartbeatConfig": {
"activeHours": {
"start": "08:00",
"end": "18:00",
"timezone": "America/Chicago"
},
"model": "<string>",
"session": "<string>",
"target": "<string>",
"to": "<string>",
"accountId": "<string>",
"includeReasoning": true,
"includeSystemPromptSection": true,
"ackMaxChars": 1,
"suppressToolErrorWarnings": true,
"timeoutSeconds": 2,
"lightContext": true,
"isolatedSession": true,
"skipWhenBusy": true
},
"backgroundAudio": "<string>",
"waitOnAnswer": 1,
"waitToGreet": true,
"postAnswerDtmf": "<string>",
"interruptionWordCount": 1,
"interruptionMinimumSpeakingTime": 1,
"speakingTimeout": 1,
"speechProcessingDelay": 1,
"speechProcessingDelayInterruptionStep": 1,
"speechProcessingDelayMaxMultiplier": 1,
"callerResponseTimeout": 1,
"callerResponseTimeoutHangupCounter": 1,
"ignoreSpeech": [
"<string>"
],
"noContactInjection": true,
"noConvoHistory": true,
"recordingNotificationPhrase": "<string>",
"preAnswerRingTime": 30,
"preAnswerSkipProcessingResults": true,
"useAgentNumberForTransfers": true,
"confirmTransfers": true,
"monitorTransfers": true,
"attendedTransfers": true,
"attendedTransferBridgeTrigger": "<string>",
"attendedTransferCheckInTimeout": 1,
"transferConfirmTimeout": 1,
"announceTransferConnecting": true,
"announceTransferConnected": true,
"preTransferNotificationStart": "<string>",
"preTransferNotificationEnd": "<string>",
"enableRingback": true,
"enableTransferRingback": true,
"cnamAutoRejectRegex": "<string>",
"cnamAutoRejectCode": 123,
"cnamAutoTransferRegex": "<string>",
"cnamAutoTransferDestination": "<string>",
"id": "<string>",
"activeEventRules": [
"<string>"
],
"effectiveReportingFields": [
{
"key": "<string>",
"label": "<string>",
"instructions": "<string>",
"values": {
"choices": [
"<string>"
]
}
}
]
}
}Agents
Restore saved agent version
Copies a saved version into staging by default. Use target=default only when an immediate live restore is intentional; staging restores still require publish.
POST
/
api
/
v2
/
agent
/
{agentConfigId}
/
versions
/
{versionId}
/
restore
Restore saved agent version
curl --request POST \
--url 'https://api.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token=' \
--header 'Content-Type: application/json' \
--data '
{
"target": "staging"
}
'import requests
url = "https://api.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token="
payload = { "target": "staging" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({target: 'staging'})
};
fetch('https://api.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token=', 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.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token=",
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([
'target' => 'staging'
]),
CURLOPT_HTTPHEADER => [
"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.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token="
payload := strings.NewReader("{\n \"target\": \"staging\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token=")
.header("Content-Type", "application/json")
.body("{\n \"target\": \"staging\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.vida.dev/api/v2/agent/{agentConfigId}/versions/{versionId}/restore?token=")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"target\": \"staging\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"restored": {
"title": "<string>",
"description": "<string>",
"brandName": "<string>",
"agentInstructions": "<string>",
"welcomeMessage": "<string>",
"links": [
"<string>"
],
"keywords": [
"<string>"
],
"agentModel": "<string>",
"agentThinking": "low",
"agentThinkingModel": "<string>",
"postConvoForceThinking": true,
"timezone": "America/Chicago",
"agentVoice": "<string>",
"agentTtsEngine": "<string>",
"agentSttSmartFormatting": true,
"actions": [
{
"name": "<string>",
"instructions": "<string>",
"placeholder": "<string>",
"allowed": true,
"reason": "<string>",
"missingRequirement": "<string>"
}
],
"reportingFields": [
{
"key": "<string>",
"label": "<string>",
"instructions": "<string>",
"values": {
"choices": [
"<string>"
]
}
}
],
"apps": [
{
"appId": "<string>",
"version": "<string>",
"instructions": "<string>",
"enabled": true
}
],
"skills": [
{
"slug": "<string>",
"instructions": "<string>"
}
],
"computerDelegateAccountId": 123,
"heartbeatInstructions": "<string>",
"heartbeatEvery": "<string>",
"heartbeatConfig": {
"activeHours": {
"start": "08:00",
"end": "18:00",
"timezone": "America/Chicago"
},
"model": "<string>",
"session": "<string>",
"target": "<string>",
"to": "<string>",
"accountId": "<string>",
"includeReasoning": true,
"includeSystemPromptSection": true,
"ackMaxChars": 1,
"suppressToolErrorWarnings": true,
"timeoutSeconds": 2,
"lightContext": true,
"isolatedSession": true,
"skipWhenBusy": true
},
"backgroundAudio": "<string>",
"waitOnAnswer": 1,
"waitToGreet": true,
"postAnswerDtmf": "<string>",
"interruptionWordCount": 1,
"interruptionMinimumSpeakingTime": 1,
"speakingTimeout": 1,
"speechProcessingDelay": 1,
"speechProcessingDelayInterruptionStep": 1,
"speechProcessingDelayMaxMultiplier": 1,
"callerResponseTimeout": 1,
"callerResponseTimeoutHangupCounter": 1,
"ignoreSpeech": [
"<string>"
],
"noContactInjection": true,
"noConvoHistory": true,
"recordingNotificationPhrase": "<string>",
"preAnswerRingTime": 30,
"preAnswerSkipProcessingResults": true,
"useAgentNumberForTransfers": true,
"confirmTransfers": true,
"monitorTransfers": true,
"attendedTransfers": true,
"attendedTransferBridgeTrigger": "<string>",
"attendedTransferCheckInTimeout": 1,
"transferConfirmTimeout": 1,
"announceTransferConnecting": true,
"announceTransferConnected": true,
"preTransferNotificationStart": "<string>",
"preTransferNotificationEnd": "<string>",
"enableRingback": true,
"enableTransferRingback": true,
"cnamAutoRejectRegex": "<string>",
"cnamAutoRejectCode": 123,
"cnamAutoTransferRegex": "<string>",
"cnamAutoTransferDestination": "<string>",
"id": "<string>",
"activeEventRules": [
"<string>"
],
"effectiveReportingFields": [
{
"key": "<string>",
"label": "<string>",
"instructions": "<string>",
"values": {
"choices": [
"<string>"
]
}
}
]
}
}Authorizations
Vida API Token
Path Parameters
Live agent configuration ID used for this account version history.
Epoch-ms score of the snapshot
Query Parameters
Account whose configuration should be restored.
Body
application/json
Available options:
staging, default ⌘I