Agents
Create Agent
Create a new agent for your organization.
POST
/
agent
cURL
curl -s -X POST \
"https://api.tembo.io/agent" \
-H "Authorization: Bearer ${API_KEY}" \
-H "Content-Type: application/json" \
-d '{
"name": "Daily triage",
"jsonContent": {
"type": "doc",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "Review new issues and summarize priority, owner, and next steps."
}
]
}
]
},
"agent": "claudeCode:claude-opus-4-5",
"mcpServers": ["linear", "github"],
"schedules": [{ "cron": "0 9 * * 1-5" }]
}' | jq .import requests
url = "https://api.tembo.io/agent"
payload = {
"name": "Daily triage",
"jsonContent": {
"type": "doc",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "Review new issues and summarize priority, owner, and next steps."
}
]
}
]
},
"mcpServers": ["linear", "github"],
"agent": "claudeCode:claude-opus-4-5",
"triggers": [
{
"name": "linear.issue.created",
"integrationId": "<string>",
"filters": {}
}
],
"schedules": [{ "cron": "0 9 * * 1-5" }]
}
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({
name: 'Daily triage',
jsonContent: {
type: 'doc',
content: [
{
type: 'paragraph',
content: [
{
type: 'text',
text: 'Review new issues and summarize priority, owner, and next steps.'
}
]
}
]
},
mcpServers: ['linear', 'github'],
agent: 'claudeCode:claude-opus-4-5',
triggers: [{name: 'linear.issue.created', integrationId: '<string>', filters: {}}],
schedules: [{cron: '0 9 * * 1-5'}]
})
};
fetch('https://api.tembo.io/agent', 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.tembo.io/agent",
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([
'name' => 'Daily triage',
'jsonContent' => [
'type' => 'doc',
'content' => [
[
'type' => 'paragraph',
'content' => [
[
'type' => 'text',
'text' => 'Review new issues and summarize priority, owner, and next steps.'
]
]
]
]
],
'mcpServers' => [
'linear',
'github'
],
'agent' => 'claudeCode:claude-opus-4-5',
'triggers' => [
[
'name' => 'linear.issue.created',
'integrationId' => '<string>',
'filters' => [
]
]
],
'schedules' => [
[
'cron' => '0 9 * * 1-5'
]
]
]),
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.tembo.io/agent"
payload := strings.NewReader("{\n \"name\": \"Daily triage\",\n \"jsonContent\": {\n \"type\": \"doc\",\n \"content\": [\n {\n \"type\": \"paragraph\",\n \"content\": [\n {\n \"type\": \"text\",\n \"text\": \"Review new issues and summarize priority, owner, and next steps.\"\n }\n ]\n }\n ]\n },\n \"mcpServers\": [\n \"linear\",\n \"github\"\n ],\n \"agent\": \"claudeCode:claude-opus-4-5\",\n \"triggers\": [\n {\n \"name\": \"linear.issue.created\",\n \"integrationId\": \"<string>\",\n \"filters\": {}\n }\n ],\n \"schedules\": [\n {\n \"cron\": \"0 9 * * 1-5\"\n }\n ]\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.tembo.io/agent")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Daily triage\",\n \"jsonContent\": {\n \"type\": \"doc\",\n \"content\": [\n {\n \"type\": \"paragraph\",\n \"content\": [\n {\n \"type\": \"text\",\n \"text\": \"Review new issues and summarize priority, owner, and next steps.\"\n }\n ]\n }\n ]\n },\n \"mcpServers\": [\n \"linear\",\n \"github\"\n ],\n \"agent\": \"claudeCode:claude-opus-4-5\",\n \"triggers\": [\n {\n \"name\": \"linear.issue.created\",\n \"integrationId\": \"<string>\",\n \"filters\": {}\n }\n ],\n \"schedules\": [\n {\n \"cron\": \"0 9 * * 1-5\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tembo.io/agent")
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 \"name\": \"Daily triage\",\n \"jsonContent\": {\n \"type\": \"doc\",\n \"content\": [\n {\n \"type\": \"paragraph\",\n \"content\": [\n {\n \"type\": \"text\",\n \"text\": \"Review new issues and summarize priority, owner, and next steps.\"\n }\n ]\n }\n ]\n },\n \"mcpServers\": [\n \"linear\",\n \"github\"\n ],\n \"agent\": \"claudeCode:claude-opus-4-5\",\n \"triggers\": [\n {\n \"name\": \"linear.issue.created\",\n \"integrationId\": \"<string>\",\n \"filters\": {}\n }\n ],\n \"schedules\": [\n {\n \"cron\": \"0 9 * * 1-5\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "Daily triage",
"organizationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"key": "daily-triage",
"jsonContent": {},
"agent": "claudeCode:claude-opus-4-5",
"mcpServers": [
"<string>"
],
"enabledAt": "2023-11-07T05:31:56Z"
}{
"error": "<string>"
}Body
application/json
Agent creation payload
Agent name
Example:
"Daily triage"
Agent instructions as a structured document
Example:
{
"type": "doc",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "Review new issues and summarize priority, owner, and next steps."
}
]
}
]
}MCP servers available to the agent
Example:
["linear", "github"]Agent harness or model to use
Example:
"claudeCode:claude-opus-4-5"
Event triggers to attach to the agent
Show child attributes
Show child attributes
Schedules to attach to the agent
Show child attributes
Show child attributes
Response
Agent created successfully
Unique identifier for the agent
Agent name
Example:
"Daily triage"
Macro key generated for the agent
Example:
"daily-triage"
Agent instructions as a structured document
Agent harness or model to use
Example:
"claudeCode:claude-opus-4-5"
MCP servers available to the agent
Was this page helpful?
⌘I
cURL
curl -s -X POST \
"https://api.tembo.io/agent" \
-H "Authorization: Bearer ${API_KEY}" \
-H "Content-Type: application/json" \
-d '{
"name": "Daily triage",
"jsonContent": {
"type": "doc",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "Review new issues and summarize priority, owner, and next steps."
}
]
}
]
},
"agent": "claudeCode:claude-opus-4-5",
"mcpServers": ["linear", "github"],
"schedules": [{ "cron": "0 9 * * 1-5" }]
}' | jq .import requests
url = "https://api.tembo.io/agent"
payload = {
"name": "Daily triage",
"jsonContent": {
"type": "doc",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "Review new issues and summarize priority, owner, and next steps."
}
]
}
]
},
"mcpServers": ["linear", "github"],
"agent": "claudeCode:claude-opus-4-5",
"triggers": [
{
"name": "linear.issue.created",
"integrationId": "<string>",
"filters": {}
}
],
"schedules": [{ "cron": "0 9 * * 1-5" }]
}
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({
name: 'Daily triage',
jsonContent: {
type: 'doc',
content: [
{
type: 'paragraph',
content: [
{
type: 'text',
text: 'Review new issues and summarize priority, owner, and next steps.'
}
]
}
]
},
mcpServers: ['linear', 'github'],
agent: 'claudeCode:claude-opus-4-5',
triggers: [{name: 'linear.issue.created', integrationId: '<string>', filters: {}}],
schedules: [{cron: '0 9 * * 1-5'}]
})
};
fetch('https://api.tembo.io/agent', 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.tembo.io/agent",
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([
'name' => 'Daily triage',
'jsonContent' => [
'type' => 'doc',
'content' => [
[
'type' => 'paragraph',
'content' => [
[
'type' => 'text',
'text' => 'Review new issues and summarize priority, owner, and next steps.'
]
]
]
]
],
'mcpServers' => [
'linear',
'github'
],
'agent' => 'claudeCode:claude-opus-4-5',
'triggers' => [
[
'name' => 'linear.issue.created',
'integrationId' => '<string>',
'filters' => [
]
]
],
'schedules' => [
[
'cron' => '0 9 * * 1-5'
]
]
]),
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.tembo.io/agent"
payload := strings.NewReader("{\n \"name\": \"Daily triage\",\n \"jsonContent\": {\n \"type\": \"doc\",\n \"content\": [\n {\n \"type\": \"paragraph\",\n \"content\": [\n {\n \"type\": \"text\",\n \"text\": \"Review new issues and summarize priority, owner, and next steps.\"\n }\n ]\n }\n ]\n },\n \"mcpServers\": [\n \"linear\",\n \"github\"\n ],\n \"agent\": \"claudeCode:claude-opus-4-5\",\n \"triggers\": [\n {\n \"name\": \"linear.issue.created\",\n \"integrationId\": \"<string>\",\n \"filters\": {}\n }\n ],\n \"schedules\": [\n {\n \"cron\": \"0 9 * * 1-5\"\n }\n ]\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.tembo.io/agent")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Daily triage\",\n \"jsonContent\": {\n \"type\": \"doc\",\n \"content\": [\n {\n \"type\": \"paragraph\",\n \"content\": [\n {\n \"type\": \"text\",\n \"text\": \"Review new issues and summarize priority, owner, and next steps.\"\n }\n ]\n }\n ]\n },\n \"mcpServers\": [\n \"linear\",\n \"github\"\n ],\n \"agent\": \"claudeCode:claude-opus-4-5\",\n \"triggers\": [\n {\n \"name\": \"linear.issue.created\",\n \"integrationId\": \"<string>\",\n \"filters\": {}\n }\n ],\n \"schedules\": [\n {\n \"cron\": \"0 9 * * 1-5\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tembo.io/agent")
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 \"name\": \"Daily triage\",\n \"jsonContent\": {\n \"type\": \"doc\",\n \"content\": [\n {\n \"type\": \"paragraph\",\n \"content\": [\n {\n \"type\": \"text\",\n \"text\": \"Review new issues and summarize priority, owner, and next steps.\"\n }\n ]\n }\n ]\n },\n \"mcpServers\": [\n \"linear\",\n \"github\"\n ],\n \"agent\": \"claudeCode:claude-opus-4-5\",\n \"triggers\": [\n {\n \"name\": \"linear.issue.created\",\n \"integrationId\": \"<string>\",\n \"filters\": {}\n }\n ],\n \"schedules\": [\n {\n \"cron\": \"0 9 * * 1-5\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "Daily triage",
"organizationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"key": "daily-triage",
"jsonContent": {},
"agent": "claudeCode:claude-opus-4-5",
"mcpServers": [
"<string>"
],
"enabledAt": "2023-11-07T05:31:56Z"
}{
"error": "<string>"
}