# Bluesky Posts API: profile posts with likes, reposts, replies (`stas_k/bluesky-posts-api`) Actor

Bluesky actors bill you for a feed you cannot verify: search needs a login and counts come back missing. This one reads any public profile's posts without a key, no login and no browser, and you pay only for a post that lands with its likes, reposts, replies, quotes, languages and dates.

- **URL**: https://apify.com/stas_k/bluesky-posts-api.md
- **Developed by:** [Stas K](https://apify.com/stas_k) (community)
- **Categories:** Social media, Developer tools, Automation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

$0.30 / 1,000 posts

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Bluesky Posts API

Read the public posts of any Bluesky profile: text, publish time, likes, reposts,
replies, quotes, languages, the author and a link to the post. No API key, no login,
no browser and no proxy.

### What this actor does

1. Takes a list of profiles: handles (`bsky.app`), dids or full profile urls
   (`https://bsky.app/profile/bsky.app`).
2. Reads each profile's public author feed, newest first, 50 posts per request.
3. Writes one row per post into the dataset, with the profile's follower and post counts
   attached, so a buyer can filter by reach without a second call.
4. Everything that was not delivered comes back as a row with a status and a reason,
   and costs nothing.

### What this actor does not do

- It does not search. The public search endpoint needs a session and answers 403 without
  one, so search is not offered at all rather than promised and broken.
- It does not read a whole network graph: profiles come from the input, not from follows.
- Reposts and replies are off by default. A repost is somebody else's post shown on this
  profile and a reply is a post written to somebody else. `includeReposts` filters them
  from the rows; `includeReplies` also changes the **request**, because the feed endpoint
  drops replies at the source unless it is asked otherwise (`posts_no_replies` versus
  `posts_with_replies`). Measured 2026-11-12: 0 replies in 50 items without the flag, 22
  on `jay.bsky.team` and 18 on `bsky.app` with it. `feedKind` and `isReply` report the
  kind either way.
- It does not resolve deleted posts: if the source does not return a post, it is not
  invented.
- A profile whose feed is closed or empty gets a free status row, not a paid empty row.

### Money

- Price: **$0.0003 per delivered post** (`post-delivered`), the lowest spending limit you can set per run is $0.05.
- You pay only for a row that lands in the dataset with text or media. A row with a
  status other than `OK` is free, and it carries no post id, no text, no author and no url.
- A post without text and without media (a like-only feed item) is not delivered and not
  charged.
- If the price cannot be read, the run stops before the first payable post: nothing is
  delivered and nothing is charged, and each remaining line says why.
- If the spending cap or the remaining budget ends, the rows beyond it are returned free
  with `NOT_CHECKED_CAP`, and `stopReason` says `spending-cap`.
- `maxPostsPerActor` is a paid boundary, not a free sample: when this profile's limit is
  reached, one free `NOT_CHECKED_LIMIT` row says so and carries no post data. Nothing
  beyond the limit is read.
- The same profile sent twice (as a handle, a did or a url) is read once, and the second
  line gets a free `DUPLICATE` row.

### What was measured against the live source (2026-11-12)

- `public.api.bsky.app/xrpc/app.bsky.actor.getProfile` answers 200 without auth and
  returns handle, did, displayName, description, followersCount, followsCount, postsCount.
- `app.bsky.feed.getAuthorFeed` answers 200 with **50 items and a cursor**; the cursor is a
  timestamp, and paging continues until the feed ends.
- A feed item is `{"post": {...}}`; the post carries `uri`, `cid`, `indexedAt`,
  `likeCount`, `repostCount`, `replyCount`, `quoteCount`, `bookmarkCount`, `embed`,
  `labels` and `author`.
- Text lives in `post.record.text`, the publish moment in `post.record.createdAt`, the
  indexed moment in `post.indexedAt`, the languages in `post.record.langs`.
- Reposts and pins arrive as `item.reason` (`#reasonRepost`, `#reasonPin`) with the
  original post inside.
- It answers from a datacenter, so no proxy is needed.

### Status codes

| Status | Meaning | Charged |
| --- | --- | --- |
| `OK` | the post was delivered | yes |
| `INVALID_INPUT` | not a handle, did or profile url | no |
| `DUPLICATE` | the same profile was already sent in this run, in any form | no |
| `NO_POSTS_FOUND` | the profile is open and its feed returned no posts | no |
| `NOT_CHECKED_LIMIT` | this profile reached `maxPostsPerActor`; more posts may exist | no |
| `NOT_CHECKED_TIME` | the platform deadline came first | no |
| `NOT_CHECKED_ERROR` | the profile or feed could not be read | no |
| `NOT_CHECKED_CAP` | the spending cap or budget ended | no |
| `NOT_CHECKED_BILLING` | the price could not be read | no |
| `NOT_CHECKED_CHARGE_UNVERIFIED` | delivered, but the charge was not confirmed | not claimed |

### Stop reasons

`spending-cap`, `billing-price-unknown`, `charge-error`, `dataset-write-error`, `deadline`.

### Output

- Dataset: one row per post, see `.actor/output_schema.json` for the field list.
- `postsLimited` counts profiles that hit `maxPostsPerActor`, not posts that were skipped:
  how many posts lie beyond the limit is not measurable without reading them.
- Run summary: `RUN_SUMMARY` in the run's default key-value store, and the same document
  under `RUN_SUMMARY-<runId>` in the named store `bluesky-posts-summary`.

### Memory

512 MB. There is no browser in the image: the source is plain JSON over HTTPS, and 512 MB
has been enough for every measured run.

### Local run

```bash
python -m src.main
```

# Actor input Schema

## `actors` (type: `array`):

Bluesky handles (bsky.app), dids or profile urls. Example: https://bsky.app/profile/bsky.app

## `maxPostsPerActor` (type: `integer`):

How many posts to take from each profile, newest first. Pagination is 50 posts per request, so the ceiling is 500.

## `includeReposts` (type: `boolean`):

Off by default: a repost is somebody else's post shown on this profile. The feed kind is reported in the feedKind field either way.

## `includeReplies` (type: `boolean`):

Off by default: replies are posts the profile wrote to somebody else. The field isReply says it either way.

## Actor input object example

```json
{
  "actors": [
    "bsky.app",
    "jay.bsky.team"
  ],
  "maxPostsPerActor": 100,
  "includeReposts": false,
  "includeReplies": false
}
```

# Actor output Schema

## `dataset` (type: `string`):

Every delivered post carries actorInput, postId, uri, url, text, createdAt, indexedAt, langs, isReply, feedKind, authorHandle, authorDid, authorName, profileHandle, profileDid, profileName, followersCount, postsCount, likeCount, repostCount, replyCount, quoteCount, bookmarkCount, embedType and status. Rows with a status other than OK carry a reason instead of data: no post id, no text, no author and no url.

## `summary` (type: `string`):

Counters: actorsRequested/attempted/read/empty/duplicate/failed/invalid/limited/cutByBudget, postsSeen/delivered/duplicate/filteredByKind/withoutText/capped, pagesRead/pagesFailed, pageErrors, rowsWritten, byStatus, chargedEvents, deliveredUncharged, chargeUncertain, writeErrors, billingActive, priceNote, priceEvent, maxPostsPerActor, includeReposts, includeReplies, counterMismatch, stopReason, datasetNote, finishedAt. Status codes: OK, INVALID_INPUT, DUPLICATE, NO_POSTS_FOUND, NOT_CHECKED_LIMIT, NOT_CHECKED_TIME, NOT_CHECKED_ERROR, NOT_CHECKED_CAP, NOT_CHECKED_BILLING, NOT_CHECKED_CHARGE_UNVERIFIED. DUPLICATE means the same profile arrived in another form (handle, did or url) and was read once. NOT_CHECKED_LIMIT is one free row per profile that reached maxPostsPerActor: more posts may exist at the source, and postsLimited counts those profiles, not the posts behind the limit. Stop reasons: spending-cap, billing-price-unknown, charge-error, dataset-write-error, deadline.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "actors": [
        "bsky.app",
        "jay.bsky.team"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("stas_k/bluesky-posts-api").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "actors": [
        "bsky.app",
        "jay.bsky.team",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("stas_k/bluesky-posts-api").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "actors": [
    "bsky.app",
    "jay.bsky.team"
  ]
}' |
apify call stas_k/bluesky-posts-api --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,stas_k/bluesky-posts-api"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/GLjBl98z1nRZeqTvs/builds/MY4eehHQotpOe3OO9/openapi.json
