curl --request POST \
--url https://api.aisa.one/apis/v1/substack-com/newsletters/archive \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"publication": "www.astralcodexten.com"
}
'import requests
url = "https://api.aisa.one/apis/v1/substack-com/newsletters/archive"
payload = { "publication": "www.astralcodexten.com" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({publication: 'www.astralcodexten.com'})
};
fetch('https://api.aisa.one/apis/v1/substack-com/newsletters/archive', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/apis/v1/substack-com/newsletters/archive",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'publication' => 'www.astralcodexten.com'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/substack-com/newsletters/archive"
payload := strings.NewReader("{\n \"publication\": \"www.astralcodexten.com\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/apis/v1/substack-com/newsletters/archive")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"publication\": \"www.astralcodexten.com\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/substack-com/newsletters/archive")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"publication\": \"www.astralcodexten.com\"\n}"
response = http.request(request)
puts response.read_bodyArchive
One page of a Substack publication’s archive, newest or top first, or only its pinned posts. Each entry carries title, subtitle, URL, publish time, audience (free or paid), word count, engagement counts, section, tags and bylines. Page with cursor (or offset) and limit.
curl --request POST \
--url https://api.aisa.one/apis/v1/substack-com/newsletters/archive \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"publication": "www.astralcodexten.com"
}
'import requests
url = "https://api.aisa.one/apis/v1/substack-com/newsletters/archive"
payload = { "publication": "www.astralcodexten.com" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({publication: 'www.astralcodexten.com'})
};
fetch('https://api.aisa.one/apis/v1/substack-com/newsletters/archive', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/apis/v1/substack-com/newsletters/archive",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'publication' => 'www.astralcodexten.com'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/substack-com/newsletters/archive"
payload := strings.NewReader("{\n \"publication\": \"www.astralcodexten.com\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/apis/v1/substack-com/newsletters/archive")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"publication\": \"www.astralcodexten.com\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/substack-com/newsletters/archive")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"publication\": \"www.astralcodexten.com\"\n}"
response = http.request(request)
puts response.read_bodyRequest contract
- Method and path: POST /apis/v1/substack-com/newsletters/archive
- Availability: enabled
- Request URL template:
https://api.aisa.one/apis/v1/substack-com/newsletters/archive
{
"operationId": "substack-com.newsletters.archive",
"method": "POST",
"path": "/apis/v1/substack-com/newsletters/archive",
"servers": [
{
"url": "https://api.aisa.one"
}
],
"parameters": [],
"security": [
{
"bearerAuth": []
}
],
"requestBody": {
"content": {
"application/json": {
"examples": {
"provider": {
"summary": "Official provider example; checked against AIsa request constraints",
"value": {
"limit": 1,
"publication": "www.astralcodexten.com"
}
}
},
"schema": {
"additionalProperties": true,
"properties": {
"cursor": {
"description": "next_cursor from the previous page of the same publication, sort and query. Takes precedence over offset.",
"type": "string",
"x-alexandria-option-metadata": {
"in": "body"
}
},
"limit": {
"default": 12,
"description": "Posts to return. Substack serves 25 per request, so larger pages take two requests.\n\nProvider reference: minimum 1; maximum 50; default 12.",
"type": "number",
"x-alexandria-option-metadata": {
"in": "body",
"max": 50,
"min": 1
}
},
"offset": {
"default": 0,
"description": "Posts to skip. new listings reach at most 250 by offset; follow next_cursor for deeper pages. Ignored when cursor is set.\n\nProvider reference: minimum 0; maximum 10000; default 0.",
"type": "number",
"x-alexandria-option-metadata": {
"in": "body",
"max": 10000,
"min": 0
}
},
"publication": {
"description": "Substack slug or a declared custom publication host (www.astralcodexten.com, www.lennysnewsletter.com, www.noahpinion.blog). Other custom domains are not supported by this program.",
"type": "string"
},
"sort": {
"default": "new",
"description": "new = newest first, top = most popular, pinned = the publication's pinned posts only (usually one, a single page).\n\nProvider reference: allowed values [\"new\", \"top\", \"pinned\"]; default \"new\".",
"type": "string",
"x-alexandria-option-metadata": {
"in": "body",
"oneOf": [
"new",
"top",
"pinned"
]
}
}
},
"required": [
"publication"
],
"type": "object"
}
}
},
"required": true
},
"x-aisa-status": "enabled",
"components": {
"securitySchemes": {
"bearerAuth": {
"scheme": "bearer",
"type": "http"
}
}
}
}
Cost and request rules
Usage-based pricing. Default request estimate: $0.0005 USD. The final charge depends on actual usage. Your account price may differ; use a request quote where supported.Authorizations
Body
Substack slug or a declared custom publication host (www.astralcodexten.com, www.lennysnewsletter.com, www.noahpinion.blog). Other custom domains are not supported by this program.
Response
One page of a Substack publication's archive, newest or top first, or only its pinned posts. Each entry carries title, subtitle, URL, publish time, audience (free or paid), word count, engagement counts, section, tags and bylines. Page with cursor (or offset) and limit. Custom domains are limited to the declared publications; paid text remains the anonymous preview.
The response contains the tool result directly.
The provider identifies posts as the primary payload key.
| Documented field | Provider type | Description |
|---|---|---|
audience | string | |
authors | object[] | |
comments | number | |
cover_image | string | |
description | string | |
free_preview_sent | boolean | |
id | string | |
paywalled | boolean | |
podcast_duration_seconds | number | |
podcast_url | string | |
preview_text | string | |
publication_id | string | |
published_at | string | |
reactions | number | |
restacks | number | |
section | object | |
slug | string | |
subtitle | string | |
tags | object[] | |
title | string | |
type | string | |
url | string | |
wordcount | number |
These are the provider's documented fields. Field requiredness, nullability and nested object structures are specified only where the descriptions explicitly say so.