morigraph Start free

Data APIs · Substack

Substack data API for AI agents

morigraph has one Substack data API, Substack Posts, that Claude, ChatGPT, Cursor, Codex or your own code can call. Pull posts from any Substack publication by its URL, or pass a single post URL (…/p/slug) to fetch just that one article. Returns title, subtitle, publish date, paywall status, word count, engagement (reactions, comments, restacks), author profile, publication details, the full article body as text, HTML and Markdown, and optional comment threads. You need no Substack developer account or API key, only one morigraph connection. A call costs 5.78 credits, about $578 for 1,000 calls, paid from one balance.

APIs
1
Price
5.78 credits a call
Call it from
MCP, command line and HTTP API
Needs
One morigraph connection. No Substack account or API key

Three ways to call it

Every data API is run by one tool, data_api, with the API's id and its arguments. The example is Substack Posts.

In your assistant (MCP). Connect once, then ask in plain words

claude mcp add --transport http --scope user morigraph https://morigraph.com/mcp

Use morigraph's Substack Posts data API with {"limit":3,"url":"https://www.astralcodexten.com"} and summarise what comes back.

From a terminal or script (CLI)

npx @morigraph/cli@latest login
morigraph call data_api --json-args '{"api":"substack.posts","input":{"limit":3,"url":"https://www.astralcodexten.com"}}'

From your own code (HTTP API)

curl https://api.morigraph.com/v1/tools/data_api \
  -H "Authorization: Bearer $MORIGRAPH_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"api":"substack.posts","input":{"limit":3,"url":"https://www.astralcodexten.com"}}'

Substack Posts

substack.posts5.78 credits a call (about $578 for 1,000)

Pull posts from any Substack publication by its URL, or pass a single post URL (…/p/slug) to fetch just that one article. Returns title, subtitle, publish date, paywall status, word count, engagement (reactions, comments, restacks), author profile, publication details, the full article body as text, HTML and Markdown, and optional comment threads.

ArgumentTypeRequiredWhat it is
contentTypeall | newsletter | podcast | threadnoRestrict to a single post type, or 'all' (e.g. newsletter). Default "all".
endDatestringnoOnly return posts published on or before this date, format YYYY-MM-DD (e.g. 2024-12-31). Applied within the most recent 'limit' posts scanned.
includeCommentsbooleannoInclude public comment threads and their direct replies on each post (e.g. true). Default false.
includeContentbooleannoInclude the full article body as text, HTML and Markdown. Set false for metadata only, which is faster (e.g. false). Default true.
limitintegernoMaximum number of recent posts to return when given a publication URL (1-100, default 25); ignored for a single post URL, which always returns that one post. You are billed per post returned, so a lower limit costs less.
maxCommentsintegernoMaximum comments collected per post when 'includeComments' is true (0-500, default 20). Costs nothing extra (e.g. 50).
minCommentsintegernoOnly return posts with at least this many comments (e.g. 10).
minReactionsintegernoOnly return posts with at least this many reactions (e.g. 100).
minWordCountintegernoOnly return posts with at least this many words, which filters out short notes and announcements (e.g. 1000).
onlyFreebooleannoReturn only free (non-paywalled) posts (e.g. true). Default false.
startDatestringnoOnly return posts published on or after this date, format YYYY-MM-DD (e.g. 2024-01-01). Applied within the most recent 'limit' posts scanned, so raise 'limit' to reach older date ranges.
urlstringyesEither a Substack publication URL / custom domain to fetch its recent posts (e.g. https://www.astralcodexten.com), OR a single post URL to fetch just that one article with full content (e.g. https://www.astralcodexten.com/p/your-book-rev…

Returns authorBio authorHandle authorImage authorName authorUrl commentCount comments contentStatus createdUtc description hasVoiceover html image isPaid language markdown podcastUrl postId postType publication reactionCount replyCount restackCount slug subtitle text title updatedUtc url wordcount

The call

data_api({"api":"substack.posts","input":{"limit":3,"url":"https://www.astralcodexten.com"}})

Good to know

When to choose something else

Choose a provider that specialises in Substack data when you need it at high volume, on a schedule, or as bulk exports: you will get volume pricing and more control. Choose the platform's official API when you need data from your own account. These APIs are for an agent that needs an answer now, alongside other tools on the same balance.

Questions

Do I need a Substack API key or developer account?

No. morigraph supplies the access. You connect morigraph once to your assistant, or use one morigraph API key from your own code, and call the API on this page.

What does Substack data cost through morigraph?

5.78 credits a call, where a credit is about 10 cents. That is from about $578 for 1,000 calls. You pay per call from one balance, with no separate subscription.

Can Claude, ChatGPT or Cursor get Substack data?

Yes. Add morigraph as an MCP server, sign in once, then ask in plain words. Your assistant finds the right API with one search and runs it with one call.

Prices and availability read from the production service on . A credit is about 10 cents of tool use; see pricing. Your assistant can quote the exact cost before a paid call.