Address Purification
Overview of address purification APIs
LEAPERone provides a suite of 22 address purification endpoints through a unified RESTful JSON API, covering address extraction, standardization, geocoding, and more.
Endpoint
POST https://api.leaper.one/v1/address/:actionReplace :action with the specific API action name.
Authentication
Authorization: Bearer sk-your-api-keyCommon Parameters
All endpoints share the following JSON body parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
| text | string | Yes | The text content to process |
| defaultProvince | string | No | Default province (e.g., "浙江省") |
| defaultCity | string | No | Default city (e.g., "杭州市") |
| defaultDistrict | string | No | Default district (e.g., "余杭区") |
Common Response
{
"RequestId": "xxx-xxx-xxx",
"Data": "{ ... }"
}The Data field is a JSON string. You need to call JSON.parse(response.Data) to parse it.
Action Reference
| Action | Endpoint | Description | Price (credits/call) |
|---|---|---|---|
extract | /v1/address/extract | Address extraction | $0.004 |
extract-name | /v1/address/extract-name | Name extraction | $0.004 |
extract-phone | /v1/address/extract-phone | Phone number extraction | $0.004 |
division-code | /v1/address/division-code | Administrative division code | $0.004 |
zipcode | /v1/address/zipcode | Zip code lookup | $0.004 |
structure | /v1/address/structure | Address structuring | $0.008 |
correct | /v1/address/correct | Address correction | $0.008 |
complete | /v1/address/complete | Address completion | $0.008 |
standardize | /v1/address/standardize | Address standardization | $0.008 |
assessment | /v1/address/assessment | Address anomaly detection | $0.008 |
extract-express | /v1/address/extract-express | Shipping label extraction | $0.008 |
search | /v1/address/search | Address search | $0.008 |
input-search | /v1/address/input-search | Address autocomplete | $0.008 |
similarity | /v1/address/similarity | Multi-address similarity | $0.008 |
one-id | /v1/address/one-id | Multi-source address unification | $0.008 |
geocode | /v1/address/geocode | POI-level geocoding | $0.008 |
hp-geocode | /v1/address/hp-geocode | Building-level geocoding | $0.008 |
transfer-coord | /v1/address/transfer-coord | Coordinate system conversion | $0.008 |
classify-poi | /v1/address/classify-poi | Address type classification | $0.008 |
predict-poi | /v1/address/predict-poi | POI prediction | $0.008 |
asr | /v1/address/asr | Voice address recognition | $0.008 |
inference | /v1/address/inference | Conversational address inference | $0.008 |
Error Codes
| HTTP Status | Code | Description |
|---|---|---|
| 400 | InvalidParameter | Invalid parameter |
| 401 | missing_api_key | API key not provided |
| 402 | insufficient_credits | Insufficient balance |
| 403 | Forbidden.NoPermission | No permission to access this endpoint |
| 429 | Throttling.User | Rate limit exceeded |
| 500 | InternalError | Upstream internal error |
| 504 | Timeout | Upstream request timeout |