Live

Substack logo

Substack API and MCP server

substack.com

Substack has only a limited API (checked 11 Oct 2026). Cotlet is a hosted MCP server and REST API for Substack with 14 endpoints (7 read, 7 write): your AI agent signs in as you and does the work.

Endpoints
14 7 read, 7 write
Updated
How Cotlet connects your agent to Substack
  1. Your agent

    Claude Code, Codex, Cursor or a script

  2. Cotlet

    MCP server and REST API · 14 endpoints

    cotlet.dev/mcp/v1

  3. Substack logo

    Substack

    Signed in as you on substack.com

You sign in once. We never store your password.

Official API

Does Substack have an official API?

Substack has only a limited API (checked 11 Oct 2026). Its Developer API looks up public creator profiles after approval, and there is no public API to write posts or Notes, manage subscribers or send email. RSS reads public posts only.

What Substack's own tools do compared with Cotlet
Task Substack official Cotlet
Create and edit drafts No Yes
Publish or schedule posts No Yes
Publish or schedule Notes No Yes
Add or export subscribers No Dashboard only: CSV import and export Yes
Post and publication stats No Dashboard only, exportable as CSV Yes
Reply to comments No Yes
Read your published posts Partly Public RSS feed, no drafts or paywalled text Yes

Sources: Substack Developer API Terms of Use · Substack features (scheduling, import, export, Notes, stats) · On Substack: you can now schedule Notes · Substack help: Do you support Markdown? (post editor) · Substack help: A guide to Substack metrics

Common use cases

What can an AI agent do in Substack?

Cotlet is best for newsletter writers who schedule posts, Notes and replies every week without running or fixing a server.

  • Schedule newsletter posts from a Markdown draft Runs: Weekly

    Turn essay.md into a Substack draft for everyone, schedule it for Tuesday 8:00 New York time, and schedule a Note with a link card to it for 12:00 the same day. Your agent calls list_posts, create_draft, schedule_post and publish_note.

  • Post a Note when a new post goes out

    Post a Note teasing today's essay, with a link card to it. Your agent calls list_posts and publish_note.

  • Weekly subscriber growth and revenue report Runs: Weekly

    Every Monday at 8:00, send me last week's Substack numbers: new free and paid subscribers, churned paid subscribers, revenue, and how each post from the week did on opens and new subscribers. Your agent calls get_publication_stats, list_posts and get_post_stats.

  • Reply to comments nobody answered Runs: Daily

    Every evening, find comments on my last three Substack posts that I have not answered, draft a short reply to each in my voice, and show me the drafts before posting. Your agent calls list_posts, list_comments and reply_to_comment.

  • Add event signups as subscribers

    Add everyone from workshop.csv as free subscribers. Your agent calls add_subscriber.

Endpoints

What is the Substack API?

Cotlet's Substack API exposes 14 endpoints for your own Substack account: list posts, get post, get post stats, get publication stats, list subscribers, export subscribers, list comments, create draft, update draft, schedule post, publish post, publish Note, reply to comment and add subscriber. The list_posts endpoint returns posts of your publication, newest first, with status and audience. Each endpoint takes simple JSON inputs like post_id, limit or cursor and works both as an MCP tool for agents and as a REST call for scripts.

All endpoints · 14 total

