LM-Kit OneDocs2026.11.1lm-kit.comEULA

Custom Tools

The built-in catalog covers computation, the web and documents. The rest of the work lives behind your own APIs: the CRM that knows the customer, the helpdesk that files the ticket, the ERP that holds the order. A custom tool makes one HTTP operation of such an API a tool that chat, agents, workflows and MCP clients call, with no code and no restart.

1Declare a tool#

Open Admin > Build > Custom tools and choose New tool. A tool is one JSON object:

{
  "name": "find_customer",
  "description": "Finds a customer of the CRM by email address and returns their account.",
  "method": "GET",
  "url": "https://crm.example.com/api/customers",
  "headers": { "Authorization": "Bearer ..." },
  "input_schema": {
    "type": "object",
    "properties": { "email": { "type": "string", "description": "The customer's email address." } },
    "required": ["email"]
  },
  "parameter_locations": { "email": "query" },
  "response_path": "data.0"
}
Field What it does
name, description What the model reads to choose the tool: say what it does and when to use it
method GET, POST, PUT, PATCH, DELETE or HEAD
url The address called; {placeholders} are filled from the arguments of the same name, escaped
headers Sent on every call (an API key, a tenant id)
input_schema The JSON schema of the arguments; without one, every URL placeholder is a required string
parameter_locations Where each argument goes: path, query, header or body. Unnamed ones go to the query string for GET and HEAD, to the JSON body otherwise; a lone object argument named body is the body itself
response_path The part of the answer the model receives, dotted (data.items.0); a path the answer lacks keeps the whole answer
timeout_seconds, max_response_chars 30 seconds and 20,000 characters by default; a longer answer is cut and flagged
requires_approval false lets a tool that writes run without asking; true makes one that reads ask

Secret headers names the headers whose values are credentials (Authorization, X-Api-Key). Their values are sealed in the shared store, plain only in the memory of the nodes that call them, and shown as ******** wherever a tool is read; a save that leaves the mask in place keeps the stored value.

Test calls the operation once as written, saved or not, and shows the request as sent (secrets masked), the raw answer, and what the model receives.

2Import an OpenAPI document#

Import OpenAPI reads an OpenAPI 3.0 or 3.1 document (JSON or YAML) and lists its operations:

  • each operation becomes one tool named after its operationId in snake case (getCustomer becomes get_customer), described by its summary;
  • its path, query and header parameters and the properties of its JSON body become the arguments, each placed where the document puts it, shared schemas ($ref) inlined;
  • the tools call the document's first server, or the Server URL you give;
  • the Headers you type (one Name: value per line) are sent by every imported tool, and the ones you name as secret are sealed.

Operations that only read are chosen by default. An operation whose name a tool already has is skipped and named; rename it in the document to import it.

3The rules a custom tool runs under#

A custom tool is offered everywhere a built-in one is, under the same rules:

Rule Where it is set
Tools are offered at all Offer tools on the Tools page
The tool is offered Its switch on the Custom tools page
Which keys may call it Each API key's tool grants
Which addresses it may reach The egress policy of the Tools page: the public web, or the allowed hosts only; a private address only when listed as a private allowed host. Every call is checked first, connects only to the addresses the check validated, and never follows a redirect
Whether it asks first A tool that writes (anything but GET and HEAD) asks for approval unless its definition says otherwise; Ask first on the Tools page adds any other
MCP clients see it Turned on in Admin > Connect > MCP, under Custom tools; off until then

An agent or workflow names a custom tool like any other, in its tools list. A call that needs approval stops the run until someone decides it in Approvals, with the arguments it would send.

4From the API#

Everything the page does goes through the admin API:

Call Does
GET /lmkit/v1/admin/custom-tools Lists the tools
GET /lmkit/v1/admin/custom-tools/{name} Reads one, secrets masked
POST /lmkit/v1/admin/custom-tools Makes one: { definition, secretHeaders, enabled }
PUT /lmkit/v1/admin/custom-tools/{name} Changes one; a masked secret keeps its value
POST /lmkit/v1/admin/custom-tools/{name}/enabled?enabled=false Turns one off
DELETE /lmkit/v1/admin/custom-tools/{name} Deletes one
POST /lmkit/v1/admin/custom-tools/test Calls a definition once: { definition, secretHeaders, arguments }
POST /lmkit/v1/admin/custom-tools/openapi/preview Lists a document's operations: { document, baseUrl }
POST /lmkit/v1/admin/custom-tools/openapi/import Makes tools of the chosen ones: { document, baseUrl, operations, headers, secretHeaders }

The same definitions run in the SDK: HttpApiTool runs an HttpApiToolDefinition and OpenApiImporter reads a document, in the LMKit.Agents.Tools.Http namespace.

  • Tools and Function Calling: the built-in catalog and the policy over it.
  • Agent Workflows: steps that call tools, with approvals.
  • MCP Server: what MCP clients see.