API para Substack

API para Substack: Posts

Colete posts de qualquer publicação do Substack pela URL dela, ou passe a URL de um único post (…/p/slug) para obter só aquele artigo. Retorna título, subtítulo, data de publicação, status de paywall, contagem de palavras, engajamento (reações, comentários, restacks), perfil do autor, detalhes da publicação, o corpo completo do artigo em texto, HTML e Markdown, e threads de comentários opcionais.

POST/v1/run/substack.posts
Disponibilidade
100,00%
30d · 10 chamadas
Requisições
10
30d · semanal, últimas 12 sem.
Resposta
3,4s
mediana · 30d

Teste

Faça sua primeira requisição

Abrir em
Obter chave grátis
Resposta de exemplo
Execuções grátis retornam só os primeiros 3 resultados. Recarregue uma chave para receber a resposta completa.
{
  "data": {
    "items": [
      {
        "authorBio": "Alex Rivera",
        "authorHandle": "alex_rivera",
        "authorImage": "https://example.com/image.jpg",
        "authorName": "Alex Rivera",
        "authorUrl": "https://example.com/page",
        "commentCount": 12500,
        "comments": [
          {
            "authorHandle": "alex_rivera",
            "authorImage": "https://example.com/image.jpg",
            "authorName": "Alex Rivera",
            "authorUrl": "https://example.com/page",
            "commentId": "a1b2c3d4",
            "createdUtc": 12.5,
            "editedUtc": 12.5,
            "isAuthor": true,
            "isPinned": true,
            "reactionCount": 12500,
            "replies": [
              null
            ],
            "restackCount": 12500,
            "text": "A short example description of this item."
          }
        ],
        "contentStatus": "A short example description of this item.",
        "createdUtc": 12.5,
        "description": "A short example description of this item.",
        "hasVoiceover": true,
        "html": "example",
        "image": "https://example.com/image.jpg",
        "isPaid": true,
        "language": "en",
        "markdown": "example",
        "podcastUrl": "https://example.com/page",
        "postId": "a1b2c3d4",
        "postType": "general",
        "publication": {
          "customDomain": "example.com",
          "description": "A short example description of this item.",
          "id": "a1b2c3d4",
          "image": "https://example.com/image.jpg",
          "language": "en",
          "name": "Example title",
          "paymentsEnabled": true,
          "subdomain": "example.com",
          "subscriberCount": 12500,
          "url": "https://example.com/page"
        },
        "reactionCount": 12500,
        "replyCount": 12500,
        "restackCount": 12500,
        "slug": "alex_rivera",
        "subtitle": "Example title",
        "text": "A short example description of this item.",
        "title": "Example title",
        "updatedUtc": 12.5,
        "url": "https://example.com/page",
        "wordcount": 12500
      }
    ]
  },
  "found": true,
  "reason": "not_found"
}
Interface da resposta
interface SubstackPostsResponse {
  data: {
    items: {
      authorBio?: string;
      authorHandle?: string;
      authorImage?: string;
      authorName?: string;
      authorUrl?: string;
      commentCount?: number;
      comments?: {
        authorHandle?: string;
        authorImage?: string;
        authorName?: string;
        authorUrl?: string;
        commentId: string;
        createdUtc?: number;
        editedUtc?: number;
        isAuthor?: boolean;
        isPinned?: boolean;
        reactionCount?: number;
        replies?: {
          authorHandle?: string;
          authorImage?: string;
          authorName?: string;
          authorUrl?: string;
          commentId: string;
          createdUtc?: number;
          editedUtc?: number;
          isAuthor?: boolean;
          isPinned?: boolean;
          reactionCount?: number;
          restackCount?: number;
          text?: string;
        }[];
        restackCount?: number;
        text?: string;
      }[];
      contentStatus?: string;
      createdUtc?: number;
      description?: string;
      hasVoiceover?: boolean;
      html?: string;
      image?: string;
      isPaid?: boolean;
      language?: string;
      markdown?: string;
      podcastUrl?: string;
      postId?: string;
      postType?: string;
      publication?: {
        customDomain?: string;
        description?: string;
        id?: string;
        image?: string;
        language?: string;
        name?: string;
        paymentsEnabled?: boolean;
        subdomain?: string;
        subscriberCount?: number;
        url?: string;
      };
      reactionCount?: number;
      replyCount?: number;
      restackCount?: number;
      slug?: string;
      subtitle?: string;
      text?: string;
      title: string;
      updatedUtc?: number;
      url: string;
      wordcount?: number;
    }[];
  } | null;
  found: boolean;
  reason?: "not_found";
}

