# TeamBlind Topic, Company & Post Thread Extractor (`vexaloom-labs/teamblind-topic-company-and-post-thread-extractor`) Actor

Search TeamBlind posts by keyword, browse a topic or company feed, or fetch a single post thread with its comments. Returns post title, author handle, board, like/comment/view counts and timestamps for each record.

- **URL**: https://apify.com/vexaloom-labs/teamblind-topic-company-and-post-thread-extractor.md
- **Developed by:** [vexaloom-labs](https://apify.com/vexaloom-labs) (community)
- **Categories:** Social media, Lead generation, Jobs
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.49 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## TeamBlind Topics, Companies & Threads Scraper

TeamBlind (Blind) is an anonymous professional community where employees at Google, Amazon, Microsoft, Meta, Apple and thousands of other companies discuss layoffs, compensation, interviews and workplace life. This actor reads the public, signed-out pages and turns them into structured records: channel feeds, company discussions, keyword matches and full post threads.

No cookie, account, API key or proxy configuration is needed. The actor reads the same public HTML/JSON that a signed-out browser receives.

### Modes

| Mode | What it collects |
|---|---|
| `byTopic` | One or more channel feeds such as `tech`, `layoffs` or `software-engineering` |
| `byCompany` | A company's discussion list, starting with the full posts on its overview page and following older pages |
| `searchPosts` | Public post search for a keyword, sorted by relevance or recency |
| `byPost` | One or more post threads, including the comments TeamBlind shows to signed-out visitors |
| `byUrl` | Paste any supported TeamBlind URL; the actor detects post, channel, company or search |

### Filters and pagination

- **Sort** — `recent` (newest), `popular` / `top` (most engaged). Search supports `recent` and `top`.
- **Max records** — hard cap across posts, comments and errors (1–1,000).
- **Max pages** — listing pages followed per topic, company or search (1–100).
- **Comments** — turn the public comment tree into one record per comment, with `depth` and `parentCommentId`.
- **Company post details** — company overview pages already include full text; enable details to follow older company-page cards and fetch each post's body and engagement fields.

Pagination uses TeamBlind's own public "load more" action. When the site rotates its build, the actor rediscovers the action id and public key from the page's JavaScript, then retries.

### Record types

Each dataset row starts with `recordType`.

#### `post`

- `id`, `alias`, `articleType`, `title`, `content`, `contentRaw`, `contentLength`
- `contentIsPreview` — true when the source only exposed a preview of the body
- `memberNickname`, `authorCompany`, `jobTitle`
- `boardName`, `boardId`, `channelId`, `channelSlug`, `channelName`, `channelUrl`
- `companySlug`, `companyUrl`, `companyLogoUrl`
- `createdAt` (relative label), `datePublished` / `writedAt` / `updatedAt` (ISO where available)
- `likeCount`, `commentCount`, `viewCount`, `lastCommentCount`
- `isPoll`, `isHot`, `isAuth`, `isHighlight`, `isHiddenCompany`, `isNow`, `isWormhole`, `isCompanyTagged`
- `tags`, `wasCompanies`, `mentionCompanies`, `images`
- `pollId`, `pollType`, `pollParticipantCount`
- `commentSummary` — TeamBlind's own thread summary, when present
- `url`, `sourceType` (`topic` / `company` / `search` / `post`), `scrapedAt`
- Mode context: `topic`, `company` or `query`

#### `comment`

- `id`, `parentPostAlias`, `parentCommentId`, `content`, `memberNickname`, `authorCompany`
- `createdAt`, `writedAt`, `datePublished`
- `likeCount`, `replyCount`
- `isAuth`, `isOp`, `isCoOp`, `depth`, `images`
- `url`, `sourceType`, `scrapedAt`

#### `error`

Emitted when a page cannot be fetched or no public records exist: `url`, `reason`, optional `httpStatus`, plus the requested mode context.

Empty fields are omitted at every depth. No `null`, `""`, `[]` or `{}` is written to the dataset.

### Examples

Browse the Tech channel, newest first:

```json
{"mode": "byTopic", "topics": ["tech"], "sortBy": "recent", "maxItems": 50}
```

Browse Google discussions, most popular, one page of extra posts:

```json
{"mode": "byCompany", "companies": ["Google"], "sortBy": "popular", "maxItems": 50, "maxPages": 2}
```

Search for layoffs stories:

```json
{"mode": "searchPosts", "query": "layoffs", "sortBy": "popular", "maxItems": 100, "maxPages": 3}
```

Fetch a thread and its public comments:

```json
{"mode": "byPost", "postUrls": ["https://www.teamblind.com/post/rumors-on-microsoft-layoffs-q8isdyxu"], "includeComments": true, "maxItems": 60}
```

Paste any mix of TeamBlind URLs:

```json
{"mode": "byUrl", "postUrls": ["https://www.teamblind.com/channels/layoffs", "https://www.teamblind.com/company/Meta", "https://www.teamblind.com/search/anthropic"]}
```

### Backward compatibility

Older tasks keep running. The input keys `mode`, `query`, `topic`, `companies`, `postUrls`, `sortBy`, `includeComments` and `maxItems` are all still honoured. `newest` is treated as `recent`; `topic: "Career"` is normalised to the current public channel. Retired keys (`cookieHeader`, `country`, `autoEscalateOnBlock`, `proxyGroups`) are accepted but ignored with a log line — cookies and proxy setup are no longer required, and only the English `www.teamblind.com` site is supported.

Existing output field names did not change. New fields sit beside them.

### Limitations

- Keyword search covers only what TeamBlind's public search exposes; login-only groups and private company channels are unavailable.
- A thread page shows a capped set of the most relevant public comments. `commentCount` is TeamBlind's displayed total and can be larger than the comments a signed-out visitor receives. The actor reports every comment the public page exposes and never fabricates the rest.
- Older company-page cards sometimes carry only the title and metadata. Turn on **Fetch full post details** to follow those cards for full text and engagement.
- The Korean site (`/kr/`, `kr.teamblind.com`) is a separate legacy application and is not supported.
- If TeamBlind blocks the actor's IP, it automatically retries through Apify Proxy. No user-side proxy setup is required.

### Development

```bash
pip install -r requirements.txt
pytest -q
apify run --purge --input-file input.json
```

### Input reference

| Field | Type | Default | Description |
|---|---|---|---|
| `mode` | string | (no default; prefill only) | `byTopic` / `byCompany` / `searchPosts` / `byPost` / `byUrl` |
| `topics` | array | (no default; prefill only) | Channel slugs or `/channels/...` URLs |
| `companies` | array | (no default; prefill only) | Company slugs |
| `query` | string | (no default; prefill only) | Search keyword (search mode) |
| `postUrls` | array | `[]` | Post aliases/URLs, or mixed URLs in URL mode |
| `sortBy` | string | `recent` | `recent` / `popular` / `top`; legacy `newest` accepted |
| `includeComments` | boolean | `true` | Emit public comments in thread mode |
| `includePostDetails` | boolean | `true` | Follow company-page cards for full post details |
| `maxItems` | integer | `50` | Hard cap on emitted records (1–1000) |
| `maxPages` | integer | `5` | Listing pages per topic/company/search (1–100) |

Scheduled prefill: `mode=byTopic`, `topics=["tech"]`, `maxItems=3`, `maxPages=1`, comments/details off — the smallest run with output.

# Actor input Schema

## `mode` (type: `string`):

Pick the kind of TeamBlind page to collect.

## `topics` (type: `array`):

Channel slugs such as `tech`, `layoffs`, `software-engineering`, `relationships`, `stocks-investments`, or a full `/channels/...` URL. The actor normalises names and legacy display labels.

## `companies` (type: `array`):

Company slugs as used in TeamBlind URLs, for example `Google`, `Amazon`, `Meta`, `Microsoft`, `Apple`, `Netflix`, `Stripe`.

## `query` (type: `string`):

Keyword used by the search mode. TeamBlind's public search covers post titles and bodies.

## `postUrls` (type: `array`):

Post URLs (or 8-character aliases) for the thread mode. The URL mode also accepts channel, company and search URLs.

## `sortBy` (type: `string`):

`recent` shows newest posts, `popular`/`top` shows the most engaged posts. The legacy value `newest` is accepted and treated as `recent`.

## `includeComments` (type: `boolean`):

Emit each comment the public thread page exposes as its own record. Replies are included with a `depth` and `parentCommentId`.

## `includePostDetails` (type: `boolean`):

Company overview pages already carry the full text of the latest discussions. Turn this on to follow older company-page cards and fetch each post's full body and engagement fields.

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

Hard cap on emitted records. Posts, comments and error records all count toward the cap.

## `maxPages` (type: `integer`):

Maximum number of listing pages to follow per topic, company or search. The first page is free; each additional page uses TeamBlind's public load-more action.

## Actor input object example

```json
{
  "mode": "byTopic",
  "topics": [
    "tech"
  ],
  "companies": [
    "Google"
  ],
  "query": "layoffs",
  "postUrls": [],
  "sortBy": "recent",
  "includeComments": false,
  "includePostDetails": false,
  "maxItems": 3,
  "maxPages": 1
}
```

# Actor output Schema

## `records` (type: `string`):

Dataset of posts and public comments. Empty fields are omitted; `recordType` is always the first field.

# 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 = {
    "mode": "byTopic",
    "topics": [
        "tech"
    ],
    "companies": [
        "Google"
    ],
    "query": "layoffs",
    "postUrls": [],
    "sortBy": "recent",
    "includeComments": false,
    "includePostDetails": false,
    "maxItems": 3,
    "maxPages": 1
};

// Run the Actor and wait for it to finish
const run = await client.actor("vexaloom-labs/teamblind-topic-company-and-post-thread-extractor").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 = {
    "mode": "byTopic",
    "topics": ["tech"],
    "companies": ["Google"],
    "query": "layoffs",
    "postUrls": [],
    "sortBy": "recent",
    "includeComments": False,
    "includePostDetails": False,
    "maxItems": 3,
    "maxPages": 1,
}

# Run the Actor and wait for it to finish
run = client.actor("vexaloom-labs/teamblind-topic-company-and-post-thread-extractor").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 '{
  "mode": "byTopic",
  "topics": [
    "tech"
  ],
  "companies": [
    "Google"
  ],
  "query": "layoffs",
  "postUrls": [],
  "sortBy": "recent",
  "includeComments": false,
  "includePostDetails": false,
  "maxItems": 3,
  "maxPages": 1
}' |
apify call vexaloom-labs/teamblind-topic-company-and-post-thread-extractor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,vexaloom-labs/teamblind-topic-company-and-post-thread-extractor"
        }
    }
}
```

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/wDGXI4sqCbSbuG5xa/builds/oxXGV1ePAb5Nor6Gk/openapi.json
