# X (Twitter) Content Publisher – Post, Reply, Quote & Manage (`b2b_leads/x-content-publisher`) Actor

Publish and manage X (Twitter) content from your own account in bulk. Create posts, replies, and quotes with media, like, retweet, bookmark, follow, update your profile, manage lists, and post to communities. Safe pacing, action limits, and per-action results. Bring your auth token and proxy.

- **URL**: https://apify.com/b2b\_leads/x-content-publisher.md
- **Developed by:** [Chidubem Aneke](https://apify.com/b2b_leads) (community)
- **Categories:** Social media, Lead generation, MCP servers
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $10.00 / 1,000 automations

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/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use 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

## X Content Publisher

Publish and manage content on **X (Twitter)** from your own account — safely and in bulk. This Actor is the **write** counterpart to a read/scraping Actor: instead of collecting data, it performs actions such as posting, replying, liking, following, updating your profile, managing lists, and posting to communities.

You choose which actions to run with simple checkboxes, connect your account, and the Actor performs them and reports the result of each one.

---

### What it can do

| Group | Actions |
| --- | --- |
| **Posts** | Create post, reply, quote, delete — each with optional media (up to 4 items) |
| **Engagement** | Like / unlike, retweet / undo, bookmark / remove, follow / unfollow |
| **Profile** | Update name, bio, location, website; change avatar and banner |
| **Lists** | Create a list, add members, remove members |
| **Communities** | Create post / reply / quote inside a community, join, leave |

Each group is a checkbox — enable only what you need.

---

### Safety first

Writing to a social account is destructive and irreversible, so this Actor is conservative by design:

- **One row per action.** The dataset contains a flat record for every attempted action with its `status` (`success`, `failed`, or `skipped`), the resulting post ID/URL, and a clear message on failure.
- **One bad action never aborts the run.** Errors are collected per action; the run keeps going and finishes with a summary.
- **Max actions cap.** `maxActions` limits how many actions a single run will attempt — a guard against accidental bulk writes.
- **Pacing.** `delayBetweenActionsMs` spaces out writes for account safety.
- **Reactive retries only.** Rate limits and temporary server errors are retried with backoff. Content-creating actions are **never** retried after they are sent, to avoid duplicate posts.
- **Secrets are never logged.** Your session token and proxy are redacted everywhere.

---

### Requirements

Every action acts on **your own account**, so you connect your account at run time. Both of the following are required.

#### 1. Your X auth token

The Actor logs in using your account's `auth_token` cookie.

**Easiest way (Chrome extension):**

1. Install a cookie viewer such as **[Cookie-Editor](https://chromewebstore.google.com/detail/cookie-editor/hlkenndednhfkekhgcdicdfddnkalmdm)** or **[EditThisCookie](https://chromewebstore.google.com/)** from the Chrome Web Store.
2. Open and log in to **[x.com](https://x.com)**.
3. Click the extension icon, find the cookie named **`auth_token`**, and copy its value.
4. Paste it into the **X auth token** field.

**Manual way (no extension):**

1. Log in to **x.com** in Chrome.
2. Press **F12** → open the **Application** tab.
3. In the left sidebar: **Cookies → https://x.com**.
4. Find **`auth_token`** and copy its **Value**.

> Keep this token private — anyone with it can act as your account. It's stored as a secret and never logged.

#### 2. A sticky proxy

Provide a stable, user-owned proxy in four simple fields:

- **Proxy host** — e.g. `proxy.example.com`
- **Proxy port** — e.g. `8080`
- **Proxy username**
- **Proxy password**

You get these from your proxy provider's dashboard. (Advanced users can instead paste a full `host:port@user:pass` string in the optional **Full proxy string** field.)

> Use a **sticky** (non-rotating) proxy whose IP stays consistent. Rotating/residential proxy pools are never used for a logged-in account because switching IPs triggers security challenges. A stable IP keeps your session healthy.

---

### Quick start

1. Fill in your **X auth token** and **proxy** fields (see Requirements above).
2. Enable a group (e.g. **Posts**) and fill the simple fields — just type your post text, no JSON needed:

```json
{
  "authToken": "your_auth_token",
  "proxyHost": "proxy.example.com",
  "proxyPort": "8080",
  "proxyUsername": "myuser",
  "proxyPassword": "mypass",
  "enablePosts": true,
  "postText": "Hello from my Actor 👋"
}
````

3. Run it — each dataset row shows the outcome of an action, including the new post's ID and URL.
4. Start with a small number of items and the default `maxActions` cap to stay safe.

> **How the form works:** each feature has a master toggle (e.g. *Enable Posts*) and is split into small sections — Posts is broken into *Create a post*, *Reply*, *Quote*, and *Delete*; Lists into *Create*, *Add members*, *Remove members*; Communities into *Post* and *Join / leave*. Tick the toggle, then fill **only** the section(s) you want to use. Any field left blank is skipped, and you can combine several actions in one run.

***

### Input reference

#### Global

| Field | Type | Default | Description |
| --- | --- | --- | --- |
| `authToken` | string (secret) | — | Your `auth_token` cookie. **Required.** |
| `proxyHost` / `proxyPort` | string (secret) | — | Your sticky proxy address and port. **Required.** |
| `proxyUsername` / `proxyPassword` | string (secret) | — | Your proxy credentials. **Required.** |
| `userProxy` | string (secret) | — | Advanced: full `host:port@user:pass` string (overrides the fields above). |
| `maxActions` | integer | `50` | Hard cap per run (`0` = unlimited). |
| `delayBetweenActionsMs` | integer | `1500` | Pause after each action. |
| `stopOnAuthOrProxyError` | boolean | `true` | Stop the run on a session/proxy failure. |
| `includeRaw` | boolean | `false` | Attach the raw upstream response to each row. |

Most groups offer **simple form fields** for the common case (one post, one reply, one list, etc.) plus an **Advanced (JSON)** option for doing many at once. Both work together — items from the advanced arrays are added on top of the simple fields.

#### Posts (`enablePosts`)

Simple fields:

- New post — `postText`, `postMediaUrls?`, `postReplyOptionMode?`, `postDisableLinkPreview?`
- Reply — `replyToTweet` (ID or URL), `replyText`, `replyMediaUrls?`
- Quote — `quoteTweet` (ID or URL), `quoteUsername?`, `quoteText`, `quoteMediaUrls?`
- `deleteTweetIds`, `deleteTweetUrls` — lists

Advanced (bulk, JSON):

- `createPosts` — `[{ text, mediaUrls?, replyOptionMode?, disableLinkPreview? }]`
- `replies` — `[{ tweetId | tweetUrl, text, mediaUrls? }]`
- `quotes` — `[{ tweetId | tweetUrl, quotedUsername?, text, mediaUrls? }]`

#### Engagement (`enableEngagement`)

- `like` / `unlike` / `retweet` / `unretweet` / `bookmark` / `unbookmark` — each takes `*TweetIds` and `*TweetUrls`
- `follow` / `unfollow` — each takes `*UserIds` and `*Usernames` (@handles are resolved automatically)

#### Profile (`enableProfile`)

- `profileName`, `profileBio`, `profileLocation`, `profileWebsite`, `avatarUrl`, `bannerUrl` — only non-empty fields are changed.

#### Lists (`enableLists`)

Simple fields:

- New list — `newListName`, `newListDescription?`, `newListPrivate?`
- Add members — `addMembersListId` + `addMemberUsernames` (@handles)
- Remove members — `removeMembersListId` + `removeMemberUsernames` (@handles)

Advanced (bulk, JSON):

- `createLists` — `[{ name, description?, isPrivate? }]`
- `addListMembers` / `removeListMembers` — `[{ listId, userId | username }]`

#### Communities (`enableCommunities`)

Simple fields:

- Community post — `communityId`, `communityPostText`, `communityPostMediaUrls?`
- `joinCommunityIds`, `leaveCommunityIds` — lists

Advanced (bulk, JSON):

- `communityPosts` — `[{ communityId, text, mediaUrls? }]`
- `communityReplies` — `[{ communityId, tweetId | tweetUrl, text, mediaUrls? }]`
- `communityQuotes` — `[{ communityId, tweetId | tweetUrl, quotedUsername?, text }]`

#### Media

Provide media per item via:

- `mediaUrls`: a list of public image/video/GIF URLs (simplest), or
- `media`: an array where each item uses exactly one source:
  - `{ "url": "https://…" }` — fetched and uploaded for you,
  - `{ "data": "<base64>", "type": "image/png" }` — base64 upload with a MIME type, or
  - `{ "media_id": "1971008286821380096" }` — a media id you already uploaded with the **same** account (advanced).

Up to 4 media items per post (or 1 video).

***

### Output

Each attempted action is one dataset row:

```json
{
  "actionType": "create_post",
  "status": "success",
  "apiAction": "create_tweet",
  "inputRef": "Hello from my Actor 👋",
  "targetId": null,
  "resultId": "1799999999999999999",
  "resultUrl": "https://x.com/you/status/1799999999999999999",
  "plannedRequest": { "endpoint": "create-post", "text": "Hello from my Actor 👋" },
  "message": null,
  "timestamp": "2026-07-06T12:00:00.000Z"
}
```

Field notes:

- `status` — one of `success`, `failed`, or `skipped`.
- `apiAction` — the platform action that was performed (e.g. `create_tweet`, `follow`, `add_to_list`).
- `targetId` — the id your input pointed at (tweet/user/list/community).
- `resultId` — the primary id created or affected: a **new tweet id** for posts/replies/quotes, a **new list id** for list creation, your **account id** for profile updates, or the affected id for engagement.
- `resultUrl` — the canonical `x.com` link when the action created a post.
- `plannedRequest` — a secret-free record of what was sent.

A per-run summary (enabled groups, counts by status and action type, and non-fatal errors) is written to the key-value store record `OUTPUT`.

***

### 📬 Contact & custom projects

Need something built? I take on custom work, including:

- **Web scraping & data extraction** — Apify Actors, crawlers, and automation for any site or API.
- **Web apps** — dashboards, tools, and full-stack applications of any kind.
- **Automation & integrations** — bots, pipelines, and workflow automation.

Reach out — happy to discuss your project:

- **Email:** <dubem115@gmail.com>
- **GitHub:** [github.com/DrunkCodes](https://github.com/DrunkCodes)

# Actor input Schema

## `authToken` (type: `string`):

Your X account login token (the 'auth\_token' cookie). Required — the Actor acts on your account. HOW TO GET IT: 1) Log in to x.com in Chrome. 2) Press F12 → open the 'Application' tab → Cookies → https://x.com. 3) Copy the value of the cookie named 'auth\_token'. Easier option: install the free 'Cookie-Editor' or 'EditThisCookie' Chrome extension, click it on x.com, and copy the 'auth\_token' value. Treated as a secret and never logged.

## `proxyHost` (type: `string`):

Your proxy server address, e.g. proxy.example.com or 123.45.67.89. From your proxy provider's dashboard.

## `proxyPort` (type: `string`):

Your proxy port number, e.g. 8080. From your proxy provider's dashboard.

## `proxyUsername` (type: `string`):

The username/login for your proxy. From your proxy provider's dashboard.

## `proxyPassword` (type: `string`):

The password for your proxy. From your proxy provider's dashboard. Treated as a secret and never logged.

## `userProxy` (type: `string`):

Advanced: instead of the four fields above, paste a full proxy string in host:port@user:pass format (e.g. proxy.example.com:8080@myuser:mypass). If set, this overrides the separate fields.

## `maxActions` (type: `integer`):

Hard cap on how many actions this run will attempt. Extra actions are marked 'skipped'. Set 0 for unlimited (not recommended). Protects against accidental bulk writes.

## `delayBetweenActionsMs` (type: `integer`):

Pause added after each action to space out writes for account safety. 0 disables pacing.

## `stopOnAuthOrProxyError` (type: `boolean`):

If a session (expired token) or proxy error occurs, stop the rest of the run instead of hammering a dead session. Remaining actions are marked 'skipped'.

## `includeRaw` (type: `boolean`):

Attach the raw response object to each result row. Useful for debugging; increases dataset size.

## `maxRetries` (type: `integer`):

Retries for transient failures (rate limits / temporary server errors). Content-creating actions are never retried after dispatch, to avoid duplicate posts.

## `retryBaseDelayMs` (type: `integer`):

Base backoff delay for retries. Grows exponentially and honors any Retry-After hint.

## `retryMaxDelayMs` (type: `integer`):

Maximum backoff delay between retries.

## `enablePosts` (type: `boolean`):

Master switch for everything in the Posts sections (create, reply, quote, delete). Leave OFF if you don't want to post.

## `postText` (type: `string`):

Text of a single post to publish. This is the simple way to post — just type here. For posting many at once, use 'Advanced: bulk create posts' below.

## `postMediaUrls` (type: `array`):

Optional. Public URLs of up to 4 images/videos to attach to the post above.

## `postReplyOptionMode` (type: `string`):

Optional. Restrict who can reply to the post above. Leave as default for everyone.

## `postDisableLinkPreview` (type: `boolean`):

Optional. Turn off the large link preview card for the post above.

## `createPosts` (type: `array`):

Advanced — publish many posts at once. Each item: { "text": "...", "mediaUrls": \["https://..."], "replyOptionMode": "everyone", "disableLinkPreview": false }. 'text' is required; up to 4 media items. These are added on top of the single 'New post' above.

## `replyToTweet` (type: `string`):

The post you want to reply to — paste its ID or full x.com URL. Leave empty if not replying.

## `replyText` (type: `string`):

Text of your reply to the post above.

## `replyMediaUrls` (type: `array`):

Optional. Public URLs of up to 4 images/videos to attach to your reply.

## `replies` (type: `array`):

Advanced — publish many replies at once. Each item: { "tweetId": "..." (or "tweetUrl"), "text": "...", "mediaUrls": \["https://..."] }. Added on top of the single 'Reply' above.

## `quoteTweet` (type: `string`):

The post you want to quote — paste its ID or full x.com URL. Leave empty if not quoting.

## `quoteUsername` (type: `string`):

Optional. The @handle of the quoted post's author. Helps build the correct quote link; the leading @ is optional.

## `quoteText` (type: `string`):

Your comment added on top of the quoted post above.

## `quoteMediaUrls` (type: `array`):

Optional. Public URLs of up to 4 images/videos to attach to your quote post.

## `quotes` (type: `array`):

Advanced — publish many quote posts at once. Each item: { "tweetId": "..." (or "tweetUrl"), "quotedUsername": "handle" (optional), "text": "...", "mediaUrls": \["https://..."] }. Added on top of the single 'Quote' above.

## `deleteTweetIds` (type: `array`):

IDs of your own posts to delete. This is irreversible.

## `deleteTweetUrls` (type: `array`):

URLs of your own posts to delete (IDs are extracted automatically). This is irreversible.

## `enableEngagement` (type: `boolean`):

Like/unlike, retweet/undo, bookmark/remove, and follow/unfollow. Enable to use the fields below.

## `likeTweetIds` (type: `array`):

IDs of posts to like.

## `likeTweetUrls` (type: `array`):

URLs of posts to like (IDs extracted automatically).

## `unlikeTweetIds` (type: `array`):

IDs of posts to unlike.

## `unlikeTweetUrls` (type: `array`):

URLs of posts to unlike (IDs extracted automatically).

## `retweetTweetIds` (type: `array`):

IDs of posts to retweet.

## `retweetTweetUrls` (type: `array`):

URLs of posts to retweet (IDs extracted automatically).

## `unretweetTweetIds` (type: `array`):

IDs of posts to un-retweet.

## `unretweetTweetUrls` (type: `array`):

URLs of posts to un-retweet (IDs extracted automatically).

## `bookmarkTweetIds` (type: `array`):

IDs of posts to bookmark.

## `bookmarkTweetUrls` (type: `array`):

URLs of posts to bookmark (IDs extracted automatically).

## `unbookmarkTweetIds` (type: `array`):

IDs of posts to remove from bookmarks.

## `unbookmarkTweetUrls` (type: `array`):

URLs of posts to remove from bookmarks (IDs extracted automatically).

## `followUserIds` (type: `array`):

Numeric user IDs to follow.

## `followUsernames` (type: `array`):

@handles to follow (resolved to IDs automatically). The leading @ is optional.

## `unfollowUserIds` (type: `array`):

Numeric user IDs to unfollow.

## `unfollowUsernames` (type: `array`):

@handles to unfollow (resolved to IDs automatically). The leading @ is optional.

## `enableProfile` (type: `boolean`):

Update your profile fields, avatar, and banner. Enable to use the fields below.

## `profileName` (type: `string`):

New display name. Leave empty to keep the current one.

## `profileBio` (type: `string`):

New bio/description. Leave empty to keep the current one.

## `profileLocation` (type: `string`):

New location. Leave empty to keep the current one.

## `profileWebsite` (type: `string`):

New website URL. Leave empty to keep the current one.

## `avatarUrl` (type: `string`):

Public URL of the new profile picture. Leave empty to keep the current one.

## `bannerUrl` (type: `string`):

Public URL of the new header/banner image. Leave empty to keep the current one.

## `enableLists` (type: `boolean`):

Master switch for everything in the Lists sections (create a list, add members, remove members). Leave OFF to skip lists.

## `newListName` (type: `string`):

Name of a single list to create. Leave empty if not creating a list.

## `newListDescription` (type: `string`):

Optional description for the new list above.

## `newListPrivate` (type: `boolean`):

If ticked, the new list above is private (only you can see it).

## `createLists` (type: `array`):

Advanced — create many lists at once. Each item: { "name": "...", "description": "...", "isPrivate": true }. 'name' is required. Added on top of the single 'New list' above.

## `addMembersListId` (type: `string`):

The list ID you want to add members to. Leave empty if not adding members.

## `addMemberUsernames` (type: `array`):

@handles to add to the list above (the leading @ is optional).

## `addListMembers` (type: `array`):

Advanced — add members to any list(s). Each item: { "listId": "...", "userId": "..." } or { "listId": "...", "username": "handle" }. Added on top of the simple fields above.

## `removeMembersListId` (type: `string`):

The list ID you want to remove members from. Leave empty if not removing members.

## `removeMemberUsernames` (type: `array`):

@handles to remove from the list above (the leading @ is optional).

## `removeListMembers` (type: `array`):

Advanced — remove members from any list(s). Each item: { "listId": "...", "userId": "..." } or { "listId": "...", "username": "handle" }. Added on top of the simple fields above.

## `enableCommunities` (type: `boolean`):

Master switch for everything in the Communities sections (post in a community, join, leave). Leave OFF to skip communities.

## `communityId` (type: `string`):

The community ID you want to post in. Leave empty if not posting to a community.

## `communityPostText` (type: `string`):

Text of a single post to publish in the community above.

## `communityPostMediaUrls` (type: `array`):

Optional. Public URLs of up to 4 images/videos to attach to the community post above.

## `communityPosts` (type: `array`):

Advanced — publish many community posts at once. Each item: { "communityId": "...", "text": "...", "mediaUrls": \["https://..."] }. Added on top of the single 'Community post' above.

## `communityReplies` (type: `array`):

Advanced — community replies. Each item: { "communityId": "...", "tweetId": "..." (or "tweetUrl"), "text": "...", "mediaUrls": \["https://..."] }.

## `communityQuotes` (type: `array`):

Advanced — community quote posts. Each item: { "communityId": "...", "tweetId": "..." (or "tweetUrl"), "quotedUsername": "handle" (optional), "text": "..." }.

## `joinCommunityIds` (type: `array`):

IDs of communities to join.

## `leaveCommunityIds` (type: `array`):

IDs of communities to leave.

## Actor input object example

```json
{
  "maxActions": 50,
  "delayBetweenActionsMs": 1500,
  "stopOnAuthOrProxyError": true,
  "includeRaw": false,
  "maxRetries": 3,
  "retryBaseDelayMs": 2000,
  "retryMaxDelayMs": 30000,
  "enablePosts": false,
  "postText": "",
  "postMediaUrls": [],
  "postReplyOptionMode": "everyone",
  "postDisableLinkPreview": false,
  "createPosts": [],
  "replyToTweet": "",
  "replyText": "",
  "replyMediaUrls": [],
  "replies": [],
  "quoteTweet": "",
  "quoteUsername": "",
  "quoteText": "",
  "quoteMediaUrls": [],
  "quotes": [],
  "deleteTweetIds": [],
  "deleteTweetUrls": [],
  "enableEngagement": false,
  "likeTweetIds": [],
  "likeTweetUrls": [],
  "unlikeTweetIds": [],
  "unlikeTweetUrls": [],
  "retweetTweetIds": [],
  "retweetTweetUrls": [],
  "unretweetTweetIds": [],
  "unretweetTweetUrls": [],
  "bookmarkTweetIds": [],
  "bookmarkTweetUrls": [],
  "unbookmarkTweetIds": [],
  "unbookmarkTweetUrls": [],
  "followUserIds": [],
  "followUsernames": [],
  "unfollowUserIds": [],
  "unfollowUsernames": [],
  "enableProfile": false,
  "profileName": "",
  "profileBio": "",
  "profileLocation": "",
  "profileWebsite": "",
  "avatarUrl": "",
  "bannerUrl": "",
  "enableLists": false,
  "newListName": "",
  "newListDescription": "",
  "newListPrivate": true,
  "createLists": [],
  "addMembersListId": "",
  "addMemberUsernames": [],
  "addListMembers": [],
  "removeMembersListId": "",
  "removeMemberUsernames": [],
  "removeListMembers": [],
  "enableCommunities": false,
  "communityId": "",
  "communityPostText": "",
  "communityPostMediaUrls": [],
  "communityPosts": [],
  "communityReplies": [],
  "communityQuotes": [],
  "joinCommunityIds": [],
  "leaveCommunityIds": []
}
```

# Actor output Schema

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

Every attempted action with its actionType, status (success, failed, or skipped), the upstream action label, the id it targeted, and the resulting id/URL (new tweet id, new list id, account id) where applicable.

## `overview` (type: `string`):

Key fields for every action in a single table.

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

Per-run metadata: enabled groups, counts by status and action type, upstream request count, and non-fatal errors.

# 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 = {
    "postMediaUrls": [],
    "createPosts": [],
    "replyMediaUrls": [],
    "replies": [],
    "quoteMediaUrls": [],
    "quotes": [],
    "deleteTweetIds": [],
    "deleteTweetUrls": [],
    "likeTweetIds": [],
    "likeTweetUrls": [],
    "unlikeTweetIds": [],
    "unlikeTweetUrls": [],
    "retweetTweetIds": [],
    "retweetTweetUrls": [],
    "unretweetTweetIds": [],
    "unretweetTweetUrls": [],
    "bookmarkTweetIds": [],
    "bookmarkTweetUrls": [],
    "unbookmarkTweetIds": [],
    "unbookmarkTweetUrls": [],
    "followUserIds": [],
    "followUsernames": [],
    "unfollowUserIds": [],
    "unfollowUsernames": [],
    "createLists": [],
    "addMemberUsernames": [],
    "addListMembers": [],
    "removeMemberUsernames": [],
    "removeListMembers": [],
    "communityPostMediaUrls": [],
    "communityPosts": [],
    "communityReplies": [],
    "communityQuotes": [],
    "joinCommunityIds": [],
    "leaveCommunityIds": []
};

// Run the Actor and wait for it to finish
const run = await client.actor("b2b_leads/x-content-publisher").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 = {
    "postMediaUrls": [],
    "createPosts": [],
    "replyMediaUrls": [],
    "replies": [],
    "quoteMediaUrls": [],
    "quotes": [],
    "deleteTweetIds": [],
    "deleteTweetUrls": [],
    "likeTweetIds": [],
    "likeTweetUrls": [],
    "unlikeTweetIds": [],
    "unlikeTweetUrls": [],
    "retweetTweetIds": [],
    "retweetTweetUrls": [],
    "unretweetTweetIds": [],
    "unretweetTweetUrls": [],
    "bookmarkTweetIds": [],
    "bookmarkTweetUrls": [],
    "unbookmarkTweetIds": [],
    "unbookmarkTweetUrls": [],
    "followUserIds": [],
    "followUsernames": [],
    "unfollowUserIds": [],
    "unfollowUsernames": [],
    "createLists": [],
    "addMemberUsernames": [],
    "addListMembers": [],
    "removeMemberUsernames": [],
    "removeListMembers": [],
    "communityPostMediaUrls": [],
    "communityPosts": [],
    "communityReplies": [],
    "communityQuotes": [],
    "joinCommunityIds": [],
    "leaveCommunityIds": [],
}

# Run the Actor and wait for it to finish
run = client.actor("b2b_leads/x-content-publisher").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "postMediaUrls": [],
  "createPosts": [],
  "replyMediaUrls": [],
  "replies": [],
  "quoteMediaUrls": [],
  "quotes": [],
  "deleteTweetIds": [],
  "deleteTweetUrls": [],
  "likeTweetIds": [],
  "likeTweetUrls": [],
  "unlikeTweetIds": [],
  "unlikeTweetUrls": [],
  "retweetTweetIds": [],
  "retweetTweetUrls": [],
  "unretweetTweetIds": [],
  "unretweetTweetUrls": [],
  "bookmarkTweetIds": [],
  "bookmarkTweetUrls": [],
  "unbookmarkTweetIds": [],
  "unbookmarkTweetUrls": [],
  "followUserIds": [],
  "followUsernames": [],
  "unfollowUserIds": [],
  "unfollowUsernames": [],
  "createLists": [],
  "addMemberUsernames": [],
  "addListMembers": [],
  "removeMemberUsernames": [],
  "removeListMembers": [],
  "communityPostMediaUrls": [],
  "communityPosts": [],
  "communityReplies": [],
  "communityQuotes": [],
  "joinCommunityIds": [],
  "leaveCommunityIds": []
}' |
apify call b2b_leads/x-content-publisher --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=b2b_leads/x-content-publisher",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "X (Twitter) Content Publisher – Post, Reply, Quote & Manage",
        "description": "Publish and manage X (Twitter) content from your own account in bulk. Create posts, replies, and quotes with media, like, retweet, bookmark, follow, update your profile, manage lists, and post to communities. Safe pacing, action limits, and per-action results. Bring your auth token and proxy.",
        "version": "0.0",
        "x-build-id": "xHQJRO39yW3VtZalw"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/b2b_leads~x-content-publisher/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-b2b_leads-x-content-publisher",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/b2b_leads~x-content-publisher/runs": {
            "post": {
                "operationId": "runs-sync-b2b_leads-x-content-publisher",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/b2b_leads~x-content-publisher/run-sync": {
            "post": {
                "operationId": "run-sync-b2b_leads-x-content-publisher",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "properties": {
                    "authToken": {
                        "title": "X auth token",
                        "type": "string",
                        "description": "Your X account login token (the 'auth_token' cookie). Required — the Actor acts on your account. HOW TO GET IT: 1) Log in to x.com in Chrome. 2) Press F12 → open the 'Application' tab → Cookies → https://x.com. 3) Copy the value of the cookie named 'auth_token'. Easier option: install the free 'Cookie-Editor' or 'EditThisCookie' Chrome extension, click it on x.com, and copy the 'auth_token' value. Treated as a secret and never logged."
                    },
                    "proxyHost": {
                        "title": "Proxy host",
                        "type": "string",
                        "description": "Your proxy server address, e.g. proxy.example.com or 123.45.67.89. From your proxy provider's dashboard."
                    },
                    "proxyPort": {
                        "title": "Proxy port",
                        "type": "string",
                        "description": "Your proxy port number, e.g. 8080. From your proxy provider's dashboard."
                    },
                    "proxyUsername": {
                        "title": "Proxy username",
                        "type": "string",
                        "description": "The username/login for your proxy. From your proxy provider's dashboard."
                    },
                    "proxyPassword": {
                        "title": "Proxy password",
                        "type": "string",
                        "description": "The password for your proxy. From your proxy provider's dashboard. Treated as a secret and never logged."
                    },
                    "userProxy": {
                        "title": "Full proxy string (advanced — optional)",
                        "type": "string",
                        "description": "Advanced: instead of the four fields above, paste a full proxy string in host:port@user:pass format (e.g. proxy.example.com:8080@myuser:mypass). If set, this overrides the separate fields."
                    },
                    "maxActions": {
                        "title": "Max actions per run",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Hard cap on how many actions this run will attempt. Extra actions are marked 'skipped'. Set 0 for unlimited (not recommended). Protects against accidental bulk writes.",
                        "default": 50
                    },
                    "delayBetweenActionsMs": {
                        "title": "Delay between actions (ms)",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Pause added after each action to space out writes for account safety. 0 disables pacing.",
                        "default": 1500
                    },
                    "stopOnAuthOrProxyError": {
                        "title": "Stop on session/proxy error",
                        "type": "boolean",
                        "description": "If a session (expired token) or proxy error occurs, stop the rest of the run instead of hammering a dead session. Remaining actions are marked 'skipped'.",
                        "default": true
                    },
                    "includeRaw": {
                        "title": "Include raw response (debugging)",
                        "type": "boolean",
                        "description": "Attach the raw response object to each result row. Useful for debugging; increases dataset size.",
                        "default": false
                    },
                    "maxRetries": {
                        "title": "Max retries",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Retries for transient failures (rate limits / temporary server errors). Content-creating actions are never retried after dispatch, to avoid duplicate posts.",
                        "default": 3
                    },
                    "retryBaseDelayMs": {
                        "title": "Retry base delay (ms)",
                        "minimum": 100,
                        "type": "integer",
                        "description": "Base backoff delay for retries. Grows exponentially and honors any Retry-After hint.",
                        "default": 2000
                    },
                    "retryMaxDelayMs": {
                        "title": "Retry max delay (ms)",
                        "minimum": 1000,
                        "type": "integer",
                        "description": "Maximum backoff delay between retries.",
                        "default": 30000
                    },
                    "enablePosts": {
                        "title": "Enable Posts",
                        "type": "boolean",
                        "description": "Master switch for everything in the Posts sections (create, reply, quote, delete). Leave OFF if you don't want to post.",
                        "default": false
                    },
                    "postText": {
                        "title": "New post — text",
                        "type": "string",
                        "description": "Text of a single post to publish. This is the simple way to post — just type here. For posting many at once, use 'Advanced: bulk create posts' below.",
                        "default": ""
                    },
                    "postMediaUrls": {
                        "title": "New post — image/video URLs",
                        "type": "array",
                        "description": "Optional. Public URLs of up to 4 images/videos to attach to the post above.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "postReplyOptionMode": {
                        "title": "New post — who can reply",
                        "enum": [
                            "everyone",
                            "accounts_you_follow",
                            "accounts_you_follow_and_followed",
                            "mentioned_accounts",
                            "verified_accounts"
                        ],
                        "type": "string",
                        "description": "Optional. Restrict who can reply to the post above. Leave as default for everyone.",
                        "default": "everyone"
                    },
                    "postDisableLinkPreview": {
                        "title": "New post — hide link preview",
                        "type": "boolean",
                        "description": "Optional. Turn off the large link preview card for the post above.",
                        "default": false
                    },
                    "createPosts": {
                        "title": "Advanced: bulk create posts (JSON)",
                        "type": "array",
                        "description": "Advanced — publish many posts at once. Each item: { \"text\": \"...\", \"mediaUrls\": [\"https://...\"], \"replyOptionMode\": \"everyone\", \"disableLinkPreview\": false }. 'text' is required; up to 4 media items. These are added on top of the single 'New post' above.",
                        "default": []
                    },
                    "replyToTweet": {
                        "title": "Reply — to post (ID or URL)",
                        "type": "string",
                        "description": "The post you want to reply to — paste its ID or full x.com URL. Leave empty if not replying.",
                        "default": ""
                    },
                    "replyText": {
                        "title": "Reply — text",
                        "type": "string",
                        "description": "Text of your reply to the post above.",
                        "default": ""
                    },
                    "replyMediaUrls": {
                        "title": "Reply — image/video URLs",
                        "type": "array",
                        "description": "Optional. Public URLs of up to 4 images/videos to attach to your reply.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "replies": {
                        "title": "Advanced: bulk replies (JSON)",
                        "type": "array",
                        "description": "Advanced — publish many replies at once. Each item: { \"tweetId\": \"...\" (or \"tweetUrl\"), \"text\": \"...\", \"mediaUrls\": [\"https://...\"] }. Added on top of the single 'Reply' above.",
                        "default": []
                    },
                    "quoteTweet": {
                        "title": "Quote — post to quote (ID or URL)",
                        "type": "string",
                        "description": "The post you want to quote — paste its ID or full x.com URL. Leave empty if not quoting.",
                        "default": ""
                    },
                    "quoteUsername": {
                        "title": "Quote — author handle (optional)",
                        "type": "string",
                        "description": "Optional. The @handle of the quoted post's author. Helps build the correct quote link; the leading @ is optional.",
                        "default": ""
                    },
                    "quoteText": {
                        "title": "Quote — your text",
                        "type": "string",
                        "description": "Your comment added on top of the quoted post above.",
                        "default": ""
                    },
                    "quoteMediaUrls": {
                        "title": "Quote — image/video URLs",
                        "type": "array",
                        "description": "Optional. Public URLs of up to 4 images/videos to attach to your quote post.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "quotes": {
                        "title": "Advanced: bulk quote posts (JSON)",
                        "type": "array",
                        "description": "Advanced — publish many quote posts at once. Each item: { \"tweetId\": \"...\" (or \"tweetUrl\"), \"quotedUsername\": \"handle\" (optional), \"text\": \"...\", \"mediaUrls\": [\"https://...\"] }. Added on top of the single 'Quote' above.",
                        "default": []
                    },
                    "deleteTweetIds": {
                        "title": "Delete post IDs",
                        "type": "array",
                        "description": "IDs of your own posts to delete. This is irreversible.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "deleteTweetUrls": {
                        "title": "Delete post URLs",
                        "type": "array",
                        "description": "URLs of your own posts to delete (IDs are extracted automatically). This is irreversible.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "enableEngagement": {
                        "title": "Engagement",
                        "type": "boolean",
                        "description": "Like/unlike, retweet/undo, bookmark/remove, and follow/unfollow. Enable to use the fields below.",
                        "default": false
                    },
                    "likeTweetIds": {
                        "title": "Like — post IDs",
                        "type": "array",
                        "description": "IDs of posts to like.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "likeTweetUrls": {
                        "title": "Like — post URLs",
                        "type": "array",
                        "description": "URLs of posts to like (IDs extracted automatically).",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "unlikeTweetIds": {
                        "title": "Unlike — post IDs",
                        "type": "array",
                        "description": "IDs of posts to unlike.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "unlikeTweetUrls": {
                        "title": "Unlike — post URLs",
                        "type": "array",
                        "description": "URLs of posts to unlike (IDs extracted automatically).",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "retweetTweetIds": {
                        "title": "Retweet — post IDs",
                        "type": "array",
                        "description": "IDs of posts to retweet.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "retweetTweetUrls": {
                        "title": "Retweet — post URLs",
                        "type": "array",
                        "description": "URLs of posts to retweet (IDs extracted automatically).",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "unretweetTweetIds": {
                        "title": "Undo retweet — post IDs",
                        "type": "array",
                        "description": "IDs of posts to un-retweet.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "unretweetTweetUrls": {
                        "title": "Undo retweet — post URLs",
                        "type": "array",
                        "description": "URLs of posts to un-retweet (IDs extracted automatically).",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "bookmarkTweetIds": {
                        "title": "Bookmark — post IDs",
                        "type": "array",
                        "description": "IDs of posts to bookmark.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "bookmarkTweetUrls": {
                        "title": "Bookmark — post URLs",
                        "type": "array",
                        "description": "URLs of posts to bookmark (IDs extracted automatically).",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "unbookmarkTweetIds": {
                        "title": "Remove bookmark — post IDs",
                        "type": "array",
                        "description": "IDs of posts to remove from bookmarks.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "unbookmarkTweetUrls": {
                        "title": "Remove bookmark — post URLs",
                        "type": "array",
                        "description": "URLs of posts to remove from bookmarks (IDs extracted automatically).",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "followUserIds": {
                        "title": "Follow — user IDs",
                        "type": "array",
                        "description": "Numeric user IDs to follow.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "followUsernames": {
                        "title": "Follow — usernames",
                        "type": "array",
                        "description": "@handles to follow (resolved to IDs automatically). The leading @ is optional.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "unfollowUserIds": {
                        "title": "Unfollow — user IDs",
                        "type": "array",
                        "description": "Numeric user IDs to unfollow.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "unfollowUsernames": {
                        "title": "Unfollow — usernames",
                        "type": "array",
                        "description": "@handles to unfollow (resolved to IDs automatically). The leading @ is optional.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "enableProfile": {
                        "title": "Profile",
                        "type": "boolean",
                        "description": "Update your profile fields, avatar, and banner. Enable to use the fields below.",
                        "default": false
                    },
                    "profileName": {
                        "title": "Display name",
                        "type": "string",
                        "description": "New display name. Leave empty to keep the current one.",
                        "default": ""
                    },
                    "profileBio": {
                        "title": "Bio",
                        "type": "string",
                        "description": "New bio/description. Leave empty to keep the current one.",
                        "default": ""
                    },
                    "profileLocation": {
                        "title": "Location",
                        "type": "string",
                        "description": "New location. Leave empty to keep the current one.",
                        "default": ""
                    },
                    "profileWebsite": {
                        "title": "Website",
                        "type": "string",
                        "description": "New website URL. Leave empty to keep the current one.",
                        "default": ""
                    },
                    "avatarUrl": {
                        "title": "Avatar image URL",
                        "type": "string",
                        "description": "Public URL of the new profile picture. Leave empty to keep the current one.",
                        "default": ""
                    },
                    "bannerUrl": {
                        "title": "Banner image URL",
                        "type": "string",
                        "description": "Public URL of the new header/banner image. Leave empty to keep the current one.",
                        "default": ""
                    },
                    "enableLists": {
                        "title": "Enable Lists",
                        "type": "boolean",
                        "description": "Master switch for everything in the Lists sections (create a list, add members, remove members). Leave OFF to skip lists.",
                        "default": false
                    },
                    "newListName": {
                        "title": "New list — name",
                        "type": "string",
                        "description": "Name of a single list to create. Leave empty if not creating a list.",
                        "default": ""
                    },
                    "newListDescription": {
                        "title": "New list — description",
                        "type": "string",
                        "description": "Optional description for the new list above.",
                        "default": ""
                    },
                    "newListPrivate": {
                        "title": "New list — private",
                        "type": "boolean",
                        "description": "If ticked, the new list above is private (only you can see it).",
                        "default": true
                    },
                    "createLists": {
                        "title": "Advanced: bulk create lists (JSON)",
                        "type": "array",
                        "description": "Advanced — create many lists at once. Each item: { \"name\": \"...\", \"description\": \"...\", \"isPrivate\": true }. 'name' is required. Added on top of the single 'New list' above.",
                        "default": []
                    },
                    "addMembersListId": {
                        "title": "Add members — list ID",
                        "type": "string",
                        "description": "The list ID you want to add members to. Leave empty if not adding members.",
                        "default": ""
                    },
                    "addMemberUsernames": {
                        "title": "Add members — usernames",
                        "type": "array",
                        "description": "@handles to add to the list above (the leading @ is optional).",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "addListMembers": {
                        "title": "Advanced: bulk add list members (JSON)",
                        "type": "array",
                        "description": "Advanced — add members to any list(s). Each item: { \"listId\": \"...\", \"userId\": \"...\" } or { \"listId\": \"...\", \"username\": \"handle\" }. Added on top of the simple fields above.",
                        "default": []
                    },
                    "removeMembersListId": {
                        "title": "Remove members — list ID",
                        "type": "string",
                        "description": "The list ID you want to remove members from. Leave empty if not removing members.",
                        "default": ""
                    },
                    "removeMemberUsernames": {
                        "title": "Remove members — usernames",
                        "type": "array",
                        "description": "@handles to remove from the list above (the leading @ is optional).",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "removeListMembers": {
                        "title": "Advanced: bulk remove list members (JSON)",
                        "type": "array",
                        "description": "Advanced — remove members from any list(s). Each item: { \"listId\": \"...\", \"userId\": \"...\" } or { \"listId\": \"...\", \"username\": \"handle\" }. Added on top of the simple fields above.",
                        "default": []
                    },
                    "enableCommunities": {
                        "title": "Enable Communities",
                        "type": "boolean",
                        "description": "Master switch for everything in the Communities sections (post in a community, join, leave). Leave OFF to skip communities.",
                        "default": false
                    },
                    "communityId": {
                        "title": "Community post — community ID",
                        "type": "string",
                        "description": "The community ID you want to post in. Leave empty if not posting to a community.",
                        "default": ""
                    },
                    "communityPostText": {
                        "title": "Community post — text",
                        "type": "string",
                        "description": "Text of a single post to publish in the community above.",
                        "default": ""
                    },
                    "communityPostMediaUrls": {
                        "title": "Community post — image/video URLs",
                        "type": "array",
                        "description": "Optional. Public URLs of up to 4 images/videos to attach to the community post above.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "communityPosts": {
                        "title": "Advanced: bulk community posts (JSON)",
                        "type": "array",
                        "description": "Advanced — publish many community posts at once. Each item: { \"communityId\": \"...\", \"text\": \"...\", \"mediaUrls\": [\"https://...\"] }. Added on top of the single 'Community post' above.",
                        "default": []
                    },
                    "communityReplies": {
                        "title": "Advanced: community replies (JSON)",
                        "type": "array",
                        "description": "Advanced — community replies. Each item: { \"communityId\": \"...\", \"tweetId\": \"...\" (or \"tweetUrl\"), \"text\": \"...\", \"mediaUrls\": [\"https://...\"] }.",
                        "default": []
                    },
                    "communityQuotes": {
                        "title": "Advanced: community quotes (JSON)",
                        "type": "array",
                        "description": "Advanced — community quote posts. Each item: { \"communityId\": \"...\", \"tweetId\": \"...\" (or \"tweetUrl\"), \"quotedUsername\": \"handle\" (optional), \"text\": \"...\" }.",
                        "default": []
                    },
                    "joinCommunityIds": {
                        "title": "Join community IDs",
                        "type": "array",
                        "description": "IDs of communities to join.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "leaveCommunityIds": {
                        "title": "Leave community IDs",
                        "type": "array",
                        "description": "IDs of communities to leave.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