missing one? request an endpoint

  • POST

    list_posts

    read

    Lists posts of your publication, newest first. Filter by status to see drafts or scheduled posts. Scheduled posts include their publish time. Pages hold up to 50 posts; pass next_cursor back as cursor for the next page.

    POST /api/v1/substack/list_posts

    Input

    Input: list_posts
    Parameter Type Description
    status enum published, draft or scheduled. Default: published.
    limit integer 1 to 50. Default: 20.
    cursor string Next page cursor from the previous call.

    Example response

    {
      "posts": [
        {
          "post_id": "148213977",
          "title": "The quiet launch",
          "status": "published",
          "audience": "everyone",
          "published_at": "2026-10-06T12:00:00Z",
          "url": "https://yourname.substack.com/p/the-quiet-launch"
        },
        {
          "post_id": "148420031",
          "title": "Notes on pricing",
          "status": "draft",
          "audience": "only_paid",
          "published_at": null,
          "url": null
        }
      ],
      "next_cursor": "eyJvZmZzZXQiOjIwfQ"
    }
  • POST

    get_post

    read

    Returns one post with its full body as Markdown, including the paywalled part of your own posts. Use it to edit a published post or to quote it in a Note. Images come back as URLs.

    POST /api/v1/substack/get_post

    Input

    Input: get_post
    Parameter Type Description
    post_id required string Post ID from list_posts.

    Example response

    {
      "post_id": "148213977",
      "title": "The quiet launch",
      "subtitle": "What waiting taught me",
      "body_markdown": "Last month I shipped without telling anyone...",
      "audience": "everyone",
      "status": "published",
      "published_at": "2026-10-06T12:00:00Z",
      "url": "https://yourname.substack.com/p/the-quiet-launch"
    }
  • POST

    get_post_stats

    read

    Returns the engagement numbers of one published post, the same as its stats page in the dashboard. Email numbers cover the send; views include the web. Numbers keep growing for days after a send, so check again later.

    POST /api/v1/substack/get_post_stats

    Input

    Input: get_post_stats
    Parameter Type Description
    post_id required string Post ID from list_posts.

    Example response

    {
      "post_id": "148213977",
      "recipients": 4120,
      "opens": 2011,
      "open_rate": 0.488,
      "views": 3560,
      "likes": 142,
      "restacks": 18,
      "subscribers_gained": 37
    }
  • POST

    get_publication_stats

    read

    Returns subscriber and revenue numbers for a period, the same figures as the publisher dashboard: total, paid and new subscribers, churned subscribers and revenue. Periods are 7, 30 or 90 days.

    POST /api/v1/substack/get_publication_stats

    Input

    Input: get_publication_stats
    Parameter Type Description
    period enum 7d, 30d or 90d. Default: 30d.

    Example response

    {
      "period": "7d",
      "subscribers_total": 4380,
      "subscribers_paid": 412,
      "subscribers_new": 96,
      "subscribers_churned": 11,
      "revenue_usd": 3150
    }
  • POST

    list_subscribers

    read

    Lists subscribers, newest first. Filter by plan or by the date they joined. Activity rating is the 0 to 5 score Substack shows in the subscriber dashboard. Pages hold up to 500 subscribers; pass next_cursor back as cursor.

    POST /api/v1/substack/list_subscribers

    Input

    Input: list_subscribers
    Parameter Type Description
    plan enum all, free, paid, comp or founding. Default: all.
    since date Only subscribers who joined on or after this date.
    limit integer 1 to 500. Default: 100.
    cursor string Next page cursor from the previous call.

    Example response

    {
      "subscribers": [
        {
          "email": "maya@example.com",
          "plan": "free",
          "joined_at": "2026-10-04T09:12:00Z",
          "activity_rating": 4
        },
        {
          "email": "jon@example.com",
          "plan": "paid",
          "joined_at": "2026-10-02T17:40:00Z",
          "activity_rating": 5
        }
      ],
      "next_cursor": null
    }
  • POST

    export_subscribers

    read

    Builds the same CSV as Export in the subscriber dashboard and returns a link to it. Use it for the full list; list_subscribers is better for filtered pages. The link stops working after 1 hour.

    POST /api/v1/substack/export_subscribers

    Input

    No parameters.

    Example response

    {
      "download_url": "https://files.cotlet.example/exports/subscribers-2026-10-11.csv",
      "rows": 4380,
      "expires_at": "2026-10-11T13:00:00Z"
    }
  • POST

    list_comments

    read

    Returns the comments of one post, oldest first, with replies nested under their parent. Set unanswered_only to skip threads you already replied to. Pass comment_id from an item to reply_to_comment.

    POST /api/v1/substack/list_comments

    Input

    Input: list_comments
    Parameter Type Description
    post_id required string Post ID from list_posts.
    unanswered_only boolean Skip threads you already replied to.

    Example response

    {
      "comments": [
        {
          "comment_id": "c_90417",
          "author": "Maya Chen",
          "body": "Does the next part cover pricing?",
          "created_at": "2026-10-07T08:20:00Z",
          "replied": false,
          "replies": []
        }
      ]
    }
  • POST

    create_draft

    write

    Creates a draft in your publication and returns its post_id. The draft is visible only to your team. Sending is a separate step: schedule_post or publish_post. Creating a draft reaches no one and update_draft or the Substack editor changes it, so it runs without asking.

    POST /api/v1/substack/create_draft

    Input

    Input: create_draft
    Parameter Type Description
    title required string Post title.
    body_markdown required string Post body. Images by URL.
    subtitle string Shown under the title and in the email preview.
    audience enum everyone, only_paid or founding. Default: everyone.

    Example response

    {
      "post_id": "148420031",
      "status": "draft",
      "audience": "everyone",
      "edit_url": "https://yourname.substack.com/publish/post/148420031"
    }
  • POST

    update_draft

    write

    Changes fields of a draft and leaves the others as they are. It works on drafts only; a published post is not changed. Nothing reaches your subscribers, so it runs without asking.

    POST /api/v1/substack/update_draft

    Input

    Input: update_draft
    Parameter Type Description
    post_id required string Post ID from list_posts.
    fields required object Any of title, subtitle, body_markdown, audience.

    Example response

    {
      "post_id": "148420031",
      "status": "draft",
      "updated": [
        "title",
        "body_markdown"
      ]
    }
  • POST

    schedule_post

    write

    Schedules a draft to go live at the time you set, on the web and, unless send_email is false, by email to your subscribers. The time must be in the future. A scheduled post stays editable until it goes out. By default you confirm each call; you can switch that off for this tool.

    POST /api/v1/substack/schedule_post

    Input

    Input: schedule_post
    Parameter Type Description
    post_id required string Post ID from list_posts.
    publish_at required datetime ISO 8601 with time zone.
    send_email boolean Email it to subscribers. Default: true.

    Example response

    {
      "post_id": "148420031",
      "status": "scheduled",
      "publish_at": "2026-10-13T08:00:00-04:00",
      "audience": "everyone",
      "url": "https://yourname.substack.com/p/notes-on-pricing"
    }
  • POST

    publish_post

    write

    Publishes a draft immediately, on the web and, unless send_email is false, by email to your subscribers. A sent email cannot be recalled. By default you confirm each call; you can switch that off for this tool.

    POST /api/v1/substack/publish_post

    Input

    Input: publish_post
    Parameter Type Description
    post_id required string Post ID from list_posts.
    send_email boolean Email it to subscribers. Default: true.

    Example response

    {
      "post_id": "148420031",
      "status": "published",
      "published_at": "2026-10-11T10:02:00Z",
      "emailed": true,
      "url": "https://yourname.substack.com/p/notes-on-pricing"
    }
  • POST

    publish_note

    write

    Posts a Note under your name. Without publish_at it goes out now; with it, the Note waits in your scheduled Notes and goes out at that time. Text is up to 1,000 characters. By default you confirm each call; you can switch that off for this tool.

    POST /api/v1/substack/publish_note

    Input

    Input: publish_note
    Parameter Type Description
    body required string Note text, up to 1,000 characters.
    link_post_id string Attach one of your posts as a card.
    publish_at datetime ISO 8601 with time zone. Omit to post now.

    Example response

    {
      "note_id": "n_5521098",
      "status": "published",
      "published_at": "2026-10-11T10:05:00Z",
      "url": "https://substack.com/@yourname/note/c-5521098"
    }
  • POST

    reply_to_comment

    write

    Posts a reply under one comment, under your name, visible to everyone who can read the post. The author gets Substack's usual reply notification. By default you confirm each call; you can switch that off for this tool.

    POST /api/v1/substack/reply_to_comment

    Input

    Input: reply_to_comment
    Parameter Type Description
    comment_id required string Comment ID from list_comments.
    body required string Reply text.

    Example response

    {
      "comment_id": "c_90432",
      "parent_id": "c_90417",
      "created_at": "2026-10-11T10:07:00Z"
    }
  • POST

    add_subscriber

    write

    Adds one email to your list. Substack sends the new subscriber its usual welcome email. With plan set to comp the person gets a complimentary paid plan until comp_until; for someone who already pays, the time is added after their current billing cycle. Add only people who agreed to hear from you. By default you confirm each call; you can switch that off for this tool.

    POST /api/v1/substack/add_subscriber

    Input

    Input: add_subscriber
    Parameter Type Description
    email required string Subscriber email.
    plan enum free or comp. Default: free.
    comp_until date End of the complimentary plan.

    Example response

    {
      "email": "maya@example.com",
      "plan": "free",
      "status": "added",
      "joined_at": "2026-10-11T10:09:00Z"
    }

