diff --git a/README.md b/README.md index 3a09c25f9..f7c27eff6 100644 --- a/README.md +++ b/README.md @@ -319,6 +319,7 @@ domains/webhooks in the **web dashboard**. | `e2a suppressions list\|add\|remove` | Inspect and manage recipient block lists (account-wide GA; agent-scoped is beta) | | `e2a send` / `e2a reply` | Send an email as the agent, or reply in-thread | | `e2a messages list\|get` | List or fetch messages for an agent | +| `e2a metrics []` | Print delivery counters — account rollup, or one inbox (`--by-agent`, `--by-day`, `--json`) | | `e2a listen --agent ` | Stream inbound email for an agent over WebSocket (real-time; `--json` for raw, `--forward ` to bridge to a local HTTP handler) | | `e2a config [list\|get\|set]` | View or update the local config | diff --git a/cli/README.md b/cli/README.md index 3c47b8c96..bd6b29f54 100644 --- a/cli/README.md +++ b/cli/README.md @@ -257,6 +257,25 @@ a server-owned, read-only mailbox-local identity. Human-readable formats do not change, and there is no `threadId` request flag, filter, or thread endpoint. +### `e2a metrics` + +Print delivery counters for the account, or a single inbox. + +```bash +e2a metrics # account rollup +e2a metrics bot@acme.com # one inbox +e2a metrics --by-agent --json # account rollup broken down per agent +e2a metrics --by-day --start 2026-08-01T00:00:00Z --json +``` + +With no positional argument this prints the account rollup; with one, that +inbox's counters (accepted/submitted/delivered, bounces by class, complaints, +suppressions, inbound DMARC results, review outcomes, and webhook delivery +health). Flags: `--start`/`--end` (RFC 3339 window bounds), `--by-agent` +(break the account rollup down per agent — account rollup only), `--by-day` +(UTC daily buckets — account rollup only), `--json` (print the full metrics +view as JSON instead of the human-readable summary). + ### `e2a contacts` (beta) Manage account-level contact identity and per-agent outreach state, with diff --git a/docs/runbooks/mcp-server.md b/docs/runbooks/mcp-server.md index 1e4afe587..ab596e8f9 100644 --- a/docs/runbooks/mcp-server.md +++ b/docs/runbooks/mcp-server.md @@ -116,7 +116,7 @@ design. - **Symptoms**: requests succeed, but the credential is served at least-privilege **agent scope**: account-scoped callers see the tool list - shrink from 76 tools to the 20 runtime tools, and the per-request default + shrink from 78 tools to the 21 runtime tools, and the per-request default agent is unset (explicit `email` required). - **Detection**: `auth_resolution` WARNING `whoami probe failed; serving least-privilege fallback`; `mcp_auth_resolutions_total{result="fallback"}`. diff --git a/mcp/README.md b/mcp/README.md index ec36d9b7c..f65db64b3 100644 --- a/mcp/README.md +++ b/mcp/README.md @@ -121,15 +121,15 @@ Hosts that support OAuth connectors can instead add `https://api.e2a.dev/mcp` as ## Tools -The server exposes up to **76** tools spanning agents, messages, human-in-the-loop +The server exposes up to **78** tools spanning agents, messages, human-in-the-loop approval, attachments, domains, events, webhooks, API keys, contacts/outreach, email templates (beta), and suppressions. **The visible set depends on your credential's scope:** an **agent**-scoped -credential sees the 20 runtime/inbox tools (read, send, reply, restore +credential sees the 21 runtime/inbox tools (read, send, reply, restore messages, per-agent outreach); an **account**-scoped credential also sees the -56 admin/setup tools (agent/domain/webhook/event/template/API-key/contact/ +57 admin/setup tools (agent/domain/webhook/event/template/API-key/contact/ suppression management — **and HITL review discovery plus approve/reject, which -is an account-owner action, never agent self-approval**) — all 76. +is an account-owner action, never agent self-approval**) — all 78. Every tool carries MCP annotations (`readOnlyHint`/`destructiveHint`/ `idempotentHint`) so hosts can auto-approve reads and flag destructive actions. The tables below highlight the most commonly used ones — your MCP host's tool list diff --git a/mcp/examples/README.md b/mcp/examples/README.md index 14453b4ed..2f55e2d88 100644 --- a/mcp/examples/README.md +++ b/mcp/examples/README.md @@ -12,7 +12,7 @@ End-to-end demos showing how to wire the e2a MCP surface into popular agent fram ## One hosted endpoint, same tool surface -Each example exercises the same e2a tool surface (76 tools; the visible set depends on your key's scope) against the hosted MCP server. The Python framework examples ship an `agent.py` script; the Codex example ships a TOML block (Codex is itself the agent, so you configure it instead of writing a script). +Each example exercises the same e2a tool surface (78 tools; the visible set depends on your key's scope) against the hosted MCP server. The Python framework examples ship an `agent.py` script; the Codex example ships a TOML block (Codex is itself the agent, so you configure it instead of writing a script). Every example connects to `https://api.e2a.dev/mcp` over Streamable HTTP with an agent-scoped API key in the `Authorization` header. Set `E2A_MCP_URL` to point diff --git a/mcp/examples/codex/README.md b/mcp/examples/codex/README.md index bf1425e7c..366d3aea4 100644 --- a/mcp/examples/codex/README.md +++ b/mcp/examples/codex/README.md @@ -2,7 +2,7 @@ [Codex CLI](https://github.com/openai/codex) is OpenAI's terminal coding agent (peer to Claude Code). It speaks MCP natively — you declare servers in `~/.codex/config.toml` and Codex connects to them at session start, then surfaces their tools to whatever model you're running. -Unlike the [LangChain](../langchain/), [CrewAI](../crewai/), [Google ADK](../adk/), and [OpenAI Agents SDK](../openai-agents/) examples — which are Python scripts you run — Codex is itself the agent. The "example" here is the TOML you paste into your Codex config to add e2a's MCP tools (76 total; the visible set depends on your key's scope). +Unlike the [LangChain](../langchain/), [CrewAI](../crewai/), [Google ADK](../adk/), and [OpenAI Agents SDK](../openai-agents/) examples — which are Python scripts you run — Codex is itself the agent. The "example" here is the TOML you paste into your Codex config to add e2a's MCP tools (78 total; the visible set depends on your key's scope). Codex opens a Streamable HTTP session to the hosted endpoint at `https://api.e2a.dev/mcp` with your API key in the `Authorization: Bearer …` header — no Node toolchain on the host (works on CI runners, dev containers, remote app servers, etc.).