Skip to main content
Glama
Tanod MCP Server

Tanod MCP Server

Official

check_wcag_contrast

Read-onlyIdempotent

Calculate the WCAG 2.x contrast ratio between a text color and background color, with AA/AAA pass/fail results for normal text, large text, and UI components.

Instructions

utilpeek: Check the WCAG contrast between a text color and a background color. To convert colour formats too use convert_color_check_contrast. Returns the WCAG 2.x contrast ratio of a foreground and a background CSS color, with AA / AAA pass or fail for normal text, large text and UI components (unrounded: #777 on white is 4.48:1 and fails AA). An unparseable or out-of-range color is a 422 before any payment (not charged). A translucent color is composited over the background before the contrast is computed. Typically under 0.1 s. Price: USD 0.001. Free: 10 utilpeek calls per IP per UTC day. Docs: https://tanod.dev/learn/color-contrast-checker-api.html

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": {
      "foreground": "<foreground>",
      "background": "<background>"
    },
    "name": "check_wcag_contrast"
  }
}

Input Schema

NameRequiredDescriptionDefault
backgroundYesThe background color it sits on, in the same CSS color formats.
foregroundYesThe text or UI color, a CSS color: hex (#rgb, #rrggbb, #rrggbbaa), rgb() / rgba(), hsl() / hsla(), oklch(), oklab(), lab(), lch(), color(srgb|display-p3|rec2020) or a CSS color name.

Output Schema

NameRequiredDescriptionDefault
noteNo
errorNoOnly on an error result: an object {code, message}, or the reason string of an x402 PaymentRequired object.
ratioNo
backgroundNo
compositedNo
foregroundNo
gamut_noteNo
large_textNo
ratio_textNo
normal_textNo
ui_componentsNo
ratio_unroundedNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.4

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the readOnly/idempotent/non-destructive annotations, it discloses what is returned (ratio plus AA/AAA verdicts for normal text, large text and UI components), validation failure behavior (422 before any payment, not charged), translucent-color compositing semantics, latency, price and the free-tier quota. That is unusually complete behavioral context for a paid API call.

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?

Front-loaded with the purpose and the sibling routing sentence, then progressively adds return shape, edge cases, timing and cost. It is dense but nearly every sentence carries information; the pricing and docs URL are justified for a metered API, though they add bulk.

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

Completeness5/5

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

An output schema exists, yet the description still summarizes the verdict structure, and it covers the tricky cases an agent would otherwise hit blind (invalid colors, alpha compositing, latency, cost). Nothing needed to invoke it correctly is missing.

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 meaning the schema does not: out-of-range or unparseable colors are rejected with 422, and a translucent color is composited over the background before computation. The concrete example (#777 on white = 4.48:1, unrounded) further clarifies semantics.

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?

States a specific verb and resource — checking WCAG contrast between a foreground text color and background color — and explicitly differentiates from the sibling convert_color_check_contrast, which handles format conversion. An agent can pick between the two without opening a schema.

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?

It names the alternative (convert_color_check_contrast) and the condition that selects it ('To convert colour formats too'), which is real routing guidance. It stops short of explicit when-not/exclusion rules, but the tool is narrowly scoped enough that little is left to inference.

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

Deploy Server

Other Tools