Pushary REST API reference
The OpenAPI 3.1 specification for the Pushary REST API, plus the base URL, auth scheme, and error shape every endpoint shares
The Pushary REST API is published as an OpenAPI 3.1 document. Point a client generator, an agent framework, or your own tooling at it directly.
| What | Where |
|---|---|
| OpenAPI specification | https://pushary.com/openapi.json |
| Same document, YAML media type | https://pushary.com/openapi.yaml |
| Base URL | https://pushary.com/api/v1/server |
| MCP server | https://pushary.com/api/mcp/mcp (Streamable HTTP) |
| MCP manifest | https://pushary.com/.well-known/mcp |
| Site index for agents | https://pushary.com/llms.txt |
curl -s https://pushary.com/openapi.json | jq '.info.title, (.paths | keys | length)'Authentication
Every endpoint takes a Pushary API key as a bearer token:
curl https://pushary.com/api/v1/server/identity \
-H "Authorization: Bearer pk_xxx.sk_xxx"Create a key with npx @pushary/agent-hooks setup, or in Dashboard → Agent → Settings.
See API keys for scopes and rotation.
The MCP endpoint additionally accepts OAuth 2.0. Discovery starts at
/.well-known/oauth-protected-resource,
which names the authorization server.
Errors
Every error is JSON in one shape. error is the human sentence and is stable across releases;
code is what to branch on.
{
"error": "Unauthorized",
"code": "unauthorized",
"status": 401,
"message": "Invalid or missing API key. Use Authorization: Bearer pk_xxx.sk_xxx",
"hint": "Create a key with `npx @pushary/agent-hooks setup`, or in Dashboard > Agent > Settings.",
"documentation": "https://pushary.com/docs/agents/api-key"
}A request to a path with no endpoint behind it returns the same shape with code: "not_found"
and an openapi field pointing back at the specification.
The code values are unauthorized, forbidden, invalid_request, not_found,
method_not_allowed and rate_limited.
Function calling
Every operation carries a unique operationId, typed parameters and a response schema, so the
document converts directly into tool definitions for OpenAI, Anthropic and any OpenAPI-aware
agent framework.
const spec = await fetch('https://pushary.com/openapi.json').then((r) => r.json())
const tools = Object.entries(spec.paths).flatMap(([path, item]) =>
Object.entries(item)
.filter(([method]) => ['get', 'post', 'patch', 'delete'].includes(method))
.map(([method, op]: [string, any]) => ({
name: op.operationId,
description: op.description,
path,
method,
})),
)SDKs
Prefer a typed client where one exists. Both wrap the endpoints below and handle retries, idempotency and long-polling for you.
- TypeScript:
npm install @pushary/server - Python:
pip install pushary - CLI:
npx @pushary/agent-hooks setup
See Framework adapters for the Vercel AI SDK, LangGraph, CrewAI, Mastra, Eve and the OpenAI Agents SDK.
What the API covers
| Group | Operations |
|---|---|
| Decisions | Open a decision that blocks on a human, read it, record an answer, cancel it, and manage the webhook secret |
| Authorization | Evaluate an action against the workspace policy: allow, deny, or requires_human |
| Enrollment | Connect one of your own end-users to phone approvals with a single-use link |
| Keys | Issue and revoke per-end-user API keys for multi-tenant agent runtimes |
| Notifications | Send a push notification, read one back |
| Subscribers | List, read, update, delete and count the people a site can notify |
| Campaigns | Create, schedule, send, pause, resume and read stats |
| Templates | Reusable notification content |
| Flows | Event-triggered notification automations |
| Account | Identify the calling key, read the site, count reachable channels, list agent machines |
Markdown for agents
Any documentation or blog URL serves raw Markdown two ways: append .md, or send an
Accept: text/markdown header.
curl -H "Accept: text/markdown" https://pushary.com/docs/agents/reference/api
curl https://pushary.com/docs/agents/reference/api.md