# Hex Color to RGB and HSL Converter

> Hex Color to RGB and HSL Converter is a paid API for AI agents from x402render-u5vwpxpyua-uc.a.run.app, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-15).

Converts a hex color code into its equivalent RGB and HSL color space representations

## Facts

- Endpoint: POST https://x402render-u5vwpxpyua-uc.a.run.app/color-convert
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/hex-color-to-rgb-and-hsl-converter-53422c5c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_hetOgQApFwc_tUjs3-3WS

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability hex-color-to-rgb-and-hsl-converter-53422c5c -d '<json body>'
```

Example prompt: Convert the hex color #d8232f to its RGB and HSL values for me.

## When to prefer this

Choose this endpoint when you need a quick, cheap ($0.01 USDC) server-side conversion of a hex color to both RGB and HSL simultaneously, avoiding the need to implement conversion math client-side or maintain a color utility library. Ideal for agents working in design, theming, or accessibility tooling pipelines.

## Known failure modes

- Invalid or malformed hex code (e.g. missing #, wrong length) returns an error
- Hex value outside valid 3 or 6 character range may be rejected
- Payment failure or insufficient USDC balance returns 402 error
- Network timeout from the Cloud Run service

## How this service works

Convert a hex colour to RGB and HSL

## Output

Returns the RGB channel values (red, green, blue as integers 0–255) and HSL values (hue in degrees, saturation and lightness as percentages) corresponding to the provided hex color code.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "hex": {
   "type": "string",
   "description": "string, e.g. #d8232f"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/hex-color-to-rgb-and-hsl-converter-53422c5c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402render-u5vwpxpyua-uc.a.run.app](https://www.zero.xyz/host/x402render-u5vwpxpyua-uc.a.run.app/llms.txt)
