Docswrite developer portal

The publishing API for AI agents

One REST API and one MCP server publish to every blog, CMS and social network your workspace has connected. Agents sign in with OAuth 2.1; servers use an org API key.

Docswrite keeps the credentials for WordPress, Webflow, Shopify, Ghost, Contentful, Medium, Dev.to, Hashnode, GitHub, X and LinkedIn. Your agent names the connections and sends the post (Markdown, HTML or a Google Doc); Docswrite converts it for the destination with formatting, images and SEO fields intact, and tells you when it is live.

5 free exports. No credit card required.

Quickstart

Publish your first post in three calls

Base URL https://api.docswrite.com. Every call returns JSON; publishing is asynchronous and retry-safe.

1. Get a credential

Agents: connect to the MCP server and sign in with OAuth 2.1, no key to copy. Servers: create an org API key in Settings > API Keys.

export DOCSWRITE_API_KEY=dw_live_...

2. Find the destination

Every blog, CMS and social account connected to the workspace has an id.

curl -s https://api.docswrite.com/api/connections \
  -H "Authorization: Bearer $DOCSWRITE_API_KEY"

3. Publish

Send Markdown or HTML (or a Google Doc URL) to one or up to 20 connections. Drafts by default; status "schedule" with scheduled_at schedules it.

curl -s -X POST https://api.docswrite.com/api/v1/posts \
  -H "Authorization: Bearer $DOCSWRITE_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: launch-post-1" \
  -d '{"connection_ids": [123, 456], "title": "Launch", "content": "# We shipped", "status": "draft"}'
MCP

Docswrite MCP server

Claude, ChatGPT, Cursor and any MCP client can list your destinations and publish to them. The first call opens the Docswrite consent screen; the user picks the workspace and approves.

Remote server (OAuth 2.1 or API key)

Streamable HTTP at https://api.docswrite.com/mcp. Clients with OAuth sign in to Docswrite; others send an org API key as Authorization: Bearer.

  • list_connections
  • publish_post(writes)
  • list_posts
  • get_post_status
  • update_post(writes)
  • get_account_info
  • list_pricing_plans
  • upgrade_plan(writes)
  • search
  • fetch
claude mcp add --transport http docswrite https://api.docswrite.com/mcp
{"mcpServers": {"docswrite": {"url": "https://api.docswrite.com/mcp"}}}

No-auth servers

  • Discovery at https://docswrite.com/mcp: destinations, pricing, the auth guide and setup instructions, before an agent has an account.
  • Docs at https://docs.docswrite.com/mcp: search the Docswrite documentation.
  • Local: npx -y github:Docswrite/docswrite-mcp with a token in DOCSWRITE_TOKEN.
Authentication

OAuth 2.1 for agents, API keys for servers

Both are sent as Authorization: Bearer. Tokens act on one workspace with the scopes the person approved; every credential belongs to a person, never an anonymous agent.

OAuth 2.1

  • Authorization code with PKCE (S256 only) and refresh tokens.
  • Dynamic client registration at https://api.docswrite.com/oauth/register.
  • Metadata: authorization server, protected resource (MCP), protected resource (REST API).
  • The MCP server answers unauthenticated calls with 401 and WWW-Authenticate: Bearer resource_metadata=….
  • Access tokens last 1 hour; refresh tokens rotate on every use. No scope requested = all four.
  • People review and revoke apps in Settings > Connected apps.

Org API keys

dw_live_ + 32 characters, shown once, stored hashed. One key reaches every connection; send it as a Bearer token or x-api-key, never in a URL. Full guide: Docswrite API authentication.

Scopes
connections:readSee your connected sites and social accounts
posts:readSee your posts and their publishing status
posts:writeCreate, publish, schedule and update posts on your connections
account:readSee your account, organization and plan, and get upgrade links
Destinations

Every destination, one call

Connect a destination once in the dashboard (OAuth for most, a few fields for the rest). Then publish to it by id.

Blogs & CMS

  • WordPressPosts and pages with categories, tags, authors, featured image, Yoast / Rank Math / Newspack fields and ACF.
  • ShopifyBlog articles on a Shopify store.
  • WebflowItems in a Webflow CMS collection, with field mapping.
  • ContentfulEntries in a Contentful space.
  • GitHubMarkdown files committed to a repository (static sites, docs, Hugo, Jekyll, Astro).
  • GhostPosts on a Ghost site: publish, schedule or draft.
  • Dev.toMarkdown articles on a DEV Community profile.
  • HashnodeArticles on a Hashnode blog.
  • MediumStories on a Medium profile.
  • Wix(soon)Wix blog posts.
  • Docswrite hosted blogA blog hosted by Docswrite on a subdomain or your own domain: no CMS to run.

Social

  • X (Twitter)Posts on an X account.
  • LinkedInPosts on a LinkedIn profile.
  • Bluesky(soon)Posts on a Bluesky account.
  • Threads(soon)Posts on a Threads account.
Events

Webhooks, retries and limits

Get told when a post goes live instead of polling. Every request is signed with HMAC-SHA256 over the timestamp and body.

Webhook events

post.published
A post went live for the first time.
post.updated
A live post was re-published.
post.drafted
A publish finished as a draft.
post.scheduled
A post got a future publish time.
post.failed
A publish failed for good (with the reason).
connection.connected
A destination was connected or re-authorized.
connection.needs_attention
A destination needs to be reconnected.
connection.disconnected
A destination was removed.

Rate limits, idempotency and errors

  • 60 requests per minute per org key, with RateLimit-Limit, RateLimit-Remaining and RateLimit-Reset headers; 429 carries Retry-After.
  • Send Idempotency-Key on publish calls: a retry replays the first response for 24 hours and never double-posts.
  • Errors are JSON with a stable code: { "error": true, "code": "CONNECTION_REQUIRED", "message": "…" }.

Versioning and deprecation

The API changes additively. A breaking change ships under a new path; the old operation keeps working for at least six months and answers with Deprecation and Sunset headers until it is retired.

Machine-readable

Docswrite developer resources

Everything an agent needs to discover, authenticate and publish, at stable URLs.

Save hundreds of hours every month

Write once. Publish everywhere.

Google Docs to WordPress, Webflow, Shopify, Ghost, Medium and more in one click. No more copy-pasting, no more formatting issues.

  • 5 free exports
  • No credit card required