Skip to Content
Tools

Get an HTTP tool

Permissiontools:readAuthentication
GET
/tools/{id}

Returns the complete normalized request template. Secret placeholders remain references; plaintext secret values are never materialized.

Authorization

bearerAuth
headerAuthorizationBearer <token>

Use a Voice API key or connected-app OAuth access token. Authentication.

Path Parameters

id*string
Formatuuid

Response Body

Complete HTTP tool.

application/json
  1. response
id*string
Formatuuid
slug*string
name*string
description*string|null
mode*ToolMode
Value in"sync""async"
phase*ToolPhase

When the tool runs. in_call (the default, and every tool authored before this field existed) is invoked by the model during the conversation. pre_call fires once, before the agent speaks, with no model involvement: its parameters must be static, system, or secret cards, its templates may reference only {{system.NAME}}, {{vars.NAME}}, and {{secrets.NAME}}, and its response_map names the values it publishes as {{tools.SLUG.NAME}}. pre_call additionally requires mode: sync, default_reaction: speaks, and precomputable: false, because all three describe behaviour during a conversation that has not started yet.

Value in"in_call""pre_call"
method*ToolMethod
Value in"GET""POST""PUT""PATCH""DELETE"
url*string
default_reaction*ToolReaction
Value in"speaks""listens"
precomputable*boolean
carry_across_calls*boolean
timeout_ms*integer
retries*integer
archived_at*|
Formatdate-time
created_at*string
Formatdate-time
updated_at*string
Formatdate-time
headers*

Header templates. Host, Content-Length, Transfer-Encoding, Connection, Proxy-Authorization, Proxy-Authenticate, Proxy-Connection, Keep-Alive, TE, Trailer, and Upgrade are transport-controlled and forbidden. Values cannot contain CR/LF.

Propertiesproperties <= 100
body*||

Templated string, templated JSON object, or null for no request body. Arrays and scalar JSON values other than strings are rejected.

parameters*array<||||>|
response_map*

Map of destination slot name to the supported tiny JSONPath syntax, such as $.customer.name or $.items.0.id.

Propertiesproperties <= 100
internal_slots*array<>

Subset of response_map slot names whose captured value is withheld from the model. The slot is still filled and still usable in templated tool fields such as a later request body or URL, but its value is never placed in the conversation the model sees, so a tool may return an account number or a policy document without that text entering the transcript or a prompt. Every entry must be a key of response_map; an unknown name is a 422. Stored canonically (sorted and deduplicated); omitted or null means an empty list.

Itemsitems <= 100
ack_response*|

Async-only agent-visible templated JSON object injected immediately while the real request continues; null disables it. It may use {{params.NAME}}, {{slots.NAME}}, {{system.NAME}}, and {{vars.NAME}}. It must never reference {{secrets.NAME}} at any nesting depth; public validation rejects the request rather than exposing a credential to the agent.

Example Request
curl -X GET 'https://api.kejue.co/v1/tools/497f6eca-6276-4993-bfeb-53cbbbba6f08'
Example Response
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "slug": "string",  "name": "string",  "description": "string",  "mode": "sync",  "phase": "in_call",  "method": "GET",  "url": "string",  "default_reaction": "speaks",  "precomputable": true,  "carry_across_calls": true,  "timeout_ms": 0,  "retries": 0,  "archived_at": "2019-08-24T14:15:22Z",  "created_at": "2019-08-24T14:15:22Z",  "updated_at": "2019-08-24T14:15:22Z",  "headers": {    "property1": "string",    "property2": "string"  },  "body": "string",  "parameters": [    {      "name": "string",      "kind": "dynamic",      "location": "path",      "type": "string",      "description": "string",      "required": false,      "enum_values": [        "string"      ],      "properties": [        {          "name": "string",          "type": "string",          "description": "string",          "required": false,          "enum_values": [            "string"          ]        }      ],      "items": {        "type": "string",        "enum_values": [          "string"        ],        "properties": [          {            "name": "string",            "type": "string",            "description": "string",            "required": false,            "enum_values": [              "string"            ]          }        ]      }    }  ],  "response_map": {    "property1": "string",    "property2": "string"  },  "internal_slots": [    "string"  ],  "ack_response": {}}