AI agents
Ship Builder agents inside your package — installed into the tenant's Agent Builder, governed by their keys, budgets and kill switches.
Declaring an agent script
"agentScripts": [{
"name": "Property valuation assistant",
"description": "Estimates listing value and drafts the summary",
"systemPrompt": "You are a real-estate valuation expert. Given a property record …",
"skills": ["create_task", "search_leads"]
}]
| field | notes |
|---|---|
systemPrompt | ≤ 20k chars; this IS your agent — write it like production code |
skills | names from the platform tool registry; the agent can ONLY call declared skills (scope violations are detected and flagged) |
Governance your agent runs under
- Tenant model keys — agents run on the tenant's own AI-provider key (Settings → AI Providers). No key, no run: the platform never silently bills its own.
- Token budgets — every agent has a monthly token budget; exceeding it returns
429 BUDGET_EXCEEDED. - Kill switch — tenants and operators can halt agent tool-calls platform-wide, per class, or per agent in under 5 seconds.
- Approvals — destructive tool calls can require human approval (two-person for critical classes).
Invoking agents from workflows
Pair an agent script with a run_agent workflow action to build closed loops: event → agent reasoning → CRM mutation. The action passes the event payload as context and DLQ-retries when the agent doesn't answer.
Write prompts that ground on the provided record context and refuse to fabricate. Review reads your
systemPrompt — hallucination-prone prompts are the most common agent-script rejection.