Skip to main content
Glama
PostalDataPI

PostalDataPI MCP Server

by PostalDataPI

PostalDataPI MCP 服务器

License: MIT Python 3.10+ PyPI

PostalDataPI 的 MCP (Model Context Protocol) 服务器——让 AI 智能体能够查询、验证和搜索全球 240 多个国家和地区的邮政编码,并获取丰富的元数据:时区、行政区域、海拔和坐标。

工具

工具

描述

lookup_postal_code

获取邮政编码(如美国 ZIP、英国邮编、德国 PLZ 等)对应的城市、州/地区及缩写

validate_postal_code

检查某个国家是否存在该邮政编码

search_by_city

查找某个城市的所有邮政编码

get_postal_code_metadata

获取完整元数据:坐标、行政层级、时区、海拔等

Related MCP server: Postio

设置

1. 获取 API 密钥

postaldatapi.com/register 注册——无需信用卡,即可获得 1,000 次免费查询。

2. 安装

pip install postaldatapi-mcp

3. 配置 Claude Code

claude mcp add --transport stdio postaldatapi -- \
  env POSTALDATAPI_KEY=your_api_key_here postaldatapi-mcp

4. 配置 Claude Desktop

添加到您的 Claude Desktop 配置文件中(macOS 上位于 ~/Library/Application Support/Claude/claude_desktop_config.json):

{
  "mcpServers": {
    "postaldatapi": {
      "command": "postaldatapi-mcp",
      "env": {
        "POSTALDATAPI_KEY": "your_api_key_here"
      }
    }
  }
}

使用方法

配置完成后,您可以自然地询问 Claude:

  • “邮政编码 90210 是哪个城市?”

  • “查询英国邮编 SW1A”

  • “10115 是有效的德国邮政编码吗?”

  • “加利福尼亚州比佛利山庄的邮政编码有哪些?”

  • “获取日本邮政编码 100-0001 的坐标”

Claude 将自动使用 PostalDataPI 工具来回答。

支持的国家/地区

涵盖美国、英国、加拿大、德国、法国、日本、澳大利亚、巴西、印度等 240 多个国家和地区。查看完整列表请访问 postaldatapi.com/countries

丰富的元数据

除了基础查询外,get_postal_code_metadata 工具每个邮政编码最多可返回 18 个字段,包括:

  • 坐标(纬度、经度)

  • 时区(例如 America/Mexico_City, Europe/Berlin

  • 行政层级(州/省、县、市)

  • 海拔(海拔高度,单位:米)

  • 地名和国家信息

墨西哥城 06000 的响应示例:

{
  "postalCode": "06000",
  "country": "MX",
  "placeName": "Centro",
  "latitude": 19.4364,
  "longitude": -99.1553,
  "timezone": "America/Mexico_City",
  "adminLevel1": "Ciudad de México",
  "adminLevel2": "Cuauhtémoc",
  "elevation": 2239
}

链接

Install Server
A
license - permissive license
A
quality
D
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • F
    license
    Not graded
    quality
    D
    maintenance
    Enables AI assistants to search, validate, and retrieve Australian postcode and suburb data with intelligent fuzzy matching for handling misspellings and voice queries. Provides comprehensive location services including geographic search, Local Government Area queries, and suburb-postcode validation for customer service interactions.
    5
  • A
    license
    Not graded
    quality
    B
    maintenance
    UK address (Royal Mail PAF), email, and phone (live HLR carrier) validation via the Postio API. Six tools: address search, postcode lookup, UDPRN, email validate, phone validate, and a health probe.
    MIT
  • F
    license
    Not graded
    quality
    C
    maintenance
    Enables location intelligence for US ZIP codes, allowing users to search, profile, and compare ZIP codes across various domains like crime, income, schools, and more.
  • A
    license
    A
    quality
    C
    maintenance
    Geospatial API tools for AI agents — geocoding, reverse geocoding, routing, isochrone, distance matrix, static maps, H3 hexagons, elevation, GPS map-matching, point-in-polygon, address normalisation, timezone lookup, and batch geocoding. Built on OpenStreetMap infrastructure. Cost-effective alternative to Google Maps API.
    18
    38
    MIT

View all related MCP servers

Related MCP Connectors

  • Hungarian postcode lookup + validation - 3,484 codes, sub-10ms lookups, bulk address endpoint.

  • Address validation & geocoding for AI agents: 240+ countries, UK PAF, free US/CA enrichment

  • Correios: CEP, official-source lookup. Platform-hosted, pay per query with prepaid credit.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/PostalDataPI/postaldatapi-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server