Setup

How do I connect Substack to Claude Code, Codex or Cursor?

Connecting Substack takes three steps: request access, sign in to Substack once, then add one MCP server or call the REST API with the same key.

Connect Substack over MCP

  1. 1

    Create an account

    Sign up and add Substack in the console. Your API key is there too.

  2. 2

    Sign in to Substack once

    Open the connect page from the console and sign in to Substack the way you always do. We keep the session, never your password, and you can revoke it anytime.

  3. 3

    Add Cotlet to your agent

    Claude Code
    claude mcp add --transport http cotlet \
      https://cotlet.dev/mcp/v1 \
      --header "Authorization: Bearer $COTLET_API_KEY"
    Cursor
    {
      "mcpServers": {
        "cotlet": {
          "url": "https://cotlet.dev/mcp/v1",
          "headers": {
            "Authorization": "Bearer ${COTLET_API_KEY}"
          }
        }
      }
    }
    Codex
    # ~/.codex/config.toml
    [mcp_servers.cotlet]
    url = "https://cotlet.dev/mcp/v1"
    bearer_token_env_var = "COTLET_API_KEY"

    Paste the snippet for your client. The same server and key serve every app you connect, so you do this once.

  4. 4

    Ask your agent

    Prompt

    Turn essay.md into a Substack draft for everyone, schedule it for Tuesday 8:00 New York time, and schedule a Note with a link card to it for 12:00 the same day.

    Ask in plain words. Your agent finds the Substack tools on the server and calls them for you; anything that reaches other people waits for your OK unless you switch that off for a tool.

