Skip to main content
Glama

StackExchange (Unofficial)

Get Answers

get_answers
Read-onlyIdempotent

Get answers for a specific StackExchange question by ID. Returns answer body, score, and whether it is accepted.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "question_id": 419163
    },
    "name": "get_answers"
  }
}

Input Schema

NameRequiredDescriptionDefault
siteNoStackExchange site slug (default: stackoverflow)
_apiKeyNoOptional, a StackExchange API key (free, 10k/day) for a dedicated quota. The gateway supplies a platform key; pass your own only to override.
question_idYesThe numeric question ID from the question URL

Output Schema

NameRequiredDescriptionDefault
siteYesThe StackExchange site slug used
countYesNumber of answers returned
answersYesArray of answers to the question
question_idYesThe question ID for which answers were retrieved
quota_remainingYesRemaining API quota for this user

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / _apiKey / description
      Previous value: -"Optional — a StackExchange API key (free, 10k/day) for a dedicated quota. The gateway supplies a platform key; pass your own only to override."New value: +"Optional, a StackExchange API key (free, 10k/day) for a dedicated quota. The gateway supplies a platform key; pass your own only to override."
  2. Changed1 schema field changed
    • addedInput schema / properties / _apiKey
      Added value: +{
      +  "description": "Optional — a StackExchange API key (free, 10k/day) for a dedicated quota. The gateway supplies a platform key; pass your own only to override.",
      +  "type": "string"
      +}
  3. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "answers": {
      +      "description": "Array of answers to the question",
      +      "items": {
      +        "properties": {
      +          "answer_id": {
      +            "description": "Unique answer identifier",
      +            "type": "number"
      +          },
      +          "body": {
      +            "description": "Answer body HTML content",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "created": {
      +            "description": "ISO 8601 creation timestamp",
      +            "type": "string"
      +          },
      +          "is_accepted": {
      +            "description": "Whether this is the accepted answer",
      +            "type": "boolean"
      +          },
      +          "last_activity": {
      +            "description": "ISO 8601 last activity timestamp",
      +            "type": "string"
      +          },
      +          "owner_name": {
      +            "description": "Display name of the answer author",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "owner_reputation": {
      +            "description": "Reputation score of the answer author",
      +            "type": [
      +              "number",
      +              "null"
      +            ]
      +          },
      +          "score": {
      +            "description": "Answer score (votes)",
      +            "type": "number"
      +          }
      +        },
      +        "required": [
      +          "answer_id",
      +          "body",
      +          "score",
      +          "is_accepted",
      +          "owner_name",
      +          "owner_reputation",
      +          "created",
      +          "last_activity"
      +        ],
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "count": {
      +      "description": "Number of answers returned",
      +      "type": "number"
      +    },
      +    "question_id": {
      +      "description": "The question ID for which answers were retrieved",
      +      "type": "number"
      +    },
      +    "quota_remaining": {
      +      "description": "Remaining API quota for this user",
      +      "type": [
      +        "number",
      +        "null"
      +      ]
      +    },
      +    "site": {
      +      "description": "The StackExchange site slug used",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "site",
      +    "question_id",
      +    "count",
      +    "quota_remaining",
      +    "answers"
      +  ],
      +  "type": "object"
      +}
  4. Changed1 schema field changed
    • addedInput schema / examples
      Added value: +[
      +  {
      +    "question_id": 419163
      +  },
      +  {
      +    "question_id": 927358,
      +    "site": "serverfault"
      +  }
      +]
  5. First observed

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already declare readOnly, idempotent, non-destructive, open-world behavior, so the safety profile is covered. The description adds that results include answer body, score, and accepted status, but says nothing about ordering, pagination, empty-answer cases, or API-key quota behavior even though the schema exposes an _apiKey override with a 10k/day limit.

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?

Two tight sentences with the core action front-loaded and no filler. The second sentence partly restates what the output schema already conveys, a minor redundancy, but overall it is efficiently sized.

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?

With an output schema covering return values and annotations covering the safety profile, the description only needs to state the lookup target, which it does. The remaining gap is guidance on site selection and quota/auth behavior, which is modest for a single-required-parameter read tool.

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 description coverage is 100%, so every parameter (site, _apiKey, question_id) is already documented in the schema, including the site default and the API-key override semantics. The description adds no syntax, format, or default information beyond that, so the baseline of 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?

The description names a specific verb and resource: 'Get answers for a specific StackExchange question by ID.' That is unambiguous and clearly distinct from a listing tool like list_questions_by_tag. It stops short of explicitly naming an alternative, so it is clear but not sibling-routing.

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?

Usage is only implied: the agent must already have a question ID to call this. There is no explicit 'use this when...' statement, no exclusion of the listing/search siblings, and no note about when to pick a site-scoped lookup versus a tag listing.

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.