聚合数据

邮编查询

  • 数据类型: 应用开发
  • 接口状态: 正常
  • 已连接App的数量: 5874
  • 描述: 提供全国邮政编码大全,为你快速准确查邮编

接口地址: http://v.juhe.cn/postcode/search

支持格式: JSON/XML

请求方式: HTTP GET/POST

请求示例: http://v.juhe.cn/postcode/search.php?key=您申请的KEY&pid=15&cid=205&did=2125&q=

请求参数:

名称 类型 必填 说明
pid int 省份ID
cid int 城市ID
did int 区域ID
q string 地名关键字,如:木渎
page int 第几页,默认为第1页
pagesize int 每页显示条数,(1-50)默认20条,
key string 在个人中心->我的数据,接口名称上方查看
dtype string 返回数据的格式,xml或json,默认json

返回字段:

名称 类型 说明
error_code int 返回码
reason string 返回说明

JSON返回示例:

{
    "reason": "successed",
    "result": {
        "list": [
            {
                "PostNumber": "215101",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "木渎镇木东路"
            },
            {
                "PostNumber": "215127",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "甪直镇西汇上塘街香花弄"
            },
            {
                "PostNumber": "215101",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "木渎镇迎号弄"
            },
            {
                "PostNumber": "215127",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "甪直镇中兴路"
            },
            {
                "PostNumber": "215168",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "旺吴路"
            },
            {
                "PostNumber": "215101",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "木渎镇邾巷弄"
            },
            {
                "PostNumber": "215101",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "木渎镇老园上"
            },
            {
                "PostNumber": "215111",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "金庭镇堂里街"
            },
            {
                "PostNumber": "215103",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "横泾街道中街弄"
            },
            {
                "PostNumber": "215127",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "甪直镇彩虹路"
            },
            {
                "PostNumber": "215124",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "郭巷街道郭新西路"
            },
            {
                "PostNumber": "215127",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "甪直镇东方大道"
            },
            {
                "PostNumber": "215164",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "胥口镇香泾路"
            },
            {
                "PostNumber": "215124",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "郭巷街道尹中路"
            },
            {
                "PostNumber": "215101",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "木渎镇仓基路"
            },
            {
                "PostNumber": "215164",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "太湖度假区湖滨路"
            },
            {
                "PostNumber": "215107",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "东山镇启园路谈家弄"
            },
            {
                "PostNumber": "215128",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "水香五村"
            },
            {
                "PostNumber": "215101",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "花苑东路"
            },
            {
                "PostNumber": "215159",
                "Province": "江苏省",
                "City": "苏州市",
                "District": "吴中区",
                "Address": "光福镇小巨角"
            }
        ],
        "totalcount": 671,
        "totalpage": 34,
        "currentpage": 1,
        "pagesize": 20
    },
    "error_code": 0
}

XML返回示例:


          

备注:根据相关条件查询符合条件地区的邮编

服务级错误码参照(error_code):

错误码 说明
206601 错误的邮编号码
206602 错误的省份ID
206603 错误的城市ID
206604 错误的地区ID

系统级错误码参照:

错误码 说明
10001 错误的请求KEY
10002 该KEY无请求权限
10003 KEY过期
10004 错误的OPENID
10005 应用未审核超时,请提交认证
10007 未知的请求源
10008 被禁止的IP
10009 被禁止的KEY
10011 当前IP请求超过限制
10012 请求超过次数限制
10013 测试KEY超过请求限制
10014 系统内部异常(调用充值类业务时,请务必联系客服或通过订单查询接口检测订单,避免造成损失)
10020 接口维护
10021 接口停用

错误码格式说明(示例:200201):

2 002 01
服务级错误(1为系统级错误) 服务模块代码(即数据ID) 具体错误代码

其他相关内容:

内容 详细
接口测试 API测试工具
技术支持 info@juhe.cn
联系电话 0512-62391880
QQ交流群 264591694
在线客服QQ 1794844675
商务合作QQ 603866358