Skip to main content
Glama
ElectionData MCP

ElectionData MCP

byelections

Read-only

Retrieves Malaysian by-elections with winner, majority, and turnout, newest first, filtered by state and date range. Use it to answer questions on historical by-election outcomes.

Instructions

All by-elections with winner, majority and turnout, newest first. Dates as YYYY-MM-DD.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

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

Input Schema

NameRequiredDescriptionDefault
stateNo
date_toNo
date_fromNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true and openWorldHint=true, so the safety profile is covered. The description adds genuinely useful behavior beyond that: newest-first ordering and the YYYY-MM-DD date format. It does not disclose result limits, pagination, or what happens when all filters are omitted.

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 compact sentences with no filler, and the highest-value facts (scope and sort order) come first. The date-format note is placed last where it reads as a usage footnote.

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?

An output schema exists, so return-field detail is fairly excused, and the ordering/format notes are helpful. Still missing for a 3-parameter list tool are the semantics of 'state' and the default behavior with no arguments, which an agent needs to call it correctly.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must carry parameter meaning. It covers the date format for date_from/date_to, but the 'state' parameter is entirely unexplained (accepted values, name vs abbreviation, whether it filters at all), leaving a substantive gap.

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 the specific resource (by-elections) and enumerates what each record carries (winner, majority, turnout) plus the sort order. An agent can distinguish it from siblings like contest_result or election_summary, though the verb is implicit ('All by-elections') rather than an explicit 'List'.

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

Usage Guidelines2/5

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

There is no explicit when-to-use guidance, no mention of when not to use it, and no pointer to an alternative such as contest_result or election_summary for non-by-election contests. Usage is only implied by the resource name and the presence of state/date parameters.

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