Skip to main content
Xquik API MCP exposes the REST API through Model Context Protocol. Code Mode is the default. Native mode exposes one tool per OpenAPI operation. Full credentials see 118 JSON or text routes. Private support media downloads use REST. Guest paid_reads keys see exactly 33 GET routes.
Public reads need no connected X account. This covers tweets, profiles, followers, replies, timelines, communities & lists. Every X write requires one. Private DMs and bookmarks also require one. See Connect X account.
This page covers the API MCP server at https://xquik.com/mcp for authenticated account actions and guest paid reads. For public documentation search, use the Docs MCP server at https://docs.xquik.com/mcp.
Codex CLI 0.147.0 and newer preserve the RFC 9207 iss value. Older Codex and affected Goose releases may discard it before token exchange. Follow Codex and Goose OAuth issuer validation to upgrade Codex or use an environment-backed API key.
Supported browsers expose the website’s tool search as a declarative WebMCP form. It performs a read-only GET and never starts an extraction.

Connection

Protocol

Model Context Protocol over Streamable HTTP.

Endpoint

Connect clients to https://xquik.com/mcp.

Server version

server/discover returns the deployed server version.

Authentication

Prefer OAuth 2.1. API keys remain available for clients with secure header storage.
GET and POST on /.well-known/mcp.json return a compatibility document derived from the MCP Registry manifest. /server.json and /.well-known/mcp/server-card.json return the same document. Its standard remotes entry identifies the streamable-http endpoint. Extra top-level convenience fields support older clients. For clarity, they are not MCP Registry or experimental MCP Server Card fields. OAuth clients read GET /.well-known/oauth-protected-resource/mcp for protected-resource metadata. Compatibility clients can also read GET /.well-known/oauth-protected-resource/.well-known/mcp.json; it redirects to the canonical metadata URL. Registry-compatible clients receive a streamable-http remote for https://xquik.com/mcp. OAuth-capable clients discover authentication from the endpoint. Clients without OAuth may send an API key as Authorization: Bearer {XQUIK_API_KEY} or x-api-key: {XQUIK_API_KEY}. Create API keys at https://dashboard.xquik.com/en/account?tab=api-keys. The direct client examples below use OAuth. Use the API-key fallback only when the client documents secure request headers. Agent discovery metadata is also available at https://xquik.com/.well-known/agents.json. That catalog lists the MCP server, the public A2A docs agent, capability endpoints, OAuth metadata, and https://xquik.com/auth.md. The auth.md file explains Client ID Metadata Documents (CIMD), Dynamic Client Registration (DCR), PKCE, and the mcp:tools scope. MCP connection metadata is also available at https://xquik.com/.well-known/mcp.json. DCR at https://xquik.com/api/oauth/register is the supported anonymous OAuth client registration path when a client cannot use CIMD. Agent Skills discovery is available at https://xquik.com/.well-known/agent-skills/index.json. It publishes a SHA-256 digest for Xquik’s hosted SKILL.md so compatible agents can verify the downloaded instructions.

MCP 2026-07-28

Xquik supports MCP 2026-07-28 at the same Streamable HTTP endpoint. Current clients start with server/discover. They do not call initialize or create a session for a modern connection. Use a current MCP SDK. It adds the request _meta envelope and required HTTP headers automatically. Modern requests must advertise both application/json and text/event-stream. server/discover and tools/list include private cache hints with a 5-minute TTL. Catalogs stay immutable and advertise no change subscriptions. Reuse results only within the same authorization context. Never share them across credentials. Xquik also accepts stateless 2025-era clients at the same endpoint. This keeps existing integrations working while current SDKs adopt 2026-07-28.
Modern Xquik connections are request-scoped. Ignore legacy session IDs and resume state. Let the client SDK negotiate the protocol.
Unauthenticated requests to https://xquik.com/mcp return 401 with a WWW-Authenticate: Bearer challenge. The challenge includes resource_metadata="https://xquik.com/.well-known/oauth-protected-resource/mcp", scope="mcp:tools", and the OAuth realm. The JSON body is { "error": "Authentication required" }. OAuth-capable clients use the challenge to discover the authorization metadata. API-key clients should send x-api-key on the first request. A supplied invalid bearer token adds error="invalid_token" and error_description="Invalid access token" to the challenge.

