Replace PAL Skills
curl --request PUT \
--url https://tavusapi.com/v2/pals/{pal_id}/skills \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"skills": {
"internet_search": {},
"presentation": {
"config": {
"document_ids": [
"d1234567890"
],
"slides_trigger": "on_demand"
}
},
"magic_canvas": {
"config": {}
}
}
}
'import requests
url = "https://tavusapi.com/v2/pals/{pal_id}/skills"
payload = { "skills": {
"internet_search": {},
"presentation": { "config": {
"document_ids": ["d1234567890"],
"slides_trigger": "on_demand"
} },
"magic_canvas": { "config": {} }
} }
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
skills: {
internet_search: {},
presentation: {config: {document_ids: ['d1234567890'], slides_trigger: 'on_demand'}},
magic_canvas: {config: {}}
}
})
};
fetch('https://tavusapi.com/v2/pals/{pal_id}/skills', 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://tavusapi.com/v2/pals/{pal_id}/skills",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'skills' => [
'internet_search' => [
],
'presentation' => [
'config' => [
'document_ids' => [
'd1234567890'
],
'slides_trigger' => 'on_demand'
]
],
'magic_canvas' => [
'config' => [
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://tavusapi.com/v2/pals/{pal_id}/skills"
payload := strings.NewReader("{\n \"skills\": {\n \"internet_search\": {},\n \"presentation\": {\n \"config\": {\n \"document_ids\": [\n \"d1234567890\"\n ],\n \"slides_trigger\": \"on_demand\"\n }\n },\n \"magic_canvas\": {\n \"config\": {}\n }\n }\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("x-api-key", "<api-key>")
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.put("https://tavusapi.com/v2/pals/{pal_id}/skills")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"skills\": {\n \"internet_search\": {},\n \"presentation\": {\n \"config\": {\n \"document_ids\": [\n \"d1234567890\"\n ],\n \"slides_trigger\": \"on_demand\"\n }\n },\n \"magic_canvas\": {\n \"config\": {}\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://tavusapi.com/v2/pals/{pal_id}/skills")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"skills\": {\n \"internet_search\": {},\n \"presentation\": {\n \"config\": {\n \"document_ids\": [\n \"d1234567890\"\n ],\n \"slides_trigger\": \"on_demand\"\n }\n },\n \"magic_canvas\": {\n \"config\": {}\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {}
}{
"error": "Bad Request: {'skills': {'presentation': {'config': {'document_ids': ['Missing data for required field.']}}}}"
}{
"message": "Invalid access token"
}{
"error": "Unknown skill 'my_skill'"
}Skills
Replace PAL Skills
Replace a PAL’s entire skill set in one call. Skills not present in the request are detached.
PUT
/
v2
/
pals
/
{pal_id}
/
skills
Replace PAL Skills
curl --request PUT \
--url https://tavusapi.com/v2/pals/{pal_id}/skills \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"skills": {
"internet_search": {},
"presentation": {
"config": {
"document_ids": [
"d1234567890"
],
"slides_trigger": "on_demand"
}
},
"magic_canvas": {
"config": {}
}
}
}
'import requests
url = "https://tavusapi.com/v2/pals/{pal_id}/skills"
payload = { "skills": {
"internet_search": {},
"presentation": { "config": {
"document_ids": ["d1234567890"],
"slides_trigger": "on_demand"
} },
"magic_canvas": { "config": {} }
} }
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
skills: {
internet_search: {},
presentation: {config: {document_ids: ['d1234567890'], slides_trigger: 'on_demand'}},
magic_canvas: {config: {}}
}
})
};
fetch('https://tavusapi.com/v2/pals/{pal_id}/skills', 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://tavusapi.com/v2/pals/{pal_id}/skills",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'skills' => [
'internet_search' => [
],
'presentation' => [
'config' => [
'document_ids' => [
'd1234567890'
],
'slides_trigger' => 'on_demand'
]
],
'magic_canvas' => [
'config' => [
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://tavusapi.com/v2/pals/{pal_id}/skills"
payload := strings.NewReader("{\n \"skills\": {\n \"internet_search\": {},\n \"presentation\": {\n \"config\": {\n \"document_ids\": [\n \"d1234567890\"\n ],\n \"slides_trigger\": \"on_demand\"\n }\n },\n \"magic_canvas\": {\n \"config\": {}\n }\n }\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("x-api-key", "<api-key>")
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.put("https://tavusapi.com/v2/pals/{pal_id}/skills")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"skills\": {\n \"internet_search\": {},\n \"presentation\": {\n \"config\": {\n \"document_ids\": [\n \"d1234567890\"\n ],\n \"slides_trigger\": \"on_demand\"\n }\n },\n \"magic_canvas\": {\n \"config\": {}\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://tavusapi.com/v2/pals/{pal_id}/skills")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"skills\": {\n \"internet_search\": {},\n \"presentation\": {\n \"config\": {\n \"document_ids\": [\n \"d1234567890\"\n ],\n \"slides_trigger\": \"on_demand\"\n }\n },\n \"magic_canvas\": {\n \"config\": {}\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {}
}{
"error": "Bad Request: {'skills': {'presentation': {'config': {'document_ids': ['Missing data for required field.']}}}}"
}{
"message": "Invalid access token"
}{
"error": "Unknown skill 'my_skill'"
}For AI agents, use
https://docs.tavus.io/openapi.yaml for the full HTTP API contract.Authorizations
Path Parameters
The unique identifier of the PAL.
Example:
"pcb7a34da5fe"
Body
application/json
The complete skill set for the PAL, keyed by skill_id. Each value holds that skill's config object (omit or pass {} for skills with no configuration).
Show child attributes
Show child attributes
Example:
{
"internet_search": {},
"presentation": {
"config": {
"document_ids": ["d1234567890"],
"slides_trigger": "on_demand"
}
},
"magic_canvas": { "config": {} }
}
Response
Successfully replaced the PAL's skill attachments
The PAL's new skill attachments keyed by skill_id.
Show child attributes
Show child attributes
⌘I

