Register a new agent
Register a new agent — status starts as draft.
curl -X POST "https://api.autopil.ai/v1/agents" \
-H "Content-Type: application/json" \
-H "X-API-Key: YOUR_API_KEY" \
-d '{
"agent_role": "transaction_analyst",
"display_name": "Fraud Transaction Analyst v2",
"description": "Analyzes transaction patterns for fraud signals",
"owner": "fraud-eng-team",
"framework": "langgraph"
}'
import requests
import json
url = "https://api.autopil.ai/v1/agents"
headers = {
"Content-Type": "application/json",
"X-API-Key": "YOUR_API_KEY"
}
data = {
"agent_role": "transaction_analyst",
"display_name": "Fraud Transaction Analyst v2",
"description": "Analyzes transaction patterns for fraud signals",
"owner": "fraud-eng-team",
"framework": "langgraph"
}
response = requests.post(url, headers=headers, json=data)
print(response.json())
const response = await fetch("https://api.autopil.ai/v1/agents", {
method: "POST",
headers: {
"Content-Type": "application/json",
"X-API-Key": "YOUR_API_KEY"
},
body: JSON.stringify({
"agent_role": "transaction_analyst",
"display_name": "Fraud Transaction Analyst v2",
"description": "Analyzes transaction patterns for fraud signals",
"owner": "fraud-eng-team",
"framework": "langgraph"
})
});
const data = await response.json();
console.log(data);
package main
import (
"fmt"
"net/http"
"bytes"
"encoding/json"
)
func main() {
data := []byte(`{
"agent_role": "transaction_analyst",
"display_name": "Fraud Transaction Analyst v2",
"description": "Analyzes transaction patterns for fraud signals",
"owner": "fraud-eng-team",
"framework": "langgraph"
}`)
req, err := http.NewRequest("POST", "https://api.autopil.ai/v1/agents", bytes.NewBuffer(data))
if err != nil {
panic(err)
}
req.Header.Set("Content-Type", "application/json")
req.Header.Set("X-API-Key", "YOUR_API_KEY")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
fmt.Println("Response Status:", resp.Status)
}
require 'net/http'
require 'json'
uri = URI('https://api.autopil.ai/v1/agents')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri)
request['Content-Type'] = 'application/json'
request['X-API-Key'] = 'YOUR_API_KEY'
request.body = '{
"agent_role": "transaction_analyst",
"display_name": "Fraud Transaction Analyst v2",
"description": "Analyzes transaction patterns for fraud signals",
"owner": "fraud-eng-team",
"framework": "langgraph"
}'
response = http.request(request)
puts response.body
{
"agent_id": "agt_abc123",
"status": "draft"
}
/v1/agents
Target server for requests. Edit to use your own host.
API key with admin, read, or evaluate scope. Missing key → 401; invalid or revoked key → 403.
admin, read, or evaluate scope. Missing key → 401; invalid or revoked key → 403.
The media type of the request body
The role this agent will claim in evaluate calls. Must match a policy.
Human-readable name shown in the dashboard.
Purpose and data access rationale. Used during approval review.
Team or individual responsible for this agent.
Runtime framework: langgraph, openai_agents, bedrock, etc.
Roles this agent is allowed to claim. Defaults to [agent_role].
Authentication method. Defaults to api_key.
If set, only the key with this ID may present this agent's identity.
Request Preview
Response
Response will appear here after sending the request
Authentication
API Key for authentication. API key with admin, read, or evaluate scope. Missing key → 401; invalid or revoked key → 403.
Body
The role this agent will claim in evaluate calls. Must match a policy.
Human-readable name shown in the dashboard.
Purpose and data access rationale. Used during approval review.
Team or individual responsible for this agent.
Runtime framework: langgraph, openai_agents, bedrock, etc.
Roles this agent is allowed to claim. Defaults to [agent_role].
Authentication method. Defaults to api_key.
api_keyjwt_oidcmtlsconjurIf set, only the key with this ID may present this agent's identity.
draftpending_approvalapproveddeprecated