Authentication

The MCP server supports 2 authentication methods:
  • OAuth 2.1 (recommended): Compatible clients discover Xquik, open the browser login and consent flow, then store and refresh Bearer tokens. Xquik supports CIMD and DCR. No manual client ID, client secret, or API key is required for normal client setup.
  • API key (x-api-key or Authorization: Bearer xq_your_api_key_here): This is an Xquik-specific fallback, not an OAuth token. Do not apply OAuth discovery or refresh rules. Use it only with secure header storage. Full account keys expose 118 catalog routes. Active guest keys expose 33 paid_reads GET routes.
See OAuth 2.1 authorization for discovery URLs, token lifetimes, client registration, and implementation details.

Choose a tool mode

Use the default endpoint for Code Mode:
Code Mode uses 3 tools. API discovery and execution run in isolated sandboxes:

docs

Search X/Twitter scraper & API documentation. Read-only. No credits.

search

Search the X/Twitter API catalog. No network calls or credits.

execute

Call authenticated X/Twitter APIs. Cost follows the endpoint.
server/discover sends no global model instructions. Tool descriptions identify the X/Twitter domain and explain code mechanics. docs searches public documentation. search accepts an async arrow function; spec is global and its first argument. execute accepts the same form; xquik is global and its first argument. OpenAPI and these docs define endpoint behavior. For a guest paid_reads session, execute is read-only, idempotent, and limited to live calls across the 33 eligible GET routes. Use native mode when a client cannot run Code Mode or needs ordinary MCP tools:
Native mode serves an OpenAPI-derived catalog. It validates only the called tool. Full credentials receive docs plus 118 OpenAPI operations. Guest keys receive docs plus 33 eligible GET operations. Each native tool uses its OpenAPI operationId as its stable name. Its input schema, title, description, HTTP method, path, query parameters, and JSON body come from the same OpenAPI contract as REST and the generated SDKs. The server injects authentication and required idempotency headers. It rejects unknown routes, custom headers, redirects, traversal, and unsupported binary responses. docs searches canonical Xquik documentation. Pass a non-empty query string.

search tool

Searches the 118-route full account catalog. The call uses no credits. MCP authentication remains required. The sandbox provides: With a guest paid_reads key, spec.paths contains only 33 eligible GET routes.

execute tool

Executes API calls. The sandbox provides:
Authentication and required idempotency headers are injected automatically. The server reuses each generated key for bounded transient retries. After an unresolved write failure, verify state. Start a new attempt only when safe_to_retry is true. An execute call can run for up to 180 seconds. Disconnecting cancels the call. A timeout does not cancel a durable extraction job. Find it through GET /extractions, then resume with its stored ID. Repeat writes only when the response marks the retry safe. xquik.request() automatically uses the normalized v1 contract. Responses use snake_case fields, date-time fields as Unix seconds, structured error objects, has_more, and next_cursor. A default REST createdAt field becomes created, not created_at, in MCP results.

MCP operation boundary

The REST contract documents 129 operations. Full credentials expose 118 JSON or text routes. These 11 stay outside:
  • Create, list, or revoke account API keys
  • Start account top-ups or charge a saved payment method
  • Create, poll, or top up a guest wallet
  • Download support attachments or draw and extraction exports
Guest wallet credential routes remain direct REST only. MCP cannot execute POST /api/v1/guest-wallets, POST /api/v1/guest-wallets/topups, or GET /api/v1/guest-wallets/status. Follow the accountless guest wallet guide for confirmation, checkout, polling, and top-up steps. A guest paid_reads MCP session exposes exactly the 33 eligible paid-read routes. It cannot execute mutations or noneligible routes. Never start checkout, top-up, subscription, or billing actions because another call returned 402. Report the choices, ask the user to select an amount and option, then wait for explicit confirmation. After confirmation, MCP may execute only an account checkout action present in the full catalog. Guest wallet actions remain direct REST.

