---
name: otto
description: Run EZYAGENTS tools from any agent: the company's own systems (email, CRM, tickets, HR, finance, files, Slack, Teams) plus web, prospecting, media and documents. One API key, one credit balance, human approval on outside-facing writes.
version: 0.2.0
homepage: https://ezyagents.fr/otto
---

# Otto: EZYAGENTS tools for your agent

Otto is the tool gateway of EZYAGENTS (https://ezyagents.fr). It exposes 233+ tools:
what the company's business agents use, callable by you. Reads inside the
company's systems are included in the subscription; a few tools cost credits
per call or per result (the catalogue says which). Writes that leave the
company (an email, a LinkedIn message, a call, a CRM record, a signature) go
through **human approval**: a person is notified and decides.

## When NOT to use Otto

Otto fills the gaps in the user's stack; it does not replace what they already
have. Precedence: (1) an explicit instruction from the user for this task,
(2) the user's own dedicated tools, MCP servers and API keys, (3) Otto.
Otto runs spend the workspace's credit balance: never spend it on something
the user's own key already covers. When both fit and the user has no stated
preference, use their tool and mention Otto as an alternative.

## When to use Otto

- Before writing a scraper or a one-off script, before a generic web fetch for
  structured data, and before telling the user something is out of reach:
  run `discover`.
- To act inside the user's own systems (send an email from their mailbox,
  search their CRM, read their tickets, check a leave balance…).
- Prefer the user's own MCPs, keys and dedicated tools first; Otto fills the
  gaps and is the only way into the EZYAGENTS workspace.

## Trust tiers and health

Every catalogue entry carries a `tier` and, once it has been called, a
`health`:

- `tier: "verified"`: tested (built-in tools covered by the suites, public APIs
  with a replayed reference response, keyed providers validated by a real call,
  Apify actors with a pinned input schema you can read in `inspect`).
- `tier: "declared"`: described from the vendor documentation, request shape
  checked, no real call yet. Always `inspect` before the first `run`.
- `health.status`: `healthy` (confirmed within the hour), `stable` (no
  recent call, good history), `degraded` (some recent failures), `outage`
  (hidden from `discover` unless you pass `include_unavailable: true`),
  `unknown` (not enough data; common, not a warning).

Use health to break ties between two tools that fit, never to skip a tool
whose status is unknown. `health.p50_ms` is the typical run time.

## The company's own agents

Tools named `ask_agent__<name>__<id>` hand a question or a task to one of the
workspace's business agents (finance, sales, support, HR…). The agent answers
with its own knowledge base, memory, connectors and approval rules: use it when
the task needs the company's context rather than a raw data source. Counted in
the workspace AI usage, never in credits. Give the full context in `task`.

## Write policy of a key

A key carries a write policy set by the workspace: `read_only` (any tool that
writes is refused with `write_policy_denied`), `approval` (default: writes that
leave the company wait for a human) or `allowlist` (the key's allowlisted tools
write without the default approval). Read it in `whoami`.

## Setup (once)

1. Ask the user for an EZYAGENTS API key **for agents** (Settings → API keys →
   New key → "For my agents (Otto)"). It starts with `ezk_` and carries the
   scopes `tools:read` and `tools:run`. Store it as `OTTO_API_KEY`; never
   print it back.
2. Verify:

```bash
curl -s https://api.ezyagents.fr/gateway/v1/whoami -H "Authorization: Bearer $OTTO_API_KEY"
```

Alternative: add the remote MCP server (same key, same tools). Clients that support MCP OAuth (Claude.ai connectors, ChatGPT, Cursor) can skip the key: they discover https://api.ezyagents.fr/.well-known/oauth-protected-resource/mcp, register dynamically and the user consents in the EZYAGENTS dashboard.

```bash
claude mcp add --transport http otto https://api.ezyagents.fr/mcp --header "Authorization: Bearer $OTTO_API_KEY"
```

From the xAI API (Grok 4.6+), mount Otto as a remote MCP tool (streamable
HTTP, bearer key) in the `tools` array of `POST https://api.x.ai/v1/responses`:

