Register an endpoint as an agent tool
POST
https://server.heyrik.com/api/v1/custom-apisHeaders
AuthorizationstringRequiredUse Bearer $HEYRIK_API_KEY with an account-scoped API key. Keep the key on your server.
Parameters 6
Fields documented for this operation. See the request example for placement and structure.
namestringRequiredTool name the agent calls, e.g. check_order_status.
urlstringRequiredYour https endpoint.
methodstringGET | POST | PUT | PATCH | DELETE. Default POST.
headersobjectSent on every call — put your own auth header here.
descriptionstringTells the agent WHEN to use it. Be specific.
parametersobjectJSON-Schema of the arguments the agent should supply.
Response
Explore the example values. This is not a complete response schema.
dataobjectExplore 4 properties
idstringExample "capi_3f81"
namestringExample "check_order_status"
urlstringExample "https://api.acme.com/orders/status"
methodstringExample "POST"
POST/custom-apis
cURL
curl -X POST https://server.heyrik.com/api/v1/custom-apis \
-H "Authorization: Bearer $HEYRIK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "check_order_status",
"url": "https://api.acme.com/orders/status",
"method": "POST",
"headers": { "X-Api-Key": "your-own-key" },
"description": "Look up the delivery status of an order by its id.",
"parameters": {
"type": "object",
"properties": { "order_id": { "type": "string", "description": "The order id" } },
"required": ["order_id"]
}
}'Response example
JSON
{
"data": {
"id": "capi_3f81",
"name": "check_order_status",
"url": "https://api.acme.com/orders/status",
"method": "POST"
}
}Illustrative examples · No live request is sent
