Skip to main content
Glama

a11y_contrast_pair

Check WCAG 2.2 contrast ratio for any color pair. Returns exact ratio, AA/AAA/non-text verdicts, and suggests the closest color that passes AA if the pair fails.

Instructions

Contraste WCAG 2.2 de un par de colores: ratio exacto y veredictos por criterio 1.4.3 (AA), 1.4.6 (AAA) y 1.4.11 (no textual). Si no pasa AA, sugiere el color más cercano que sí pasa.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bgYes
fgYes
langNoIdioma de la salida (es por defecto)
Behavior4/5

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

With no annotations provided, the description carries the full burden, and it does well by disclosing the exact outputs: ratio, verdicts per criterion, and a conditional closest-color suggestion when AA fails. It omits details like accepted color formats and exact response structure, but the core behavior is transparent.

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 concise sentences with no filler. The main action and criteria are front-loaded, and the conditional suggestion behavior is added as a brief second sentence. Every phrase contributes to understanding how the tool behaves.

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?

Given no output schema and no annotations, the description provides a useful high-level summary of return values and criteria. It is not fully complete because it does not describe the response format in detail, accepted color input syntax, or language behavior beyond what the schema already states for lang.

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 coverage is low (33%) because fg and bg have no descriptions, so the description must compensate. It adds the meaning that fg and bg form a color pair for contrast evaluation, which is valuable, but it does not specify accepted color formats or clarify the exact roles beyond the parameter names.

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 states a specific operation: WCAG 2.2 contrast checking of a color pair, with exact ratio and per-criterion verdicts (1.4.3 AA, 1.4.6 AAA, 1.4.11 non-text). This clearly differentiates it from siblings like a11y_audit_url and a11y_contrast_image, even though the suggestion behavior may overlap with a11y_suggest_color.

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 functionality makes the primary use case evident: checking contrast for a foreground/background color pair. However, there is no explicit guidance about when to choose this over a11y_suggest_color or a11y_contrast_image, and no conditions or exclusions are stated.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/kinti/a11y-toolkit'

If you have feedback or need assistance with the MCP directory API, please join our Discord server