---
title: "Substack API: publication details, public posts as JSON"
description: "Substack API for publication details, public posts, single posts and comments as JSON. Four endpoints, one key, 1 credit per call."
url: https://perceptlayer.com/apis/substack
---

[APIs](https://perceptlayer.com/apis) / [Social media](https://perceptlayer.com/verticals/social) / Substack

1 credit per call 4 endpoints 

# Substack API

Substack API for publication details, public posts, single posts and comments as JSON. Four endpoints, one key, 1 credit per call.

[Get a free API key](https://perceptlayer.com/signup) Run it below

Substack

GET /v1/substack/posts?publication=slowboring&sort=new&offset=0&limit=2 

```
curl "https://api.perceptlayer.com/v1/substack/posts?publication=slowboring&sort=new&offset=0&limit=2" \
  -H "X-API-Key: $API_KEY"
```

cURL 1 credit per successful call

Run this call below or from your dashboard to see a live response.

Playground

## Run this API

cURL shell 

```
curl "https://api.perceptlayer.com/v1/substack/posts?publication=slowboring&sort=new&offset=0&limit=2" \
  -H "X-API-Key: $API_KEY"
```

Substack · 4 endpoints

## Endpoints

Every endpoint takes the same key. Open one for its parameters, the fields it returns and an example request.

Note 

Endpoints marked “Needs terms” return personal or social data. They work once you accept the [restricted-endpoint terms](https://perceptlayer.com/legal/restricted-endpoints) in your dashboard.

| Endpoint | Required parameters | Returns | Cost |
| --- | --- | --- | --- |
| [GET `/v1/substack/comments`](https://perceptlayer.com/apis/substack/comments) | `publication` `post_id` Needs terms | `id` `author` `date` `text` `likes` | 1 credit |
| [GET `/v1/substack/post`](https://perceptlayer.com/apis/substack/post) | `publication` `slug` Needs terms | `post` | 1 credit |
| [GET `/v1/substack/posts`](https://perceptlayer.com/apis/substack/posts) | `publication` +4 optional Needs terms | `id` `title` `slug` `author` `date` `likes` +3 more | 1 credit |
| [GET `/v1/substack/publication`](https://perceptlayer.com/apis/substack/publication) | `publication` Needs terms | `publication` | 1 credit |

Overview

## About the Substack API

## What you can get

The Substack API returns public Substack data as JSON through 4 endpoints. Every endpoint takes a `publication`. These are restricted endpoints: the [restricted-endpoint terms](https://perceptlayer.com/legal/restricted-endpoints) apply, and they don't permit collecting personal data without a lawful basis or using it to contact people.

-   **Publications:** `publication` returns one publication's details.
-   **Posts:** `posts` lists a publication's posts, with `sort` (new or top), `offset` and `limit`.
-   **One post:** `post` takes the post's `slug`.
-   **Comments:** `comments` takes a `post_id`.

## How a call works

Use the publication's name: `GET /v1/substack/posts?publication=...&sort=new&limit=10` with your key in the `X-API-Key` header lists its latest posts. Read one in full with `post` and its `slug`, and its comments with `comments` and its `post_id`. Every successful call costs 1 credit; failed calls cost nothing.

Social media JSON REST MCP Some endpoints need terms

### More social media APIs

[Behance](https://perceptlayer.com/apis/behance) [Bilibili](https://perceptlayer.com/apis/bilibili) [Bluesky](https://perceptlayer.com/apis/bluesky) [Dailymotion](https://perceptlayer.com/apis/dailymotion) [DeviantArt](https://perceptlayer.com/apis/deviantart) [DISBOARD](https://perceptlayer.com/apis/disboard) [Dribbble](https://perceptlayer.com/apis/dribbble) [Facebook](https://perceptlayer.com/apis/facebook) [Facebook Ad Library](https://perceptlayer.com/apis/facebook-ad-library) [Flickr](https://perceptlayer.com/apis/flickr) [Hacker News](https://perceptlayer.com/apis/hacker-news) [Imgur](https://perceptlayer.com/apis/imgur)

Use cases

### Archive a newsletter's public posts

`Use the Substack API to archive a newsletter's public posts` 

### Track what publications in your field are writing about

`Use the Substack API to track what publications in your field are writing about` 

### Feed public posts into a reading or summarising agent

`Use the Substack API to feed public posts into a reading or summarising agent` 

### Review public discussion on posts through their comments

`Use the Substack API to review public discussion on posts through their comments` 

FAQ

## Questions

**Is there a Substack API key?**

No key from Substack is needed. You call this Substack API with your Perceptlayer key in the \`X-API-Key\` header, after accepting the restricted-endpoint terms.

**How much does the Substack API cost?**

Each successful call costs one credit. New accounts get free credits to start, and credit packs bring the price down as you scale.

**What format are responses in?**

Every endpoint returns JSON, with no HTML parsing on your side.

**Is this the official Substack API?**

No. Perceptlayer is an independent service and is not affiliated with Substack. It returns Substack data as JSON with a Perceptlayer key, so there is no Substack developer account, app review or partner approval to get first. It only reads data: if Substack has an official API and you need to act on your own Substack account, such as posting, managing orders or reading private data, use that one.

**Should I build a Substack scraper instead?**

You can, but a Substack scraper is code you maintain: page changes break it, requests get blocked, and Substack's terms govern how you collect data. The Substack API gives you 4 endpoints of named JSON fields for 1 credit per successful call, and failed calls cost nothing. A scraper makes sense only for data these endpoints don't return, so check the response in the playground on this page first. Some of these endpoints return social or personal data and need the restricted-endpoint terms; collect only what you have a lawful basis for.

## Try the Substack API with 100 free credits

No credit card. Failed calls are never billed.

[Get a free API key](https://perceptlayer.com/signup) [Read the docs](https://docs.perceptlayer.com)
