# Agentshelf Hex Color Regex Extractor

> Agentshelf Hex Color Regex Extractor is a paid API for AI agents from agentshelf.syntexa.ch, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-24).

Extracts all hex color codes (up to 20 matches) from a provided text string using regex pattern matching.

## Facts

- Endpoint: POST https://agentshelf.syntexa.ch/v1/regex-hex-color?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-24
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agentshelf-hex-color-regex-extractor-d50acfc1
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_twcX9b-U5ZqkUyxpYY---

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 agentshelf-hex-color-regex-extractor-d50acfc1 -d '<json body>'
```

Example prompt: Can you extract all the hex color codes from this CSS snippet for me? Here it is: 'body { background: #1a2b3c; color: #fff; border: 1px solid #FF5733; }'

## When to prefer this

Use this endpoint when you need a quick, no-network regex extraction of hex color codes from text and are willing to pay $0.002 USDC per call. Prefer the free POST /v1/sandbox/regex-hex-color endpoint first if available. Choose this over general-purpose LLM color parsing when you need deterministic, regex-exact matching rather than approximate extraction.

## Known failure modes

- Empty match list returned when no hex colors are present in text — still billed
- Input text exceeds 100,000 character limit — request rejected
- Missing or empty 'text' field — validation error
- More than 20 hex colors in text — only first 20 returned, remainder silently truncated

## How this service works

Call when an agent needs hex colors extracted from text, capped at 20 matches. An empty match list is billed. No network. Exact $0.002 USDC. Prefer unpaid POST /v1/sandbox/regex-hex-color first.

## Output

Returns a list of up to 20 hex color code strings found in the input text, matched via regex. If no hex colors are present, an empty list is returned — but the call is still billed at $0.002 USDC.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "text": {
   "type": "string",
   "examples": [
    "#ff00aa"
   ],
   "maxLength": 100000,
   "minLength": 1,
   "description": "Input for this SKU. The route description says whether it is plain text, a URL, base64 bytes, or an already-encoded token."
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agentshelf-hex-color-regex-extractor-d50acfc1/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agentshelf.syntexa.ch](https://www.zero.xyz/host/agentshelf.syntexa.ch/llms.txt)
