@dench.com/cli 3.10.2 → 3.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/app-sdk.d.ts +10 -0
- package/leads.ts +173 -14
- package/lib/app-sdk-catalog.generated.ts +1 -0
- package/lib/command-registry.ts +19 -0
- package/lib/references.generated.json +6 -6
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
|
-
"revision": "
|
|
3
|
-
"builtinHash": "
|
|
2
|
+
"revision": "ccf3a1459b0939d1d843c293f6119f68a9e6e560ce287329a285c46dcaade4d6",
|
|
3
|
+
"builtinHash": "e818202802c633e578e1f69964be7b461532576dbecd60e92c5b2779813ba7be",
|
|
4
4
|
"files": {
|
|
5
5
|
"SKILL.md": {
|
|
6
6
|
"sha256": "304f0f9a0fbd232758b26c6d7ec8c1767bf56717d7f9f22b344d1c2264b6b747",
|
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
"content": "---\nname: actions\ndescription: Create and run per-row CRM action buttons (`action`-typed fields). Covers the three kinds — no-code Tier-A recipes (update/create/delete entries), Tier-B script/agent actions, and link buttons that open a workspace deep link or external URL — plus the recipe shape, URL templating ({id}/{object}/{Field}), and the CLI/API/agent authoring surface. Load before adding or running action buttons.\n---\n\n# Dench Actions\n\nActions are buttons attached to a CRM object via an **`action`-typed field**.\nClicking a button on a row runs a small piece of member logic — a declarative\nrecipe of CRM operations (no code), a script executed by a Dench agent, or a\n**link** that just opens a workspace deep link or external URL. Actions are\nrunnable from the table UI, the public API, the `dench` CLI, and the in-product\nagent.\n\n> **Status (live).** Defining actions (the Basic Action Builder + `action`\n> fields) and *executing* them are both live across the table UI, CLI, public\n> API, and the in-product agent. Tier-A recipes run immediately as the\n> triggering member; Tier-B script actions spawn a Dench agent that executes in\n> its sandbox.\n\n## The kinds of action\n\nEvery button is exactly one kind. Pick the smallest that does the job.\n\n- **Tier A — declarative recipe (no code).** A short ordered list of CRM\n operations. Built with the **Basic Action Builder** UI (no scripting) or via\n the API/CLI. Runs directly on the workflow — cheap, fast, safe. This covers\n the common cases: set fields, create a related row, delete the row.\n- **Tier B — script / agent (custom logic).** Arbitrary logic (branching,\n external APIs, multi-object work). Runs by spinning up a **Dench agent** with\n the row as context; the agent executes in its sandbox. Use this only when a\n recipe can't express what you need.\n- **Link — open a URL.** A button that opens a link: an internal workspace\n deep link (a record, an object, a saved view, a settings tab — see **Link\n actions** below) or an external URL (a dashboard, a doc, a `mailto:`).\n Static by default; add a recipe to make it **run-then-open** (compute/write,\n then open a link built from the result — see **Dynamic links**).\n\n## Link actions\n\nA link action stores a `url` instead of a `recipe`/`script`. Clicking it\nnavigates: internal deep links open in-app (no page reload), external URLs\nopen in a new tab. The URL is a **template** resolved against the clicked row\nwith three token kinds:\n\n- `{id}` — the row's entry id.\n- `{object}` — the object's canonical name.\n- `{Field Name}` — the value of a field on the row (e.g. `{Website}`).\n\n```text\n# Open THIS record's detail (internal deep link):\n--url '/?path=deal&entry=deal:{id}'\n\n# Open the value stored in a URL-typed cell (external, new tab):\n--url '{Website}'\n--url '{LinkedIn URL}'\n\n# Cross-link an external system with a row field:\n--url 'https://app.stripe.com/customers/{Stripe ID}'\n\n# Jump to a workspace surface:\n--url '/?path=~settings/billing'\n--url '/?path=people'\n```\n\nInternal paths follow the full deep-link vocabulary in\n[`references/NAVIGATION.md`](https://dench.com/references/NAVIGATION.md)\n(`load_skill navigation`) — objects, records, saved views, the App Store, apps,\nautomations, the inbox, settings tabs, files. Use the slug-less `/?…` form so it\nresolves to the current workspace. External URLs must be `http(s)://`,\n`mailto:`, or `tel:`; `javascript:`/`data:` and other schemes are rejected.\nRunning a link action headless (CLI/API/agent) returns the resolved `url`\nrather than navigating, so the agent can hand the user a ready link.\n\n### Dynamic links (run-then-open)\n\nA link doesn't have to be fully predefined. Give a link action **both a `url`\nand a `recipe`** and it becomes \"run-then-open\": clicking it first runs the\nTier-A recipe on the row (member-attributed, in entry history), then resolves\nthe `url` template against the **updated** row and opens it. So you can compute\nor write a value and immediately open a link built from it.\n\n```bash\n# Stamp a field, then open a link derived from the fresh value.\ndench crm actions create deal \"Quick actions\" --label \"Start checkout\" \\\n --recipe '[{\"op\":\"update_entry\",\"assignments\":[{\"field\":\"Checkout Status\",\"value\":{\"from\":\"static\",\"value\":\"Started\"}}]}]' \\\n --url '/?path=deal&entry=deal:{id}&entryTab=activity'\n```\n\nThe recipe can only do the deterministic CRM steps (update/create/delete) — it\nruns synchronously and the tab opens as soon as it finishes. For links that need\n**arbitrary lookup or search** (e.g. \"find this company's LinkedIn\"), have an\nagent (a chat request, an automation, or a Tier-B action) write the discovered\nURL into a field, then point a link action at `{That Field}` — the link is then\nfully dynamic per row.\n\n## Recipe shape (Tier A)\n\nAn `action` field stores its buttons in the field's `default_value` as JSON:\n\n```json\n{\n \"actions\": [\n {\n \"id\": \"mark-won\",\n \"label\": \"Mark as Won\",\n \"variant\": \"success\",\n \"confirmMessage\": \"Mark this deal Won?\",\n \"recipe\": [\n { \"op\": \"update_entry\",\n \"assignments\": [\n { \"field\": \"Status\", \"value\": { \"from\": \"static\", \"value\": \"Won\" } },\n { \"field\": \"Closed By\", \"value\": { \"from\": \"field\", \"field\": \"Owner\" } }\n ] },\n { \"op\": \"create_entry\", \"object\": \"task\",\n \"assignments\": [\n { \"field\": \"Title\", \"value\": { \"from\": \"prompt\", \"label\": \"Follow-up?\" } }\n ] }\n ]\n }\n ]\n}\n```\n\n- **Operations:** `update_entry` (set fields on the clicked row),\n `create_entry` (a new row in this or another object), `delete_entry`.\n- **Value sources:** `static` (a literal), `field` (copy from another field on\n the clicked row), `prompt` (ask the member when they click).\n- **Button meta:** `label`, `variant`\n (`default|primary|success|warning|destructive`), optional `confirmMessage`\n (auto-required for delete).\n- **Tier B** uses `script` / `scriptPath` instead of `recipe`.\n\n## One column, many buttons\n\nAn `action` field is a **column** that holds an **array** of buttons. Two rules\nkeep tables readable:\n\n- **Group related buttons in one column.** To add a button to an existing\n column, pass the same `fieldName` (CLI/API) — it upserts into that column's\n `actions` array. Every row then shows those buttons side by side.\n- **Give columns clear custom names.** Name a column for what it does — e.g.\n `Quick actions`, `Outreach`, `Account actions` — instead of creating a new\n `Actions` column per button. An object can have several action columns, each\n with its own name and its own set of buttons.\n\nButtons always render with their label (never a bare icon), so a column with\ntwo or more buttons stays legible.\n\n## Create / edit an action\n\nEverything below is equivalent — the API is the single source of truth; CLI and\nthe agent call it.\n\n### UI (no code)\n\nEntry sidebar → **Add property** → type **Action** → the **Basic Action\nBuilder** opens (button meta + step list + live preview). Also available from a\ntable column header's \"Add column\". Saves into the field's `default_value`.\n\n### CLI\n\n```bash\n# Create (or upsert) an action — creates the `action` field if it doesn't exist.\n# A button is exactly one kind: --recipe (Tier A), --script/--script-path\n# (Tier B), or --url (a link).\ndench crm actions create deal \"Quick actions\" --label \"Mark as Won\" --variant success \\\n --recipe '[{\"op\":\"update_entry\",\"assignments\":[{\"field\":\"Status\",\"value\":{\"from\":\"static\",\"value\":\"Won\"}}]}]'\n\n# Link action: open this record's detail (internal deep link, opens in-app).\ndench crm actions create deal \"Quick actions\" --label \"Open\" \\\n --url '/?path=deal&entry=deal:{id}'\n\n# Link action: open a field's URL in a new tab (external).\ndench crm actions create company \"Links\" --label \"Website\" --url '{Website}'\n\n# Edit an action (object + field name + actionId); change label, recipe, variant…\ndench crm actions edit deal \"Quick actions\" mark_as_won --label \"Mark Won\"\n\n# Delete an action (optionally drop the field once its last action is gone)\ndench crm actions delete deal mark_as_won --field \"Quick actions\" [--delete-field-if-empty]\n\n# List the actions available on an entry\ndench crm actions list <entryId> --json\n\n# Run an action on one or more entries (Tier-A runs inline; Tier-B spawns an agent)\ndench crm actions run <objectName> <fieldId> <actionId> <entryId> [<entryId> ...]\n```\n\n### Public API\n\nSame surface as the CLI (one contract; `Authorization: Bearer <DENCH_API_KEY>`):\n\n```http\n# Create / upsert an action. Send exactly one of `recipe` (Tier A),\n# `script`/`scriptPath` (Tier B), or `url` (a link action).\nPOST /api/v1/crm/actions\n{ \"objectName\": \"deal\", \"fieldName\": \"Quick actions\", \"label\": \"Mark as Won\",\n \"variant\": \"success\",\n \"recipe\": [{\"op\":\"update_entry\",\"assignments\":[{\"field\":\"Status\",\"value\":{\"from\":\"static\",\"value\":\"Won\"}}]}] }\n\n# Link action (deep link or external URL; supports {id}/{object}/{Field} tokens):\nPOST /api/v1/crm/actions\n{ \"objectName\": \"deal\", \"fieldName\": \"Quick actions\", \"label\": \"Open\",\n \"url\": \"/?path=deal&entry=deal:{id}\" }\n\n# Update an action\nPATCH /api/v1/crm/actions/{actionId}\n{ \"objectName\": \"deal\", \"fieldName\": \"Quick actions\", \"label\": \"Mark Won\" }\n\n# Delete an action\nDELETE /api/v1/crm/actions/{actionId}\n{ \"objectName\": \"deal\", \"fieldName\": \"Quick actions\" }\n\n# Run an action\nPOST /api/v1/crm/actions/{actionId}/runs\n{ \"objectName\": \"deal\", \"fieldId\": \"<fieldId>\", \"entryIds\": [\"<entryId>\"] }\n```\n\n### Agent (in-product)\n\nThe chat agent runs actions via the `run_crm_action` tool (member-attributed),\nand can author them by calling `dench crm actions create` from its sandbox (or\nthe API). Ask it: *\"Add a 'Mark as Won' button to deals that sets Status =\nWon,\"* or *\"Add an 'Open in Stripe' button that links to the customer.\"* For a\nlink action the agent passes `--url` (CLI) / `url` (API); running a link action\nvia `run_crm_action` returns the resolved URL so the agent can hand it to you as\na link.\n\n## Execution model\n\n- **Tier A** resolves the recipe against each row (`planRecipe`) and performs\n every CRM operation via the same member-authed mutations a manual edit uses —\n so writes inherit validation, automations, and entry-history attribution. It\n runs inline (the browser actions route, the `crm.actions.run` operation\n used by CLI/API, and the agent's `run_crm_action` tool) and records a\n `crmActionRuns` history row per entry.\n- **Tier B** spawns a **Dench agent** (`chatTurnWorkflow`, a durable workflow)\n with the row context + the action's script/instructions as the first message;\n arbitrary code runs only inside the agent's sandbox — the established trust\n boundary. Browser callers start the workflow directly; the CLI/API/agent path\n starts it via the internal `spawn-chat` route.\n- Runs are **attributed to the member** who triggered them. The agent and\n browser paths use the member's per-member Dench API key (FR2), so **entry\n history records the human**, not the org.\n- Bulk runs (many rows) iterate per entry; each row reports its own result\n (Tier A: operation count; Tier B: the spawned run/thread ids).\n\n## Run log (entry History)\n\nEvery run — Tier-A recipe, Tier-B agent, run-then-open link — writes a\n`crmActionRuns` audit row on the entry carrying **who** triggered it (the\nmember actor, same shape as entry history), the **input** (Tier-B prompt,\nTier-A ask-when-run answers, link template), the **output** (Tier-A operation\ncount; Tier-B: the agent's `finish` summary once the run completes), status\n(`pending → running → completed | failed | canceled`), and timestamps.\n\n- The record's **History tab** renders these interleaved with field-change\n events, live: an agent run flips from Running to Completed/Failed in place\n when the workflow finishes.\n- A Tier-B run's chat thread is its **execution transcript**. It appears in\n the chat sidebar with a badge for the entry it ran on (display label +\n favicon); clicking it opens the chat **and** that entry's detail panel on\n its History tab. The run's \"View transcript\" button (deep link\n `/?chat={threadId}`) opens the chat beside the record without closing the\n entry panel.\n- Headless surfaces read the same log:\n `GET /api/workspace/objects/{object}/actions/runs?entryId=...` returns rows\n with `actor`, `action_label`, `kind`, `input`, `result`, `thread_id`.\n\n## Permissions & safety\n\n- Actions run with the triggering member's authority and are audited.\n- Tier A can only do CRM CRUD on objects the member can access.\n- Tier B (script/agent) is sandboxed; treat it like any agent run.\n\n## Related\n\n- CRM fields & the `action` type: [`references/CRM.md`](https://dench.com/references/CRM.md)\n- Workspace deep links for link-action URLs: [`references/NAVIGATION.md`](https://dench.com/references/NAVIGATION.md)\n- Building full apps with `window.dench`: [`references/APPS.md`](https://dench.com/references/APPS.md)\n- Public API: [`references/API.md`](https://dench.com/references/API.md)\n"
|
|
12
12
|
},
|
|
13
13
|
"references/API.md": {
|
|
14
|
-
"sha256": "
|
|
15
|
-
"content": "# Dench API Guide\n\nUse the Dench CLI first. This API guide is the backup path for agents when the CLI is unavailable, cannot be installed, or cannot run in the current environment.\n\nBase URL:\n\n```bash\nexport DENCH_API_BASE=\"https://www.dench.com/api/v1\"\nexport DENCH_API_KEY=\"<workspace API key or dch_agent_* session token>\"\n```\n\nAuthentication:\n\n```http\nAuthorization: Bearer <DENCH_API_KEY or dch_agent_* session token>\n```\n\nEvery parameter, request body, and response is documented interactively in the OpenAPI playground. This curl guide is generated from the same registry.\n\nMachine-readable spec:\n\n```bash\ncurl -sS \"$DENCH_API_BASE/openapi.json\"\n```\n\n## Important Notes\n\n- Prefer the CLI when it works; it handles local session selection, prompts, streaming display, and file staging ergonomics.\n- Gateway-backed operations (search, dench web, images, apps, tools, enrichment) accept either a Dench API key or an agent session; agent sessions are exchanged for the workspace gateway key server-side.\n- Dench web (page read, brand, sitemap, crawl, screenshot, extract) is `POST /context/{op}`, proxied to `$DENCH_GATEWAY_URL/v1/context/{op}`. Prefer `dench web` / `fetch_url` over writing your own scraper. Search stays `POST /search`.\n- Local-only commands are listed for completeness but operate on the caller's machine and cannot run remotely.\n- For chat operations authenticated with an API key, include `x-dench-run-id: <run_id>` when acting from inside a running agent turn.\n\n## Agent Config\n\n### dench context --sections identity\n\nRead IDENTITY.md.\n\n- API: `GET /agent-config/identity`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench identity show`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/identity\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context set identity\n\nUpdate IDENTITY.md.\n\n- API: `PUT /agent-config/identity`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench identity edit`\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/identity\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench context --sections organisation\n\nRead ORGANISATION.md.\n\n- API: `GET /agent-config/organisation`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench organisation show`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/organisation\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context set organisation\n\nUpdate ORGANISATION.md.\n\n- API: `PUT /agent-config/organisation`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench organisation edit`\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/organisation\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench context --sections user\n\nRead USER.md.\n\n- API: `GET /agent-config/user`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench user show`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/user\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context set user\n\nUpdate USER.md.\n\n- API: `PUT /agent-config/user`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench user edit`\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/user\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench context --sections tools\n\nRead tool notes.\n\n- API: `GET /agent-config/tools`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench tools show`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/tools\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context set tools\n\nUpdate tool notes.\n\n- API: `PUT /agent-config/tools`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench tools edit`\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/tools\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench mem show\n\nRead aggregate memory.\n\n- API: `GET /agent-config/mem`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/mem\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench mem set\n\nUpdate aggregate memory.\n\n- API: `PUT /agent-config/mem`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/mem\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench bootstrap status\n\nRead bootstrap state.\n\n- API: `GET /agent-config/bootstrap`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/bootstrap\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench bootstrap complete\n\nComplete bootstrap.\n\n- API: `POST /agent-config/bootstrap/complete`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/agent-config/bootstrap/complete\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench bootstrap template\n\nUpdate bootstrap template.\n\n- API: `PUT /agent-config/bootstrap/template`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/bootstrap/template\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench model default\n\nSet the default chat model.\n\n- API: `PUT /agent-config/model/default`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/model/default\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"modelId\": \"string\"\n }'\n```\n\n### dench model thread\n\nSet a thread model override.\n\n- API: `PUT /agent-config/model/threads/{threadId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/model/threads/{threadId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"modelId\": \"string\"\n }'\n```\n\n### dench daily today\n\nRead today's daily activity path.\n\n- API: `GET /agent-config/daily/today`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/daily/today\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench daily show\n\nRead a daily activity path.\n\n- API: `GET /agent-config/daily/{date}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/daily/{date}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Approvals\n\n### dench approvals\n\nList approval requests visible in the workspace status payload.\n\n- API: `GET /approvals`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/approvals\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench approval request\n\nRequest human approval.\n\n- API: `POST /approvals`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/approvals\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"title\": \"Deploy the new API branch?\",\n \"reason\": \"Production deploy changes public behavior.\",\n \"risk\": \"high\"\n }'\n```\n\n### dench approval approve|reject\n\nRecord an approval decision.\n\n- API: `POST /approvals/{approvalId}/decision`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/approvals/{approvalId}/decision\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"decision\": \"approved\",\n \"evidence\": \"User said yes in chat\"\n }'\n```\n\n## Apps\n\n### dench apps list\n\nList installed App Store apps in the workspace.\n\n- API: `GET /apps`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/apps\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench apps gallery\n\nList Discover listings — Official (Dench) + Community shelves.\n\n- API: `GET /apps/gallery`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/apps/gallery\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench apps create\n\nScaffold and register a new App Store app.\n\n- API: `POST /apps`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/apps\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"slug\": \"string\",\n \"name\": \"string\"\n }'\n```\n\n### dench apps install\n\nInstall an App Store listing into the workspace.\n\n- API: `POST /apps/install`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/apps/install\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"listingId\": \"string\"\n }'\n```\n\n### dench apps publish\n\nPublish an app's files as a versioned App Store listing.\n\n- API: `POST /apps/publish`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/apps/publish\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"appPath\": \"string\",\n \"slug\": \"string\",\n \"name\": \"string\"\n }'\n```\n\n### dench apps uninstall\n\nUninstall an app from the workspace.\n\n- API: `DELETE /apps/{slug}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/apps/{slug}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench apps enable\n\nEnable or disable an installed app.\n\n- API: `PATCH /apps/{slug}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/apps/{slug}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"enabled\": true\n }'\n```\n\n### dench apps pin\n\nPin or unpin an installed app in the rail.\n\n- API: `POST /apps/{slug}/pin`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/apps/{slug}/pin\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"pinned\": true\n }'\n```\n\n### dench apps validate\n\nValidate a .dench.app folder: manifest, permissions, and every window.dench call it makes.\n\n- API: `POST /local/apps/validate`\n- Auth: No bearer token required.\n\n```bash\n# dench apps validate\n# Local-only: Validation reads the app folder on the caller's disk. In the browser, the same catalog is window.dench.api.operations().\n```\n\n### dench apps webhooks register\n\nRegister an inbound webhook for an app. Returns the URL and signing secret ONCE.\n\n- API: `POST /apps/{slug}/webhooks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/apps/{slug}/webhooks\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"hookName\": \"string\"\n }'\n```\n\n### dench apps webhooks list\n\nList an app's registered webhooks (URLs, never secrets).\n\n- API: `GET /apps/{slug}/webhooks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/apps/{slug}/webhooks\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench apps webhooks poll\n\nRead events an app webhook received since a timestamp.\n\n- API: `GET /apps/{slug}/webhooks/{hookName}/events`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/apps/{slug}/webhooks/{hookName}/events\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench apps webhooks delete\n\nRemove an app webhook and every event it stored.\n\n- API: `DELETE /apps/{slug}/webhooks/{hookName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/apps/{slug}/webhooks/{hookName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Auth\n\n### dench signin\n\nCreate an agent sign-in request.\n\n- API: `POST /auth/signin-requests`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/auth/signin-requests\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"codeHash\": \"string\",\n \"sessionTokenHash\": \"string\",\n \"agentName\": \"string\",\n \"agentKind\": \"string\",\n \"intent\": \"join_existing\"\n }'\n```\n\n### dench signin\n\nPoll an agent sign-in request until approval.\n\n- API: `POST /auth/signin-requests/{requestId}/poll`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/auth/signin-requests/{requestId}/poll\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"codeHash\": \"string\",\n \"sessionTokenHash\": \"string\"\n }'\n```\n\n### dench signin --email\n\nStart the email OTP sign-in flow.\n\n- API: `POST /auth/otp/start`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/auth/otp/start\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"email\": \"string\"\n }'\n```\n\n### dench signin --email\n\nVerify an email OTP sign-in code.\n\n- API: `POST /auth/otp/verify`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/auth/otp/verify\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"email\": \"string\",\n \"code\": \"string\",\n \"agentName\": \"string\",\n \"agentKind\": \"string\",\n \"sessionTokenHash\": \"string\",\n \"intent\": \"join_existing\"\n }'\n```\n\n### dench signin --email\n\nFinalize an email OTP sign-in session.\n\n- API: `POST /auth/otp/finalize`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/auth/otp/finalize\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"authToken\": \"string\"\n }'\n```\n\n## Billing\n\n### dench billing status\n\nGet billing and AI credit status.\n\n- API: `GET /billing/status`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/billing/status\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench billing topup\n\nCreate an AI credit top-up checkout link.\n\n- API: `POST /billing/topup`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/billing/topup\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"requestId\": \"string\",\n \"amountUsd\": 0\n }'\n```\n\n### dench upgrade\n\nCreate a workspace upgrade checkout link.\n\n- API: `POST /billing/upgrade`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/billing/upgrade\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Browser\n\n### dench browser\n\nDrive Dench Browser with a single interactive action (open, inspect, click, fill, type, screenshot, stop). Pass the step in `action` plus its arguments.\n\n- API: `POST /browser/cli`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/browser/cli\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"action\": \"open\",\n \"url\": \"https://example.com\"\n }'\n```\n\n### dench browser session create\n\nCreate a Dench Browser session and return a CDP connect URL for Playwright (chromium.connectOverCDP) plus a live-view URL. Use for durable scripts run from the sandbox.\n\n- API: `POST /browser/sessions`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/browser/sessions\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"viewport\": {\n \"width\": 1280,\n \"height\": 800\n }\n }'\n```\n\n### dench browser session status\n\nGet the status, connect URL, and live-view URL for a Dench Browser session.\n\n- API: `GET /browser/sessions/{sessionId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/browser/sessions/{sessionId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench browser session stop\n\nStop a Dench Browser session and release the remote browser.\n\n- API: `DELETE /browser/sessions/{sessionId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/browser/sessions/{sessionId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Campaigns\n\n### dench campaign draft\n\nCreate an idempotent empty campaign draft with the caller's available sender pools. Does not launch or send.\n\n- API: `POST /campaigns/drafts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/drafts\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"clientRequestId\": \"string\"\n }'\n```\n\n### dench campaign search\n\nSearch people by filters without adding CRM records or campaign recipients. Search credits apply; this is not a free provider preview.\n\n- API: `POST /campaigns/audience/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/audience/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"filters\": {}\n }'\n```\n\n### dench campaign add --search\n\nSearch and add up to 50 people to an existing campaign. New identities become Leads. Search credits apply; use nextPageToken for another page.\n\n- API: `POST /campaigns/{sequenceId}/people/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/people/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"filters\": {}\n }'\n```\n\n### dench campaign add --people-file\n\nAdd up to 50 selected recipients without another search. Deduplicates, applies suppression, and preserves the campaign's launch state.\n\n- API: `POST /campaigns/{sequenceId}/people/batch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/people/batch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"recipients\": []\n }'\n```\n\n### dench campaign sources get\n\nRead a campaign's saved signal source, targeting and schedule.\n\n- API: `GET /campaigns/{sequenceId}/sources`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/sources\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources signals\n\nRead signal choices, suggested terms and current source configuration.\n\n- API: `GET /campaigns/{sequenceId}/sources/signals`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/signals\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources set\n\nUpdate source cadence, pause/resume, targeting, signals or terms. Active sources may perform billable future work.\n\n- API: `PATCH /campaigns/{sequenceId}/sources`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/campaigns/{sequenceId}/sources\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources preview\n\nPreview a signal source using its current audience. Provider credits may apply; does not enroll people.\n\n- API: `POST /campaigns/{sequenceId}/sources/preview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/preview\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"signal\": \"post_engagement\"\n }'\n```\n\n### dench campaign sources run\n\nRun a live campaign's signals now instead of waiting for the schedule (Run now). Provider credits apply; limited to 6 runs an hour.\n\n- API: `POST /campaigns/{sequenceId}/sources/run`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/run\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources overview\n\nRead the Sources tab: each signal's status, last and next run, people found and anything needing attention.\n\n- API: `GET /campaigns/{sequenceId}/sources/overview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/overview\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources pending\n\nList people a signal found who are waiting for approval (manual approval mode).\n\n- API: `GET /campaigns/{sequenceId}/sources/pending`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/pending\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources approve|reject\n\nApprove people waiting for review (they start the sequence) or reject them.\n\n- API: `POST /campaigns/{sequenceId}/sources/review`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/review\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"enrollmentIds\": [],\n \"decision\": \"approve\"\n }'\n```\n\n### dench campaign queue\n\nToday's queue: who the campaign plans to contact today, warmest first, within the senders' limits.\n\n- API: `GET /campaigns/{sequenceId}/queue`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/queue\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder profile\n\nRead the company profile and suggested campaign audience.\n\n- API: `GET /campaigns/builder/profile`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/builder/profile\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder save\n\nSave a signal campaign's audience, signals and terms idempotently. Does not start a build.\n\n- API: `POST /campaigns/builder/drafts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/drafts\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"clientRequestId\": \"string\",\n \"targeting\": {},\n \"signals\": []\n }'\n```\n\n### dench campaign builder get\n\nRead signal build progress, preview people, messages and errors.\n\n- API: `GET /campaigns/builder/drafts/{draftId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder build\n\nStart the same billable signal/audience/message build used by the UI; poll the draft for progress.\n\n- API: `POST /campaigns/builder/drafts/{draftId}/build`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/build\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder create\n\nCreate a campaign from a reviewed signal draft. Does not launch the campaign.\n\n- API: `POST /campaigns/builder/drafts/{draftId}/create`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/create\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder opener\n\nEdit or reset one preview person's opening line before creating the campaign.\n\n- API: `PUT /campaigns/builder/drafts/{draftId}/people/{leadId}/opener`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/people/{leadId}/opener\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"opener\": \"string\"\n }'\n```\n\n### dench campaign builder drafts\n\nList saved, unfinished campaign drafts that can be resumed.\n\n- API: `GET /campaigns/builder/drafts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/builder/drafts\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder resume\n\nRead a saved draft's setup (source, name, targeting, signals, terms, lookalike) to resume it.\n\n- API: `GET /campaigns/builder/drafts/{draftId}/setup`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/setup\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder discard\n\nDiscard a saved draft that has not become a campaign.\n\n- API: `DELETE /campaigns/builder/drafts/{draftId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder outreach\n\nSave a draft's Outreach and Review choices: AI or manual steps, the brief, the steps, who sends and when, and auto or manual approval.\n\n- API: `PATCH /campaigns/builder/drafts/{draftId}/outreach`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/outreach\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder sequence\n\nGenerate the draft's sequence from a brief (goal, problem, tone, channels), as Generate sequence does. AI credits apply.\n\n- API: `POST /campaigns/builder/drafts/{draftId}/sequence`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/sequence\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"brief\": {}\n }'\n```\n\n### dench campaign builder lookalike\n\nSet up a lookalike from the best lead's LinkedIn URL (role, similar roles, place, industry, similar companies), suggest roles again, or re-scope to a company. Nothing is saved. Provider credits apply.\n\n- API: `POST /campaigns/builder/lookalike`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/lookalike\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder voices\n\nSuggest market voices (LinkedIn experts) for the campaign's topics, to watch with voice_engagement. AI credits apply.\n\n- API: `POST /campaigns/builder/voices`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/voices\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder autofill\n\nTurn an audience description into targeting filters. AI credits apply.\n\n- API: `POST /campaigns/builder/autofill`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/autofill\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"description\": \"string\"\n }'\n```\n\n### dench campaign builder estimate\n\nEstimate audience or weekly signal volume using the UI's cached estimator. Provider credits may apply.\n\n- API: `POST /campaigns/builder/estimate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/estimate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"kind\": \"people\",\n \"targeting\": {}\n }'\n```\n\n### dench campaign accounts\n\nDiscover LinkedIn sender ids, labels, availability and remaining capacity visible to the acting workspace member. Never returns provider credentials.\n\n- API: `GET /campaigns/accounts/linkedin`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/accounts/linkedin\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign accounts\n\nDiscover the mailboxes the acting workspace member can send campaign email from: ids for emailMailboxAccountIds, status, warm-up state and when it is done, the daily cold-email cap and what is left today. Never returns provider credentials.\n\n- API: `GET /campaigns/accounts/email`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/accounts/email\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign list [--with-references]\n\nList outreach campaigns (archived ones on request).\n\n- API: `GET /campaigns`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign create\n\nCreate a draft outreach campaign with email and LinkedIn sender pools and a business-hours send window in the given timezone.\n\n- API: `POST /campaigns`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Founder outreach\",\n \"timezone\": \"America/Los_Angeles\",\n \"emailMailboxAccountIds\": [\n \"<emailMailboxAccountId>\"\n ],\n \"linkedinAccountIds\": [\n \"<linkedinAccountId>\"\n ]\n }'\n```\n\n### dench campaign duplicate\n\nCopy a campaign into a new draft named \"<name> copy\": the same steps, schedule, sender pools and personalized lines, its lead source paused, and no people. To reach more than 300 people, duplicate and add the next page of the search to the copy.\n\n- API: `POST /campaigns/{sequenceId}/duplicate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/duplicate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign get\n\nRead a campaign: settings, steps, people, their current step and hold, last touches, linked leads.\n\n- API: `GET /campaigns/{sequenceId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign get\n\nCampaign funnel: enrolled, contacted, invited, accepted, messaged, replied, opens and clicks, and for a workflow how many people took each If / else and Wait for them to accept path (branchStats).\n\n- API: `GET /campaigns/{sequenceId}/analytics`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/analytics\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign get\n\nWhat the campaign is doing now, what comes next and when, and why it is holding.\n\n- API: `GET /campaigns/{sequenceId}/live`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/live\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign pipeline\n\nWhere a campaign's people sit in the workspace's lead pipeline right now: each lead Status in order with how many enrolled leads are at it, and how many have no lead or a status outside the pipeline.\n\n- API: `GET /campaigns/{sequenceId}/pipeline`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/pipeline\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign set\n\nChange a campaign's name, sender pools, send windows, daily email cap, stop-on-reply, start or end. Works until archived; existing conversations keep their assigned sender.\n\n- API: `PATCH /campaigns/{sequenceId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/campaigns/{sequenceId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"emailMailboxAccountIds\": [\n \"<emailMailboxAccountId>\"\n ],\n \"linkedinAccountIds\": [\n \"<linkedinAccountId>\"\n ],\n \"dailySendCap\": 30,\n \"sendSchedules\": [\n {\n \"name\": \"Mon-Fri 9-18\",\n \"timezone\": \"America/Los_Angeles\",\n \"startHour\": 9,\n \"endHour\": 18,\n \"weekdays\": [\n 1,\n 2,\n 3,\n 4,\n 5\n ]\n }\n ]\n }'\n```\n\n### dench campaign steps set\n\nReplace every step of a draft campaign (email, wait, LinkedIn visit, connection request, message, post reaction, InMail, If / else, Wait for them to accept). A workflow (stepModel workflow, or steps with key, next, yesNext or noNext) branches: condition and wait_for_connection steps continue on yesNext or noNext, other steps on next; each points at another step's key or end. Steps are checked first: a field the step type would drop, missing text, {TOKEN} single braces or paths that don't hold together are rejected, not saved. Configure sender pools on the campaign; step sender ids are legacy-only.\n\n- API: `PUT /campaigns/{sequenceId}/steps`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/{sequenceId}/steps\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"stepModel\": \"workflow\",\n \"steps\": [\n {\n \"key\": \"connected\",\n \"type\": \"condition\",\n \"check\": \"linkedin_connected\",\n \"yesNext\": \"message\",\n \"noNext\": \"invite\"\n },\n {\n \"key\": \"invite\",\n \"type\": \"linkedin_connection\",\n \"linkedinMessageBody\": \"Hi {{First name}}, enjoyed your post on {{Topic}}.\",\n \"next\": \"accept\"\n },\n {\n \"key\": \"accept\",\n \"type\": \"wait_for_connection\",\n \"connectionTimeoutHours\": 240,\n \"yesNext\": \"message\",\n \"noNext\": \"email\"\n },\n {\n \"key\": \"email\",\n \"type\": \"email\",\n \"emailSubject\": \"Quick question, {{First name}}\",\n \"emailTextBody\": \"Hi {{First name}}, ...\",\n \"next\": \"end\"\n },\n {\n \"key\": \"message\",\n \"type\": \"linkedin_message\",\n \"linkedinMessageBody\": \"Thanks for connecting, {{First name}}. ...\",\n \"next\": \"end\"\n }\n ]\n }'\n```\n\n### dench campaign steps edit\n\nEdit the text, waits and conditions of a launched (or paused) campaign's steps in place. Each step keeps its id, type and place; pass the stepId and the updatedAt you read, and only the fields you change. A workflow keeps its paths and what each If / else checks (key, next, yesNext, noNext, check, conditionField, conditionOperator); conditionValue and acceptance waits stay editable. Messages already sent or being prepared keep their text; drafts use campaigns.steps.replace.\n\n- API: `PATCH /campaigns/{sequenceId}/steps`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/campaigns/{sequenceId}/steps\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"steps\": [\n {\n \"stepId\": \"<stepId>\",\n \"expectedUpdatedAt\": 1765526400000,\n \"type\": \"email\",\n \"emailSubject\": \"A quicker question, {{First name}}\"\n },\n {\n \"stepId\": \"<waitStepId>\",\n \"expectedUpdatedAt\": 1765526400000,\n \"type\": \"wait\",\n \"waitHours\": 96\n },\n {\n \"stepId\": \"<waitForConnectionStepId>\",\n \"expectedUpdatedAt\": 1765526400000,\n \"type\": \"wait_for_connection\",\n \"connectionTimeoutHours\": 336\n }\n ]\n }'\n```\n\n### dench campaign personalize get\n\nRead a campaign's personalized lines (written for each person): their {{keys}} for steps, instructions and fallbacks, how many people have them, and the cost per person.\n\n- API: `GET /campaigns/{sequenceId}/personalization`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/personalization\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign personalize set\n\nDefine up to 5 personalized lines (each used as {{key}} in steps) and what you sell. Saving starts writing missing lines for up to 100 people, about 3 cents a person; for more it returns needsConfirm and writes nothing until campaigns.personalization.write is confirmed.\n\n- API: `PUT /campaigns/{sequenceId}/personalization`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/{sequenceId}/personalization\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"template\": {\n \"variables\": [\n {\n \"key\": \"companyHook\",\n \"label\": \"Company hook\",\n \"prompt\": \"One sentence about something specific their company does or recently did. 8 to 18 words.\",\n \"fallback\": \"Your team caught my eye.\",\n \"maxChars\": 160\n }\n ],\n \"context\": {\n \"sells\": \"Senior engineers who join your team in your time zone.\"\n }\n }\n }'\n```\n\n### dench campaign personalize clear\n\nTurn off a campaign's personalized lines and cancel the ones not yet written. Refused while a step still uses one of the {{keys}}.\n\n- API: `DELETE /campaigns/{sequenceId}/personalization`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/campaigns/{sequenceId}/personalization\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign personalize write\n\nWrite personalized lines for the people missing them (mode missing) or rewrite everyone's (mode all). Rewriting everyone or more than 100 people returns needsConfirm and the estimate until called with confirmed: true.\n\n- API: `POST /campaigns/{sequenceId}/personalization/write`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/personalization/write\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign personalize edit\n\nSet one person's personalized line by hand; an empty value undoes the edit. Braces are removed and text past the line's length is cut.\n\n- API: `PUT /campaigns/people/{enrollmentId}/personalization`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/personalization\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"key\": \"string\",\n \"value\": \"string\"\n }'\n```\n\n### dench campaign personalize rewrite\n\nWrite a fresh personalized line for one person: one key, or all of their lines when key is left out. About 3 cents.\n\n- API: `POST /campaigns/people/{enrollmentId}/personalization/rewrite`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/personalization/rewrite\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign add\n\nAdd CRM records (up to 100 ids per call) to a campaign; returns how many were added and why others were skipped.\n\n- API: `POST /campaigns/{sequenceId}/people`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/people\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"objectName\": \"lead\",\n \"entryIds\": [\n \"<entryId1>\",\n \"<entryId2>\"\n ]\n }'\n```\n\n### dench campaign add --name\n\nAdd one person by email and/or LinkedIn profile URL.\n\n- API: `POST /campaigns/{sequenceId}/person`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/person\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"displayName\": \"Ada Lovelace\",\n \"email\": \"ada@example.com\",\n \"linkedinProfileUrl\": \"https://linkedin.com/in/ada\"\n }'\n```\n\n### dench campaign preview\n\nShow the message one person gets at one email or LinkedIn step, with their fields and personalized lines filled in: subject, body, sender, recipient, merge fields still missing, warnings, and why the step would be skipped. Nothing is sent, prepared or charged.\n\n- API: `GET /campaigns/{sequenceId}/preview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/preview?enrollmentId=string&stepId=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign launch --check\n\nLaunch readiness without launching: blockers grouped by problem, warnings, and the fingerprint `launch` requires.\n\n- API: `GET /campaigns/{sequenceId}/launch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/launch\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign launch\n\nLaunch a ready draft. Pass the fingerprint from the preview and acknowledge the LinkedIn notice when LinkedIn steps exist.\n\n- API: `POST /campaigns/{sequenceId}/launch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/launch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"fingerprint\": \"<fingerprint from the launch preview>\",\n \"linkedinRiskAcknowledged\": true\n }'\n```\n\n### dench campaign pause\n\nPause an active campaign.\n\n- API: `POST /campaigns/{sequenceId}/pause`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/pause\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign resume\n\nResume a paused campaign.\n\n- API: `POST /campaigns/{sequenceId}/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign archive\n\nArchive a campaign and stop everyone still in flight. This is the app's Delete: campaigns are never erased, and their people, leads and activity stay.\n\n- API: `POST /campaigns/{sequenceId}/archive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench campaign delete`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/archive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign events\n\nThe campaign's activity log, newest first (sent, accepted, replied, skipped, failed, paused, stopped).\n\n- API: `GET /campaigns/{sequenceId}/events`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/events\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign stop\n\nStop one person: nothing more is sent to them from this campaign.\n\n- API: `POST /campaigns/people/{enrollmentId}/stop`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/stop\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign resume-person\n\nResume one paused person in an active campaign.\n\n- API: `POST /campaigns/people/{enrollmentId}/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign person set --email\n\nGive a person in a draft campaign a new or corrected email address; their linked CRM record gets it too. Only before launch; another person in the campaign can't share it.\n\n- API: `PUT /campaigns/people/{enrollmentId}/email`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/email\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"email\": \"string\"\n }'\n```\n\n### dench campaign person set --linkedin-url\n\nGive a person in a draft campaign a new or corrected LinkedIn profile URL; their linked CRM record gets it too. Only before launch.\n\n- API: `PUT /campaigns/people/{enrollmentId}/linkedin`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/linkedin\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"linkedinProfileUrl\": \"string\"\n }'\n```\n\n### dench campaign person set --field\n\nFill or fix one {{merge field}} for a person in a draft campaign, e.g. a missing Company that blocks launch; a matching column on their CRM record is updated too. Only before launch; written personalized lines are not merge fields and can't be set here.\n\n- API: `PUT /campaigns/people/{enrollmentId}/fields`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/fields\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"key\": \"string\",\n \"value\": \"string\"\n }'\n```\n\n### dench campaign resume-person --all\n\nResume every paused person in an active campaign at once, e.g. after a sending account is reconnected. Returns how many were resumed.\n\n- API: `POST /campaigns/{sequenceId}/people/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/people/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sync\n\nFill each unfinished person's empty email, LinkedIn URL, name and merge fields from their linked CRM record, e.g. after enriching the records. Never overwrites a value the campaign already has; returns how many people changed.\n\n- API: `POST /campaigns/{sequenceId}/people/sync`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/people/sync\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign where\n\nThe campaigns a CRM record (a person or a lead) is in, newest first, with the person's status in each and the accounts that send to them.\n\n- API: `GET /campaigns/by-record/{entryId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/by-record/{entryId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign person show\n\nEverything a campaign did for one person, step by step: what was sent (subject and text), whether it was opened or clicked, what was skipped and why, waits, failures and retries.\n\n- API: `GET /campaigns/people/{enrollmentId}/timeline`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/timeline\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign remove\n\nRemove a person who was never contacted from a draft campaign. Frees their place in the 300-person cap and keeps the draft launchable; stop anyone already contacted instead.\n\n- API: `DELETE /campaigns/people/{enrollmentId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/campaigns/people/{enrollmentId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Chat\n\n### dench chat list\n\nList past chat threads.\n\n- API: `GET /chat/threads`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/chat/threads\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench chat search\n\nSearch past chat messages.\n\n- API: `GET /chat/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/chat/search?query=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench chat read\n\nRead a past chat thread.\n\n- API: `GET /chat/threads/{threadId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/chat/threads/{threadId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench chat tree\n\nRead the parent-child chat thread hierarchy.\n\n- API: `GET /chat/tree`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/chat/tree\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench chat rename\n\nRename one or more chat threads.\n\n- API: `PATCH /chat/threads`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/chat/threads\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"items\": [\n {\n \"threadId\": \"th_abc123\",\n \"title\": \"Deploy checklist\"\n }\n ]\n }'\n```\n\n### dench chat delete\n\nDelete one or more chat threads.\n\n- API: `DELETE /chat/threads`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/chat/threads\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"threadIds\": [\n \"th_abc123\"\n ]\n }'\n```\n\n### dench chat new\n\nStart a new chat-turn workflow.\n\n- API: `POST /chat/threads`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench agent new`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/chat/threads\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"prompt\": \"Summarize the latest CRM changes.\"\n }'\n```\n\n### dench chat send\n\nSend a message to an existing chat thread.\n\n- API: `POST /chat/threads/{threadId}/messages`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench agent send`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/chat/threads/{threadId}/messages\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"prompt\": \"string\"\n }'\n```\n\n### dench chat follow\n\nFollow a live chat response stream.\n\n- API: `GET /chat/threads/{threadId}/stream`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench agent follow`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/chat/threads/{threadId}/stream\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Crm\n\n### dench crm objects list [--with-references]\n\nList CRM objects.\n\n- API: `GET /crm/objects`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects list --compact\n\nList names, display labels, visibility and workspace counts without internal state.\n\n- API: `GET /crm/catalog/objects`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/catalog/objects\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects get\n\nGet a CRM object.\n\n- API: `GET /crm/objects/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{name}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects create\n\nCreate a CRM object.\n\n- API: `POST /crm/objects`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"lead\",\n \"description\": \"Sales leads\",\n \"defaultView\": \"kanban\",\n \"icon\": \"target\"\n }'\n```\n\n### dench crm objects update\n\nUpdate a CRM object.\n\n- API: `PATCH /crm/objects/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects rename\n\nRename a CRM object.\n\n- API: `POST /crm/objects/{from}/rename`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{from}/rename\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"to\": \"string\"\n }'\n```\n\n### dench crm objects delete\n\nDelete a CRM object.\n\n- API: `DELETE /crm/objects/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects archive\n\nHide a CRM object's workspace sidebar row for the whole workspace. Not a delete — the table keeps working. Admin-only.\n\n- API: `POST /crm/objects/{name}/archive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{name}/archive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects unarchive\n\nRestore a CRM object's workspace sidebar row. Admin-only.\n\n- API: `POST /crm/objects/{name}/unarchive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{name}/unarchive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views list\n\nList the saved views on a CRM object (plus the active view).\n\n- API: `GET /crm/objects/{objectName}/views`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/views\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views get\n\nGet one saved view's definition by name.\n\n- API: `GET /crm/objects/{objectName}/views/{viewName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views entries\n\nMaterialize a saved view's rows (applies its filters/sort/pins), paginated.\n\n- API: `GET /crm/objects/{objectName}/views/{viewName}/entries`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}/entries\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views create\n\nCreate a saved view (named filters/sort/columns combo) on a CRM object.\n\n- API: `POST /crm/objects/{objectName}/views`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/views\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"view\": {\n \"name\": \"Hot leads\",\n \"view_type\": \"table\",\n \"filters\": {\n \"id\": \"g1\",\n \"conjunction\": \"and\",\n \"rules\": [\n {\n \"id\": \"r1\",\n \"field\": \"Status\",\n \"operator\": \"is\",\n \"value\": \"Hot\"\n }\n ]\n },\n \"sort\": [\n {\n \"field\": \"created_at\",\n \"direction\": \"desc\"\n }\n ]\n },\n \"setActive\": true\n }'\n```\n\n### dench crm views update\n\nReplace a saved view's definition (upsert by name).\n\n- API: `PATCH /crm/objects/{objectName}/views/{viewName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"view\": {\n \"sort\": [\n {\n \"field\": \"Score\",\n \"direction\": \"desc\"\n }\n ],\n \"columns\": [\n \"Name\",\n \"Email\",\n \"Status\",\n \"Score\"\n ]\n }\n }'\n```\n\n### dench crm views rename\n\nRename a saved view in place — keeps its filters, pins, and sidebar slot.\n\n- API: `POST /crm/objects/{objectName}/views/{viewName}/rename`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}/rename\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views delete\n\nDelete a saved view by name (idempotent).\n\n- API: `DELETE /crm/objects/{objectName}/views/{viewName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views archive\n\nMove a pinned view's sidebar row into the Archived flyout. Admin-only.\n\n- API: `POST /crm/objects/{objectName}/views/{viewName}/archive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}/archive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views unarchive\n\nRestore a view's sidebar row (re-asserts its pin). Admin-only.\n\n- API: `POST /crm/objects/{objectName}/views/{viewName}/unarchive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}/unarchive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar list\n\nDescribe the workspace sidebar: Library rows in tree order (with their groups), the home-level Pinned strip, what is hidden and why, and whether the caller is an admin.\n\n- API: `GET /crm/sidebar`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/sidebar\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar move\n\nReposition one Library row (or group) among the Library's top-level slots. Does not add a home-level Pinned tab. Workspace-shared; admin-only.\n\n- API: `POST /crm/sidebar/move`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/move\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"navId\": \"string\",\n \"position\": \"string\"\n }'\n```\n\n### dench crm sidebar group create\n\nCreate a named sidebar group (e.g. \"Hiring\") in the workspace-shared Library. Open to any member.\n\n- API: `POST /crm/sidebar/groups`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/groups\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar group rename\n\nRename a sidebar group. Open to any member.\n\n- API: `POST /crm/sidebar/groups/rename`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/groups/rename\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar group delete\n\nDissolve a sidebar group; its rows return to the top level in its slot. Open to any member.\n\n- API: `POST /crm/sidebar/groups/delete`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/groups/delete\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar group add\n\nMove a sidebar row into a group (groupId set) or back to the top level (groupId null). Open to any member.\n\n- API: `POST /crm/sidebar/groups/move`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench crm sidebar group remove`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/groups/move\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar pin\n\nPin (pinned true) or unpin a Library row — or a whole group — on the home-level Pinned shortcut strip (the \"tab on the left\"). Does not move the row inside Library. Workspace-shared; open to any member.\n\n- API: `POST /crm/sidebar/pins`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench crm sidebar unpin`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/pins\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields list\n\nList fields for a CRM object, including read-only calculation metadata.\n\n- API: `GET /crm/objects/{objectName}/fields`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/fields\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields list --compact\n\nList field names, types and effective constraints without indexing or enrichment internals.\n\n- API: `GET /crm/catalog/objects/{objectName}/fields`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/catalog/objects/{objectName}/fields\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields create\n\nCreate a CRM field or read-only campaign activity boolean column.\n\n- API: `POST /crm/objects/{objectName}/fields`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Status\",\n \"type\": \"enum\",\n \"enumValues\": [\n \"New\",\n \"Working\",\n \"Qualified\",\n \"Lost\"\n ],\n \"enumColors\": [\n \"#94a3b8\",\n \"#3b82f6\",\n \"#22c55e\",\n \"#ef4444\"\n ],\n \"indexed\": true\n }'\n```\n\n### dench crm fields update\n\nUpdate a CRM field or change/explicitly clear an existing campaign calculation.\n\n- API: `PATCH /crm/objects/{objectName}/fields/{fieldName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields delete\n\nDelete a CRM field.\n\n- API: `DELETE /crm/objects/{objectName}/fields/{fieldName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields reorder\n\nReorder CRM fields.\n\n- API: `POST /crm/objects/{objectName}/fields/reorder`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields/reorder\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"orderedFieldNames\": []\n }'\n```\n\n### dench crm fields enum-reorder\n\nReorder enum values.\n\n- API: `POST /crm/objects/{objectName}/fields/{fieldName}/enum/reorder`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}/enum/reorder\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"orderedValues\": []\n }'\n```\n\n### dench crm fields enum-add\n\nAdd an enum value.\n\n- API: `POST /crm/objects/{objectName}/fields/{fieldName}/enum`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}/enum\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"value\": \"Nurturing\",\n \"color\": \"#eab308\",\n \"position\": 2\n }'\n```\n\n### dench crm fields enum-remove\n\nRemove an enum value.\n\n- API: `DELETE /crm/objects/{objectName}/fields/{fieldName}/enum/{value}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}/enum/{value}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields enum-rename\n\nRename an enum value.\n\n- API: `POST /crm/objects/{objectName}/fields/{fieldName}/enum/{oldValue}/rename`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}/enum/{oldValue}/rename\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"newValue\": \"string\"\n }'\n```\n\n### dench crm fields enum-set-color\n\nSet an enum color.\n\n- API: `POST /crm/objects/{objectName}/fields/{fieldName}/enum/{value}/color`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}/enum/{value}/color\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"color\": \"#22c55e\"\n }'\n```\n\n### dench crm entries list [--with-references]\n\nList CRM entries.\n\n- API: `GET /crm/objects/{objectName}/entries`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries get\n\nGet a CRM entry.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries sync-history\n\nQueue a full, paged pull of the record's email history from every connected mailbox; the ledger fills as pages land.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/sync-history`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/sync-history\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries sync-history --status\n\nHas Dench read this record's email history? One row per address per mailbox.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/sync-history`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/sync-history\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries dossier\n\nStatus of the account's research dossier — the delimited `dench:dossier` section Dench keeps in the record's Notes: status, when it was written, how many dated updates followed, the last error.\n\n- API: `GET /crm/entries/{entryId}/dossier`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/entries/{entryId}/dossier\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries dossier --regenerate\n\nResearch the account again and append a fresh dossier section to its Notes (needs a Website / Domain on the record).\n\n- API: `POST /crm/entries/{entryId}/dossier/regenerate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/entries/{entryId}/dossier/regenerate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm privacy status\n\nWhether the caller hides their own emails / messages with this record from the workspace (directly, or through its account), and whether they own a connection the toggle applies to.\n\n- API: `GET /crm/entries/{entryId}/privacy`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/entries/{entryId}/privacy\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm privacy hide|show\n\nHide (`hidden: true`) or show the caller's own emails / messages with this record to the workspace. An account covers every contact and opportunity linked to it; existing ledger rows are restamped and the shared Brief regenerates.\n\n- API: `PUT /crm/entries/{entryId}/privacy`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/entries/{entryId}/privacy\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"hidden\": true\n }'\n```\n\n### dench crm detections list\n\nList account-detection verdicts — why a domain (or personal address) did or did not become an account: verdict, counterparty type, probabilities, evidence threads, the rows created. `kind` picks the creator: `detections` (email + sweep), `linkedin` (the LinkedIn resolver's rows) or `all` (default). Newest first.\n\n- API: `GET /crm/detections`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/detections\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm detections undo\n\nUndo what the ingestion jobs created since a timestamp (admin): `kind` = `detections` (accounts + contacts from the email detector and the sweep), `linkedin` (the LinkedIn resolver's contacts + accounts; their conversations are unlinked and parked), `email-tasks` (auto-created tasks and cases) or `all` (default). Deletes only rows no human has touched and marks the verdicts / decisions rolled_back so they are never re-created. `dryRun` lists what would go; per-kind counts in `kinds`.\n\n- API: `POST /crm/detections/undo`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/detections/undo\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"since\": 0\n }'\n```\n\n### dench crm history\n\nList a CRM entry's audit history.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/history`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/history\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm activity\n\nList a CRM entry's activity ledger (comments, notes, field changes, emails, meetings, Slack, LinkedIn) in one timeline, newest first by default.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/activity`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/activity\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm brief\n\nThe record's generated Brief: health, who owes the next move, open threads, commitments, risks, next step. Read this before the ledger.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/brief`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/brief\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm context\n\nRead-only source diagnostics: accessible evidence, association reasons, last Brief source manifest, generation queue, and your mailbox delivery health. Bounded, cursor-paged snapshot; does not certify complete history.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/context`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/context\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm brief --regenerate\n\nRebuild a record's Brief from the current timeline.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/brief/regenerate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/brief/regenerate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm activity\n\nBounded per-source counts of a CRM entry's activity ledger.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/activity/count`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/activity/count\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm notes list\n\nList a CRM entry's notes (titled, document-style comments), newest first.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/notes`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/notes\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm notes create\n\nAdd a titled note to a CRM entry's activity timeline (markdown body). Research goes here, never into the Notes document.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/notes`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/notes\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm comments list\n\nList comments on a CRM entry (roots newest first, with preview replies).\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/comments`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/comments\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm comments replies\n\nList every reply under a root comment, oldest first.\n\n- API: `GET /crm/comments/{commentId}/replies`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/comments/{commentId}/replies\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm comments get\n\nGet one comment with its entry label.\n\n- API: `GET /crm/comments/{commentId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/comments/{commentId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm comments create\n\nComment on a CRM entry (markdown). Mention members with [@Name](/?member=<userId>); mention Dench with [@Dench](/?member=dench) or mentionDench.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/comments`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/comments\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"body\": \"Kickoff went well — [@Bob](/?member=user_bob) can you send the proposal? [@Dench](/?member=dench) what's the ARR here?\"\n }'\n```\n\n### dench crm comments update\n\nEdit a comment you wrote.\n\n- API: `PATCH /crm/comments/{commentId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/comments/{commentId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"body\": \"Kickoff went well — proposal sent.\"\n }'\n```\n\n### dench crm comments delete\n\nDelete a comment (kept as a tombstone when it has replies).\n\n- API: `DELETE /crm/comments/{commentId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/comments/{commentId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm comments react\n\nToggle an emoji reaction on a comment.\n\n- API: `PUT /crm/comments/{commentId}/reactions/{emoji}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/comments/{commentId}/reactions/{emoji}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm watch status\n\nWhether you follow a CRM entry's activity.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/watch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/watch\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm watch\n\nFollow or unfollow a CRM entry's activity.\n\n- API: `PUT /crm/objects/{objectName}/entries/{entryId}/watch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/watch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"watching\": true\n }'\n```\n\n### dench crm tasks mine --page\n\nPage assigned tasks in priority order (or completed tasks by recency).\n\n- API: `POST /crm/tasks/assigned/page`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/assigned/page\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks list --page\n\nPage all tasks linked to a record, including subtasks.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/tasks/page`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/tasks/page\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks prepare\n\nStart or resume preparation of exact task ordering and progress.\n\n- API: `POST /crm/tasks/prepare`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/prepare\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks mine\n\nYour open tasks (plus ones completed today).\n\n- API: `GET /crm/tasks/mine`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/tasks/mine\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks list\n\nTasks linked to a CRM entry.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/tasks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/tasks\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks create\n\nCreate a task linked to a CRM entry.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/tasks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/tasks\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Send proposal\",\n \"assigneeUserId\": \"user_bob\",\n \"dueDateKey\": \"2026-09-05\"\n }'\n```\n\n### dench crm tasks complete\n\nMark a task done.\n\n- API: `POST /crm/tasks/{entryId}/complete`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/complete\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks reopen\n\nReopen a completed task.\n\n- API: `POST /crm/tasks/{entryId}/reopen`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/reopen\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks priority\n\nSet or clear a task's priority.\n\n- API: `PUT /crm/tasks/{entryId}/priority`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/tasks/{entryId}/priority\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"priority\": \"string\"\n }'\n```\n\n### dench crm tasks subtasks\n\nA task's subtasks.\n\n- API: `GET /crm/tasks/{entryId}/subtasks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/tasks/{entryId}/subtasks\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks create-subtask\n\nCreate a subtask under a task (inherits the parent's record relations).\n\n- API: `POST /crm/tasks/{entryId}/subtasks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/subtasks\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"string\"\n }'\n```\n\n### dench crm tasks parent\n\nNest a task under a parent, or promote it (parentEntryId: null).\n\n- API: `PUT /crm/tasks/{entryId}/parent`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/tasks/{entryId}/parent\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"parentEntryId\": \"string\"\n }'\n```\n\n### dench crm tasks delete\n\nDelete a task and its subtasks, or keep them as tasks.\n\n- API: `DELETE /crm/tasks/{entryId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/tasks/{entryId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat\n\nHow a task repeats (rule, RRULE, trigger, ends, next due).\n\n- API: `GET /crm/tasks/{entryId}/repeat`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat\n\nMake a task repeat, or change how it repeats (JSON rule or RRULE). An undated task gets its due date anchored on the first matching day from today.\n\n- API: `PUT /crm/tasks/{entryId}/repeat`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat --off\n\nStop a task repeating (past occurrences are kept).\n\n- API: `DELETE /crm/tasks/{entryId}/repeat`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat --skip\n\nSkip the current occurrence: the next one is created now.\n\n- API: `POST /crm/tasks/{entryId}/repeat/skip`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat/skip\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat --pause\n\nPause a repeating task.\n\n- API: `POST /crm/tasks/{entryId}/repeat/pause`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat/pause\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat --resume\n\nResume a paused repeating task.\n\n- API: `POST /crm/tasks/{entryId}/repeat/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks series\n\nEvery repeating-task series in the workspace.\n\n- API: `GET /crm/tasks/series`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/tasks/series\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks series <seriesId> --occurrences\n\nEvery occurrence (task) of one series.\n\n- API: `GET /crm/tasks/series/{seriesId}/occurrences`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/tasks/series/{seriesId}/occurrences\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries create\n\nCreate a CRM entry.\n\n- API: `POST /crm/objects/{objectName}/entries`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"data\": {\n \"Name\": \"Joint review\",\n \"Assignee\": [\n \"user_kumar\",\n \"user_mark\"\n ],\n \"Status\": \"New\"\n }\n }'\n```\n\n### dench crm entries create-many\n\nCreate many CRM entries.\n\n- API: `POST /crm/objects/{objectName}/entries/batch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/batch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"entries\": [\n {\n \"Name\": \"Jane\",\n \"Email\": \"jane@example.com\"\n },\n {\n \"Name\": \"Bob\",\n \"Email\": \"bob@example.com\"\n }\n ]\n }'\n```\n\n### dench crm entries update\n\nUpdate a CRM entry.\n\n- API: `PATCH /crm/objects/{objectName}/entries/{entryId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"data\": {}\n }'\n```\n\n### dench crm entries update-many\n\nUpdate many CRM entries.\n\n- API: `PATCH /crm/objects/{objectName}/entries/batch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{objectName}/entries/batch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"updates\": []\n }'\n```\n\n### dench crm entries delete\n\nDelete a CRM entry.\n\n- API: `DELETE /crm/objects/{objectName}/entries/{entryId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries bulk-delete\n\nBulk delete CRM entries.\n\n- API: `POST /crm/objects/{objectName}/entries/delete`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/delete\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"entryIds\": []\n }'\n```\n\n### dench crm cells get\n\nGet a CRM cell value.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm cells set\n\nSet a CRM cell value.\n\n- API: `PUT /crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"value\": [\n \"user_kumar\",\n \"user_mark\"\n ]\n }'\n```\n\n### dench crm cells set-many\n\nSet many CRM cell values.\n\n- API: `POST /crm/cells/batch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/cells/batch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"cells\": []\n }'\n```\n\n### dench crm cells append\n\nAppend to a CRM cell.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}/append`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}/append\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"value\": \"value\"\n }'\n```\n\n### dench crm query [--with-references]\n\nQuery CRM entries.\n\n- API: `POST /crm/query`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/query\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"lead\",\n \"dslJson\": \"{\\\"filter\\\":{\\\"Status\\\":\\\"Qualified\\\",\\\"Score\\\":{\\\"$gt\\\":50}},\\\"sort\\\":\\\"-Score\\\",\\\"limit\\\":50}\"\n }'\n```\n\n### dench crm query --page\n\nScan CRM entries with a resumable cursor. Empty filtered pages can have more results.\n\n- API: `POST /crm/query/page`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/query/page\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"paginationOpts\": {}\n }'\n```\n\n### dench crm sql\n\nRun CRM SQL-compatible query.\n\n- API: `POST /crm/sql`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sql\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\"\n }'\n```\n\n### dench crm aggregate\n\nAggregate CRM entries.\n\n- API: `POST /crm/aggregate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/aggregate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"fieldName\": \"string\"\n }'\n```\n\n### dench crm search [--with-references]\n\nSearch CRM entries.\n\n- API: `GET /crm/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/search?text=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm search --page\n\nSearch bounded pages of readable CRM entries, optionally projecting cells. Always follow continueCursor until isDone.\n\n- API: `GET /crm/search/page`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/search/page?text=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm statuses list\n\nList CRM statuses.\n\n- API: `GET /crm/objects/{objectName}/statuses`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/statuses\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm statuses set\n\nSet CRM statuses.\n\n- API: `PUT /crm/objects/{objectName}/statuses`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/objects/{objectName}/statuses\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"statuses\": [\n {\n \"name\": \"New\",\n \"color\": \"#94a3b8\"\n },\n {\n \"name\": \"Working\",\n \"color\": \"#3b82f6\"\n },\n {\n \"name\": \"Qualified\",\n \"color\": \"#22c55e\",\n \"isDefault\": true\n }\n ]\n }'\n```\n\n### dench crm batch\n\nApply a CRM batch.\n\n- API: `POST /crm/batch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/batch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"ops\": [\n {\n \"type\": \"entries.create\",\n \"objectName\": \"people\",\n \"data\": {\n \"Name\": \"Jane\"\n }\n }\n ],\n \"idempotencyKey\": \"import-2026-06-01\"\n }'\n```\n\n### dench crm transaction begin\n\nBegin a CRM transaction.\n\n- API: `POST /crm/transactions`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/transactions\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm transaction add\n\nAdd an operation to a CRM transaction.\n\n- API: `POST /crm/transactions/{txnId}/operations`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/transactions/{txnId}/operations\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"op\": {\n \"type\": \"entries.update\",\n \"entryId\": \"ent_lead99\",\n \"data\": {\n \"Status\": \"Qualified\"\n }\n }\n }'\n```\n\n### dench crm transaction commit\n\nCommit a CRM transaction.\n\n- API: `POST /crm/transactions/{txnId}/commit`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/transactions/{txnId}/commit\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm transaction abort\n\nAbort a CRM transaction.\n\n- API: `POST /crm/transactions/{txnId}/abort`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/transactions/{txnId}/abort\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm transaction inspect\n\nInspect a CRM transaction.\n\n- API: `GET /crm/transactions/{txnId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/transactions/{txnId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm docs list\n\nList CRM documents.\n\n- API: `GET /crm/docs`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/docs\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm docs create\n\nCreate a CRM document.\n\n- API: `POST /crm/docs`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/docs\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"title\": \"string\",\n \"filePath\": \"string\"\n }'\n```\n\n### dench crm docs link\n\nLink a CRM document.\n\n- API: `POST /crm/docs/link`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/docs/link\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"filePath\": \"string\"\n }'\n```\n\n### dench crm actions list\n\nList CRM actions.\n\n- API: `GET /crm/actions`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/actions?entryId=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm actions create\n\nCreate or upsert an action button on a named action column (fieldName is the column header; a column can hold multiple buttons — reuse fieldName to add more).\n\n- API: `POST /crm/actions`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/actions\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"fieldName\": \"string\"\n }'\n```\n\n### dench crm actions edit\n\nUpdate an action button on a CRM field.\n\n- API: `PATCH /crm/actions/{actionId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/actions/{actionId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"fieldName\": \"string\"\n }'\n```\n\n### dench crm actions delete\n\nDelete an action button from a CRM field.\n\n- API: `DELETE /crm/actions/{actionId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/actions/{actionId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\"\n }'\n```\n\n### dench crm actions run\n\nRun a CRM action on one or more entries.\n\n- API: `POST /crm/actions/{actionId}/runs`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/actions/{actionId}/runs\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"fieldId\": \"string\",\n \"entryIds\": []\n }'\n```\n\n### dench members list\n\nList workspace members for CRM user fields.\n\n- API: `GET /members`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/members\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm reports generate\n\nGenerate a CRM report.\n\n- API: `POST /crm/reports`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/reports\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"type\": \"pie\",\n \"groupByField\": \"string\"\n }'\n```\n\n### dench crm analytics get\n\nRead an object's analytics dashboard: panels, field roles, the strip's collapsed flag, the named view's own dashboard (if any), and the fields panels may bucket on (synthetic $createdAt / $location last).\n\n- API: `GET /crm/objects/{objectName}/analytics`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/analytics\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics compute\n\nCompute chart-ready results (buckets / series / values) for the stored dashboard, a subset of its panels, or ad-hoc panel definitions — optionally scoped to a saved view, a period preset (with the previous interval as previousValue) and extra filters. Same query the strip renders from.\n\n- API: `POST /crm/objects/{objectName}/analytics/compute`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/compute\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"period\": \"this_month\",\n \"panels\": [\n {\n \"id\": \"adhoc:leads-by-source\",\n \"title\": \"New leads by source\",\n \"type\": \"donut\",\n \"metric\": \"count\",\n \"groupBy\": \"Source\",\n \"sortOrder\": 0\n }\n ]\n }'\n```\n\n### dench crm analytics save\n\nCreate or update one panel (upsert by id). With viewName the write lands on that saved view's own dashboard, forking a copy if it was still inheriting the object's.\n\n- API: `PUT /crm/objects/{objectName}/analytics/panels/{panelId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"panel\": {\n \"title\": \"Open pipeline\",\n \"type\": \"stat\",\n \"metric\": \"sum\",\n \"derived\": \"open_pipeline\",\n \"sortOrder\": 10\n }\n }'\n```\n\n### dench crm analytics update\n\nEdit part of one stored panel: only the keys in `patch` change (title, type, metric, metricField, groupBy, dateField, dateBucket, filters, derived, span, hidden, sortOrder); null clears an optional key. What the card's ⋮ menu writes.\n\n- API: `PATCH /crm/objects/{objectName}/analytics/panels/{panelId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"patch\": {}\n }'\n```\n\n### dench crm analytics hide\n\nTake a chart off the strip above the table (hidden: true). It stays in the full analytics view, counted by the strip's “+N more”.\n\n- API: `POST /crm/objects/{objectName}/analytics/panels/{panelId}/hide`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}/hide\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics show\n\nBring a hidden chart back onto the strip (hidden: false).\n\n- API: `POST /crm/objects/{objectName}/analytics/panels/{panelId}/show`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}/show\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics resize\n\nSet a card's width on the 6-track dashboard grid: span 2 (third), 3 (half), 4 (two thirds), 6 (full), or null for the chart kind's default.\n\n- API: `POST /crm/objects/{objectName}/analytics/panels/{panelId}/resize`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}/resize\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"span\": 0\n }'\n```\n\n### dench crm analytics delete\n\nDelete one panel (idempotent). Template panels are tombstoned so a re-install never resurrects them.\n\n- API: `DELETE /crm/objects/{objectName}/analytics/panels/{panelId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics reorder\n\nPersist the full panel order. panelIds must name every stored panel of the targeted dashboard.\n\n- API: `POST /crm/objects/{objectName}/analytics/reorder`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/reorder\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"panelIds\": [\n \"tpl:sales:total-leads\",\n \"tpl:sales:leads-by-source\"\n ]\n }'\n```\n\n### dench crm analytics roles\n\nSet the object's analytics setup — the field roles shared by every chart and view (amount, stage, won/lost/converted values, stageProbabilities, closeDate, recurrence, owner, location). Replaces the mapping; with merge: true only the keys given change and null clears one.\n\n- API: `PUT /crm/objects/{objectName}/analytics/roles`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/roles\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"fieldRoles\": {\n \"amount\": \"Amount\",\n \"stage\": \"Stage\",\n \"wonValues\": [\n \"Closed Won\"\n ],\n \"lostValues\": [\n \"Closed Lost\"\n ],\n \"closeDate\": \"Close Date\",\n \"owner\": \"Owner\",\n \"location\": \"Account.HQ Location\",\n \"recurrence\": \"annual\"\n }\n }'\n```\n\n### dench crm analytics collapse\n\nCollapse the analytics strip above the object's table (team-shared, like saved views).\n\n- API: `POST /crm/objects/{objectName}/analytics/collapse`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/collapse\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics expand\n\nExpand the analytics strip above the object's table.\n\n- API: `POST /crm/objects/{objectName}/analytics/expand`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/expand\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics scope\n\nGive a saved view its own dashboard (mode \"own\": starts as a copy of the object's panels) or hand it back to the object's shared one (mode \"shared\").\n\n- API: `POST /crm/objects/{objectName}/views/{viewName}/analytics/scope`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}/analytics/scope\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"mode\": \"own\"\n }'\n```\n\n### dench crm enrich cell\n\nRequest enrichment for one CRM cell.\n\n- API: `POST /crm/enrich/cell`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/enrich/cell\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"entryId\": \"string\",\n \"fieldName\": \"string\"\n }'\n```\n\n### dench crm enrich object\n\nRequest enrichment for a CRM object.\n\n- API: `POST /crm/enrich/object`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/enrich/object\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"fieldName\": \"string\"\n }'\n```\n\n### dench crm people search\n\nSearch for people through the enrichment gateway. `companyDomains` takes up to 1000 domains (e.g. a resolved company list; `dench leads find --company-list <id|view>` resolves one for you) — the gateway fans large lists out as sequential vendor-safe chunks behind one `nextPageToken` stream.\n\n- API: `POST /enrichment/people/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/people/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"titles\": [\n \"Head of Sales\"\n ],\n \"industries\": [\n \"SaaS\"\n ],\n \"companyDomains\": [\n \"acme.com\",\n \"globex.com\"\n ],\n \"limit\": 10\n }'\n```\n\n### dench crm companies search\n\nSearch for companies through the enrichment gateway (also `dench companies find`).\n\n- API: `POST /enrichment/company/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench companies find`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/company/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"domain\": \"example.com\"\n }'\n```\n\n### dench jobs find\n\nSearch job postings through Dench find. `companyDomains` takes up to 1000 domains (chunked automatically); `dench jobs find --company-list <id|view>` resolves a saved company list into it.\n\n- API: `POST /enrichment/jobs/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/jobs/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"titles\": [\n \"Account Executive\"\n ],\n \"locations\": [\n \"San Francisco\"\n ],\n \"companyDomains\": [\n \"acme.com\",\n \"globex.com\"\n ],\n \"limit\": 50\n }'\n```\n\n### dench crm enrich cell\n\nLook up one person profile.\n\n- API: `POST /enrichment/person`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/person\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"linkedinURL\": \"https://www.linkedin.com/in/janedoe\"\n }'\n```\n\n### dench crm enrich cell\n\nLook up one company profile.\n\n- API: `POST /enrichment/company`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/company\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"website\": \"acme.com\"\n }'\n```\n\n### dench crm enrich cell\n\nLook up verified emails and phones for people.\n\n- API: `POST /enrichment/person/contact`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/person/contact\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"contacts\": [\n {\n \"linkedinUrl\": \"https://www.linkedin.com/in/janedoe\"\n }\n ]\n }'\n```\n\n### dench crm enrich profiles\n\nLook up up to 100 people or company profiles without buying emails or phones. Pass kind (people|companies) and lookups; results preserve inputIndex. People require linkedinUrl or email; companies require domain or linkedinUrl.\n\n- API: `POST /enrichment/profiles/bulk`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/profiles/bulk\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"kind\": \"companies\",\n \"lookups\": [\n {\n \"domain\": \"acme.com\"\n }\n ]\n }'\n```\n\n### dench companies related\n\nRead company employees, founders, funding, investors, acquisitions, or investments. Pass domain or linkedinUrl, kind, limit (1–100), and optional pageToken. Does not import CRM records or buy contacts.\n\n- API: `POST /enrichment/company/related`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/company/related\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"domain\": \"acme.com\",\n \"kind\": \"founders\",\n \"limit\": 10\n }'\n```\n\n### dench leads find --limit 1\n\nPreview how many records a find would return.\n\n- API: `POST /enrichment/search/preview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/search/preview\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"kind\": \"people\",\n \"titles\": [\n \"VP Sales\"\n ]\n }'\n```\n\n### dench leads filters\n\nList Lead Finder filter vocabularies: exact enum values (seniorities, functions, industries, headcount, company types, languages) and curated suggestions (titles, locations, company HQ, universities, skills, keywords).\n\n- API: `GET /local/enrichment/filter-options`\n- Auth: No bearer token required.\n\n```bash\n# dench leads filters\n# Local-only: Catalogs are bundled with the CLI. Over HTTPS, fetch https://dench.com/references/find-filter-options.json instead.\n```\n\n### dench crm templates list\n\nList one-click CRM templates (objects + automations + sample rows) with per-workspace installed flags.\n\n- API: `GET /crm/templates`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/templates\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm templates install\n\nInstall a CRM template. Idempotent: re-installs top up missing pieces and never duplicate objects, automations, or sample rows.\n\n- API: `POST /crm/templates/{templateId}/install`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/templates/{templateId}/install\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm templates remove-sample-data\n\nDelete a CRM template's sample rows (tagged \"Sample\"); schema, views, and automations stay.\n\n- API: `POST /crm/templates/{templateId}/remove-sample-data`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/templates/{templateId}/remove-sample-data\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm automations list\n\nList deterministic CRM automations (rules that fire inside entry writes, e.g. qualified prospect → opportunity).\n\n- API: `GET /crm/automations`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/automations\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm automations enable|disable\n\nEnable or disable a CRM automation.\n\n- API: `PATCH /crm/automations/{automationId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/automations/{automationId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Email\n\n### dench email identity verify\n\nStart Dench Emailing Service sender verification.\n\n- API: `POST /email/identities/verify`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/identities/verify\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"type\": \"email\",\n \"identity\": \"founder@example.com\"\n }'\n```\n\n### dench email identity verify\n\nCreate a durable Dench email sending identity record.\n\n- API: `POST /email/sending-identities`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sending-identities\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"type\": \"domain\",\n \"domain\": \"example.com\",\n \"fromEmail\": \"founder@example.com\",\n \"fromName\": \"Ada at Example\"\n }'\n```\n\n### dench email identity status --identity-id\n\nRefresh a Dench Emailing Service sender verification status.\n\n- API: `POST /email/sending-identities/{identityId}/status`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sending-identities/{identityId}/status\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity verify\n\nBegin the full Dench sender verification flow for a sending identity.\n\n- API: `POST /email/sending-identities/{identityId}/verify`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sending-identities/{identityId}/verify\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity status\n\nRead Dench Emailing Service sender verification status.\n\n- API: `GET /email/identities/{identity}/status`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/identities/{identity}/status\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity list\n\nList the workspace's email sending identities.\n\n- API: `GET /email/sending-identities`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/sending-identities\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity dns\n\nFetch DNS records (DKIM/SPF/DMARC) for a pending domain sender verification.\n\n- API: `GET /email/sending-identities/{identityId}/dns`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/sending-identities/{identityId}/dns\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity disable\n\nSoft-disable a sender (or every sender on a domain) for the workspace; sends are blocked until restored.\n\n- API: `POST /email/sending-identities/{identity}/disable`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sending-identities/{identity}/disable\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity restore\n\nRestore a previously disabled sender for the workspace.\n\n- API: `POST /email/sending-identities/{identity}/restore`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sending-identities/{identity}/restore\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity delete\n\nPermanently delete a sender (or every sender on a domain) from the workspace; re-adding it requires verification from scratch.\n\n- API: `DELETE /email/sending-identities/{identity}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/email/sending-identities/{identity}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email inbox search\n\nSearch authorized synced mailbox headers with bounded cursor pagination. isDone covers stored records, not provider completeness.\n\n- API: `GET /email/inbox/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/inbox/search\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email inbox thread\n\nRead a bounded page of synced headers using an exact thread handle from inbox search; bodies remain on demand.\n\n- API: `GET /email/inbox/threads/{threadHandle}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/inbox/threads/{threadHandle}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email inbox message\n\nRead a bounded stored body using an exact message handle from inbox search; rechecks mailbox and record privacy.\n\n- API: `GET /email/inbox/messages/{messageHandle}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/inbox/messages/{messageHandle}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email draft create\n\nCreate an editable Dench email draft and synchronize its selected native mailbox asynchronously. Use a stable requestId for retries.\n\n- API: `POST /email/drafts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/drafts\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"requestId\": \"string\"\n }'\n```\n\n### dench email draft show\n\nRead an email draft, eligible senders and provider sync status.\n\n- API: `GET /email/drafts/{draftId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/drafts/{draftId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email draft senders\n\nList native mailboxes this caller may use.\n\n- API: `GET /email/drafts/senders`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/drafts/senders\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email draft update\n\nSave draft content using expectedRevision; sender changes require a new draft after provider binding.\n\n- API: `PATCH /email/drafts/{draftId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/email/drafts/{draftId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"expectedRevision\": 0,\n \"patch\": {}\n }'\n```\n\n### dench email draft send\n\nSend the current Dench draft revision through its native mailbox. Repeated requests share a durable receipt.\n\n- API: `POST /email/drafts/{draftId}/send`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/drafts/{draftId}/send\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"expectedRevision\": 0\n }'\n```\n\n### dench email draft attach\n\nUpload attachment bytes authorized against this draft before adding its storage reference.\n\n- API: `POST /email/drafts/{draftId}/attachments`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/drafts/{draftId}/attachments\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"string\",\n \"contentType\": \"string\",\n \"contentBase64\": \"string\"\n }'\n```\n\n### dench email draft signature\n\nLoad the selected mailbox signature for explicit visible insertion.\n\n- API: `GET /email/drafts/{draftId}/signature`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/drafts/{draftId}/signature\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email send [--mailbox <id/email>]\n\nSend through a native Gmail or Outlook mailbox with a durable request receipt. Only use for an explicit send request.\n\n- API: `POST /email/native/send`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/native/send\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"requestId\": \"send-intro-001\",\n \"to\": [\n {\n \"email\": \"ada@example.com\",\n \"name\": \"Ada\"\n }\n ],\n \"subject\": \"Introduction\",\n \"textBody\": \"Hello Ada\"\n }'\n```\n\n### dench email send --from <verified-email>\n\nSend one raw email (no campaign): to/cc/bcc, custom from-name and reply-to, optional reply threading via replyToMessageId.\n\n- API: `POST /email/send`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/send\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"fromEmail\": \"founder@example.com\",\n \"to\": [\n {\n \"email\": \"ada@lovelace.dev\",\n \"name\": \"Ada\"\n }\n ],\n \"subject\": \"Quick intro\",\n \"htmlBody\": \"<p>Hi Ada — great meeting you!</p>\"\n }'\n```\n\n### dench email message status\n\nRead a raw email message's status and open/click counters.\n\n- API: `GET /email/messages/{messageId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/messages/{messageId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email message list\n\nList recent raw email messages for the workspace.\n\n- API: `GET /email/messages`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/messages\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email template create\n\nCreate a managed email campaign template.\n\n- API: `POST /email/templates`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/templates\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Intro outreach\",\n \"subject\": \"Hi {{firstName}}\",\n \"htmlBody\": \"<p>Hi {{firstName}}, saw your work at {{company}}.</p>\"\n }'\n```\n\n### dench email template preview\n\nPreview a managed email campaign template.\n\n- API: `POST /email/templates/{templateId}/preview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/templates/{templateId}/preview\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"data\": {\n \"firstName\": \"Ada\",\n \"company\": \"Lovelace Labs\"\n }\n }'\n```\n\n### dench email campaign create\n\nCreate a managed email campaign draft from a connected inbox or verified sender.\n\n- API: `POST /email/campaigns`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Q2 outreach\",\n \"identityId\": \"founder@example.com\",\n \"templateId\": \"etpl_abc123\"\n }'\n```\n\n### dench email campaign status\n\nRead campaign status and counters.\n\n- API: `GET /email/campaigns/{campaignId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/campaigns/{campaignId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign recipients add\n\nAdd recipients to a managed email campaign.\n\n- API: `POST /email/campaigns/{campaignId}/recipients`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/recipients\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"recipients\": [\n {\n \"email\": \"ada@lovelace.dev\",\n \"displayName\": \"Ada Lovelace\",\n \"personalization\": {\n \"firstName\": \"Ada\",\n \"company\": \"Lovelace Labs\"\n }\n }\n ]\n }'\n```\n\n### dench email campaign preview\n\nPreview rendered messages for a campaign sample.\n\n- API: `POST /email/campaigns/{campaignId}/preview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/preview\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sample\": 5\n }'\n```\n\n### dench email campaign submit\n\nSubmit a campaign for approval or sending.\n\n- API: `POST /email/campaigns/{campaignId}/submit`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/submit\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign pause\n\nPause a sending email campaign.\n\n- API: `POST /email/campaigns/{campaignId}/pause`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/pause\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign resume\n\nResume a paused email campaign.\n\n- API: `POST /email/campaigns/{campaignId}/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign cancel\n\nCancel an email campaign.\n\n- API: `POST /email/campaigns/{campaignId}/cancel`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/cancel\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign list\n\nList managed email campaigns (paginated, optional status filter).\n\n- API: `GET /email/campaigns`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/campaigns\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign recipients list\n\nList a campaign's recipients (paginated, optional status filter).\n\n- API: `GET /email/campaigns/{campaignId}/recipients`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/campaigns/{campaignId}/recipients\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign recipients add-from-object\n\nAdd campaign recipients from a CRM object: pick the object, the email field, and the entry ids.\n\n- API: `POST /email/campaigns/{campaignId}/recipients/from-object`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/recipients/from-object\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence create\n\nCreate a follow-up sequence from a connected inbox or verified sender.\n\n- API: `POST /email/sequences`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence update\n\nUpdate a sequence's name, sender, or reply/stop settings.\n\n- API: `POST /email/sequences/{sequenceId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence activate\n\nActivate a sequence so its enrollments begin sending.\n\n- API: `POST /email/sequences/{sequenceId}/activate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/activate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence deactivate\n\nDeactivate a sequence (pause sending, revert to draft).\n\n- API: `POST /email/sequences/{sequenceId}/deactivate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/deactivate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence archive\n\nArchive a sequence (stops all sending).\n\n- API: `POST /email/sequences/{sequenceId}/archive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/archive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence list\n\nList the workspace's follow-up sequences.\n\n- API: `GET /email/sequences`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/sequences\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence status\n\nRead a sequence with its ordered steps.\n\n- API: `GET /email/sequences/{sequenceId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/sequences/{sequenceId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence steps add\n\nAdd a step (subject, body, and wait delay) to a sequence.\n\n- API: `POST /email/sequences/{sequenceId}/steps`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/steps\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence steps update\n\nUpdate a sequence step's subject, body, or delay.\n\n- API: `POST /email/sequences/steps/{stepId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/steps/{stepId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence steps remove\n\nRemove a step from a sequence.\n\n- API: `POST /email/sequences/steps/{stepId}/remove`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/steps/{stepId}/remove\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence steps reorder\n\nReorder a sequence's steps.\n\n- API: `POST /email/sequences/{sequenceId}/steps/reorder`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/steps/reorder\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enroll\n\nEnroll explicit recipients into a sequence.\n\n- API: `POST /email/sequences/{sequenceId}/enroll`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/enroll\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enroll-from-object\n\nEnroll people from a CRM object: pick the object, the email field, and the entry ids.\n\n- API: `POST /email/sequences/{sequenceId}/enroll/from-object`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/enroll/from-object\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enrollments list\n\nList a sequence's enrollments (paginated, optional status filter).\n\n- API: `GET /email/sequences/{sequenceId}/enrollments`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/sequences/{sequenceId}/enrollments\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enrollment pause\n\nPause one enrollment.\n\n- API: `POST /email/sequences/enrollments/{enrollmentId}/pause`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/enrollments/{enrollmentId}/pause\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enrollment resume\n\nResume one paused enrollment.\n\n- API: `POST /email/sequences/enrollments/{enrollmentId}/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/enrollments/{enrollmentId}/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enrollment stop\n\nStop one enrollment (no further steps send).\n\n- API: `POST /email/sequences/enrollments/{enrollmentId}/stop`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/enrollments/{enrollmentId}/stop\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Environments\n\n### dench env list\n\nList workspace-shared reusable setups and ready revisions (metadata only).\n\n- API: `GET /environments`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/environments\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench env show\n\nInspect a saved setup, its manifest, and an optional immutable revision.\n\n- API: `GET /environments/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/environments/{name}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench env save\n\nReserve an owner-bound source upload. Prefix the uploaded bytes with the returned proof before saving.\n\n- API: `POST /environments/uploads`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/environments/uploads\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"kind\": \"string\",\n \"size\": 0,\n \"sha256\": \"string\"\n }'\n```\n\n### dench env save\n\nPublish an explicitly saved source and manifest for one-time preparation. Returns pending/building until verified; does not run the task.\n\n- API: `POST /environments/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/environments/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"manifest\": {},\n \"uploadId\": \"string\",\n \"storageId\": \"string\",\n \"sha256\": \"string\"\n }'\n```\n\n### dench env delete\n\nRetire a saved setup from new selection; retain immutable revisions and active job evidence.\n\n- API: `DELETE /environments/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/environments/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench env run\n\nRun a command with prepared dependencies and declared credentials, saving declared state with a revision check.\n\n- API: `POST /local/environments/run`\n- Auth: No bearer token required.\n\n```bash\n# dench env run\n# Local-only: Execution occurs in the CLI process. Use dench env run NAME -- COMMAND; secret-bearing execution resolution is not a general REST read endpoint.\n```\n\n## Files\n\n### dench files ls\n\nList workspace files.\n\n- API: `GET /files`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/files\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench files cat\n\nRead a workspace file's text.\n\n- API: `GET /files/content`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/files/content?path=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench files write\n\nWrite a workspace file's text.\n\n- API: `PUT /files/content`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/files/content\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"path\": \"string\",\n \"content\": \"string\"\n }'\n```\n\n### dench files download\n\nGet a signed file download URL.\n\n- API: `GET /files/download-url`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/files/download-url?path=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench files rm\n\nRemove a workspace file or directory.\n\n- API: `DELETE /files`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/files\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"path\": \"string\"\n }'\n```\n\n### dench files mv\n\nMove a workspace file or directory.\n\n- API: `POST /files/move`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/files/move\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"from\": \"string\",\n \"to\": \"string\"\n }'\n```\n\n### dench files mkdir\n\nCreate a workspace directory (and any missing parents). Idempotent.\n\n- API: `POST /files/mkdir`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/files/mkdir\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"path\": \"string\"\n }'\n```\n\n### dench stage\n\nStage uploaded content into the workspace.\n\n- API: `POST /files/stage`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/files/stage\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Gateway\n\n### dench search\n\nSearch the web through the Dench gateway.\n\n- API: `POST /search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"query\": \"latest AI CRM workflows\",\n \"numResults\": 5\n }'\n```\n\n### dench search contents\n\nFetch page contents through the Dench gateway.\n\n- API: `POST /search/contents`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/search/contents\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"urls\": []\n }'\n```\n\n### dench search answer\n\nAnswer a question with web search.\n\n- API: `POST /search/answer`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/search/answer\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"query\": \"string\"\n }'\n```\n\n### dench web scrape\n\nRead a page as clean Markdown through Dench web.\n\n- API: `POST /context/web-scrape-markdown`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-scrape-markdown\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"url\": \"https://example.com\",\n \"useMainContentOnly\": true\n }\n }'\n```\n\n### dench web brand\n\nLook up a brand kit from a domain or email.\n\n- API: `POST /context/brand-retrieve`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/brand-retrieve\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"domain\": \"stripe.com\"\n }\n }'\n```\n\n### dench web sitemap\n\nList sitemap URLs for a domain.\n\n- API: `POST /context/web-sitemap`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-sitemap\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"domain\": \"example.com\",\n \"maxLinks\": 1000\n }\n }'\n```\n\n### dench web crawl\n\nCrawl a site to Markdown (capped).\n\n- API: `POST /context/web-crawl`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-crawl\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"url\": \"https://example.com\",\n \"maxPages\": 15,\n \"useMainContentOnly\": true\n }\n }'\n```\n\n### dench web screenshot\n\nCapture a rendered page screenshot.\n\n- API: `POST /context/web-screenshot`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-screenshot\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"directUrl\": \"https://example.com\",\n \"fullScreenshot\": false\n }\n }'\n```\n\n### dench web extract\n\nExtract typed fields from a page using a JSON Schema.\n\n- API: `POST /context/web-extract`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-extract\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"url\": \"https://example.com\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"title\": {\n \"type\": \"string\"\n }\n }\n }\n }\n }'\n```\n\n### dench web product\n\nExtract a product listing from a URL.\n\n- API: `POST /context/web-product`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-product\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"url\": \"https://example.com/product\"\n }\n }'\n```\n\n### dench web competitors\n\nFind competitors of a domain.\n\n- API: `POST /context/web-competitors`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-competitors\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"domain\": \"stripe.com\",\n \"numCompetitors\": 5\n }\n }'\n```\n\n### dench web styleguide\n\nRead a brand styleguide from a domain.\n\n- API: `POST /context/brand-styleguide`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/brand-styleguide\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"domain\": \"stripe.com\"\n }\n }'\n```\n\n### dench web fonts\n\nRead site fonts from a domain.\n\n- API: `POST /context/brand-fonts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/brand-fonts\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"domain\": \"stripe.com\"\n }\n }'\n```\n\n### dench web classify\n\nClassify a domain with NAICS or SIC.\n\n- API: `POST /context/classify-naics`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/classify-naics\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"input\": \"stripe.com\"\n }\n }'\n```\n\n### dench web brand-search\n\nAutocomplete brand names.\n\n- API: `POST /context/brand-search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/brand-search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"query\": \"stripe\"\n }\n }'\n```\n\n### dench image generate\n\nGenerate an image through the Dench gateway.\n\n- API: `POST /images/generations`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/images/generations\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"prompt\": \"A minimal flat-vector app icon\",\n \"size\": \"1024x1024\"\n }'\n```\n\n### dench image edit\n\nEdit an image through the Dench gateway.\n\n- API: `POST /images/edits`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/images/edits\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"prompt\": \"Make the background transparent\",\n \"input_images_base64\": [\n \"iVBORw0KGgoAAAANSUhEUg...\"\n ]\n }'\n```\n\n### dench integrations\n\nList every connected integration — connected apps plus the Gmail, Outlook, Calendar, LinkedIn and Slack connections Dench provides itself (Slack rows report source: dench).\n\n- API: `GET /integrations`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/integrations\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench tool status\n\nList connected tool accounts.\n\n- API: `GET /tools/status`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/tools/status\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench tool connect\n\nCreate a tool OAuth connection link. Slack is in-house, never a third-party connection: for toolkit slack the CLI prints the first-party install URL (/api/slack/install?slug=<workspace>, org admin) instead of calling this endpoint.\n\n- API: `POST /tools/connections`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/tools/connections\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench tool search\n\nSearch for external tool actions.\n\n- API: `POST /tools/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/tools/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"queries\": [\n {\n \"use_case\": \"list Slack channels\"\n }\n ]\n }'\n```\n\n### dench tool run\n\nRun an external tool action. SLACK_* slugs (SLACK_SEND_MESSAGE with Block Kit blocks/buttons, SLACK_FETCH_HISTORY, SLACK_LIST_CHANNELS, …) run through Dench's in-house Slack app install — any channel in the connected workspace — and are always preferred over any third-party Slack connection.\n\n- API: `POST /tools/run`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/tools/run\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"tool_slug\": \"SLACK_LIST_CHANNELS\",\n \"arguments\": {\n \"limit\": 10\n }\n }'\n```\n\n### dench tool disconnect\n\nDisconnect an external tool account.\n\n- API: `DELETE /tools/connections/{connectionId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/tools/connections/{connectionId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench tool labels\n\nList human names given to connected accounts.\n\n- API: `GET /tools/labels`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/tools/labels\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench tool label\n\nName a connected account, or clear its name with an empty string.\n\n- API: `PUT /tools/connections/{connectionId}/label`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/tools/connections/{connectionId}/label\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"displayName\": \"string\"\n }'\n```\n\n## Lists\n\n### dench lists\n\nList saved searches (find-result lists) in the workspace, newest first.\n\n- API: `GET /lists`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench lists list`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/lists\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists rows\n\nRead saved rows with current enrichment results and original indices; cursor-paged, without repeating a search.\n\n- API: `GET /lists/{artifactId}/rows`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/lists/{artifactId}/rows\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench artifacts import\n\nExplicitly import selected saved profiles, optionally filtered by enrichment, with a configured Lead status. Reuses CRM records; never sends outreach or triggers conversion.\n\n- API: `POST /lists/{artifactId}/import`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/lists/{artifactId}/import\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"to\": \"lead\"\n }'\n```\n\n### dench lists show\n\nGet one saved search / list by artifact id.\n\n- API: `GET /lists/{artifactId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/lists/{artifactId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists save\n\nSave find results as a named list (rows + filters become a workspace artifact).\n\n- API: `POST /lists`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench leads find --save-as \"Name\"`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/lists\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"createdFrom\": \"find_people\",\n \"title\": \"string\"\n }'\n```\n\n### dench lists update\n\nUpdate a saved list in place (title, filters, and/or replacement rows).\n\n- API: `PATCH /lists/{artifactId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/lists/{artifactId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists rename\n\nRename a saved search / list.\n\n- API: `POST /lists/{artifactId}/rename`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/lists/{artifactId}/rename\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists delete\n\nDelete a saved search / list, its exported CSV/JSONL files, and any linked watch.\n\n- API: `DELETE /lists/{artifactId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/lists/{artifactId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists reviews\n\nRead durable enrichment activity (legacy review metadata remains readable). Use lists rows for current saved profiles and contacts.\n\n- API: `GET /lists/{artifactId}/reviews`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/lists/{artifactId}/reviews\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists assess\n\nSuggest ICP fit for one profile. Never changes a human review decision.\n\n- API: `POST /lists/{artifactId}/assess`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/lists/{artifactId}/assess\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"row\": {},\n \"suggestion\": {}\n }'\n```\n\n## Local\n\n### dench sessions\n\nList local CLI sessions.\n\n- API: `GET /local/sessions`\n- Auth: No bearer token required.\n\n```bash\n# dench sessions\n# Local-only: CLI sessions live in the caller's ~/.dench/config.json.\n```\n\n### dench use <session-key-or-workspace-slug>\n\nSelect a local CLI session.\n\n- API: `POST /local/sessions/use`\n- Auth: No bearer token required.\n\n```bash\n# dench use <session-key-or-workspace-slug>\n# Local-only: The server cannot mutate the caller's local CLI config.\n```\n\n### dench logout\n\nRemove local CLI sessions.\n\n- API: `POST /local/logout`\n- Auth: No bearer token required.\n\n```bash\n# dench logout\n# Local-only: The server cannot mutate the caller's local CLI config.\n```\n\n### dench backend show|set|clear\n\nConfigure the CLI backend target.\n\n- API: `POST /local/backend`\n- Auth: No bearer token required.\n\n```bash\n# dench backend show|set|clear\n# Local-only: Backend selection is local CLI state.\n```\n\n### dench crm import\n\nImport a local CSV into a CRM object.\n\n- API: `POST /local/crm/import`\n- Auth: No bearer token required.\n\n```bash\n# dench crm import\n# Local-only: Reads a CSV from the caller's local filesystem. Over the API, parse the CSV client-side and POST rows to /crm/objects/{objectName}/entries/batch.\n```\n\n### dench crm export\n\nExport a CRM object to a local CSV.\n\n- API: `POST /local/crm/export`\n- Auth: No bearer token required.\n\n```bash\n# dench crm export\n# Local-only: Writes a CSV to the caller's local filesystem. Over the API, call POST /crm/query and format CSV client-side.\n```\n\n### dench meetings import\n\nImport calls from a local CSV/JSONL: meeting fields plus transcript, action items and attendees per row.\n\n- API: `POST /local/meetings/import`\n- Auth: No bearer token required.\n\n```bash\n# dench meetings import\n# Local-only: Reads a CSV/JSONL from the caller's local filesystem. Over the API: POST /crm/objects/meeting/entries/batch with seedKey per row, then POST /meetings/{meetingEntryId}/transcript, POST …/action-items and PUT …/participants for each created meeting.\n```\n\n### dench fs\n\nRun the local file sync daemon.\n\n- API: `POST /local/fs`\n- Auth: No bearer token required.\n\n```bash\n# dench fs\n# Local-only: The fs daemon watches the caller's local /workspace mount.\n```\n\n## Meetings\n\n### dench meetings list\n\nList meetings, newest first, with status and participants.\n\n- API: `GET /meetings`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/meetings\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings transcript get\n\nRead a meeting's transcript, in order, one page at a time.\n\n- API: `GET /meetings/{meetingEntryId}/transcript`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/meetings/{meetingEntryId}/transcript\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings transcript set\n\nAppend up to 500 transcript segments to a meeting (speakers with an email link to existing people).\n\n- API: `POST /meetings/{meetingEntryId}/transcript`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/meetings/{meetingEntryId}/transcript\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"segments\": []\n }'\n```\n\n### dench meetings transcript clear\n\nDelete a batch of a meeting's transcript segments; repeat until `done` before re-appending.\n\n- API: `DELETE /meetings/{meetingEntryId}/transcript`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/meetings/{meetingEntryId}/transcript\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings action-items list\n\nList a meeting's action items.\n\n- API: `GET /meetings/{meetingEntryId}/action-items`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/meetings/{meetingEntryId}/action-items\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings action-items set\n\nAdd action items to a meeting; `replace: true` swaps the whole list.\n\n- API: `POST /meetings/{meetingEntryId}/action-items`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/meetings/{meetingEntryId}/action-items\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"items\": []\n }'\n```\n\n### dench meetings action-items done\n\nTick or untick one action item.\n\n- API: `PATCH /meetings/action-items/{itemId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/meetings/action-items/{itemId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"done\": true\n }'\n```\n\n### dench meetings action-items delete\n\nDelete one action item.\n\n- API: `DELETE /meetings/action-items/{itemId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/meetings/action-items/{itemId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings participants list\n\nWho was in the meeting, merged with the linked calendar invite.\n\n- API: `GET /meetings/{meetingEntryId}/participants`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/meetings/{meetingEntryId}/participants\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings participants set\n\nRecord attendees by name/email; known members and existing people are linked, nobody is created.\n\n- API: `PUT /meetings/{meetingEntryId}/participants`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/meetings/{meetingEntryId}/participants\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"participants\": []\n }'\n```\n\n### dench meetings share\n\nWhether a meeting is shared with the whole workspace, and whether you may change that.\n\n- API: `GET /meetings/{meetingEntryId}/sharing`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/meetings/{meetingEntryId}/sharing\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings share --workspace\n\nShare one meeting with the workspace, or take it back to owner + invitees.\n\n- API: `PUT /meetings/{meetingEntryId}/sharing`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/meetings/{meetingEntryId}/sharing\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"shared\": true\n }'\n```\n\n## Members\n\n### dench members presence\n\nLive presence (online / away / offline) for workspace members.\n\n- API: `GET /members/presence`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/members/presence\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members get\n\nA member's profile: name, email, tagline, role, timezone, presence, open task count.\n\n- API: `GET /members/{userId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/members/{userId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members activity\n\nA member's recent comments and record changes across the CRM, newest first.\n\n- API: `GET /members/{userId}/activity`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/members/{userId}/activity\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members tasks\n\nOpen tasks assigned to a member (plus ones completed today).\n\n- API: `GET /members/{userId}/tasks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/members/{userId}/tasks\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members me\n\nYour own member profile.\n\n- API: `GET /me/profile`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/me/profile\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members me --name … --tagline … --timezone …\n\nUpdate your name, tagline, avatar URL, or timezone.\n\n- API: `PATCH /me/profile`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/me/profile\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"tagline\": \"Head of Ops\",\n \"timezone\": \"America/New_York\"\n }'\n```\n\n### dench members me --avatar <file>\n\nGet a one-time URL to POST an avatar image to; then PUT /me/avatar with the returned storageId.\n\n- API: `POST /me/avatar/upload-url`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/me/avatar/upload-url\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members me --avatar <file>\n\nSet your avatar from an uploaded storageId.\n\n- API: `PUT /me/avatar`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/me/avatar\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"storageId\": \"kg2abc123def456\"\n }'\n```\n\n### dench members me --clear-avatar\n\nRemove your avatar.\n\n- API: `DELETE /me/avatar`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/me/avatar\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Memory\n\n### dench memory search\n\nSearch durable workspace memory.\n\n- API: `GET /memory/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/memory/search?query=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench memory save\n\nSave a durable workspace memory fact.\n\n- API: `POST /memory`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/memory\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"key\": \"deployment-policy\",\n \"kind\": \"decision\",\n \"text\": \"Never deploy without human approval.\",\n \"tags\": [\n \"deployment\",\n \"policy\"\n ]\n }'\n```\n\n## Meta\n\n### dench help\n\nList all CLI/API operations and parity classifications.\n\n- API: `GET /commands`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/commands\"\n```\n\n## Notifications\n\n### dench notifications list\n\nList your notifications (inbox, unread, archived, or all).\n\n- API: `GET /notifications`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/notifications\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench notifications count\n\nHow many unread notifications you have.\n\n- API: `GET /notifications/unread-count`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/notifications/unread-count\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench notifications read\n\nMark a notification read (or unread).\n\n- API: `PATCH /notifications/{notificationId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/notifications/{notificationId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"read\": true\n }'\n```\n\n### dench notifications read-all\n\nMark every inbox notification read.\n\n- API: `POST /notifications/read-all`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/notifications/read-all\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench notifications archive\n\nArchive a notification.\n\n- API: `POST /notifications/{notificationId}/archive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/notifications/{notificationId}/archive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench notifications prefs\n\nRead your notification preferences.\n\n- API: `GET /notifications/preferences`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/notifications/preferences\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench notifications prefs --set\n\nUpdate your notification preferences.\n\n- API: `PATCH /notifications/preferences`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/notifications/preferences\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"emailEnabled\": true,\n \"perKind\": {\n \"entry_activity\": {\n \"email\": false\n }\n }\n }'\n```\n\n## Routines\n\n### dench cron list\n\nList routines.\n\n- API: `GET /routines`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench routine list`, `dench routines list`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/routines\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron history\n\nList routine run history.\n\n- API: `GET /routines/history`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/routines/history\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron get\n\nGet a routine.\n\n- API: `GET /routines/{jobId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/routines/{jobId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron create\n\nCreate a routine.\n\n- API: `POST /routines`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/routines\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Daily digest\",\n \"prompt\": \"Summarize open CRM tasks.\",\n \"schedule\": {\n \"kind\": \"every\",\n \"everyMs\": 86400000\n }\n }'\n```\n\n### dench cron update\n\nUpdate a routine.\n\n- API: `PATCH /routines/{jobId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/routines/{jobId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron delete\n\nDelete a routine.\n\n- API: `DELETE /routines/{jobId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/routines/{jobId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron enable\n\nEnable a routine.\n\n- API: `POST /routines/{jobId}/enable`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/routines/{jobId}/enable\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron disable\n\nDisable a routine.\n\n- API: `POST /routines/{jobId}/disable`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/routines/{jobId}/disable\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron run\n\nRun a routine now.\n\n- API: `POST /routines/{jobId}/run`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/routines/{jobId}/run\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron runs\n\nList runs for a routine.\n\n- API: `GET /routines/{jobId}/runs`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/routines/{jobId}/runs\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Secrets\n\n### dench secrets list\n\nList workspace-shared credential names, kinds and versions; never values.\n\n- API: `GET /secrets`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/secrets\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench secrets set\n\nEncrypt a workspace credential. Use CLI stdin or the secure chat form; return metadata only. Do not put values in chat, manifests or scripts.\n\n- API: `PUT /secrets/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/secrets/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"kind\": \"env\",\n \"value\": \"string\"\n }'\n```\n\n### dench secrets delete\n\nRevoke a workspace credential for future resolution, optionally checking its version.\n\n- API: `DELETE /secrets/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/secrets/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Settings\n\n### dench settings sync\n\nRead the workspace's Sync switches (accounts from email, contacts from LinkedIn, Slack Connect, calendar, dossier, tasks from email, lead auto-qualify, summaries and Brief). All on by default.\n\n- API: `GET /settings/sync`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/settings/sync\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench settings sync set\n\nFlip Sync switches (admin). Partial patch: only the keys sent change. Off stops new work; nothing already created is removed.\n\n- API: `PATCH /settings/sync`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/settings/sync\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"linkedinContacts\": false\n }'\n```\n\n## Workspace\n\n### dench context --sections\n\nRead selected scoped workspace documents and a compact context index without writes.\n\n- API: `GET /context/sections`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/context/sections\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context\n\nReturn the current Dench workspace context for the bearer.\n\n- API: `GET /context`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/context\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context --instructions\n\nReturn the current workspace's standing instructions for external agents.\n\n- API: `GET /context/instructions`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/context/instructions\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench status\n\nReturn workspace and agent status.\n\n- API: `GET /status`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/status\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench agents\n\nList agents visible in the workspace status payload.\n\n- API: `GET /agents`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agents\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench artifacts\n\nList artifacts for the authenticated workspace.\n\n- API: `GET /artifacts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/artifacts\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench suggested-work\n\nList draft suggested-work artifacts.\n\n- API: `GET /suggested-work`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/suggested-work\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context set rules\n\nUpdate standing workspace rules; credentials belong in secrets and runnable setup in environments.\n\n- API: `PUT /context/rules`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/context/rules\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n"
|
|
14
|
+
"sha256": "2d103c219873314997661140ce5efc5d5b9a9caf01a1496f11af23628ba5a796",
|
|
15
|
+
"content": "# Dench API Guide\n\nUse the Dench CLI first. This API guide is the backup path for agents when the CLI is unavailable, cannot be installed, or cannot run in the current environment.\n\nBase URL:\n\n```bash\nexport DENCH_API_BASE=\"https://www.dench.com/api/v1\"\nexport DENCH_API_KEY=\"<workspace API key or dch_agent_* session token>\"\n```\n\nAuthentication:\n\n```http\nAuthorization: Bearer <DENCH_API_KEY or dch_agent_* session token>\n```\n\nEvery parameter, request body, and response is documented interactively in the OpenAPI playground. This curl guide is generated from the same registry.\n\nMachine-readable spec:\n\n```bash\ncurl -sS \"$DENCH_API_BASE/openapi.json\"\n```\n\n## Important Notes\n\n- Prefer the CLI when it works; it handles local session selection, prompts, streaming display, and file staging ergonomics.\n- Gateway-backed operations (search, dench web, images, apps, tools, enrichment) accept either a Dench API key or an agent session; agent sessions are exchanged for the workspace gateway key server-side.\n- Dench web (page read, brand, sitemap, crawl, screenshot, extract) is `POST /context/{op}`, proxied to `$DENCH_GATEWAY_URL/v1/context/{op}`. Prefer `dench web` / `fetch_url` over writing your own scraper. Search stays `POST /search`.\n- Local-only commands are listed for completeness but operate on the caller's machine and cannot run remotely.\n- For chat operations authenticated with an API key, include `x-dench-run-id: <run_id>` when acting from inside a running agent turn.\n\n## Agent Config\n\n### dench context --sections identity\n\nRead IDENTITY.md.\n\n- API: `GET /agent-config/identity`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench identity show`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/identity\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context set identity\n\nUpdate IDENTITY.md.\n\n- API: `PUT /agent-config/identity`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench identity edit`\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/identity\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench context --sections organisation\n\nRead ORGANISATION.md.\n\n- API: `GET /agent-config/organisation`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench organisation show`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/organisation\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context set organisation\n\nUpdate ORGANISATION.md.\n\n- API: `PUT /agent-config/organisation`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench organisation edit`\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/organisation\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench context --sections user\n\nRead USER.md.\n\n- API: `GET /agent-config/user`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench user show`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/user\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context set user\n\nUpdate USER.md.\n\n- API: `PUT /agent-config/user`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench user edit`\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/user\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench context --sections tools\n\nRead tool notes.\n\n- API: `GET /agent-config/tools`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench tools show`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/tools\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context set tools\n\nUpdate tool notes.\n\n- API: `PUT /agent-config/tools`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench tools edit`\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/tools\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench mem show\n\nRead aggregate memory.\n\n- API: `GET /agent-config/mem`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/mem\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench mem set\n\nUpdate aggregate memory.\n\n- API: `PUT /agent-config/mem`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/mem\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench bootstrap status\n\nRead bootstrap state.\n\n- API: `GET /agent-config/bootstrap`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/bootstrap\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench bootstrap complete\n\nComplete bootstrap.\n\n- API: `POST /agent-config/bootstrap/complete`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/agent-config/bootstrap/complete\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench bootstrap template\n\nUpdate bootstrap template.\n\n- API: `PUT /agent-config/bootstrap/template`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/bootstrap/template\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n\n### dench model default\n\nSet the default chat model.\n\n- API: `PUT /agent-config/model/default`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/model/default\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"modelId\": \"string\"\n }'\n```\n\n### dench model thread\n\nSet a thread model override.\n\n- API: `PUT /agent-config/model/threads/{threadId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/agent-config/model/threads/{threadId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"modelId\": \"string\"\n }'\n```\n\n### dench daily today\n\nRead today's daily activity path.\n\n- API: `GET /agent-config/daily/today`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/daily/today\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench daily show\n\nRead a daily activity path.\n\n- API: `GET /agent-config/daily/{date}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agent-config/daily/{date}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Approvals\n\n### dench approvals\n\nList approval requests visible in the workspace status payload.\n\n- API: `GET /approvals`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/approvals\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench approval request\n\nRequest human approval.\n\n- API: `POST /approvals`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/approvals\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"title\": \"Deploy the new API branch?\",\n \"reason\": \"Production deploy changes public behavior.\",\n \"risk\": \"high\"\n }'\n```\n\n### dench approval approve|reject\n\nRecord an approval decision.\n\n- API: `POST /approvals/{approvalId}/decision`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/approvals/{approvalId}/decision\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"decision\": \"approved\",\n \"evidence\": \"User said yes in chat\"\n }'\n```\n\n## Apps\n\n### dench apps list\n\nList installed App Store apps in the workspace.\n\n- API: `GET /apps`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/apps\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench apps gallery\n\nList Discover listings — Official (Dench) + Community shelves.\n\n- API: `GET /apps/gallery`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/apps/gallery\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench apps create\n\nScaffold and register a new App Store app.\n\n- API: `POST /apps`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/apps\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"slug\": \"string\",\n \"name\": \"string\"\n }'\n```\n\n### dench apps install\n\nInstall an App Store listing into the workspace.\n\n- API: `POST /apps/install`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/apps/install\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"listingId\": \"string\"\n }'\n```\n\n### dench apps publish\n\nPublish an app's files as a versioned App Store listing.\n\n- API: `POST /apps/publish`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/apps/publish\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"appPath\": \"string\",\n \"slug\": \"string\",\n \"name\": \"string\"\n }'\n```\n\n### dench apps uninstall\n\nUninstall an app from the workspace.\n\n- API: `DELETE /apps/{slug}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/apps/{slug}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench apps enable\n\nEnable or disable an installed app.\n\n- API: `PATCH /apps/{slug}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/apps/{slug}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"enabled\": true\n }'\n```\n\n### dench apps pin\n\nPin or unpin an installed app in the rail.\n\n- API: `POST /apps/{slug}/pin`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/apps/{slug}/pin\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"pinned\": true\n }'\n```\n\n### dench apps validate\n\nValidate a .dench.app folder: manifest, permissions, and every window.dench call it makes.\n\n- API: `POST /local/apps/validate`\n- Auth: No bearer token required.\n\n```bash\n# dench apps validate\n# Local-only: Validation reads the app folder on the caller's disk. In the browser, the same catalog is window.dench.api.operations().\n```\n\n### dench apps webhooks register\n\nRegister an inbound webhook for an app. Returns the URL and signing secret ONCE.\n\n- API: `POST /apps/{slug}/webhooks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/apps/{slug}/webhooks\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"hookName\": \"string\"\n }'\n```\n\n### dench apps webhooks list\n\nList an app's registered webhooks (URLs, never secrets).\n\n- API: `GET /apps/{slug}/webhooks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/apps/{slug}/webhooks\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench apps webhooks poll\n\nRead events an app webhook received since a timestamp.\n\n- API: `GET /apps/{slug}/webhooks/{hookName}/events`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/apps/{slug}/webhooks/{hookName}/events\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench apps webhooks delete\n\nRemove an app webhook and every event it stored.\n\n- API: `DELETE /apps/{slug}/webhooks/{hookName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/apps/{slug}/webhooks/{hookName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Auth\n\n### dench signin\n\nCreate an agent sign-in request.\n\n- API: `POST /auth/signin-requests`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/auth/signin-requests\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"codeHash\": \"string\",\n \"sessionTokenHash\": \"string\",\n \"agentName\": \"string\",\n \"agentKind\": \"string\",\n \"intent\": \"join_existing\"\n }'\n```\n\n### dench signin\n\nPoll an agent sign-in request until approval.\n\n- API: `POST /auth/signin-requests/{requestId}/poll`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/auth/signin-requests/{requestId}/poll\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"codeHash\": \"string\",\n \"sessionTokenHash\": \"string\"\n }'\n```\n\n### dench signin --email\n\nStart the email OTP sign-in flow.\n\n- API: `POST /auth/otp/start`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/auth/otp/start\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"email\": \"string\"\n }'\n```\n\n### dench signin --email\n\nVerify an email OTP sign-in code.\n\n- API: `POST /auth/otp/verify`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/auth/otp/verify\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"email\": \"string\",\n \"code\": \"string\",\n \"agentName\": \"string\",\n \"agentKind\": \"string\",\n \"sessionTokenHash\": \"string\",\n \"intent\": \"join_existing\"\n }'\n```\n\n### dench signin --email\n\nFinalize an email OTP sign-in session.\n\n- API: `POST /auth/otp/finalize`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/auth/otp/finalize\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"authToken\": \"string\"\n }'\n```\n\n## Billing\n\n### dench billing status\n\nGet billing and AI credit status.\n\n- API: `GET /billing/status`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/billing/status\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench billing topup\n\nCreate an AI credit top-up checkout link.\n\n- API: `POST /billing/topup`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/billing/topup\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"requestId\": \"string\",\n \"amountUsd\": 0\n }'\n```\n\n### dench upgrade\n\nCreate a workspace upgrade checkout link.\n\n- API: `POST /billing/upgrade`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/billing/upgrade\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Browser\n\n### dench browser\n\nDrive Dench Browser with a single interactive action (open, inspect, click, fill, type, screenshot, stop). Pass the step in `action` plus its arguments.\n\n- API: `POST /browser/cli`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/browser/cli\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"action\": \"open\",\n \"url\": \"https://example.com\"\n }'\n```\n\n### dench browser session create\n\nCreate a Dench Browser session and return a CDP connect URL for Playwright (chromium.connectOverCDP) plus a live-view URL. Use for durable scripts run from the sandbox.\n\n- API: `POST /browser/sessions`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/browser/sessions\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"viewport\": {\n \"width\": 1280,\n \"height\": 800\n }\n }'\n```\n\n### dench browser session status\n\nGet the status, connect URL, and live-view URL for a Dench Browser session.\n\n- API: `GET /browser/sessions/{sessionId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/browser/sessions/{sessionId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench browser session stop\n\nStop a Dench Browser session and release the remote browser.\n\n- API: `DELETE /browser/sessions/{sessionId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/browser/sessions/{sessionId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Campaigns\n\n### dench campaign draft\n\nCreate an idempotent empty campaign draft with the caller's available sender pools. Does not launch or send.\n\n- API: `POST /campaigns/drafts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/drafts\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"clientRequestId\": \"string\"\n }'\n```\n\n### dench campaign search\n\nSearch people by filters without adding CRM records or campaign recipients. Search credits apply; this is not a free provider preview.\n\n- API: `POST /campaigns/audience/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/audience/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"filters\": {}\n }'\n```\n\n### dench campaign add --search\n\nSearch and add up to 50 people to an existing campaign. New identities become Leads. Search credits apply; use nextPageToken for another page.\n\n- API: `POST /campaigns/{sequenceId}/people/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/people/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"filters\": {}\n }'\n```\n\n### dench campaign add --people-file\n\nAdd up to 50 selected recipients without another search. Deduplicates, applies suppression, and preserves the campaign's launch state.\n\n- API: `POST /campaigns/{sequenceId}/people/batch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/people/batch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"recipients\": []\n }'\n```\n\n### dench campaign sources get\n\nRead a campaign's saved signal source, targeting and schedule.\n\n- API: `GET /campaigns/{sequenceId}/sources`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/sources\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources signals\n\nRead signal choices, suggested terms and current source configuration.\n\n- API: `GET /campaigns/{sequenceId}/sources/signals`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/signals\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources set\n\nUpdate source cadence, pause/resume, targeting, signals or terms. Active sources may perform billable future work.\n\n- API: `PATCH /campaigns/{sequenceId}/sources`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/campaigns/{sequenceId}/sources\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources preview\n\nPreview a signal source using its current audience. Provider credits may apply; does not enroll people.\n\n- API: `POST /campaigns/{sequenceId}/sources/preview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/preview\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"signal\": \"post_engagement\"\n }'\n```\n\n### dench campaign sources run\n\nRun a live campaign's signals now instead of waiting for the schedule (Run now). Provider credits apply; limited to 6 runs an hour.\n\n- API: `POST /campaigns/{sequenceId}/sources/run`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/run\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources overview\n\nRead the Sources tab: each signal's status, last and next run, people found and anything needing attention.\n\n- API: `GET /campaigns/{sequenceId}/sources/overview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/overview\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources pending\n\nList people a signal found who are waiting for approval (manual approval mode).\n\n- API: `GET /campaigns/{sequenceId}/sources/pending`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/pending\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sources approve|reject\n\nApprove people waiting for review (they start the sequence) or reject them.\n\n- API: `POST /campaigns/{sequenceId}/sources/review`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/sources/review\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"enrollmentIds\": [],\n \"decision\": \"approve\"\n }'\n```\n\n### dench campaign queue\n\nToday's queue: who the campaign plans to contact today, warmest first, within the senders' limits.\n\n- API: `GET /campaigns/{sequenceId}/queue`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/queue\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder profile\n\nRead the company profile and suggested campaign audience.\n\n- API: `GET /campaigns/builder/profile`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/builder/profile\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder save\n\nSave a signal campaign's audience, signals and terms idempotently. Does not start a build.\n\n- API: `POST /campaigns/builder/drafts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/drafts\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"clientRequestId\": \"string\",\n \"targeting\": {},\n \"signals\": []\n }'\n```\n\n### dench campaign builder get\n\nRead signal build progress, preview people, messages and errors.\n\n- API: `GET /campaigns/builder/drafts/{draftId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder build\n\nStart the same billable signal/audience/message build used by the UI; poll the draft for progress.\n\n- API: `POST /campaigns/builder/drafts/{draftId}/build`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/build\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder create\n\nCreate a campaign from a reviewed signal draft. Does not launch the campaign.\n\n- API: `POST /campaigns/builder/drafts/{draftId}/create`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/create\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder opener\n\nEdit or reset one preview person's opening line before creating the campaign.\n\n- API: `PUT /campaigns/builder/drafts/{draftId}/people/{leadId}/opener`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/people/{leadId}/opener\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"opener\": \"string\"\n }'\n```\n\n### dench campaign builder drafts\n\nList saved, unfinished campaign drafts that can be resumed.\n\n- API: `GET /campaigns/builder/drafts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/builder/drafts\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder resume\n\nRead a saved draft's setup (source, name, targeting, signals, terms, lookalike) to resume it.\n\n- API: `GET /campaigns/builder/drafts/{draftId}/setup`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/setup\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder discard\n\nDiscard a saved draft that has not become a campaign.\n\n- API: `DELETE /campaigns/builder/drafts/{draftId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder outreach\n\nSave a draft's Outreach and Review choices: AI or manual steps, the brief, the steps, who sends and when, and auto or manual approval.\n\n- API: `PATCH /campaigns/builder/drafts/{draftId}/outreach`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/outreach\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder sequence\n\nGenerate the draft's sequence from a brief (goal, problem, tone, channels), as Generate sequence does. AI credits apply.\n\n- API: `POST /campaigns/builder/drafts/{draftId}/sequence`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/drafts/{draftId}/sequence\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"brief\": {}\n }'\n```\n\n### dench campaign builder lookalike\n\nSet up a lookalike from the best lead's LinkedIn URL (role, similar roles, place, industry, similar companies), suggest roles again, or re-scope to a company. Nothing is saved. Provider credits apply.\n\n- API: `POST /campaigns/builder/lookalike`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/lookalike\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder voices\n\nSuggest market voices (LinkedIn experts) for the campaign's topics, to watch with voice_engagement. AI credits apply.\n\n- API: `POST /campaigns/builder/voices`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/voices\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign builder autofill\n\nTurn an audience description into targeting filters. AI credits apply.\n\n- API: `POST /campaigns/builder/autofill`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/autofill\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"description\": \"string\"\n }'\n```\n\n### dench campaign builder estimate\n\nEstimate audience or weekly signal volume using the UI's cached estimator. Provider credits may apply.\n\n- API: `POST /campaigns/builder/estimate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/builder/estimate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"kind\": \"people\",\n \"targeting\": {}\n }'\n```\n\n### dench campaign accounts\n\nDiscover LinkedIn sender ids, labels, availability and remaining capacity visible to the acting workspace member. Never returns provider credentials.\n\n- API: `GET /campaigns/accounts/linkedin`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/accounts/linkedin\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign accounts\n\nDiscover the mailboxes the acting workspace member can send campaign email from: ids for emailMailboxAccountIds, status, warm-up state and when it is done, the daily cold-email cap and what is left today. Never returns provider credentials.\n\n- API: `GET /campaigns/accounts/email`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/accounts/email\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign list [--with-references]\n\nList outreach campaigns (archived ones on request).\n\n- API: `GET /campaigns`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign create\n\nCreate a draft outreach campaign with email and LinkedIn sender pools and a business-hours send window in the given timezone.\n\n- API: `POST /campaigns`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Founder outreach\",\n \"timezone\": \"America/Los_Angeles\",\n \"emailMailboxAccountIds\": [\n \"<emailMailboxAccountId>\"\n ],\n \"linkedinAccountIds\": [\n \"<linkedinAccountId>\"\n ]\n }'\n```\n\n### dench campaign duplicate\n\nCopy a campaign into a new draft named \"<name> copy\": the same steps, schedule, sender pools and personalized lines, its lead source paused, and no people. To reach more than 300 people, duplicate and add the next page of the search to the copy.\n\n- API: `POST /campaigns/{sequenceId}/duplicate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/duplicate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign get\n\nRead a campaign: settings, steps, people, their current step and hold, last touches, linked leads.\n\n- API: `GET /campaigns/{sequenceId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign get\n\nCampaign funnel: enrolled, contacted, invited, accepted, messaged, replied, opens and clicks, and for a workflow how many people took each If / else and Wait for them to accept path (branchStats).\n\n- API: `GET /campaigns/{sequenceId}/analytics`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/analytics\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign get\n\nWhat the campaign is doing now, what comes next and when, and why it is holding.\n\n- API: `GET /campaigns/{sequenceId}/live`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/live\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign pipeline\n\nWhere a campaign's people sit in the workspace's lead pipeline right now: each lead Status in order with how many enrolled leads are at it, and how many have no lead or a status outside the pipeline.\n\n- API: `GET /campaigns/{sequenceId}/pipeline`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/pipeline\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign set\n\nChange a campaign's name, sender pools, send windows, daily email cap, stop-on-reply, start or end. Works until archived; existing conversations keep their assigned sender.\n\n- API: `PATCH /campaigns/{sequenceId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/campaigns/{sequenceId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"emailMailboxAccountIds\": [\n \"<emailMailboxAccountId>\"\n ],\n \"linkedinAccountIds\": [\n \"<linkedinAccountId>\"\n ],\n \"dailySendCap\": 30,\n \"sendSchedules\": [\n {\n \"name\": \"Mon-Fri 9-18\",\n \"timezone\": \"America/Los_Angeles\",\n \"startHour\": 9,\n \"endHour\": 18,\n \"weekdays\": [\n 1,\n 2,\n 3,\n 4,\n 5\n ]\n }\n ]\n }'\n```\n\n### dench campaign steps set\n\nReplace every step of a draft campaign (email, wait, LinkedIn visit, connection request, message, post reaction, InMail, If / else, Wait for them to accept). A workflow (stepModel workflow, or steps with key, next, yesNext or noNext) branches: condition and wait_for_connection steps continue on yesNext or noNext, other steps on next; each points at another step's key or end. Steps are checked first: a field the step type would drop, missing text, {TOKEN} single braces or paths that don't hold together are rejected, not saved. Configure sender pools on the campaign; step sender ids are legacy-only.\n\n- API: `PUT /campaigns/{sequenceId}/steps`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/{sequenceId}/steps\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"stepModel\": \"workflow\",\n \"steps\": [\n {\n \"key\": \"connected\",\n \"type\": \"condition\",\n \"check\": \"linkedin_connected\",\n \"yesNext\": \"message\",\n \"noNext\": \"invite\"\n },\n {\n \"key\": \"invite\",\n \"type\": \"linkedin_connection\",\n \"linkedinMessageBody\": \"Hi {{First name}}, enjoyed your post on {{Topic}}.\",\n \"next\": \"accept\"\n },\n {\n \"key\": \"accept\",\n \"type\": \"wait_for_connection\",\n \"connectionTimeoutHours\": 240,\n \"yesNext\": \"message\",\n \"noNext\": \"email\"\n },\n {\n \"key\": \"email\",\n \"type\": \"email\",\n \"emailSubject\": \"Quick question, {{First name}}\",\n \"emailTextBody\": \"Hi {{First name}}, ...\",\n \"next\": \"end\"\n },\n {\n \"key\": \"message\",\n \"type\": \"linkedin_message\",\n \"linkedinMessageBody\": \"Thanks for connecting, {{First name}}. ...\",\n \"next\": \"end\"\n }\n ]\n }'\n```\n\n### dench campaign steps edit\n\nEdit the text, waits and conditions of a launched (or paused) campaign's steps in place. Each step keeps its id, type and place; pass the stepId and the updatedAt you read, and only the fields you change. A workflow keeps its paths and what each If / else checks (key, next, yesNext, noNext, check, conditionField, conditionOperator); conditionValue and acceptance waits stay editable. Messages already sent or being prepared keep their text; drafts use campaigns.steps.replace.\n\n- API: `PATCH /campaigns/{sequenceId}/steps`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/campaigns/{sequenceId}/steps\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"steps\": [\n {\n \"stepId\": \"<stepId>\",\n \"expectedUpdatedAt\": 1765526400000,\n \"type\": \"email\",\n \"emailSubject\": \"A quicker question, {{First name}}\"\n },\n {\n \"stepId\": \"<waitStepId>\",\n \"expectedUpdatedAt\": 1765526400000,\n \"type\": \"wait\",\n \"waitHours\": 96\n },\n {\n \"stepId\": \"<waitForConnectionStepId>\",\n \"expectedUpdatedAt\": 1765526400000,\n \"type\": \"wait_for_connection\",\n \"connectionTimeoutHours\": 336\n }\n ]\n }'\n```\n\n### dench campaign personalize get\n\nRead a campaign's personalized lines (written for each person): their {{keys}} for steps, instructions and fallbacks, how many people have them, and the cost per person.\n\n- API: `GET /campaigns/{sequenceId}/personalization`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/personalization\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign personalize set\n\nDefine up to 5 personalized lines (each used as {{key}} in steps) and what you sell. Saving starts writing missing lines for up to 100 people, about 3 cents a person; for more it returns needsConfirm and writes nothing until campaigns.personalization.write is confirmed.\n\n- API: `PUT /campaigns/{sequenceId}/personalization`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/{sequenceId}/personalization\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"template\": {\n \"variables\": [\n {\n \"key\": \"companyHook\",\n \"label\": \"Company hook\",\n \"prompt\": \"One sentence about something specific their company does or recently did. 8 to 18 words.\",\n \"fallback\": \"Your team caught my eye.\",\n \"maxChars\": 160\n }\n ],\n \"context\": {\n \"sells\": \"Senior engineers who join your team in your time zone.\"\n }\n }\n }'\n```\n\n### dench campaign personalize clear\n\nTurn off a campaign's personalized lines and cancel the ones not yet written. Refused while a step still uses one of the {{keys}}.\n\n- API: `DELETE /campaigns/{sequenceId}/personalization`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/campaigns/{sequenceId}/personalization\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign personalize write\n\nWrite personalized lines for the people missing them (mode missing) or rewrite everyone's (mode all). Rewriting everyone or more than 100 people returns needsConfirm and the estimate until called with confirmed: true.\n\n- API: `POST /campaigns/{sequenceId}/personalization/write`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/personalization/write\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign personalize edit\n\nSet one person's personalized line by hand; an empty value undoes the edit. Braces are removed and text past the line's length is cut.\n\n- API: `PUT /campaigns/people/{enrollmentId}/personalization`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/personalization\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"key\": \"string\",\n \"value\": \"string\"\n }'\n```\n\n### dench campaign personalize rewrite\n\nWrite a fresh personalized line for one person: one key, or all of their lines when key is left out. About 3 cents.\n\n- API: `POST /campaigns/people/{enrollmentId}/personalization/rewrite`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/personalization/rewrite\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign add\n\nAdd CRM records (up to 100 ids per call) to a campaign; returns how many were added and why others were skipped.\n\n- API: `POST /campaigns/{sequenceId}/people`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/people\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"objectName\": \"lead\",\n \"entryIds\": [\n \"<entryId1>\",\n \"<entryId2>\"\n ]\n }'\n```\n\n### dench campaign add --name\n\nAdd one person by email and/or LinkedIn profile URL.\n\n- API: `POST /campaigns/{sequenceId}/person`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/person\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"displayName\": \"Ada Lovelace\",\n \"email\": \"ada@example.com\",\n \"linkedinProfileUrl\": \"https://linkedin.com/in/ada\"\n }'\n```\n\n### dench campaign preview\n\nShow the message one person gets at one email or LinkedIn step, with their fields and personalized lines filled in: subject, body, sender, recipient, merge fields still missing, warnings, and why the step would be skipped. Nothing is sent, prepared or charged.\n\n- API: `GET /campaigns/{sequenceId}/preview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/preview?enrollmentId=string&stepId=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign launch --check\n\nLaunch readiness without launching: blockers grouped by problem, warnings, and the fingerprint `launch` requires.\n\n- API: `GET /campaigns/{sequenceId}/launch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/launch\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign launch\n\nLaunch a ready draft. Pass the fingerprint from the preview and acknowledge the LinkedIn notice when LinkedIn steps exist.\n\n- API: `POST /campaigns/{sequenceId}/launch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/launch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sequenceId\": \"<sequenceId>\",\n \"fingerprint\": \"<fingerprint from the launch preview>\",\n \"linkedinRiskAcknowledged\": true\n }'\n```\n\n### dench campaign pause\n\nPause an active campaign.\n\n- API: `POST /campaigns/{sequenceId}/pause`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/pause\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign resume\n\nResume a paused campaign.\n\n- API: `POST /campaigns/{sequenceId}/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign archive\n\nArchive a campaign and stop everyone still in flight. This is the app's Delete: campaigns are never erased, and their people, leads and activity stay.\n\n- API: `POST /campaigns/{sequenceId}/archive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench campaign delete`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/archive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign events\n\nThe campaign's activity log, newest first (sent, accepted, replied, skipped, failed, paused, stopped).\n\n- API: `GET /campaigns/{sequenceId}/events`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/{sequenceId}/events\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign stop\n\nStop one person: nothing more is sent to them from this campaign.\n\n- API: `POST /campaigns/people/{enrollmentId}/stop`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/stop\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign resume-person\n\nResume one paused person in an active campaign.\n\n- API: `POST /campaigns/people/{enrollmentId}/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign person set --email\n\nGive a person in a draft campaign a new or corrected email address; their linked CRM record gets it too. Only before launch; another person in the campaign can't share it.\n\n- API: `PUT /campaigns/people/{enrollmentId}/email`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/email\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"email\": \"string\"\n }'\n```\n\n### dench campaign person set --linkedin-url\n\nGive a person in a draft campaign a new or corrected LinkedIn profile URL; their linked CRM record gets it too. Only before launch.\n\n- API: `PUT /campaigns/people/{enrollmentId}/linkedin`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/linkedin\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"linkedinProfileUrl\": \"string\"\n }'\n```\n\n### dench campaign person set --field\n\nFill or fix one {{merge field}} for a person in a draft campaign, e.g. a missing Company that blocks launch; a matching column on their CRM record is updated too. Only before launch; written personalized lines are not merge fields and can't be set here.\n\n- API: `PUT /campaigns/people/{enrollmentId}/fields`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/fields\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"key\": \"string\",\n \"value\": \"string\"\n }'\n```\n\n### dench campaign resume-person --all\n\nResume every paused person in an active campaign at once, e.g. after a sending account is reconnected. Returns how many were resumed.\n\n- API: `POST /campaigns/{sequenceId}/people/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/people/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign sync\n\nFill each unfinished person's empty email, LinkedIn URL, name and merge fields from their linked CRM record, e.g. after enriching the records. Never overwrites a value the campaign already has; returns how many people changed.\n\n- API: `POST /campaigns/{sequenceId}/people/sync`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/campaigns/{sequenceId}/people/sync\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign where\n\nThe campaigns a CRM record (a person or a lead) is in, newest first, with the person's status in each and the accounts that send to them.\n\n- API: `GET /campaigns/by-record/{entryId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/by-record/{entryId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign person show\n\nEverything a campaign did for one person, step by step: what was sent (subject and text), whether it was opened or clicked, what was skipped and why, waits, failures and retries.\n\n- API: `GET /campaigns/people/{enrollmentId}/timeline`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/campaigns/people/{enrollmentId}/timeline\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench campaign remove\n\nRemove a person who was never contacted from a draft campaign. Frees their place in the 300-person cap and keeps the draft launchable; stop anyone already contacted instead.\n\n- API: `DELETE /campaigns/people/{enrollmentId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/campaigns/people/{enrollmentId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Chat\n\n### dench chat list\n\nList past chat threads.\n\n- API: `GET /chat/threads`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/chat/threads\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench chat search\n\nSearch past chat messages.\n\n- API: `GET /chat/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/chat/search?query=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench chat read\n\nRead a past chat thread.\n\n- API: `GET /chat/threads/{threadId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/chat/threads/{threadId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench chat tree\n\nRead the parent-child chat thread hierarchy.\n\n- API: `GET /chat/tree`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/chat/tree\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench chat rename\n\nRename one or more chat threads.\n\n- API: `PATCH /chat/threads`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/chat/threads\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"items\": [\n {\n \"threadId\": \"th_abc123\",\n \"title\": \"Deploy checklist\"\n }\n ]\n }'\n```\n\n### dench chat delete\n\nDelete one or more chat threads.\n\n- API: `DELETE /chat/threads`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/chat/threads\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"threadIds\": [\n \"th_abc123\"\n ]\n }'\n```\n\n### dench chat new\n\nStart a new chat-turn workflow.\n\n- API: `POST /chat/threads`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench agent new`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/chat/threads\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"prompt\": \"Summarize the latest CRM changes.\"\n }'\n```\n\n### dench chat send\n\nSend a message to an existing chat thread.\n\n- API: `POST /chat/threads/{threadId}/messages`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench agent send`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/chat/threads/{threadId}/messages\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"prompt\": \"string\"\n }'\n```\n\n### dench chat follow\n\nFollow a live chat response stream.\n\n- API: `GET /chat/threads/{threadId}/stream`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench agent follow`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/chat/threads/{threadId}/stream\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Crm\n\n### dench crm objects list [--with-references]\n\nList CRM objects.\n\n- API: `GET /crm/objects`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects list --compact\n\nList names, display labels, visibility and workspace counts without internal state.\n\n- API: `GET /crm/catalog/objects`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/catalog/objects\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects get\n\nGet a CRM object.\n\n- API: `GET /crm/objects/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{name}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects create\n\nCreate a CRM object.\n\n- API: `POST /crm/objects`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"lead\",\n \"description\": \"Sales leads\",\n \"defaultView\": \"kanban\",\n \"icon\": \"target\"\n }'\n```\n\n### dench crm objects update\n\nUpdate a CRM object.\n\n- API: `PATCH /crm/objects/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects rename\n\nRename a CRM object.\n\n- API: `POST /crm/objects/{from}/rename`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{from}/rename\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"to\": \"string\"\n }'\n```\n\n### dench crm objects delete\n\nDelete a CRM object.\n\n- API: `DELETE /crm/objects/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects archive\n\nHide a CRM object's workspace sidebar row for the whole workspace. Not a delete — the table keeps working. Admin-only.\n\n- API: `POST /crm/objects/{name}/archive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{name}/archive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm objects unarchive\n\nRestore a CRM object's workspace sidebar row. Admin-only.\n\n- API: `POST /crm/objects/{name}/unarchive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{name}/unarchive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views list\n\nList the saved views on a CRM object (plus the active view).\n\n- API: `GET /crm/objects/{objectName}/views`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/views\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views get\n\nGet one saved view's definition by name.\n\n- API: `GET /crm/objects/{objectName}/views/{viewName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views entries\n\nMaterialize a saved view's rows (applies its filters/sort/pins), paginated.\n\n- API: `GET /crm/objects/{objectName}/views/{viewName}/entries`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}/entries\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views create\n\nCreate a saved view (named filters/sort/columns combo) on a CRM object.\n\n- API: `POST /crm/objects/{objectName}/views`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/views\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"view\": {\n \"name\": \"Hot leads\",\n \"view_type\": \"table\",\n \"filters\": {\n \"id\": \"g1\",\n \"conjunction\": \"and\",\n \"rules\": [\n {\n \"id\": \"r1\",\n \"field\": \"Status\",\n \"operator\": \"is\",\n \"value\": \"Hot\"\n }\n ]\n },\n \"sort\": [\n {\n \"field\": \"created_at\",\n \"direction\": \"desc\"\n }\n ]\n },\n \"setActive\": true\n }'\n```\n\n### dench crm views update\n\nReplace a saved view's definition (upsert by name).\n\n- API: `PATCH /crm/objects/{objectName}/views/{viewName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"view\": {\n \"sort\": [\n {\n \"field\": \"Score\",\n \"direction\": \"desc\"\n }\n ],\n \"columns\": [\n \"Name\",\n \"Email\",\n \"Status\",\n \"Score\"\n ]\n }\n }'\n```\n\n### dench crm views rename\n\nRename a saved view in place — keeps its filters, pins, and sidebar slot.\n\n- API: `POST /crm/objects/{objectName}/views/{viewName}/rename`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}/rename\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views delete\n\nDelete a saved view by name (idempotent).\n\n- API: `DELETE /crm/objects/{objectName}/views/{viewName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views archive\n\nMove a pinned view's sidebar row into the Archived flyout. Admin-only.\n\n- API: `POST /crm/objects/{objectName}/views/{viewName}/archive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}/archive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm views unarchive\n\nRestore a view's sidebar row (re-asserts its pin). Admin-only.\n\n- API: `POST /crm/objects/{objectName}/views/{viewName}/unarchive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}/unarchive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar list\n\nDescribe the workspace sidebar: Library rows in tree order (with their groups), the home-level Pinned strip, what is hidden and why, and whether the caller is an admin.\n\n- API: `GET /crm/sidebar`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/sidebar\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar move\n\nReposition one Library row (or group) among the Library's top-level slots. Does not add a home-level Pinned tab. Workspace-shared; admin-only.\n\n- API: `POST /crm/sidebar/move`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/move\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"navId\": \"string\",\n \"position\": \"string\"\n }'\n```\n\n### dench crm sidebar group create\n\nCreate a named sidebar group (e.g. \"Hiring\") in the workspace-shared Library. Open to any member.\n\n- API: `POST /crm/sidebar/groups`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/groups\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar group rename\n\nRename a sidebar group. Open to any member.\n\n- API: `POST /crm/sidebar/groups/rename`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/groups/rename\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar group delete\n\nDissolve a sidebar group; its rows return to the top level in its slot. Open to any member.\n\n- API: `POST /crm/sidebar/groups/delete`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/groups/delete\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar group add\n\nMove a sidebar row into a group (groupId set) or back to the top level (groupId null). Open to any member.\n\n- API: `POST /crm/sidebar/groups/move`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench crm sidebar group remove`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/groups/move\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm sidebar pin\n\nPin (pinned true) or unpin a Library row — or a whole group — on the home-level Pinned shortcut strip (the \"tab on the left\"). Does not move the row inside Library. Workspace-shared; open to any member.\n\n- API: `POST /crm/sidebar/pins`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench crm sidebar unpin`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sidebar/pins\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields list\n\nList fields for a CRM object, including read-only calculation metadata.\n\n- API: `GET /crm/objects/{objectName}/fields`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/fields\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields list --compact\n\nList field names, types and effective constraints without indexing or enrichment internals.\n\n- API: `GET /crm/catalog/objects/{objectName}/fields`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/catalog/objects/{objectName}/fields\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields create\n\nCreate a CRM field or read-only campaign activity boolean column.\n\n- API: `POST /crm/objects/{objectName}/fields`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Status\",\n \"type\": \"enum\",\n \"enumValues\": [\n \"New\",\n \"Working\",\n \"Qualified\",\n \"Lost\"\n ],\n \"enumColors\": [\n \"#94a3b8\",\n \"#3b82f6\",\n \"#22c55e\",\n \"#ef4444\"\n ],\n \"indexed\": true\n }'\n```\n\n### dench crm fields update\n\nUpdate a CRM field or change/explicitly clear an existing campaign calculation.\n\n- API: `PATCH /crm/objects/{objectName}/fields/{fieldName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields delete\n\nDelete a CRM field.\n\n- API: `DELETE /crm/objects/{objectName}/fields/{fieldName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields reorder\n\nReorder CRM fields.\n\n- API: `POST /crm/objects/{objectName}/fields/reorder`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields/reorder\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"orderedFieldNames\": []\n }'\n```\n\n### dench crm fields enum-reorder\n\nReorder enum values.\n\n- API: `POST /crm/objects/{objectName}/fields/{fieldName}/enum/reorder`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}/enum/reorder\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"orderedValues\": []\n }'\n```\n\n### dench crm fields enum-add\n\nAdd an enum value.\n\n- API: `POST /crm/objects/{objectName}/fields/{fieldName}/enum`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}/enum\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"value\": \"Nurturing\",\n \"color\": \"#eab308\",\n \"position\": 2\n }'\n```\n\n### dench crm fields enum-remove\n\nRemove an enum value.\n\n- API: `DELETE /crm/objects/{objectName}/fields/{fieldName}/enum/{value}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}/enum/{value}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm fields enum-rename\n\nRename an enum value.\n\n- API: `POST /crm/objects/{objectName}/fields/{fieldName}/enum/{oldValue}/rename`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}/enum/{oldValue}/rename\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"newValue\": \"string\"\n }'\n```\n\n### dench crm fields enum-set-color\n\nSet an enum color.\n\n- API: `POST /crm/objects/{objectName}/fields/{fieldName}/enum/{value}/color`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/fields/{fieldName}/enum/{value}/color\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"color\": \"#22c55e\"\n }'\n```\n\n### dench crm entries list [--with-references]\n\nList CRM entries.\n\n- API: `GET /crm/objects/{objectName}/entries`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries get\n\nGet a CRM entry.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries sync-history\n\nQueue a full, paged pull of the record's email history from every connected mailbox; the ledger fills as pages land.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/sync-history`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/sync-history\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries sync-history --status\n\nHas Dench read this record's email history? One row per address per mailbox.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/sync-history`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/sync-history\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries dossier\n\nStatus of the account's research dossier — the delimited `dench:dossier` section Dench keeps in the record's Notes: status, when it was written, how many dated updates followed, the last error.\n\n- API: `GET /crm/entries/{entryId}/dossier`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/entries/{entryId}/dossier\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries dossier --regenerate\n\nResearch the account again and append a fresh dossier section to its Notes (needs a Website / Domain on the record).\n\n- API: `POST /crm/entries/{entryId}/dossier/regenerate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/entries/{entryId}/dossier/regenerate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm privacy status\n\nWhether the caller hides their own emails / messages with this record from the workspace (directly, or through its account), and whether they own a connection the toggle applies to.\n\n- API: `GET /crm/entries/{entryId}/privacy`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/entries/{entryId}/privacy\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm privacy hide|show\n\nHide (`hidden: true`) or show the caller's own emails / messages with this record to the workspace. An account covers every contact and opportunity linked to it; existing ledger rows are restamped and the shared Brief regenerates.\n\n- API: `PUT /crm/entries/{entryId}/privacy`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/entries/{entryId}/privacy\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"hidden\": true\n }'\n```\n\n### dench crm detections list\n\nList account-detection verdicts — why a domain (or personal address) did or did not become an account: verdict, counterparty type, probabilities, evidence threads, the rows created. `kind` picks the creator: `detections` (email + sweep), `linkedin` (the LinkedIn resolver's rows) or `all` (default). Newest first.\n\n- API: `GET /crm/detections`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/detections\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm detections undo\n\nUndo what the ingestion jobs created since a timestamp (admin): `kind` = `detections` (accounts + contacts from the email detector and the sweep), `linkedin` (the LinkedIn resolver's contacts + accounts; their conversations are unlinked and parked), `email-tasks` (auto-created tasks and cases) or `all` (default). Deletes only rows no human has touched and marks the verdicts / decisions rolled_back so they are never re-created. `dryRun` lists what would go; per-kind counts in `kinds`.\n\n- API: `POST /crm/detections/undo`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/detections/undo\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"since\": 0\n }'\n```\n\n### dench crm history\n\nList a CRM entry's audit history.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/history`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/history\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm activity\n\nList a CRM entry's activity ledger (comments, notes, field changes, emails, meetings, Slack, LinkedIn) in one timeline, newest first by default.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/activity`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/activity\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm brief\n\nThe record's generated Brief: health, who owes the next move, open threads, commitments, risks, next step. Read this before the ledger.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/brief`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/brief\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm context\n\nRead-only source diagnostics: accessible evidence, association reasons, last Brief source manifest, generation queue, and your mailbox delivery health. Bounded, cursor-paged snapshot; does not certify complete history.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/context`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/context\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm brief --regenerate\n\nRebuild a record's Brief from the current timeline.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/brief/regenerate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/brief/regenerate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm activity\n\nBounded per-source counts of a CRM entry's activity ledger.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/activity/count`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/activity/count\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm notes list\n\nList a CRM entry's notes (titled, document-style comments), newest first.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/notes`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/notes\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm notes create\n\nAdd a titled note to a CRM entry's activity timeline (markdown body). Research goes here, never into the Notes document.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/notes`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/notes\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm comments list\n\nList comments on a CRM entry (roots newest first, with preview replies).\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/comments`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/comments\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm comments replies\n\nList every reply under a root comment, oldest first.\n\n- API: `GET /crm/comments/{commentId}/replies`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/comments/{commentId}/replies\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm comments get\n\nGet one comment with its entry label.\n\n- API: `GET /crm/comments/{commentId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/comments/{commentId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm comments create\n\nComment on a CRM entry (markdown). Mention members with [@Name](/?member=<userId>); mention Dench with [@Dench](/?member=dench) or mentionDench.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/comments`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/comments\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"body\": \"Kickoff went well — [@Bob](/?member=user_bob) can you send the proposal? [@Dench](/?member=dench) what's the ARR here?\"\n }'\n```\n\n### dench crm comments update\n\nEdit a comment you wrote.\n\n- API: `PATCH /crm/comments/{commentId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/comments/{commentId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"body\": \"Kickoff went well — proposal sent.\"\n }'\n```\n\n### dench crm comments delete\n\nDelete a comment (kept as a tombstone when it has replies).\n\n- API: `DELETE /crm/comments/{commentId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/comments/{commentId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm comments react\n\nToggle an emoji reaction on a comment.\n\n- API: `PUT /crm/comments/{commentId}/reactions/{emoji}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/comments/{commentId}/reactions/{emoji}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm watch status\n\nWhether you follow a CRM entry's activity.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/watch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/watch\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm watch\n\nFollow or unfollow a CRM entry's activity.\n\n- API: `PUT /crm/objects/{objectName}/entries/{entryId}/watch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/watch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"watching\": true\n }'\n```\n\n### dench crm tasks mine --page\n\nPage assigned tasks in priority order (or completed tasks by recency).\n\n- API: `POST /crm/tasks/assigned/page`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/assigned/page\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks list --page\n\nPage all tasks linked to a record, including subtasks.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/tasks/page`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/tasks/page\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks prepare\n\nStart or resume preparation of exact task ordering and progress.\n\n- API: `POST /crm/tasks/prepare`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/prepare\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks mine\n\nYour open tasks (plus ones completed today).\n\n- API: `GET /crm/tasks/mine`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/tasks/mine\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks list\n\nTasks linked to a CRM entry.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/tasks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/tasks\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks create\n\nCreate a task linked to a CRM entry.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/tasks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/tasks\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Send proposal\",\n \"assigneeUserId\": \"user_bob\",\n \"dueDateKey\": \"2026-09-05\"\n }'\n```\n\n### dench crm tasks complete\n\nMark a task done.\n\n- API: `POST /crm/tasks/{entryId}/complete`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/complete\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks reopen\n\nReopen a completed task.\n\n- API: `POST /crm/tasks/{entryId}/reopen`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/reopen\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks priority\n\nSet or clear a task's priority.\n\n- API: `PUT /crm/tasks/{entryId}/priority`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/tasks/{entryId}/priority\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"priority\": \"string\"\n }'\n```\n\n### dench crm tasks subtasks\n\nA task's subtasks.\n\n- API: `GET /crm/tasks/{entryId}/subtasks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/tasks/{entryId}/subtasks\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks create-subtask\n\nCreate a subtask under a task (inherits the parent's record relations).\n\n- API: `POST /crm/tasks/{entryId}/subtasks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/subtasks\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"string\"\n }'\n```\n\n### dench crm tasks parent\n\nNest a task under a parent, or promote it (parentEntryId: null).\n\n- API: `PUT /crm/tasks/{entryId}/parent`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/tasks/{entryId}/parent\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"parentEntryId\": \"string\"\n }'\n```\n\n### dench crm tasks delete\n\nDelete a task and its subtasks, or keep them as tasks.\n\n- API: `DELETE /crm/tasks/{entryId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/tasks/{entryId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat\n\nHow a task repeats (rule, RRULE, trigger, ends, next due).\n\n- API: `GET /crm/tasks/{entryId}/repeat`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat\n\nMake a task repeat, or change how it repeats (JSON rule or RRULE). An undated task gets its due date anchored on the first matching day from today.\n\n- API: `PUT /crm/tasks/{entryId}/repeat`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat --off\n\nStop a task repeating (past occurrences are kept).\n\n- API: `DELETE /crm/tasks/{entryId}/repeat`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat --skip\n\nSkip the current occurrence: the next one is created now.\n\n- API: `POST /crm/tasks/{entryId}/repeat/skip`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat/skip\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat --pause\n\nPause a repeating task.\n\n- API: `POST /crm/tasks/{entryId}/repeat/pause`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat/pause\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks repeat --resume\n\nResume a paused repeating task.\n\n- API: `POST /crm/tasks/{entryId}/repeat/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/tasks/{entryId}/repeat/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks series\n\nEvery repeating-task series in the workspace.\n\n- API: `GET /crm/tasks/series`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/tasks/series\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm tasks series <seriesId> --occurrences\n\nEvery occurrence (task) of one series.\n\n- API: `GET /crm/tasks/series/{seriesId}/occurrences`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/tasks/series/{seriesId}/occurrences\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries create\n\nCreate a CRM entry.\n\n- API: `POST /crm/objects/{objectName}/entries`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"data\": {\n \"Name\": \"Joint review\",\n \"Assignee\": [\n \"user_kumar\",\n \"user_mark\"\n ],\n \"Status\": \"New\"\n }\n }'\n```\n\n### dench crm entries create-many\n\nCreate many CRM entries.\n\n- API: `POST /crm/objects/{objectName}/entries/batch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/batch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"entries\": [\n {\n \"Name\": \"Jane\",\n \"Email\": \"jane@example.com\"\n },\n {\n \"Name\": \"Bob\",\n \"Email\": \"bob@example.com\"\n }\n ]\n }'\n```\n\n### dench crm entries update\n\nUpdate a CRM entry.\n\n- API: `PATCH /crm/objects/{objectName}/entries/{entryId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"data\": {}\n }'\n```\n\n### dench crm entries update-many\n\nUpdate many CRM entries.\n\n- API: `PATCH /crm/objects/{objectName}/entries/batch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{objectName}/entries/batch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"updates\": []\n }'\n```\n\n### dench crm entries delete\n\nDelete a CRM entry.\n\n- API: `DELETE /crm/objects/{objectName}/entries/{entryId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm entries bulk-delete\n\nBulk delete CRM entries.\n\n- API: `POST /crm/objects/{objectName}/entries/delete`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/delete\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"entryIds\": []\n }'\n```\n\n### dench crm cells get\n\nGet a CRM cell value.\n\n- API: `GET /crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm cells set\n\nSet a CRM cell value.\n\n- API: `PUT /crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"value\": [\n \"user_kumar\",\n \"user_mark\"\n ]\n }'\n```\n\n### dench crm cells set-many\n\nSet many CRM cell values.\n\n- API: `POST /crm/cells/batch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/cells/batch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"cells\": []\n }'\n```\n\n### dench crm cells append\n\nAppend to a CRM cell.\n\n- API: `POST /crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}/append`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/entries/{entryId}/fields/{fieldName}/append\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"value\": \"value\"\n }'\n```\n\n### dench crm query [--with-references]\n\nQuery CRM entries.\n\n- API: `POST /crm/query`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/query\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"lead\",\n \"dslJson\": \"{\\\"filter\\\":{\\\"Status\\\":\\\"Qualified\\\",\\\"Score\\\":{\\\"$gt\\\":50}},\\\"sort\\\":\\\"-Score\\\",\\\"limit\\\":50}\"\n }'\n```\n\n### dench crm query --page\n\nScan CRM entries with a resumable cursor. Empty filtered pages can have more results.\n\n- API: `POST /crm/query/page`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/query/page\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"paginationOpts\": {}\n }'\n```\n\n### dench crm sql\n\nRun CRM SQL-compatible query.\n\n- API: `POST /crm/sql`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/sql\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\"\n }'\n```\n\n### dench crm aggregate\n\nAggregate CRM entries.\n\n- API: `POST /crm/aggregate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/aggregate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"fieldName\": \"string\"\n }'\n```\n\n### dench crm search [--with-references]\n\nSearch CRM entries.\n\n- API: `GET /crm/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/search?text=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm search --page\n\nSearch bounded pages of readable CRM entries, optionally projecting cells. Always follow continueCursor until isDone.\n\n- API: `GET /crm/search/page`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/search/page?text=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm statuses list\n\nList CRM statuses.\n\n- API: `GET /crm/objects/{objectName}/statuses`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/statuses\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm statuses set\n\nSet CRM statuses.\n\n- API: `PUT /crm/objects/{objectName}/statuses`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/objects/{objectName}/statuses\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"statuses\": [\n {\n \"name\": \"New\",\n \"color\": \"#94a3b8\"\n },\n {\n \"name\": \"Working\",\n \"color\": \"#3b82f6\"\n },\n {\n \"name\": \"Qualified\",\n \"color\": \"#22c55e\",\n \"isDefault\": true\n }\n ]\n }'\n```\n\n### dench crm batch\n\nApply a CRM batch.\n\n- API: `POST /crm/batch`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/batch\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"ops\": [\n {\n \"type\": \"entries.create\",\n \"objectName\": \"people\",\n \"data\": {\n \"Name\": \"Jane\"\n }\n }\n ],\n \"idempotencyKey\": \"import-2026-06-01\"\n }'\n```\n\n### dench crm transaction begin\n\nBegin a CRM transaction.\n\n- API: `POST /crm/transactions`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/transactions\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm transaction add\n\nAdd an operation to a CRM transaction.\n\n- API: `POST /crm/transactions/{txnId}/operations`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/transactions/{txnId}/operations\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"op\": {\n \"type\": \"entries.update\",\n \"entryId\": \"ent_lead99\",\n \"data\": {\n \"Status\": \"Qualified\"\n }\n }\n }'\n```\n\n### dench crm transaction commit\n\nCommit a CRM transaction.\n\n- API: `POST /crm/transactions/{txnId}/commit`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/transactions/{txnId}/commit\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm transaction abort\n\nAbort a CRM transaction.\n\n- API: `POST /crm/transactions/{txnId}/abort`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/transactions/{txnId}/abort\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm transaction inspect\n\nInspect a CRM transaction.\n\n- API: `GET /crm/transactions/{txnId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/transactions/{txnId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm docs list\n\nList CRM documents.\n\n- API: `GET /crm/docs`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/docs\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm docs create\n\nCreate a CRM document.\n\n- API: `POST /crm/docs`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/docs\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"title\": \"string\",\n \"filePath\": \"string\"\n }'\n```\n\n### dench crm docs link\n\nLink a CRM document.\n\n- API: `POST /crm/docs/link`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/docs/link\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"filePath\": \"string\"\n }'\n```\n\n### dench crm actions list\n\nList CRM actions.\n\n- API: `GET /crm/actions`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/actions?entryId=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm actions create\n\nCreate or upsert an action button on a named action column (fieldName is the column header; a column can hold multiple buttons — reuse fieldName to add more).\n\n- API: `POST /crm/actions`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/actions\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"fieldName\": \"string\"\n }'\n```\n\n### dench crm actions edit\n\nUpdate an action button on a CRM field.\n\n- API: `PATCH /crm/actions/{actionId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/actions/{actionId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"fieldName\": \"string\"\n }'\n```\n\n### dench crm actions delete\n\nDelete an action button from a CRM field.\n\n- API: `DELETE /crm/actions/{actionId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/actions/{actionId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\"\n }'\n```\n\n### dench crm actions run\n\nRun a CRM action on one or more entries.\n\n- API: `POST /crm/actions/{actionId}/runs`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/actions/{actionId}/runs\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"fieldId\": \"string\",\n \"entryIds\": []\n }'\n```\n\n### dench members list\n\nList workspace members for CRM user fields.\n\n- API: `GET /members`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/members\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm reports generate\n\nGenerate a CRM report.\n\n- API: `POST /crm/reports`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/reports\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"type\": \"pie\",\n \"groupByField\": \"string\"\n }'\n```\n\n### dench crm analytics get\n\nRead an object's analytics dashboard: panels, field roles, the strip's collapsed flag, the named view's own dashboard (if any), and the fields panels may bucket on (synthetic $createdAt / $location last).\n\n- API: `GET /crm/objects/{objectName}/analytics`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/objects/{objectName}/analytics\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics compute\n\nCompute chart-ready results (buckets / series / values) for the stored dashboard, a subset of its panels, or ad-hoc panel definitions — optionally scoped to a saved view, a period preset (with the previous interval as previousValue) and extra filters. Same query the strip renders from.\n\n- API: `POST /crm/objects/{objectName}/analytics/compute`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/compute\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"period\": \"this_month\",\n \"panels\": [\n {\n \"id\": \"adhoc:leads-by-source\",\n \"title\": \"New leads by source\",\n \"type\": \"donut\",\n \"metric\": \"count\",\n \"groupBy\": \"Source\",\n \"sortOrder\": 0\n }\n ]\n }'\n```\n\n### dench crm analytics save\n\nCreate or update one panel (upsert by id). With viewName the write lands on that saved view's own dashboard, forking a copy if it was still inheriting the object's.\n\n- API: `PUT /crm/objects/{objectName}/analytics/panels/{panelId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"panel\": {\n \"title\": \"Open pipeline\",\n \"type\": \"stat\",\n \"metric\": \"sum\",\n \"derived\": \"open_pipeline\",\n \"sortOrder\": 10\n }\n }'\n```\n\n### dench crm analytics update\n\nEdit part of one stored panel: only the keys in `patch` change (title, type, metric, metricField, groupBy, dateField, dateBucket, filters, derived, span, hidden, sortOrder); null clears an optional key. What the card's ⋮ menu writes.\n\n- API: `PATCH /crm/objects/{objectName}/analytics/panels/{panelId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"patch\": {}\n }'\n```\n\n### dench crm analytics hide\n\nTake a chart off the strip above the table (hidden: true). It stays in the full analytics view, counted by the strip's “+N more”.\n\n- API: `POST /crm/objects/{objectName}/analytics/panels/{panelId}/hide`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}/hide\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics show\n\nBring a hidden chart back onto the strip (hidden: false).\n\n- API: `POST /crm/objects/{objectName}/analytics/panels/{panelId}/show`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}/show\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics resize\n\nSet a card's width on the 6-track dashboard grid: span 2 (third), 3 (half), 4 (two thirds), 6 (full), or null for the chart kind's default.\n\n- API: `POST /crm/objects/{objectName}/analytics/panels/{panelId}/resize`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}/resize\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"span\": 0\n }'\n```\n\n### dench crm analytics delete\n\nDelete one panel (idempotent). Template panels are tombstoned so a re-install never resurrects them.\n\n- API: `DELETE /crm/objects/{objectName}/analytics/panels/{panelId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/panels/{panelId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics reorder\n\nPersist the full panel order. panelIds must name every stored panel of the targeted dashboard.\n\n- API: `POST /crm/objects/{objectName}/analytics/reorder`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/reorder\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"panelIds\": [\n \"tpl:sales:total-leads\",\n \"tpl:sales:leads-by-source\"\n ]\n }'\n```\n\n### dench crm analytics roles\n\nSet the object's analytics setup — the field roles shared by every chart and view (amount, stage, won/lost/converted values, stageProbabilities, closeDate, recurrence, owner, location). Replaces the mapping; with merge: true only the keys given change and null clears one.\n\n- API: `PUT /crm/objects/{objectName}/analytics/roles`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/roles\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"fieldRoles\": {\n \"amount\": \"Amount\",\n \"stage\": \"Stage\",\n \"wonValues\": [\n \"Closed Won\"\n ],\n \"lostValues\": [\n \"Closed Lost\"\n ],\n \"closeDate\": \"Close Date\",\n \"owner\": \"Owner\",\n \"location\": \"Account.HQ Location\",\n \"recurrence\": \"annual\"\n }\n }'\n```\n\n### dench crm analytics collapse\n\nCollapse the analytics strip above the object's table (team-shared, like saved views).\n\n- API: `POST /crm/objects/{objectName}/analytics/collapse`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/collapse\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics expand\n\nExpand the analytics strip above the object's table.\n\n- API: `POST /crm/objects/{objectName}/analytics/expand`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/analytics/expand\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm analytics scope\n\nGive a saved view its own dashboard (mode \"own\": starts as a copy of the object's panels) or hand it back to the object's shared one (mode \"shared\").\n\n- API: `POST /crm/objects/{objectName}/views/{viewName}/analytics/scope`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/objects/{objectName}/views/{viewName}/analytics/scope\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"mode\": \"own\"\n }'\n```\n\n### dench crm enrich cell\n\nRequest enrichment for one CRM cell.\n\n- API: `POST /crm/enrich/cell`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/enrich/cell\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"entryId\": \"string\",\n \"fieldName\": \"string\"\n }'\n```\n\n### dench crm enrich object\n\nRequest enrichment for a CRM object.\n\n- API: `POST /crm/enrich/object`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/enrich/object\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"objectName\": \"string\",\n \"fieldName\": \"string\"\n }'\n```\n\n### dench crm people search\n\nSearch for people through the enrichment gateway. `companyDomains` takes up to 1000 domains (e.g. a resolved company list; `dench leads find --company-list <id|view>` resolves one for you) — the gateway fans large lists out as sequential vendor-safe chunks behind one `nextPageToken` stream.\n\n- API: `POST /enrichment/people/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/people/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"titles\": [\n \"Head of Sales\"\n ],\n \"industries\": [\n \"SaaS\"\n ],\n \"companyDomains\": [\n \"acme.com\",\n \"globex.com\"\n ],\n \"limit\": 10\n }'\n```\n\n### dench crm companies search\n\nSearch for companies through the enrichment gateway (also `dench companies find`).\n\n- API: `POST /enrichment/company/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench companies find`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/company/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"domain\": \"example.com\"\n }'\n```\n\n### dench jobs find\n\nSearch job postings through Dench find. `companyDomains` takes up to 1000 domains (chunked automatically); `dench jobs find --company-list <id|view>` resolves a saved company list into it.\n\n- API: `POST /enrichment/jobs/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/jobs/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"titles\": [\n \"Account Executive\"\n ],\n \"locations\": [\n \"San Francisco\"\n ],\n \"companyDomains\": [\n \"acme.com\",\n \"globex.com\"\n ],\n \"limit\": 50\n }'\n```\n\n### dench crm enrich cell\n\nLook up one person profile.\n\n- API: `POST /enrichment/person`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/person\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"linkedinURL\": \"https://www.linkedin.com/in/janedoe\"\n }'\n```\n\n### dench crm enrich cell\n\nLook up one company profile.\n\n- API: `POST /enrichment/company`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/company\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"website\": \"acme.com\"\n }'\n```\n\n### dench crm enrich cell\n\nLook up verified emails and phones for people.\n\n- API: `POST /enrichment/person/contact`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/person/contact\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"contacts\": [\n {\n \"linkedinUrl\": \"https://www.linkedin.com/in/janedoe\"\n }\n ]\n }'\n```\n\n### dench crm enrich profiles\n\nLook up up to 100 people or company profiles without buying emails or phones. Pass kind (people|companies) and lookups; results preserve inputIndex. People require linkedinUrl or email; companies require domain or linkedinUrl.\n\n- API: `POST /enrichment/profiles/bulk`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/profiles/bulk\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"kind\": \"companies\",\n \"lookups\": [\n {\n \"domain\": \"acme.com\"\n }\n ]\n }'\n```\n\n### dench companies related\n\nRead company employees, founders, funding, investors, acquisitions, or investments. Pass domain or linkedinUrl, kind, limit (1–100), and optional pageToken. Does not import CRM records or buy contacts.\n\n- API: `POST /enrichment/company/related`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/company/related\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"domain\": \"acme.com\",\n \"kind\": \"founders\",\n \"limit\": 10\n }'\n```\n\n### dench leads find --limit 1\n\nPreview how many records a find would return.\n\n- API: `POST /enrichment/search/preview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/enrichment/search/preview\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"kind\": \"people\",\n \"titles\": [\n \"VP Sales\"\n ]\n }'\n```\n\n### dench leads filters\n\nList Lead Finder filter vocabularies: exact enum values (seniorities, functions, industries, headcount, company types, languages) and curated suggestions (titles, locations, company HQ, universities, skills, keywords).\n\n- API: `GET /local/enrichment/filter-options`\n- Auth: No bearer token required.\n\n```bash\n# dench leads filters\n# Local-only: Catalogs are bundled with the CLI. Over HTTPS, fetch https://dench.com/references/find-filter-options.json instead.\n```\n\n### dench crm templates list\n\nList one-click CRM templates (objects + automations + sample rows) with per-workspace installed flags.\n\n- API: `GET /crm/templates`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/templates\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm templates install\n\nInstall a CRM template. Idempotent: re-installs top up missing pieces and never duplicate objects, automations, or sample rows.\n\n- API: `POST /crm/templates/{templateId}/install`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/templates/{templateId}/install\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm templates remove-sample-data\n\nDelete a CRM template's sample rows (tagged \"Sample\"); schema, views, and automations stay.\n\n- API: `POST /crm/templates/{templateId}/remove-sample-data`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/crm/templates/{templateId}/remove-sample-data\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm automations list\n\nList deterministic CRM automations (rules that fire inside entry writes, e.g. qualified prospect → opportunity).\n\n- API: `GET /crm/automations`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/crm/automations\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench crm automations enable|disable\n\nEnable or disable a CRM automation.\n\n- API: `PATCH /crm/automations/{automationId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/crm/automations/{automationId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Email\n\n### dench email identity verify\n\nStart Dench Emailing Service sender verification.\n\n- API: `POST /email/identities/verify`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/identities/verify\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"type\": \"email\",\n \"identity\": \"founder@example.com\"\n }'\n```\n\n### dench email identity verify\n\nCreate a durable Dench email sending identity record.\n\n- API: `POST /email/sending-identities`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sending-identities\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"type\": \"domain\",\n \"domain\": \"example.com\",\n \"fromEmail\": \"founder@example.com\",\n \"fromName\": \"Ada at Example\"\n }'\n```\n\n### dench email identity status --identity-id\n\nRefresh a Dench Emailing Service sender verification status.\n\n- API: `POST /email/sending-identities/{identityId}/status`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sending-identities/{identityId}/status\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity verify\n\nBegin the full Dench sender verification flow for a sending identity.\n\n- API: `POST /email/sending-identities/{identityId}/verify`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sending-identities/{identityId}/verify\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity status\n\nRead Dench Emailing Service sender verification status.\n\n- API: `GET /email/identities/{identity}/status`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/identities/{identity}/status\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity list\n\nList the workspace's email sending identities.\n\n- API: `GET /email/sending-identities`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/sending-identities\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity dns\n\nFetch DNS records (DKIM/SPF/DMARC) for a pending domain sender verification.\n\n- API: `GET /email/sending-identities/{identityId}/dns`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/sending-identities/{identityId}/dns\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity disable\n\nSoft-disable a sender (or every sender on a domain) for the workspace; sends are blocked until restored.\n\n- API: `POST /email/sending-identities/{identity}/disable`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sending-identities/{identity}/disable\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity restore\n\nRestore a previously disabled sender for the workspace.\n\n- API: `POST /email/sending-identities/{identity}/restore`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sending-identities/{identity}/restore\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email identity delete\n\nPermanently delete a sender (or every sender on a domain) from the workspace; re-adding it requires verification from scratch.\n\n- API: `DELETE /email/sending-identities/{identity}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/email/sending-identities/{identity}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email inbox search\n\nSearch authorized synced mailbox headers with bounded cursor pagination. isDone covers stored records, not provider completeness.\n\n- API: `GET /email/inbox/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/inbox/search\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email inbox thread\n\nRead a bounded page of synced headers using an exact thread handle from inbox search; bodies remain on demand.\n\n- API: `GET /email/inbox/threads/{threadHandle}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/inbox/threads/{threadHandle}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email inbox message\n\nRead a bounded stored body using an exact message handle from inbox search; rechecks mailbox and record privacy.\n\n- API: `GET /email/inbox/messages/{messageHandle}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/inbox/messages/{messageHandle}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email draft create\n\nCreate an editable Dench email draft and synchronize its selected native mailbox asynchronously. Use a stable requestId for retries.\n\n- API: `POST /email/drafts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/drafts\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"requestId\": \"string\"\n }'\n```\n\n### dench email draft show\n\nRead an email draft, eligible senders and provider sync status.\n\n- API: `GET /email/drafts/{draftId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/drafts/{draftId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email draft senders\n\nList native mailboxes this caller may use.\n\n- API: `GET /email/drafts/senders`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/drafts/senders\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email draft update\n\nSave draft content using expectedRevision; sender changes require a new draft after provider binding.\n\n- API: `PATCH /email/drafts/{draftId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/email/drafts/{draftId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"expectedRevision\": 0,\n \"patch\": {}\n }'\n```\n\n### dench email draft send\n\nSend the current Dench draft revision through its native mailbox. Repeated requests share a durable receipt.\n\n- API: `POST /email/drafts/{draftId}/send`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/drafts/{draftId}/send\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"expectedRevision\": 0\n }'\n```\n\n### dench email draft attach\n\nUpload attachment bytes authorized against this draft before adding its storage reference.\n\n- API: `POST /email/drafts/{draftId}/attachments`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/drafts/{draftId}/attachments\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"string\",\n \"contentType\": \"string\",\n \"contentBase64\": \"string\"\n }'\n```\n\n### dench email draft signature\n\nLoad the selected mailbox signature for explicit visible insertion.\n\n- API: `GET /email/drafts/{draftId}/signature`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/drafts/{draftId}/signature\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email send [--mailbox <id/email>]\n\nSend through a native Gmail or Outlook mailbox with a durable request receipt. Only use for an explicit send request.\n\n- API: `POST /email/native/send`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/native/send\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"requestId\": \"send-intro-001\",\n \"to\": [\n {\n \"email\": \"ada@example.com\",\n \"name\": \"Ada\"\n }\n ],\n \"subject\": \"Introduction\",\n \"textBody\": \"Hello Ada\"\n }'\n```\n\n### dench email send --from <verified-email>\n\nSend one raw email (no campaign): to/cc/bcc, custom from-name and reply-to, optional reply threading via replyToMessageId.\n\n- API: `POST /email/send`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/send\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"fromEmail\": \"founder@example.com\",\n \"to\": [\n {\n \"email\": \"ada@lovelace.dev\",\n \"name\": \"Ada\"\n }\n ],\n \"subject\": \"Quick intro\",\n \"htmlBody\": \"<p>Hi Ada — great meeting you!</p>\"\n }'\n```\n\n### dench email message status\n\nRead a raw email message's status and open/click counters.\n\n- API: `GET /email/messages/{messageId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/messages/{messageId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email message list\n\nList recent raw email messages for the workspace.\n\n- API: `GET /email/messages`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/messages\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email template create\n\nCreate a managed email campaign template.\n\n- API: `POST /email/templates`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/templates\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Intro outreach\",\n \"subject\": \"Hi {{firstName}}\",\n \"htmlBody\": \"<p>Hi {{firstName}}, saw your work at {{company}}.</p>\"\n }'\n```\n\n### dench email template preview\n\nPreview a managed email campaign template.\n\n- API: `POST /email/templates/{templateId}/preview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/templates/{templateId}/preview\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"data\": {\n \"firstName\": \"Ada\",\n \"company\": \"Lovelace Labs\"\n }\n }'\n```\n\n### dench email campaign create\n\nCreate a managed email campaign draft from a connected inbox or verified sender.\n\n- API: `POST /email/campaigns`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Q2 outreach\",\n \"identityId\": \"founder@example.com\",\n \"templateId\": \"etpl_abc123\"\n }'\n```\n\n### dench email campaign status\n\nRead campaign status and counters.\n\n- API: `GET /email/campaigns/{campaignId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/campaigns/{campaignId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign recipients add\n\nAdd recipients to a managed email campaign.\n\n- API: `POST /email/campaigns/{campaignId}/recipients`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/recipients\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"recipients\": [\n {\n \"email\": \"ada@lovelace.dev\",\n \"displayName\": \"Ada Lovelace\",\n \"personalization\": {\n \"firstName\": \"Ada\",\n \"company\": \"Lovelace Labs\"\n }\n }\n ]\n }'\n```\n\n### dench email campaign preview\n\nPreview rendered messages for a campaign sample.\n\n- API: `POST /email/campaigns/{campaignId}/preview`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/preview\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"sample\": 5\n }'\n```\n\n### dench email campaign submit\n\nSubmit a campaign for approval or sending.\n\n- API: `POST /email/campaigns/{campaignId}/submit`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/submit\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign pause\n\nPause a sending email campaign.\n\n- API: `POST /email/campaigns/{campaignId}/pause`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/pause\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign resume\n\nResume a paused email campaign.\n\n- API: `POST /email/campaigns/{campaignId}/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign cancel\n\nCancel an email campaign.\n\n- API: `POST /email/campaigns/{campaignId}/cancel`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/cancel\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign list\n\nList managed email campaigns (paginated, optional status filter).\n\n- API: `GET /email/campaigns`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/campaigns\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign recipients list\n\nList a campaign's recipients (paginated, optional status filter).\n\n- API: `GET /email/campaigns/{campaignId}/recipients`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/campaigns/{campaignId}/recipients\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email campaign recipients add-from-object\n\nAdd campaign recipients from a CRM object: pick the object, the email field, and the entry ids.\n\n- API: `POST /email/campaigns/{campaignId}/recipients/from-object`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/campaigns/{campaignId}/recipients/from-object\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence create\n\nCreate a follow-up sequence from a connected inbox or verified sender.\n\n- API: `POST /email/sequences`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence update\n\nUpdate a sequence's name, sender, or reply/stop settings.\n\n- API: `POST /email/sequences/{sequenceId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence activate\n\nActivate a sequence so its enrollments begin sending.\n\n- API: `POST /email/sequences/{sequenceId}/activate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/activate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence deactivate\n\nDeactivate a sequence (pause sending, revert to draft).\n\n- API: `POST /email/sequences/{sequenceId}/deactivate`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/deactivate\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence archive\n\nArchive a sequence (stops all sending).\n\n- API: `POST /email/sequences/{sequenceId}/archive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/archive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence list\n\nList the workspace's follow-up sequences.\n\n- API: `GET /email/sequences`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/sequences\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence status\n\nRead a sequence with its ordered steps.\n\n- API: `GET /email/sequences/{sequenceId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/sequences/{sequenceId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence steps add\n\nAdd a step (subject, body, and wait delay) to a sequence.\n\n- API: `POST /email/sequences/{sequenceId}/steps`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/steps\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence steps update\n\nUpdate a sequence step's subject, body, or delay.\n\n- API: `POST /email/sequences/steps/{stepId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/steps/{stepId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence steps remove\n\nRemove a step from a sequence.\n\n- API: `POST /email/sequences/steps/{stepId}/remove`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/steps/{stepId}/remove\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence steps reorder\n\nReorder a sequence's steps.\n\n- API: `POST /email/sequences/{sequenceId}/steps/reorder`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/steps/reorder\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enroll\n\nEnroll explicit recipients into a sequence.\n\n- API: `POST /email/sequences/{sequenceId}/enroll`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/enroll\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enroll-from-object\n\nEnroll people from a CRM object: pick the object, the email field, and the entry ids.\n\n- API: `POST /email/sequences/{sequenceId}/enroll/from-object`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/{sequenceId}/enroll/from-object\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enrollments list\n\nList a sequence's enrollments (paginated, optional status filter).\n\n- API: `GET /email/sequences/{sequenceId}/enrollments`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/email/sequences/{sequenceId}/enrollments\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enrollment pause\n\nPause one enrollment.\n\n- API: `POST /email/sequences/enrollments/{enrollmentId}/pause`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/enrollments/{enrollmentId}/pause\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enrollment resume\n\nResume one paused enrollment.\n\n- API: `POST /email/sequences/enrollments/{enrollmentId}/resume`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/enrollments/{enrollmentId}/resume\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench email sequence enrollment stop\n\nStop one enrollment (no further steps send).\n\n- API: `POST /email/sequences/enrollments/{enrollmentId}/stop`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/email/sequences/enrollments/{enrollmentId}/stop\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Environments\n\n### dench env list\n\nList workspace-shared reusable setups and ready revisions (metadata only).\n\n- API: `GET /environments`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/environments\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench env show\n\nInspect a saved setup, its manifest, and an optional immutable revision.\n\n- API: `GET /environments/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/environments/{name}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench env save\n\nReserve an owner-bound source upload. Prefix the uploaded bytes with the returned proof before saving.\n\n- API: `POST /environments/uploads`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/environments/uploads\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"kind\": \"string\",\n \"size\": 0,\n \"sha256\": \"string\"\n }'\n```\n\n### dench env save\n\nPublish an explicitly saved source and manifest for one-time preparation. Returns pending/building until verified; does not run the task.\n\n- API: `POST /environments/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/environments/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"manifest\": {},\n \"uploadId\": \"string\",\n \"storageId\": \"string\",\n \"sha256\": \"string\"\n }'\n```\n\n### dench env delete\n\nRetire a saved setup from new selection; retain immutable revisions and active job evidence.\n\n- API: `DELETE /environments/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/environments/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench env run\n\nRun a command with prepared dependencies and declared credentials, saving declared state with a revision check.\n\n- API: `POST /local/environments/run`\n- Auth: No bearer token required.\n\n```bash\n# dench env run\n# Local-only: Execution occurs in the CLI process. Use dench env run NAME -- COMMAND; secret-bearing execution resolution is not a general REST read endpoint.\n```\n\n## Files\n\n### dench files ls\n\nList workspace files.\n\n- API: `GET /files`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/files\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench files cat\n\nRead a workspace file's text.\n\n- API: `GET /files/content`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/files/content?path=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench files write\n\nWrite a workspace file's text.\n\n- API: `PUT /files/content`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/files/content\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"path\": \"string\",\n \"content\": \"string\"\n }'\n```\n\n### dench files download\n\nGet a signed file download URL.\n\n- API: `GET /files/download-url`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/files/download-url?path=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench files rm\n\nRemove a workspace file or directory.\n\n- API: `DELETE /files`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/files\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"path\": \"string\"\n }'\n```\n\n### dench files mv\n\nMove a workspace file or directory.\n\n- API: `POST /files/move`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/files/move\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"from\": \"string\",\n \"to\": \"string\"\n }'\n```\n\n### dench files mkdir\n\nCreate a workspace directory (and any missing parents). Idempotent.\n\n- API: `POST /files/mkdir`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/files/mkdir\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"path\": \"string\"\n }'\n```\n\n### dench stage\n\nStage uploaded content into the workspace.\n\n- API: `POST /files/stage`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/files/stage\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Gateway\n\n### dench search\n\nSearch the web through the Dench gateway.\n\n- API: `POST /search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"query\": \"latest AI CRM workflows\",\n \"numResults\": 5\n }'\n```\n\n### dench search contents\n\nFetch page contents through the Dench gateway.\n\n- API: `POST /search/contents`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/search/contents\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"urls\": []\n }'\n```\n\n### dench search answer\n\nAnswer a question with web search.\n\n- API: `POST /search/answer`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/search/answer\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"query\": \"string\"\n }'\n```\n\n### dench web scrape\n\nRead a page as clean Markdown through Dench web.\n\n- API: `POST /context/web-scrape-markdown`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-scrape-markdown\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"url\": \"https://example.com\",\n \"useMainContentOnly\": true\n }\n }'\n```\n\n### dench web brand\n\nLook up a brand kit from a domain or email.\n\n- API: `POST /context/brand-retrieve`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/brand-retrieve\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"domain\": \"stripe.com\"\n }\n }'\n```\n\n### dench web sitemap\n\nList sitemap URLs for a domain.\n\n- API: `POST /context/web-sitemap`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-sitemap\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"domain\": \"example.com\",\n \"maxLinks\": 1000\n }\n }'\n```\n\n### dench web crawl\n\nCrawl a site to Markdown (capped).\n\n- API: `POST /context/web-crawl`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-crawl\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"url\": \"https://example.com\",\n \"maxPages\": 15,\n \"useMainContentOnly\": true\n }\n }'\n```\n\n### dench web screenshot\n\nCapture a rendered page screenshot.\n\n- API: `POST /context/web-screenshot`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-screenshot\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"directUrl\": \"https://example.com\",\n \"fullScreenshot\": false\n }\n }'\n```\n\n### dench web extract\n\nExtract typed fields from a page using a JSON Schema.\n\n- API: `POST /context/web-extract`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-extract\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"url\": \"https://example.com\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"title\": {\n \"type\": \"string\"\n }\n }\n }\n }\n }'\n```\n\n### dench web product\n\nExtract a product listing from a URL.\n\n- API: `POST /context/web-product`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-product\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"url\": \"https://example.com/product\"\n }\n }'\n```\n\n### dench web competitors\n\nFind competitors of a domain.\n\n- API: `POST /context/web-competitors`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/web-competitors\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"domain\": \"stripe.com\",\n \"numCompetitors\": 5\n }\n }'\n```\n\n### dench web styleguide\n\nRead a brand styleguide from a domain.\n\n- API: `POST /context/brand-styleguide`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/brand-styleguide\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"domain\": \"stripe.com\"\n }\n }'\n```\n\n### dench web fonts\n\nRead site fonts from a domain.\n\n- API: `POST /context/brand-fonts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/brand-fonts\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"domain\": \"stripe.com\"\n }\n }'\n```\n\n### dench web classify\n\nClassify a domain with NAICS or SIC.\n\n- API: `POST /context/classify-naics`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/classify-naics\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"input\": \"stripe.com\"\n }\n }'\n```\n\n### dench web brand-search\n\nAutocomplete brand names.\n\n- API: `POST /context/brand-search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/context/brand-search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"input\": {\n \"query\": \"stripe\"\n }\n }'\n```\n\n### dench image generate\n\nGenerate an image through the Dench gateway.\n\n- API: `POST /images/generations`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/images/generations\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"prompt\": \"A minimal flat-vector app icon\",\n \"size\": \"1024x1024\"\n }'\n```\n\n### dench image edit\n\nEdit an image through the Dench gateway.\n\n- API: `POST /images/edits`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/images/edits\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"prompt\": \"Make the background transparent\",\n \"input_images_base64\": [\n \"iVBORw0KGgoAAAANSUhEUg...\"\n ]\n }'\n```\n\n### dench integrations\n\nList every connected integration — connected apps plus the Gmail, Outlook, Calendar, LinkedIn and Slack connections Dench provides itself (Slack rows report source: dench).\n\n- API: `GET /integrations`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/integrations\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench tool status\n\nList connected tool accounts.\n\n- API: `GET /tools/status`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/tools/status\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench tool connect\n\nCreate a tool OAuth connection link. Slack is in-house, never a third-party connection: for toolkit slack the CLI prints the first-party install URL (/api/slack/install?slug=<workspace>, org admin) instead of calling this endpoint.\n\n- API: `POST /tools/connections`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/tools/connections\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench tool search\n\nSearch for external tool actions.\n\n- API: `POST /tools/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/tools/search\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"queries\": [\n {\n \"use_case\": \"list Slack channels\"\n }\n ]\n }'\n```\n\n### dench tool run\n\nRun an external tool action. SLACK_* slugs (SLACK_SEND_MESSAGE with Block Kit blocks/buttons, SLACK_FETCH_HISTORY, SLACK_LIST_CHANNELS, …) run through Dench's in-house Slack app install — any channel in the connected workspace — and are always preferred over any third-party Slack connection.\n\n- API: `POST /tools/run`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/tools/run\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"tool_slug\": \"SLACK_LIST_CHANNELS\",\n \"arguments\": {\n \"limit\": 10\n }\n }'\n```\n\n### dench tool disconnect\n\nDisconnect an external tool account.\n\n- API: `DELETE /tools/connections/{connectionId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/tools/connections/{connectionId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench tool labels\n\nList human names given to connected accounts.\n\n- API: `GET /tools/labels`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/tools/labels\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench tool label\n\nName a connected account, or clear its name with an empty string.\n\n- API: `PUT /tools/connections/{connectionId}/label`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/tools/connections/{connectionId}/label\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"displayName\": \"string\"\n }'\n```\n\n## Lists\n\n### dench lists\n\nList saved searches (find-result lists) in the workspace, newest first.\n\n- API: `GET /lists`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench lists list`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/lists\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists rows\n\nRead saved rows with current enrichment results and original indices; cursor-paged, without repeating a search.\n\n- API: `GET /lists/{artifactId}/rows`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/lists/{artifactId}/rows\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists enrich\n\nBuy contact details for 1–100 saved profiles and save them to the list. Skips fields already found, looked up empty, or in flight. Requires a signed-in member or their personal agent.\n\n- API: `POST /lists/{artifactId}/enrich`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/lists/{artifactId}/enrich\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"rows\": [],\n \"fields\": []\n }'\n```\n\n### dench artifacts import\n\nExplicitly import selected saved profiles, optionally filtered by enrichment, with a configured Lead status. Reuses CRM records; never sends outreach or triggers conversion.\n\n- API: `POST /lists/{artifactId}/import`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/lists/{artifactId}/import\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"to\": \"lead\"\n }'\n```\n\n### dench lists show\n\nGet one saved search / list by artifact id.\n\n- API: `GET /lists/{artifactId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/lists/{artifactId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists save\n\nSave find results as a named list (rows + filters become a workspace artifact).\n\n- API: `POST /lists`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench leads find --save-as \"Name\"`\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/lists\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"createdFrom\": \"find_people\",\n \"title\": \"string\"\n }'\n```\n\n### dench lists update\n\nUpdate a saved list in place (title, filters, and/or replacement rows).\n\n- API: `PATCH /lists/{artifactId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/lists/{artifactId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists rename\n\nRename a saved search / list.\n\n- API: `POST /lists/{artifactId}/rename`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/lists/{artifactId}/rename\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists delete\n\nDelete a saved search / list, its exported CSV/JSONL files, and any linked watch.\n\n- API: `DELETE /lists/{artifactId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/lists/{artifactId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists reviews\n\nRead durable enrichment activity (legacy review metadata remains readable). Use lists rows for current saved profiles and contacts.\n\n- API: `GET /lists/{artifactId}/reviews`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/lists/{artifactId}/reviews\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench lists assess\n\nSuggest ICP fit for one profile. Never changes a human review decision.\n\n- API: `POST /lists/{artifactId}/assess`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/lists/{artifactId}/assess\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"row\": {},\n \"suggestion\": {}\n }'\n```\n\n## Local\n\n### dench sessions\n\nList local CLI sessions.\n\n- API: `GET /local/sessions`\n- Auth: No bearer token required.\n\n```bash\n# dench sessions\n# Local-only: CLI sessions live in the caller's ~/.dench/config.json.\n```\n\n### dench use <session-key-or-workspace-slug>\n\nSelect a local CLI session.\n\n- API: `POST /local/sessions/use`\n- Auth: No bearer token required.\n\n```bash\n# dench use <session-key-or-workspace-slug>\n# Local-only: The server cannot mutate the caller's local CLI config.\n```\n\n### dench logout\n\nRemove local CLI sessions.\n\n- API: `POST /local/logout`\n- Auth: No bearer token required.\n\n```bash\n# dench logout\n# Local-only: The server cannot mutate the caller's local CLI config.\n```\n\n### dench backend show|set|clear\n\nConfigure the CLI backend target.\n\n- API: `POST /local/backend`\n- Auth: No bearer token required.\n\n```bash\n# dench backend show|set|clear\n# Local-only: Backend selection is local CLI state.\n```\n\n### dench crm import\n\nImport a local CSV into a CRM object.\n\n- API: `POST /local/crm/import`\n- Auth: No bearer token required.\n\n```bash\n# dench crm import\n# Local-only: Reads a CSV from the caller's local filesystem. Over the API, parse the CSV client-side and POST rows to /crm/objects/{objectName}/entries/batch.\n```\n\n### dench crm export\n\nExport a CRM object to a local CSV.\n\n- API: `POST /local/crm/export`\n- Auth: No bearer token required.\n\n```bash\n# dench crm export\n# Local-only: Writes a CSV to the caller's local filesystem. Over the API, call POST /crm/query and format CSV client-side.\n```\n\n### dench meetings import\n\nImport calls from a local CSV/JSONL: meeting fields plus transcript, action items and attendees per row.\n\n- API: `POST /local/meetings/import`\n- Auth: No bearer token required.\n\n```bash\n# dench meetings import\n# Local-only: Reads a CSV/JSONL from the caller's local filesystem. Over the API: POST /crm/objects/meeting/entries/batch with seedKey per row, then POST /meetings/{meetingEntryId}/transcript, POST …/action-items and PUT …/participants for each created meeting.\n```\n\n### dench fs\n\nRun the local file sync daemon.\n\n- API: `POST /local/fs`\n- Auth: No bearer token required.\n\n```bash\n# dench fs\n# Local-only: The fs daemon watches the caller's local /workspace mount.\n```\n\n## Meetings\n\n### dench meetings list\n\nList meetings, newest first, with status and participants.\n\n- API: `GET /meetings`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/meetings\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings transcript get\n\nRead a meeting's transcript, in order, one page at a time.\n\n- API: `GET /meetings/{meetingEntryId}/transcript`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/meetings/{meetingEntryId}/transcript\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings transcript set\n\nAppend up to 500 transcript segments to a meeting (speakers with an email link to existing people).\n\n- API: `POST /meetings/{meetingEntryId}/transcript`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/meetings/{meetingEntryId}/transcript\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"segments\": []\n }'\n```\n\n### dench meetings transcript clear\n\nDelete a batch of a meeting's transcript segments; repeat until `done` before re-appending.\n\n- API: `DELETE /meetings/{meetingEntryId}/transcript`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/meetings/{meetingEntryId}/transcript\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings action-items list\n\nList a meeting's action items.\n\n- API: `GET /meetings/{meetingEntryId}/action-items`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/meetings/{meetingEntryId}/action-items\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings action-items set\n\nAdd action items to a meeting; `replace: true` swaps the whole list.\n\n- API: `POST /meetings/{meetingEntryId}/action-items`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/meetings/{meetingEntryId}/action-items\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"items\": []\n }'\n```\n\n### dench meetings action-items done\n\nTick or untick one action item.\n\n- API: `PATCH /meetings/action-items/{itemId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/meetings/action-items/{itemId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"done\": true\n }'\n```\n\n### dench meetings action-items delete\n\nDelete one action item.\n\n- API: `DELETE /meetings/action-items/{itemId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/meetings/action-items/{itemId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings participants list\n\nWho was in the meeting, merged with the linked calendar invite.\n\n- API: `GET /meetings/{meetingEntryId}/participants`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/meetings/{meetingEntryId}/participants\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings participants set\n\nRecord attendees by name/email; known members and existing people are linked, nobody is created.\n\n- API: `PUT /meetings/{meetingEntryId}/participants`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/meetings/{meetingEntryId}/participants\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"participants\": []\n }'\n```\n\n### dench meetings share\n\nWhether a meeting is shared with the whole workspace, and whether you may change that.\n\n- API: `GET /meetings/{meetingEntryId}/sharing`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/meetings/{meetingEntryId}/sharing\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench meetings share --workspace\n\nShare one meeting with the workspace, or take it back to owner + invitees.\n\n- API: `PUT /meetings/{meetingEntryId}/sharing`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/meetings/{meetingEntryId}/sharing\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"shared\": true\n }'\n```\n\n## Members\n\n### dench members presence\n\nLive presence (online / away / offline) for workspace members.\n\n- API: `GET /members/presence`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/members/presence\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members get\n\nA member's profile: name, email, tagline, role, timezone, presence, open task count.\n\n- API: `GET /members/{userId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/members/{userId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members activity\n\nA member's recent comments and record changes across the CRM, newest first.\n\n- API: `GET /members/{userId}/activity`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/members/{userId}/activity\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members tasks\n\nOpen tasks assigned to a member (plus ones completed today).\n\n- API: `GET /members/{userId}/tasks`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/members/{userId}/tasks\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members me\n\nYour own member profile.\n\n- API: `GET /me/profile`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/me/profile\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members me --name … --tagline … --timezone …\n\nUpdate your name, tagline, avatar URL, or timezone.\n\n- API: `PATCH /me/profile`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/me/profile\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"tagline\": \"Head of Ops\",\n \"timezone\": \"America/New_York\"\n }'\n```\n\n### dench members me --avatar <file>\n\nGet a one-time URL to POST an avatar image to; then PUT /me/avatar with the returned storageId.\n\n- API: `POST /me/avatar/upload-url`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/me/avatar/upload-url\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench members me --avatar <file>\n\nSet your avatar from an uploaded storageId.\n\n- API: `PUT /me/avatar`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/me/avatar\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"storageId\": \"kg2abc123def456\"\n }'\n```\n\n### dench members me --clear-avatar\n\nRemove your avatar.\n\n- API: `DELETE /me/avatar`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/me/avatar\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Memory\n\n### dench memory search\n\nSearch durable workspace memory.\n\n- API: `GET /memory/search`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/memory/search?query=string\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench memory save\n\nSave a durable workspace memory fact.\n\n- API: `POST /memory`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/memory\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"key\": \"deployment-policy\",\n \"kind\": \"decision\",\n \"text\": \"Never deploy without human approval.\",\n \"tags\": [\n \"deployment\",\n \"policy\"\n ]\n }'\n```\n\n## Meta\n\n### dench help\n\nList all CLI/API operations and parity classifications.\n\n- API: `GET /commands`\n- Auth: No bearer token required.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/commands\"\n```\n\n## Notifications\n\n### dench notifications list\n\nList your notifications (inbox, unread, archived, or all).\n\n- API: `GET /notifications`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/notifications\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench notifications count\n\nHow many unread notifications you have.\n\n- API: `GET /notifications/unread-count`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/notifications/unread-count\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench notifications read\n\nMark a notification read (or unread).\n\n- API: `PATCH /notifications/{notificationId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/notifications/{notificationId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"read\": true\n }'\n```\n\n### dench notifications read-all\n\nMark every inbox notification read.\n\n- API: `POST /notifications/read-all`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/notifications/read-all\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench notifications archive\n\nArchive a notification.\n\n- API: `POST /notifications/{notificationId}/archive`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/notifications/{notificationId}/archive\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench notifications prefs\n\nRead your notification preferences.\n\n- API: `GET /notifications/preferences`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/notifications/preferences\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench notifications prefs --set\n\nUpdate your notification preferences.\n\n- API: `PATCH /notifications/preferences`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/notifications/preferences\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"emailEnabled\": true,\n \"perKind\": {\n \"entry_activity\": {\n \"email\": false\n }\n }\n }'\n```\n\n## Routines\n\n### dench cron list\n\nList routines.\n\n- API: `GET /routines`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n- Aliases: `dench routine list`, `dench routines list`\n\n```bash\ncurl -sS \"$DENCH_API_BASE/routines\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron history\n\nList routine run history.\n\n- API: `GET /routines/history`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/routines/history\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron get\n\nGet a routine.\n\n- API: `GET /routines/{jobId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/routines/{jobId}\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron create\n\nCreate a routine.\n\n- API: `POST /routines`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/routines\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"name\": \"Daily digest\",\n \"prompt\": \"Summarize open CRM tasks.\",\n \"schedule\": {\n \"kind\": \"every\",\n \"everyMs\": 86400000\n }\n }'\n```\n\n### dench cron update\n\nUpdate a routine.\n\n- API: `PATCH /routines/{jobId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/routines/{jobId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron delete\n\nDelete a routine.\n\n- API: `DELETE /routines/{jobId}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/routines/{jobId}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron enable\n\nEnable a routine.\n\n- API: `POST /routines/{jobId}/enable`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/routines/{jobId}/enable\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron disable\n\nDisable a routine.\n\n- API: `POST /routines/{jobId}/disable`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/routines/{jobId}/disable\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron run\n\nRun a routine now.\n\n- API: `POST /routines/{jobId}/run`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X POST \"$DENCH_API_BASE/routines/{jobId}/run\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench cron runs\n\nList runs for a routine.\n\n- API: `GET /routines/{jobId}/runs`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/routines/{jobId}/runs\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Secrets\n\n### dench secrets list\n\nList workspace-shared credential names, kinds and versions; never values.\n\n- API: `GET /secrets`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/secrets\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench secrets set\n\nEncrypt a workspace credential. Use CLI stdin or the secure chat form; return metadata only. Do not put values in chat, manifests or scripts.\n\n- API: `PUT /secrets/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/secrets/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"kind\": \"env\",\n \"value\": \"string\"\n }'\n```\n\n### dench secrets delete\n\nRevoke a workspace credential for future resolution, optionally checking its version.\n\n- API: `DELETE /secrets/{name}`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X DELETE \"$DENCH_API_BASE/secrets/{name}\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n## Settings\n\n### dench settings sync\n\nRead the workspace's Sync switches (accounts from email, contacts from LinkedIn, Slack Connect, calendar, dossier, tasks from email, lead auto-qualify, summaries and Brief). All on by default.\n\n- API: `GET /settings/sync`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/settings/sync\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench settings sync set\n\nFlip Sync switches (admin). Partial patch: only the keys sent change. Off stops new work; nothing already created is removed.\n\n- API: `PATCH /settings/sync`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PATCH \"$DENCH_API_BASE/settings/sync\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"linkedinContacts\": false\n }'\n```\n\n## Workspace\n\n### dench context --sections\n\nRead selected scoped workspace documents and a compact context index without writes.\n\n- API: `GET /context/sections`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/context/sections\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context\n\nReturn the current Dench workspace context for the bearer.\n\n- API: `GET /context`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/context\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context --instructions\n\nReturn the current workspace's standing instructions for external agents.\n\n- API: `GET /context/instructions`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/context/instructions\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench status\n\nReturn workspace and agent status.\n\n- API: `GET /status`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/status\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench agents\n\nList agents visible in the workspace status payload.\n\n- API: `GET /agents`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/agents\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench artifacts\n\nList artifacts for the authenticated workspace.\n\n- API: `GET /artifacts`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/artifacts\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench suggested-work\n\nList draft suggested-work artifacts.\n\n- API: `GET /suggested-work`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS \"$DENCH_API_BASE/suggested-work\" -H \"Authorization: Bearer $DENCH_API_KEY\"\n```\n\n### dench context set rules\n\nUpdate standing workspace rules; credentials belong in secrets and runnable setup in environments.\n\n- API: `PUT /context/rules`\n- Auth: Requires `Authorization: Bearer $DENCH_API_KEY` or an approved `dch_agent_*` session token.\n\n```bash\ncurl -sS -X PUT \"$DENCH_API_BASE/context/rules\" \\\n -H \"Authorization: Bearer $DENCH_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n --data '{\n \"content\": \"string\"\n }'\n```\n"
|
|
16
16
|
},
|
|
17
17
|
"references/APPS.md": {
|
|
18
18
|
"sha256": "8e9faaf4a7aa453181e7ddc4b7606baa8238f9def2fabb21a95aa4baa83e9a87",
|
|
@@ -31,8 +31,8 @@
|
|
|
31
31
|
"content": "---\nname: campaigns\ndescription: \"Build, run and fix email + LinkedIn outreach campaigns with `dench campaign` (CLI/API), starting from a raw brief: ask the setup questions with recommended answers from organization memory, then build from any of the five sources (buying signals, lookalike of a best lead, pasted leads or CSV, CRM records, a people search), write steps and personalized lines, set senders, schedule and approval, check launch readiness, launch, run signals now, approve new people, then track replies, the funnel and hold reasons. Use for any request to set up, edit, duplicate, delete or monitor an outreach, cold-email or LinkedIn campaign or sequence.\"\n---\n\n# Dench Outreach Campaigns\n\nAn **outreach campaign** sends a sequence of steps — emails from a connected\nGmail/Outlook mailbox, LinkedIn profile visits, connection requests and\nmessages from a connected LinkedIn account — to a list of people, one person\nat a time, inside a send window. The steps run in order, or as a workflow\nwhose If / else and Wait for them to accept steps send people down different\npaths. It is the Outreach → Campaigns page in the\nDench app, and everything that page does is also a `dench campaign …` command\nor an API call. Every command takes `--json`. Notices and cost lines go to\nstderr and stdout is plain JSON, so `> file.json` is safe.\n\n`draft`, `create`, `duplicate` and `get` include named `references`, a canonical\n`href`, and an absolute `url` when the connected workspace slug is available.\nLink the campaign name using that result rather than displaying its raw ID or\nmaking an extra lookup to construct a URL. `list --with-references --json` wraps\nthe ordinary list in `{data, references, referenceCoverage}`; plain `list --json`\nstill returns the original array. The reference identity is the Outreach\n`sequenceId`, never the separate CRM campaign mirror's entry ID.\n\nCampaign analytics scans the full history in bounded server-side pages. The\nJSON result includes `startedAt` and `computedAt`: totals reflect that\nobservation interval, not an atomic snapshot while sending continues. The\ndashboard refreshes every minute.\n\nNot this skill: one-shot newsletters and raw `dench email send` live in\n`email-campaigns`. Prospecting on its own (no campaign) is `sales` / `dench\nleads find`. A CRM record's history is `crm`.\n\n## Ask first, with recommended answers\n\nBefore building anything, settle the campaign with the user in ONE message of\nshort numbered questions. Every question carries a **recommended answer** the\nuser can accept with \"yes\" or a number. Never send a question without one,\nand never ask what the brief already answers. Say what you inferred instead.\n\n**Where the recommendations come from**, in this order:\n\n1. **Organization memory**: the `## Organisation` section of your system\n prompt, or `read_file /ORGANISATION.md`. It says what the company sells,\n to whom, the market, competitors and voice.\n2. **`dench campaign builder profile --json`** (free). It returns the\n workspace's saved ICP (`targeting`), suggested targeting, `defaultSignals`,\n suggested terms per signal (`suggestions`), and whether a LinkedIn account\n and a mailbox are connected (`hasLinkedin`, `hasMailbox`).\n3. **`dench campaign accounts --json`** for the sender ids.\n\nIf organization memory says nothing about what the company sells or who it\nsells to, ask that first: \"What do you sell, and who buys it?\" Offer to save\nthe answer with `update_organisation`, then derive the rest from it.\nRecommendations must come from these sources. Never fill them with generic\nB2B defaults.\n\n**The questions** (skip any the brief settles; keep each to one line plus the\nrecommendation):\n\n| # | Ask | Recommend |\n|---|---|---|\n| 1 | **Where people come from**: Signals (people showing buying intent), Lookalike (people like your best lead), Existing leads (paste or CSV), From CRM, or Find new people (a filtered search) | Signals when organization memory describes a problem people post or hire for; Lookalike when the user names a best customer; From CRM when they mean people they already know |\n| 2 | **Who**: titles, industries, company sizes, locations, who to leave out | The ICP from organization memory and `builder profile`. Name competitors from memory as exclusions |\n| 3 | **Which signals and terms** (signals only) | `defaultSignals`, plus 2-4 topics from `suggestions` rewritten as **what the buyer does**, e.g. \"using AI for outbound\" rather than \"Claude\" (see Topics below) |\n| 4 | **Channels and goal**: email, LinkedIn or both; what a reply should lead to; tone | Both when `hasLinkedin` and `hasMailbox`, else the connected one; the goal and tone from organization memory |\n| 5 | **Who sends and when**: mailboxes and LinkedIn accounts, days, hours, timezone, daily email cap | Every connected account, Mon-Fri 9-17 in the user's timezone, 30 emails a day |\n| 6 | **Approval** (signals and lookalike): new people start on their own, or wait for approval | Manual review (the app's default) for a new campaign; automatic once the first week's people look right |\n| 7 | **How often signals run** and whether to add matching people without a signal | Daily; add matching people off |\n\nAfter the answers, restate the plan in five lines (source, who, signals,\nchannels and senders, approval) and say what will cost money before any\nbillable step.\n\n## Build a campaign from a brief\n\nThe brief can be an ICP document, a list of titles and companies, a sequence\nexported from another outreach tool, or one sentence. Follow these steps in\norder. Only step 3 (search), step 6 (AI lines) and step 9 (launch) spend money\nor send messages; say so before each one and wait for a yes before step 9.\n\n### 0. Check the prerequisites\n\n- **Campaign commands available.** Run `dench campaign help` and confirm it\n lists `draft`, `search`, `add`, `steps`, `person` and `preview`. An older CLI\n answers \"Unknown campaign subcommand: search\". Update with `npm install -g @dench.com/cli@latest`,\n or run commands as `npx -y -p @dench.com/cli@latest dench …`. The CLI comes\n preinstalled in a Dench chat sandbox. When testing a source checkout, check\n its campaign help: commands can be available before a release version bump.\n- **A workspace member's credentials.** `dench signin` (the human approves a\n link), a member-bound `DENCH_API_KEY`, or an agent session a member created.\n An organization-only key is refused with \"Outreach needs a workspace\n member's credentials\". Check with `dench context --json`.\n- **A paid workspace with credits.** Search and AI lines are billed to the\n workspace. `dench billing status --json` shows the balance; `dench upgrade`\n and `dench billing topup --amount 10` give the human a link.\n- **Connected senders.** `dench campaign accounts --json` must list a mailbox\n (for email steps) and/or a LinkedIn account (for LinkedIn steps). If a\n channel is empty, `dench tool connect gmail` (or `outlook`, `linkedin`)\n prints a sign-in link; the human opens it, then run `dench campaign\n accounts` again. Ids from this command go into `--email-mailboxes` and\n `--linkedin-accounts`.\n\n### 1. Turn the brief into a plan\n\nPull these out of the brief and ask the user only for what is missing:\n\n| Need | Where it goes |\n|---|---|\n| Who to reach: titles, seniority, industries, company size, places | search filters (step 3) |\n| Who to leave out: competitors, dev shops, current clients, wrong industries | exclusions (step 3) |\n| How many people | one campaign holds at most 300 (step 4) |\n| Channels and timing: which touches, how many days apart | `steps.json` (step 7) |\n| Branches: \"if they're connected…\", \"if they don't accept…\", \"if their title contains…\" | a workflow `steps.json` (step 7) |\n| What changes per person: first name, company, a role or reason to write | variables (steps 5 and 6) |\n| Timezone, days and hours, daily email cap, which accounts send | the draft (step 2) |\n| Buying signals (hiring, funding, launches, new leaders, post engagement) | the signal builder, below, instead of steps 3 and 4 |\n\nFilter names, exact values and ranges: `dench leads filters` (free) lists\nthem, `dench leads filters --filter industries --search \"financial\"` finds an\nexact industry name. Company size is a headcount bucket (`1-10`, `11-50`,\n`51-200`, `201-500`, `501-1000`, `1001-5000`, `5001-10000`, `10001+`); there is\nno revenue filter.\n\n### 2. Create the draft\n\n```bash\ndench campaign draft --name \"Fintech engineering leaders\" \\\n --request-id fintech-eng-leaders-q4 --timezone America/New_York \\\n --window \"Mon-Fri 9-17\" --daily-cap 30 \\\n --email-mailboxes <mailboxId> --linkedin-accounts <linkedinAccountId> --json\n```\n\n`--request-id` (8-64 characters) makes a retry return the same draft instead of\na second one. Without sender flags the draft sends from every running account\nyou own; the output says which. A draft sends nothing.\n\n### 3. Search, with exclusions\n\n```bash\ncat > filters.json <<'EOF'\n{\n \"titles\": [\"CTO\", \"VP Engineering\", \"Head of Engineering\"],\n \"industries\": [\"Financial Services\", \"Hospitals and Health Care\"],\n \"headcountRanges\": [\"51-200\", \"201-500\", \"501-1000\"],\n \"locations\": [\"United States\"]\n}\nEOF\n\ndench campaign search --filters @filters.json \\\n --not-industries \"IT Services and IT Consulting,Staffing and Recruiting\" \\\n --not-company-keywords \"software outsourcing\" \\\n --not-domains competitor.com,current-client.com \\\n --limit 25 --out audience.json\n```\n\n- **Cost: 1 cent per person returned**, billed on what comes back, not on the\n limit. The most a call can cost prints on stderr before it runs, and the\n result carries `estimatedCents` and `chargedCents`. There is no free preview;\n start with `--limit 25`, read the sample, then widen.\n- **Exclusions.** `--not-<filter>` (or `--exclude-<filter>`) works on every list\n filter, for example `--not-industries`, `--not-titles`, `--not-company-names`,\n `--not-company-keywords`; `--not-domains` is short for `--not-company-domains`.\n In JSON an exclusion is `{\"value\":\"Staffing and Recruiting\",\"exclude\":true}`\n inside that filter's list. A search still needs at least one include filter.\n- `--limit` is at most 100 per search. Continue with `--page-token\n <nextPageToken>` from the previous result (even after an empty page); keep the\n same filters.\n- `--out audience.json` writes the full result, complete profiles included, and\n the terminal shows a short summary. `--raw` prints the full result instead of\n writing a file. The file is checked before the search is billed: its folder\n must exist and the file must not (`--force` replaces it), so give each page\n its own name (`audience-2.json`). If the write still fails, the result prints\n on stdout with a `saveError` instead of being lost; do not run the search\n again.\n- Review before adding: `jq -r '.rows[] | [.name,.title,.company] | @tsv'\n audience.json`. Show the user 5-10 people and the cost so far. If the sample is\n wrong, change the filters and search again (each search is billed).\n\n### 4. Add the people\n\n```bash\ndench campaign add \"Fintech engineering leaders\" --people-file audience.json\n```\n\nThis adds the searched people without searching or paying again, up to 300\npeople per file, in batches of 50. New people become Leads in the CRM. The\nresult lists `added`, `duplicates`, `duplicatesElsewhere` (already queued or\nenrolled in another campaign, skipped unless `--allow-duplicates`), `suppressed`,\n`invalid`, `skippedNoIdentity`, `skippedMissingInfo` and `cappedAtLimit`. Read\nit back to the user.\n\nOther ways in, all with the same checks: `add --search '<filters json>'\n--limit 50` (search and add one page in a single billed call), `add --csv\npeople.csv`, `add --list <artifactId>`, `add --object lead --view \"<view>\"`,\n`add --name \"Ada\" --email ada@x.com`. See Add people below.\n\n- **A campaign holds 300 people**, counting stopped and finished ones. For a\n bigger audience, `dench campaign duplicate <campaign>` makes a new draft with\n the same steps, schedule, senders and lines and no people; add the next page\n of the search to the copy (`search --page-token …`). Duplicate checks include\n draft, active and paused campaigns, so someone queued or enrolled elsewhere\n is skipped.\n- People need an email for email steps and a LinkedIn profile URL for LinkedIn\n steps. A person without an email has their email steps skipped (launch warns);\n someone with neither is a launch blocker. Search results carry a LinkedIn URL\n and, when available, an email.\n- A mistake in a draft: `dench campaign remove <campaign> --person\n <enrollmentId|name>` takes a never-contacted person out and frees their place.\n\n### 5. Choose the variables\n\nA `{{token}}` or `[[token]]` in a subject or message is filled in per person.\nBoth forms work in email and LinkedIn messages, InMail subjects, previews and\nsends. Typing either opener brings up field suggestions, and choosing a field\nkeeps the brackets you started with:\n\n- **Fields of the person or their CRM row:** `{{First name}}`, `{{Company}}`,\n `{{Job Title}}`, `{{Website}}`, `{{Location}}` and any other column of the\n record.\n- **Values you supply.** In a `--people-file`, put them under `personalization`\n for each person: `{\"linkedinProfileUrl\":\"…\",\"personalization\":{\"fund\":\"Seed\n fund\",\"role_title\":\"Head of Data\"}}` makes `{{fund}}` and `{{role_title}}`. In\n a CSV every column that is not an email, LinkedIn URL or name becomes a value\n named after its header.\n- **Greeting names.** Built-in `name`, `firstName` and `lastName` are cleaned\n for greetings, so casing and credentials may change. Custom keys such as\n `first_name`, `Fund` and `role_title` keep the values you supply. To confirm\n an exact built-in name, use `dench campaign person set <campaign> --person\n <name> --field \"name=Hortensia Ruiz, MBA\"`.\n- **Fallbacks.** `{{First name || \"there\"}}` or `[[First name || \"there\"]]`.\n A plain token with no value for\n someone is a **launch blocker** for that person; a quoted fallback avoids it.\n Fix a single person before launch with `dench campaign person set\n <campaign> --person <name> --field \"Company=Acme\"`, or pull missing fields\n from their CRM record with `dench campaign sync <campaign>`.\n- **Brackets.** Write `{{First name}}` or `[[First name]]`, with a matching\n pair of double braces or square brackets. `steps set` refuses\n `{first_name}` or `{FIRST_NAME}`, which would go out exactly as typed; pass\n `--allow-single-braces` only when the braces are literal text.\n\n### 6. Optional: AI-written lines\n\nFor a line that must differ for every person (a reason to write, a comment on\ntheir company), define up to 5 AI-written lines. They cost about 3 cents a\nperson; say so, then:\n\n```bash\ncat > lines.json <<'EOF'\n{\n \"sells\": \"Senior engineers who join your team or own a build end to end\",\n \"lines\": [\n {\n \"label\": \"Why now\",\n \"instructions\": \"One sentence tying their company's business to engineering capacity.\",\n \"fallback\": \"building the roadmap faster\"\n }\n ]\n}\nEOF\ndench campaign personalize set \"Fintech engineering leaders\" --file lines.json\ndench campaign personalize get \"Fintech engineering leaders\"\n```\n\nUse the line in steps as `{{whyNow}}` (the key is made from the label; `get`\nprints it). Saving writes lines for up to 100 people right away; more waits\nfor `personalize write --yes`. Edit one person's line with `personalize edit`,\nredo it with `personalize rewrite`. Until a line is written the saved fallback\nis used and it never blocks launch.\n\n### 7. Write and check the steps\n\nFirst decide the shape. If everyone gets the same touches in the same order,\n`steps.json` is a plain JSON array in send order. If the brief says \"if …,\nthen …\" (connected or not, accepted or not, has an email or not, a field's\nvalue), it is a workflow: `{\"stepModel\":\"workflow\",\"steps\":[...]}` with\npaths (see Workflows below). Each step is one of `email`, `wait`,\n`linkedin_visit`, `linkedin_connection`, `linkedin_message`,\n`linkedin_like_post` or `linkedin_inmail`; a workflow can also use\n`condition` (If / else) and `wait_for_connection` (Wait for them to accept).\nTiming is a `wait` step between the\ntouches: wait hours = (day of this touch − day of the\nprevious touch) × 24. This example turns \"email day 1, LinkedIn connect day 2,\nLinkedIn message day 4 after they accept, email day 5 in the same thread,\nLinkedIn bump day 8, email day 10 in the same thread\" into steps:\n\n```json\n[\n {\n \"type\": \"email\",\n \"emailSubject\": \"Keep building while you hire\",\n \"emailTextBody\": \"{{First name || \\\"Hi\\\"}}, saw {{Company}} is hiring for {{role_title || \\\"engineering\\\"}}. We add senior engineers to your team or own a build end to end.\\n\\nWant me to send a few profiles?\"\n },\n { \"type\": \"wait\", \"waitHours\": 24 },\n {\n \"type\": \"linkedin_connection\",\n \"linkedinMessageBody\": \"{{First name || \\\"Hi\\\"}}, saw {{Company}} is hiring. We add senior engineers to your team on your hours. Open to connecting?\"\n },\n { \"type\": \"wait\", \"waitHours\": 48 },\n {\n \"type\": \"linkedin_message\",\n \"linkedinMessageBody\": \"Thanks for connecting, {{First name || \\\"there\\\"}}. Want me to send a few profiles that match your open roles?\",\n \"linkedinMessageMode\": \"wait_until_connected\",\n \"connectionTimeoutHours\": 336\n },\n { \"type\": \"wait\", \"waitHours\": 24 },\n {\n \"type\": \"email\",\n \"emailReplyToPrevious\": true,\n \"emailTextBody\": \"Following up on the {{role_title || \\\"engineering\\\"}} role. Can we find 15 minutes this week?\"\n },\n { \"type\": \"wait\", \"waitHours\": 72 },\n {\n \"type\": \"linkedin_message\",\n \"linkedinMessageBody\": \"Circling back, {{First name || \\\"there\\\"}}: worth 15 minutes this week?\",\n \"linkedinMessageMode\": \"skip_if_not_connected\"\n },\n { \"type\": \"wait\", \"waitHours\": 48 },\n {\n \"type\": \"email\",\n \"emailReplyToPrevious\": true,\n \"emailTextBody\": \"Last note from me. Want me to send a few profiles?\"\n }\n]\n```\n\n```bash\ndench campaign steps set \"Fintech engineering leaders\" --file steps.json\ndench campaign preview \"Fintech engineering leaders\" --person \"Ada Lovelace\"\n```\n\n`steps set` validates before it saves and refuses anything that would be\nsilently dropped or sent wrong (rules in Steps below). `preview` shows the exact\nmessages one person would get, with every token and AI line filled in, and\nsays what is missing or would be skipped; nothing is sent. Preview two or\nthree different people and show the user the text. In a workflow, `preview`\nshows the message of every path, and a person gets only the ones on the path\nthey take: say which path each message is on, or preview one with `--step N`.\n\nPost reactions, InMail and scheduled withdrawal of pending invitations are\nsupported; see the Steps section for their fields and limits. A plain list\nlike the one above runs every step in order for everyone; `onlyIf` on email\nand post-like steps and `linkedinMessageMode` adjust it to whether someone\nis connected. When the brief branches (\"if they are connected, message them;\nif not, send a connection request, wait 10 days for the accept and InMail the\nones who don't accept\"), write a workflow instead (Workflows under Steps):\neach step gets a `key` and says where it goes, and If / else (`condition`)\nand Wait for them to accept (`wait_for_connection`) steps choose the path.\nBefore saving, tell the user how you mapped the brief: each \"if\" and the\nstep that answers it, where the paths join again, where each one ends, and\nanything you changed because a workflow can't do it (a path that goes back\nto an earlier step, more than 20 steps). Dench also checks whether someone\nis already connected before sending an invitation.\n\n### 8. Check readiness\n\n```bash\ndench campaign launch \"Fintech engineering leaders\" --check --json\n```\n\n`--check` never launches. It lists each blocker with why it fires and the\ncommands that fix it, the warnings, the audience and step counts and the\n`fingerprint`, and exits 1 when blocked. Fix blockers (`steps set`, `add`,\n`remove`, `person set`, `set`) and run it again until it exits 0.\n\nThen show the user, in one message: the number of people and five examples, the\nsteps as rendered by `preview`, the schedule and timezone, the daily email cap,\nthe sending accounts, what has been spent, and that LinkedIn steps break\nLinkedIn's terms and can get the account restricted. Ask for a clear yes.\n\n### 9. Launch and watch\n\n```bash\ndench campaign launch \"Fintech engineering leaders\" --ack-linkedin-risk\ndench campaign get \"Fintech engineering leaders\"\ndench campaign replies \"Fintech engineering leaders\" --since 7d\n```\n\n`--ack-linkedin-risk` is required only when the campaign has LinkedIn steps and\nonly after the user accepts the notice. `launch` without `--check` launches as\nsoon as the campaign is ready. After launch:\n\n- `get` is the dashboard: funnel, what is sending now, what comes next and\n why anything is holding (hold reasons clear on their own; report the hold,\n not a failure). `events` is the activity log; `people --status replied` lists\n who answered; `replies` shows what they wrote; `pipeline` shows where people\n sit in the lead pipeline.\n- Change wording or waits in place with `steps edit`; stop a person with `stop`;\n `pause` and `resume` the whole campaign.\n- Replying to a prospect happens in the Inbox in the Dench app.\n\n### Fixing mistakes\n\n| Mistake | Fix |\n|---|---|\n| Added the wrong person (draft) | `dench campaign remove <c> --person <id>` |\n| Wrong email or LinkedIn URL (draft) | `dench campaign person set <c> --person <id> --email … --linkedin-url …` |\n| Typo in a message after launch | `dench campaign steps edit <c> --file steps.json` |\n| Step types, order or a workflow's paths must change after launch | `steps edit` keeps them fixed. `dench campaign duplicate <c>`, fix the copy, and add only people who were never contacted to it |\n| Person should stop getting messages | `dench campaign stop <c> --person <id>` |\n| Whole campaign is wrong | `dench campaign pause <c>`, or `archive` / `delete` (same thing: stops everyone, erases nothing) |\n| A search was too broad | Nothing refunds a search; narrow the filters, and check `estimatedCents` first |\n\n## The New campaign flow (all five sources)\n\nThe app's **New campaign** page starts by asking where people come from. Each\nanswer to question 1 maps to commands:\n\n| Source | What it is | Commands |\n|---|---|---|\n| **Signals** | People showing buying intent, found again on a schedule | `builder save` (`\"source\":\"signals\"`) → `build` → `get` → `sequence`/`outreach` → `create` |\n| **Lookalike** | People like one best lead, found again on a schedule | `builder lookalike` → `save` (`\"source\":\"lookalike\"`, `\"signals\":[\"lookalike\"]`, `lookalike`) → the same as Signals |\n| **Existing leads** | A pasted list or a CSV | `draft` → `add --csv` / `--people-file` / `--name … --email …` (steps 2 and 4 above) |\n| **From CRM** | Records already in the CRM | `draft` → `add --object lead --view \"<view>\"` or `--entries` (Add people below) |\n| **Find new people** | A one-time filtered search | `draft` → `search` → `add --people-file` (steps 2-4 above) |\n\nSignals and Lookalike keep finding people after launch. The other three are a\nfixed list.\n\n### Signals and Lookalike, step by step\n\n```bash\ndench campaign builder profile --json # recommendations (free)\ndench campaign builder autofill --description \"VP Sales at US SaaS companies\" --json # optional: words -> targeting\ndench campaign builder estimate --data '{\"kind\":\"week\",\"targeting\":{...},\"signals\":[\"post_engagement\"],\"signalTerms\":{...}}' --json\ndench campaign builder save --file draft.json --json # -> draftId; nothing billed yet\ndench campaign builder build <draftId> --json # billable: finds the first people, writes openers\ndench campaign builder get <draftId> --json # poll until status is ready; review people and openers\ndench campaign builder opener <draftId> <leadId> --text \"...\" --json # fix an opener (\"\" resets it)\ndench campaign builder sequence <draftId> --goal \"Book a demo\" --help-with \"...\" --tone conversational --channels both --json\ndench campaign builder outreach <draftId> --file outreach.json --approval manual --json\ndench campaign builder create <draftId> --name \"...\" [--paused] --json # makes the campaign; does not launch\n```\n\nThen check readiness and launch as in steps 8 and 9 above. `create --paused`\nis the app's \"Save paused\": signals wait to run until launch.\n\n**`draft.json`** (every field the app saves):\n\n```json\n{\n \"clientRequestId\": \"ai-sales-leaders-2026-10\",\n \"name\": \"AI-curious sales leaders\",\n \"source\": \"signals\",\n \"targeting\": {\n \"titles\": [\"VP Sales\", \"Head of Sales\", \"CRO\"],\n \"industries\": [\"Software Development\"],\n \"companySizes\": [\"51-200\", \"201-500\"],\n \"locations\": [\"United States\"],\n \"excludes\": [\"competitor.com\"],\n \"companyTypes\": [\"Startup\"]\n },\n \"signals\": [\"post_engagement\", \"hiring\", \"funding\"],\n \"signalTerms\": {\n \"post_engagement\": [\"using AI for outbound\", \"AI SDR results\"],\n \"hiring\": [\"SDR\", \"Sales Development Representative\"]\n },\n \"findMoreMatching\": false\n}\n```\n\n- **Signals**: `post_engagement` (people who post or comment on a topic),\n `keyword` (posts mentioning a keyword), `hiring` (companies hiring a role),\n `funding`, `launch`, `new_leader`, `voice_engagement` (people engaging with\n chosen LinkedIn experts; terms are profile URLs, suggested by `builder voices\n --topics \"...\"`), `company_engagement` (people engaging with a company's or a\n competitor's page; terms are company page URLs), `brand_engagement` (people\n engaging with your own company page), and `lookalike` (Lookalike source\n only).\n- **Topics** (`post_engagement`, `keyword`): write what the buyer does or\n wants, not a bare product or brand name. Dench reads each topic for its\n meaning and searches for posts about that meaning, so \"Claude for GTM\" means\n sales teams using AI for sales, never posts that only mention Claude. A topic\n in `\"exact\": [\"keyword\"]` is searched as typed and the post must contain it.\n- **`findMoreMatching: true`** also adds people who match the audience without\n a signal.\n- **Lookalike**: `builder lookalike --linkedin-url <url>` returns the seed and\n an editable setup (role, `similarRoles`, `roles`, location, industry,\n `relatedIndustries`, `industries`, `companySizes`, similar `companies`).\n Show it to the user, apply their edits, and pass it as `lookalike` in\n `draft.json`. `--data '{\"suggest\":{\"title\":\"…\"}}'` suggests roles again;\n `--data '{\"rescope\":{\"seed\":{…},\"company\":\"…\"}}'` switches the company.\n\n**`outreach.json`** (the app's Outreach and Review screens):\n\n```json\n{\n \"brief\": {\"goal\": \"Book a demo\", \"helpWith\": \"...\", \"tone\": \"conversational\", \"channels\": \"both\"},\n \"steps\": [{\"type\": \"linkedin_connection\"}, {\"type\": \"wait\", \"waitHours\": 48}, {\"type\": \"email\", \"emailSubject\": \"...\", \"emailTextBody\": \"...\"}],\n \"sending\": {\"emailMailboxAccountIds\": [\"...\"], \"linkedinAccountIds\": [\"...\"], \"timezone\": \"America/New_York\",\n \"startHour\": 9, \"endHour\": 17, \"weekdays\": [1,2,3,4,5], \"dailySendCap\": 30},\n \"approvalMode\": \"manual\"\n}\n```\n\n`builder sequence` writes `steps` from the brief, as **Generate sequence**\ndoes (AI credits apply). Leave `steps` out of `outreach.json` after it, or use\n`--mode manual` with your own steps. In `weekdays`, 0 is Sunday.\n`approvalMode` `manual` (the default) holds each new person a signal finds\nuntil someone approves them. `auto` starts them on their own.\n\n**Drafts**: every save is resumable. `builder drafts` lists unfinished ones,\n`builder resume <draftId>` shows a draft's setup, `builder discard <draftId>`\ndrops it. `save` with the same `clientRequestId` updates the same draft.\n\n### A live signal campaign (the Sources tab)\n\n```bash\ndench campaign sources overview \"<campaign>\" --json # each signal: status, last/next run, people found, problems\ndench campaign sources run \"<campaign>\" --json # Run now (billable; 6 an hour; live campaigns only)\ndench campaign sources pending \"<campaign>\" --json # people waiting for approval\ndench campaign sources approve \"<campaign>\" --people <enrollmentId,...>\ndench campaign sources reject \"<campaign>\" --people <enrollmentId,...>\ndench campaign sources set \"<campaign>\" --approval auto\ndench campaign sources set \"<campaign>\" --data '{\"cadence\":\"weekly\"}'\ndench campaign sources set \"<campaign>\" --data '{\"signal\":{\"signal\":\"hiring\",\"enabled\":false}}'\ndench campaign sources set \"<campaign>\" --data '{\"terms\":{\"signal\":\"post_engagement\",\"values\":[\"using AI for outbound\"]}}'\ndench campaign sources preview \"<campaign>\" --signal hiring --json # sample results; enrolls no one\ndench campaign queue \"<campaign>\" --json # who goes out today, warmest first\n```\n\n- Each run continues where the last one stopped and skips people already in\n the campaign, so a quiet day means nothing new was posted, not a broken\n signal. `Run now` is for testing a change right away.\n- `sources set` takes one change per call: `status` (`active`/`paused`),\n `cadence` (`daily`/`weekly`/`monthly`), `findMoreMatching`, `approvalMode`,\n `targeting`, one `signal` on or off, or one signal's `terms`.\n- **Intent** (the bars next to each person on the Leads tab): High, Medium\n or Low. It weighs fit with the campaign's target titles and\n buyer profile first, then the signal. Someone outside the target titles is\n Low however strong their post. Warmer people go first in today's queue.\n Someone whose title is a different job altogether (HR commenting on a\n sales post; not just another word or level for a target title) is Low\n whatever they posted, and a signal lead like that is removed before\n anything is sent; the source won't add them again. Changing the target titles\n re-rates everyone in the campaign.\n\n## Commands\n\n`<campaign>` is a campaign **id or its exact name** (case-insensitive). When\ntwo live campaigns share a name the command fails and lists both ids; use the\nid. `dench campaign list` shows ids.\n\n### Browse and inspect\n\n```bash\ndench campaign list [--all] [--json] # live campaigns; --all includes archived\ndench campaign get <campaign> [--json] # status, schedule, funnel, Now/Next, holds, people\ndench campaign people <campaign> [--status <s>] [--json]\ndench campaign events <campaign> [--limit 50] [--max-pages 1] [--json]\ndench campaign accounts [--json] # email + LinkedIn sender ids, warm-up, availability and capacity\ndench campaign preview <campaign> [--person <enrollmentId|name>] [--step N] [--json]\ndench campaign person show <campaign> --person <enrollmentId|name> [--json]\ndench campaign replies <campaign> [--person <enrollmentId|name>] [--since 7d] [--limit 20] [--json]\ndench campaign pipeline <campaign> [--json]\ndench campaign where <entryId> [--json]\n```\n\n`people --status` accepts an enrollment status: `draft` (not launched yet),\n`active`, `paused`, `finished` (reached the end: every step of a plain list, or\nthe end of their path in a workflow), `replied`, `stopped`,\n`bounced`, `complained`, `unsubscribed`, `failed`.\n\n`events` is the campaign's activity log, newest first: added, launched,\nemail sent, connection request sent, accepted the connection, LinkedIn\nmessage sent, profile visited, replied, step skipped, step failed, needs a\nlook, paused, resumed, stopped, finished, bounced, unsubscribed, campaign\ncompleted, campaign picked back up, campaign archived. `--limit` is the page size (1-200);\n`--max-pages` drains more pages. `--json` returns `{ events, isDone,\ncontinueCursor }`.\n\n`preview` renders every email and LinkedIn step (or step N) for one person\n(the first person when `--person` is left out) with fields and AI lines filled\nin. In a workflow that is every path's messages; the person gets only the ones\non their path. `person show` lists each step a person reached with its outcome (sent,\nopened, clicked, skipped and why, waiting, failed), when, and the subject and\nstart of the text that was sent. `replies` lists the people who replied, newest\nfirst, with the text of their latest inbound email or LinkedIn message (up to\n400 characters, quoted history removed) and whether you have answered.\n`pipeline` counts a campaign's people at each lead Status. `where <entryId>`\nlists the campaigns a CRM person or lead is in and their status in each.\n\n### Create and configure\n\n```bash\ndench campaign create --name \"<name>\" [--timezone <IANA tz>] \\\n [--window \"<spec>\" ...] [--daily-cap 1-100] [--stop-on-reply|--no-stop-on-reply] \\\n [--email-mailboxes id1,id2] [--linkedin-accounts id1,id2] \\\n [--start <ISO date/time>] [--end <ISO date/time>] [--json]\n\ndench campaign draft [--name \"<name>\"] [--request-id <8-64 chars>] [same settings as create] [--json]\n\ndench campaign set <campaign> [--name \"<new name>\"] [--timezone <tz>] [--window \"<spec>\" ...] \\\n [--daily-cap 1-100] [--stop-on-reply|--no-stop-on-reply] \\\n [--email-mailboxes id1,id2|none] [--linkedin-accounts id1,id2|none] \\\n [--start <ISO>|--clear-start] [--end <ISO>|--clear-end] [--json]\n\ndench campaign duplicate <campaign> [--name \"<name>\"] [--json]\ndench campaign archive <campaign> [--json] # stops everyone still in flight; final\ndench campaign delete <campaign> [--json] # the same command, named like Delete in the app\n```\n\n`create` and `draft` make the same kind of draft; `draft` is the retry-safe\none (a stable `--request-id`) and the name is optional.\n\n- `--timezone` defaults to the machine's timezone (UTC in a sandbox — pass\n the user's zone). With no `--window`, the campaign gets one window:\n Mon-Fri 9-18 in that timezone.\n- `--daily-cap` is the number of cold emails per day across the campaign\n (default 30, max 100). LinkedIn has its own per-account limits, set on the\n account, not here.\n- `--email-mailboxes` and `--linkedin-accounts` select **sender pools on the\n campaign**, not on individual steps. Each accepts up to 50 account ids,\n comma-separated or as a JSON array. Only accounts both the caller and the\n campaign owner may use are accepted. The app puts these under **Settings →\n Sender pools**, with remaining-today counts and availability.\n- Omit a sender flag to preserve that channel's current configuration. Pass\n `none` or `'[]'` to clear it. Legacy per-step senders remain until that\n channel's pool is explicitly configured. Each person's assigned sender\n stays fixed through their conversation, including after a pool is changed;\n disconnecting it does not silently move the conversation to another sender.\n- API equivalents: `emailMailboxAccountIds` and `linkedinAccountIds` on\n `POST /campaigns` and `PATCH /campaigns/{sequenceId}`. Launch readiness\n checks remain mandatory; selecting a sender does not bypass them.\n- `--stop-on-reply` (the default) stops a person's remaining steps the\n moment they reply on either channel. `--no-stop-on-reply` keeps sending.\n- `--start` / `--end` bound the campaign in time (ISO 8601). A bare date\n (`2026-09-03`) is midnight at the start of that day in the campaign's\n timezone (`--timezone`, or the campaign's own), so `--end 2026-10-01`\n means \"nothing goes out on or after Oct 1 local time\". Add a time and\n offset (`2026-09-03T09:00:00-07:00`) to be exact. `--clear-start` /\n `--clear-end` remove them.\n- `set` works for the life of the campaign (not once archived). Steps are\n the one thing `set` does not cover; see Steps below.\n- `set --timezone X` alone moves the existing windows to that zone.\n- `duplicate` makes a new draft named \"<name> copy\" (or `--name`) with the same\n steps, schedule, sender pools and AI lines, and no people.\n- `archive` and `delete` stop everyone still in flight and keep every lead and\n all activity; a campaign is never erased.\n\n#### `--window` spec\n\n`\"<days> <start>-<end>\"`, repeatable (up to eight), all in `--timezone`:\n\n| Spec | Meaning |\n|---|---|\n| `\"Mon-Fri 9-18\"` | weekdays, 09:00 until 18:00 |\n| `\"Mon,Wed,Fri 10-16\"` | those three days |\n| `\"Weekdays 9am-5pm\"` | am/pm accepted; `Weekdays`, `Weekends`, `Daily` are groups |\n| `\"Sat-Sun 10-14\"` | day ranges wrap (`Fri-Mon` = Fri, Sat, Sun, Mon) |\n\nHours are whole hours, 0-24; the end must be after the start. Minutes are\nnot supported.\n\n### Add people\n\n```bash\n# search filters: the flags, or --search/--filters JSON (same object, @file.json works)\ndench campaign search --filters @filters.json [--titles Founder,CEO] [--not-industries \"Staffing and Recruiting\"] [--limit 100] [--page-token <t>] [--out audience.json] [--raw]\ndench campaign add <campaign> --search '{\"titles\":[\"Founder\"],\"locations\":[\"United States\"]}' [--limit 50] [--page-token <t>] [--preview] [--allow-active] [--allow-duplicates] [--out added.json]\ndench campaign add <campaign> --titles Founder --locations \"United States\" [--headcount 11-50] [--not-domains example.com] [--limit 50]\n\n# people you already have\ndench campaign add <campaign> --people-file audience.json [--allow-duplicates]\ndench campaign add <campaign> --csv people.csv [--map \"email=Work Email\" ...] [--preview] [--allow-duplicates]\ndench campaign add <campaign> --list <artifactId> [--limit 100] [--enrichment enriched] [--preview] [--allow-duplicates]\n\n# CRM records\ndench campaign add <campaign> --object lead --view \"Q3 targets\" [--email-field Email] [--linkedin-field \"POC LinkedIn URL\"] [--name-field Name] [--allow-duplicates] [--json]\ndench campaign add <campaign> --object people --entries <id1>,<id2> [--relation-field Contact] [--reverse] [--json]\n\n# one person with no CRM row yet (a lead is created); needs --email, --linkedin-url or both\ndench campaign add <campaign> [--name \"Ada Lovelace\"] --email ada@example.com [--linkedin-url https://linkedin.com/in/ada] [--json]\n```\n\n**Search and filters.** `--filters` and `--search` take the same JSON with every\npeople filter and work on both `search` and `add`. The flags `--titles`,\n`--past-titles`, `--person-names`, `--locations`, `--seniorities`,\n`--past-seniorities`, `--profile-keywords`, `--company-keywords`,\n`--industries`, `--functions`, `--sub-functions`, `--company-domains`,\n`--company-names`, `--past-company-names`, `--company-hq`, `--company-types`,\n`--universities`, `--skills`, `--languages`, `--headcount`, the ranges\n`--years-in-role`, `--years-at-company`, `--days-since-job-change`,\n`--founded-years` (`min:max`), and `--exact` add to that JSON: list flags\nappend to the JSON lists, so exclusions in the JSON survive. `--not-<flag>` and\n`--exclude-<flag>` leave values out of any list filter. A filter name that is\nnot allowed lists the allowed ones and the nearest match. `dench leads filters`\nprints accepted values.\n\nA flag value is split at its commas: `--titles \"CTO,VP Engineering\"` is two\ntitles, and a Note on stderr shows how a value was split (not for domains or\nexact filter values such as seniorities). Names with a comma that match a known\nvalue stay whole (the industry \"Technology, Information and Internet\"). A\ntitle, place or company name that contains a comma must be wrapped in double\nquotes inside the shell quotes, `--titles '\"Vice President, Information\nSystems\"'` or `--not-company-names '\"Acme, Inc.\"'`, or go in the `--filters`\nJSON. Otherwise it becomes several values and widens a billed search.\n\n**Limits and cost.** `search` returns at most 100 people per call and `add\n--search` adds at most 50 (a higher `--limit` is capped, with a note). Search\nand `--preview` cost 1 cent per person returned; `add --search --preview` means\n**no enrollment**, not a free search. Adding with `--people-file`, `--csv`,\n`--list`, `--object` or a single person is free of search cost. Adding with a\nsearch into a campaign that is already active, paused or completed needs\n`--allow-active`, because new people start its steps right away. Every add\nresult carries `campaignStatus`.\n\n**`--people-file`** accepts a recipient array or the result of `campaign search`\n(its `recipients`), 1-300 people. A recipient may contain `email`,\n`linkedinProfileUrl` (also `linkedinUrl`, `linkedin`), `displayName` (also\n`name`, `fullName`) and `personalization` (merge values); other text columns\nbecome merge values named after the key. An unknown value type is refused with\nthe row number instead of being dropped. New identities become Leads.\n`--allow-duplicates` only disables the cross-campaign duplicate check, not\nsuppression or campaign-local deduplication.\n\n**`--csv`** reads a spreadsheet export the way the app's Add people does: the\nemail and LinkedIn columns are found from what they hold, whatever they are\ncalled; the name comes from First name + Last name columns or from one `Name`,\n`Full name` or `Contact` column, found by its header (that column also stays\navailable as a merge value); every other column becomes a merge value\n(`{{Company}}`, `{{Job Title}}`). `--map\nemail|linkedin|name|first|last=\"<header or column letter>\"` overrides a guess\n(`none` switches a field off); `name` is the whole name in one column and cannot\nbe combined with `first` or `last`. `--preview` shows how each column is read\nand adds nobody, and the `Read` note says when no name column was found. Comma,\nsemicolon and tab files work, up to 5 MB and 500 people.\n\n**`--list`** adds people from a saved list (`dench lists`, made by `dench leads\nfind --save-as`) without searching or paying again. New people become Leads\nduring enrollment, in batches of 50. Custom values saved under each person's\n`personalization` object are preserved, including `role_title` and `Fund`.\n`--enrichment` keeps only rows at that stage\n(`all`, `enriched`, `in_progress`, `no_contacts`, `failed`, `not_enriched`).\n\n**CRM records.**\n\n- One person needs at least one of `--email` / `--linkedin-url`. `--name`\n is only for this form; with `--object`, pick the name column with\n `--name-field`.\n- A campaign holds at most **300 people**. `add` stops at the cap and says\n so (`cappedAtLimit`). Adding works on drafts and on launched campaigns\n (new people start at step 1); not on archived ones.\n- `--view` reads the saved view's own filters, sort and pinned rows, the\n same rows `dench crm views entries <object> \"<view>\"` returns. A view\n over more than 1000 rows cannot be listed fully (`truncated`); the\n command warns and only the listed rows are considered — narrow the view.\n- Each record needs an email (`--email-field`, default the `Email`\n column) and/or a LinkedIn profile URL (`--linkedin-field`, default the\n LinkedIn URL column). Records with neither are skipped\n (`skippedNoIdentity`). `--relation-field Contact` follows a relation to\n the person record first; `--reverse` walks it the other way.\n- By default a person already **queued or enrolled in another draft, active or\n paused campaign** is skipped (`duplicatesElsewhere`); `--allow-duplicates`\n adds them anyway. Remove them from one draft's audience, archive an old draft,\n or stop their enrollment in a launched campaign to resolve the conflict.\n Someone already in this campaign is never added twice (`duplicates`; `merged`\n counts the ones that gained a missing email or URL). Unsubscribed or\n bounced people are skipped (`suppressed`).\n- The result says how many were added and why the rest were not. Read it\n back to the user before launching.\n\nEvery enrolled person **gets a lead**: a `lead` row is used as-is; a\n`people` row finds the lead whose `Contact` is that person or creates one\n(`Status = New`, `Source = Outbound`, `Contact` linked); a bare `--email` /\n`--linkedin-url` creates the lead too. Workspaces without a `lead` object\nstamp the person instead.\n\n### Steps\n\n```bash\ndench campaign steps get <campaign> [--with-ids] # JSON you can edit and save: an array, or {\"stepModel\":\"workflow\",\"steps\":[...]} for a workflow\ndench campaign steps set <campaign> --file steps.json [--allow-single-braces] [--json] # replaces every step; DRAFTS ONLY\ndench campaign steps edit <campaign> --file steps.json [--allow-single-braces] [--json] # text and waits in place, also after launch\n```\n\n`steps set` replaces every step and works only while the campaign is a draft.\n`steps edit` keeps the number, order and type of every step and changes their\ntext, waits, reactions, withdrawal settings and conditions, also after launch (people already waiting keep the\ntiming they started with; messages already sent, or already being prepared, keep\ntheir text). In `steps edit` each step in the file is its full new content:\nleaving out a subject (including `inmailSubject`), body, note, `onlyIf` or\n`emailReplyToPrevious` clears it. Senders, LinkedIn wait settings, reaction\nsettings and `withdrawAfterHours` are kept when omitted, and so are a workflow's paths and\nan If / else's settings; set `withdrawAfterHours: null` to turn withdrawal\noff. Steps match by order (a workflow's by `key`, so the file can keep the\norder it was written in), or by `stepId` from `steps get --with-ids` to edit\nonly some; a step saved since you read it is refused, not overwritten. After\nlaunch a workflow's paths (`key`, `next`, `yesNext`, `noNext`) and what an\nIf / else checks (`check`, `conditionField`, `conditionOperator`) stay fixed;\nits `conditionValue` and a `wait_for_connection`'s `connectionTimeoutHours`\ncan still change. On a draft, changing `check` or `conditionOperator` drops\nthe saved settings the new check doesn't use.\n\nFor a plain list, `steps.json` is a JSON array of step objects, in send\norder (max 20). A workflow wraps them as\n`{\"stepModel\":\"workflow\",\"steps\":[...]}` (see Workflows below). Each step\nhas a `type` and only the fields that type uses. For a campaign with sender\npools configured as above, omit step sender ids. A plain list:\n\n```json\n[\n { \"type\": \"linkedin_visit\" },\n {\n \"type\": \"linkedin_connection\",\n \"linkedinMessageBody\": \"Hi {{First name}}, enjoyed your post on {{Topic || \\\"AI\\\"}}.\"\n },\n { \"type\": \"wait\", \"waitHours\": 48 },\n {\n \"type\": \"linkedin_message\",\n \"linkedinMessageBody\": \"Thanks for connecting, {{First name}}. Quick question: …\",\n \"linkedinMessageMode\": \"wait_until_connected\",\n \"connectionTimeoutHours\": 336\n },\n {\n \"type\": \"email\",\n \"emailSubject\": \"Quick question, {{First name}}\",\n \"emailTextBody\": \"Hi {{First name}}, …\",\n \"onlyIf\": \"not_connected\"\n },\n { \"type\": \"wait\", \"waitHours\": 72 },\n {\n \"type\": \"email\",\n \"emailReplyToPrevious\": true,\n \"emailHtmlBody\": \"<p>Bumping this, {{First name}} — worth a look?</p>\"\n }\n]\n```\n\n| `type` | Required | Optional |\n|---|---|---|\n| `wait` | `waitHours` (> 0, up to 2160 = 90 days) | — |\n| `email` | `emailSubject` (unless `emailReplyToPrevious`); `emailHtmlBody` and/or `emailTextBody` | `emailReplyToPrevious` (thread under the last email sent to this person, no new subject); `onlyIf` |\n| `linkedin_visit` | — | — |\n| `linkedin_connection` | — | `linkedinMessageBody` (the invite note, ≤ 300 chars; the request goes out without it if LinkedIn refuses the note); `withdrawAfterHours` (168–2160, or `null` to turn off) |\n| `linkedin_message` | `linkedinMessageBody` (≤ 3000 chars) | `linkedinMessageMode`; `connectionTimeoutHours` (plain lists; a workflow uses `wait_for_connection`) |\n| `linkedin_like_post` | — | `likeReaction`; `likeMaxPostAgeDays`; `likeSkipPreviousWait`; `likeSkipNextWait`; `likeCount` (1–3 recent posts, default 1); `onlyIf` |\n| `linkedin_inmail` | `linkedinMessageBody` (≤ 1900 chars) | `inmailSubject` (≤ 200 chars; use this, not `emailSubject`) |\n| `condition` (If / else, workflows only) | `check`; `yesNext` (Yes) and `noNext` (No); with `check: \"field_value\"`, `conditionField`, `conditionOperator` and (except `is_empty` / `is_not_empty`) `conditionValue` | — |\n| `wait_for_connection` (Wait for them to accept, workflows only) | `yesNext` (Accepted) and `noNext` (Not accepted) | `connectionTimeoutHours` (the window: 24–2160 = 1–90 days, default 720) |\n\nIn a workflow every step also takes a `key` and a `next`; `condition` and\n`wait_for_connection` take `yesNext` and `noNext` instead of `next`.\n\nLegacy campaigns without a pool for a channel still require\n`emailMailboxAccountId` on email steps and `linkedinAccountId` on LinkedIn\nsteps, on Wait for them to accept (`wait_for_connection`) steps and on If / else\nsteps that check `linkedin_connected`. `steps get` / `steps set` preserve those\nvalues until conversion.\n\n- **What `steps set` and `steps edit` refuse** (so nothing is lost or sent\n raw): a field the step type would drop (`onlyIf` off an email or post-like step, a body on\n a visit, `emailReplyToPrevious` on the first email, condition fields its\n `check` or `conditionOperator` ignores), a missing subject or\n body, an invite note over 300, a message over 3000, an InMail body over 1900\n or InMail subject over 200 characters, out-of-range reaction/withdrawal/\n acceptance-window settings, `likeCount` outside 1–3,\n a wait of 0 or over 2160 hours, more than 20 steps, `{TOKEN}` with single\n braces, and workflow paths that don't hold together (Workflows below). It\n warns when several LinkedIn messages after a connection request each wait 30\n days for the accept, and when a plain list saved on a workflow campaign has\n a message after the connection request, which then no longer waits for the\n accept (Workflows below). An email with both `emailHtmlBody` and `emailTextBody`\n sends the HTML: when you edit only the text, the HTML copied from `steps get`\n is dropped (with a warning) and the new text is sent.\n- `onlyIf` — email and post-like steps in a plain list: `always` (default),\n `connected` (run only if the person accepted the LinkedIn connection),\n `not_connected` (send only if they have not). `connected` without an\n earlier `linkedin_connection` step is a launch warning. In a workflow,\n branch with an If / else (`\"check\": \"linkedin_connected\"`) instead.\n- `linkedinMessageMode` — plain lists: what a `linkedin_message` does while\n the invite is still pending: `wait_until_connected` (default when a\n `linkedin_connection` step comes before it) waits up to\n `connectionTimeoutHours` (1–2160 hours, default 720 = 30 days) then skips;\n `skip_if_not_connected` (default otherwise) skips right away. In a\n workflow a message never waits on its own (the default is\n `skip_if_not_connected`): put it on the Accepted path of a\n `wait_for_connection`, or the Yes path of a `linkedin_connected` If / else.\n- `withdrawAfterHours` — connection requests only. After 168–2160 hours\n (7–90 days), withdraw a still-pending invitation sent by this campaign.\n It never withdraws an unrelated invitation or an accepted connection.\n Omitted on creation or `null` means off; there is no automatic withdrawal\n default. A value of `600` means 25 days after the invitation was sent.\n- `likeReaction` — one of `like` (default), `celebrate`, `support`, `love`,\n `insightful`, `funny`. `likeMaxPostAgeDays` is a whole number from 1 to 365,\n default 30. `likeCount` (1–3, default 1) is how many posts to react to.\n The step chooses their newest eligible original posts and skips when none\n is available or (with one post) it was already reacted to. With\n `likeCount` above 1 a post already reacted to doesn't use one up, and\n fewer recent posts means fewer reactions.\n `likeSkipPreviousWait: true` checks for eligible posts before the wait\n immediately before this step starts. If there are none, it skips that wait\n and the like step, **keeping the following waits**, even when\n `likeSkipNextWait` is true. Earlier consecutive waits remain. Omitted means\n false, so existing campaigns keep their behavior. For example, Wait 2 days →\n Like → Wait 1 day → Message becomes Wait 1 day → Message when no eligible\n posts are found. New like steps created in the editor enable this option\n and set `likeSkipNextWait` to false.\n `likeSkipNextWait` defaults to `true` when omitted: **a reaction skipped\n during normal execution also skips\n consecutive wait steps immediately after it**, including a skip caused by\n `onlyIf`. Set it to `false` to preserve those waits. Omitting these fields\n in `steps edit` preserves their saved values.\n- InMail automatically skips people who are already connected. Do not add\n `onlyIf` or `linkedinMessageMode` to an InMail step. LinkedIn Premium InMail\n through the personal inbox is supported, not Sales Navigator or Recruiter\n InMail. Available InMail credits are checked; an open profile may be free.\n If InMail is unavailable or has no credits, the step skips rather than\n falling back to another send. Read the warnings from `launch --check`.\n- **Merge tokens** work in subjects, bodies and LinkedIn text:\n `{{First name}}`, `{{Company}}`, `{{Job Title}}` — any column of the\n enrolled record or value supplied with the person, plus `firstName`,\n `lastName`, `name`, `company`, `email`. Chain fallbacks with `||`:\n `{{First name || \"there\"}}`. A plain token with no value for a person is a\n **launch blocker** for that person (a quoted fallback avoids it); on a\n launched campaign such people are skipped at `add` time\n (`skippedMissingInfo`). AI-line tokens use their saved fallback until the line\n is written and never block launch.\n\n#### Workflows (branching paths)\n\nA workflow is a campaign whose steps say where each one goes, so different\npeople take different paths through the same campaign (the app shows it as\nthe campaign's Sequence tab). Use one whenever the brief has an \"if\".\n\n**How the Sequence tab draws them.** Each ordinary `wait` is a separate,\nclickable step (for example, \"Wait 2 days\") between actions. Add one from\n**+ → Flow → Wait**, then click it to edit the amount and unit. Waits can\nalso go before End; deleting an action keeps the wait before it.\nA `linkedin_connection` card carries the `wait_for_connection` right after\nit (**Wait up to** N days, paths Accepted / Not accepted) and, when the only\nway into the request is the No exit of a `linkedin_connected` If / else,\nthat check too (**If already connected → Separate steps for existing\nconnections**, a third path).\nThe acceptance window stays on the connection request; the add menu does\nnot offer a separate Wait for them to accept step. The stored steps below\nkeep the same timing and paths.\n\n**Keyboard editing in a draft.** Select a node and press Delete or Backspace\nto remove it; a branching node asks which path to keep. Use **⌘Z** to undo and\n**⌘⇧Z** to redo (**Ctrl+Z** / **Ctrl+Shift+Z** or **Ctrl+Y** on Windows).\nUndo restores the node's content and connections, including after deleting\nthe last node. In a message or other text field, the shortcuts edit the text\nnormally. Sequence history is kept for the current campaign editing session.\n\n**Keys and paths.** Give every step a `key`: a short id like `\"invite\"`,\nunique in the campaign, never `\"end\"`. Then say where it goes:\n\n- `condition` (If / else) and `wait_for_connection` (Wait for them to accept)\n have two exits, both required: `yesNext` and `noNext` (Yes / No, or\n Accepted / Not accepted). They take no `next`.\n- Every other step has one exit, `next`. Left out, it is the step listed\n after it in the file, or `\"end\"` after the last one.\n- An exit is another step's `key`, or `\"end\"`: that path stops there and the\n person is done with the campaign. Any path can end anywhere, so one branch\n can stop after an InMail while the other goes on.\n- **Merges**: several exits may point at the same step. Write a message once,\n then point the If / else's Yes exit and the Wait for them to accept step's\n Accepted exit at it; everything after it is shared.\n\n**If / else** (`\"type\": \"condition\"`) sends nothing. It checks the person\nwhen they reach it and takes Yes or No (`check`):\n\nIn the editor, a new If / else starts with **Choose a condition**. Select a\ncheck in its settings; the unfinished step can be saved as a draft, but a\ncondition must be chosen before launch.\n\n| `check` | Yes when |\n|---|---|\n| `linkedin_connected` | they are connected to the sender on LinkedIn (No without a LinkedIn profile) |\n| `has_email` | they have an email address that can still be emailed (not bounced, unsubscribed or marked as spam) |\n| `opened_last_email` | they opened the last email sent to them. Needs an email before it on every path and open tracking; put a wait between the email and the check so people have time to open it (`launch --check` warns otherwise) |\n| `field_value` | a field on their lead matches (Field value): `conditionField` (the field's name, like `\"Job Title\"` or `\"Source\"`), `conditionOperator` and, except for the empty checks, `conditionValue` |\n\nField value reads the person's lead, or their own record if they have no\nlead, when they reach the If / else. The campaign itself changes `Status`,\n`Last touch` and `LinkedIn connection` as it runs (How it shows up in the CRM,\nbelow): after the first send everyone is `Contacted`, so don't branch on\nthose to mean \"before we wrote to them\". Pick a field the campaign doesn't\nwrite.\n\nField value operators (`conditionOperator`), all case-insensitive:\n\n| `conditionOperator` | Yes when the field |\n|---|---|\n| `is` | equals `conditionValue` (on a multi-value field: any of its values does) |\n| `is_not` | does not equal it (none of its values do) |\n| `contains` | contains it as text (any of its values does) |\n| `is_empty` | has no value |\n| `is_not_empty` | has a value |\n\n**Wait for them to accept** (`\"type\": \"wait_for_connection\"`) sends nothing.\nFrom when the person reaches it, it waits up to `connectionTimeoutHours`\n(the window: 24–2160 hours = 1–90 days, default 720 = 30 days) for the\nconnection request to be accepted. It takes Accepted as soon as they accept\n(right away if they were already connected) and Not accepted when the window\ncloses, the invitation is withdrawn or it never went out. It needs a\n`linkedin_connection` before it on every path. Keep that request's\n`withdrawAfterHours` longer than the window, or leave it off: a withdrawal\nduring the wait ends it as Not accepted.\n\n**Rules.**\n\n- Paths only move forward: no loops, no exit back to an earlier step, and\n every step reachable from the first. At most 20 steps, If / else and Wait\n for them to accept included.\n- The server stores the steps in path order, which can differ from the\n file's; the paths, not the order, decide who gets what. `steps get` shows\n the stored order and `dench campaign get` lists each step's paths.\n- A reply-in-thread email (`\"emailReplyToPrevious\": true`) needs an email\n before it on every path that reaches it; it threads under the last email\n sent to that person.\n- Branch with If / else and Wait for them to accept, not `onlyIf` and\n `linkedinMessageMode`: in a workflow a `linkedin_message` never waits for\n the accept on its own. A plain list file (no keys or paths) saved on a\n workflow campaign runs as a workflow too, so a message after its connection\n request skips anyone who hasn't accepted yet: edit the file `steps get`\n prints instead. `steps set` warns about such a list, and `launch --check`\n about any message some path reaches after a connection request without a\n Wait for them to accept or a `linkedin_connected` If / else.\n- Steps with a `key`, a path or one of these two types save the campaign as\n a workflow, and a workflow stays one (`\"stepModel\": \"linear\"` is refused).\n For a plain list again, start a new campaign with `dench campaign draft`\n and set the steps there. Don't use `dench campaign duplicate`: the copy is\n still a workflow, so a plain-list `linkedin_message` would no longer wait\n for the accept. `steps get` prints a workflow\n as `{\"stepModel\":\"workflow\",\"steps\":[...]}`; `steps set` and `steps edit`\n take that file back as is.\n- After launch the structure is fixed: step types, keys, paths (`next`,\n `yesNext`, `noNext`) and what each If / else checks (`check`,\n `conditionField`, `conditionOperator`). `steps edit` still changes text,\n waits, `conditionValue` and the window of a Wait for them to accept. To\n change the structure, `dench campaign duplicate <c>`, fix the copy and add\n only people who were never contacted.\n\n**Workflow launch blockers** (`launch --check` names the step):\n\n| Blocker | What's wrong | Fix |\n|---|---|---|\n| `workflow_path_invalid` | the paths don't hold together: two steps share a key, an exit names a key no step has, a path goes back or loops, nothing leads to a step, or an If / else or Wait for them to accept misses an exit. Also fires when a plain list holds one of those two steps | fix `key`, `next`, `yesNext` and `noNext` in the file, then `steps set` |\n| `wait_for_connection_without_invite` | a path reaches a Wait for them to accept with no connection request before it | add a `linkedin_connection` earlier on that path |\n| `opened_check_without_email` | a path reaches an `opened_last_email` If / else with no email before it | send an email earlier on every path to it, or check something else |\n| `open_tracking_unavailable` | email opens aren't tracked, so `opened_last_email` would always say No | check something else |\n| `condition_field_missing` | a `field_value` If / else names a field the campaign's leads don't have | `dench crm fields list lead` (for people with no lead, the object they were added from, like `dench crm fields list people`), then use one of those field names |\n| `reply_without_prior_email` | a path reaches a reply-in-thread email with no email before it | send an email earlier on every path to it, or give it its own `emailSubject` |\n\n**Example: connected or not, an acceptance window and an InMail fallback.**\nPeople already connected get the message right away. Everyone else gets a\nconnection request (withdrawn after 25 days if still pending); those who\naccept within 10 days get the same message, the rest get an InMail and\nstop. After the message: a 2-day wait, a reaction to two recent posts, a\nday, then a follow-up. Supply `Fund` for each person (or use a deliberate\nfallback); do not guess investor data. Sender pools still come from the\ncampaign settings.\n\n```json\n{\n \"stepModel\": \"workflow\",\n \"steps\": [\n {\n \"key\": \"connected\",\n \"type\": \"condition\",\n \"check\": \"linkedin_connected\",\n \"yesNext\": \"pitch\",\n \"noNext\": \"invite\"\n },\n {\n \"key\": \"invite\",\n \"type\": \"linkedin_connection\",\n \"withdrawAfterHours\": 600,\n \"next\": \"accept\"\n },\n {\n \"key\": \"accept\",\n \"type\": \"wait_for_connection\",\n \"connectionTimeoutHours\": 240,\n \"yesNext\": \"pitch\",\n \"noNext\": \"inmail\"\n },\n {\n \"key\": \"inmail\",\n \"type\": \"linkedin_inmail\",\n \"inmailSubject\": \"Fellow {{Fund}} founder\",\n \"linkedinMessageBody\": \"Hi {{First name}}, fellow {{Fund}} founder here. We wrote a short report on how teams like {{Company}} handle this. May I send it?\",\n \"next\": \"end\"\n },\n {\n \"key\": \"pitch\",\n \"type\": \"linkedin_message\",\n \"linkedinMessageBody\": \"Hi {{First name}}, fellow {{Fund}} founder here. We wrote a short report on how teams like {{Company}} handle this. May I send it?\",\n \"next\": \"pause\"\n },\n { \"key\": \"pause\", \"type\": \"wait\", \"waitHours\": 48, \"next\": \"like\" },\n {\n \"key\": \"like\",\n \"type\": \"linkedin_like_post\",\n \"likeReaction\": \"like\",\n \"likeMaxPostAgeDays\": 30,\n \"likeCount\": 2,\n \"next\": \"pause2\"\n },\n { \"key\": \"pause2\", \"type\": \"wait\", \"waitHours\": 24, \"next\": \"report\" },\n {\n \"key\": \"report\",\n \"type\": \"linkedin_message\",\n \"linkedinMessageBody\": \"Hi {{First name}}, is the report useful for {{Company}}?\",\n \"next\": \"end\"\n }\n ]\n}\n```\n\nExplain the mapping to the user like this: \"if connected\" is the\n`connected` If / else; \"else a connection request\" is its No exit to\n`invite`; \"wait 10 days\" is `accept` (`connectionTimeoutHours: 240`); its\nAccepted exit merges into the same `pitch` as the Yes exit; Not accepted goes\nto `inmail`, which ends. Everything from `pitch` on is one shared path. In\nthe app that is one \"Send connection request\" card with Already connected,\nAccepted and Not accepted paths and \"Wait up to 10 days\"; the 2-day and\n1-day waits appear as separate steps before the Like and follow-up cards.\n\nSave on a draft, inspect the round trip, then check readiness without sending:\n\n```bash\ndench campaign steps set <campaign> --file steps.json --json\ndench campaign steps get <campaign> --with-ids\ndench campaign launch <campaign> --check --json\n```\n\nThe REST operations `campaigns.steps.replace` and `campaigns.steps.update` use\nthe same field rules. When replacing a workflow's steps, send\n`\"stepModel\": \"workflow\"` so they are checked the way they will be saved.\nUpdates require `stepId`, `type` and `expectedUpdatedAt`; only supplied fields\nchange. Defaults are not re-applied to a partial update.\nKeep the campaign at a reviewed draft until the user approves real sends.\n- **Account ids.** `dench campaign accounts --json` returns `mailboxes` with\n `emailMailboxAccountId` and `linkedinAccounts` with `linkedinAccountId`.\n Both lists honor the acting member's connection visibility: their own\n private accounts and teammates' shared accounts, never someone else's\n private account. LinkedIn discovery also excludes removed accounts,\n former members' accounts and mock connections. It needs a live member's\n API key or agent session; an organization-only key is refused.\n LinkedIn summaries contain display/owner labels, status, availability,\n `remainingToday` (`invites`, `messages`, `profiles`) and\n `remainingInvitesThisWeek`. Today's invites also respect the rolling\n seven-day limit. Mailbox summaries include warm-up status, when a new\n mailbox is ready and its daily cold-send cap. These are account-local usage\n snapshots before queued work and campaign limits, not send reservations. Pool\n updates validate both the editor's and campaign owner's access; launch and\n dispatch still validate availability. Use only the Dench account ids in a\n campaign pool.\n API equivalent for LinkedIn discovery: `GET $DENCH_API_BASE/campaigns/accounts/linkedin`\n with the same bearer credentials; no caller-supplied user or workspace id.\n\n### AI-written lines\n\n```bash\ndench campaign personalize get <campaign>\ndench campaign personalize set <campaign> --file lines.json\ndench campaign personalize write <campaign> [--all] [--yes]\ndench campaign personalize edit <campaign> --person <enrollmentId|name> --line <key> --text \"…\"\ndench campaign personalize rewrite <campaign> --person <enrollmentId|name> [--line <key>]\ndench campaign personalize clear <campaign>\n```\n\nUp to 5 lines per campaign, about 3 cents a person. `lines.json` is\n`{\"sells\":\"…\",\"lines\":[{\"label\",\"instructions\",\"fallback\"}]}`; optional per\nline: `key` (otherwise made from the label), `maxChars` 20-300 and `fallbackFrom`\n(a field to use before the fallback). `set` writes lines for up to 100 people\nright away; more waits for `write --yes`, which confirms the cost. `write --all`\nrewrites everyone; `edit --text \"\"` undoes a manual edit. `clear` turns lines\noff; take the `{{keys}}` out of the steps first.\n\n### Per person\n\n```bash\ndench campaign stop <campaign> --person <enrollmentId|name> [--json] # nothing more is sent to them\ndench campaign remove <campaign> --person <enrollmentId|name> [--json] # drafts only: drop someone never contacted\ndench campaign resume-person <campaign> (--person <enrollmentId|name> | --all) [--json]\ndench campaign person set <campaign> --person <enrollmentId|name> [--email ada@new.com] [--linkedin-url <url>] [--field \"Job Title=CTO\" ...] [--json]\ndench campaign sync <campaign> [--json] # fill empty email, LinkedIn URL, name and fields from CRM records\n```\n\nEnrollment ids come from `dench campaign people`. A person's name works\nwhen it is unique in the campaign. `stop` on a never-contacted person in a\ndraft removes them, which frees their place in the 300-person cap. `remove`\nrefuses anyone already contacted. `resume-person --all` resumes every paused\nperson in an active campaign, for example after a sender was reconnected.\n`person set` fixes an address or fills a `{{merge field}}` before launch (a\ncorrected email, LinkedIn URL or matching column also updates the linked CRM\nrecord); `--field` repeats. `sync` fills each unfinished person's empty email,\nLinkedIn URL, name and merge fields from their linked CRM record, for example\nafter enriching the records; it never overwrites a value the campaign already\nhas.\n\n### Launch and lifecycle\n\n```bash\ndench campaign launch <campaign> --check [--json] # readiness only; never launches\ndench campaign launch <campaign> [--ack-linkedin-risk] [--json]\ndench campaign pause <campaign> [--json]\ndench campaign resume <campaign> [--json]\ndench campaign archive <campaign> [--json] # stops everyone still in flight; final\n```\n\n`launch --check` runs only the readiness check and never launches. It\nprints each blocker with why it fires and the commands that fix it\n(`reasons` and `fix` on every entry of `blockers[]` in `--json`), the\nwarnings, the audience and step counts and the `fingerprint`, then exits 0\nwhen the campaign is ready and 1 when it is blocked. Run it before every\nlaunch: plain `launch` launches as soon as the campaign is ready, so it is\nnot a dry run. `start` is another name for `launch`, including `--check`.\n\n`launch` runs the same check first. When something is missing it\nprints every blocker in plain words — no steps, nobody enrolled, a step's\nmailbox or LinkedIn account missing or disconnected, people without an\nemail or URL, people missing a merge field the steps use, a reply-to-thread\nstep with no earlier email, people enrolled in another LinkedIn campaign —\nand exits 1 without launching. Fix them (`steps set`, `add`, `set`) and run\n`launch` again. `--json` prints the full readiness payload (`blockers[]`\ngrouped by problem with the affected people, `warnings[]`).\n\nCampaigns with LinkedIn steps need `--ack-linkedin-risk`: automated\nLinkedIn activity is against LinkedIn's terms and can get the account\nrestricted. Say so to the user and pass the flag only once they accept.\n\nStatus moves `draft → active → (paused ↔ active) → completed`, and\n`archived` from anywhere. `pause` only acts on an active campaign, `resume`\nonly on a paused one; both say when there is nothing to do. `completed`\nmeans everyone finished, replied or stopped; adding people to a completed\ncampaign revives it.\n\n## Reading `dench campaign get`\n\n```\nFounder outreach — active [js7…]\nSchedule: Mon-Fri 9-18 America/Los_Angeles · up to 30 emails/day · stops on reply\nSteps (4): Visit profile → Connect on LinkedIn → Wait 2d → Email\n\nFunnel\n Enrolled 120\n In flight 38 (active 36, paused 2)\n Contacted 80\n LinkedIn invited 60 · accepted 22 · messaged 18\n Email sent 75 · opened 30 · clicked 4\n Replied 9 (11.3% of contacted)\n Done finished 30 · stopped 5 · failed 1\n\nNow / Next\n Now: Sending a connection request to Grace Hopper (since Sep 2, 2026, 10:41 AM)\n Next: Send an email to Ada Lovelace at Sep 2, 2026, 10:44 AM (in 3m)\n Held: today's email cap is reached · resumes Sep 3, 2026, 9:00 AM (in 22h)\n Emails today: 30/30 · next email Sep 3, 2026, 9:00 AM (in 22h)\n Sender Mark R: running · invites 12/25 today, 40/100 this week · messages 3/40 today · 09:00-18:00 America/Los_Angeles (in window)\n\nPeople (50 of 120)\n Ada Lovelace — active · waiting: email · until Sep 2, 2026, 10:44 AM (in 3m) · last: invite sent 2d ago · lead: Contacted [enr_…]\n Grace Hopper — active · sending: connect on linkedin · hold: the sender's daily LinkedIn limit is reached (until …) [enr_…]\n Linus T — replied · last: LinkedIn message sent 5h ago · lead: Replied [enr_…]\n```\n\n- **Funnel**: `Enrolled` = everyone ever added. `Contacted` = got at least\n one email, invite or message (a profile visit does not count). `Replied`\n counts replies from people this campaign contacted, whether or not the\n reply stopped them; the rate is replied / `Contacted`. `Done` splits\n finished (reached the end), stopped (stopped, bounced, complained,\n unsubscribed) and failed. In a plain list a finished person ran every\n step; in a workflow they reached the end of their path, so someone on the\n Not accepted → InMail path finishes without the steps on the other path.\n- **Now** is the one action being sent this instant; **Next** is the next\n action and when. `Held` explains why nothing is going out.\n- **Hold reasons** (on `Next`, on a person, or as `Held`), in plain words:\n the campaign is paused · a sending account is disconnected · today's email\n cap is reached · outside the sender's working hours · outside the\n campaign's send window · the sender's daily LinkedIn limit is reached ·\n the sender's weekly connection limit is reached · spacing out sends so\n they look human · checking whether they are already connected · paused\n after LinkedIn errors · the LinkedIn account is paused · LinkedIn asked\n us to retry later · writing personalized lines (shown on a person as\n `note: Waiting for personalized lines`; after 2 hours the saved fallback\n text is sent). Every one of these clears on its own; none means a\n step \"did not send\". Report the hold, not a failure.\n- **People**: status, what their current step is doing, the last delivered\n step, any hold, and the linked lead's `Status`. `--json` returns `{\n detail, analytics, live }` — the raw campaign (`detail.enrollments`,\n `detail.currentRuns[enrollmentId].hold`, `detail.lastTouches`,\n `detail.connectedEntries[enrollmentId].lead`), the funnel and the live\n strip.\n\nA workflow's `get` lists its paths, counts each exit and shows the\nacceptance waits:\n\n```\nSteps (9, a workflow with paths):\n 1. If / else: Connected on LinkedIn? → Yes: LinkedIn message (step 5) · No: Connect on LinkedIn (step 2)\n 2. Connect on LinkedIn\n 3. Wait for them to accept (up to 10d) → Accepted: LinkedIn message (step 5) · Not accepted: LinkedIn InMail (step 4)\n 4. LinkedIn InMail → End\n 5. LinkedIn message\n …\n\nFunnel\n …\n Done finished 3 · stopped 0 · failed 0\n Paths step 1 If / else: Connected on LinkedIn? → Yes 12 · No 40\n step 3 Wait for them to accept → Accepted 9 · Not accepted 14\n\nNow / Next\n Next: Wait for Ada Lovelace to accept the connection request — next check Sep 2, 2026, 12:41 PM (in 2h), stops waiting Sep 7, 2026, 10:41 AM (in 5d)\n\nPeople (50 of 52)\n Ada Lovelace — active · waiting: Wait for them to accept · stops waiting Sep 7, 2026, 10:41 AM (in 5d) [enr_…]\n Grace Hopper — active · checking: If / else: Connected on LinkedIn? [enr_…]\n```\n\n- **Steps**: one line per step in the stored order. A step names where it\n goes only when that isn't the next line; `→ End` ends that path. If /\n else and Wait for them to accept name both exits.\n- **Paths**: how many people have taken each exit so far (`branchStats` in\n `--json` analytics). The two numbers can add up to less than `Enrolled`:\n people before the step, or on another path, haven't reached it.\n- **Next** for a Wait for them to accept: when Dench next checks for the\n accept, and when it stops waiting and takes Not accepted. `Check\n \"<label>\" for <name>` is an If / else about to run.\n- **People**: `checking: <If / else>` while an If / else or Wait for them to\n accept reads the profile (nothing is sent); `waiting: Wait for them to\n accept · stops waiting …` until they accept or the window closes.\n\n## How it shows up in the CRM\n\n- **Lead `Status` moves on its own, forward only**: the first delivered\n email, connection request or LinkedIn message moves New → `Contacted`; a\n reply moves it to `Replied`. Nothing sets `Qualified` / `Disqualified` or\n moves backwards, and a `Status` outside New/Contacted/Replied is left\n alone. `Last touch` is bumped on every send, acceptance and reply. Never\n hand-edit `Status` after a step ran — you would race the writeback.\n- **Lead `LinkedIn connection` tracks the relationship, forward only**: a\n connection request sets `Invited`; an acceptance — or finding the person\n is already a connection — sets `Connected`. The column is created on the\n lead object the first time a LinkedIn step runs; email-only campaigns\n never touch it.\n- Every touch is also an event on the lead's History tab (source\n \"Campaign\") and in `dench campaign events`. `dench crm history <object>\n <entryId>` shows the field changes under the actor `Campaign: <name>`.\n- Enrolling a `people` row links its lead's `Contact` to that person; that\n link is expected — leave it.\n\n## REST API and app SDK\n\nAll paths are under `/api/v1` and need member-bound credentials. Agents can call\nany operation through `dench.api.call(operationId, args)`, and the typed\nmethods are under `dench.campaigns` (see [APPS.md](./APPS.md)). The full\nrequest and response schemas are in [API.md](./API.md) and `openapi.json`.\nOperation ids below are `campaigns.<name>`:\n\n| What | Operations |\n|---|---|\n| Browse and inspect | `list`, `get`, `analytics`, `live`, `events`, `preview`, `pipeline`, `people.timeline`, `people.forRecord`, `accounts.email`, `accounts.linkedin` |\n| Create and configure | `create`, `drafts.create`, `update`, `duplicate`, `archive` |\n| Add people | `audience.search`, `people.addFromSearch`, `people.addBatch` (50 recipients), `people.addFromCrm` (100 ids), `people.add`; saved lists via `lists.rows` and `people.addBatch`, retaining each row's `personalization` |\n| Steps | `steps.replace` (draft), `steps.update` (also after launch) |\n| AI lines | `personalization.get`, `.set`, `.write`, `.edit`, `.rewrite`, `.clear` |\n| Per person | `people.stop`, `people.remove`, `people.resume`, `people.resumeAll`, `people.setEmail`, `people.setLinkedin`, `people.setField`, `people.sync` |\n| Launch | `launch.preview` (`GET /campaigns/{sequenceId}/launch`, returns the `fingerprint`), `launch` (`POST`, needs that `fingerprint`), `pause`, `resume` |\n| Builder | `builder.profile`, `.autofill`, `.estimate`, `.lookalike`, `.voices`, `.save`, `.get`, `.build`, `.opener`, `.sequence`, `.outreach`, `.create`, `.drafts`, `.resume`, `.discard` |\n| Signals | `sources.overview`, `.get`, `.signals`, `.update`, `.preview`, `.run`, `.pending`, `.review`; `queue` |\n\nSearch bodies are `{ \"filters\": { … }, \"limit\": 50 }` with an optional\n`pageToken`; batch bodies are `{ \"recipients\": [ … ] }`. There is no reply-text\nendpoint: combine `campaigns.get` with the CRM activity of the person, or use\n`dench campaign replies`.\n\n## Rules\n\n- `steps set` works only in draft; `steps edit` changes text and waits after\n launch. Schedule, daily cap, stop-on-reply, start and end change any time\n before archive.\n- One campaign, one schedule: all steps share the send windows; LinkedIn\n steps also respect the LinkedIn account's own working hours and limits.\n- Max 300 people per campaign, 20 steps, 100 ids per CRM `add` batch and 50\n people per search or file batch (the CLI chunks for you), 8 send windows,\n 300 characters per invite note, 3000 characters per LinkedIn message.\n- Outreach needs a **workspace member's** credentials: a `dench signin`\n session, a member-bound `DENCH_API_KEY`, or an agent session a member\n created. With an organization-only key every command fails with\n \"Outreach needs a workspace member's credentials\". That is about whose\n credentials the run has, not about sending accounts — connecting a\n mailbox changes nothing. Ask the user to run it from a chat in the Dench\n app (or to link their account in Slack) so the run carries their\n identity, rather than retrying.\n- `dench email multichannel …` drives the same campaigns with fewer\n controls; prefer `dench campaign`.\n- HTTP equivalent: `$DENCH_API_BASE/campaigns…` (the Campaigns section of\n `references/API.md`; operationIds `campaigns_*` in `openapi.json`). `launch` there needs the `fingerprint` from\n `GET /campaigns/{sequenceId}/launch`.\n\n## What still needs the user in the Dench app\n\n- Signing in to a mailbox or LinkedIn account (`dench tool connect` prints the\n link), reconnecting or disconnecting it, and a mailbox's warm-up sign-in.\n- A mailbox's daily cold-send cap, skipping its warm-up and sharing it with\n teammates; a LinkedIn account's daily and weekly limits, working hours and\n risk acknowledgement.\n- Answering replies in the Inbox.\n"
|
|
32
32
|
},
|
|
33
33
|
"references/CLI.md": {
|
|
34
|
-
"sha256": "
|
|
35
|
-
"content": "<img src=\"/logos/apple-touch-icon.png\" alt=\"Dench\" width=\"32\" height=\"32\">\n\n# Dench CLI\n\nGenerated from the command registry, native file-command contracts and saved-setup parsers. Run `dench <command> --help` for arguments and flags. API-only upload phases and compatibility aliases are not standalone commands.\n\nUse `dench context --sections organisation,user,memory` for knowledge, `dench memory` for facts, `dench env` for explicitly saved executable setups, and `dench secrets` for encrypted credentials. `dench cron secret` signs inbound webhooks; it does not store service credentials.\n\n## Reusable setups\n\n```text\ndench env — verified setups reused across chats\n\n dench env list [--limit N] [--cursor CURSOR] [--json]\n dench env show NAME [--revision SHA256] [--json]\n dench env save NAME --path DIRECTORY [--wait SECONDS | --no-wait] [--json]\n dench env run NAME [--revision SHA256] [--state-key KEY] [--prepare-local] [--json] -- COMMAND [ARGS...]\n dench env delete NAME [--json]\n\nSave requires dench-env.json, SKILL.md, an explicit files allowlist and verify\ncommands. Credentials, caches and symlinks are excluded from source uploads.\nSave returns an authoritative preparation receipt; default observation is 10s.\nReady runs reuse prepared dependencies. --prepare-local explicitly prepares a\nseparate local platform cache once; ordinary ready runs never reinstall.\nState is job-local by default; choose an explicit state key to share it.\nExample: dench env run openai-report -- node report.mjs\n```\n\n```text\ndench secrets — workspace-shared encrypted credentials\n\n dench secrets set NAME --stdin [--kind env|file] [--expected-version N] [--json]\n dench secrets set NAME --file PATH [--kind env|file] [--expected-version N] [--json]\n dench secrets list [--json]\n dench secrets delete NAME [--expected-version N] [--json]\n\nValues are accepted only through stdin or a file. Values are never printed.\nBind a stored name in dench-env.json secretEnv or secretFiles; env run injects\nonly those bindings. Memory is not credential storage. --kind defaults to env.\nExample: dench secrets set OPENAI_API_KEY --stdin < /private/path/key.txt\n```\n\nSee [ENVIRONMENTS.md](ENVIRONMENTS.md) for the manifest, preparation lifecycle, state and security rules.\n\n## Workspace files\n\nWorkspace paths are POSIX paths under /workspace; /reports/a.md and /workspace/reports/a.md address the same file.\n\nThese commands read or update workspace storage. Use dench stage to upload local files or directories.\n\n### files ls\n\nList workspace files; the default path is /.\n\n```text\ndench files ls [<path>] [--recursive|-r] [--json]\n```\n\n--recursive (or -r) includes descendants.\n\n```sh\ndench files ls /reports --recursive --json\n```\n\n### files cat\n\nRead a workspace file's inline text.\n\n```text\ndench files cat <path> [--json]\n```\n\nUse cat for virtual files such as IDENTITY.md and ORGANISATION.md, which have no download blob.\n\nFor binary files or files without inline text, use files download.\n\n```sh\ndench files cat /reports/summary.md\n```\n\n### files write\n\nWrite a workspace file's text from stdin.\n\n```text\ndench files write <path> [--json]\n```\n\nThe destination path is required. Pipe or redirect the raw UTF-8 file text into stdin.\n\n--json controls the result format; stdin is file content, not an API JSON envelope. No --stdin, --content or --file flag is supported.\n\nWriting replaces the complete text; empty stdin writes an empty file.\n\n```sh\ndench files write /reports/summary.md --json < ./summary.md\nprintf '%s\\n' 'Report ready.' | dench files write /reports/summary.md --json\n```\n\n### files mv\n\nMove or rename a workspace file or directory.\n\n```text\ndench files mv <src> <dst> [--json]\n```\n\nBoth paths refer to workspace storage, not local disk.\n\n```sh\ndench files mv /reports/draft.md /reports/summary.md --json\n```\n\n### files rm\n\nRemove a workspace file or directory.\n\n```text\ndench files rm <path> [--recursive|-r] [--json]\n```\n\nDirectories require --recursive (or -r). An absent path is already removed.\n\n```sh\ndench files rm /reports/old --recursive --json\n```\n\n### files download\n\nDownload workspace bytes to local disk, or print a signed URL.\n\n```text\ndench files download <path> [<local-dest>] [--url] [--json]\n```\n\nWithout --url, downloads directories recursively and defaults the local destination to the path's basename (/ becomes workspace).\n\n--url prints a short-lived signed URL for one stored file instead of saving locally; local-dest is unused in this mode.\n\n```sh\ndench files download /reports/summary.pdf ./summary.pdf --json\ndench files download /reports/summary.pdf --url --json\n```\n\n\n## Supported command index\n\nThis is an operation index, not a promise that a command has no required arguments. Local-only entries identify their execution boundary.\n\n| Command | Purpose |\n| --- | --- |\n| `dench env list` | List workspace-shared reusable setups and ready revisions (metadata only). |\n| `dench env show` | Inspect a saved setup, its manifest, and an optional immutable revision. |\n| `dench env save` | Publish an explicitly saved source and manifest for one-time preparation. Returns pending/building until verified; does not run the task. |\n| `dench env delete` | Retire a saved setup from new selection; retain immutable revisions and active job evidence. |\n| `dench env run` | Run a command with prepared dependencies and declared credentials, saving declared state with a revision check. |\n| `dench secrets list` | List workspace-shared credential names, kinds and versions; never values. |\n| `dench secrets set` | Encrypt a workspace credential. Use CLI stdin or the secure chat form; return metadata only. Do not put values in chat, manifests or scripts. |\n| `dench secrets delete` | Revoke a workspace credential for future resolution, optionally checking its version. |\n| `dench campaign draft` | Create an idempotent empty campaign draft with the caller's available sender pools. Does not launch or send. |\n| `dench campaign search` | Search people by filters without adding CRM records or campaign recipients. Search credits apply; this is not a free provider preview. |\n| `dench campaign add --search` | Search and add up to 50 people to an existing campaign. New identities become Leads. Search credits apply; use nextPageToken for another page. |\n| `dench campaign add --people-file` | Add up to 50 selected recipients without another search. Deduplicates, applies suppression, and preserves the campaign's launch state. |\n| `dench campaign sources get` | Read a campaign's saved signal source, targeting and schedule. |\n| `dench campaign sources signals` | Read signal choices, suggested terms and current source configuration. |\n| `dench campaign sources set` | Update source cadence, pause/resume, targeting, signals or terms. Active sources may perform billable future work. |\n| `dench campaign sources preview` | Preview a signal source using its current audience. Provider credits may apply; does not enroll people. |\n| `dench campaign sources run` | Run a live campaign's signals now instead of waiting for the schedule (Run now). Provider credits apply; limited to 6 runs an hour. |\n| `dench campaign sources overview` | Read the Sources tab: each signal's status, last and next run, people found and anything needing attention. |\n| `dench campaign sources pending` | List people a signal found who are waiting for approval (manual approval mode). |\n| `dench campaign sources approve\\|reject` | Approve people waiting for review (they start the sequence) or reject them. |\n| `dench campaign queue` | Today's queue: who the campaign plans to contact today, warmest first, within the senders' limits. |\n| `dench campaign builder profile` | Read the company profile and suggested campaign audience. |\n| `dench campaign builder save` | Save a signal campaign's audience, signals and terms idempotently. Does not start a build. |\n| `dench campaign builder get` | Read signal build progress, preview people, messages and errors. |\n| `dench campaign builder build` | Start the same billable signal/audience/message build used by the UI; poll the draft for progress. |\n| `dench campaign builder create` | Create a campaign from a reviewed signal draft. Does not launch the campaign. |\n| `dench campaign builder opener` | Edit or reset one preview person's opening line before creating the campaign. |\n| `dench campaign builder drafts` | List saved, unfinished campaign drafts that can be resumed. |\n| `dench campaign builder resume` | Read a saved draft's setup (source, name, targeting, signals, terms, lookalike) to resume it. |\n| `dench campaign builder discard` | Discard a saved draft that has not become a campaign. |\n| `dench campaign builder outreach` | Save a draft's Outreach and Review choices: AI or manual steps, the brief, the steps, who sends and when, and auto or manual approval. |\n| `dench campaign builder sequence` | Generate the draft's sequence from a brief (goal, problem, tone, channels), as Generate sequence does. AI credits apply. |\n| `dench campaign builder lookalike` | Set up a lookalike from the best lead's LinkedIn URL (role, similar roles, place, industry, similar companies), suggest roles again, or re-scope to a company. Nothing is saved. Provider credits apply. |\n| `dench campaign builder voices` | Suggest market voices (LinkedIn experts) for the campaign's topics, to watch with voice_engagement. AI credits apply. |\n| `dench campaign builder autofill` | Turn an audience description into targeting filters. AI credits apply. |\n| `dench campaign builder estimate` | Estimate audience or weekly signal volume using the UI's cached estimator. Provider credits may apply. |\n| `dench help` | List all CLI/API operations and parity classifications. |\n| `dench signin` | Create an agent sign-in request. |\n| `dench signin --email` | Start the email OTP sign-in flow. |\n| `dench sessions` | List local CLI sessions. |\n| `dench use <session-key-or-workspace-slug>` | Select a local CLI session. |\n| `dench logout` | Remove local CLI sessions. |\n| `dench backend show\\|set\\|clear` | Configure the CLI backend target. |\n| `dench context --sections` | Read selected scoped workspace documents and a compact context index without writes. |\n| `dench context` | Return the current Dench workspace context for the bearer. |\n| `dench context --instructions` | Return the current workspace's standing instructions for external agents. |\n| `dench status` | Return workspace and agent status. |\n| `dench agents` | List agents visible in the workspace status payload. |\n| `dench approvals` | List approval requests visible in the workspace status payload. |\n| `dench artifacts` | List artifacts for the authenticated workspace. |\n| `dench suggested-work` | List draft suggested-work artifacts. |\n| `dench lists` | List saved searches (find-result lists) in the workspace, newest first. |\n| `dench lists rows` | Read saved rows with current enrichment results and original indices; cursor-paged, without repeating a search. |\n| `dench artifacts import` | Explicitly import selected saved profiles, optionally filtered by enrichment, with a configured Lead status. Reuses CRM records; never sends outreach or triggers conversion. |\n| `dench lists show` | Get one saved search / list by artifact id. |\n| `dench lists save` | Save find results as a named list (rows + filters become a workspace artifact). |\n| `dench lists update` | Update a saved list in place (title, filters, and/or replacement rows). |\n| `dench lists rename` | Rename a saved search / list. |\n| `dench lists delete` | Delete a saved search / list, its exported CSV/JSONL files, and any linked watch. |\n| `dench lists reviews` | Read durable enrichment activity (legacy review metadata remains readable). Use lists rows for current saved profiles and contacts. |\n| `dench lists assess` | Suggest ICP fit for one profile. Never changes a human review decision. |\n| `dench memory search` | Search durable workspace memory. |\n| `dench memory save` | Save a durable workspace memory fact. |\n| `dench approval request` | Request human approval. |\n| `dench approval approve\\|reject` | Record an approval decision. |\n| `dench billing status` | Get billing and AI credit status. |\n| `dench billing topup` | Create an AI credit top-up checkout link. |\n| `dench upgrade` | Create a workspace upgrade checkout link. |\n| `dench chat list` | List past chat threads. |\n| `dench chat search` | Search past chat messages. |\n| `dench chat read` | Read a past chat thread. |\n| `dench chat tree` | Read the parent-child chat thread hierarchy. |\n| `dench chat rename` | Rename one or more chat threads. |\n| `dench chat delete` | Delete one or more chat threads. |\n| `dench chat new` | Start a new chat-turn workflow. |\n| `dench chat send` | Send a message to an existing chat thread. |\n| `dench chat follow` | Follow a live chat response stream. |\n| `dench crm objects list [--with-references]` | List CRM objects. |\n| `dench crm objects list --compact` | List names, display labels, visibility and workspace counts without internal state. |\n| `dench crm objects get` | Get a CRM object. |\n| `dench crm objects create` | Create a CRM object. |\n| `dench crm objects update` | Update a CRM object. |\n| `dench crm objects rename` | Rename a CRM object. |\n| `dench crm objects delete` | Delete a CRM object. |\n| `dench crm objects archive` | Hide a CRM object's workspace sidebar row for the whole workspace. Not a delete — the table keeps working. Admin-only. |\n| `dench crm objects unarchive` | Restore a CRM object's workspace sidebar row. Admin-only. |\n| `dench crm views list` | List the saved views on a CRM object (plus the active view). |\n| `dench crm views get` | Get one saved view's definition by name. |\n| `dench crm views entries` | Materialize a saved view's rows (applies its filters/sort/pins), paginated. |\n| `dench crm views create` | Create a saved view (named filters/sort/columns combo) on a CRM object. |\n| `dench crm views update` | Replace a saved view's definition (upsert by name). |\n| `dench crm views rename` | Rename a saved view in place — keeps its filters, pins, and sidebar slot. |\n| `dench crm views delete` | Delete a saved view by name (idempotent). |\n| `dench crm views archive` | Move a pinned view's sidebar row into the Archived flyout. Admin-only. |\n| `dench crm views unarchive` | Restore a view's sidebar row (re-asserts its pin). Admin-only. |\n| `dench crm sidebar list` | Describe the workspace sidebar: Library rows in tree order (with their groups), the home-level Pinned strip, what is hidden and why, and whether the caller is an admin. |\n| `dench crm sidebar move` | Reposition one Library row (or group) among the Library's top-level slots. Does not add a home-level Pinned tab. Workspace-shared; admin-only. |\n| `dench crm sidebar group create` | Create a named sidebar group (e.g. \"Hiring\") in the workspace-shared Library. Open to any member. |\n| `dench crm sidebar group rename` | Rename a sidebar group. Open to any member. |\n| `dench crm sidebar group delete` | Dissolve a sidebar group; its rows return to the top level in its slot. Open to any member. |\n| `dench crm sidebar group add` | Move a sidebar row into a group (groupId set) or back to the top level (groupId null). Open to any member. |\n| `dench crm sidebar pin` | Pin (pinned true) or unpin a Library row — or a whole group — on the home-level Pinned shortcut strip (the \"tab on the left\"). Does not move the row inside Library. Workspace-shared; open to any member. |\n| `dench crm fields list` | List fields for a CRM object, including read-only calculation metadata. |\n| `dench crm fields list --compact` | List field names, types and effective constraints without indexing or enrichment internals. |\n| `dench crm fields create` | Create a CRM field or read-only campaign activity boolean column. |\n| `dench crm fields update` | Update a CRM field or change/explicitly clear an existing campaign calculation. |\n| `dench crm fields delete` | Delete a CRM field. |\n| `dench crm fields reorder` | Reorder CRM fields. |\n| `dench crm fields enum-reorder` | Reorder enum values. |\n| `dench crm fields enum-add` | Add an enum value. |\n| `dench crm fields enum-remove` | Remove an enum value. |\n| `dench crm fields enum-rename` | Rename an enum value. |\n| `dench crm fields enum-set-color` | Set an enum color. |\n| `dench crm entries list [--with-references]` | List CRM entries. |\n| `dench crm entries get` | Get a CRM entry. |\n| `dench crm entries sync-history` | Queue a full, paged pull of the record's email history from every connected mailbox; the ledger fills as pages land. |\n| `dench crm entries sync-history --status` | Has Dench read this record's email history? One row per address per mailbox. |\n| `dench crm entries dossier` | Status of the account's research dossier — the delimited `dench:dossier` section Dench keeps in the record's Notes: status, when it was written, how many dated updates followed, the last error. |\n| `dench crm entries dossier --regenerate` | Research the account again and append a fresh dossier section to its Notes (needs a Website / Domain on the record). |\n| `dench crm privacy status` | Whether the caller hides their own emails / messages with this record from the workspace (directly, or through its account), and whether they own a connection the toggle applies to. |\n| `dench crm privacy hide\\|show` | Hide (`hidden: true`) or show the caller's own emails / messages with this record to the workspace. An account covers every contact and opportunity linked to it; existing ledger rows are restamped and the shared Brief regenerates. |\n| `dench crm detections list` | List account-detection verdicts — why a domain (or personal address) did or did not become an account: verdict, counterparty type, probabilities, evidence threads, the rows created. `kind` picks the creator: `detections` (email + sweep), `linkedin` (the LinkedIn resolver's rows) or `all` (default). Newest first. |\n| `dench crm detections undo` | Undo what the ingestion jobs created since a timestamp (admin): `kind` = `detections` (accounts + contacts from the email detector and the sweep), `linkedin` (the LinkedIn resolver's contacts + accounts; their conversations are unlinked and parked), `email-tasks` (auto-created tasks and cases) or `all` (default). Deletes only rows no human has touched and marks the verdicts / decisions rolled_back so they are never re-created. `dryRun` lists what would go; per-kind counts in `kinds`. |\n| `dench crm history` | List a CRM entry's audit history. |\n| `dench crm activity` | List a CRM entry's activity ledger (comments, notes, field changes, emails, meetings, Slack, LinkedIn) in one timeline, newest first by default. |\n| `dench crm brief` | The record's generated Brief: health, who owes the next move, open threads, commitments, risks, next step. Read this before the ledger. |\n| `dench crm context` | Read-only source diagnostics: accessible evidence, association reasons, last Brief source manifest, generation queue, and your mailbox delivery health. Bounded, cursor-paged snapshot; does not certify complete history. |\n| `dench crm brief --regenerate` | Rebuild a record's Brief from the current timeline. |\n| `dench crm notes list` | List a CRM entry's notes (titled, document-style comments), newest first. |\n| `dench crm notes create` | Add a titled note to a CRM entry's activity timeline (markdown body). Research goes here, never into the Notes document. |\n| `dench crm comments list` | List comments on a CRM entry (roots newest first, with preview replies). |\n| `dench crm comments replies` | List every reply under a root comment, oldest first. |\n| `dench crm comments get` | Get one comment with its entry label. |\n| `dench crm comments create` | Comment on a CRM entry (markdown). Mention members with [@Name](/?member=<userId>); mention Dench with [@Dench](/?member=dench) or mentionDench. |\n| `dench crm comments update` | Edit a comment you wrote. |\n| `dench crm comments delete` | Delete a comment (kept as a tombstone when it has replies). |\n| `dench crm comments react` | Toggle an emoji reaction on a comment. |\n| `dench crm watch status` | Whether you follow a CRM entry's activity. |\n| `dench crm watch` | Follow or unfollow a CRM entry's activity. |\n| `dench crm tasks mine --page` | Page assigned tasks in priority order (or completed tasks by recency). |\n| `dench crm tasks list --page` | Page all tasks linked to a record, including subtasks. |\n| `dench crm tasks prepare` | Start or resume preparation of exact task ordering and progress. |\n| `dench crm tasks mine` | Your open tasks (plus ones completed today). |\n| `dench crm tasks list` | Tasks linked to a CRM entry. |\n| `dench crm tasks create` | Create a task linked to a CRM entry. |\n| `dench crm tasks complete` | Mark a task done. |\n| `dench crm tasks reopen` | Reopen a completed task. |\n| `dench crm tasks priority` | Set or clear a task's priority. |\n| `dench crm tasks subtasks` | A task's subtasks. |\n| `dench crm tasks create-subtask` | Create a subtask under a task (inherits the parent's record relations). |\n| `dench crm tasks parent` | Nest a task under a parent, or promote it (parentEntryId: null). |\n| `dench crm tasks delete` | Delete a task and its subtasks, or keep them as tasks. |\n| `dench crm tasks repeat` | How a task repeats (rule, RRULE, trigger, ends, next due). |\n| `dench crm tasks repeat --off` | Stop a task repeating (past occurrences are kept). |\n| `dench crm tasks repeat --skip` | Skip the current occurrence: the next one is created now. |\n| `dench crm tasks repeat --pause` | Pause a repeating task. |\n| `dench crm tasks repeat --resume` | Resume a paused repeating task. |\n| `dench crm tasks series` | Every repeating-task series in the workspace. |\n| `dench crm tasks series <seriesId> --occurrences` | Every occurrence (task) of one series. |\n| `dench crm entries create` | Create a CRM entry. |\n| `dench crm entries create-many` | Create many CRM entries. |\n| `dench crm entries update` | Update a CRM entry. |\n| `dench crm entries update-many` | Update many CRM entries. |\n| `dench crm entries delete` | Delete a CRM entry. |\n| `dench crm entries bulk-delete` | Bulk delete CRM entries. |\n| `dench crm cells get` | Get a CRM cell value. |\n| `dench crm cells set` | Set a CRM cell value. |\n| `dench crm cells set-many` | Set many CRM cell values. |\n| `dench crm cells append` | Append to a CRM cell. |\n| `dench crm query [--with-references]` | Query CRM entries. |\n| `dench crm query --page` | Scan CRM entries with a resumable cursor. Empty filtered pages can have more results. |\n| `dench crm sql` | Run CRM SQL-compatible query. |\n| `dench crm aggregate` | Aggregate CRM entries. |\n| `dench crm search [--with-references]` | Search CRM entries. |\n| `dench crm search --page` | Search bounded pages of readable CRM entries, optionally projecting cells. Always follow continueCursor until isDone. |\n| `dench crm statuses list` | List CRM statuses. |\n| `dench crm statuses set` | Set CRM statuses. |\n| `dench crm batch` | Apply a CRM batch. |\n| `dench crm transaction begin` | Begin a CRM transaction. |\n| `dench crm transaction add` | Add an operation to a CRM transaction. |\n| `dench crm transaction commit` | Commit a CRM transaction. |\n| `dench crm transaction abort` | Abort a CRM transaction. |\n| `dench crm transaction inspect` | Inspect a CRM transaction. |\n| `dench crm docs list` | List CRM documents. |\n| `dench crm docs create` | Create a CRM document. |\n| `dench crm docs link` | Link a CRM document. |\n| `dench crm actions list` | List CRM actions. |\n| `dench crm actions create` | Create or upsert an action button on a named action column (fieldName is the column header; a column can hold multiple buttons — reuse fieldName to add more). |\n| `dench crm actions edit` | Update an action button on a CRM field. |\n| `dench crm actions delete` | Delete an action button from a CRM field. |\n| `dench crm actions run` | Run a CRM action on one or more entries. |\n| `dench members list` | List workspace members for CRM user fields. |\n| `dench members presence` | Live presence (online / away / offline) for workspace members. |\n| `dench members get` | A member's profile: name, email, tagline, role, timezone, presence, open task count. |\n| `dench members activity` | A member's recent comments and record changes across the CRM, newest first. |\n| `dench members tasks` | Open tasks assigned to a member (plus ones completed today). |\n| `dench members me` | Your own member profile. |\n| `dench members me --name … --tagline … --timezone …` | Update your name, tagline, avatar URL, or timezone. |\n| `dench members me --avatar <file>` | Get a one-time URL to POST an avatar image to; then PUT /me/avatar with the returned storageId. |\n| `dench members me --clear-avatar` | Remove your avatar. |\n| `dench crm reports generate` | Generate a CRM report. |\n| `dench crm analytics get` | Read an object's analytics dashboard: panels, field roles, the strip's collapsed flag, the named view's own dashboard (if any), and the fields panels may bucket on (synthetic $createdAt / $location last). |\n| `dench crm analytics compute` | Compute chart-ready results (buckets / series / values) for the stored dashboard, a subset of its panels, or ad-hoc panel definitions — optionally scoped to a saved view, a period preset (with the previous interval as previousValue) and extra filters. Same query the strip renders from. |\n| `dench crm analytics save` | Create or update one panel (upsert by id). With viewName the write lands on that saved view's own dashboard, forking a copy if it was still inheriting the object's. |\n| `dench crm analytics update` | Edit part of one stored panel: only the keys in `patch` change (title, type, metric, metricField, groupBy, dateField, dateBucket, filters, derived, span, hidden, sortOrder); null clears an optional key. What the card's ⋮ menu writes. |\n| `dench crm analytics hide` | Take a chart off the strip above the table (hidden: true). It stays in the full analytics view, counted by the strip's “+N more”. |\n| `dench crm analytics show` | Bring a hidden chart back onto the strip (hidden: false). |\n| `dench crm analytics resize` | Set a card's width on the 6-track dashboard grid: span 2 (third), 3 (half), 4 (two thirds), 6 (full), or null for the chart kind's default. |\n| `dench crm analytics delete` | Delete one panel (idempotent). Template panels are tombstoned so a re-install never resurrects them. |\n| `dench crm analytics reorder` | Persist the full panel order. panelIds must name every stored panel of the targeted dashboard. |\n| `dench crm analytics roles` | Set the object's analytics setup — the field roles shared by every chart and view (amount, stage, won/lost/converted values, stageProbabilities, closeDate, recurrence, owner, location). Replaces the mapping; with merge: true only the keys given change and null clears one. |\n| `dench crm analytics collapse` | Collapse the analytics strip above the object's table (team-shared, like saved views). |\n| `dench crm analytics expand` | Expand the analytics strip above the object's table. |\n| `dench crm analytics scope` | Give a saved view its own dashboard (mode \"own\": starts as a copy of the object's panels) or hand it back to the object's shared one (mode \"shared\"). |\n| `dench crm enrich cell` | Request enrichment for one CRM cell. |\n| `dench crm enrich object` | Request enrichment for a CRM object. |\n| `dench crm people search` | Search for people through the enrichment gateway. `companyDomains` takes up to 1000 domains (e.g. a resolved company list; `dench leads find --company-list <id\\|view>` resolves one for you) — the gateway fans large lists out as sequential vendor-safe chunks behind one `nextPageToken` stream. |\n| `dench crm companies search` | Search for companies through the enrichment gateway (also `dench companies find`). |\n| `dench jobs find` | Search job postings through Dench find. `companyDomains` takes up to 1000 domains (chunked automatically); `dench jobs find --company-list <id\\|view>` resolves a saved company list into it. |\n| `dench crm enrich profiles` | Look up up to 100 people or company profiles without buying emails or phones. Pass kind (people\\|companies) and lookups; results preserve inputIndex. People require linkedinUrl or email; companies require domain or linkedinUrl. |\n| `dench companies related` | Read company employees, founders, funding, investors, acquisitions, or investments. Pass domain or linkedinUrl, kind, limit (1–100), and optional pageToken. Does not import CRM records or buy contacts. |\n| `dench leads find --limit 1` | Preview how many records a find would return. |\n| `dench leads filters` | List Lead Finder filter vocabularies: exact enum values (seniorities, functions, industries, headcount, company types, languages) and curated suggestions (titles, locations, company HQ, universities, skills, keywords). |\n| `dench crm templates list` | List one-click CRM templates (objects + automations + sample rows) with per-workspace installed flags. |\n| `dench crm templates install` | Install a CRM template. Idempotent: re-installs top up missing pieces and never duplicate objects, automations, or sample rows. |\n| `dench crm templates remove-sample-data` | Delete a CRM template's sample rows (tagged \"Sample\"); schema, views, and automations stay. |\n| `dench crm automations list` | List deterministic CRM automations (rules that fire inside entry writes, e.g. qualified prospect → opportunity). |\n| `dench crm automations enable\\|disable` | Enable or disable a CRM automation. |\n| `dench crm import` | Import a local CSV into a CRM object. |\n| `dench crm export` | Export a CRM object to a local CSV. |\n| `dench meetings list` | List meetings, newest first, with status and participants. |\n| `dench meetings transcript get` | Read a meeting's transcript, in order, one page at a time. |\n| `dench meetings transcript set` | Append up to 500 transcript segments to a meeting (speakers with an email link to existing people). |\n| `dench meetings transcript clear` | Delete a batch of a meeting's transcript segments; repeat until `done` before re-appending. |\n| `dench meetings action-items list` | List a meeting's action items. |\n| `dench meetings action-items set` | Add action items to a meeting; `replace: true` swaps the whole list. |\n| `dench meetings action-items done` | Tick or untick one action item. |\n| `dench meetings action-items delete` | Delete one action item. |\n| `dench meetings participants list` | Who was in the meeting, merged with the linked calendar invite. |\n| `dench meetings participants set` | Record attendees by name/email; known members and existing people are linked, nobody is created. |\n| `dench meetings share` | Whether a meeting is shared with the whole workspace, and whether you may change that. |\n| `dench meetings share --workspace` | Share one meeting with the workspace, or take it back to owner + invitees. |\n| `dench meetings import` | Import calls from a local CSV/JSONL: meeting fields plus transcript, action items and attendees per row. |\n| `dench email identity verify` | Start Dench Emailing Service sender verification. |\n| `dench email identity status --identity-id` | Refresh a Dench Emailing Service sender verification status. |\n| `dench email identity status` | Read Dench Emailing Service sender verification status. |\n| `dench email identity list` | List the workspace's email sending identities. |\n| `dench email identity dns` | Fetch DNS records (DKIM/SPF/DMARC) for a pending domain sender verification. |\n| `dench email identity disable` | Soft-disable a sender (or every sender on a domain) for the workspace; sends are blocked until restored. |\n| `dench email identity restore` | Restore a previously disabled sender for the workspace. |\n| `dench email identity delete` | Permanently delete a sender (or every sender on a domain) from the workspace; re-adding it requires verification from scratch. |\n| `dench email inbox search` | Search authorized synced mailbox headers with bounded cursor pagination. isDone covers stored records, not provider completeness. |\n| `dench email inbox thread` | Read a bounded page of synced headers using an exact thread handle from inbox search; bodies remain on demand. |\n| `dench email inbox message` | Read a bounded stored body using an exact message handle from inbox search; rechecks mailbox and record privacy. |\n| `dench email draft create` | Create an editable Dench email draft and synchronize its selected native mailbox asynchronously. Use a stable requestId for retries. |\n| `dench email draft show` | Read an email draft, eligible senders and provider sync status. |\n| `dench email draft senders` | List native mailboxes this caller may use. |\n| `dench email draft update` | Save draft content using expectedRevision; sender changes require a new draft after provider binding. |\n| `dench email draft send` | Send the current Dench draft revision through its native mailbox. Repeated requests share a durable receipt. |\n| `dench email draft attach` | Upload attachment bytes authorized against this draft before adding its storage reference. |\n| `dench email draft signature` | Load the selected mailbox signature for explicit visible insertion. |\n| `dench email send [--mailbox <id/email>]` | Send through a native Gmail or Outlook mailbox with a durable request receipt. Only use for an explicit send request. |\n| `dench email send --from <verified-email>` | Send one raw email (no campaign): to/cc/bcc, custom from-name and reply-to, optional reply threading via replyToMessageId. |\n| `dench email message status` | Read a raw email message's status and open/click counters. |\n| `dench email message list` | List recent raw email messages for the workspace. |\n| `dench email template create` | Create a managed email campaign template. |\n| `dench email template preview` | Preview a managed email campaign template. |\n| `dench email campaign create` | Create a managed email campaign draft from a connected inbox or verified sender. |\n| `dench email campaign status` | Read campaign status and counters. |\n| `dench email campaign recipients add` | Add recipients to a managed email campaign. |\n| `dench email campaign preview` | Preview rendered messages for a campaign sample. |\n| `dench email campaign submit` | Submit a campaign for approval or sending. |\n| `dench email campaign pause` | Pause a sending email campaign. |\n| `dench email campaign resume` | Resume a paused email campaign. |\n| `dench email campaign cancel` | Cancel an email campaign. |\n| `dench email campaign list` | List managed email campaigns (paginated, optional status filter). |\n| `dench email campaign recipients list` | List a campaign's recipients (paginated, optional status filter). |\n| `dench email campaign recipients add-from-object` | Add campaign recipients from a CRM object: pick the object, the email field, and the entry ids. |\n| `dench email sequence create` | Create a follow-up sequence from a connected inbox or verified sender. |\n| `dench email sequence update` | Update a sequence's name, sender, or reply/stop settings. |\n| `dench email sequence activate` | Activate a sequence so its enrollments begin sending. |\n| `dench email sequence deactivate` | Deactivate a sequence (pause sending, revert to draft). |\n| `dench email sequence archive` | Archive a sequence (stops all sending). |\n| `dench email sequence list` | List the workspace's follow-up sequences. |\n| `dench email sequence status` | Read a sequence with its ordered steps. |\n| `dench email sequence steps add` | Add a step (subject, body, and wait delay) to a sequence. |\n| `dench email sequence steps update` | Update a sequence step's subject, body, or delay. |\n| `dench email sequence steps remove` | Remove a step from a sequence. |\n| `dench email sequence steps reorder` | Reorder a sequence's steps. |\n| `dench email sequence enroll` | Enroll explicit recipients into a sequence. |\n| `dench email sequence enroll-from-object` | Enroll people from a CRM object: pick the object, the email field, and the entry ids. |\n| `dench email sequence enrollments list` | List a sequence's enrollments (paginated, optional status filter). |\n| `dench email sequence enrollment pause` | Pause one enrollment. |\n| `dench email sequence enrollment resume` | Resume one paused enrollment. |\n| `dench email sequence enrollment stop` | Stop one enrollment (no further steps send). |\n| `dench campaign accounts` | Discover LinkedIn sender ids, labels, availability and remaining capacity visible to the acting workspace member. Never returns provider credentials. |\n| `dench campaign list [--with-references]` | List outreach campaigns (archived ones on request). |\n| `dench campaign create` | Create a draft outreach campaign with email and LinkedIn sender pools and a business-hours send window in the given timezone. |\n| `dench campaign duplicate` | Copy a campaign into a new draft named \"<name> copy\": the same steps, schedule, sender pools and personalized lines, its lead source paused, and no people. To reach more than 300 people, duplicate and add the next page of the search to the copy. |\n| `dench campaign get` | Read a campaign: settings, steps, people, their current step and hold, last touches, linked leads. |\n| `dench campaign pipeline` | Where a campaign's people sit in the workspace's lead pipeline right now: each lead Status in order with how many enrolled leads are at it, and how many have no lead or a status outside the pipeline. |\n| `dench campaign set` | Change a campaign's name, sender pools, send windows, daily email cap, stop-on-reply, start or end. Works until archived; existing conversations keep their assigned sender. |\n| `dench campaign steps set` | Replace every step of a draft campaign (email, wait, LinkedIn visit, connection request, message, post reaction, InMail, If / else, Wait for them to accept). A workflow (stepModel workflow, or steps with key, next, yesNext or noNext) branches: condition and wait_for_connection steps continue on yesNext or noNext, other steps on next; each points at another step's key or end. Steps are checked first: a field the step type would drop, missing text, {TOKEN} single braces or paths that don't hold together are rejected, not saved. Configure sender pools on the campaign; step sender ids are legacy-only. |\n| `dench campaign steps edit` | Edit the text, waits and conditions of a launched (or paused) campaign's steps in place. Each step keeps its id, type and place; pass the stepId and the updatedAt you read, and only the fields you change. A workflow keeps its paths and what each If / else checks (key, next, yesNext, noNext, check, conditionField, conditionOperator); conditionValue and acceptance waits stay editable. Messages already sent or being prepared keep their text; drafts use campaigns.steps.replace. |\n| `dench campaign personalize get` | Read a campaign's personalized lines (written for each person): their {{keys}} for steps, instructions and fallbacks, how many people have them, and the cost per person. |\n| `dench campaign personalize set` | Define up to 5 personalized lines (each used as {{key}} in steps) and what you sell. Saving starts writing missing lines for up to 100 people, about 3 cents a person; for more it returns needsConfirm and writes nothing until campaigns.personalization.write is confirmed. |\n| `dench campaign personalize clear` | Turn off a campaign's personalized lines and cancel the ones not yet written. Refused while a step still uses one of the {{keys}}. |\n| `dench campaign personalize write` | Write personalized lines for the people missing them (mode missing) or rewrite everyone's (mode all). Rewriting everyone or more than 100 people returns needsConfirm and the estimate until called with confirmed: true. |\n| `dench campaign personalize edit` | Set one person's personalized line by hand; an empty value undoes the edit. Braces are removed and text past the line's length is cut. |\n| `dench campaign personalize rewrite` | Write a fresh personalized line for one person: one key, or all of their lines when key is left out. About 3 cents. |\n| `dench campaign add` | Add CRM records (up to 100 ids per call) to a campaign; returns how many were added and why others were skipped. |\n| `dench campaign add --name` | Add one person by email and/or LinkedIn profile URL. |\n| `dench campaign preview` | Show the message one person gets at one email or LinkedIn step, with their fields and personalized lines filled in: subject, body, sender, recipient, merge fields still missing, warnings, and why the step would be skipped. Nothing is sent, prepared or charged. |\n| `dench campaign launch --check` | Launch readiness without launching: blockers grouped by problem, warnings, and the fingerprint `launch` requires. |\n| `dench campaign launch` | Launch a ready draft. Pass the fingerprint from the preview and acknowledge the LinkedIn notice when LinkedIn steps exist. |\n| `dench campaign pause` | Pause an active campaign. |\n| `dench campaign resume` | Resume a paused campaign. |\n| `dench campaign archive` | Archive a campaign and stop everyone still in flight. This is the app's Delete: campaigns are never erased, and their people, leads and activity stay. |\n| `dench campaign events` | The campaign's activity log, newest first (sent, accepted, replied, skipped, failed, paused, stopped). |\n| `dench campaign stop` | Stop one person: nothing more is sent to them from this campaign. |\n| `dench campaign resume-person` | Resume one paused person in an active campaign. |\n| `dench campaign person set --email` | Give a person in a draft campaign a new or corrected email address; their linked CRM record gets it too. Only before launch; another person in the campaign can't share it. |\n| `dench campaign person set --linkedin-url` | Give a person in a draft campaign a new or corrected LinkedIn profile URL; their linked CRM record gets it too. Only before launch. |\n| `dench campaign person set --field` | Fill or fix one {{merge field}} for a person in a draft campaign, e.g. a missing Company that blocks launch; a matching column on their CRM record is updated too. Only before launch; written personalized lines are not merge fields and can't be set here. |\n| `dench campaign resume-person --all` | Resume every paused person in an active campaign at once, e.g. after a sending account is reconnected. Returns how many were resumed. |\n| `dench campaign sync` | Fill each unfinished person's empty email, LinkedIn URL, name and merge fields from their linked CRM record, e.g. after enriching the records. Never overwrites a value the campaign already has; returns how many people changed. |\n| `dench campaign where` | The campaigns a CRM record (a person or a lead) is in, newest first, with the person's status in each and the accounts that send to them. |\n| `dench campaign person show` | Everything a campaign did for one person, step by step: what was sent (subject and text), whether it was opened or clicked, what was skipped and why, waits, failures and retries. |\n| `dench campaign remove` | Remove a person who was never contacted from a draft campaign. Frees their place in the 300-person cap and keeps the draft launchable; stop anyone already contacted instead. |\n| `dench cron list` | List routines. |\n| `dench cron history` | List routine run history. |\n| `dench cron get` | Get a routine. |\n| `dench cron create` | Create a routine. |\n| `dench cron update` | Update a routine. |\n| `dench cron delete` | Delete a routine. |\n| `dench cron enable` | Enable a routine. |\n| `dench cron disable` | Disable a routine. |\n| `dench cron run` | Run a routine now. |\n| `dench cron runs` | List runs for a routine. |\n| `dench files ls [<path>] [--recursive\\|-r] [--json]` | List workspace files; the default path is /. |\n| `dench files cat <path> [--json]` | Read a workspace file's inline text. |\n| `dench files write <path> [--json]` | Write a workspace file's text from stdin. |\n| `dench files download <path> [<local-dest>] [--url] [--json]` | Download workspace bytes to local disk, or print a signed URL. |\n| `dench files rm <path> [--recursive\\|-r] [--json]` | Remove a workspace file or directory. |\n| `dench files mv <src> <dst> [--json]` | Move or rename a workspace file or directory. |\n| `dench stage` | Stage uploaded content into the workspace. |\n| `dench fs` | Run the local file sync daemon. |\n| `dench search` | Search the web through the Dench gateway. |\n| `dench search contents` | Fetch page contents through the Dench gateway. |\n| `dench search answer` | Answer a question with web search. |\n| `dench web scrape` | Read a page as clean Markdown through Dench web. |\n| `dench web brand` | Look up a brand kit from a domain or email. |\n| `dench web sitemap` | List sitemap URLs for a domain. |\n| `dench web crawl` | Crawl a site to Markdown (capped). |\n| `dench web screenshot` | Capture a rendered page screenshot. |\n| `dench web extract` | Extract typed fields from a page using a JSON Schema. |\n| `dench web product` | Extract a product listing from a URL. |\n| `dench web competitors` | Find competitors of a domain. |\n| `dench web styleguide` | Read a brand styleguide from a domain. |\n| `dench web fonts` | Read site fonts from a domain. |\n| `dench web classify` | Classify a domain with NAICS or SIC. |\n| `dench web brand-search` | Autocomplete brand names. |\n| `dench image generate` | Generate an image through the Dench gateway. |\n| `dench image edit` | Edit an image through the Dench gateway. |\n| `dench integrations` | List every connected integration — connected apps plus the Gmail, Outlook, Calendar, LinkedIn and Slack connections Dench provides itself (Slack rows report source: dench). |\n| `dench apps list` | List installed App Store apps in the workspace. |\n| `dench apps gallery` | List Discover listings — Official (Dench) + Community shelves. |\n| `dench apps create` | Scaffold and register a new App Store app. |\n| `dench apps install` | Install an App Store listing into the workspace. |\n| `dench apps publish` | Publish an app's files as a versioned App Store listing. |\n| `dench apps uninstall` | Uninstall an app from the workspace. |\n| `dench apps enable` | Enable or disable an installed app. |\n| `dench apps pin` | Pin or unpin an installed app in the rail. |\n| `dench apps validate` | Validate a .dench.app folder: manifest, permissions, and every window.dench call it makes. |\n| `dench apps webhooks register` | Register an inbound webhook for an app. Returns the URL and signing secret ONCE. |\n| `dench apps webhooks list` | List an app's registered webhooks (URLs, never secrets). |\n| `dench apps webhooks poll` | Read events an app webhook received since a timestamp. |\n| `dench apps webhooks delete` | Remove an app webhook and every event it stored. |\n| `dench tool status` | List connected tool accounts. |\n| `dench tool connect` | Create a tool OAuth connection link. Slack is in-house, never a third-party connection: for toolkit slack the CLI prints the first-party install URL (/api/slack/install?slug=<workspace>, org admin) instead of calling this endpoint. |\n| `dench tool search` | Search for external tool actions. |\n| `dench tool run` | Run an external tool action. SLACK_* slugs (SLACK_SEND_MESSAGE with Block Kit blocks/buttons, SLACK_FETCH_HISTORY, SLACK_LIST_CHANNELS, …) run through Dench's in-house Slack app install — any channel in the connected workspace — and are always preferred over any third-party Slack connection. |\n| `dench tool disconnect` | Disconnect an external tool account. |\n| `dench tool labels` | List human names given to connected accounts. |\n| `dench tool label` | Name a connected account, or clear its name with an empty string. |\n| `dench browser` | Drive Dench Browser with a single interactive action (open, inspect, click, fill, type, screenshot, stop). Pass the step in `action` plus its arguments. |\n| `dench browser session create` | Create a Dench Browser session and return a CDP connect URL for Playwright (chromium.connectOverCDP) plus a live-view URL. Use for durable scripts run from the sandbox. |\n| `dench browser session status` | Get the status, connect URL, and live-view URL for a Dench Browser session. |\n| `dench browser session stop` | Stop a Dench Browser session and release the remote browser. |\n| `dench context --sections identity` | Read IDENTITY.md. |\n| `dench context set identity` | Update IDENTITY.md. |\n| `dench context --sections organisation` | Read ORGANISATION.md. |\n| `dench context set organisation` | Update ORGANISATION.md. |\n| `dench context --sections user` | Read USER.md. |\n| `dench context set user` | Update USER.md. |\n| `dench context --sections tools` | Read tool notes. |\n| `dench context set tools` | Update tool notes. |\n| `dench context set rules` | Update standing workspace rules; credentials belong in secrets and runnable setup in environments. |\n| `dench model default` | Set the default chat model. |\n| `dench model thread` | Set a thread model override. |\n| `dench notifications list` | List your notifications (inbox, unread, archived, or all). |\n| `dench notifications count` | How many unread notifications you have. |\n| `dench notifications read` | Mark a notification read (or unread). |\n| `dench notifications read-all` | Mark every inbox notification read. |\n| `dench notifications archive` | Archive a notification. |\n| `dench notifications prefs` | Read your notification preferences. |\n| `dench notifications prefs --set` | Update your notification preferences. |\n| `dench settings sync` | Read the workspace's Sync switches (accounts from email, contacts from LinkedIn, Slack Connect, calendar, dossier, tasks from email, lead auto-qualify, summaries and Brief). All on by default. |\n| `dench settings sync set` | Flip Sync switches (admin). Partial patch: only the keys sent change. Off stops new work; nothing already created is removed. |\n\n## Compatibility\n\nExisting identity/organisation/user/tools aliases still address the same stored documents. Prefer `dench context --sections …` and `dench context set …`. Aggregate `dench mem` and bootstrap endpoints remain compatibility readers/writers while existing clients migrate; they are not the recommended memory API. Existing history is retained. No `dench agent spawn/await/message/wait-message/pause/resume/continue/tree` commands exist; use the harness subagent tools or supported `dench chat` commands.\n"
|
|
34
|
+
"sha256": "4cf770b52942820d9f5bc085fd826c31c1f834010d26bcecbbe20293dff6834d",
|
|
35
|
+
"content": "<img src=\"/logos/apple-touch-icon.png\" alt=\"Dench\" width=\"32\" height=\"32\">\n\n# Dench CLI\n\nGenerated from the command registry, native file-command contracts and saved-setup parsers. Run `dench <command> --help` for arguments and flags. API-only upload phases and compatibility aliases are not standalone commands.\n\nUse `dench context --sections organisation,user,memory` for knowledge, `dench memory` for facts, `dench env` for explicitly saved executable setups, and `dench secrets` for encrypted credentials. `dench cron secret` signs inbound webhooks; it does not store service credentials.\n\n## Reusable setups\n\n```text\ndench env — verified setups reused across chats\n\n dench env list [--limit N] [--cursor CURSOR] [--json]\n dench env show NAME [--revision SHA256] [--json]\n dench env save NAME --path DIRECTORY [--wait SECONDS | --no-wait] [--json]\n dench env run NAME [--revision SHA256] [--state-key KEY] [--prepare-local] [--json] -- COMMAND [ARGS...]\n dench env delete NAME [--json]\n\nSave requires dench-env.json, SKILL.md, an explicit files allowlist and verify\ncommands. Credentials, caches and symlinks are excluded from source uploads.\nSave returns an authoritative preparation receipt; default observation is 10s.\nReady runs reuse prepared dependencies. --prepare-local explicitly prepares a\nseparate local platform cache once; ordinary ready runs never reinstall.\nState is job-local by default; choose an explicit state key to share it.\nExample: dench env run openai-report -- node report.mjs\n```\n\n```text\ndench secrets — workspace-shared encrypted credentials\n\n dench secrets set NAME --stdin [--kind env|file] [--expected-version N] [--json]\n dench secrets set NAME --file PATH [--kind env|file] [--expected-version N] [--json]\n dench secrets list [--json]\n dench secrets delete NAME [--expected-version N] [--json]\n\nValues are accepted only through stdin or a file. Values are never printed.\nBind a stored name in dench-env.json secretEnv or secretFiles; env run injects\nonly those bindings. Memory is not credential storage. --kind defaults to env.\nExample: dench secrets set OPENAI_API_KEY --stdin < /private/path/key.txt\n```\n\nSee [ENVIRONMENTS.md](ENVIRONMENTS.md) for the manifest, preparation lifecycle, state and security rules.\n\n## Workspace files\n\nWorkspace paths are POSIX paths under /workspace; /reports/a.md and /workspace/reports/a.md address the same file.\n\nThese commands read or update workspace storage. Use dench stage to upload local files or directories.\n\n### files ls\n\nList workspace files; the default path is /.\n\n```text\ndench files ls [<path>] [--recursive|-r] [--json]\n```\n\n--recursive (or -r) includes descendants.\n\n```sh\ndench files ls /reports --recursive --json\n```\n\n### files cat\n\nRead a workspace file's inline text.\n\n```text\ndench files cat <path> [--json]\n```\n\nUse cat for virtual files such as IDENTITY.md and ORGANISATION.md, which have no download blob.\n\nFor binary files or files without inline text, use files download.\n\n```sh\ndench files cat /reports/summary.md\n```\n\n### files write\n\nWrite a workspace file's text from stdin.\n\n```text\ndench files write <path> [--json]\n```\n\nThe destination path is required. Pipe or redirect the raw UTF-8 file text into stdin.\n\n--json controls the result format; stdin is file content, not an API JSON envelope. No --stdin, --content or --file flag is supported.\n\nWriting replaces the complete text; empty stdin writes an empty file.\n\n```sh\ndench files write /reports/summary.md --json < ./summary.md\nprintf '%s\\n' 'Report ready.' | dench files write /reports/summary.md --json\n```\n\n### files mv\n\nMove or rename a workspace file or directory.\n\n```text\ndench files mv <src> <dst> [--json]\n```\n\nBoth paths refer to workspace storage, not local disk.\n\n```sh\ndench files mv /reports/draft.md /reports/summary.md --json\n```\n\n### files rm\n\nRemove a workspace file or directory.\n\n```text\ndench files rm <path> [--recursive|-r] [--json]\n```\n\nDirectories require --recursive (or -r). An absent path is already removed.\n\n```sh\ndench files rm /reports/old --recursive --json\n```\n\n### files download\n\nDownload workspace bytes to local disk, or print a signed URL.\n\n```text\ndench files download <path> [<local-dest>] [--url] [--json]\n```\n\nWithout --url, downloads directories recursively and defaults the local destination to the path's basename (/ becomes workspace).\n\n--url prints a short-lived signed URL for one stored file instead of saving locally; local-dest is unused in this mode.\n\n```sh\ndench files download /reports/summary.pdf ./summary.pdf --json\ndench files download /reports/summary.pdf --url --json\n```\n\n\n## Supported command index\n\nThis is an operation index, not a promise that a command has no required arguments. Local-only entries identify their execution boundary.\n\n| Command | Purpose |\n| --- | --- |\n| `dench env list` | List workspace-shared reusable setups and ready revisions (metadata only). |\n| `dench env show` | Inspect a saved setup, its manifest, and an optional immutable revision. |\n| `dench env save` | Publish an explicitly saved source and manifest for one-time preparation. Returns pending/building until verified; does not run the task. |\n| `dench env delete` | Retire a saved setup from new selection; retain immutable revisions and active job evidence. |\n| `dench env run` | Run a command with prepared dependencies and declared credentials, saving declared state with a revision check. |\n| `dench secrets list` | List workspace-shared credential names, kinds and versions; never values. |\n| `dench secrets set` | Encrypt a workspace credential. Use CLI stdin or the secure chat form; return metadata only. Do not put values in chat, manifests or scripts. |\n| `dench secrets delete` | Revoke a workspace credential for future resolution, optionally checking its version. |\n| `dench campaign draft` | Create an idempotent empty campaign draft with the caller's available sender pools. Does not launch or send. |\n| `dench campaign search` | Search people by filters without adding CRM records or campaign recipients. Search credits apply; this is not a free provider preview. |\n| `dench campaign add --search` | Search and add up to 50 people to an existing campaign. New identities become Leads. Search credits apply; use nextPageToken for another page. |\n| `dench campaign add --people-file` | Add up to 50 selected recipients without another search. Deduplicates, applies suppression, and preserves the campaign's launch state. |\n| `dench campaign sources get` | Read a campaign's saved signal source, targeting and schedule. |\n| `dench campaign sources signals` | Read signal choices, suggested terms and current source configuration. |\n| `dench campaign sources set` | Update source cadence, pause/resume, targeting, signals or terms. Active sources may perform billable future work. |\n| `dench campaign sources preview` | Preview a signal source using its current audience. Provider credits may apply; does not enroll people. |\n| `dench campaign sources run` | Run a live campaign's signals now instead of waiting for the schedule (Run now). Provider credits apply; limited to 6 runs an hour. |\n| `dench campaign sources overview` | Read the Sources tab: each signal's status, last and next run, people found and anything needing attention. |\n| `dench campaign sources pending` | List people a signal found who are waiting for approval (manual approval mode). |\n| `dench campaign sources approve\\|reject` | Approve people waiting for review (they start the sequence) or reject them. |\n| `dench campaign queue` | Today's queue: who the campaign plans to contact today, warmest first, within the senders' limits. |\n| `dench campaign builder profile` | Read the company profile and suggested campaign audience. |\n| `dench campaign builder save` | Save a signal campaign's audience, signals and terms idempotently. Does not start a build. |\n| `dench campaign builder get` | Read signal build progress, preview people, messages and errors. |\n| `dench campaign builder build` | Start the same billable signal/audience/message build used by the UI; poll the draft for progress. |\n| `dench campaign builder create` | Create a campaign from a reviewed signal draft. Does not launch the campaign. |\n| `dench campaign builder opener` | Edit or reset one preview person's opening line before creating the campaign. |\n| `dench campaign builder drafts` | List saved, unfinished campaign drafts that can be resumed. |\n| `dench campaign builder resume` | Read a saved draft's setup (source, name, targeting, signals, terms, lookalike) to resume it. |\n| `dench campaign builder discard` | Discard a saved draft that has not become a campaign. |\n| `dench campaign builder outreach` | Save a draft's Outreach and Review choices: AI or manual steps, the brief, the steps, who sends and when, and auto or manual approval. |\n| `dench campaign builder sequence` | Generate the draft's sequence from a brief (goal, problem, tone, channels), as Generate sequence does. AI credits apply. |\n| `dench campaign builder lookalike` | Set up a lookalike from the best lead's LinkedIn URL (role, similar roles, place, industry, similar companies), suggest roles again, or re-scope to a company. Nothing is saved. Provider credits apply. |\n| `dench campaign builder voices` | Suggest market voices (LinkedIn experts) for the campaign's topics, to watch with voice_engagement. AI credits apply. |\n| `dench campaign builder autofill` | Turn an audience description into targeting filters. AI credits apply. |\n| `dench campaign builder estimate` | Estimate audience or weekly signal volume using the UI's cached estimator. Provider credits may apply. |\n| `dench help` | List all CLI/API operations and parity classifications. |\n| `dench signin` | Create an agent sign-in request. |\n| `dench signin --email` | Start the email OTP sign-in flow. |\n| `dench sessions` | List local CLI sessions. |\n| `dench use <session-key-or-workspace-slug>` | Select a local CLI session. |\n| `dench logout` | Remove local CLI sessions. |\n| `dench backend show\\|set\\|clear` | Configure the CLI backend target. |\n| `dench context --sections` | Read selected scoped workspace documents and a compact context index without writes. |\n| `dench context` | Return the current Dench workspace context for the bearer. |\n| `dench context --instructions` | Return the current workspace's standing instructions for external agents. |\n| `dench status` | Return workspace and agent status. |\n| `dench agents` | List agents visible in the workspace status payload. |\n| `dench approvals` | List approval requests visible in the workspace status payload. |\n| `dench artifacts` | List artifacts for the authenticated workspace. |\n| `dench suggested-work` | List draft suggested-work artifacts. |\n| `dench lists` | List saved searches (find-result lists) in the workspace, newest first. |\n| `dench lists rows` | Read saved rows with current enrichment results and original indices; cursor-paged, without repeating a search. |\n| `dench lists enrich` | Buy contact details for 1–100 saved profiles and save them to the list. Skips fields already found, looked up empty, or in flight. Requires a signed-in member or their personal agent. |\n| `dench artifacts import` | Explicitly import selected saved profiles, optionally filtered by enrichment, with a configured Lead status. Reuses CRM records; never sends outreach or triggers conversion. |\n| `dench lists show` | Get one saved search / list by artifact id. |\n| `dench lists save` | Save find results as a named list (rows + filters become a workspace artifact). |\n| `dench lists update` | Update a saved list in place (title, filters, and/or replacement rows). |\n| `dench lists rename` | Rename a saved search / list. |\n| `dench lists delete` | Delete a saved search / list, its exported CSV/JSONL files, and any linked watch. |\n| `dench lists reviews` | Read durable enrichment activity (legacy review metadata remains readable). Use lists rows for current saved profiles and contacts. |\n| `dench lists assess` | Suggest ICP fit for one profile. Never changes a human review decision. |\n| `dench memory search` | Search durable workspace memory. |\n| `dench memory save` | Save a durable workspace memory fact. |\n| `dench approval request` | Request human approval. |\n| `dench approval approve\\|reject` | Record an approval decision. |\n| `dench billing status` | Get billing and AI credit status. |\n| `dench billing topup` | Create an AI credit top-up checkout link. |\n| `dench upgrade` | Create a workspace upgrade checkout link. |\n| `dench chat list` | List past chat threads. |\n| `dench chat search` | Search past chat messages. |\n| `dench chat read` | Read a past chat thread. |\n| `dench chat tree` | Read the parent-child chat thread hierarchy. |\n| `dench chat rename` | Rename one or more chat threads. |\n| `dench chat delete` | Delete one or more chat threads. |\n| `dench chat new` | Start a new chat-turn workflow. |\n| `dench chat send` | Send a message to an existing chat thread. |\n| `dench chat follow` | Follow a live chat response stream. |\n| `dench crm objects list [--with-references]` | List CRM objects. |\n| `dench crm objects list --compact` | List names, display labels, visibility and workspace counts without internal state. |\n| `dench crm objects get` | Get a CRM object. |\n| `dench crm objects create` | Create a CRM object. |\n| `dench crm objects update` | Update a CRM object. |\n| `dench crm objects rename` | Rename a CRM object. |\n| `dench crm objects delete` | Delete a CRM object. |\n| `dench crm objects archive` | Hide a CRM object's workspace sidebar row for the whole workspace. Not a delete — the table keeps working. Admin-only. |\n| `dench crm objects unarchive` | Restore a CRM object's workspace sidebar row. Admin-only. |\n| `dench crm views list` | List the saved views on a CRM object (plus the active view). |\n| `dench crm views get` | Get one saved view's definition by name. |\n| `dench crm views entries` | Materialize a saved view's rows (applies its filters/sort/pins), paginated. |\n| `dench crm views create` | Create a saved view (named filters/sort/columns combo) on a CRM object. |\n| `dench crm views update` | Replace a saved view's definition (upsert by name). |\n| `dench crm views rename` | Rename a saved view in place — keeps its filters, pins, and sidebar slot. |\n| `dench crm views delete` | Delete a saved view by name (idempotent). |\n| `dench crm views archive` | Move a pinned view's sidebar row into the Archived flyout. Admin-only. |\n| `dench crm views unarchive` | Restore a view's sidebar row (re-asserts its pin). Admin-only. |\n| `dench crm sidebar list` | Describe the workspace sidebar: Library rows in tree order (with their groups), the home-level Pinned strip, what is hidden and why, and whether the caller is an admin. |\n| `dench crm sidebar move` | Reposition one Library row (or group) among the Library's top-level slots. Does not add a home-level Pinned tab. Workspace-shared; admin-only. |\n| `dench crm sidebar group create` | Create a named sidebar group (e.g. \"Hiring\") in the workspace-shared Library. Open to any member. |\n| `dench crm sidebar group rename` | Rename a sidebar group. Open to any member. |\n| `dench crm sidebar group delete` | Dissolve a sidebar group; its rows return to the top level in its slot. Open to any member. |\n| `dench crm sidebar group add` | Move a sidebar row into a group (groupId set) or back to the top level (groupId null). Open to any member. |\n| `dench crm sidebar pin` | Pin (pinned true) or unpin a Library row — or a whole group — on the home-level Pinned shortcut strip (the \"tab on the left\"). Does not move the row inside Library. Workspace-shared; open to any member. |\n| `dench crm fields list` | List fields for a CRM object, including read-only calculation metadata. |\n| `dench crm fields list --compact` | List field names, types and effective constraints without indexing or enrichment internals. |\n| `dench crm fields create` | Create a CRM field or read-only campaign activity boolean column. |\n| `dench crm fields update` | Update a CRM field or change/explicitly clear an existing campaign calculation. |\n| `dench crm fields delete` | Delete a CRM field. |\n| `dench crm fields reorder` | Reorder CRM fields. |\n| `dench crm fields enum-reorder` | Reorder enum values. |\n| `dench crm fields enum-add` | Add an enum value. |\n| `dench crm fields enum-remove` | Remove an enum value. |\n| `dench crm fields enum-rename` | Rename an enum value. |\n| `dench crm fields enum-set-color` | Set an enum color. |\n| `dench crm entries list [--with-references]` | List CRM entries. |\n| `dench crm entries get` | Get a CRM entry. |\n| `dench crm entries sync-history` | Queue a full, paged pull of the record's email history from every connected mailbox; the ledger fills as pages land. |\n| `dench crm entries sync-history --status` | Has Dench read this record's email history? One row per address per mailbox. |\n| `dench crm entries dossier` | Status of the account's research dossier — the delimited `dench:dossier` section Dench keeps in the record's Notes: status, when it was written, how many dated updates followed, the last error. |\n| `dench crm entries dossier --regenerate` | Research the account again and append a fresh dossier section to its Notes (needs a Website / Domain on the record). |\n| `dench crm privacy status` | Whether the caller hides their own emails / messages with this record from the workspace (directly, or through its account), and whether they own a connection the toggle applies to. |\n| `dench crm privacy hide\\|show` | Hide (`hidden: true`) or show the caller's own emails / messages with this record to the workspace. An account covers every contact and opportunity linked to it; existing ledger rows are restamped and the shared Brief regenerates. |\n| `dench crm detections list` | List account-detection verdicts — why a domain (or personal address) did or did not become an account: verdict, counterparty type, probabilities, evidence threads, the rows created. `kind` picks the creator: `detections` (email + sweep), `linkedin` (the LinkedIn resolver's rows) or `all` (default). Newest first. |\n| `dench crm detections undo` | Undo what the ingestion jobs created since a timestamp (admin): `kind` = `detections` (accounts + contacts from the email detector and the sweep), `linkedin` (the LinkedIn resolver's contacts + accounts; their conversations are unlinked and parked), `email-tasks` (auto-created tasks and cases) or `all` (default). Deletes only rows no human has touched and marks the verdicts / decisions rolled_back so they are never re-created. `dryRun` lists what would go; per-kind counts in `kinds`. |\n| `dench crm history` | List a CRM entry's audit history. |\n| `dench crm activity` | List a CRM entry's activity ledger (comments, notes, field changes, emails, meetings, Slack, LinkedIn) in one timeline, newest first by default. |\n| `dench crm brief` | The record's generated Brief: health, who owes the next move, open threads, commitments, risks, next step. Read this before the ledger. |\n| `dench crm context` | Read-only source diagnostics: accessible evidence, association reasons, last Brief source manifest, generation queue, and your mailbox delivery health. Bounded, cursor-paged snapshot; does not certify complete history. |\n| `dench crm brief --regenerate` | Rebuild a record's Brief from the current timeline. |\n| `dench crm notes list` | List a CRM entry's notes (titled, document-style comments), newest first. |\n| `dench crm notes create` | Add a titled note to a CRM entry's activity timeline (markdown body). Research goes here, never into the Notes document. |\n| `dench crm comments list` | List comments on a CRM entry (roots newest first, with preview replies). |\n| `dench crm comments replies` | List every reply under a root comment, oldest first. |\n| `dench crm comments get` | Get one comment with its entry label. |\n| `dench crm comments create` | Comment on a CRM entry (markdown). Mention members with [@Name](/?member=<userId>); mention Dench with [@Dench](/?member=dench) or mentionDench. |\n| `dench crm comments update` | Edit a comment you wrote. |\n| `dench crm comments delete` | Delete a comment (kept as a tombstone when it has replies). |\n| `dench crm comments react` | Toggle an emoji reaction on a comment. |\n| `dench crm watch status` | Whether you follow a CRM entry's activity. |\n| `dench crm watch` | Follow or unfollow a CRM entry's activity. |\n| `dench crm tasks mine --page` | Page assigned tasks in priority order (or completed tasks by recency). |\n| `dench crm tasks list --page` | Page all tasks linked to a record, including subtasks. |\n| `dench crm tasks prepare` | Start or resume preparation of exact task ordering and progress. |\n| `dench crm tasks mine` | Your open tasks (plus ones completed today). |\n| `dench crm tasks list` | Tasks linked to a CRM entry. |\n| `dench crm tasks create` | Create a task linked to a CRM entry. |\n| `dench crm tasks complete` | Mark a task done. |\n| `dench crm tasks reopen` | Reopen a completed task. |\n| `dench crm tasks priority` | Set or clear a task's priority. |\n| `dench crm tasks subtasks` | A task's subtasks. |\n| `dench crm tasks create-subtask` | Create a subtask under a task (inherits the parent's record relations). |\n| `dench crm tasks parent` | Nest a task under a parent, or promote it (parentEntryId: null). |\n| `dench crm tasks delete` | Delete a task and its subtasks, or keep them as tasks. |\n| `dench crm tasks repeat` | How a task repeats (rule, RRULE, trigger, ends, next due). |\n| `dench crm tasks repeat --off` | Stop a task repeating (past occurrences are kept). |\n| `dench crm tasks repeat --skip` | Skip the current occurrence: the next one is created now. |\n| `dench crm tasks repeat --pause` | Pause a repeating task. |\n| `dench crm tasks repeat --resume` | Resume a paused repeating task. |\n| `dench crm tasks series` | Every repeating-task series in the workspace. |\n| `dench crm tasks series <seriesId> --occurrences` | Every occurrence (task) of one series. |\n| `dench crm entries create` | Create a CRM entry. |\n| `dench crm entries create-many` | Create many CRM entries. |\n| `dench crm entries update` | Update a CRM entry. |\n| `dench crm entries update-many` | Update many CRM entries. |\n| `dench crm entries delete` | Delete a CRM entry. |\n| `dench crm entries bulk-delete` | Bulk delete CRM entries. |\n| `dench crm cells get` | Get a CRM cell value. |\n| `dench crm cells set` | Set a CRM cell value. |\n| `dench crm cells set-many` | Set many CRM cell values. |\n| `dench crm cells append` | Append to a CRM cell. |\n| `dench crm query [--with-references]` | Query CRM entries. |\n| `dench crm query --page` | Scan CRM entries with a resumable cursor. Empty filtered pages can have more results. |\n| `dench crm sql` | Run CRM SQL-compatible query. |\n| `dench crm aggregate` | Aggregate CRM entries. |\n| `dench crm search [--with-references]` | Search CRM entries. |\n| `dench crm search --page` | Search bounded pages of readable CRM entries, optionally projecting cells. Always follow continueCursor until isDone. |\n| `dench crm statuses list` | List CRM statuses. |\n| `dench crm statuses set` | Set CRM statuses. |\n| `dench crm batch` | Apply a CRM batch. |\n| `dench crm transaction begin` | Begin a CRM transaction. |\n| `dench crm transaction add` | Add an operation to a CRM transaction. |\n| `dench crm transaction commit` | Commit a CRM transaction. |\n| `dench crm transaction abort` | Abort a CRM transaction. |\n| `dench crm transaction inspect` | Inspect a CRM transaction. |\n| `dench crm docs list` | List CRM documents. |\n| `dench crm docs create` | Create a CRM document. |\n| `dench crm docs link` | Link a CRM document. |\n| `dench crm actions list` | List CRM actions. |\n| `dench crm actions create` | Create or upsert an action button on a named action column (fieldName is the column header; a column can hold multiple buttons — reuse fieldName to add more). |\n| `dench crm actions edit` | Update an action button on a CRM field. |\n| `dench crm actions delete` | Delete an action button from a CRM field. |\n| `dench crm actions run` | Run a CRM action on one or more entries. |\n| `dench members list` | List workspace members for CRM user fields. |\n| `dench members presence` | Live presence (online / away / offline) for workspace members. |\n| `dench members get` | A member's profile: name, email, tagline, role, timezone, presence, open task count. |\n| `dench members activity` | A member's recent comments and record changes across the CRM, newest first. |\n| `dench members tasks` | Open tasks assigned to a member (plus ones completed today). |\n| `dench members me` | Your own member profile. |\n| `dench members me --name … --tagline … --timezone …` | Update your name, tagline, avatar URL, or timezone. |\n| `dench members me --avatar <file>` | Get a one-time URL to POST an avatar image to; then PUT /me/avatar with the returned storageId. |\n| `dench members me --clear-avatar` | Remove your avatar. |\n| `dench crm reports generate` | Generate a CRM report. |\n| `dench crm analytics get` | Read an object's analytics dashboard: panels, field roles, the strip's collapsed flag, the named view's own dashboard (if any), and the fields panels may bucket on (synthetic $createdAt / $location last). |\n| `dench crm analytics compute` | Compute chart-ready results (buckets / series / values) for the stored dashboard, a subset of its panels, or ad-hoc panel definitions — optionally scoped to a saved view, a period preset (with the previous interval as previousValue) and extra filters. Same query the strip renders from. |\n| `dench crm analytics save` | Create or update one panel (upsert by id). With viewName the write lands on that saved view's own dashboard, forking a copy if it was still inheriting the object's. |\n| `dench crm analytics update` | Edit part of one stored panel: only the keys in `patch` change (title, type, metric, metricField, groupBy, dateField, dateBucket, filters, derived, span, hidden, sortOrder); null clears an optional key. What the card's ⋮ menu writes. |\n| `dench crm analytics hide` | Take a chart off the strip above the table (hidden: true). It stays in the full analytics view, counted by the strip's “+N more”. |\n| `dench crm analytics show` | Bring a hidden chart back onto the strip (hidden: false). |\n| `dench crm analytics resize` | Set a card's width on the 6-track dashboard grid: span 2 (third), 3 (half), 4 (two thirds), 6 (full), or null for the chart kind's default. |\n| `dench crm analytics delete` | Delete one panel (idempotent). Template panels are tombstoned so a re-install never resurrects them. |\n| `dench crm analytics reorder` | Persist the full panel order. panelIds must name every stored panel of the targeted dashboard. |\n| `dench crm analytics roles` | Set the object's analytics setup — the field roles shared by every chart and view (amount, stage, won/lost/converted values, stageProbabilities, closeDate, recurrence, owner, location). Replaces the mapping; with merge: true only the keys given change and null clears one. |\n| `dench crm analytics collapse` | Collapse the analytics strip above the object's table (team-shared, like saved views). |\n| `dench crm analytics expand` | Expand the analytics strip above the object's table. |\n| `dench crm analytics scope` | Give a saved view its own dashboard (mode \"own\": starts as a copy of the object's panels) or hand it back to the object's shared one (mode \"shared\"). |\n| `dench crm enrich cell` | Request enrichment for one CRM cell. |\n| `dench crm enrich object` | Request enrichment for a CRM object. |\n| `dench crm people search` | Search for people through the enrichment gateway. `companyDomains` takes up to 1000 domains (e.g. a resolved company list; `dench leads find --company-list <id\\|view>` resolves one for you) — the gateway fans large lists out as sequential vendor-safe chunks behind one `nextPageToken` stream. |\n| `dench crm companies search` | Search for companies through the enrichment gateway (also `dench companies find`). |\n| `dench jobs find` | Search job postings through Dench find. `companyDomains` takes up to 1000 domains (chunked automatically); `dench jobs find --company-list <id\\|view>` resolves a saved company list into it. |\n| `dench crm enrich profiles` | Look up up to 100 people or company profiles without buying emails or phones. Pass kind (people\\|companies) and lookups; results preserve inputIndex. People require linkedinUrl or email; companies require domain or linkedinUrl. |\n| `dench companies related` | Read company employees, founders, funding, investors, acquisitions, or investments. Pass domain or linkedinUrl, kind, limit (1–100), and optional pageToken. Does not import CRM records or buy contacts. |\n| `dench leads find --limit 1` | Preview how many records a find would return. |\n| `dench leads filters` | List Lead Finder filter vocabularies: exact enum values (seniorities, functions, industries, headcount, company types, languages) and curated suggestions (titles, locations, company HQ, universities, skills, keywords). |\n| `dench crm templates list` | List one-click CRM templates (objects + automations + sample rows) with per-workspace installed flags. |\n| `dench crm templates install` | Install a CRM template. Idempotent: re-installs top up missing pieces and never duplicate objects, automations, or sample rows. |\n| `dench crm templates remove-sample-data` | Delete a CRM template's sample rows (tagged \"Sample\"); schema, views, and automations stay. |\n| `dench crm automations list` | List deterministic CRM automations (rules that fire inside entry writes, e.g. qualified prospect → opportunity). |\n| `dench crm automations enable\\|disable` | Enable or disable a CRM automation. |\n| `dench crm import` | Import a local CSV into a CRM object. |\n| `dench crm export` | Export a CRM object to a local CSV. |\n| `dench meetings list` | List meetings, newest first, with status and participants. |\n| `dench meetings transcript get` | Read a meeting's transcript, in order, one page at a time. |\n| `dench meetings transcript set` | Append up to 500 transcript segments to a meeting (speakers with an email link to existing people). |\n| `dench meetings transcript clear` | Delete a batch of a meeting's transcript segments; repeat until `done` before re-appending. |\n| `dench meetings action-items list` | List a meeting's action items. |\n| `dench meetings action-items set` | Add action items to a meeting; `replace: true` swaps the whole list. |\n| `dench meetings action-items done` | Tick or untick one action item. |\n| `dench meetings action-items delete` | Delete one action item. |\n| `dench meetings participants list` | Who was in the meeting, merged with the linked calendar invite. |\n| `dench meetings participants set` | Record attendees by name/email; known members and existing people are linked, nobody is created. |\n| `dench meetings share` | Whether a meeting is shared with the whole workspace, and whether you may change that. |\n| `dench meetings share --workspace` | Share one meeting with the workspace, or take it back to owner + invitees. |\n| `dench meetings import` | Import calls from a local CSV/JSONL: meeting fields plus transcript, action items and attendees per row. |\n| `dench email identity verify` | Start Dench Emailing Service sender verification. |\n| `dench email identity status --identity-id` | Refresh a Dench Emailing Service sender verification status. |\n| `dench email identity status` | Read Dench Emailing Service sender verification status. |\n| `dench email identity list` | List the workspace's email sending identities. |\n| `dench email identity dns` | Fetch DNS records (DKIM/SPF/DMARC) for a pending domain sender verification. |\n| `dench email identity disable` | Soft-disable a sender (or every sender on a domain) for the workspace; sends are blocked until restored. |\n| `dench email identity restore` | Restore a previously disabled sender for the workspace. |\n| `dench email identity delete` | Permanently delete a sender (or every sender on a domain) from the workspace; re-adding it requires verification from scratch. |\n| `dench email inbox search` | Search authorized synced mailbox headers with bounded cursor pagination. isDone covers stored records, not provider completeness. |\n| `dench email inbox thread` | Read a bounded page of synced headers using an exact thread handle from inbox search; bodies remain on demand. |\n| `dench email inbox message` | Read a bounded stored body using an exact message handle from inbox search; rechecks mailbox and record privacy. |\n| `dench email draft create` | Create an editable Dench email draft and synchronize its selected native mailbox asynchronously. Use a stable requestId for retries. |\n| `dench email draft show` | Read an email draft, eligible senders and provider sync status. |\n| `dench email draft senders` | List native mailboxes this caller may use. |\n| `dench email draft update` | Save draft content using expectedRevision; sender changes require a new draft after provider binding. |\n| `dench email draft send` | Send the current Dench draft revision through its native mailbox. Repeated requests share a durable receipt. |\n| `dench email draft attach` | Upload attachment bytes authorized against this draft before adding its storage reference. |\n| `dench email draft signature` | Load the selected mailbox signature for explicit visible insertion. |\n| `dench email send [--mailbox <id/email>]` | Send through a native Gmail or Outlook mailbox with a durable request receipt. Only use for an explicit send request. |\n| `dench email send --from <verified-email>` | Send one raw email (no campaign): to/cc/bcc, custom from-name and reply-to, optional reply threading via replyToMessageId. |\n| `dench email message status` | Read a raw email message's status and open/click counters. |\n| `dench email message list` | List recent raw email messages for the workspace. |\n| `dench email template create` | Create a managed email campaign template. |\n| `dench email template preview` | Preview a managed email campaign template. |\n| `dench email campaign create` | Create a managed email campaign draft from a connected inbox or verified sender. |\n| `dench email campaign status` | Read campaign status and counters. |\n| `dench email campaign recipients add` | Add recipients to a managed email campaign. |\n| `dench email campaign preview` | Preview rendered messages for a campaign sample. |\n| `dench email campaign submit` | Submit a campaign for approval or sending. |\n| `dench email campaign pause` | Pause a sending email campaign. |\n| `dench email campaign resume` | Resume a paused email campaign. |\n| `dench email campaign cancel` | Cancel an email campaign. |\n| `dench email campaign list` | List managed email campaigns (paginated, optional status filter). |\n| `dench email campaign recipients list` | List a campaign's recipients (paginated, optional status filter). |\n| `dench email campaign recipients add-from-object` | Add campaign recipients from a CRM object: pick the object, the email field, and the entry ids. |\n| `dench email sequence create` | Create a follow-up sequence from a connected inbox or verified sender. |\n| `dench email sequence update` | Update a sequence's name, sender, or reply/stop settings. |\n| `dench email sequence activate` | Activate a sequence so its enrollments begin sending. |\n| `dench email sequence deactivate` | Deactivate a sequence (pause sending, revert to draft). |\n| `dench email sequence archive` | Archive a sequence (stops all sending). |\n| `dench email sequence list` | List the workspace's follow-up sequences. |\n| `dench email sequence status` | Read a sequence with its ordered steps. |\n| `dench email sequence steps add` | Add a step (subject, body, and wait delay) to a sequence. |\n| `dench email sequence steps update` | Update a sequence step's subject, body, or delay. |\n| `dench email sequence steps remove` | Remove a step from a sequence. |\n| `dench email sequence steps reorder` | Reorder a sequence's steps. |\n| `dench email sequence enroll` | Enroll explicit recipients into a sequence. |\n| `dench email sequence enroll-from-object` | Enroll people from a CRM object: pick the object, the email field, and the entry ids. |\n| `dench email sequence enrollments list` | List a sequence's enrollments (paginated, optional status filter). |\n| `dench email sequence enrollment pause` | Pause one enrollment. |\n| `dench email sequence enrollment resume` | Resume one paused enrollment. |\n| `dench email sequence enrollment stop` | Stop one enrollment (no further steps send). |\n| `dench campaign accounts` | Discover LinkedIn sender ids, labels, availability and remaining capacity visible to the acting workspace member. Never returns provider credentials. |\n| `dench campaign list [--with-references]` | List outreach campaigns (archived ones on request). |\n| `dench campaign create` | Create a draft outreach campaign with email and LinkedIn sender pools and a business-hours send window in the given timezone. |\n| `dench campaign duplicate` | Copy a campaign into a new draft named \"<name> copy\": the same steps, schedule, sender pools and personalized lines, its lead source paused, and no people. To reach more than 300 people, duplicate and add the next page of the search to the copy. |\n| `dench campaign get` | Read a campaign: settings, steps, people, their current step and hold, last touches, linked leads. |\n| `dench campaign pipeline` | Where a campaign's people sit in the workspace's lead pipeline right now: each lead Status in order with how many enrolled leads are at it, and how many have no lead or a status outside the pipeline. |\n| `dench campaign set` | Change a campaign's name, sender pools, send windows, daily email cap, stop-on-reply, start or end. Works until archived; existing conversations keep their assigned sender. |\n| `dench campaign steps set` | Replace every step of a draft campaign (email, wait, LinkedIn visit, connection request, message, post reaction, InMail, If / else, Wait for them to accept). A workflow (stepModel workflow, or steps with key, next, yesNext or noNext) branches: condition and wait_for_connection steps continue on yesNext or noNext, other steps on next; each points at another step's key or end. Steps are checked first: a field the step type would drop, missing text, {TOKEN} single braces or paths that don't hold together are rejected, not saved. Configure sender pools on the campaign; step sender ids are legacy-only. |\n| `dench campaign steps edit` | Edit the text, waits and conditions of a launched (or paused) campaign's steps in place. Each step keeps its id, type and place; pass the stepId and the updatedAt you read, and only the fields you change. A workflow keeps its paths and what each If / else checks (key, next, yesNext, noNext, check, conditionField, conditionOperator); conditionValue and acceptance waits stay editable. Messages already sent or being prepared keep their text; drafts use campaigns.steps.replace. |\n| `dench campaign personalize get` | Read a campaign's personalized lines (written for each person): their {{keys}} for steps, instructions and fallbacks, how many people have them, and the cost per person. |\n| `dench campaign personalize set` | Define up to 5 personalized lines (each used as {{key}} in steps) and what you sell. Saving starts writing missing lines for up to 100 people, about 3 cents a person; for more it returns needsConfirm and writes nothing until campaigns.personalization.write is confirmed. |\n| `dench campaign personalize clear` | Turn off a campaign's personalized lines and cancel the ones not yet written. Refused while a step still uses one of the {{keys}}. |\n| `dench campaign personalize write` | Write personalized lines for the people missing them (mode missing) or rewrite everyone's (mode all). Rewriting everyone or more than 100 people returns needsConfirm and the estimate until called with confirmed: true. |\n| `dench campaign personalize edit` | Set one person's personalized line by hand; an empty value undoes the edit. Braces are removed and text past the line's length is cut. |\n| `dench campaign personalize rewrite` | Write a fresh personalized line for one person: one key, or all of their lines when key is left out. About 3 cents. |\n| `dench campaign add` | Add CRM records (up to 100 ids per call) to a campaign; returns how many were added and why others were skipped. |\n| `dench campaign add --name` | Add one person by email and/or LinkedIn profile URL. |\n| `dench campaign preview` | Show the message one person gets at one email or LinkedIn step, with their fields and personalized lines filled in: subject, body, sender, recipient, merge fields still missing, warnings, and why the step would be skipped. Nothing is sent, prepared or charged. |\n| `dench campaign launch --check` | Launch readiness without launching: blockers grouped by problem, warnings, and the fingerprint `launch` requires. |\n| `dench campaign launch` | Launch a ready draft. Pass the fingerprint from the preview and acknowledge the LinkedIn notice when LinkedIn steps exist. |\n| `dench campaign pause` | Pause an active campaign. |\n| `dench campaign resume` | Resume a paused campaign. |\n| `dench campaign archive` | Archive a campaign and stop everyone still in flight. This is the app's Delete: campaigns are never erased, and their people, leads and activity stay. |\n| `dench campaign events` | The campaign's activity log, newest first (sent, accepted, replied, skipped, failed, paused, stopped). |\n| `dench campaign stop` | Stop one person: nothing more is sent to them from this campaign. |\n| `dench campaign resume-person` | Resume one paused person in an active campaign. |\n| `dench campaign person set --email` | Give a person in a draft campaign a new or corrected email address; their linked CRM record gets it too. Only before launch; another person in the campaign can't share it. |\n| `dench campaign person set --linkedin-url` | Give a person in a draft campaign a new or corrected LinkedIn profile URL; their linked CRM record gets it too. Only before launch. |\n| `dench campaign person set --field` | Fill or fix one {{merge field}} for a person in a draft campaign, e.g. a missing Company that blocks launch; a matching column on their CRM record is updated too. Only before launch; written personalized lines are not merge fields and can't be set here. |\n| `dench campaign resume-person --all` | Resume every paused person in an active campaign at once, e.g. after a sending account is reconnected. Returns how many were resumed. |\n| `dench campaign sync` | Fill each unfinished person's empty email, LinkedIn URL, name and merge fields from their linked CRM record, e.g. after enriching the records. Never overwrites a value the campaign already has; returns how many people changed. |\n| `dench campaign where` | The campaigns a CRM record (a person or a lead) is in, newest first, with the person's status in each and the accounts that send to them. |\n| `dench campaign person show` | Everything a campaign did for one person, step by step: what was sent (subject and text), whether it was opened or clicked, what was skipped and why, waits, failures and retries. |\n| `dench campaign remove` | Remove a person who was never contacted from a draft campaign. Frees their place in the 300-person cap and keeps the draft launchable; stop anyone already contacted instead. |\n| `dench cron list` | List routines. |\n| `dench cron history` | List routine run history. |\n| `dench cron get` | Get a routine. |\n| `dench cron create` | Create a routine. |\n| `dench cron update` | Update a routine. |\n| `dench cron delete` | Delete a routine. |\n| `dench cron enable` | Enable a routine. |\n| `dench cron disable` | Disable a routine. |\n| `dench cron run` | Run a routine now. |\n| `dench cron runs` | List runs for a routine. |\n| `dench files ls [<path>] [--recursive\\|-r] [--json]` | List workspace files; the default path is /. |\n| `dench files cat <path> [--json]` | Read a workspace file's inline text. |\n| `dench files write <path> [--json]` | Write a workspace file's text from stdin. |\n| `dench files download <path> [<local-dest>] [--url] [--json]` | Download workspace bytes to local disk, or print a signed URL. |\n| `dench files rm <path> [--recursive\\|-r] [--json]` | Remove a workspace file or directory. |\n| `dench files mv <src> <dst> [--json]` | Move or rename a workspace file or directory. |\n| `dench stage` | Stage uploaded content into the workspace. |\n| `dench fs` | Run the local file sync daemon. |\n| `dench search` | Search the web through the Dench gateway. |\n| `dench search contents` | Fetch page contents through the Dench gateway. |\n| `dench search answer` | Answer a question with web search. |\n| `dench web scrape` | Read a page as clean Markdown through Dench web. |\n| `dench web brand` | Look up a brand kit from a domain or email. |\n| `dench web sitemap` | List sitemap URLs for a domain. |\n| `dench web crawl` | Crawl a site to Markdown (capped). |\n| `dench web screenshot` | Capture a rendered page screenshot. |\n| `dench web extract` | Extract typed fields from a page using a JSON Schema. |\n| `dench web product` | Extract a product listing from a URL. |\n| `dench web competitors` | Find competitors of a domain. |\n| `dench web styleguide` | Read a brand styleguide from a domain. |\n| `dench web fonts` | Read site fonts from a domain. |\n| `dench web classify` | Classify a domain with NAICS or SIC. |\n| `dench web brand-search` | Autocomplete brand names. |\n| `dench image generate` | Generate an image through the Dench gateway. |\n| `dench image edit` | Edit an image through the Dench gateway. |\n| `dench integrations` | List every connected integration — connected apps plus the Gmail, Outlook, Calendar, LinkedIn and Slack connections Dench provides itself (Slack rows report source: dench). |\n| `dench apps list` | List installed App Store apps in the workspace. |\n| `dench apps gallery` | List Discover listings — Official (Dench) + Community shelves. |\n| `dench apps create` | Scaffold and register a new App Store app. |\n| `dench apps install` | Install an App Store listing into the workspace. |\n| `dench apps publish` | Publish an app's files as a versioned App Store listing. |\n| `dench apps uninstall` | Uninstall an app from the workspace. |\n| `dench apps enable` | Enable or disable an installed app. |\n| `dench apps pin` | Pin or unpin an installed app in the rail. |\n| `dench apps validate` | Validate a .dench.app folder: manifest, permissions, and every window.dench call it makes. |\n| `dench apps webhooks register` | Register an inbound webhook for an app. Returns the URL and signing secret ONCE. |\n| `dench apps webhooks list` | List an app's registered webhooks (URLs, never secrets). |\n| `dench apps webhooks poll` | Read events an app webhook received since a timestamp. |\n| `dench apps webhooks delete` | Remove an app webhook and every event it stored. |\n| `dench tool status` | List connected tool accounts. |\n| `dench tool connect` | Create a tool OAuth connection link. Slack is in-house, never a third-party connection: for toolkit slack the CLI prints the first-party install URL (/api/slack/install?slug=<workspace>, org admin) instead of calling this endpoint. |\n| `dench tool search` | Search for external tool actions. |\n| `dench tool run` | Run an external tool action. SLACK_* slugs (SLACK_SEND_MESSAGE with Block Kit blocks/buttons, SLACK_FETCH_HISTORY, SLACK_LIST_CHANNELS, …) run through Dench's in-house Slack app install — any channel in the connected workspace — and are always preferred over any third-party Slack connection. |\n| `dench tool disconnect` | Disconnect an external tool account. |\n| `dench tool labels` | List human names given to connected accounts. |\n| `dench tool label` | Name a connected account, or clear its name with an empty string. |\n| `dench browser` | Drive Dench Browser with a single interactive action (open, inspect, click, fill, type, screenshot, stop). Pass the step in `action` plus its arguments. |\n| `dench browser session create` | Create a Dench Browser session and return a CDP connect URL for Playwright (chromium.connectOverCDP) plus a live-view URL. Use for durable scripts run from the sandbox. |\n| `dench browser session status` | Get the status, connect URL, and live-view URL for a Dench Browser session. |\n| `dench browser session stop` | Stop a Dench Browser session and release the remote browser. |\n| `dench context --sections identity` | Read IDENTITY.md. |\n| `dench context set identity` | Update IDENTITY.md. |\n| `dench context --sections organisation` | Read ORGANISATION.md. |\n| `dench context set organisation` | Update ORGANISATION.md. |\n| `dench context --sections user` | Read USER.md. |\n| `dench context set user` | Update USER.md. |\n| `dench context --sections tools` | Read tool notes. |\n| `dench context set tools` | Update tool notes. |\n| `dench context set rules` | Update standing workspace rules; credentials belong in secrets and runnable setup in environments. |\n| `dench model default` | Set the default chat model. |\n| `dench model thread` | Set a thread model override. |\n| `dench notifications list` | List your notifications (inbox, unread, archived, or all). |\n| `dench notifications count` | How many unread notifications you have. |\n| `dench notifications read` | Mark a notification read (or unread). |\n| `dench notifications read-all` | Mark every inbox notification read. |\n| `dench notifications archive` | Archive a notification. |\n| `dench notifications prefs` | Read your notification preferences. |\n| `dench notifications prefs --set` | Update your notification preferences. |\n| `dench settings sync` | Read the workspace's Sync switches (accounts from email, contacts from LinkedIn, Slack Connect, calendar, dossier, tasks from email, lead auto-qualify, summaries and Brief). All on by default. |\n| `dench settings sync set` | Flip Sync switches (admin). Partial patch: only the keys sent change. Off stops new work; nothing already created is removed. |\n\n## Compatibility\n\nExisting identity/organisation/user/tools aliases still address the same stored documents. Prefer `dench context --sections …` and `dench context set …`. Aggregate `dench mem` and bootstrap endpoints remain compatibility readers/writers while existing clients migrate; they are not the recommended memory API. Existing history is retained. No `dench agent spawn/await/message/wait-message/pause/resume/continue/tree` commands exist; use the harness subagent tools or supported `dench chat` commands.\n"
|
|
36
36
|
},
|
|
37
37
|
"references/CMO.md": {
|
|
38
38
|
"sha256": "2dbbdb126ae4c02bed59aa961e1392b2200b16ee9c135372fe33af87b79739a4",
|