x-api
X/Twitter API integration for posting tweets, threads, reading timelines, search, and analytics.
Skill by mturac
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/mturac-x-api
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: backend, data, security, writing
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/x-api
What's inside
- Skill name
x-api- Description
- X/Twitter API integration for posting tweets, threads, reading timelines, search, and analytics. Covers OAuth auth patterns, rate limits, and platform-native content posting. Use when the user wants to interact with X programmatically.
- License
- MIT
- Instructions
- 226 lines in SKILL.md · view on GitHub
Before installing
- Instructions call the network
Files (2)
- SKILL.md
- openai.yaml · agents/
SKILL.md (first lines)
# X API
Programmatic interaction with X (Twitter) for posting, reading, searching, and analytics.
## When to Activate
- User wants to post tweets or threads programmatically
- Reading timeline, mentions, or user data from X
- Searching X for content, trends, or conversations
- Building X integrations or bots
- Analytics and engagement tracking
- User says "post to X", "tweet", "X API", or "Twitter API"
## Authentication
### OAuth 2.0 Bearer Token (App-Only)
Best for: read-heavy operations, search, public data.
```bash
# Environment setup
export X_BEARER_TOKEN="your-bearer-token"
```
```python
import os
import requests
bearer = os.environ["X_BEARER_TOKEN"]
headers = {"Authorization": f"Bearer {bearer}"}
# Search recent tweets
resp = requests.get(
"https://api.x.com/2/tweets/search/recent",
headers=headers,
params={"query": "openai codex", "max_results": 10}
)
tweets = resp.json()
```
### OAuth 1.0a (User Context)
Required for: posting tweets, managing account, DMs, and any write flow.
```bash
# Environment setup — source before use
export X_CONSUMER_KEY="your-consumer-key"
export X_CONSUMER_SECRET="your-consumer-secret"
export X_ACCESS_TOKEN="your-access-token"
export X_ACCESS_TOKEN_SECRET="your-access-token-secret"
```
Legacy aliases such as `X_API_KEY`, `X_API_SECRET`, and `X_ACCESS_SECRET` may exist in older setups. Prefer the `X_CONSUMER_*` and `X_ACCESS_TOKEN_SECRET` names when documenting or wiring new flows.
```python
import os
from requests_oauthlib import OAuth1Session
oauth = OAuth1Session(
os.environ["X_CONSUMER_KEY"],
client_secret=os.environ["X_CONSUMER_SECRET"],
resource_owner_key=os.environ["X_ACCESS_TOKEN"],
resource_owner_secret=os.environ["X_ACCESS_TOKEN_SECRET"],
)
```
## Core Operations
### Post a Tweet
```python
resp = oauth.post(
"https://api.x.com/2/tweets",
json={"text": "Hello from OpenAI Codex"}
)
resp.raise_for_status()
tweet_id = resp.json()["data"]["id"]
```
### Post a Thread
```python
def post_thread(oauth, tweets: list[str]) -> list[str]:
ids = []
reply_to = None
for text in tweets:
payload = {"text": text}
if reply_to:
payload["reply"] = {"in_reply_to_tweet_id": reply_to}
resp = oauth.post("https://api.x.com/2/tweets", json=payload)
tweet_id = resp.json()["data"]["id"]
ids.append(tweet_id)
reply_to = tweet_id
return ids
```
### Read User Timeline
```python
resp = requests.get(
f"https://api.x.com/2/users/{user_id}/tweets",
headers=headers,
params={
"max_results": 10,
"tweet.fields": "created_at,public_metrics",
}
)
```
### Search Tweets
```python
resp = requests.get(
"https://api.x.com/2/tweets/search/recent",
headers=headers,
params={
"query": "from:mehmet_turac -is:retweet",
"max_results": 10,
"tweet.fields": "public_metrics,created_at",From mturac/everything-openai-codex, MIT.
More from mturac/everything-openai-codex
- 0.581score
database-migrations
mturac
Database migration best practices for schema changes, data migrations, rollbacks, and zero-downtime deployments across PostgreSQL, MySQL, and common ORMs…
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
deployment-patterns
mturac
Deployment workflows, CI/CD pipeline patterns, Docker containerization, health checks, rollback strategies, and production readiness checklists for web…
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
docker-patterns
mturac
Docker and Docker Compose patterns for local development, container security, networking, volume strategies, and multi-service orchestration.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
fal-ai-media
mturac
Unified media generation via fal.ai MCP — image, video, and audio.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
documentation-lookup
mturac
Use up-to-date library and framework docs via Context7 MCP instead of training data.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
dmux-workflows
mturac
Multi-agent orchestration using dmux (tmux pane manager for AI agents).
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
investor-materials
mturac
Create and update pitch decks, one-pagers, investor memos, accelerator applications, financial models, and fundraising materials.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
investor-outreach
mturac
Draft cold emails, warm intro blurbs, follow-ups, update emails, and investor communications for fundraising.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
market-research
mturac
Conduct market research, competitive analysis, investor due diligence, and industry intelligence with source attribution and decision-oriented summaries.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
mle-workflow
mturac
Production machine-learning engineering workflow for data contracts, reproducible training, model evaluation, deployment, monitoring, and rollback.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
exa-search
mturac
Neural search via Exa MCP for web, code, and company research.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
product-capability
mturac
Translate PRD intent, roadmap asks, or product discussions into an implementation-ready capability plan that exposes constraints, invariants, interfaces, and…
SkillCFreshness: C★ 83Claude Code +9
Signals
- Stars
- 83
- Forks
- 2
- Open issues
- 1
- Last commit (this folder)
- May 18, 2026 (5 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- MIT
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
Same skill elsewhere
Copies of this SKILL.md published by others; search shows only one of them.
- 0.401score
x-api
Fmarzochi
X/Twitter API integration for posting tweets, threads, reading timelines, search, and analytics.
SkillAFreshness: A★ 67Claude Code +9 - 0.345score
x-api
ysyecust
X/Twitter API integration for posting tweets, threads, reading timelines, search, and analytics.
SkillCFreshness: C★ 59Claude Code +9
More from mturac
- 0.581score
documentation-lookup
mturac
Use up-to-date library and framework docs via Context7 MCP instead of training data.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
exa-search
mturac
Neural search via Exa MCP for web, code, and company research.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
fal-ai-media
mturac
Unified media generation via fal.ai MCP — image, video, and audio.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
dmux-workflows
mturac
Multi-agent orchestration using dmux (tmux pane manager for AI agents).
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
investor-materials
mturac
Create and update pitch decks, one-pagers, investor memos, accelerator applications, financial models, and fundraising materials.
SkillCFreshness: C★ 83Claude Code +9 - 0.581score
investor-outreach
mturac
Draft cold emails, warm intro blurbs, follow-ups, update emails, and investor communications for fundraising.
SkillCFreshness: C★ 83Claude Code +9
Cite this page
x-api skill. Agent Mart. https://agentmart.dev/skills/mturac-x-api (last updated 2026-10-24)