# UK Postcode Autocomplete API

> UK Postcode Autocomplete API is a paid API for AI agents from postcode.payapi.market, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-30).

Returns a list of matching UK postcode suggestions given a partial postcode string

## Facts

- Endpoint: POST https://postcode.payapi.market/lookup/autocomplete?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-30
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/uk-postcode-autocomplete-api-05ca5552
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_s0NsUg-a5BCn_iwTfE5r5

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 uk-postcode-autocomplete-api-05ca5552 -d '<json body>'
```

Example prompt: Can you suggest up to 10 UK postcodes that start with 'SW1A' so I can show the user a dropdown of matching options?

## When to prefer this

Choose this endpoint when you need real-time UK postcode autocompletion or typeahead suggestions from a partial prefix — ideal for building address forms, validating user input incrementally, or helping users narrow down a correct UK postcode without knowing the full code.

## Known failure modes

- Empty or missing 'partial' field returns no suggestions or an error
- Limit outside 1–100 range is rejected or clamped
- Non-UK postcode prefixes return zero suggestions
- Payment failure via x402 results in 402 response and no data returned
- Very broad partial (e.g. single letter) may return truncated results at the limit

## How this service works

UK postcode lookup, search, validation and autocomplete with x402 payments.

## Output

A JSON object containing the original partial postcode, a count of suggestions returned, and an array of matching full UK postcode strings (e.g. ['SW1A 0AA', 'SW1A 1AA', 'SW1A 2AA'])

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "limit": {
   "type": "integer",
   "maximum": 100,
   "minimum": 1,
   "description": "Maximum number of suggestions to return (1-100, default 10)."
  },
  "partial": {
   "type": "string",
   "description": "Partial UK postcode to autocomplete, e.g. 'SW1A'."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "count": 3,
  "partial": "SW1A",
  "suggestions": [
   "SW1A 0AA",
   "SW1A 1AA",
   "SW1A 2AA"
  ]
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/uk-postcode-autocomplete-api-05ca5552/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from postcode.payapi.market](https://www.zero.xyz/host/postcode.payapi.market/llms.txt)
