PeumeAPI

Social publishing & inbox · X

Search recent tweets

Search public tweets from the last 7 days matching an X search query, e.g. to discover tweets to reply to.

$0.002 per callRuns on an account you connect

Call it

curl https://api.peume.com/v1/call/x-search-recent-tweets \
  -H "Authorization: Bearer $PEUME_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "input": {
    "accountId": "your accountId",
    "query": "your query",
    "limit": 10,
    "sortOrder": "recency"
  }
}'

Answer: {"id": "run_…", "status": "completed", "cost_usd": …, "output": {…}}. Long jobs answer 202 with a run id to read later. From an AI agent, connect the MCP server and ask for this by name: x-search-recent-tweets.

Parameters

accountIdRequiredstring

The account ID

queryRequiredstring

X search query, max 512 characters. Operators are passed through unchanged; X rejects malformed queries with a 400.

limitinteger

Results per page. X requires a minimum of 10; values below 10 are rejected.

Example: 10

sinceIdstring

Only return tweets with an ID greater than (more recent than) this numeric tweet ID. Non-numeric values are rejected with 400.

untilIdstring

Only return tweets with an ID less than (older than) this numeric tweet ID. Non-numeric values are rejected with 400.

startTimestring

Oldest UTC timestamp (ISO 8601, inclusive), within the last 7 days

endTimestring

Newest UTC timestamp (ISO 8601, exclusive), within the last 7 days

cursorstring

Pagination cursor from a previous response

sortOrderstring

recency · relevancy

Example: recency

Start free · $1 of calls included

Every API your product needs. One key.

7,267 endpoints, one bill, and you only pay for calls that work.