{"uid":"cap_q1RVOGmSW0iWEnL6YGVda","slug":"forgemesh-color-conversion-api-bf9976a7","name":"ForgeMesh Color Conversion API","description":"Color conversion API: any hex or rgb() color to hex, RGB, and HSL plus is-it-dark detection and the accessible text color (black or white) to place on top of it. For theming, chart, and design-generation agents. Instant, computed locally.","url":"https://x402.forgemesh.io/color-convert","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"color":{"type":"string","description":"#RRGGBB or rgb(r,g,b)"}}},"responseSchema":{"type":"json","example":{"hex":"#5eead4","hsl":{"h":171,"l":64,"s":77},"rgb":{"b":212,"g":234,"r":94},"is_dark":false,"contrast_text":"#000000"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_gqBBs9j2KH7zDjz1WdwE6","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Converts any hex or RGB color to hex, RGB, and HSL formats, and returns whether the color is dark plus the accessible overlay text color (black or white).","exampleAgentPrompt":"Convert #3a7bd5 to RGB and HSL, tell me if it's a dark color, and tell me whether I should put black or white text on top of it.","exampleUseCases":[{"title":"Dynamic dashboard theme generator","prompt":"I'm building a customizable dashboard where users pick brand colors. Take the color they selected, convert it to all three formats, and tell me whether to use black or white text labels so everything stays readable."},{"title":"Accessible chart color palette builder","prompt":"I need to generate a set of chart colors that work for my data visualization. For each color I give you, figure out if it's dark or light and recommend the right text color so the legend and labels don't disappear."},{"title":"UI component color validation tool","prompt":"Before we push these button and card colors to production, run them through your converter. I need the hex, RGB, and HSL values for our design system, plus confirmation that the text contrast will actually be accessible to users."}],"resultDescription":"Returns the input color expressed as hex, RGB components, and HSL values, plus a boolean indicating whether the color is dark, and the recommended accessible text color (either black or white) to overlay on it.","failureModes":["Invalid color string (not a valid hex or rgb() format) returns an error","Missing 'color' field in request body returns a validation error","Malformed hex (e.g. wrong number of digits) returns a parsing error"],"whenToPreferThis":"Use this endpoint when you need instant, locally-computed color format conversion and accessibility checks without relying on a design tool API. Ideal for theming engines, chart generators, or design agents that need to programmatically determine text contrast and multi-format color values from a single input color.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T18:53:35.287Z","isFirstParty":false}