Create Agent
curl --request POST \
--url https://api.example.com/v1/agentsimport requests
url = "https://api.example.com/v1/agents"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://api.example.com/v1/agents', 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.example.com/v1/agents",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/agents"
req, _ := http.NewRequest("POST", url, nil)
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.example.com/v1/agents")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/agents")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_bodyOrganizations
Create Agent
POST /v1/agents — create an agent wallet and initial mandate
POST
/
v1
/
agents
Create Agent
curl --request POST \
--url https://api.example.com/v1/agentsimport requests
url = "https://api.example.com/v1/agents"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://api.example.com/v1/agents', 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.example.com/v1/agents",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/agents"
req, _ := http.NewRequest("POST", url, nil)
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.example.com/v1/agents")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/agents")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_bodyCreates an agent wallet and its initial mandate row.
This route is operator-surface only. Wallet-scoped runtime keys are rejected before body validation.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
organization_id | string | yes | Target organization |
name | string | yes | Human-readable wallet name |
daily_limit_usdc | number | no | Initial spend cap. Defaults to 0 when omitted. |
per_tx_limit_usdc | number | no | Initial per-transaction cap. Defaults to 0 when omitted. |
monthly_limit_usdc | number | no | Optional monthly cap |
allow_list | string[] | no | Allowed spend hosts |
block_list | string[] | no | Blocked spend hosts |
networks | string[] | no | Defaults to ["eip155:8453"] |
enforcement | string | no | Defaults to hard_stop |
purpose | string | no | Free-text purpose |
allowed_categories | string[] | no | Allowed spend categories |
agent_address | string | no | Browser-signing override. Must be provided together with agent_derived_path. |
agent_derived_path | string | no | Browser-signing override. Must match m/44'/60'/0'/0/N with N >= 1. |
curl -X POST http://127.0.0.1:3030/v1/agents \
-H "Authorization: Bearer $AXON_DECISION_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"organization_id": "<ORG_UUID>",
"name": "Research Agent 01",
"daily_limit_usdc": 25,
"per_tx_limit_usdc": 2,
"allow_list": ["pro-api.coingecko.com"],
"networks": ["eip155:8453"],
"purpose": "Market data research"
}'
Response
{
"wallet_id": "uuid",
"address": "0xabc123...",
"derived_path": "m/44'/60'/0'/0/7",
"mandate_id": "uuid",
"name": "Research Agent 01"
}
Error codes
| Code | Meaning |
|---|---|
VALIDATION_ERROR | Missing required fields or invalid browser-signing override |
REJECTED_POLICY | Caller cannot create agents for this organization |