六派数据-邮编查询
  • ID

    31

  • 收藏

    0

  • 使用

    3

邮编查询

全国30多个省市县的邮编号码查询,数据权威准确,数百万条数据,精确到区、县、街道。支持按模糊地址、指定区域地址查询邮编。
免费会员100次/天 白银会员600次/天 钻石会员15万次/日
免费 (根据会员等级不同,每日可调用次数不同,了解各会员权益>>
  • 邮编查地址
  • 地址查询邮编
  • 区域查询

基本信息

  • 接口地址: http://open.6api.net/zipcode/query
  • 支持格式: JSON,JSONP
  • 请求方法: GET POST
  • 请求示例: http://open.6api.net/zipcode/query?appkey=yourappsecret

请求参数 API在线测试

参数名称 类型 必填 说明
zipcode string 邮编

返回参数

参数名称 类型   说明
province string  
city string  
town string  
address string   地址
zipcode string   邮编

请求代码 查看代码

  • PHP
  • JAVA
  • Python
require_once("curl.func.php");

$method = "POST";
$url = "http://open.6api.net/zipcode/query";
$headers = NULL;
$params = array(  
    "appkey" => "yourappsecret",
    "zipcode" => "参数1"
);
$result = api_curl($method, $url, $headers, $params);
if ($result) {
    $body = json_decode($result["body"], TRUE);
    $status_code = $body["status"];
    if ($status_code == "200") { 
        var_dump($body["result"]);
    }else
        var_dump($body); 
}else  
    echo "发送请求失败";

JSON返回示例

{
    "status": 200,
    "msg": "OK",
    "result": [
        {
            "province": "北京",
            "city": "东城区",
            "town": "",
            "address": "灯市口北巷",
            "zipcode": "100010"
        },
        {
            "province": "北京",
            "city": "东城区",
            "town": "",
            "address": "东罗圈胡同",
            "zipcode": "100010"
        },
        {
            "province": "北京",
            "city": "东城区",
            "town": "",
            "address": "连丰西巷",
            "zipcode": "100010"
        },
        {
            "province": "北京",
            "city": "东城区",
            "town": "",
            "address": "道湾胡同",
            "zipcode": "100010"
        },
        {
            "province": "北京",
            "city": "东城区",
            "town": "",
            "address": "广汇大院",
            "zipcode": "100010"
        },
        {
            "province": "北京",
            "city": "东城区",
            "town": "",
            "address": "烧酒胡同",
            "zipcode": "100010"
        },
        {
            "province": "北京",
            "city": "东城区",
            "town": "",
            "address": "礼士胡同",
            "zipcode": "100010"
        },
        {
            "province": "北京",
            "city": "东城区",
            "town": "",
            "address": "东四五条",
            "zipcode": "100010"
        },
        {
            "province": "北京",
            "city": "东城区",
            "town": "",
            "address": "小牌坊胡同",
            "zipcode": "100010"
        },
        {
            "province": "北京",
            "city": "东城区",
            "town": "",
            "address": "多福巷",
            "zipcode": "100010"
        }
    ]
}

    数据信息

  • 今日调用: 15,959  次
  • 客服电话: 010-8639-9970
  • 客服邮箱: kf@ksmsoft.net
  • 售前客服: 点击这里给我发消息
  • 售后技术: 点击这里给我发消息

邮编查询问答专区

问答专区

相关资讯

其他推荐