# Threads Scraper: Posts, Profiles & Search (`fetch_cat/threads-profile-posts-scraper`) Actor

Scrape public Threads profiles, recent posts, direct posts, visible replies, keyword search, engagement metrics, and media. No login required.

- **URL**: https://apify.com/fetch_cat/threads-profile-posts-scraper.md
- **Developed by:** [Fetch Cat](https://apify.com/fetch_cat) (community)
- **Categories:** Social media, Automation, Developer tools
- **Features:** Limited permissions
- **Stats:** 20 total users, 6 monthly users, 98.3% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.10 / 1,000 result extracteds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
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

Collect public Threads profile details, recent profile posts, direct posts and visible replies, or keyword and hashtag search results. It reads the data available to logged-out visitors without asking for a Threads or Instagram login.

### Quick start

1. Choose **posts** mode and add a public handle such as `zuck`.
2. Start with a small post limit. Public availability can be lower than your requested limit.
3. Click **Start**, then open the dataset to inspect the returned profile and posts.

```json
{
  "mode": "posts",
  "usernames": [
    "zuck"
  ],
  "maxPosts": 10,
  "includeProfile": true
}
```

Prefer a video guide? This short Apify walkthrough shows you how to set up and run an Actor. It uses a different Actor, but the setup steps are the same.

https://youtu.be/1OW8gOqlZbY?t=25

### Ready-to-run examples

- [Collect @zuck’s public Threads posts](https://apify.com/fetch_cat/threads-profile-posts-scraper/examples/scrape-zuck-threads-posts) — export the requested public profile and its recent posts.
- [Build a Threads post preview dataset](https://apify.com/fetch_cat/threads-profile-posts-scraper/examples/threads-keyword-search) — collect a bounded public post sample for a downstream preview.
- [Scrape Threads posts with visible replies](https://apify.com/fetch_cat/threads-profile-posts-scraper/examples/threads-post-replies) — export a public post and its visible replies.

### What you get

| Mode | Input | Results |
| --- | --- | --- |
| Profile details | Handles or profile URLs | Profile identity, bio, followers, verification, avatar |
| Profile posts | Handles or profile URLs | Profile row plus recent posts and engagement |
| Direct posts and replies | Public post URLs | Requested posts plus their visible reply window |
| Search | Keywords or hashtags | Recent matching public posts with engagement and media |
| Auto | Any combination | Processes profiles, post URLs, and searches in one run |

Available post fields include text, timestamps, engagement counts, media, hashtags, mentions and author details. When present in the same public response, posts also include the author's avatar and privacy flag, editing/sponsorship/metric-visibility flags, reply-to and root-author context, and structured image/video attachments with positive dimensions. Carousel children remain grouped under their post. The carousel root is not an extra attachment. No media downloads or additional profile requests are made for these fields. Profile rows can include identity, biography, follower count, verification, avatar and a source privacy flag.

### Who is it for?

- Social media analysts comparing public Threads activity and engagement
- Brand and PR teams monitoring public conversations and account posts
- Creator marketers researching public profiles and content patterns
- Developers connecting Threads datasets to APIs, schedules, webhooks, or AI agents

### Common workflows

**Review a few known profiles.** Collect recent public posts from selected handles and export their text, timestamps and engagement fields. Compare the returned samples in a spreadsheet or ask an assistant to summarize their themes. The logged-out window is limited, so this is not a complete posting history.

**Research a distinctive keyword.** Run search mode with a brand name or specific hashtag. Keep the source post URLs in your review table and examine the returned matches before classifying them. Search exposes a small recent public window rather than every mention.

**Read a visible conversation sample.** Supply a known public post URL with a bounded reply limit. Use the returned reply text for your own qualitative review. Hidden or unavailable replies are not recovered, and a sample does not establish the opinion of the whole audience.

### Input settings

| Setting | JSON key | Description |
| --- | --- | --- |
| Mode | `mode` | `posts`, `profile`, `post`, `search`, or `auto` |
| Usernames or profile URLs | `usernames` | Public handles, `@handles`, or Threads profile URLs |
| Legacy profile inputs | `profileUrlsOrUsernames` | Backward-compatible alias for existing tasks and API clients |
| Post URLs | `postUrls` | Direct public Threads post URLs |
| Search queries | `searchQueries` | Keywords or hashtags for public Threads search |
| Maximum posts | `maxPosts` | Requested post limit per username or search. Public availability may be lower |
| Legacy maximum posts | `maxPostsPerProfile` | Backward-compatible alias for existing API clients and tasks |
| Include profile | `includeProfile` | Save a profile row in profile-post mode |
| Include replies | `includeReplies` | Request replies below direct post URLs. Initial visible replies can still appear when false. Use `maxRepliesPerPost: 0` for a root-post-only cap |
| Maximum replies | `maxRepliesPerPost` | Reply-row limit per direct post. Zero requests only the root post |
| Posted at or after | `postedAfter` | Inclusive ISO 8601 timestamp filter |
| Posted before | `postedBefore` | Exclusive ISO 8601 timestamp filter |
| Connection | `connectionMode` | `automatic` (default) or `direct`. See field help for routing and platform costs |
| Existing proxy settings | `proxyConfiguration` | Optional managed settings or customer pool. Explicit settings override Connection |

Supply at most 100 combined inputs across all input lists, with at most 2,048 characters per input (200 for a search query). Each run uses at most 60 request attempts, each with at most three redirects, and a 300-second processing envelope including shutdown time. Collection stops with an explicit failure if a response or retained-output safety limit is exceeded. Saved results remain accessible. Memory is capped at 512 MiB.

Direct-post rows are matched to the requested post code; unrelated recommendations and home-feed posts are not substitutes. If Threads redirects a public post link to its home feed, the run records that the link returned no target post without assuming deletion or privacy.

A max-cost limit too small for startup plus one result stops collection before target requests or manual charges. A short customer timeout stops new work early, preserves saved rows, and reports the limit in the run status and `RUN_SUMMARY`; allow at least 45 seconds for useful work. Genuine extraction, storage and billing failures are still reported.

A row without a usable timestamp remains eligible through date filters. Check returned timestamps before treating an export as a strict reporting window.

#### Search example

```json
{
  "mode": "search",
  "searchQueries": ["artificial intelligence", "#marketing"],
  "maxPosts": 20
}
```

#### Direct-post example

```json
{
  "mode": "post",
  "postUrls": ["https://www.threads.com/@zuck/post/DakyAavlKLZ"],
  "includeReplies": true,
  "maxRepliesPerPost": 20
}
```

### Output data

| Group | Fields |
| --- | --- |
| Record identity | `itemType`, `sourceUrl`, `scrapedAt` |
| Author/profile | `username`, `displayName`, `userId`, `isVerified`, `profileUrl`, `bio`, `followerCount`, `avatarUrl`, `isPrivate` |
| Post identity | `postId`, `shortcode`, `postUrl`, `parentPostId`, `rootPostId` |
| Content | `text`, `timestamp`, `mediaType`, `mediaUrls`, `media`, `hashtags`, `mentions`, `externalUrls` |
| Engagement | `likeCount`, `replyCount`, `repostCount`, `quoteCount` |
| Classification | `isReply`, `isRepost`, `isQuotePost`, `replyToId` |
| Conversation | `replyToUsername`, `replyToUserId`, `rootAuthorUsername` |
| Source flags | `isEdited`, `isPaidPartnership`, `metricsHidden` |
| Search | `searchQuery` |

`media` contains at most 50 actual image/video attachments with `type`, `url`, zero-based `index`, optional `carouselGroup` (the parent post ID), and positive `width`/`height` when exposed. `mediaUrls` keeps its existing meaning. `replyToId` retains its legacy author-or-post identifier semantics. Use the explicit new author fields when identifying a conversation participant. Missing flags and context stay absent, not inferred false. `isPrivate` describes a flag exposed in a public payload, not access to private content. No language, view counts, alt text or video duration is promised. Use the **Complete dataset** output or JSON export for all optional fields. The existing table views show selected columns.

Some missing engagement counts are represented as zero. A zero is not always a measured zero. Missing timestamps can remain eligible through date filters, and profile rows do not establish a dated activity window.

#### Download your results

Open your run's dataset, choose **Export** and select JSON, CSV or Excel. JSON keeps nested fields together. CSV and Excel are useful when you want to review the records in a spreadsheet.

See [Apify's download and export guide](https://docs.apify.com/storage/dataset#apify-console) for the available formats and field options.

### Pricing

This Actor uses pay-per-event pricing. The `result` event is charged once for each saved profile, post, reply, or search-result row, not per field or media attachment. Added fields have no separate event fee, although larger exports add storage and transfer usage. `RUN_SUMMARY` and `PENDING_WORK` are not dataset results.

**Automatic-start pricing, when effective:** the platform charges `apify-actor-start` once per started run at the supported allocation of up to 512 MiB, plus `result` for each saved row. See the live Pricing tab for your plan's startup and result rates.

The automatic startup fee can apply even when a run returns no rows or later fails. It is not an extra fee on top of the previous custom startup event. During any required pricing notice, runs using the previous contract retain their existing rates and charge custom `start` only after the first saved result. The run's effective pricing determines which single startup contract applies. Scheduled prices are not current prices. Check the live Pricing tab for the actual rates and effective date before starting a run.

See the Actor's [live Pricing tab](https://apify.com/fetch_cat/threads-profile-posts-scraper/pricing) for current rates. Proxy traffic, storage, and other Apify platform usage may add cost depending on your account and configuration.

### Tips for best results

- **Start with one known profile.** Check the available logged-out post window before adding more handles.
- **Choose the mode that matches your input.** `posts` (the form/API default) and `profile` require `usernames` or `profileUrlsOrUsernames`; `post` requires `postUrls`; `search` requires `searchQueries`. Choose `auto` to process all supplied input types. With no valid targets for the selected mode, the run completes without collection and explains how to correct the input in its log warning and `RUN_SUMMARY`. No result charges apply, but an automatic platform startup charge may still apply. Use a direct known post for reply samples and a distinctive query for search.
- **Treat limits as ceilings.** Raising `maxPosts` cannot reveal public history that Threads does not expose.
- **Check dates and metrics.** Missing timestamps remain eligible and missing counts can appear as zero.
- **Use only proxy groups available to your account.** Keep your existing authorized configuration when repeating a task.

### Limits and caveats

Logged-out profiles typically expose a small recent window, roughly 15 non-reply posts. Search also exposes a limited recent window. Raising a limit does not create older history or inaccessible replies.

Explicit login-gated and missing targets can complete successfully with no rows and a reason in `RUN_SUMMARY`. An HTTP restriction alone does not prove that a profile is private or deleted. Completed searches or date windows without usable rows can also succeed empty. Mixed batches retain useful saved results. Missing parser payloads and blocking remain actionable defects. An all-empty batch containing these defects fails. Systemic service, configuration, validation, storage and billing errors remain fatal, including after useful rows were saved. Threads can change or rate-limit its public routes. The Actor uses bounded fallback for request failures. If the processing deadline leaves work incomplete, the run fails and preserves saved results. Remaining inputs are recorded in `PENDING_WORK` when possible, but are not automatically resumed. Resurrection of a run that has already begun extraction is refused to prevent replaying output or charges. A normal automatic startup count alone does not indicate earlier extraction. This conservative restart stop does not guarantee atomic exactly-once recovery across storage and billing interruptions. Inspect saved rows before explicitly starting another run. A user charge limit can stop collection earlier while keeping the results already saved.

### Automation and integrations

#### Save your settings for next time

Once you have an input that works for you, [save it as an Apify task](https://docs.apify.com/actors/running/tasks). This keeps your settings together so you can use them again without filling in the form from scratch.

#### Run on a schedule

Need fresh results regularly? You can [schedule the Actor or a saved task](https://docs.apify.com/actors/running/schedules) to run at a time that suits you.

Each scheduled run collects the data again. If you want to compare results or highlight changes, add that step in your own workflow.

#### Send results to your other tools

Use **n8n, Make or Zapier** to connect this scraper to the rest of your workflow. For example, you could pass its results to an AI assistant or add records to a spreadsheet. Follow the [Apify integration guides](https://docs.apify.com/integrations) for your chosen tool.

For a custom connection, an [Apify webhook](https://docs.apify.com/integrations/webhooks) can notify your app when a run finishes or fails. Your app can then fetch the results or handle the failure.

### API usage

Want to collect this data from your own app or automation? The examples below send input to the scraper and show how to collect its results.

The Node.js and Python examples wait for the run to finish before reading its results. The cURL example starts the run and returns its details. Wait for that run to finish, then use its `defaultDatasetId` to fetch the results.

For setup instructions, see Apify's [JavaScript client guide](https://docs.apify.com/api/client/js), [Python client guide](https://docs.apify.com/api/client/python) and [Actor runs API reference](https://docs.apify.com/api/v2/acts-runs-post).

#### cURL

```bash
curl -X POST "https://api.apify.com/v2/acts/fetch_cat~threads-profile-posts-scraper/runs" \
  -H "Authorization: Bearer $APIFY_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{"mode":"posts","usernames":["zuck"],"maxPosts":10,"includeProfile":true}'
```

#### Node.js

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

const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const input = {
  "mode": "posts",
  "usernames": [
    "zuck"
  ],
  "maxPosts": 10,
  "includeProfile": true
};
const run = await client.actor('fetch_cat/threads-profile-posts-scraper').call(input);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);
```

#### Python

```python
import json
import os
from apify_client import ApifyClient

client = ApifyClient(os.environ['APIFY_TOKEN'])
run_input = json.loads('''{
  "mode": "posts",
  "usernames": [
    "zuck"
  ],
  "maxPosts": 10,
  "includeProfile": true
}''')
run = client.actor('fetch_cat/threads-profile-posts-scraper').call(run_input=run_input)
items = client.dataset(run['defaultDatasetId']).list_items().items
print(items)
```

### MCP and AI agents

You can ask your AI assistant to collect data with **Threads Scraper: Posts, Profiles & Search** and help you work with the results. The scraper returns the data, and your assistant can then summarize it, compare records or prepare notes.

Connect your assistant through the [Apify MCP server](https://mcp.apify.com/). MCP gives your assistant a way to find this scraper, run it and read the results. Follow the [official setup and sign-in guide](https://docs.apify.com/mcp) for your app.

#### Easier setup with an Apify plugin

If you use a supported coding assistant, the [official Apify plugin](https://docs.apify.com/agents/plugins) can set up the connection for you. It connects your assistant to Apify and includes instructions for common tasks. Follow the guide for your particular app.

#### Use Apify AI in Console

Prefer to keep everything in Apify? Open [Apify AI in Console](https://docs.apify.com/account/apify-ai) and ask it to find Fetch Cat's **Threads Scraper: Posts, Profiles & Search**. You can describe the data you want and ask questions about the results.

Apify AI is currently in beta. It asks for confirmation before starting an Actor, and normal run charges apply.

#### Choose your assistant

- **Claude and Claude Code (Anthropic):** [Apify setup guide](https://docs.apify.com/integrations/claude).
- **ChatGPT and Codex (OpenAI):** [Apify setup guides](https://docs.apify.com/integrations/openai).
- **Grok Bot (xAI):** [Apify plugin guide](https://docs.apify.com/integrations/grok-bot).
- **Gemini CLI (Google):** [MCP server setup guide](https://geminicli.com/docs/tools/mcp-server/). Use the server URL below with the HTTP configuration supported by Gemini CLI.

#### Connect just this scraper

To keep your setup focused on this scraper, add this server configuration to a compatible MCP client:

```json
{
  "mcpServers": {
    "apify": {
      "url": "https://mcp.apify.com?tools=fetch_cat/threads-profile-posts-scraper"
    }
  }
}
```

Sign in to Apify when your client asks. If your client uses a Bearer token instead, follow its setup guide and keep the token in its secure configuration. Configuration formats vary by app, so use the linked guide if your client needs a different format.

#### Use Apify's general server

Already connected to the general Apify MCP server at `https://mcp.apify.com`? You can use it to find this scraper without adding another server. Ask your assistant to use **Threads Scraper: Posts, Profiles & Search** by Fetch Cat, or give it the identifier `fetch_cat/threads-profile-posts-scraper`.

Your assistant can check the available settings and retrieve the results from the returned run. If the run is still working, it should follow that run rather than start it again. Both connection options use Apify's hosted service.

#### Example requests

- “Collect up to 10 recent public Threads posts from @zuck and include the available profile details.”
- “Search the recent public Threads window for this distinctive brand name and return source-linked matches.”
- “Collect this public post and up to 10 visible replies, then summarize the returned conversation sample.”

Normal Apify charges apply. Check the [live Pricing tab](https://apify.com/fetch_cat/threads-profile-posts-scraper/pricing) before asking your assistant to run a larger batch.

### Pay with x402

If your AI agent has a funded wallet, it can pay for Apify usage through [x402](https://docs.apify.com/integrations/x402). This experimental option lets an agent use Apify without a conventional account.

[Apify AGI](https://agi.apify.com/) provides a prepaid API token with a spending cap after payment. Your agent can use that token to run this scraper through the Apify API or an authenticated MCP connection.

Some MCP setups also support paying for each request directly. That is a different payment option, so check the official guide for its availability.

Follow the official guide for wallet setup, supported payment options and current terms. Apify handles the payments. Keep wallet keys and payment tokens in your agent's secure configuration.

#### Other ways for agents to pay

Apify also supports **MPP** for prepaid access through AGI and **Skyfire** for eligible Actors. If your agent already uses one of these, see the [agentic payment guide](https://docs.apify.com/agents/payments) to choose the right setup.

### FAQ

**Does this require an account?**
No. It reads public logged-out data and does not ask for login cookies or credentials.

**Can it search by keyword or hashtag?**
Use `mode: "search"` with `searchQueries`. The recent public window may contain fewer rows than `maxPosts`.

**How do I retrieve replies or only the root post?**
Use a direct post URL with `includeReplies: true` and a bounded `maxRepliesPerPost`. Initial visible replies can still be returned when `includeReplies` is false. Use `maxRepliesPerPost: 0` for a root-post-only cap.

**What happens when one target fails?**
Useful rows remain accessible and `RUN_SUMMARY` records source outcomes. Explicit unavailable targets and completed no-match windows can succeed empty. An all-empty batch with extraction defects still fails. Systemic service, setup, validation, storage and billing errors remain fatal even after another target saved useful rows.

### Related Actors

- [Threads Replies Scraper](https://apify.com/fetch_cat/threads-replies-scraper) — export public Threads conversation and reply records.
- [TikTok Video Scraper](https://apify.com/fetch_cat/tiktok-video-scraper) — retrieve public TikTok video metadata and engagement.
- [TikTok Profile Scraper](https://apify.com/fetch_cat/tiktok-profile-scraper) — collect public creator profile details.
- [Reddit Scraper](https://apify.com/fetch_cat/reddit-scraper) — retrieve posts and discussions by community or query.
- [Bluesky Profile Feed Scraper](https://apify.com/fetch_cat/bluesky-profile-feed-scraper) — collect public Bluesky profile metadata and recent posts from handles or DIDs.

### Support and feedback

For custom additions or integrations, email <hello@fetchcat.dev>.

Found an error or have a feature request? [Open an issue](https://apify.com/fetch_cat/threads-profile-posts-scraper/issues) with the run URL, a non-sensitive input example and what you expected.

Need help sharing it? See [Apify’s guide to sharing a run when reporting an issue](https://docs.apify.com/account/collaboration/general-resource-access#automatically-sharing-runs-via-actor-issues). Sharing a run can give the developer access to its input, logs and results, so use a run that contains no sensitive data. Please leave out API tokens, passwords, cookies, private documents and personal data. Use a public sample URL or a redacted example instead.

Tried this scraper? We'd love to hear how it worked for you. [Leave a review](https://apify.com/fetch_cat/threads-profile-posts-scraper/reviews) to help others choose the right tool and help us improve it. Your feedback means a lot to us.

Made with care for curious people, AI agents and the possibilities in data. ♥

# Changelog

This Actor's version history is a separate document: https://apify.com/fetch_cat/threads-profile-posts-scraper/changelog.md

# Actor input Schema

## `usernames` (type: `array`):

Public Threads handles or profile URLs. Used by Profile details and Profile posts modes. At most 100 combined inputs across all input lists.

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

Full public post URLs such as https://www.threads.com/@zuck/post/SHORTCODE. Direct post mode returns each post and can include its visible replies.

## `searchQueries` (type: `array`):

Search terms such as artificial intelligence, your brand name, or #marketing. Threads exposes a limited recent public search window.

## `maxPosts` (type: `integer`):

Maximum post rows per username or search query. Public logged-out pages may expose fewer rows than this limit.

## `includeProfile` (type: `boolean`):

Save one profile row before post rows in Profile posts mode.

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

In Direct posts and replies mode, request additional visible replies. The initial visible reply window can still be returned when false. Set maxRepliesPerPost to 0 for only the root post.

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

Profile details and Profile posts require usernames or legacy profile inputs; Direct posts requires postUrls; Keyword search requires searchQueries. Auto processes every supplied input type, including legacy profile inputs. If no valid inputs match the selected mode, the run performs no collection and explains the correction in a warning and RUN_SUMMARY.

## `profileUrlsOrUsernames` (type: `array`):

Backward-compatible alias for usernames. Existing API calls and saved tasks can keep using this field.

## `maxPostsPerProfile` (type: `integer`):

Backward-compatible alias for maxPosts. This legacy field takes precedence when both are supplied, including when maxPosts was added by a form default.

## `maxRepliesPerPost` (type: `integer`):

Maximum visible reply rows saved for each direct post URL.

## `postedAfter` (type: `string`):

Optional inclusive ISO 8601 date or timestamp, for example 2026-07-01T00:00:00Z.

## `postedBefore` (type: `string`):

Optional exclusive ISO 8601 date or timestamp. Must be later than Posted at or after.

## `connectionMode` (type: `string`):

Automatic preserves the existing managed-proxy-first strategy, with bounded retries and direct fallback. Managed proxy traffic may add platform costs. Direct makes only direct requests, with no paid fallback. Explicit proxyConfiguration settings take precedence over this choice, including saved opt-outs and customer pools. Omitted settings use Automatic.

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

Optional legacy managed settings or customer proxy pool. When supplied, these settings override Connection, including its form default. Existing useApifyProxy:false stays direct unless a customer pool is supplied. Customer pools retain their existing bounded rotation and direct fallback. Named groups require account access. Leave this field absent to use Connection. Invalid settings fail rather than enabling another paid route.

## Actor input object example

```json
{
  "usernames": [
    "zuck",
    "instagram"
  ],
  "postUrls": [
    "https://www.threads.com/@zuck/post/DakyAavlKLZ"
  ],
  "searchQueries": [
    "artificial intelligence"
  ],
  "maxPosts": 20,
  "includeProfile": true,
  "includeReplies": true,
  "mode": "posts",
  "maxRepliesPerPost": 20,
  "connectionMode": "automatic"
}
```

# Actor output Schema

## `runSummary` (type: `string`):

No description

## `profiles` (type: `string`):

No description

## `posts` (type: `string`):

No description

## `replies` (type: `string`):

No description

## `searchResults` (type: `string`):

No description

## `complete` (type: `string`):

No description

# 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 = {
    "usernames": [
        "zuck",
        "instagram"
    ],
    "postUrls": [
        "https://www.threads.com/@zuck/post/DakyAavlKLZ"
    ],
    "searchQueries": [
        "artificial intelligence"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("fetch_cat/threads-profile-posts-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 = {
    "usernames": [
        "zuck",
        "instagram",
    ],
    "postUrls": ["https://www.threads.com/@zuck/post/DakyAavlKLZ"],
    "searchQueries": ["artificial intelligence"],
}

# Run the Actor and wait for it to finish
run = client.actor("fetch_cat/threads-profile-posts-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 '{
  "usernames": [
    "zuck",
    "instagram"
  ],
  "postUrls": [
    "https://www.threads.com/@zuck/post/DakyAavlKLZ"
  ],
  "searchQueries": [
    "artificial intelligence"
  ]
}' |
apify call fetch_cat/threads-profile-posts-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,fetch_cat/threads-profile-posts-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/fi4ifwrzHSM6yC6Tb/builds/gc775hWQuCu1jZZgj/openapi.json
