> For the complete documentation index, see [llms.txt](https://doc.duaer.com/zh/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://doc.duaer.com/zh/getting-started/postal-codes.md).

# 在 Duaer 里查邮政编码

在 Duaer 里：Zippopotam.us：约 60 个国家的邮编对应地点，或某城市的全部邮编。一次成功查询用 1 额度。
## 能拿到什么

Duaer 数据市场里的「邮政编码」：Zippopotam.us：约 60 个国家的邮编对应地点，或某城市的全部邮编。查到结果时用 1 额度，结果交给数字组织的下一个节点。

从节点创建器选 Duaer 数据 → 邮政编码，或打开 [数据市场](/zh/getting-started/data-market.md)。相关：[地名查询](/zh/getting-started/geocoding.md)、[附近地点](/zh/getting-started/places-nearby.md)。

## 适合做什么

- 查某个邮编属于哪个城市。
- 列出比佛利山的全部邮编。

## 在画布里检索

1. 打开节点创建器，选 Duaer 数据 → Postal codes。
2. 填 Postal Code（如 90210），或 State 与 City；Country（如 DE）可选。
3. Limit 默认 10，最大 20。执行。

查到结果才扣 1 额度；没有结果、输入有误或上游失败都不扣。

## 用 API 调用

- GET https://api.duaer.com/v1/data/postal-codes?country=US&postalCode=90210
- Authorization: Bearer <Duaer key>

下方是与数据市场「复制技能」相同的英文技能，含参数、示例与返回字段。

## 调用技能（英文）

与数据市场「复制技能」一致。

```
---
name: duaer-postal-codes
description: >-
  Duaer Postal codes. Zippopotam.us: the places for a postal code, or the postal codes of a city, in about 60 countries.
  One successful search uses 1 Duaer credit.
---

# Duaer Postal codes

Duaer Postal codes turns a postal code into places with coordinates, or lists the postal codes of a city when you give a state and city.

## When to use

- Check which city a ZIP code belongs to.
- List all postal codes in Beverly Hills.

## When not to use

- Full street addresses. Use https://skills.duaer.com/geocoding.md.
- Places around a point. Use https://skills.duaer.com/places-nearby.md.

## Call

`GET https://api.duaer.com/v1/data/postal-codes?country=US&postalCode=90210`

Header: `Authorization: Bearer <Duaer key>`

Use an account key or a model API key.

Get a Duaer key: https://skills.duaer.com/keys.md

## Parameters

Provide `postalCode`, or `state` and `city`.

- `country` — Optional. Two-letter code such as US, DE, or FR. Default US.
- `postalCode` — Postal code such as 90210.
- `state` — Optional. State code such as CA, used with `city` instead of a postal code.
- `city` — Optional. City name, used with `state`.
- `limit` — Optional. Rows to return, from 1 to 20. Default 10.

## Examples

- `GET https://api.duaer.com/v1/data/postal-codes?country=US&postalCode=90210` — the place for ZIP 90210.
- `GET https://api.duaer.com/v1/data/postal-codes?country=US&state=CA&city=Beverly%20Hills` — the ZIP codes of Beverly Hills.

## Result

The response is `{ "items": [...] }`. Each item has `source`, `title`, `url`, and `summary`, plus:

- `postalCode`, `place` — code and place name.
- `state`, `stateCode`, `country`, `countryCode` — region and country.
- `latitude`, `longitude` — approximate center.

An unknown code returns no rows.

Fields without a value are left out.

## Credits

A search that returns at least one row uses 1 credit.
An empty search, a search that finds nothing, or a failed search uses 0.
Wrong input returns 400 with a message and uses 0.
No remaining credits returns 402 and does not search.
A missing key returns 401.

## Related

- https://skills.duaer.com/geocoding.md — Duaer Place lookup
- https://skills.duaer.com/places-nearby.md — Duaer Places nearby

```
## Questions

### Duaer 的邮政编码检索扣多少额度？

查到结果时扣 1 额度；没有结果或出错不扣。

### Duaer 邮政编码支持中国邮编吗？

取决于 Zippopotam.us 的覆盖；不支持的国家或邮编返回空结果，不扣额度。

## 相关

- [在 Duaer 里查地名查询](https://doc.duaer.com/zh/getting-started/geocoding.md)
- [在 Duaer 里查附近地点](https://doc.duaer.com/zh/getting-started/places-nearby.md)