Referência completa de parâmetros e resposta - todos os campos, tipos e exemplos deste endpoint.

Referência

Requisição, resposta e preço

Última verificação em 2026-09-29 · disponibilidade e latência medidas em 30d
POST /v1/run/substack.posts
curl -X POST https://api.getanyapi.com/v1/run/substack.posts \
  -H "Authorization: Bearer $ANYAPI_KEY" \
  -H "Content-Type: application/json" \
  -d '{"limit":3,"url":"https://www.astralcodexten.com"}'
CampoTipoValor de exemplo
Corpo da requisição
urlstring"https://www.astralcodexten.com"A URL ou o domínio próprio de uma publicação do Substack, para obter seus posts recentes (ex.: https://www.astralcodexten.com), OU a URL de um único post, para obter só aquele artigo com o conteúdo completo (ex.: https://www.astralcodexten.com/p/your-book-review).
contentTypeenumRestringe a um único tipo de post, ou 'all' (ex.: newsletter).
endDatestringRetorna apenas posts publicados nesta data ou antes dela, no formato YYYY-MM-DD (ex.: 2024-12-31). Aplicado dentro dos 'limit' posts mais recentes analisados.
includeCommentsbooleanInclui as threads de comentários públicos e suas respostas diretas em cada post (ex.: true).
includeContentbooleanInclui o corpo completo do artigo em texto, HTML e Markdown. Defina como false para obter só metadados, o que é mais rápido (ex.: false).
limitinteger3Número máximo de posts recentes a retornar quando for informada a URL de uma publicação (1-100, padrão 25); ignorado para a URL de um único post, que sempre retorna aquele post. A cobrança é por post retornado, então um limite menor custa menos.
maxCommentsintegerMáximo de comentários coletados por post quando 'includeComments' for true (0-500, padrão 20). Não custa nada a mais (ex.: 50).
minCommentsintegerRetorna apenas posts com pelo menos este número de comentários (ex.: 10).
minReactionsintegerRetorna apenas posts com pelo menos este número de reações (ex.: 100).
minWordCountintegerRetorna apenas posts com pelo menos este número de palavras, o que filtra notas curtas e anúncios (ex.: 1000).
onlyFreebooleanRetorna apenas posts gratuitos (sem paywall) (ex.: true).
startDatestringRetorna apenas posts publicados nesta data ou depois dela, no formato YYYY-MM-DD (ex.: 2024-01-01). Aplicado dentro dos 'limit' posts mais recentes analisados, então aumente 'limit' para alcançar períodos mais antigos.
Resposta
dataobjectResult payload, or null when nothing was found.
data.itemsobject[]Post records: title, subtitle, URL, publish date, paywall status, word count, engagement (reactions, comments, restacks), author profile, publication details, the article body as text, HTML and Markdown, and comment threads when requested. Populated whenever the provider has data for the entity.
data.items[].authorBiostringAuthor bio as shown on their Substack profile.
data.items[].authorHandlestringSubstack handle of the post author. Populated whenever the provider has data for the entity.
data.items[].authorImagestringProfile photo URL of the post author.
data.items[].authorNamestringDisplay name of the post author. Populated whenever the provider has data for the entity.
data.items[].authorUrlstringSubstack profile URL of the post author.
data.items[].commentCountintegerNumber of top-level comments on the post.
data.items[].commentsobject[]Top-level comment threads on the post, each with its direct replies. Empty unless 'includeComments' is true. Replies nested more than one level deep are not returned.
data.items[].comments[].authorHandlestringSubstack handle of the comment author.
data.items[].comments[].authorImagestringProfile photo URL of the comment author.
data.items[].comments[].authorNamestringDisplay name of the comment author.
data.items[].comments[].authorUrlstringSubstack profile URL of the comment author.
data.items[].comments[].commentIdstringSubstack comment identifier.
data.items[].comments[].createdUtcnumberUTC epoch timestamp in seconds (Unix time). Multiply by 1000 for a JS Date in milliseconds.
data.items[].comments[].editedUtcnumberUTC epoch timestamp in seconds (Unix time). Multiply by 1000 for a JS Date in milliseconds.
data.items[].comments[].isAuthorbooleanWhether the comment was written by the post author.
data.items[].comments[].isPinnedbooleanWhether the comment is pinned by the publication.
data.items[].comments[].reactionCountintegerNumber of reactions on the comment.
data.items[].comments[].repliesobject[]Direct replies to this comment.
data.items[].comments[].replies[].authorHandlestringSubstack handle of the reply author.
data.items[].comments[].replies[].authorImagestringProfile photo URL of the reply author.
data.items[].comments[].replies[].authorNamestringDisplay name of the reply author.
data.items[].comments[].replies[].authorUrlstringSubstack profile URL of the reply author.
data.items[].comments[].replies[].commentIdstringSubstack comment identifier.
data.items[].comments[].replies[].createdUtcnumberUTC epoch timestamp in seconds (Unix time). Multiply by 1000 for a JS Date in milliseconds.
data.items[].comments[].replies[].editedUtcnumberUTC epoch timestamp in seconds (Unix time). Multiply by 1000 for a JS Date in milliseconds.
data.items[].comments[].replies[].isAuthorbooleanWhether the reply was written by the post author.
data.items[].comments[].replies[].isPinnedbooleanWhether the reply is pinned by the publication.
data.items[].comments[].replies[].reactionCountintegerNumber of reactions on the reply.
data.items[].comments[].replies[].restackCountintegerNumber of times the reply was restacked.
data.items[].comments[].replies[].textstringReply body text.
data.items[].comments[].restackCountintegerNumber of times the comment was restacked.
data.items[].comments[].textstringComment body text.
data.items[].contentStatusstringHow much of the article body this record carries: 'full' for the whole article, 'preview_only' for the public excerpt of a paywalled post, 'metadata_only' when no body was requested or available, or 'failed' when extraction failed. Read this before trusting 'text', 'html', or 'markdown'. Populated whenever the provider has data for the entity.
data.items[].createdUtcnumberUTC epoch timestamp in seconds (Unix time). Multiply by 1000 for a JS Date in milliseconds. Populated whenever the provider has data for the entity.
data.items[].descriptionstringShort post description, usually the subtitle or an excerpt.
data.items[].hasVoiceoverbooleanWhether the post carries a narrated audio version.
data.items[].htmlstringArticle body as HTML. Present when 'includeContent' is true and 'contentStatus' is 'full' or 'preview_only'.
data.items[].imagestringCover image URL.
data.items[].isPaidbooleanWhether the post is behind a paywall.
data.items[].languagestringTwo-letter language code of the post.
data.items[].markdownstringArticle body as Markdown. Present when 'includeContent' is true and 'contentStatus' is 'full' or 'preview_only'.
data.items[].podcastUrlstringAudio URL for a podcast post or a narrated voiceover, when the post has one.
data.items[].postIdstringSubstack post identifier. Populated whenever the provider has data for the entity.
data.items[].postTypestringPost type (newsletter, podcast, or thread). Populated whenever the provider has data for the entity.
data.items[].publicationobjectThe publication the post belongs to.
data.items[].publication.customDomainstringCustom domain the publication is served on, when it has one.
data.items[].publication.descriptionstringPublication tagline or hero text.
data.items[].publication.idstringSubstack publication identifier.
data.items[].publication.imagestringPublication logo URL.
data.items[].publication.languagestringTwo-letter language code of the publication.
data.items[].publication.namestringPublication name.
data.items[].publication.paymentsEnabledbooleanWhether the publication sells paid subscriptions.
data.items[].publication.subdomainstringPublication subdomain on substack.com.
data.items[].publication.subscriberCountintegerSubscriber count, when the publication publishes it.
data.items[].publication.urlstringPublication home URL.
data.items[].reactionCountintegerNumber of reactions (likes) on the post.
data.items[].replyCountintegerNumber of replies to comments on the post.
data.items[].restackCountintegerNumber of times the post was restacked.
data.items[].slugstringPost slug, the last path segment of the post URL. Populated whenever the provider has data for the entity.
data.items[].subtitlestringPost subtitle or deck.
data.items[].textstringArticle body as plain text. Present when 'includeContent' is true and 'contentStatus' is 'full' or 'preview_only'.
data.items[].titlestringPost title. Populated whenever the provider has data for the entity.
data.items[].updatedUtcnumberUTC epoch timestamp in seconds (Unix time). Multiply by 1000 for a JS Date in milliseconds.
data.items[].urlstringCanonical post URL. Populated whenever the provider has data for the entity.
data.items[].wordcountintegerApproximate word count of the article.
foundbooleanWhether any posts were found for the request.
reason"not_found"Present only when `found` is false, and says why there is no result. `not_found`: the source states the target does not exist, or returned nothing for it. A `found: false` answer is a successful call, not an error, and `costUsd` is what it actually cost.
Preço
Preço por requisição (teto)USDUS$ 0,0444
Preço /mil resultadosUSDUS$ 0,439604

Dúvidas frequentes

Sobre o endpoint Posts da API para Substack

O endpoint Posts da AnyAPI para Substack retorna dados de Substack em JSON normalizado com uma chamada POST para /v1/run/substack.posts. Colete posts de qualquer publicação do Substack pela URL dela, ou passe a URL de um único post (…/p/slug) para obter só aquele artigo. Retorna título, subtítulo, data de publicação, status de paywall, contagem de palavras, engajamento (reações, comentários, restacks), perfil do autor, detalhes da publicação, o corpo completo do artigo em texto, HTML e Markdown, e threads de comentários opcionais. A AnyAPI retorna um schema normalizado, seja qual for a fonte que atende. Custa US$ 0,44 por mil resultados, e nunca mais de US$ 0,0444 por requisição, em dólares, sem assinatura e sem mínimo mensal. Nos últimos 30 dias, 100,0% das chamadas ao endpoint Posts da API para Substack feitas pela AnyAPI tiveram sucesso, com tempo de resposta mediano de 3,4 segundos, em 10 chamadas medidas.

Custa US$ 0,44 por mil resultados, e nunca mais de US$ 0,0444 por requisição, em dólares, sem assinatura e sem mínimo mensal. Você recarrega uma carteira em dólares e cada chamada desconta dela. Algumas requisições pagas pela carteira que falham geram cobranças de processamento, que repassamos pelo custo, sem margem; a resposta de erro mostra o valor cobrado.

Colete posts de qualquer publicação do Substack pela URL dela, ou passe a URL de um único post (…/p/slug) para obter só aquele artigo. Retorna título, subtítulo, data de publicação, status de paywall, contagem de palavras, engajamento (reações, comentários, restacks), perfil do autor, detalhes da publicação, o corpo completo do artigo em texto, HTML e Markdown, e threads de comentários opcionais. A resposta é JSON normalizado, com o mesmo envelope que todo endpoint da AnyAPI retorna, então processar um segundo endpoint é só trocar a URL, e nada mais.

Nos últimos 30 dias, 100,0% das chamadas ao endpoint Posts da API para Substack feitas pela AnyAPI tiveram sucesso, com tempo de resposta mediano de 3,4 segundos, em 10 chamadas medidas. Estas são medições da própria AnyAPI sobre o tráfego que passa pelo gateway, recalculadas continuamente, e não uma meta de nível de serviço publicada.