Call Substack over REST

  1. 1

    Export your API key

    Shell

    export COTLET_API_KEY="cotlet_..."

    Your scripts use the same API key as your agent. Keep it in an environment variable, never in your code.

  2. 2

    Call a tool

    curl

    curl https://cotlet.dev/api/v1/substack/schedule_post \
      -H "Authorization: Bearer $COTLET_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{"post_id":"148420031","publish_at":"2026-10-13T08:00:00-04:00","send_email":true}'

    Every tool is a POST endpoint at /api/v1/substack/{tool}. Send its parameters as JSON, exactly as listed in the endpoints above.

  3. 3

    Read the result

    Example response · schedule_post

    {
      "post_id": "148420031",
      "status": "scheduled",
      "publish_at": "2026-10-13T08:00:00-04:00",
      "audience": "everyone",
      "url": "https://yourname.substack.com/p/notes-on-pricing"
    }

    You get plain JSON back, ready for your script. A failed call costs nothing.

Why Cotlet

Why use Cotlet for Substack? Hosted, safe and kept working.

  • Built for agents

    • One MCP server for every app you connect.
    • The same tools as a REST API for scripts and cron jobs.
    • Works with Claude Code, Codex and Cursor.
  • Your login stays yours

    • You sign in to Substack yourself. We keep only the session, encrypted with AES-256.
    • The model never sees a login.
    • No stored passwords, no CAPTCHA solving, no MFA bypass.
  • You stay in control

    • Pick read only, or read and write.
    • Anything that reaches other people waits for your OK, unless you switch it off per tool.
    • Revoke access in one click.
  • Kept working for you

    • We test every integration daily.
    • When Substack changes, the tool pauses until we fix it.
    • Failed calls cost nothing.

Alternatives

Is there a Substack MCP server on GitHub?

Yes. Community Substack MCP servers exist on GitHub, usually maintained by one person. You install one on your own computer, give it a session cookie copied from your browser, and keep it running yourself; when Substack changes its site, it stops working until you or the maintainer fix it. Cotlet hosts the same kind of server for you, and our team keeps it working.

