TotalApp Docs

Tool / Function Registry

Define JSON Schema tools — database queries, API calls, file I/O — and wire them into any agent in seconds.

Overview

The Tool Registry is the catalogue of callable functions that AI agents can invoke during a workflow run. It is the TotalApp implementation of the function-calling feature available in modern LLMs (Anthropic tool use, OpenAI function calling).

You define a tool once in the Registry — its name, description, and JSON Schema parameter spec. Attach the tool to any agent in Agent Architect. When the agent decides it needs to call that tool, TotalApp executes the tool's underlying implementation and returns the result to the agent.

Tool Definition

Each tool in the Registry consists of:

  • Name — a snake_case identifier the model uses to call the tool (e.g. search_database, send_email).
  • Description — a plain-language explanation of what the tool does and when to use it. The LLM reads this to decide whether to call the tool.
  • Parameters — a JSON Schema object describing the tool's input parameters. The model generates a JSON object matching this schema when calling the tool.
  • Implementation — the server-side handler that executes when the tool is called. Implementation options include: HTTP request to an external endpoint, SQL query against a connected database, JavaScript function in the TotalApp sandbox, or a call to another TotalApp workflow.

Parameter Schema Best Practices

Use required to mark parameters the model must always supply. Add a description to every parameter property — the LLM uses descriptions to understand what value to fill in. Avoid overly-generic parameter names like input or value; use specific names like customer_id or date_range.

Attaching Tools to Agents

Open Agent Architect, find the Tools section, and select tools from the Registry dropdown. The selected tools' names and descriptions are automatically included in the system prompt sent to the model. No manual prompt engineering is required — TotalApp handles the tool-call schema injection.

Keep Tool Lists Small

Attaching too many tools to one agent increases the chance of the model choosing the wrong tool or making unnecessary tool calls. As a rule of thumb, keep each agent's tool list under 10 tools. Create multiple focused agents rather than one agent with many tools.

Observing Tool Calls

Every tool call an agent makes during a workflow run is recorded in the Observability log. You can see the exact arguments the model passed and the value the tool returned. This is essential for debugging agent behaviour when the model is choosing to call a tool with unexpected arguments.