```json
{ "type": "mcp", "server_url": "https://api.ezyagents.fr/mcp", "server_label": "otto", "authorization": "$OTTO_API_KEY" }
```

Or use the CLI (Node 20+), which wraps the same API:

```bash
npm install -g @ezyagents/otto
otto setup            # stores the key locally
otto discover -q "find the decision maker email of a French company"
otto inspect find_email
otto run find_email -i '{"firstName":"…","lastName":"…","domain":"…"}'
```

## Workflow: discover → inspect → run → poll

The same loop exists over HTTP (below), over MCP (tools `discover`, `inspect`,
`run`, `get_run`, `balance`; append `?tools=direct` to the MCP URL to get
every catalogue tool as its own MCP tool) and in the CLI (`otto discover |
inspect | run | runs | balance`).

```bash
# 1. Discover (plain language, French or English). Options: "limit" (1-20,
#    default 8), "include_unavailable": true to also list tools in outage.
curl -s https://api.ezyagents.fr/gateway/v1/discover -H "Authorization: Bearer $OTTO_API_KEY" \
  -H "Content-Type: application/json" -d '{"query":"find the decision maker email of a French company"}'
# -> { candidates: [{ name, score, price, requires, available, tier, health, capability }], hints: [...] }
#    Read "hints" first: they name the included tool that covers the same need as a paid candidate.

# 2. Inspect: input_schema, price, the connectors this workspace has or lacks
#    (requires.connectors[].configured, settings_url) and the approval rule.
#    Keep the key: without it you read the public catalogue, blind to the
#    workspace's connectors, custom tools and agents. Never guess parameters.
curl -s https://api.ezyagents.fr/gateway/v1/tools/find_email -H "Authorization: Bearer $OTTO_API_KEY"

# 3. Run. wait=true by default: the tool runs inside the request for up to
#    120 s, then the run is "timed_out". Allow at least 130 s on your HTTP
#    client, or pass "wait": false and poll. Always send "idempotency_key" on
#    a write: a retried POST returns the same run, never a second email.
curl -s https://api.ezyagents.fr/gateway/v1/run -H "Authorization: Bearer $OTTO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"tool":"find_email","input":{"firstName":"Léa","lastName":"Marin","domain":"ateliers-marin.fr"},"idempotency_key":"lead-42-email"}'
# -> { run_id, tool, status, cost: { credits, billed, unit, billing },
#      result?, error?: { code, message }, approval?: { id, dashboard_url, message } }

# 4. Poll a queued or pending run (a few seconds apart while queued or
#    running, about once a minute while pending_approval)
curl -s https://api.ezyagents.fr/gateway/v1/runs/<run_id> -H "Authorization: Bearer $OTTO_API_KEY"

# Cancel a run still queued or waiting for approval (409 not_cancellable once it started)
curl -s -X POST https://api.ezyagents.fr/gateway/v1/runs/<run_id>/cancel -H "Authorization: Bearer $OTTO_API_KEY"

# This key's runs (filters: status, before=<ISO date>, limit up to 100; next_before paginates)
curl -s "https://api.ezyagents.fr/gateway/v1/runs?status=pending_approval" -H "Authorization: Bearer $OTTO_API_KEY"

# Balance and this key's monthly cap: check it before a batch (price.credits x items)
curl -s https://api.ezyagents.fr/gateway/v1/balance -H "Authorization: Bearer $OTTO_API_KEY"
```

Run statuses: `queued`, `running`, `pending_approval`, `completed`,
`failed`, `rejected`, `cancelled`, `timed_out`. HTTP 200 = finished
(completed, failed or timed_out), 202 = queued or pending approval (poll
`GET /runs/{run_id}`). An approval waits up to 24 hours; an expired or
rejected approval costs nothing.

Files produced by a tool (Excel, PDF, images) come back as `result.files[]`
with a `fileId`; `POST https://api.ezyagents.fr/gateway/v1/files/{fileId}/download-url` gives a
5-minute link. A key can only fetch files produced by its own runs.

