GroundsocialDocs

API · X

GET /x/users/{username}/tweets/next

The next page of an X account’s posts, from a next_token (beta).

RequestGET /v1/x/users/{username}/tweets/next
Operation idx.user.tweets_next
Cost2 credits, refunded if the call fails
AuthAPI key: Authorization: Bearer <key> or x-api-key.

The next page of an X account’s posts, from a next_token (beta).

Path parameters

NameTypeRequiredDescription
usernamestringyesHandle, with or without the @, or a profile URL. Example: NASA.

Query parameters

NameTypeRequiredDescription
afterstringyesCursor: the previous page's meta.next_token (x_user_tweets or this endpoint).
sincestringnoOnly posts on or after this time. Reaching an older post ends the walk: YYYY-MM-DD (UTC) or an ISO 8601 timestamp. Example: 2026-11-01.
untilstringnoOnly posts on or before this time (a date includes that whole UTC day): YYYY-MM-DD (UTC) or an ISO 8601 timestamp. Example: 2026-11-01.
stop_at_idstringnoThe newest post you already hold (id or URL): the page stops just before it and there is no next page.

Responses

StatusMeaningSchema
200The next page of posts.XTimelineResponse
400Invalid input. Nothing was charged.Error
401Missing or invalid API key.Error
402Not enough credits, a spend cap was reached, or payment is required.Error
403The target is private, or the account is suspended.Error
404The post or account does not exist, was deleted, or is suspended.Error
429Too many requests. Wait for Retry-After seconds.Error
503X is temporarily unavailable. Retryable; nothing was charged.Error

XTimelineResponse fields

FieldTypeDescription
dataXTweet[]
includesXIncludesObjects the response refers to by id, each once: authors, quoted and reposted posts, media, polls.
metaXTimelineMeta

Errors use one shape everywhere; see Errors for every code and what to do.