Skip to main content
Glama

X-EGO

Check whether this user was seen before

xego_check_pairwise_seen_before
Idempotent

Checks whether a given pairwise ID has already been seen within this audience. It protects against one person acting as several different users (multiple accounts, repeat voting, and similar).

WHEN TO USE: returning-user checks and one-human-one-vote. Requires a pairwise_id previously obtained from a verify call for YOUR audience.

Only the pair (audience, pairwise_id) and the time of first occurrence are recorded. No personal data.

The ledger is PERMANENT and shared across every instance and session of the server (Postgres) — it survives restarts and new MCP sessions. record_if_new=true writes atomically (no window for a concurrent write).

Args:

  • audience (string): the service domain or URL. Normalized to a bare lowercase hostname — the same key the proof was issued under, so a domain and its URL form are the same audience.

  • pairwise_id (string): the identifier from xego_verify_proof.

  • record_if_new (boolean): record the user if they are new.

Returns (JSON): { "seen_before": boolean, // true = already on record "first_seen": number|null, // Unix time of first occurrence "recorded_now": boolean // true = recorded just now }

Errors (free, no sybil check performed): invalid_audience (the audience cannot be normalized to a domain), dedup_store_unavailable (temporary — retry). Neither ever means 'not seen before'.

PAID TOOL (x402): this call costs $0.01 USD in USDC per execution, unless you send a valid X-EGO pilot operator key as an 'Authorization: Bearer ' HTTP header (operator calls are free). Calling without payment returns an x402 error whose _meta["x402/error"] contains payment requirements (accepts) and step-by-step instructions how to pay and retry. Invalid input is rejected for free before any payment is taken.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
audienceYesThe service being asked about. Domain (forum.example.com) or full URL (https://forum.example.com/...) — both are normalized to a bare lowercase hostname, exactly like the token's aud.
pairwise_idYesThe user's pairwise identifier (from the xego_verify_proof result).
record_if_newNoIf true and the user has not been seen yet, they are recorded immediately — an atomic 'is new? then mark' in one call.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Goes well beyond the annotations by disclosing that the ledger is PERMANENT and shared across instances/sessions (Postgres, survives restarts), that record_if_new writes atomically with no concurrency window, that only (audience, pairwise_id) plus first-seen time is stored, and the full paid-tool x402 flow including a free operator-key bypass. It also enumerates error cases and clarifies none of them mean 'not seen before'.

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?

Well-structured and front-loaded, with purpose first, then WHEN TO USE, ledger semantics, Args, Returns, and Errors/payment. The Args and Returns sections partially restate the schema, which adds length, but the added value (normalization, atomicity, error semantics) keeps it mostly efficient.

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

Completeness5/5

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

Although no output schema exists, the description inlines the JSON return shape, documents error cases with their meaning, and explains the payment model. Nothing an agent needs to call and interpret the tool correctly appears to be missing.

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?

With 100% schema coverage the schema already documents all three parameters, so the baseline is 3. The description adds meaning on top: audience is normalized to a bare lowercase hostname (same key the proof was issued under), and record_if_new's atomic 'is new? then mark' behavior is explained beyond the schema's wording.

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?

The description names a specific verb and resource ('Checks whether a given pairwise ID has already been seen within this audience') and states the concrete goal it serves (preventing one person acting as several users). It also positions the tool in the workflow by noting the pairwise_id must come from a verify call, which distinguishes it from the verify siblings.

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

Usage Guidelines5/5

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

An explicit 'WHEN TO USE' line names the scenarios (returning-user checks, one-human-one-vote) and the prerequisite ('Requires a pairwise_id previously obtained from a verify call for YOUR audience'). An agent knows both when to call it and what inputs must exist first.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources