curl --request POST \
--url 'https://api.vida.dev/api/v2/tasks?token=' \
--header 'Content-Type: application/json' \
--data '
{
"type": "call",
"target": "+15551234567",
"accountId": 1234,
"title": "<string>",
"context": "<string>",
"taskContext": "Confirm whether the customer wants a renewal quote.",
"scheduledFor": 1712350000,
"externalTaskId": "<string>",
"contactListName": "<string>",
"goal": {
"completionCriteria": "<string>",
"description": "<string>"
},
"retryPolicy": {
"retryOn": [],
"delaysSeconds": [
1296030
],
"steps": [
{
"offsetSeconds": 3888030,
"target": "<string>",
"responseTimeoutSeconds": 302430,
"content": {}
}
],
"responseTimeoutSeconds": 302430
},
"meta": {},
"greeting": "<string>",
"waitToGreet": true
}
'import requests
url = "https://api.vida.dev/api/v2/tasks?token="
payload = {
"type": "call",
"target": "+15551234567",
"accountId": 1234,
"title": "<string>",
"context": "<string>",
"taskContext": "Confirm whether the customer wants a renewal quote.",
"scheduledFor": 1712350000,
"externalTaskId": "<string>",
"contactListName": "<string>",
"goal": {
"completionCriteria": "<string>",
"description": "<string>"
},
"retryPolicy": {
"retryOn": [],
"delaysSeconds": [1296030],
"steps": [
{
"offsetSeconds": 3888030,
"target": "<string>",
"responseTimeoutSeconds": 302430,
"content": {}
}
],
"responseTimeoutSeconds": 302430
},
"meta": {},
"greeting": "<string>",
"waitToGreet": True
}
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({
type: 'call',
target: '+15551234567',
accountId: 1234,
title: '<string>',
context: '<string>',
taskContext: 'Confirm whether the customer wants a renewal quote.',
scheduledFor: 1712350000,
externalTaskId: '<string>',
contactListName: '<string>',
goal: {completionCriteria: '<string>', description: '<string>'},
retryPolicy: {
retryOn: [],
delaysSeconds: [1296030],
steps: [
{
offsetSeconds: 3888030,
target: '<string>',
responseTimeoutSeconds: 302430,
content: {}
}
],
responseTimeoutSeconds: 302430
},
meta: {},
greeting: '<string>',
waitToGreet: true
})
};
fetch('https://api.vida.dev/api/v2/tasks?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/tasks?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([
'type' => 'call',
'target' => '+15551234567',
'accountId' => 1234,
'title' => '<string>',
'context' => '<string>',
'taskContext' => 'Confirm whether the customer wants a renewal quote.',
'scheduledFor' => 1712350000,
'externalTaskId' => '<string>',
'contactListName' => '<string>',
'goal' => [
'completionCriteria' => '<string>',
'description' => '<string>'
],
'retryPolicy' => [
'retryOn' => [
],
'delaysSeconds' => [
1296030
],
'steps' => [
[
'offsetSeconds' => 3888030,
'target' => '<string>',
'responseTimeoutSeconds' => 302430,
'content' => [
]
]
],
'responseTimeoutSeconds' => 302430
],
'meta' => [
],
'greeting' => '<string>',
'waitToGreet' => true
]),
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/tasks?token="
payload := strings.NewReader("{\n \"type\": \"call\",\n \"target\": \"+15551234567\",\n \"accountId\": 1234,\n \"title\": \"<string>\",\n \"context\": \"<string>\",\n \"taskContext\": \"Confirm whether the customer wants a renewal quote.\",\n \"scheduledFor\": 1712350000,\n \"externalTaskId\": \"<string>\",\n \"contactListName\": \"<string>\",\n \"goal\": {\n \"completionCriteria\": \"<string>\",\n \"description\": \"<string>\"\n },\n \"retryPolicy\": {\n \"retryOn\": [],\n \"delaysSeconds\": [\n 1296030\n ],\n \"steps\": [\n {\n \"offsetSeconds\": 3888030,\n \"target\": \"<string>\",\n \"responseTimeoutSeconds\": 302430,\n \"content\": {}\n }\n ],\n \"responseTimeoutSeconds\": 302430\n },\n \"meta\": {},\n \"greeting\": \"<string>\",\n \"waitToGreet\": true\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/tasks?token=")
.header("Content-Type", "application/json")
.body("{\n \"type\": \"call\",\n \"target\": \"+15551234567\",\n \"accountId\": 1234,\n \"title\": \"<string>\",\n \"context\": \"<string>\",\n \"taskContext\": \"Confirm whether the customer wants a renewal quote.\",\n \"scheduledFor\": 1712350000,\n \"externalTaskId\": \"<string>\",\n \"contactListName\": \"<string>\",\n \"goal\": {\n \"completionCriteria\": \"<string>\",\n \"description\": \"<string>\"\n },\n \"retryPolicy\": {\n \"retryOn\": [],\n \"delaysSeconds\": [\n 1296030\n ],\n \"steps\": [\n {\n \"offsetSeconds\": 3888030,\n \"target\": \"<string>\",\n \"responseTimeoutSeconds\": 302430,\n \"content\": {}\n }\n ],\n \"responseTimeoutSeconds\": 302430\n },\n \"meta\": {},\n \"greeting\": \"<string>\",\n \"waitToGreet\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.vida.dev/api/v2/tasks?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 \"type\": \"call\",\n \"target\": \"+15551234567\",\n \"accountId\": 1234,\n \"title\": \"<string>\",\n \"context\": \"<string>\",\n \"taskContext\": \"Confirm whether the customer wants a renewal quote.\",\n \"scheduledFor\": 1712350000,\n \"externalTaskId\": \"<string>\",\n \"contactListName\": \"<string>\",\n \"goal\": {\n \"completionCriteria\": \"<string>\",\n \"description\": \"<string>\"\n },\n \"retryPolicy\": {\n \"retryOn\": [],\n \"delaysSeconds\": [\n 1296030\n ],\n \"steps\": [\n {\n \"offsetSeconds\": 3888030,\n \"target\": \"<string>\",\n \"responseTimeoutSeconds\": 302430,\n \"content\": {}\n }\n ],\n \"responseTimeoutSeconds\": 302430\n },\n \"meta\": {},\n \"greeting\": \"<string>\",\n \"waitToGreet\": true\n}"
response = http.request(request)
puts response.read_bodyCreate a new task
Creates communication, scheduled, or Computer Agent work. Computer Tasks run only on provisioned Computer Agents and preserve their complete work in a linked conversation.
curl --request POST \
--url 'https://api.vida.dev/api/v2/tasks?token=' \
--header 'Content-Type: application/json' \
--data '
{
"type": "call",
"target": "+15551234567",
"accountId": 1234,
"title": "<string>",
"context": "<string>",
"taskContext": "Confirm whether the customer wants a renewal quote.",
"scheduledFor": 1712350000,
"externalTaskId": "<string>",
"contactListName": "<string>",
"goal": {
"completionCriteria": "<string>",
"description": "<string>"
},
"retryPolicy": {
"retryOn": [],
"delaysSeconds": [
1296030
],
"steps": [
{
"offsetSeconds": 3888030,
"target": "<string>",
"responseTimeoutSeconds": 302430,
"content": {}
}
],
"responseTimeoutSeconds": 302430
},
"meta": {},
"greeting": "<string>",
"waitToGreet": true
}
'import requests
url = "https://api.vida.dev/api/v2/tasks?token="
payload = {
"type": "call",
"target": "+15551234567",
"accountId": 1234,
"title": "<string>",
"context": "<string>",
"taskContext": "Confirm whether the customer wants a renewal quote.",
"scheduledFor": 1712350000,
"externalTaskId": "<string>",
"contactListName": "<string>",
"goal": {
"completionCriteria": "<string>",
"description": "<string>"
},
"retryPolicy": {
"retryOn": [],
"delaysSeconds": [1296030],
"steps": [
{
"offsetSeconds": 3888030,
"target": "<string>",
"responseTimeoutSeconds": 302430,
"content": {}
}
],
"responseTimeoutSeconds": 302430
},
"meta": {},
"greeting": "<string>",
"waitToGreet": True
}
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({
type: 'call',
target: '+15551234567',
accountId: 1234,
title: '<string>',
context: '<string>',
taskContext: 'Confirm whether the customer wants a renewal quote.',
scheduledFor: 1712350000,
externalTaskId: '<string>',
contactListName: '<string>',
goal: {completionCriteria: '<string>', description: '<string>'},
retryPolicy: {
retryOn: [],
delaysSeconds: [1296030],
steps: [
{
offsetSeconds: 3888030,
target: '<string>',
responseTimeoutSeconds: 302430,
content: {}
}
],
responseTimeoutSeconds: 302430
},
meta: {},
greeting: '<string>',
waitToGreet: true
})
};
fetch('https://api.vida.dev/api/v2/tasks?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/tasks?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([
'type' => 'call',
'target' => '+15551234567',
'accountId' => 1234,
'title' => '<string>',
'context' => '<string>',
'taskContext' => 'Confirm whether the customer wants a renewal quote.',
'scheduledFor' => 1712350000,
'externalTaskId' => '<string>',
'contactListName' => '<string>',
'goal' => [
'completionCriteria' => '<string>',
'description' => '<string>'
],
'retryPolicy' => [
'retryOn' => [
],
'delaysSeconds' => [
1296030
],
'steps' => [
[
'offsetSeconds' => 3888030,
'target' => '<string>',
'responseTimeoutSeconds' => 302430,
'content' => [
]
]
],
'responseTimeoutSeconds' => 302430
],
'meta' => [
],
'greeting' => '<string>',
'waitToGreet' => true
]),
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/tasks?token="
payload := strings.NewReader("{\n \"type\": \"call\",\n \"target\": \"+15551234567\",\n \"accountId\": 1234,\n \"title\": \"<string>\",\n \"context\": \"<string>\",\n \"taskContext\": \"Confirm whether the customer wants a renewal quote.\",\n \"scheduledFor\": 1712350000,\n \"externalTaskId\": \"<string>\",\n \"contactListName\": \"<string>\",\n \"goal\": {\n \"completionCriteria\": \"<string>\",\n \"description\": \"<string>\"\n },\n \"retryPolicy\": {\n \"retryOn\": [],\n \"delaysSeconds\": [\n 1296030\n ],\n \"steps\": [\n {\n \"offsetSeconds\": 3888030,\n \"target\": \"<string>\",\n \"responseTimeoutSeconds\": 302430,\n \"content\": {}\n }\n ],\n \"responseTimeoutSeconds\": 302430\n },\n \"meta\": {},\n \"greeting\": \"<string>\",\n \"waitToGreet\": true\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/tasks?token=")
.header("Content-Type", "application/json")
.body("{\n \"type\": \"call\",\n \"target\": \"+15551234567\",\n \"accountId\": 1234,\n \"title\": \"<string>\",\n \"context\": \"<string>\",\n \"taskContext\": \"Confirm whether the customer wants a renewal quote.\",\n \"scheduledFor\": 1712350000,\n \"externalTaskId\": \"<string>\",\n \"contactListName\": \"<string>\",\n \"goal\": {\n \"completionCriteria\": \"<string>\",\n \"description\": \"<string>\"\n },\n \"retryPolicy\": {\n \"retryOn\": [],\n \"delaysSeconds\": [\n 1296030\n ],\n \"steps\": [\n {\n \"offsetSeconds\": 3888030,\n \"target\": \"<string>\",\n \"responseTimeoutSeconds\": 302430,\n \"content\": {}\n }\n ],\n \"responseTimeoutSeconds\": 302430\n },\n \"meta\": {},\n \"greeting\": \"<string>\",\n \"waitToGreet\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.vida.dev/api/v2/tasks?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 \"type\": \"call\",\n \"target\": \"+15551234567\",\n \"accountId\": 1234,\n \"title\": \"<string>\",\n \"context\": \"<string>\",\n \"taskContext\": \"Confirm whether the customer wants a renewal quote.\",\n \"scheduledFor\": 1712350000,\n \"externalTaskId\": \"<string>\",\n \"contactListName\": \"<string>\",\n \"goal\": {\n \"completionCriteria\": \"<string>\",\n \"description\": \"<string>\"\n },\n \"retryPolicy\": {\n \"retryOn\": [],\n \"delaysSeconds\": [\n 1296030\n ],\n \"steps\": [\n {\n \"offsetSeconds\": 3888030,\n \"target\": \"<string>\",\n \"responseTimeoutSeconds\": 302430,\n \"content\": {}\n }\n ],\n \"responseTimeoutSeconds\": 302430\n },\n \"meta\": {},\n \"greeting\": \"<string>\",\n \"waitToGreet\": true\n}"
response = http.request(request)
puts response.read_bodyAuthorizations
Vida API Token
Body
- Option 1
- Option 2
- Option 3
- Option 4
- Option 5
- Option 6
- Option 7
call Phone number, email address, or supported Vida username for this Task type.
"+15551234567"
Agent account that performs the Task.
1234
Contact context supplied to the Agent.
Instructions for the Agent performing this Task.
"Confirm whether the customer wants a renewal quote."
Unix timestamp for the first attempt or Computer Agent run.
1712350000
Reusable caller-defined correlation ID; not an idempotency key.
Task-specific outcome definition. Omit or pass null to inherit the organization default.
Show child attributes
Show child attributes
Task-specific cadence. Omit or pass null to inherit the organization default. Use delaysSeconds or steps, never both.
Show child attributes
Show child attributes
Metadata retained for filtering and reporting; it is not added to the Agent prompt.
Call greeting. Prefix with prompt: to generate it from an instruction.
Response
Task created successfully