# Origin Header Normalize

> Origin Header Normalize is a paid API for AI agents from api.delx.ai, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-15).

Normalizes the scheme, host, and effective port from a caller-supplied HTTP Origin header value into a canonical, validated form with pass/advisory status.

## Facts

- Endpoint: POST https://api.delx.ai/api/v1/x402/origin-header-normalize
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/origin-header-normalize-452eeb8e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_d69Wi8Vcj_RcSkzG4jsiu

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 origin-header-normalize-452eeb8e -d '<json body>'
```

Example prompt: Normalize this Origin header value for me and tell me if it passes: 'https://example.com:443' — I need the canonical scheme, host, and effective port before I accept this request.

## When to prefer this

Choose this endpoint when you need a fast, deterministic, zero-external-dependency normalization of an HTTP Origin header value — especially before CORS validation, cache keying, redirect handling, or retry logic where a non-canonical origin could introduce security or correctness issues. Prefer it over rolling your own parser when you need a consistent effective-port computation and an explicit pass/advisory signal as structured JSON.

## Known failure modes

- Malformed or unparseable Origin string returns advisory status with finding describing the error
- Empty or missing 'origin' field may return a validation error or advisory
- Origin strings exceeding 8192 characters are rejected
- Non-standard schemes may produce advisory rather than pass status
- Opaque origins (e.g. 'null') may produce advisory status

## How this service works

Origin Header Normalize: Origin Header Normalize normalizes scheme, host, and effective port from an Origin value from bounded caller-supplied values without an external provider. Call Origin Header Normalize before accepting, caching, redirecting, or retrying a caller-supplied web response. Returns normalized web evidence, the computed finding, and an explicit pass or advisory status for Origin Header Normalize as versioned deterministic JSON. Price: $0.001 USDC via x402 on Base. First-party,…

## Output

Returns a versioned deterministic JSON object containing the normalized origin (with canonical scheme, host, and effective port), the computed finding describing what was parsed, and an explicit pass or advisory status indicating whether the Origin value is well-formed and safe to use.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "origin": {
   "type": "string",
   "maxLength": 8192,
   "description": "Origin supplied to Origin Header Normalize; used only for this bounded calculation and processed in memory without retention."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "result": {
   "host": "example.com",
   "origin": "https://example.com",
   "scheme": "https",
   "effective_port": 443
  },
  "schema": "delx/util-origin-header-normalize/v1",
  "status": "pass",
  "evidence": {
   "retained": false,
   "input_sha256": "07b2bd8501ded3c8a0fda45530946ed82acb0010a7632e08f86773e43703f622",
   "external_calls": 0
  },
  "operation": "web_reliability:origin_header_normalize"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/origin-header-normalize-452eeb8e/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.delx.ai](https://www.zero.xyz/host/api.delx.ai/llms.txt)
