From grok-x-search
Search Twitter/X using Grok API's native `x_search` tool. Returns structured results from recent posts, optimized for discovering practical tips, tool releases, and business use cases from real practitioners.
How this skill is triggered — by the user, by Claude, or both
Slash command
/grok-x-search:grok-x-searchThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Search Twitter/X using Grok API's native `x_search` tool. Returns structured results from recent posts, optimized for discovering practical tips, tool releases, and business use cases from real practitioners.
Search Twitter/X using Grok API's native x_search tool. Returns structured results from recent posts, optimized for discovering practical tips, tool releases, and business use cases from real practitioners.
XAI_API_KEY — xAI API key (from console.x.ai)httpx pip package (pip install httpx)The API key must be set as an environment variable or in a .env file (searched in current directory and up to 4 parent directories).
grok_search.py# Use built-in default queries, save to results.json
python grok_search.py --output results.json
# Custom queries via CLI (repeatable)
python grok_search.py --query "AI tools for business" --query "prompt engineering tips" --output results.json
# Queries from a JSON file
python grok_search.py --queries-file my_queries.json --output results.json
# Custom model
python grok_search.py --output results.json --model grok-3-mini-fast
| Arg | Required | Default | Description |
|---|---|---|---|
--output | Yes | — | Path to save results JSON |
--query | No | — | Search query (repeatable for multiple queries) |
--queries-file | No | — | Path to JSON file with query list (["query1", "query2"]) |
--model | No | grok-4-fast-non-reasoning | Grok model to use |
If neither --query nor --queries-file is provided, uses built-in default queries.
{
"date": "20260312",
"query_count": 4,
"result_count": 12,
"results": [
{
"query": "AI tools for business",
"content": "Full text response from Grok with tweet URLs...",
"source": "x_search"
}
]
}
Plain JSON array of strings:
[
"AI agent workflow automation business",
"new AI tool released this week",
"ChatGPT vs Claude practical comparison"
]
XAI_API_KEY from environment or .envhttps://api.x.ai/v1/responses) with x_search tool enabledoutput array (handles both output_text and nested content formats)https://api.x.ai/v1/responsesx_search (native Twitter/X search, not a web scraper)When no queries are specified, searches for:
These defaults cover tool discovery, workflow automation, prompting, and business cases.
XAI_API_KEY=xai-abc123...
npx claudepluginhub mtkana/claude-code-plugins --plugin grok-x-searchAI-powered summaries of X/Twitter discussions via Grok API. Analyze trending topics, social sentiment, and conversations. Different from raw tweet tools. Requires XAI_API_KEY.
Automates Grok AI interactions on X/Twitter via browser console JavaScript for chat, image generation, tweet analysis, and content strategy. Requires X Premium+. Use for AI-assisted content workflows on X.
Researches X/Twitter via xAI Grok API: account digests, thread/post analysis, trending topics, custom searches for Telegram post ideas.