[Docs](/docs) /Agent skill

# Agent skill

Drive Crumbless from your coding agent. Prefer MCP tools when connected; otherwise use the crumbless CLI. Same OAuth identity — no static API tokens.

**Prefer MCP.** When the Crumbless MCP server is connected, call tools like list\_brands and approve\_posts. Fall back to the CLI only when MCP is unavailable.

## Choose interface

| Situation | Action |
| --- | --- |
| Crumbless MCP is connected | Call MCP tools (list\_brands, list\_posts, …) |
| MCP not available | Shell: crumbless … after crumbless login |
| Vague / multi-step ask | MCP chat or crumbless ai <slug> --message "…" --pipe |

Never invent REST endpoints or API keys.

## Install the skill

The agent instructions live in cli/skills/crumbless/ in this repository. Copy that directory into the skill location supported by your coding agent, then configure MCP or the CLI separately.

```
cli/skills/crumbless/
```

You can also copy `cli/skills/crumbless/` into `.cursor/skills/crumbless/` or `~/.claude/skills/crumbless/`.

## Auth (always OAuth)

-   **Local MCP / CLI:** shared session at `~/.config/crumbless/session.json`. MCP tool `login` opens the browser, or run `crumbless login`.
-   **HTTP MCP:** use only an endpoint supplied by your operator and its OAuth login flow. A hosted Crumbless MCP URL is not established here. REST API keys do not authenticate MCP.
-   Verify with `whoami` / `list_brands` or `crumbless brands`.

## Operating rules

1.  Start with list\_brands (or crumbless brands) to learn slugs.
2.  Pass slug on every brand-scoped call.
3.  Post/article ids accept short unambiguous prefixes from list output — never guess if ambiguous.
4.  Prefer specific tools (approve\_posts, edit\_post, …) over chat for precise edits.
5.  Confirm before reject / delete / discard unless the user clearly asked.

## Quick workflows

-   **Approve pending posts** — list\_posts (status pending\_user) → optional get\_post → approve\_posts
-   **Fix one carousel slide** — get\_post → regenerate\_slide (index, instruction; 0 = cover)
-   **Blog draft** — generate\_article → optional optimize\_article → publish\_article when asked

## Examples

-   Show my brands and confirm which one we are working on.
-   List pending posts for this brand and show the content before asking me to approve.
-   Summarize the available post metrics and explain what the data cannot establish.
-   Revise this draft to match the approved brand voice without changing the facts.

## Supported agents

-   **Claude Code** — local skill instructions and MCP or CLI access
-   **Cursor** — MCP + terminal skill
-   **GitHub Copilot** — via CLI commands
-   **Windsurf** — via terminal integration
-   **Cline** — via CLI commands
-   **Aider** — via pipe mode

## CLI fallback

If MCP is not connected, install the CLI and work from the shell:

These local examples require a configured app checkout, app and CLI dependencies, and Bun. Start the app with npm run dev from the repository root and wait for its ready message. Use its actual origin: http://localhost:5173 below is only an example, not an assumed running service. Run CLI commands from cli/. Set PUBLIC\_APP\_URL before login and every command, and set the same value in each separately launched MCP process's env configuration. Without this pin, local detection can fall back to production. The MCP listener on port 8787 is not the app origin. No hosted installer or published package is assumed.

```
export PUBLIC_APP_URL="http://localhost:5173"
bun run cli.ts login
bun run cli.ts brands
bun run cli.ts content <slug> --status pending_user
bun run cli.ts approve <slug> --all
```

For machine-readable output:

```
export PUBLIC_APP_URL="http://localhost:5173"
crumbless ai <slug> --message "Summarize the available post metrics and explain what the data cannot establish." --pipe
```

* * *

## Next

-   [MCP](/docs/mcp) — connect stdio or remote HTTP and authenticate
-   [CLI](/docs/cli) — full terminal reference
-   [anomalia](https://github.com/anomaliaso/anomalia) — historical upstream project, not a Crumbless installation source

---
Source: https://crumbless.app/docs/agents
