# Bluesky Scraper - Posts, Profiles & Keyword Search (`dami_studio/bluesky-scraper`) Actor

Scrape Bluesky posts and profiles by handle. No login needed for a profile or an author's timeline. Keyword search is different: signed-out requests get a 403. To search the archive you need your own Bluesky app password. Without one the run watches the live stream. $2.00 per 1,000 posts.

- **URL**: https://apify.com/dami\_studio/bluesky-scraper.md
- **Developed by:** [Dami's Studio](https://apify.com/dami_studio) (community)
- **Categories:** Social media, Integrations, AI
- **Stats:** 1 total users, 0 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

$2.00 / 1,000 post returneds

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?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Bluesky Scraper

Bluesky serves a profile and an author's timeline to anyone who asks, straight off the public AT Protocol AppView, with no account involved. Two things this does: scrape a list of author handles (their profile plus their recent posts), or search for a keyword.

Author scraping needs no login. Keyword search is more complicated, and it's worth reading the next section before you buy.

### Read this before you use keyword search

Bluesky **stopped serving archive search to signed-out clients**. A logged-out request to the search endpoint gets a 403. That's their change, and no proxy or user agent gets around it.

So a keyword query has three possible lanes, and the row tells you which one you got in its `source` field:

| `source` | What it actually is | Needs an app password |
|---|---|---|
| `archive_search` | The real historical index. Everything Bluesky has. | Yes |
| `topic_feed` | Public Bluesky topic feeds whose own name or description matches your keyword, and their recent posts. Historical and on-topic, but it's a feed, not a search. | No |
| `live_capture` | Watches the public post stream for a set window and keeps posts matching your keyword. Only catches things posted **while the run is watching**. | No |

Left on `auto`, the actor uses the archive if you gave it credentials, tries topic feeds if you didn't, and falls back to live capture. Every keyless run also writes one uncharged notice row spelling out which lane it used, so you're never guessing.

If you want the full historical index, supply `blueskyIdentifier` and `blueskyAppPassword`. That's an app password from bsky.app → Settings → Privacy and security → App passwords, never your real account password. Set `searchMode` to `archive` and the run won't quietly substitute a lesser lane. Without credentials it says archive search is unavailable and returns nothing, uncharged.

Rows from `topic_feed` carry a `matchesQueryText` flag: true when the post text itself contains your keyword, false when the feed was on-topic but the post never used your exact word. Both happen.

### What you get

A post row:

```json
{
  "type": "post",
  "uri": "at://did:plc:zwzbnzr6dzo3lbr2wnfuggfi/app.bsky.feed.post/3mtlyz56v7s2b",
  "postUrl": "https://bsky.app/profile/testament3.blacksky.app/post/3mtlyz56v7s2b",
  "authorHandle": "testament3.blacksky.app",
  "authorName": "testament3",
  "authorDid": "did:plc:zwzbnzr6dzo3lbr2wnfuggfi",
  "text": "It sux that it's become enmeshed in my #LikeList, but I do enjoy how exasperated he gets...",
  "createdAt": "2026-08-21T14:49:26.435Z",
  "likeCount": 0,
  "repostCount": 0,
  "replyCount": 0,
  "quoteCount": 0,
  "langs": ["en"],
  "source": "live_capture",
  "matchedQuery": "music",
  "capturedDuringSecs": 40
}
```

A profile row, one per handle in `authorHandles`:

```json
{
  "type": "profile",
  "did": "did:plc:z72i7hdynmk6r22z27h6tvur",
  "handle": "bsky.app",
  "displayName": "Bluesky",
  "description": "official bluesky account",
  "followersCount": 1234567,
  "followsCount": 42,
  "postsCount": 890,
  "avatar": "https://cdn.bsky.app/img/avatar/plain/...",
  "banner": "https://cdn.bsky.app/img/banner/plain/...",
  "createdAt": "2023-04-12T04:53:57.057Z",
  "profileUrl": "https://bsky.app/profile/bsky.app"
}
```

Counts on a freshly captured post are usually zero. You caught it seconds after it was written and nobody has liked it yet. If you want engagement numbers, scrape the author's timeline later instead.

### Input

Scrape authors, no login:

```json
{
  "authorHandles": ["bsky.app", "jay.bsky.team"],
  "maxItems": 200
}
```

Search the full archive:

```json
{
  "searchQuery": "artificial intelligence",
  "searchMode": "archive",
  "blueskyIdentifier": "yourname.bsky.social",
  "blueskyAppPassword": "xxxx-xxxx-xxxx-xxxx",
  "maxItems": 500
}
```

Monitor a keyword in real time, no login:

```json
{
  "searchQuery": "product launch",
  "searchMode": "live",
  "liveWatchSecs": 300,
  "maxItems": 100
}
```

- `maxItems` — per query or per author handle, not a run total. Ceiling 1,000, default 100.
- `liveWatchSecs` — how long live capture watches, 10 to 900 seconds, default 60. It stops early once it hits `maxItems`. A common word fills up in seconds. A rare one may watch the whole window and return two posts.
- `authorHandles` — the leading `@` is optional.
- `searchQuery` — quoted `"phrases"` stay whole; several bare words must all appear.
- `proxyConfiguration` — off by default. The public API has no anti-bot, so you don't need it. Turn it on only if your region is being rate-limited.

You can also write each post into Notion as it finishes, via `notionConnector`. Results land in the dataset either way.

### Limits

- Live capture only sees the future. It cannot reach back for a post written before the run started.
- Archive search needs your own credentials. There is no shared account behind this actor.
- 1,000 items per query or author, per run.
- Author timelines return recent posts, not the complete lifetime history of the account.

### Billing

$2.00 per 1,000 posts.

Profile rows and notice rows are not charged. You pay for posts, deduplicated by post URI, so the same post appearing in two feeds bills once. A run that returns nothing costs nothing, which is the case worth knowing about for live capture on a rare keyword.

# Actor input Schema

## `searchQuery` (type: `string`):

Keyword(s) to match in Bluesky posts (e.g. "artificial intelligence"). Quoted "phrases" stay whole and several words must all appear. With a Bluesky handle + app password below this searches the full post archive; without one it captures matching posts live from Bluesky's public post stream, because Bluesky no longer serves archive search to signed-out clients. Leave empty to scrape specific authors instead.

## `searchMode` (type: `string`):

How to answer a search query. "Auto" uses the full archive when you supply an app password and captures live posts when you do not. "Live capture" always watches the public post stream. "Archive only" never substitutes live capture: without credentials it reports that archive search is unavailable and returns nothing (uncharged).

## `blueskyIdentifier` (type: `string`):

Your Bluesky handle or email, e.g. yourname.bsky.social. Needed ONLY to search the full post archive - Bluesky returns 403 for signed-out archive search. Author handles, profiles and live capture need no login.

## `blueskyAppPassword` (type: `string`):

An app password from bsky.app -> Settings -> Privacy and security -> App passwords. Never your account password. Needed ONLY to search the full post archive.

## `authorHandles` (type: `array`):

Bluesky handles to scrape (e.g. bsky.app, jay.bsky.team). For each handle the actor returns the author's profile plus their recent posts. The leading @ is optional. Leave empty if using a Search query instead.

## `liveWatchSecs` (type: `integer`):

How long live capture watches Bluesky's public post stream before it stops. It also stops early once it has collected "maxItems" matches. Common keywords fill up in seconds; a rare keyword needs a longer window.

## `maxItems` (type: `integer`):

Maximum number of posts to return per search query or per author handle. Pagination follows the API cursor until this limit is reached.

## `notionConnector` (type: `string`):

Optional. Write each post as a page into your Notion when the run finishes. Authorize a Notion connector once in Settings → API & Integrations → MCP connectors, then pick it here. Leave empty to skip (default) — results are always saved to the dataset regardless.

## `notionParentId` (type: `string`):

Optional. The Notion data source ID of the database to write into (only used if a Notion connector is set). Leave empty to create the pages privately in your workspace instead.

## `proxyConfiguration` (type: `object`):

Optional. The public Bluesky API needs no proxy and has no anti-bot, so leave this off by default. Only enable a proxy if you hit IP rate limits from your region.

## Actor input object example

```json
{
  "searchQuery": "artificial intelligence",
  "searchMode": "auto",
  "authorHandles": [
    "bsky.app"
  ],
  "liveWatchSecs": 60,
  "maxItems": 100,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `results` (type: `string`):

Scraped rows are stored in the default dataset (one row per result). Blocked/empty/error runs return a single uncharged diagnostic row instead.

# 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 = {
    "searchQuery": "artificial intelligence",
    "authorHandles": [
        "bsky.app"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("dami_studio/bluesky-scraper").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 = {
    "searchQuery": "artificial intelligence",
    "authorHandles": ["bsky.app"],
}

# Run the Actor and wait for it to finish
run = client.actor("dami_studio/bluesky-scraper").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 '{
  "searchQuery": "artificial intelligence",
  "authorHandles": [
    "bsky.app"
  ]
}' |
apify call dami_studio/bluesky-scraper --silent --output-dataset

```

## MCP server setup

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

```

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/jKNTqI9IE40gVxTaR/builds/U1KTZbJBulaGvBYWS/openapi.json