Cotlet compared with a GitHub MCP server
GitHub MCP server Cotlet
Setup Clone the repo, copy a session cookie from DevTools into a config file, add it to each MCP client Request access, sign in to Substack once, add one MCP server or API key
When Substack changes It breaks until you or the maintainer fix it Our team tests it daily and fixes it for you; failed calls are free
Your Substack session A cookie in a file on your computer, readable by any program you run Encrypted in an EU vault, limited to the actions you allow, revoked in one click
When the session expires Tools fail until you paste a new cookie We keep it alive; if Substack logs you out, your agent gets a link to sign in again
Upkeep You update, monitor and debug it yourself Nothing to host or update
Where it runs Your computer, while it is on Hosted: Claude Code, Codex, Cursor, n8n and scripts, also on a schedule
Price Free, paid for with your time Free 7-day trial with 5,000 credits, then credits per call

Which one fits you

Pick Cotlet if

  • you are not a developer, or you do not want to maintain a server
  • you need it to keep working when Substack changes, without checking it yourself
  • your agent or a script should run it on a schedule, also while your computer is off

Pick an open-source server if

  • you are comfortable installing, updating and fixing it yourself
  • you want the session to stay on your own computer
  • you only need it now and then, from one MCP client

For AI agents

Cotlet for Substack in plain text The facts on this page in one block: status, endpoints, access, pricing, contact.

Endpoint health

verified 2h ago

  • list_posts passing
  • get_post passing
  • get_post_stats passing
  • get_publication_stats passing
  • list_subscribers passing

+ 9 more endpoints

14/14 passing latest check self-healing

substack.txt

Substack has only a limited API (checked 11 Oct 2026). Its Developer API looks up public creator profiles after approval, and there is no public API to write posts or Notes, manage subscribers or send email. RSS reads public posts only.
Cotlet provides a hosted MCP server and REST API for Substack: 14 tools (7 read, 7 write).
Access       Request access at https://cotlet.dev/app/signup?app=substack; we email the API key.

MCP server   https://cotlet.dev/mcp/v1
REST base    https://cotlet.dev/api/v1/substack
Auth         Authorization: Bearer <COTLET_API_KEY>. Listing endpoints and schemas needs no key; calling an endpoint needs one.
Tools        list_posts, get_post, get_post_stats, get_publication_stats, list_subscribers, export_subscribers, list_comments, create_draft, update_draft, schedule_post, publish_post, publish_note, reply_to_comment, add_subscriber
Confirm      schedule_post, publish_post, publish_note, reply_to_comment, add_subscriber (by default the user approves each call; the user can switch this off per tool, e.g. for scheduled automations)
Markdown     https://cotlet.dev/integrations/substack-api-mcp-server.md

How access works:
1. The user requests access at https://cotlet.dev/app/signup?app=substack (Substack is pre-selected). Each request is reviewed and the API key is sent by email.
2. The user signs in to Substack once in a browser. An agent cannot do this step.
3. The API key goes into the MCP client or the REST call as a bearer token.

Fits: people who want a hosted Substack server that someone else maintains, including non-developers. Developers who prefer to run and fix code on their own computer can use an open-source Substack MCP server instead.

Policy: Cotlet never stores passwords, never solves CAPTCHAs, never bypasses MFA.
Company: legal details in the Terms of service at https://cotlet.dev/terms. Contact contact@cotlet.dev.
Session: the user signs in to Substack in a browser; Cotlet keeps only the session, AES-256 encrypted, revocable in the dashboard at any time.
Terms: the user stays responsible for following Substack's terms; Cotlet is not affiliated with Substack.
Full page as Markdown

Automations

Can Substack automations run on a schedule in n8n, Make or Zapier?

Yes. Cotlet does not replace your automation platform: it gives it a Substack connection it does not have, with the same API key as your agent. Write actions ask for your OK by default; switch that off in your dashboard for the tools you choose, for example to schedule newsletter posts from a markdown draft, and the schedule runs on its own. Cotlet runs in the cloud, so it keeps going while your computer is off.

