Skip to main content
Glama
alterlab-mcp-server

alterlab-mcp-server

Validate Session

alterlab_validate_session
Read-onlyIdempotent

Checks whether a stored session is still active and its cookies remain valid, returning status and an invalidation reason so you can verify sessions before scraping.

Instructions

Validate whether a stored session is still active and its cookies are valid. Run this before scraping if you suspect a session may have expired. Returns the session status and a reason if invalid.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "session_id": "<session_id>"
    },
    "name": "alterlab_validate_session"
  }
}

Input Schema

NameRequiredDescriptionDefault
session_idYesUUID of the session to validate

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.5.0

TDQS

A3.8/5.0
Behavior3/5

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

Annotations already declare readOnly, idempotent, non-destructive and open-world, so the safety profile is covered by structured data. The description adds the useful detail that the response includes a status plus a failure reason, but says nothing about cost, side effects on the session, or whether validation extends session lifetime.

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

Conciseness5/5

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

Three short sentences with zero padding: what it does, when to run it, and what comes back. The trigger guidance is placed immediately after the purpose statement.

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?

For a single-parameter read tool with no output schema, the description covers purpose, trigger, and the shape of the return value. It could go slightly further by indicating how to obtain a session_id or what to do on an invalid result, but nothing essential for a correct call is missing.

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

Parameters3/5

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

Schema coverage is 100% and the single parameter is fully described in the schema (UUID of the session to validate). The description adds no format, sourcing, or constraint detail beyond that, so the schema carries the weight and the baseline 3 applies.

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

Purpose4/5

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

States a specific verb and resource: validate a stored session's liveness and cookie validity, plus what it returns (status and reason). An agent can distinguish it from create/list/delete siblings, though the boundary against get_session and refresh_session is left implicit.

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

Usage Guidelines4/5

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

"Run this before scraping if you suspect a session may have expired" gives a concrete trigger condition. It stops short of naming alternatives (e.g., refresh_session to repair an invalid session), so the routing logic after a negative result is unstated.

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