getUserByUsername

2 credits per call

Get X user profile by username/handle. Returns userId for use with getUserPosts.

Try it

Open in playground
kirha tools run x_getUserByUsername \
  --input '{
    "username": "kirha_ai or @kirha_ai"
  }'

Uses the key saved by kirha auth login.

  • usernamestring, required

    e.g., kirha_ai or @kirha_ai

Works in any harness

Get your API key, then install with one command

  • Claude Code
  • OpenCode
  • π
  • Windsurf
  • Gemini CLI
  • Codex
  • Cursor
  • GitHub Copilot