# URL Normalize

> URL Normalize is a paid API for AI agents from x402-canary.nicolas-x402-16f380a7.workers.dev, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-15).

Normalizes and parses a raw URL string into a canonical, cleaned URL and its component parts

## Facts

- Endpoint: POST https://x402-canary.nicolas-x402-16f380a7.workers.dev/v1/url/normalize
- 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/url-normalize-c6f52977
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_R1tBxFdrK2-PGzuGUdf0O

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 url-normalize-c6f52977 -d '<json body>'
```

Example prompt: Can you normalize this URL for me — 'https://Example.COM/foo/../bar?utm_source=x&utm_source=y' — and tell me its canonical form and hostname?

## When to prefer this

Choose this endpoint when you need deterministic, canonical URL normalization as part of a coding agent or data pipeline workflow, especially when already using the x402-canary Coding Agent Context APIs suite. It is particularly suited for agents that need to deduplicate URLs, extract hostnames programmatically, or sanitize user-submitted links before storage or comparison. Prefer it over rolling your own normalization when you want a consistent, pay-per-call microservice with a stable response schema.

## Known failure modes

- Invalid or malformed input URL may result in an error or unexpected normalization output
- Empty or missing `url` field in the request body returns a validation error
- Non-URL strings passed as the URL field may cause parsing failures
- Network timeout if the worker is cold-starting
- Payment failure via x402 protocol blocks the call

## How this service works

Free need-to-tool routing plus pay-per-call npm docs and TypeScript API signatures, npm breaking-change diffs, JavaScript-rendered browser snapshots and deterministic coding-agent checks via AgentCash/x402.

## Output

Returns a JSON object with a `data` field containing the normalized `url` string and extracted `hostname`, plus a `meta` field indicating the engine used (`url-normalize`). The normalized URL is in canonical form with resolved paths, normalized casing, and proper formatting.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "url": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "data": {
   "url": "https://example.com/",
   "hostname": "example.com"
  },
  "meta": {
   "engine": "url-normalize"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/url-normalize-c6f52977/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402-canary.nicolas-x402-16f380a7.workers.dev](https://www.zero.xyz/host/x402-canary.nicolas-x402-16f380a7.workers.dev/llms.txt)
