# PennyRail Domain Extractor

> PennyRail Domain Extractor is a paid API for AI agents from pennyrail.vercel.app, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-15).

Extracts the root domain from a given URL string

## Facts

- Endpoint: POST https://pennyrail.vercel.app/api/p/nano/url.domain--extract-domain
- 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/pennyrail-domain-extractor-c85180d6
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ZmisCSJBk3SMfDqCLNSK3

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 pennyrail-domain-extractor-c85180d6 -d '<json body>'
```

Example prompt: Can you extract just the root domain from this URL: https://blog.example.com/posts/2024/my-article?utm_source=twitter

## When to prefer this

Choose this endpoint when you need a lightweight, pay-per-call domain extraction service without standing up your own URL parsing infrastructure. Useful in automated pipelines where you need to normalize many URLs to their root domains on demand and want a machine-readable settlement model via x402.

## Known failure modes

- Malformed or non-URL input string may return an error or unexpected result
- Empty input string likely returns an error response
- Non-HTTP protocols (e.g. ftp://) may not be handled correctly
- Payment failure (402) if USDC funds are insufficient
- Timeout if Vercel cold-start latency is high

## How this service works

Machine-readable settlement service

## Output

Returns a JSON object containing the extracted root domain from the provided URL input string, stripping subdomains, paths, query parameters, and protocol prefixes.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "additionalProperties": true
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/pennyrail-domain-extractor-c85180d6/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from pennyrail.vercel.app](https://www.zero.xyz/host/pennyrail.vercel.app/llms.txt)
