Skip to content

Docs

Unspar for agents, terminals and pipelines

Let Claude Code, Codex, Cursor or any MCP host research, write and publish articles in your Unspar projects. Script the same work from a terminal, or call the REST API from your own code. Three ways in, one set of team permissions.

Three ways in

Pick the channel that fits the tool you already use. All three run against the same projects, templates, voices and outlets, and all three respect the permissions your team already has.

Included in every plan. Every plan, including free, can use the API, the CLI and MCP. There is nothing extra to buy. Work started by an agent spends the same credits as work started in the app, and the estimate is visible the same way.

Quick starts

Each of these takes about a minute. They all end with an agent or a script that can list your projects, create an article from a brief, wait for the draft and publish it on your say-so.

Claude Code, through the hosted MCP server

claude mcp add --transport http unspar https://app.unspar.com/mcp

Then run /mcp inside Claude Code and choose Authenticate for Unspar. A browser page opens where you pick the team, the projects and what the agent may do. Codex CLI: codex mcp add unspar --url https://app.unspar.com/mcp. Other hosts and the full tool list.

The terminal, through the unspar CLI

curl -fsSL https://app.unspar.com/install.sh | sh
unspar login
unspar projects list
unspar articles create --project prj_xxx --brief "How small bakeries pick a domain name" --wait
unspar articles content art_xxx
unspar articles publish art_xxx --outlet out_xxx

Windows PowerShell installs with irm https://app.unspar.com/install.ps1 | iex. Every command supports --json. Login options, the local MCP server and the skill file.

Your own code, through the REST API

curl https://app.unspar.com/api/v1/projects \
  -H "Authorization: Bearer $UNSPAR_API_KEY"

Create a key under Team settings, API keys and send it as a bearer token. Responses use a { "data": ... } envelope and public ids only. Authentication, idempotency and the operation list.

How access works

Every channel is backed by the same authority model, so a team owner always knows who can do what.

  • Team API keys. Created under Team settings, API keys. Full-access keys can read, generate and publish; read-only and custom keys narrow that down, optionally to selected projects. The CLI login creates one of these for the machine you log in from.
  • MCP connections. Each hosted MCP connection gets its own credentials after you approve it in the browser. You choose the team, the projects and the permission groups (read, generate, publish) per connection, and you can review or revoke connections at any time under Team settings, MCP connections.
  • Review stays with you. Generation spends credits and publishing sends content to a destination outside Unspar, so both are explicit steps. Nothing is published unless the connection was granted publishing and the agent or script asks for it.

What an agent can do

The same operations are available through MCP tools, CLI commands and API endpoints:

  • Show the connected team and its permissions (whoami).
  • List and inspect projects, templates, voice profiles and outlets.
  • Create an article from a brief, optionally with a title, language, template or outlet, and start generation.
  • Read generation status, the finished markdown and the research sources behind it.
  • Cancel a run that is still generating, or retry one that failed.
  • Schedule publication to a connected outlet.
  • Check the credit balance and recent credit transactions.

Machine-readable docs

If your agent reads contracts on its own, point it here:

Give your agent a real content workspace

Create a project, connect a tool, and let the first draft come back for your review. The cost is visible before a single credit is spent.