Docs menu: Communities

Communities

Read a public community's record, posts, members and moderators.

Endpoints

EndpointReturns and price
GET /v1/communities/{communityId}
Community information
Community
· $0.001 per request
GET /v1/communities/{communityId}/posts
Community posts
Page of posts
· $0.10 per 1,000 records
GET /v1/communities/{communityId}/members
Community members
Page of accounts
· $0.01 per 1,000 accounts
GET /v1/communities/{communityId}/moderators
Community moderators
Page of accounts
· $0.01 per 1,000 accounts

All routes take Authorization: Bearer $TWITTERXAPI_KEY and level. Collections return one page; continue with the cursor.

Find the community ID

  • Use the number in the community URL, for example x.com/i/communities/1493446837214187523.

Queue larger collections

GET/v1/communities/{communityId}Community

Community information

Name, description, member and moderator counts, and rules.

ParameterInDescription
communityId required
numeric string
pathNumeric ID from a community URL such as x.com/i/communities/1493446837214187523.
level
raw | moderate | contentful
queryResponse level. Defaults to moderate.

Returns: Community · Price: $0.001 per request

cURL
curl "https://twitterxapi.com/api/v1/communities/1493446837214187523" \
  -H "Authorization: Bearer $TWITTERXAPI_KEY"
GET/v1/communities/{communityId}/postsPage of posts

Community posts

One page of posts from the community.

ParameterInDescription
communityId required
numeric string
pathNumeric ID from a community URL such as x.com/i/communities/1493446837214187523.
cursor
string
queryValue of pagination.next_cursor from the previous page. Omit for the first page.
level
raw | moderate | contentful
queryResponse level. Defaults to moderate.

Returns: Page of posts · Price: $0.10 per 1,000 records

cURL
curl "https://twitterxapi.com/api/v1/communities/1493446837214187523/posts" \
  -H "Authorization: Bearer $TWITTERXAPI_KEY"
GET/v1/communities/{communityId}/membersPage of accounts

Community members

One page of community members.

ParameterInDescription
communityId required
numeric string
pathNumeric ID from a community URL such as x.com/i/communities/1493446837214187523.
cursor
string
queryValue of pagination.next_cursor from the previous page. Omit for the first page.
level
raw | moderate | contentful
queryResponse level. Defaults to moderate.

Returns: Page of accounts · Price: $0.01 per 1,000 accounts

cURL
curl "https://twitterxapi.com/api/v1/communities/1493446837214187523/members" \
  -H "Authorization: Bearer $TWITTERXAPI_KEY"
GET/v1/communities/{communityId}/moderatorsPage of accounts

Community moderators

One page of community moderators.

ParameterInDescription
communityId required
numeric string
pathNumeric ID from a community URL such as x.com/i/communities/1493446837214187523.
cursor
string
queryValue of pagination.next_cursor from the previous page. Omit for the first page.
level
raw | moderate | contentful
queryResponse level. Defaults to moderate.

Returns: Page of accounts · Price: $0.01 per 1,000 accounts

cURL
curl "https://twitterxapi.com/api/v1/communities/1493446837214187523/moderators" \
  -H "Authorization: Bearer $TWITTERXAPI_KEY"