/xpoz:xpoz-best-practicesfrom xpoz
Reference for Xpoz social media intelligence platform covering query syntax, field selection, pagination, auth, and best practices for Twitter, Instagram, Reddit, and TikTok via MCP, SDK, or CLI.
Ships in xpoz. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Xpoz is a social media intelligence platform providing access to Twitter/X, Instagram, Reddit, and TikTok data through MCP tools, Python SDK, TypeScript SDK, and CLI — no social media API keys required.
Load this skill for any Xpoz interaction — not just when the user explicitly asks about best practices. It provides the context needed to use Xpoz tools correctly:
MCP — add the Xpoz MCP server to your agent's config. The server URL is https://mcp.xpoz.ai/mcp. Most MCP clients handle OAuth automatically on first tool call.
Example for Claude Code (~/.claude.json):
{
"mcpServers": {
"xpoz": {
"url": "https://mcp.xpoz.ai/mcp",
"transport": "streamable-http"
}
}
}
Python SDK:
pip install xpoz
from xpoz import XpozClient
client = XpozClient() # reads XPOZ_API_KEY env var
results = client.twitter.search_posts("artificial intelligence")
print(f"Found {results.pagination.total_rows:,} tweets")
client.close()
TypeScript SDK:
npm install @xpoz/xpoz
import { XpozClient } from "@xpoz/xpoz";
const client = new XpozClient();
await client.connect();
const results = await client.twitter.searchPosts("artificial intelligence");
console.log(`Found ${results.pagination.totalRows.toLocaleString()} tweets`);
await client.close();
CLI:
pip install xpoz-cli
xpoz-cli twitter search_posts --query "artificial intelligence" --limit 20
See references/authentication.md for detailed auth flows (MCP, SDK, CLI). See references/sdk.md for complete Python & TypeScript SDK reference. See references/cli.md for CLI installation, commands, and rendering modes.
All keyword search tools support boolean query syntax:
| Operator | Example | Effect |
|---|---|---|
| Exact phrase | "machine learning" | Matches exact phrase |
| OR | "AI" OR "artificial intelligence" | Matches either term |
| AND | "Tesla" AND "earnings" | Matches both terms |
| Grouping | ("deep learning" OR "neural network") AND python | Combines operators |
Date filtering: Use startDate / endDate in YYYY-MM-DD format. Omit to use defaults (varies by tool).
Content filtering (Twitter only): Set filterOutRetweets: true to exclude retweets.
Forbidden in query string: from:, to:, lang:, since:, until:, filter: — use dedicated parameters instead.
| Tool | Purpose |
|---|---|
getTwitterUser / getTwitterUsers | Look up 1-100 users by ID or username |
searchTwitterUsers | Fuzzy search users by name |
getTwitterUserConnections | Get followers or following |
getTwitterUsersByKeywords | Find users who posted about a topic |
getTwitterPostsByIds | Get 1-100 posts by ID |
getTwitterPostsByAuthor | Get all posts from a username |
getTwitterPostsByKeywords | Search posts by keywords |
getTwitterPostRetweets | Get retweets of a post |
getTwitterPostQuotes | Get quote tweets of a post |
getTwitterPostComments | Get replies to a post |
getTwitterPostInteractingUsers | Get commenters, quoters, or retweeters |
countTweets | Count tweets matching a phrase |
See references/twitter.md for all parameters, fields, and examples.
| Tool | Purpose |
|---|---|
getInstagramUser | Look up user by ID or username |
searchInstagramUsers | Fuzzy search users by name |
getInstagramUserConnections | Get followers or following |
getInstagramUsersByKeywords | Find users who posted about a topic |
getInstagramPostInteractingUsers | Get commenters or likers of a post |
getInstagramPostsByIds | Get posts by strong_id |
getInstagramPostsByUser | Get posts from a user |
getInstagramPostsByKeywords | Search posts by keywords in captions/subtitles |
getInstagramCommentsByPostId | Get comments on a post |
See references/instagram.md for all parameters, fields, and examples.
| Tool | Purpose |
|---|---|
getRedditUser | Look up user by username |
searchRedditUsers | Fuzzy search users by name |
getRedditUsersByKeywords | Find users who posted about a topic |
getRedditPostsByKeywords | Search posts by keywords |
getRedditPostWithCommentsById | Get a post with all its comments |
getRedditCommentsByKeywords | Search comments by keywords |
searchRedditSubreddits | Search subreddits by name |
getRedditSubredditWithPostsByName | Get subreddit details with posts |
getRedditSubredditsByKeywords | Search subreddits by keyword in description |
See references/reddit.md for all parameters, fields, and examples.
| Tool | Purpose |
|---|---|
getTiktokUser | Look up user by ID or username |
searchTiktokUsers | Fuzzy search users by name |
getTiktokUsersByKeywords | Find users who posted about a topic |
getTiktokUsersByHashtags | Find users who used specific hashtags |
getTiktokPostsByIds | Get posts by ID |
getTiktokPostsByUser | Get posts from a user |
getTiktokPostsByKeywords | Search posts by keywords |
getTiktokPostsByHashtags | Search posts by hashtags |
getTiktokCommentsByPostId | Get comments on a post |
See references/tiktok.md for all parameters, fields, and examples.
Setting up tracking is a best practice for getting more complete data from Xpoz. Tracked items are crawled regularly in the background, which means:
Track keywords, users, subreddits, and hashtags across all 4 platforms.
Supported types per platform:
| Platform | keyword | user | subreddit | hashtag |
|---|---|---|---|---|
| Yes | Yes | — | — | |
| Yes | Yes | — | — | |
| Yes | Yes | Yes | — | |
| TikTok | Yes | Yes | — | Yes |
View current tracking:
MCP: call getTrackedItems
Python: client.tracking.get_tracked_items()
TypeScript: await client.tracking.getTrackedItems()
CLI: xpoz-cli tracking get_tracked_items
Add tracked items:
MCP: call addTrackedItems with items: [{ phrase: "AI agents", type: "keyword", platform: "twitter" }]
Python: client.tracking.add_tracked_items([{ "phrase": "AI agents", "type": "keyword", "platform": "twitter" }])
TypeScript: await client.tracking.addTrackedItems([{ phrase: "AI agents", type: "keyword", platform: "twitter" }])
CLI: xpoz-cli tracking add_tracked_items --items '[{"phrase": "AI agents", "type": "keyword", "platform": "twitter"}]'
Remove tracked items:
MCP: call removeTrackedItems with items: [{ phrase: "AI agents", type: "keyword", platform: "twitter" }]
Python: client.tracking.remove_tracked_items([...])
TypeScript: await client.tracking.removeTrackedItems([...])
CLI: xpoz-cli tracking remove_tracked_items --items '[{"phrase": "AI agents", "type": "keyword", "platform": "twitter"}]'
See xpoz-social-tracking for full tracking workflows and advanced patterns.
All paginated tools support three response modes via responseType:
| Mode | Behavior | Best For |
|---|---|---|
"fast" (default) | Returns up to 300 results immediately | Quick lookups, exploration |
"paging" | Async — returns operationId, poll with checkOperationStatus | Large datasets, page-by-page |
"csv" | Async CSV export to S3 — returns download URL | Bulk export, offline analysis |
See references/pagination-and-export.md for async polling patterns, pagination, and CSV export details.
Pass fields to request only the data you need. This reduces response size and improves performance.
MCP: fields: ["id", "text", "authorUsername", "likeCount"]
Python: fields=["id", "text", "author_username", "like_count"]
TypeScript: fields: ["id", "text", "authorUsername", "likeCount"]
CLI: --fields id text author_username like_count
Each platform has different available fields — see the platform-specific references for complete field lists.
Search → Analyze → Export:
Find Users → Get Their Posts → Analyze:
Data Freshness:
forceLatest: true to bypass cache and force a live fetch (increases latency and cost)| Problem | Solution |
|---|---|
| MCP: "Unauthorized" | Re-run OAuth flow — see references/authentication.md |
SDK: AuthenticationError | Verify key at xpoz.ai/settings |
| Empty results | Check query syntax, widen date range, try different keywords |
| Stale data | Use forceLatest: true to bypass cache |
| Operation timeout | Keep polling checkOperationStatus every ~5s until status is no longer running |
| Token exchange fails | Ask user to re-authorize — codes are single-use |
For complete parameters, response fields, patterns, and examples:
references/authentication.md (opens in a new tab)references/cli.md (opens in a new tab)references/instagram.md (opens in a new tab)references/pagination-and-export.md (opens in a new tab)references/reddit.md (opens in a new tab)references/sdk.md (opens in a new tab)references/tiktok.md (opens in a new tab)references/twitter.md (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
14 skills in this plugin
/ai-answer-traceAsk Claude, ChatGPT, and Gemini a question and capture the full trace behind the answer (the search queries each engine ran, the pages it retrieved, and the sources it cited, span by span). Use when asked to "trace an AI answer", "see what AI engines cite", "check AI citations", "which sources does ChatGPT/Claude/Gemini use", "why does the AI recommend X", or for any GEO (Generative Engine Optimization) measurement./competitive-intelCompare brands and products across social media — share of voice, sentiment, positioning, and audience overlap using Xpoz. Use when asked to "compare brands", "competitive analysis", "share of voice", "brand vs brand", or "competitive intelligence"./creator-authenticity-scoreScore an Instagram creator's (or a list of creators') audience authenticity and engagement quality using Xpoz. Measures real engagement rate against views rather than follower count, the bot/spam share of their comments, and an overall 0-100 authenticity score for influencer vetting and partner selection. Use when asked to "vet this influencer", "are their followers real", "check engagement quality for @username", "rate these Instagram accounts", "compare creators before a sponsorship", or when the user pastes a list of Instagram handles to evaluate./geo-redditMap the most influential Reddit venues for a brand's AI visibility using Xpoz. Finds which subreddits and threads AI engines actually cite when answering buyer questions, where those questions get asked, and which live threads are worth answering. Use when asked to "get cited by AI through Reddit", "which subreddits matter for my brand", "Reddit influence map", "where should we engage on Reddit", or "why does ChatGPT cite Reddit for my category"./geo-visibility-checkOne-shot GEO visibility check for a brand using Xpoz. Runs the buyer questions that matter through Claude, ChatGPT, and Gemini, and reports where the brand appears, who wins instead, and which surfaces the answers are assembled from. Use when asked to "check my AI visibility", "does ChatGPT recommend us", "GEO audit", "where do we show up in AI answers", or "who wins our category in AI answers"./influencer-discoveryFind and rank influencers by niche, engagement, and authenticity using Xpoz. Searches Twitter, Instagram, and Reddit for active voices in any topic. Use when asked to "find influencers", "discover thought leaders", "who's talking about X", "influencer research", or "find KOLs".npx claudepluginhub xpozpublic/xpoz-agent-skills --plugin xpozOther plugins' skills for the same job