Skip to main content
Glama

Agent Data Tools: Utilities

Convert a colour

color
Read-only

Convert a colour between hex, RGB and HSL, and give its relative luminance and whether black or white text reads better on it. Accepts #rgb, #rrggbb, rgb(r,g,b) and hsl(h,s%,l%). Use for theming and design checks. Example: color=#0f6cbd. Price $0.003/call via x402 USDC or a card key (/credits), first 25 free; failed calls free. Reads or computes only and changes nothing; each call is charged, so repeats are not free.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
colorYesThe colour

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnlyHint=true, destructiveHint=false), and the description adds genuinely useful context beyond them: it is compute-only and changes nothing, every call is charged so repeats are not free, failed calls are free, and the price is $0.003 via x402 USDC or a card key. The idempotentHint=false is implicitly explained by the per-call charging model, which is helpful cost-behavior disclosure.

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?

Outputs and accepted formats are front-loaded, then the supporting usage, pricing, and safety notes follow. Slightly verbose with the payment mechanics, but that information is decision-relevant for a paid tool and every sentence carries weight.

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?

With no output schema, the description correctly enumerates what is returned (the three color representations, relative luminance, and best text color), and it documents input formats, cost, and side-effect-free behavior. Nothing an agent needs to call 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% but the schema only says 'The colour.' The description compensates by enumerating the accepted input formats (#rgb, #rrggbb, rgb(r,g,b), hsl(h,s%,l%)) and giving a concrete valid example, which is real added meaning over the schema.

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 specific verb ('Convert') plus resource ('a colour') and enumerates the outputs: hex/RGB/HSL conversion, relative luminance, and black/white text recommendation. An agent can distinguish this from sibling color_contrast, which deals with contrast checking rather than conversion.

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?

Offers a context cue, 'Use for theming and design checks,' plus an example (color=#0f6cbd), which implies usage. It does not say when to prefer color_contrast or random_color, nor does it state any exclusions, so routing 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.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.