# ApexAPI Regex Generator

> ApexAPI Regex Generator is a paid API for AI agents from apex-api-gamma.vercel.app, paid per call via x402, $0.199877/call, status unknown (last checked 2026-10-11).

Generates a regular expression pattern from a natural language description of what to match

## Facts

- Endpoint: POST https://apex-api-gamma.vercel.app/api/tools/regex/generate?utm_source=zero.xyz
- Price: $0.199877/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-11
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/apexapi-regex-generator-455518be
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_JYElZwAeDJd5ttxlJwfIz

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 apexapi-regex-generator-455518be -d '<json body>'
```

Example prompt: Can you generate a regex pattern that matches valid US phone numbers in formats like (555) 123-4567, 555-123-4567, and 5551234567?

## When to prefer this

Use this endpoint when an AI agent or user needs a ready-made regular expression from a plain English description, without requiring a developer to manually craft or test the pattern. Ideal for quick prototyping, form validation rules, or text extraction logic.

## Known failure modes

- Ambiguous or underspecified query results in overly broad or incorrect regex
- Complex pattern requirements may produce a regex that partially matches
- Service returns generic 500 error if the input query is malformed or empty
- Query too vague may yield a pattern that doesn't handle edge cases

## How this service works

Crypto, AI, Social Media, Finance, Weather, Tools &amp; more. Pay per call in USDC on Base. No API keys.

## Output

Returns a generated regular expression pattern matching the described criteria, likely including the regex string and possibly an explanation or flags.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "query": {
   "type": "string",
   "description": "Search query or input parameter"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "description": "API response data"
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/apexapi-regex-generator-455518be/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from apex-api-gamma.vercel.app](https://www.zero.xyz/host/apex-api-gamma.vercel.app/llms.txt)
