Skip to main content
Glama

x_search

Read-only

Searches X posts, threads, and users with filters for handles and dates. Analyzes images and videos to answer queries with cited sources.

Instructions

Answer a query using agentic search over X (Twitter).

Searches posts, threads, and users on X. Can filter by handle allow/deny
lists and a date range, and optionally analyze images/videos attached to posts.

Args:
    prompt: Search query or question about X content.
    model: Grok model driving the agent (default `grok-4.3`).
    allowed_x_handles: Restrict search to these handles (max 10, mutually exclusive with excluded).
    excluded_x_handles: Exclude these handles (max 10).
    from_date: Inclusive start date as `DD-MM-YYYY`.
    to_date: Inclusive end date as `DD-MM-YYYY`.
    enable_image_understanding: Let the agent analyze images in posts.
    enable_video_understanding: Let the agent analyze videos in posts (X Search only).
    include_inline_citations: Embed `[1]`-style citation markers into the answer.
    max_turns: Cap the agent's reasoning/tool turns.

Returns:
    Markdown with the answer body followed by a `**Sources:**` list of cited posts.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
promptYes
modelNogrok-4.3
allowed_x_handlesNo
excluded_x_handlesNo
from_dateNo
to_dateNo
enable_image_understandingNo
enable_video_understandingNo
include_inline_citationsNo
max_turnsNo
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already provide readOnlyHint=true, and the description's 'search' wording aligns. The description adds detail about image/video analysis, citations, and max turns, which are not in annotations. No contradictions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The main description is a single clear sentence, but the 'Args' section is somewhat lengthy. However, it is well-organized and front-loaded with the purpose. Slight redundancy but acceptable given schema lacks descriptions.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers all 10 parameters, the return format (Markdown with sources), and the tool's agentic behavior. Missing details on error handling or limits, but sufficient for selection and invocation given the output schema absent.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description compensates with the 'Args' block explaining each parameter, including format for dates, defaults, and max constraints. While some descriptions are terse, they add needed meaning beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states it answers a query by searching over X (Twitter) including posts, threads, and users. The verb 'search' and resource 'X' are specific, and it is distinct from siblings like web_search and grok_agent.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage for answering questions about X content, but does not explicitly state when to use vs. alternatives like web_search or grok_agent. No when-not-to-use guidance is provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/merterbak/Grok-MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server