Skip to main content
Glama

Get Codeforces problem metadata

get_problem_metadata
Read-onlyIdempotent

Fetch official Codeforces problem metadata by ID, including name, rating, tags, solved count, and canonical URL, to support problem lookup and analysis.

Instructions

Fetch official metadata for one problem by id ('158A', '158/A' or '158-A'): name, rating, tags, solved count and canonical URL. Note: the Codeforces API does not expose the full problem statement, so this returns metadata only.

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": {
      "problemId": "<problemId>"
    },
    "name": "get_problem_metadata"
  }
}

Input Schema

NameRequiredDescriptionDefault
problemIdYesProblem id such as '158A', '158/A' or '158-A'.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false, and openWorldHint, so safety is covered. The description adds real value beyond them by disclosing that the Codeforces API does not expose the full problem statement, preventing an agent from expecting statement text in the response. It stops short of describing field formats or error behavior for invalid ids.

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?

Two sentences, both earning their place: the first states the action and the returned fields, the second preempts a likely misconception about statement availability. Front-loaded and free of filler.

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 no output schema, the description compensates by naming the return fields, and it flags the statement-exclusion caveat. For a single-parameter read tool this is nearly complete; omitted are failure modes for unknown or malformed ids.

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% and the schema itself already lists the '158A' / '158/A' / '158-A' examples, so the description largely repeats structured data. Baseline 3 applies since the schema carries parameter meaning on its own.

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?

Uses a specific verb and resource ('Fetch official metadata for one problem by id') and enumerates the returned fields (name, rating, tags, solved count, canonical URL). The 'one problem by id' framing implicitly separates it from list-oriented siblings like list_problems and search_problems, though it never names them.

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 'by id' phrasing implies the prerequisite (you must already know the problem id), and the note about the missing statement sets a useful expectation boundary. However, it never states when to prefer this over search_problems or list_problems, leaving alternative selection to inference from the id examples.

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