Skip to main content
Most AI workflows have a problem: every action runs through the model. Need to update a CRM record? The model decides if, when, and how. Need to send a Slack message? Same thing. This works when you need judgment, but it’s wasteful and unreliable when you already know exactly what to do. Deterministic tool calls let you call integration tools directly from your workflow code. No model reasoning, no token spend, no chance the LLM decides to skip the step or call the wrong tool. The backend still handles credentials and OAuth. You just skip the AI middleman.

When to use each approach

agent.tools.*

The generated SDK attaches typed wrappers under agent.tools.* for every integration declared in the agent’s skills. Use them when you want a deterministic call inside an agentic handler.
Every method on agent.tools.* is generated by terse generate based on your connected integrations. The wrappers are fully typed, so your editor autocompletes tool names, parameter shapes, and return types. Note: agent.tools.* is scoped to integrations declared in the agent’s skills. If you need unfiltered access from code, use toolbox instead.

toolbox.*

Code generation exports a toolbox object alongside agent.tools.*. It exposes the same typed integration methods, but you do not need a TerseAgent, and it is not filtered by skills. Use it when you only want deterministic tool calls.

Mixing deterministic and agentic calls

The real power is combining both in a single workflow. Use deterministic calls for predictable operations and hand off to the model when you need reasoning.
Steps 2 and 3 always execute the same way. Step 1 is where the model adds value: researching and reasoning about data that would be hard to codify as rules.

Available deterministic tools

Every integration you connect generates deterministic wrappers. Run terse generate to see what’s available in your project. Common examples:
Re-run terse generate when your connected integrations change. Do not hand-edit src/terse.generated.ts.

Where to go next

Context as Code

How terse generate creates typed helpers from your workspace.

TypeScript SDK reference

Full reference for toolbox.*, agent.tools.*, and more.