Where to run Substack automations through Cotlet, and how to schedule them
Where How to connect How to schedule
Your AI agent Add https://cotlet.dev/mcp/v1 with your API key. A scheduled agent run, for example a Claude Code routine.
n8n MCP Client node with https://cotlet.dev/mcp/v1, or an HTTP Request node to https://cotlet.dev/api/v1/substack/{tool}. Schedule Trigger node.
Make HTTP module: POST https://cotlet.dev/api/v1/substack/{tool} with an Authorization: Bearer header and a JSON body. Scenario schedule.
Zapier Webhooks by Zapier: POST https://cotlet.dev/api/v1/substack/{tool} with the same header and body. Schedule by Zapier trigger.
Your own script POST https://cotlet.dev/api/v1/substack/{tool} with your API key. cron or GitHub Actions.

Pricing & limits

How much does the Substack API cost?

Free 7-day trial with 5,000 credits, no card needed. After that, the Substack API comes with the Cotlet plan, from $29 a month for 3,000 credits, with no limit on apps. Each month's credits stay valid for 3 months, so unused credits add up.

Cotlet plan sizes: price, monthly credits and price per credit
Size Price Credits / month Per credit
Solo $29/mo 3,000 about $0.0097
Pro $99/mo 12,000 about $0.0083
Agency $299/mo 40,000 $0.0075

Each successful call uses credits for the work it takes; failed calls and timeouts cost nothing. A hard spend cap is on by default. Authenticate with the Authorization: Bearer header.

About Cotlet

How Cotlet holds your access

Cotlet hosts MCP servers and REST APIs for apps with no usable API. Your agent works in your own Substack account.

Company details
The legal name, address and registration numbers of the company behind Cotlet are in the Terms of service. Terms
Your session
You sign in to Substack yourself, in your browser. We keep only the session, never your password: encrypted with AES-256 in an EU vault, isolated to your account and used only when your agent calls a Substack tool you allowed. When it expires, your agent gives you a link to sign in again. Security
Revoking access
Disconnect Substack in your dashboard: the session is deleted and access ends at once. Actions that reach other people wait for your OK unless you switch that off per tool.
What we never do
Store passwords, solve CAPTCHAs or bypass MFA.
Substack's terms
You use your own Substack account and stay responsible for following Substack's terms. Cotlet is independent and not affiliated with Substack. Terms
Contact
Questions about the company, security or an app: contact@cotlet.dev
About Cotlet

Frequently asked questions

How do I get access?

Request access and pick Substack. Cotlet reviews each request and emails you your API key.

Do I need to be technical?

No. You sign in to Substack once in your browser and paste one command into your agent, or one URL into n8n. Your agent can walk you through it. There is no server to install, update or fix.

Is a hosted server safe? My Substack session would leave my computer.

Cotlet keeps your Substack session encrypted with AES-256 in an EU vault, isolated to your account and used only for the tools you allow: read only, or read and write. The AI model never sees it, and you revoke it in one click. A local server keeps the same session in a file on your computer, readable by any program you run, and needs a fresh sign-in whenever it expires.

Can it schedule Notes as well as posts?

Yes. publish_note takes a publish_at time and the Note waits in your scheduled Notes until then. Substack added Notes scheduling in its apps; see On Substack, linked in the sources.

Does it need a paid Substack plan?

It acts as the Substack account you sign in with and can do what that account can do in the publication.

Can my agent post or send messages in Substack without asking me?

No. Every call to schedule_post, publish_post, publish_note, reply_to_comment or add_subscriber waits for your OK by default. For scheduled automations you can switch confirmation off per tool in your dashboard, for example only for approvals. create_draft, update_draft runs without asking, because it sends nothing to anyone and one call undoes it.

Can I use the Substack API in n8n?

Yes. Add https://cotlet.dev/mcp/v1 with your API key in n8n's MCP Client node, or call https://cotlet.dev/api/v1/substack/{tool} from the HTTP Request node.

Give your agent access to Substack.

Request access and pick it. We review each request and email you your API key. Free 7-day trial with 5,000 credits, no card needed.