> ## Documentation Index
> Fetch the complete documentation index at: https://creatorinsights.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# X Community Tweets

Fetches tweets posted within a Twitter/X Community by URL. Returns an array of tweets, each with id, full\_text, view\_count, favorite\_count, retweet\_count, reply\_count, bookmark\_count, quote\_count, created\_at, and source. Each tweet includes a user object with the author's name, screen\_name, avatar, followers\_count, and is\_blue\_verified status. Scraper responses preserve their public source field names by default (trim omitted or true) while removing only noisy, heavy, or unsafe fields. Set trim=false for the full sanitized source response.

Intelligence uses plan credits; niche searches start at 2, other ordinary fetches at 1, and applicable options can cost more.

> [!NOTE]
>
> Examples use illustrative values. The playground sends a real request. Intelligence can consume plan credits. Publishing examples save drafts.

## Endpoint

**GET** `https://api.creatorinsights.in/v1/twitter/search`

**Content type:** Query parameters; no JSON request body.

**Authentication:** `x-api-key: YOUR_SAVED_API_KEY`

**MCP tool:** `fetch_x_community_tweets`. See [MCP Setup](https://creatorinsights.mintlify.site/mcp-setup.md) for AI clients.

## Request parameters

**x-workspace-id** `string`

Active workspace ID or current name in your organization. Optional header alternative to passing workspace in the query.

**url** `string` *required*

Community URL

**workspace** `string`

Workspace ID or current name in the authenticated organization. Required for paid requests when the organization has more than one active workspace. The selected workspace receives this request charge.

**trim** `boolean` (default: true)

Defaults to true: preserve public source field names, metrics, and public media URLs while removing only noisy, heavy, or unsafe fields. Set false for the full sanitized source response; credentials, transport headers/context, internal credit data, and upstream-provider identity are always removed.

## Request example

Send these arguments as URL query parameters.

```json theme={null}
{
  "url": "https://x.com/examplecreator/status/1800000000000000000",
  "workspace": "YOUR_WORKSPACE_ID_OR_CURRENT_NAME"
}
```

```bash cURL theme={null}
curl --get 'https://api.creatorinsights.in/v1/twitter/search' \
  -H "x-api-key: $CREATOR_INSIGHTS_API_KEY" \
  --data-urlencode 'url=https://x.com/examplecreator/status/1800000000000000000' \
  --data-urlencode 'workspace=YOUR_WORKSPACE_ID_OR_CURRENT_NAME'
```

```javascript Node.js theme={null}
const parameters = {
  "url": "https://x.com/examplecreator/status/1800000000000000000",
  "workspace": "YOUR_WORKSPACE_ID_OR_CURRENT_NAME"
};
const url = new URL('https://api.creatorinsights.in/v1/twitter/search');
for (const [name, value] of Object.entries(parameters)) url.searchParams.set(name, String(value));
const response = await fetch(url, { headers: { 'x-api-key': process.env.CREATOR_INSIGHTS_API_KEY } });
const raw = await response.text();
let result;
try { result = JSON.parse(raw); } catch { throw new Error('Non-JSON response: ' + response.status); }
if (!response.ok || result.success === false) throw new Error(result.message || result.error || 'Request failed');
console.log(result.data);
```

```python Python theme={null}
import json, os, requests

arguments = json.loads("{\"url\":\"https://x.com/examplecreator/status/1800000000000000000\",\"workspace\":\"YOUR_WORKSPACE_ID_OR_CURRENT_NAME\"}")
response = requests.get("https://api.creatorinsights.in/v1/twitter/search",
    headers={"x-api-key": os.environ["CREATOR_INSIGHTS_API_KEY"]},
    params=arguments, timeout=120)
response.raise_for_status()
result = response.json()
print(result["data"])
```

## Response example

HTTP 200. Illustrative values; optional fields can be omitted, null, or empty. Additional platform fields may be returned.

```json Success theme={null}
{
  "success": true,
  "data": {
    "success": true,
    "tweets": [
      {
        "id": "1234567890123456789",
        "source": "https://example.com/sample",
        "view_count": "1234567890123456789",
        "bookmark_count": 120,
        "bookmarked": false,
        "created_at": "example",
        "conversation_id_str": "1234567890123456789",
        "display_text_range": [
          1
        ],
        "favorite_count": 120,
        "favorited": false,
        "full_text": "https://example.com/sample",
        "is_quote_status": false,
        "lang": "example",
        "possibly_sensitive": false,
        "possibly_sensitive_editable": false,
        "quote_count": 120,
        "reply_count": 120,
        "retweet_count": 120,
        "retweeted": false,
        "user_id_str": "1234567890123456789",
        "id_str": "1234567890123456789",
        "user": {
          "__typename": "Example creator content",
          "id": "example_id",
          "rest_id": "1234567890123456789",
          "affiliates_highlighted_label": {},
          "avatar": {
            "image_url": "https://media.example.com/sample.jpg"
          },
          "core": {
            "created_at": "example",
            "name": "Example creator content",
            "screen_name": "examplecreator"
          },
          "dm_permissions": {},
          "is_blue_verified": false,
          "legacy": {
            "default_profile": false,
            "default_profile_image": false,
            "description": "Example creator content",
            "entities": {
              "description": {
                "urls": []
              }
            },
            "fast_followers_count": 120,
            "favourites_count": 120,
            "followers_count": 120,
            "friends_count": 120,
            "has_custom_timelines": false,
            "is_translator": false,
            "listed_count": 120,
            "media_count": 120,
            "normal_followers_count": 120,
            "pinned_tweet_ids_str": [
              "1234567890123456789"
            ],
            "possibly_sensitive": false,
            "profile_interstitial_type": "",
            "statuses_count": 120,
            "translator_type": "example",
            "withheld_in_countries": []
          },
          "location": {
            "location": ""
          },
          "media_permissions": {},
          "parody_commentary_fan_label": "example",
          "profile_image_shape": "example",
          "professional": {
            "rest_id": "1234567890123456789",
            "professional_type": "example",
            "category": [
              {
                "id": 1,
                "name": "Example creator content",
                "icon_name": "Example creator content"
              }
            ]
          },
          "privacy": {
            "protected": false
          },
          "relationship_perspectives": {},
          "tipjar_settings": {
            "is_enabled": false,
            "bandcamp_handle": "",
            "bitcoin_handle": "",
            "cash_app_handle": "",
            "ethereum_handle": "",
            "gofundme_handle": "",
            "patreon_handle": "",
            "pay_pal_handle": "",
            "venmo_handle": ""
          },
          "verification": {
            "verified": false
          }
        }
      }
    ]
  },
  "credits_charged": 1
}
```

## Response fields

**success** `boolean` *required*

Whether this operation succeeded. Also check HTTP status and nested platform statuses.

**data** `object` *required*

Operation-specific payload. See the nested field table and response example below.

**credits\_charged** `number`

Creator Insights plan credits for this call; the example is illustrative.

| Field | Type | Description |
| - | - | - |
| `success` | boolean | Example response field. Availability depends on the record and selected options. |
| `data` | object | Public source field names are preserved by default when trim is omitted or true; only noisy, heavy, or unsafe fields are removed. Set trim=false for the full sanitized source response. Fields vary with source availability; unavailable metrics are null. |
| `data.success` | boolean | Example response field. Availability depends on the record and selected options. |
| `data.tweets` | array | List of returned entries; may be empty. |
| `data.tweets[].id` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].source` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].view_count` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].bookmark_count` | integer | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].bookmarked` | boolean | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].created_at` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].conversation_id_str` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].display_text_range` | array | List of returned entries; may be empty. |
| `data.tweets[].favorite_count` | integer | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].favorited` | boolean | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].full_text` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].is_quote_status` | boolean | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].lang` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].possibly_sensitive` | boolean | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].possibly_sensitive_editable` | boolean | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].quote_count` | integer | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].reply_count` | integer | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].retweet_count` | integer | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].retweeted` | boolean | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].user_id_str` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].id_str` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].user` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.__typename` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].user.id` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].user.rest_id` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].user.affiliates_highlighted_label` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.avatar` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.core` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.dm_permissions` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.is_blue_verified` | boolean | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].user.legacy` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.location` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.media_permissions` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.parody_commentary_fan_label` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].user.profile_image_shape` | string | Example response field. Availability depends on the record and selected options. |
| `data.tweets[].user.professional` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.privacy` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.relationship_perspectives` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.tipjar_settings` | object | Nested object. Expand the response schema for its fields. |
| `data.tweets[].user.verification` | object | Nested object. Expand the response schema for its fields. |
| `credits_charged` | number | Example response field. Availability depends on the record and selected options. |

