注意:以下文档只适用于TOP接口,请谨慎使用!

文档中心 > API类目 > 万相台无界API

taobao.universalbp.new.commonapi.getcodeconfig (查询地域码表)

查询地域码表

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
top_service_context TopServiceContext 必须 topServiceContext
  • └ biz_code
  • String
  • 必须
  • xxxxx
  • api业务线编码
  • └ login_type
  • Number
  • 可选
  • 1
  • 1: 直客(正常)登录 2: 代理直投(叉乘账号)
  • └ member_id
  • Number
  • 可选
  • 12345
  • 代理直投时被代理商家账号, 代理直投(叉乘)时必填。 直客 时也可以填入 memberId
  • └ ext
  • String
  • 可选
  • {}
  • 扩展内容, 暂时无用
area_query_v_o AreaQueryVO 可选 areaQueryVO
  • └ campaign_id
  • Number
  • 可选
  • 68796878069
  • 计划id,计划已经存在场景必填,eg:添加主体、编辑计划状态等场景

响应参数

名称 类型 示例值 描述
top_result TopResult topResult
  • info
  • TopInfo
  • 通用前端结果的Info信息
  • 请求系统信息
  • └ ok
  • Boolean
  • true
  • 是否成功
  • └ message
  • String
  • 参数错误
  • 错误信息
  • └ error_code
  • String
  • xxxxx
  • 错误编码
  • area_group_new_v_o
  • AreaGroupNewVO
  • 结果集
  • letter_groups
  • AreaNewVO []
  • 字母开头的
  • └ name
  • String
  • xxxxx
  • 测试
  • └ id
  • String
  • xxxxx
  • 471
  • provinces
  • ProvincesVO []
  • 地域集合
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357
  • cities
  • RegionVO []
  • 城市集合
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357
  • provinces
  • RegionVO []
  • 省集合
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357
  • location_groups
  • AreaNewVO []
  • 地理大区开头的
  • └ name
  • String
  • xxxxx
  • 测试
  • └ id
  • String
  • xxxxx
  • 471
  • provinces
  • ProvincesVO []
  • 地域集合
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357
  • cities
  • RegionVO []
  • 城市集合
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357
  • provinces
  • RegionVO []
  • 省集合
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357
  • last_provinces
  • ProvincesVO []
  • 非常用地域
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357
  • cities
  • RegionVO []
  • 城市集合
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357
  • provinces
  • RegionVO []
  • 省集合
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357
  • overseas
  • ProvincesVO []
  • 海外
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357
  • cities
  • RegionVO []
  • 城市集合
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357
  • provinces
  • RegionVO []
  • 省集合
  • └ name
  • String
  • 测试
  • 名称
  • └ id
  • Number
  • 10
  • 357

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
UniversalbpNewCommonapiGetcodeconfigRequest req = new UniversalbpNewCommonapiGetcodeconfigRequest();
UniversalbpNewCommonapiGetcodeconfigRequest.TopServiceContext obj1 = new UniversalbpNewCommonapiGetcodeconfigRequest.TopServiceContext();
obj1.setBizCode("xxxxx");
obj1.setLoginType(1L);
obj1.setMemberId(12345L);
obj1.setExt("{}");
req.setTopServiceContext(obj1);
UniversalbpNewCommonapiGetcodeconfigRequest.AreaQueryVO obj2 = new UniversalbpNewCommonapiGetcodeconfigRequest.AreaQueryVO();
obj2.setCampaignId(68796878069L);
req.setAreaQueryVO(obj2);
UniversalbpNewCommonapiGetcodeconfigResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<universalbp_new_commonapi_getcodeconfig_response>
    <top_result>
        <info>
            <ok>true</ok>
            <message>参数错误</message>
            <error_code>xxxxx</error_code>
        </info>
        <area_group_new_v_o>
            <letter_groups>
                <area_new_v_o>
                    <name>xxxxx</name>
                    <id>xxxxx</id>
                    <provinces>
                        <provinces_v_o>
                            <name>测试</name>
                            <id>10</id>
                            <cities>
                                <region_v_o>
                                    <name>测试</name>
                                    <id>10</id>
                                </region_v_o>
                            </cities>
                            <provinces>
                                <region_v_o>
                                    <name>测试</name>
                                    <id>10</id>
                                </region_v_o>
                            </provinces>
                        </provinces_v_o>
                    </provinces>
                </area_new_v_o>
            </letter_groups>
            <location_groups>
                <area_new_v_o>
                    <name>xxxxx</name>
                    <id>xxxxx</id>
                    <provinces>
                        <provinces_v_o>
                            <name>测试</name>
                            <id>10</id>
                            <cities>
                                <region_v_o>
                                    <name>测试</name>
                                    <id>10</id>
                                </region_v_o>
                            </cities>
                            <provinces>
                                <region_v_o>
                                    <name>测试</name>
                                    <id>10</id>
                                </region_v_o>
                            </provinces>
                        </provinces_v_o>
                    </provinces>
                </area_new_v_o>
            </location_groups>
            <last_provinces>
                <provinces_v_o>
                    <name>测试</name>
                    <id>10</id>
                    <cities>
                        <region_v_o>
                            <name>测试</name>
                            <id>10</id>
                        </region_v_o>
                    </cities>
                    <provinces>
                        <region_v_o>
                            <name>测试</name>
                            <id>10</id>
                        </region_v_o>
                    </provinces>
                </provinces_v_o>
            </last_provinces>
            <overseas>
                <provinces_v_o>
                    <name>测试</name>
                    <id>10</id>
                    <cities>
                        <region_v_o>
                            <name>测试</name>
                            <id>10</id>
                        </region_v_o>
                    </cities>
                    <provinces>
                        <region_v_o>
                            <name>测试</name>
                            <id>10</id>
                        </region_v_o>
                    </provinces>
                </provinces_v_o>
            </overseas>
        </area_group_new_v_o>
    </top_result>
</universalbp_new_commonapi_getcodeconfig_response>

异常示例

  • XML示例
  • JSON示例
<error_response>
    <code>50</code>
    <msg>Remote service error</msg>
    <sub_code>isv.invalid-parameter</sub_code>
    <sub_msg>非法参数</sub_msg>
</error_response>

错误码解释

错误码 错误描述 解决方案

API工具

如何获得此API

FAQ

返回
顶部