# Color Gradient Steps Generator

> Color Gradient Steps Generator is a paid API for AI agents from color-design.x402tookit.com, paid per call via x402, $0.02/call, status unknown (last checked 2026-10-30).

Returns evenly spaced hex color steps between two hex colors in sRGB or linear light color space, for use in charts, heatmaps, and gradients.

## Facts

- Endpoint: GET https://color-design.x402tookit.com/gradient-steps?utm_source=zero.xyz
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-30
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/color-gradient-steps-generator-1bb3ff8c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Z76xDK9925i-uyUmImFiz

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 color-gradient-steps-generator-1bb3ff8c
```

Example prompt: Give me 9 evenly spaced hex color steps from #1a237e to #e53935 in linear light — I want to use them as a heatmap color scale.

## When to prefer this

Use this endpoint when you need a precise, mathematically evenly spaced sequence of hex colors between two endpoints, especially for data visualization artifacts like heatmaps, chart gradients, or color scales. It supports both perceptual sRGB interpolation and physically correct linear light interpolation, making it better than naive CSS gradient approximations when color accuracy matters.

## Known failure modes

- Missing required 'from' or 'to' query parameters returns an error
- Invalid hex color format causes a 400-level error
- Steps value outside 2–32 range may be rejected or clamped
- Unsupported color space value causes an error
- Payment not included or insufficient USDC results in a 402 Payment Required response

## How this service works

Evenly spaced color steps between two hex colors, in sRGB or linear light, for charts, heatmaps and gradients.

## Output

Returns an array of hex color strings evenly interpolated between the start and end colors, plus the CSS gradient string, the input from/to colors, the color space used, and optional metadata fields like source and summary.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "from",
      "to"
     ],
     "properties": {
      "to": {
       "type": "string",
       "description": "End hex color"
      },
      "from": {
       "type": "string",
       "description": "Start hex color"
      },
      "space": {
       "type": "string",
       "description": "srgb (default) or linear"
      },
      "steps": {
       "type": "integer",
       "description": "Number of colors, 2 to 32, default 7"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "to": {
       "type": [
        "null",
        "string"
       ]
      },
      "css": {
       "type": [
        "null",
        "string"
       ]
      },
      "asOf": {
       "type": [
        "null",
        "string"
       ]
      },
      "from": {
       "type": [
        "null",
        "string"
       ]
      },
      "space": {
       "type": [
        "null",
        "string"
       ]
      },
      "colors": {
       "type": [
        "array",
        "null"
       ],
       "items": {
        "type": "string"
       }
      },
      "source": {
       "type": [
        "null",
        "string"
       ]
      },
      "reasons": {
       "type": [
        "array",
        "null"
       ],
       "items": {
        "type": "string"
       }
      },
      "summary": {
       "type": [
        "null",
        "string"
       ]
      },
      "verdict": {
       "type": [
        "null",
        "string"
       ]
      },
      "degraded": {
       "type": [
        "boolean",
        "null"
       ]
      },
      "disclaimer": {
       "type": [
        "null",
        "string"
       ]
      },
      "notChecked": {
       "type": [
        "array",
        "null"
       ],
       "items": {
        "type": "string"
       }
      }
     }
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/color-gradient-steps-generator-1bb3ff8c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from color-design.x402tookit.com](https://www.zero.xyz/host/color-design.x402tookit.com/llms.txt)