MCP vs REST API

MCP follows REST authentication, authorization, billing, and response contracts for every exposed operation.

MCP server

Use MCP for agents and IDE integrations. Full credentials expose 118 catalog routes. Guest keys expose 33 GET reads. Use REST for binary downloads.

REST API

Best for backend services, automation scripts, guest wallet credential routes, and direct programmatic access. The REST contract documents all 129 operations and file download responses.

Website WebMCP

Supported browsers discover open_xquik_tool_search on https://xquik.com. Pass a query string with 1 to 200 characters. The read-only tool opens matching website tools. It needs no authentication or credits. The page uses the current document.modelContext API.
Start with Claude.ai for OAuth login or Claude Code for terminal setup.

Client compatibility

Choose the authentication path that your current client can complete. Xquik keeps OAuth issuer, redirect, resource, and Proof Key for Code Exchange (PKCE) validation enabled for every client. Clients that ignore the optional RFC 9207 iss response parameter can still complete OAuth. Codex CLI 0.147.0 and newer preserve the value. Older Codex and affected Goose releases may require the parameter after discarding it, so retrying OAuth cannot repair those callbacks. Xquik does not weaken issuer validation.

Setup

Web and terminal clients

  1. Open Claude Connectors or Customize > Connectors.
  2. Select +, then Add custom connector.
  3. Enter https://xquik.com/mcp.
  4. Select Add.
  5. In a chat, select + > Connectors, enable Xquik, then select Connect and approve access.
Leave the advanced client ID and client secret fields empty. Custom remote connectors require Pro, Max, Team, or Enterprise. On Team and Enterprise, an Owner or Primary Owner must add the connector first.

OpenAI

Codex CLI 0.147.0 and newer support Xquik OAuth. Remove bearer_token_env_var, then add Xquik and complete OAuth:
Codex CLI, the IDE extension, and the ChatGPT desktop app share the same config.toml MCP configuration.Older releases affected by openai/codex#31573 use the Codex API key fallback below.

Codex API key fallback

Use an environment-backed API key if Codex reports Authorization server response missing required issuer: expected https://xquik.com:
Add this configuration to ~/.codex/config.toml or a trusted project’s .codex/config.toml:
Restart Codex, then run codex mcp list. Do not run codex mcp login xquik while using the bearer-token fallback. Never commit the key or place its value directly in config.toml. See Codex OAuth issuer validation error for recovery steps. Issue #31573 records the fix in Codex CLI 0.147.0.

Editor clients

Add to ~/.cursor/mcp.json (global) or .cursor/mcp.json (project):
Cursor starts OAuth when the server first returns 401. You can also run cursor-agent mcp login xquik. Cursor currently lists MCP access on its paid Individual, Teams, and Enterprise plans.

Other terminal clients

Add the remote server:
If your installed build does not expose the noninteractive add flags, start Copilot CLI and run /mcp add. Enter xquik, choose HTTP, enter https://xquik.com/mcp, keep * for tools, then press Ctrl+S. Run /mcp auth xquik after the server appears. Enterprise policy may block servers outside the organization allowlist.

Remaining API key and adapter paths

API-key fallback is client-specific. ChatGPT custom apps require OAuth and cannot present custom API keys. Codex uses the environment-backed bearer_token_env_var configuration above. For other clients, follow that client’s documented secret-input or environment-variable syntax. Never copy a generic header example into an incompatible schema, place a literal key in a configuration file, or commit a key.
Export your key, then add this entry to ~/.config/goose/config.yaml:
Goose substitutes the environment variable before sending the header. Its current OAuth callback has an RFC 9207 issuer handling defect. Follow Codex and Goose OAuth issuer validation.

Example prompts

