curl --request PATCH \
--url https://api.{environment}.corti.app/agents/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Tenant-Name: <tenant-name>' \
--data '
{
"name": "<string>",
"systemPrompt": "<string>",
"description": "<string>",
"experts": [
{
"type": "new",
"name": "<string>",
"description": "<string>",
"systemPrompt": "<string>",
"mcpServers": [
{
"name": "<string>",
"url": "<string>",
"description": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>",
"token": "<string>"
}
]
}
],
"mcpServers": [
{
"name": "<string>",
"url": "<string>",
"description": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>",
"token": "<string>"
}
]
}
'import { CortiClient, CortiEnvironment } from "@corti/sdk";
const client = new CortiClient({
environment: CortiEnvironment.Eu,
auth: {
clientId: "YOUR_CLIENT_ID",
clientSecret: "YOUR_CLIENT_SECRET"
},
tenantName: "YOUR_TENANT_NAME"
});
await client.agents.update("12345678-90ab-cdef-gh12-34567890abc");using Corti;
var client = new CortiClient(
"TENANT_NAME",
CortiClientEnvironment.Eu,
new CortiClientAuth.ClientCredentials("client_id", "client_secret")
);
await client.Agents.UpdateAsync("12345678-90ab-cdef-gh12-34567890abc", new AgentsUpdateAgent());import requests
url = "https://api.{environment}.corti.app/agents/{id}"
payload = {
"name": "<string>",
"systemPrompt": "<string>",
"description": "<string>",
"experts": [
{
"type": "new",
"name": "<string>",
"description": "<string>",
"systemPrompt": "<string>",
"mcpServers": [
{
"name": "<string>",
"url": "<string>",
"description": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>",
"token": "<string>"
}
]
}
],
"mcpServers": [
{
"name": "<string>",
"url": "<string>",
"description": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>",
"token": "<string>"
}
]
}
headers = {
"Tenant-Name": "<tenant-name>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.{environment}.corti.app/agents/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'systemPrompt' => '<string>',
'description' => '<string>',
'experts' => [
[
'type' => 'new',
'name' => '<string>',
'description' => '<string>',
'systemPrompt' => '<string>',
'mcpServers' => [
[
'name' => '<string>',
'url' => '<string>',
'description' => '<string>',
'authorizationScope' => '<string>',
'redirectUrl' => '<string>',
'token' => '<string>'
]
]
]
],
'mcpServers' => [
[
'name' => '<string>',
'url' => '<string>',
'description' => '<string>',
'authorizationScope' => '<string>',
'redirectUrl' => '<string>',
'token' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Tenant-Name: <tenant-name>"
],
]);
$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.{environment}.corti.app/agents/{id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"systemPrompt\": \"<string>\",\n \"description\": \"<string>\",\n \"experts\": [\n {\n \"type\": \"new\",\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"systemPrompt\": \"<string>\",\n \"mcpServers\": [\n {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"description\": \"<string>\",\n \"authorizationScope\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"token\": \"<string>\"\n }\n ]\n }\n ],\n \"mcpServers\": [\n {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"description\": \"<string>\",\n \"authorizationScope\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"token\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Tenant-Name", "<tenant-name>")
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.patch("https://api.{environment}.corti.app/agents/{id}")
.header("Tenant-Name", "<tenant-name>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"systemPrompt\": \"<string>\",\n \"description\": \"<string>\",\n \"experts\": [\n {\n \"type\": \"new\",\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"systemPrompt\": \"<string>\",\n \"mcpServers\": [\n {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"description\": \"<string>\",\n \"authorizationScope\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"token\": \"<string>\"\n }\n ]\n }\n ],\n \"mcpServers\": [\n {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"description\": \"<string>\",\n \"authorizationScope\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"token\": \"<string>\"\n }\n ]\n}")
.asString();{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"systemPrompt": "<string>",
"experts": [
{
"type": "expert",
"id": "<string>",
"name": "<string>",
"description": "<string>",
"systemPrompt": "<string>",
"mcpServers": [
{
"id": "<string>",
"name": "<string>",
"url": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>"
}
]
}
],
"mcpServers": [
{
"id": "<string>",
"name": "<string>",
"url": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>"
}
]
}{
"code": "<string>",
"description": "<string>",
"howToFix": "<string>",
"details": {},
"cause": {}
}{
"code": "<string>",
"description": "<string>",
"howToFix": "<string>",
"details": {},
"cause": {}
}{
"code": "<string>",
"description": "<string>",
"howToFix": "<string>",
"details": {},
"cause": {}
}{
"code": "<string>",
"description": "<string>",
"howToFix": "<string>",
"details": {},
"cause": {},
"detail": [
{
"msg": "<string>",
"type": "<string>",
"reason": "<string>",
"howToFix": "<string>",
"errors": [
{
"location": "<string>",
"reason": "<string>"
}
]
}
]
}Update Agent by ID
This endpoint updates an existing agent. Only the fields provided in the request body will be updated; other fields will remain unchanged.
curl --request PATCH \
--url https://api.{environment}.corti.app/agents/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Tenant-Name: <tenant-name>' \
--data '
{
"name": "<string>",
"systemPrompt": "<string>",
"description": "<string>",
"experts": [
{
"type": "new",
"name": "<string>",
"description": "<string>",
"systemPrompt": "<string>",
"mcpServers": [
{
"name": "<string>",
"url": "<string>",
"description": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>",
"token": "<string>"
}
]
}
],
"mcpServers": [
{
"name": "<string>",
"url": "<string>",
"description": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>",
"token": "<string>"
}
]
}
'import { CortiClient, CortiEnvironment } from "@corti/sdk";
const client = new CortiClient({
environment: CortiEnvironment.Eu,
auth: {
clientId: "YOUR_CLIENT_ID",
clientSecret: "YOUR_CLIENT_SECRET"
},
tenantName: "YOUR_TENANT_NAME"
});
await client.agents.update("12345678-90ab-cdef-gh12-34567890abc");using Corti;
var client = new CortiClient(
"TENANT_NAME",
CortiClientEnvironment.Eu,
new CortiClientAuth.ClientCredentials("client_id", "client_secret")
);
await client.Agents.UpdateAsync("12345678-90ab-cdef-gh12-34567890abc", new AgentsUpdateAgent());import requests
url = "https://api.{environment}.corti.app/agents/{id}"
payload = {
"name": "<string>",
"systemPrompt": "<string>",
"description": "<string>",
"experts": [
{
"type": "new",
"name": "<string>",
"description": "<string>",
"systemPrompt": "<string>",
"mcpServers": [
{
"name": "<string>",
"url": "<string>",
"description": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>",
"token": "<string>"
}
]
}
],
"mcpServers": [
{
"name": "<string>",
"url": "<string>",
"description": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>",
"token": "<string>"
}
]
}
headers = {
"Tenant-Name": "<tenant-name>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.{environment}.corti.app/agents/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'systemPrompt' => '<string>',
'description' => '<string>',
'experts' => [
[
'type' => 'new',
'name' => '<string>',
'description' => '<string>',
'systemPrompt' => '<string>',
'mcpServers' => [
[
'name' => '<string>',
'url' => '<string>',
'description' => '<string>',
'authorizationScope' => '<string>',
'redirectUrl' => '<string>',
'token' => '<string>'
]
]
]
],
'mcpServers' => [
[
'name' => '<string>',
'url' => '<string>',
'description' => '<string>',
'authorizationScope' => '<string>',
'redirectUrl' => '<string>',
'token' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Tenant-Name: <tenant-name>"
],
]);
$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.{environment}.corti.app/agents/{id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"systemPrompt\": \"<string>\",\n \"description\": \"<string>\",\n \"experts\": [\n {\n \"type\": \"new\",\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"systemPrompt\": \"<string>\",\n \"mcpServers\": [\n {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"description\": \"<string>\",\n \"authorizationScope\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"token\": \"<string>\"\n }\n ]\n }\n ],\n \"mcpServers\": [\n {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"description\": \"<string>\",\n \"authorizationScope\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"token\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Tenant-Name", "<tenant-name>")
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.patch("https://api.{environment}.corti.app/agents/{id}")
.header("Tenant-Name", "<tenant-name>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"systemPrompt\": \"<string>\",\n \"description\": \"<string>\",\n \"experts\": [\n {\n \"type\": \"new\",\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"systemPrompt\": \"<string>\",\n \"mcpServers\": [\n {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"description\": \"<string>\",\n \"authorizationScope\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"token\": \"<string>\"\n }\n ]\n }\n ],\n \"mcpServers\": [\n {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"description\": \"<string>\",\n \"authorizationScope\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"token\": \"<string>\"\n }\n ]\n}")
.asString();{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"systemPrompt": "<string>",
"experts": [
{
"type": "expert",
"id": "<string>",
"name": "<string>",
"description": "<string>",
"systemPrompt": "<string>",
"mcpServers": [
{
"id": "<string>",
"name": "<string>",
"url": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>"
}
]
}
],
"mcpServers": [
{
"id": "<string>",
"name": "<string>",
"url": "<string>",
"authorizationScope": "<string>",
"redirectUrl": "<string>"
}
]
}{
"code": "<string>",
"description": "<string>",
"howToFix": "<string>",
"details": {},
"cause": {}
}{
"code": "<string>",
"description": "<string>",
"howToFix": "<string>",
"details": {},
"cause": {}
}{
"code": "<string>",
"description": "<string>",
"howToFix": "<string>",
"details": {},
"cause": {}
}{
"code": "<string>",
"description": "<string>",
"howToFix": "<string>",
"details": {},
"cause": {},
"detail": [
{
"msg": "<string>",
"type": "<string>",
"reason": "<string>",
"howToFix": "<string>",
"errors": [
{
"location": "<string>",
"reason": "<string>"
}
]
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
Identifies a distinct entity within Corti's multi-tenant system. Ensures correct routing and authentication of the request.
"base"
Path Parameters
The identifier of the agent associated with the context.
"12345678-90ab-cdef-gh12-34567890abc"
Body
The name of the agent.
The system prompt that defines the overall agents behavior and expectations. This field is optional as there is a default system orchestrator.
A brief description of the agent's capabilities.
- Option 1
- Option 2
Show child attributes
Show child attributes
A list of MCP servers that the agent can call. If omitted, the agent can't call any MCP servers.
Show child attributes
Show child attributes
Response
Agent updated successfully.
The unique identifier of the agent.
The name of the agent.
A brief description of the agent's capabilities.
The system prompt that defines the overall agents behavior and expectations.
- Option 1
- Option 2
Show child attributes
Show child attributes
A list of MCP servers that the agent can call. If omitted, the agent can't call any MCP servers.
Show child attributes
Show child attributes
Was this page helpful?