Skip to main content
Glama

Grade Calculator API - weighted course grade and score needed on final exam

grade_calculator
Read-onlyIdempotent

Compute current weighted course grade from category weights and scores (percent, fractions like 17/20 or lists) and calculate the exact score required on the final exam for a target grade (and A/B/C/D table). Runs on our server, files are deleted right after the call, nothing stored. Free: 5 calls/day per IP. Paid: Radar API key (from €9/mo at https://radarbg.com/pricing#starter via X-API-Key) or $0.001/call via x402 at https://radarbg.com/x402/grade-calculator.

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": {
      "mode": "final",
      "categories": "Homework | 20 | 92\nMidterm | 40 | 81\nFinal | 40 |",
      "targetPercent": "90"
    },
    "name": "grade_calculator"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeNocurrent (weighted grade) or final (score needed on final)final
categoriesYesOne category per line (or JSON array): Name | weight | score
finalWeightNoWeight of the final exam (optional if an empty-score line exists)
targetPercentNoTarget course grade % (for mode=final)90

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.2/5.0
Behavior5/5

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

Annotations only declare readOnly/idempotent/openWorld; the description adds substantial behavior beyond them: server-side execution, immediate file deletion with nothing stored, a 5-call/day per-IP free tier, and two paid paths (X-API-Key from a pricing page, or $0.001/call via x402 with a direct endpoint). This is exactly the auth, rate-limit, and data-retention context an agent needs before calling.

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 sentences, front-loaded with the computation before pricing/access details, and no filler. The second sentence is dense with URLs and pricing tiers, but every clause (retention, free quota, key header, x402) is operationally load-bearing.

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

Completeness3/5

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

There is no output schema, so the description carries the burden of describing returns, yet it only hints at an 'A/B/C/D table' without saying what the response contains or how it is structured. Behavioral and access context are strong; response-shape coverage is the remaining gap for a 4-parameter tool.

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 coverage is 100%, so the baseline is 3, but the description adds real meaning the schema lacks: scores may be percents, fractions like 17/20, or lists. That format flexibility is the most common failure mode for this tool and is documented only here.

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+resource pair: computing a weighted course grade from category weights/scores and the exact score needed on a final exam for a target grade. It is unambiguous against siblings like percentage_calculator or standard_deviation_calculator, and it names both supported operations (current grade, final-exam target).

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 two operating modes are conveyed (current weighted grade vs. score needed on final) but mostly restate what the mode enum already says; there is no explicit when-to-use/when-not guidance or prerequisite framing. Usage is implied rather than instructed, which is adequate for a self-contained math tool but leaves the agent to infer mode selection.

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