The interactive schema includes deeper nested fields. Sample fields are descriptive, not a promise that every record includes them.

## n8n and JSON tool endpoint

**POST** `https://api.creatorinsights.in/api/v1/tools/fetch_x_community_tweets`. Use Header Auth with `x-api-key` and body content type JSON. This alias returns the n8n envelope below; included operations can report zero credits\_deducted.

```bash theme={null}
curl -X POST 'https://api.creatorinsights.in/api/v1/tools/fetch_x_community_tweets' \
  -H "x-api-key: $CREATOR_INSIGHTS_API_KEY" \
  -H 'Content-Type: application/json' \
  --data '{"url":"https://x.com/examplecreator/status/1800000000000000000","workspace":"YOUR_WORKSPACE_ID_OR_CURRENT_NAME"}'
```

```json theme={null}
{
  "status": true,
  "tool": "fetch_x_community_tweets",
  "credits_deducted": 1,
  "data": {
    "success": true,
    "tweets": [
      {
        "id": "1234567890123456789",
        "source": "https://example.com/sample",
        "view_count": "1234567890123456789",
        "bookmark_count": 120,
        "bookmarked": false,
        "created_at": "example",
        "conversation_id_str": "1234567890123456789",
        "display_text_range": [
          1
        ],
        "favorite_count": 120,
        "favorited": false,
        "full_text": "https://example.com/sample",
        "is_quote_status": false,
        "lang": "example",
        "possibly_sensitive": false,
        "possibly_sensitive_editable": false,
        "quote_count": 120,
        "reply_count": 120,
        "retweet_count": 120,
        "retweeted": false,
        "user_id_str": "1234567890123456789",
        "id_str": "1234567890123456789",
        "user": {
          "__typename": "Example creator content",
          "id": "example_id",
          "rest_id": "1234567890123456789",
          "affiliates_highlighted_label": {},
          "avatar": {
            "image_url": "https://media.example.com/sample.jpg"
          },
          "core": {
            "created_at": "example",
            "name": "Example creator content",
            "screen_name": "examplecreator"
          },
          "dm_permissions": {},
          "is_blue_verified": false,
          "legacy": {
            "default_profile": false,
            "default_profile_image": false,
            "description": "Example creator content",
            "entities": {
              "description": {
                "urls": []
              }
            },
            "fast_followers_count": 120,
            "favourites_count": 120,
            "followers_count": 120,
            "friends_count": 120,
            "has_custom_timelines": false,
            "is_translator": false,
            "listed_count": 120,
            "media_count": 120,
            "normal_followers_count": 120,
            "pinned_tweet_ids_str": [
              "1234567890123456789"
            ],
            "possibly_sensitive": false,
            "profile_interstitial_type": "",
            "statuses_count": 120,
            "translator_type": "example",
            "withheld_in_countries": []
          },
          "location": {
            "location": ""
          },
          "media_permissions": {},
          "parody_commentary_fan_label": "example",
          "profile_image_shape": "example",
          "professional": {
            "rest_id": "1234567890123456789",
            "professional_type": "example",
            "category": [
              {
                "id": 1,
                "name": "Example creator content",
                "icon_name": "Example creator content"
              }
            ]
          },
          "privacy": {
            "protected": false
          },
          "relationship_perspectives": {},
          "tipjar_settings": {
            "is_enabled": false,
            "bandcamp_handle": "",
            "bitcoin_handle": "",
            "cash_app_handle": "",
            "ethereum_handle": "",
            "gofundme_handle": "",
            "patreon_handle": "",
            "pay_pal_handle": "",
            "venmo_handle": ""
          },
          "verification": {
            "verified": false
          }
        }
      }
    ]
  },
  "credits_charged": 1
}
```

## Errors

Handle non-2xx responses before mapping data. Error codes vary with the cause; these are representative examples. A 429 response may be plain text. Never treat a queued post as published or blindly retry a partial publication.

```json theme={null}
{
  "success": false,
  "error": "UNAUTHORIZED",
  "message": "Missing or invalid API key"
}
```

| HTTP status | Meaning |
| - | - |
| 400 | Invalid arguments |
| 401 | Missing or invalid API key |
| 402 | Insufficient Creator Insights plan credits |
| 403 | Subscription or permission required |
| 404 | Resource not found |
| 409 | Conflicting request, idempotency key, or unfinished upload |
| 410 | Managed media expired; upload the file again |
| 413 | Media too large |
| 415 | Unsupported media type |
| 422 | Account selection, connection, or platform payload needs attention |
| 500 | Authentication or server error |
| 503 | Service temporarily unavailable or operation failed; inspect saved status before retrying |
| 429 | Rate limit; inspect response headers and retry later. |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.