Once connected, ask: Monitoring & Events
  • Start watching @elonmusk for new tweets and replies.
  • List the accounts I am currently monitoring.
  • Show monitored account activity from today.
  • Replay stored events for monitor mon_123 using the last next_cursor as cursor.
  • Stop tracking @elonmusk.
Search & Lookup
  • Search recent X posts about TypeScript.
  • Find recent tweets from @vercel.
  • Read this tweet: https://x.com/elonmusk/status/1893456789012345678
  • Get metrics for this tweet: https://x.com/vercel/status/1893704267862470862
User Profiles & Follows
  • Get @username follower count.
  • Read @openai profile bio.
  • Check whether @elonmusk follows @SpaceX.
  • Check whether @vercel and @nextjs follow each other.
Trends
  • Show current X trends.
  • Show top trending topics in the US.
  • Check whether AI is trending today.
Radar & News
  • Show current Radar trends.
  • Show current Reddit posts with text, links, media, and engagement signals.
  • Show top developer trends today.
  • Show startups ranked by available growth metrics.
  • Get technology topics from the last 12 hours.
  • Show popular knowledge topics right now.
  • Show regional trends for a selected region.
  • Find trending tech news and draft a tweet about one item.
Extractions
  • Pull all replies to this tweet: https://x.com/elonmusk/status/1893456789012345678
  • List users who retweeted this tweet: https://x.com/vercel/status/1893704267862470862
  • Estimate the cost to extract all followers of @elonmusk.
  • Get quote tweets for this post: https://x.com/openai/status/1893456789012345678
  • Extract the full thread for this tweet: https://x.com/elonmusk/status/1893704267862470862
Giveaways
  • Pick 3 random winners from this tweet: https://x.com/example_user/status/1893456789012345678
  • Run a giveaway draw where participants must have retweeted and have at least 100 followers.
  • Show the results of my last giveaway draw.
Webhooks
  • Set up a webhook at https://my-server.com/events for new tweets.
  • List configured webhook endpoints.
  • Remove the webhook pointing to my old server.
Tweet Composition
  • Write a casual launch tweet for my new product.
  • Research a fresh angle from Compose’s Radar recommendations.
  • Optimize the draft for engagement.
  • Score this draft: Just shipped v2.0 of our API. What do you think?
  • Improve this tweet to get more replies.
Style Analysis & Drafts
  • Analyze how @elonmusk tweets.
  • Compare @vercel and @nextjs tweeting styles.
  • Show cached tweet performance.
  • Save this tweet draft for later.
  • Show all saved drafts.
  • Set my X account to @myusername.
X Write Actions
  • Post a tweet saying: Just shipped v2.0!
  • Like this tweet: https://x.com/vercel/status/1893704267862470862
  • Retweet this: https://x.com/openai/status/1893456789012345678
  • Follow @vercel from my connected account.
  • Send a DM to user ID 44196397 saying hello.
  • Post a tweet saying: New feature! Use public image URL https://example.com/launch.png.
Account & Usage
  • Show my plan and month-to-date usage.
  • Check whether I have enough budget left for a large extraction.

Framework guides

Build agents with Xquik’s MCP tools in your preferred framework:

LangChain

Python agents with LangChain + LangGraph

CrewAI

Multi-agent crews with CrewAI

Pydantic AI

Type-safe agents with Pydantic AI

Google ADK

Multi-agent assistants with Google ADK

Mastra

TypeScript agents with Mastra

Microsoft Agent Framework

Python agents with Microsoft Agent Framework

Migrate from Composio

Move an existing Composio workflow to Xquik

AI agent skill

The Xquik Skill gives AI coding agents deep knowledge of the Xquik API without requiring an MCP connection. Install it to let your agent write API integrations, set up webhooks, and configure MCP connections using Xquik best practices. Works with Claude Code, Cursor, GitHub Copilot, Codex, Windsurf, VS Code, Gemini CLI, and other Skill-capable agents. It covers MCP tools and 129 REST API operations.