New to Claude Skills? Learn how to install them →

openclaw on GitHub

XURL CLI

Free

Simplify your interactions with the X API.

Get this skill

Free · Opens the source repo

What XURL CLI does

XURL is a command-line interface designed for seamless interaction with the X API, enabling users to perform a variety of operations such as posting updates, sending direct messages, and managing followers. With a focus on authenticated access, XURL allows developers and designers to work efficiently with X's features through straightforward command shortcuts that return JSON outputs. This makes it an ideal tool for those who prefer working in a terminal environment and need to integrate X API functionality into their workflows.

The CLI supports a wide range of commands for managing posts, including creating, replying to, quoting, and deleting content. Users can also search for posts, retrieve timelines, and manage their interactions with other users, such as following or blocking accounts. For media handling, XURL provides commands to upload images and videos, check their processing status, and associate them with posts, streamlining the media management process.

Additionally, XURL offers robust authentication and app management capabilities. Users can check their authentication status, list applications, and set defaults for app usage. For advanced users, the tool includes a raw API mode, allowing for direct interaction with any v2 endpoint, which is useful for executing complex requests that may not be covered by the provided shortcuts. This flexibility makes XURL a powerful tool for developers looking to leverage the full potential of the X API.

Overall, XURL is well-suited for developers and designers who need a reliable, scriptable interface for managing their interactions with the X platform, whether for personal use, application development, or automation tasks.

When to use it

Use XURL when you need to automate or script interactions with the X API, especially if you prefer working in a command-line environment.

When not to use it

Avoid using XURL if you require a graphical interface or if you are not comfortable with command-line tools.

What you can build with it

Automating Social Media Posts

Use XURL to schedule and automate posting updates to your X account, streamlining your social media management.

Managing Direct Messages

Utilize XURL to send and manage direct messages on X, making it easier to handle communications programmatically.

Integrating with Applications

Incorporate XURL into your applications to interact with the X API for features like user management and content retrieval.

How to install XURL CLI

View source

1. Install with the skills CLI

npx skills add openclaw/openclaw/xurl --agent claude-code

2. Or install it manually

Download the skill folder and drop it into ~/.claude/skills/ for all projects, or .claude/skills/ to scope it to one repo. Restart Claude Code so it picks up the new skill.

Anthropic's agentic coding CLI, and the reference implementation of Agent Skills. Drop a skill folder into ~/.claude/skills and Claude Code loads it automatically whenever a task matches the skill's description. Claude Code docs

Inside SKILL.md

Written by openclaw

xurl

Use xurl for X API work. Shortcut commands return JSON; raw mode works for any v2 endpoint.

Secret safety

  • Never read, print, summarize, upload, or inspect ~/.xurl.
  • Never ask user to paste tokens/secrets into chat.
  • Do not run auth commands with inline secrets.
  • Do not use --verbose in agent sessions; it can expose auth headers.
  • Check auth with xurl auth status.

Common shortcuts

xurl post "Hello world!"
xurl reply POST_ID "Nice."
xurl quote POST_ID "My take"
xurl delete POST_ID
xurl read POST_ID
xurl search "query" -n 20
xurl whoami
xurl user @handle
xurl timeline -n 20
xurl mentions -n 10
xurl like POST_ID
xurl unlike POST_ID
xurl repost POST_ID
xurl unrepost POST_ID
xurl bookmark POST_ID
xurl unbookmark POST_ID
xurl followers -n 20
xurl following -n 20
xurl follow @handle
xurl unfollow @handle
xurl block @handle
xurl unblock @handle
xurl mute @handle
xurl unmute @handle
xurl dm @handle "message"
xurl dms -n 10

POST_ID can be a full https://x.com/<user>/status/<id> URL.

Media

xurl media upload image.jpg
xurl media upload clip.mp4
xurl media status MEDIA_ID
xurl post "caption" --media-id MEDIA_ID

Videos may need processing; poll media status.

Auth/app management

xurl auth status
xurl auth apps list
xurl auth default
xurl auth default APP_NAME USERNAME
xurl auth apps remove APP_NAME

Per request:

xurl --app APP_NAME /2/users/me
xurl --auth oauth2 /2/users/me

Raw API

xurl /2/users/me
xurl -X POST /2/tweets -d '{"text":"Hello world!"}'
xurl '/2/tweets/search/recent?query=openclaw&max_results=10'

Use raw mode when shortcuts do not cover the endpoint. Keep payloads in temp files for complex JSON.

Output and errors

  • JSON stdout on success.
  • Non-zero exit on API/auth/network errors.
  • 401/403: auth, scope, or app mismatch; check xurl auth status.
  • 429: rate limited; back off.
  • Media upload failures: check file type/size and media processing status.

Frequently asked questions about XURL CLI

Similar skills