## Errors (JSON: { "error": { "code", "message", ... } })

| HTTP | code | what to do |
|------|------|------------|
| 401 | invalid_key | ask the user for a valid key |
| 402 | credits_exhausted / ai_budget_exceeded | tell the user to top up in Settings → Billing; do not retry |
| 403 | scope_denied / policy_denied / tool_not_allowed | the key or the organisation forbids this tool; say so |
| 404 | unknown_tool / tool_not_exposed | run discover |
| 409 | connector_required | the user must connect a system: give them `settings_url` verbatim |
| 422 | invalid_input | read `errors`, fix the input, inspect again |
| 429 | rate_limited / key_cap_reached | slow down (120 req/min) or the key's monthly cap is reached |

Third-party APIs: the catalogue includes public data sources (weather, geocoding, French address and company registers, EU VAT, Wikipedia, exchange rates, GitHub, npm) that need no setup, and keyed services (Exa, Tavily, Brave, Firecrawl, Hunter, DeepL, Perplexity, Google Places…) whose key lives in the workspace settings; `apify_search_actors` → `apify_inspect_actor` → `apify_run_actor` gives access to thousands of Apify scrapers; the most used actors are also named tools (`apify__<username>__<name>`, e.g. `apify__compass__crawler-google-places`) that discover returns directly: inspect the actor's schema once, then run the named tool with { input }. A tool answering with a `note` and a settings link is not an error: relay the link.

## Rules

- Always inspect before running; never guess parameters.
- Start with small limits (5-10 items); report credits spent when the user
  cares about cost (`cost.credits` in every run response).
- `pending_approval` is normal, not an error: tell the user who was notified
  and wait or poll; never retry the same run, never work around it.
- Say clearly, before running, when a tool writes to the outside world
  (email, message, call, publication, CRM record, signature).
- A provider failure costs nothing. A rejected or expired approval costs nothing.

## Categories

- **Finance** (25): send_payment_reminder, parse_invoice, validate_vat_number, match_invoice_to_po
- **Files & calendar** (22): drive_search, gdocs_read, gdocs_write, gsheets_read
- **Web** (19): web_search, web_fetch, web_extract, apify_search_actors
- **Prospecting** (18): search_prospects_apollo, search_prospects_linkedin, find_email, enrich_prospects
- **Human resources** (16): list_employees, create_employee, create_candidate, list_candidates
- **Knowledge** (15): search_knowledge, company_knowledge, remember, recall
- **Marketing** (15): draft_blog_post, draft_social_post, draft_newsletter, generate_email_campaign
- **Customer support** (14): escalate_to_human, create_ticket, list_tickets, update_ticket_status
- **Social & video** (13): publish_social_post, schedule_cross_post, plan_campaign, get_campaign_status
- **Data & public APIs** (12): weather_forecast, geocode_place, osm_search_address, osm_reverse_geocode
- **Routines & missions** (11): schedule_task, list_tasks, update_task, cancel_task
- **CRM** (8): hubspot_list_deals, hubspot_update_deal, lookup_crm, create_contact_hubspot
- **Advertising** (7): generate_ad_visuals, generate_ad_video, check_ad_creatives, create_ad_campaign
- **Documents & code** (7): generate_document, run_code, run_shell, repo_checkout
- **SEO** (7): site_audit, search_console_query, analytics_report, serp_rank_check
- **Images & voice** (6): generate_social_image, generate_image, unsplash_search, pexels_search
- **Email** (4): read_emails, send_email, forward_email, reply_email
- **French companies** (4): search_companies_pappers, fr_bodacc_by_siren, fr_bodacc_search, fr_company_search
- **Database** (3): db_schema, db_query, db_execute
- **News** (3): hackernews_search, news_search, gnews_search
- **Slack & Teams** (2): post_slack_message, post_teams_message
- **Phone** (2): voice_call, voice_transcribe

Full catalogue with prices and schemas: https://ezyagents.fr/otto/outils
This file: https://ezyagents.fr/otto/SKILL.md
