---
title: "Community Search"
method: GET
path: "/community/search"
tags: ["Communities"]
---

# Community Search

`GET /community/search`

## Request

- Base URL: `https://api.twitterapis.com/twitter`
- URL: `https://api.twitterapis.com/twitter/community/search`
- Auth: HTTP bearer

Find communities by keyword, cursor-paginated. This is the discovery step the rest of this family assumes: every other community endpoint starts from a community id, and this is the one that produces one. Each hit is a compact record, id, name, member count, nsfw flag, topic name, banners and the facepile avatars, which is exactly what X's search operation sends and nothing more. Billed at $0.0008 per call. Cost: $0.0008 per call.

## Query parameters

- `query` string, required: The keyword to search for. 1 to 500 characters.
- `cursor` string: Pagination cursor from a previous response's next_cursor. Omit on the first call.
- `fields` string
- `compact` '1'

## Response `200`

Search X Communities by keyword.

- object
  - `communities` object[]: The matching communities for this page. A COMPACT record, not the full Community object Community Info returns: id, name, member_count, is_nsfw, primary_topic, banner_url, custom_banner, default_banner and member_avatar_urls. Take an id from here and call Community Info for the rest.
  - `next_cursor` string, nullable: Opaque cursor for the next page, or null when there is none.
  - `has_more` boolean: True when this page returned communities and carried a usable next_cursor.

## Other responses

- `400`: Bad request
- `401`: Unauthorized
- `402`: Insufficient credits
- `403`: Forbidden
- `404`: Not found
- `429`: Rate limited
- `5XX`: Server error

---

[API](https://skmtc.dev/twitterapis/apis/twitterapis-api.md) · [All operations](https://skmtc.dev/twitterapis/apis/twitterapis-api/llms.txt) · [OpenAPI document](https://skmtc.dev/twitterapis/apis/twitterapis-api/revisions/a33ce0fedb3c?raw)
