# PennyRail URL Domain Extractor

> PennyRail URL 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-10-31).

Extracts the domain from a given URL via a machine-readable, pay-per-call settlement endpoint

## Facts

- Endpoint: POST https://pennyrail.vercel.app/api/p/nano/url.domain--domain-from-url?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-31
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/pennyrail-url-domain-extractor-84f9d049
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ByNNQSlLOBM8zIATkH2p2

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-url-domain-extractor-84f9d049 -d '<json body>'
```

Example prompt: Can you extract just the domain name from this URL: https://www.example.com/some/path?query=123

## When to prefer this

Choose this endpoint when you need a lightweight, pay-per-call domain extraction with no API key setup, particularly in agentic or automated pipelines using x402 micropayment rails. Prefer it when integrating with Coinbase-compatible payment flows or when you want a simple, stateless URL-to-domain transformation without standing up your own parsing logic.

## Known failure modes

- Malformed or non-URL input string may return an error or empty result
- Missing required 'input' field causes a 400-level validation error
- Ambiguous inputs (e.g. bare domain without scheme) may produce unexpected output
- Service unavailability on Vercel hosting could cause 5xx errors
- Payment failure or insufficient USDC balance blocks the call

## How this service works

Machine-readable settlement service

## Output

Returns a JSON object containing the extracted domain from the provided URL string, representing just the hostname or root domain portion of the input URL.

## 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-url-domain-extractor-84f9d049/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)
