Install
openclaw skills install wip-xX Platform API. Read posts, search tweets, post, upload media.
openclaw skills install wip-xX Platform API. Sensor (read) + Actuator (write). All X Platform functions in one tool.
Use fetch_post for:
Use search_recent for:
Use get_bookmarks for:
Use get_user for:
Use post_tweet for:
Use upload_media for:
Use delete_tweet for:
Use bookmark_post for:
const result = await fetch_post({ id_or_url: 'https://x.com/user/status/123' });
// result: { data, includes, errors }
Options: id_or_url (required). Accepts tweet ID or full URL.
const result = await search_recent({ query: 'AI agents', max_results: 20 });
// result: { data, includes, meta, errors }
Options: query (required), max_results (10-100), start_time, end_time, sort_order
const result = await get_bookmarks({ max_results: 20 });
Options: max_results, pagination_token. Requires OAuth.
const result = await get_user({ username_or_id: 'parkertoddbrooks' });
Options: username_or_id (required). Accepts username (with or without @) or numeric ID.
const result = await post_tweet({ text: 'Hello world', reply_to: '123', media_ids: ['456'] });
// result: { data: { id, text }, errors }
Options: text (required), reply_to, media_ids, quote_tweet_id. Requires OAuth.
const result = await upload_media({ file_path: './photo.jpg' });
// result: { data: { id }, errors }
Options: file_path (required), media_type (auto-detected), media_data (base64 alternative)
const result = await delete_tweet({ id: '123456' });
Options: id (required). Requires OAuth.
Set X_BEARER_TOKEN for read-only, or all four OAuth tokens for read+write. 1Password: vault "Agent Secrets", item "X Platform API".
Bookmarks and write operations need OAuth 1.0a (all four tokens), not just bearer token.
Your app needs "Read and Write" permissions in the X Developer Portal. Check at https://developer.x.com/en/portal/dashboard
X API v2 has per-endpoint rate limits. The SDK handles rate limit headers automatically. If you hit limits, back off and retry.