X MCP Ai
Safety-first X (Twitter) API v2 MCP server: 41 typed tools across 12 packages…
- Pricing
- Open source
- Runs
- Locally
- Version
- 0.8.0
- Listing updated
- 6 days ago
About X MCP Ai
X MCP Ai is an open-source MCP server. It runs locally on your machine and is started by your AI client.
Safety-first X (Twitter) API v2 MCP server: 41 typed tools across 12 packages, policy-gated.
Install
Run in a terminal
claude mcp add x-mcp-ai --env X_MCP_CLIENT_SECRET='<X_MCP_CLIENT_SECRET>' --env X_MCP_BEARER_TOKEN='<X_MCP_BEARER_TOKEN>' -- npx -y x-mcp-aiAdd to claude_desktop_config.json
{
"mcpServers": {
"x-mcp-ai": {
"command": "npx",
"args": [
"-y",
"x-mcp-ai"
],
"env": {
"X_MCP_CLIENT_SECRET": "<X_MCP_CLIENT_SECRET>",
"X_MCP_BEARER_TOKEN": "<X_MCP_BEARER_TOKEN>"
}
}
}
}Add to ~/.cursor/mcp.json
{
"mcpServers": {
"x-mcp-ai": {
"command": "npx",
"args": [
"-y",
"x-mcp-ai"
],
"env": {
"X_MCP_CLIENT_SECRET": "<X_MCP_CLIENT_SECRET>",
"X_MCP_BEARER_TOKEN": "<X_MCP_BEARER_TOKEN>"
}
}
}
}Add to .vscode/mcp.json
{
"servers": {
"x-mcp-ai": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"x-mcp-ai"
],
"env": {
"X_MCP_CLIENT_SECRET": "<X_MCP_CLIENT_SECRET>",
"X_MCP_BEARER_TOKEN": "<X_MCP_BEARER_TOKEN>"
}
}
}
}Add to ~/.codeium/windsurf/mcp_config.json
{
"mcpServers": {
"x-mcp-ai": {
"command": "npx",
"args": [
"-y",
"x-mcp-ai"
],
"env": {
"X_MCP_CLIENT_SECRET": "<X_MCP_CLIENT_SECRET>",
"X_MCP_BEARER_TOKEN": "<X_MCP_BEARER_TOKEN>"
}
}
}
}Add to your client's MCP settings (most use this shape)
{
"mcpServers": {
"x-mcp-ai": {
"command": "npx",
"args": [
"-y",
"x-mcp-ai"
],
"env": {
"X_MCP_CLIENT_SECRET": "<X_MCP_CLIENT_SECRET>",
"X_MCP_BEARER_TOKEN": "<X_MCP_BEARER_TOKEN>"
}
}
}
}Using several servers? Build one config file with the MCP config generator.
Configuration
X_MCP_AUTH_MODEAuthentication mode: oauth2 (default) or app-only.X_MCP_CLIENT_IDOAuth 2.0 client ID (oauth2 mode).X_MCP_CLIENT_SECRETOAuth 2.0 client secret (confidential clients only).X_MCP_BEARER_TOKENApplication-only bearer token (app-only mode).X_MCP_TOKEN_FILEPath to the rotating OAuth 2.0 token store (default: OS-resolved).X_MCP_TOKEN_KEYCHAINSet to 1 to keep OAuth 2.0 tokens in the OS keychain (macOS, Linux) instead of a token file. Mutually exclusive with an explicit X_MCP_TOKEN_FILE.X_MCP_POLICYPolicy preset: read-only (default), engage, publish, manage, or full.X_MCP_POLICY_ALLOWComma-separated op:domain cells to allow on top of the preset (e.g. read:dm,write:dm).X_MCP_POLICY_DENYComma-separated op:domain cells to deny; deny beats allow beats preset.X_MCP_HIDE_DENIEDSet to 1 to drop policy-denied tools from registration entirely instead of registering them annotated as denied.X_MCP_MEDIA_DIRDirectory uploads must resolve inside. Media upload is disabled unless this is set.X_MCP_AVAILABILITYComma-separated specially-provisioned access classes to declare: pilot, premium-user, enterprise. Unset means the conservative default (app+user, user-only).X_MCP_PROFILES_FILEPath to a profiles file holding named configuration blocks.X_MCP_PROFILEName of the profile to select from the profiles file.X_MCP_TIMEOUT_MSPer-HTTP-request timeout in milliseconds (default 30000).X_MCP_LOG_LEVELDiagnostic verbosity on stderr: silent, error, info (default), or debug.X_MCP_CREDIT_BUDGETSession spend cap in USD.X_MCP_BUDGET_MODEBudget enforcement: warn (default) or hard.
Pricing
Open source
X MCP Ai FAQ
Is X MCP Ai free?
Yes. X MCP Ai is open source, so you can use and self-host it for free.
How do I add X MCP Ai to Claude Code?
Run this command in your terminal: claude mcp add x-mcp-ai --env X_MCP_CLIENT_SECRET='<X_MCP_CLIENT_SECRET>' --env X_MCP_BEARER_TOKEN='<X_MCP_BEARER_TOKEN>' -- npx -y x-mcp-ai
Where this comes from
- Description: from the official MCP Registry entry.
- Install steps: from the official MCP Registry entry.