
| 接口环境 | 接口地址 |
|---|---|
| 正式环境 | https://apis.speedaf.com/ |
| 测试环境 | https://uat-api.speedaf.com/ |
接口地址:https://uat-api.speedaf.com/open-api/common/area/getArea?appCode=你的appCode×tamp=当前时间戳
请求方式:POST
请求数据类型:application/json
接口描述:
请求参数示例:
{ "countryCode":"CN", "parentCode":"R001", "type":2}请求参数描述:
| 参数名称 | 参数说明 | 是否必须 | 数据类型 | 备注 |
|---|---|---|---|---|
| parentCode | 上级编码 | false | string | |
| countryCode | 国家编码 | false | string | CN,GH,NG,KE,MA |
| type | 类型 | true | int | 0=国家,1=省,2=市,3=区 |
响应状态:
响应参数示例:
xxxxxxxxxx[{ "code": "C001", "name": "Guangzhou", "type": 2},{ "code": "C002", "name": "Shenzhen", "type": 2}, {}]响应参数描述:
| 参数名称 | 参数说明 | 类型 | 备注 |
|---|---|---|---|
| code | 编码 | string | |
| name | 名称 | string | |
| type | 类型 | int | 0=国家,1=省,2=市,3=区 |
接口地址:/open-api/common/area/getAreaTree?appCode=你的appCode×tamp=当前时间戳
请求方式:POST
请求数据类型:application/json
接口描述:
请求参数示例:
xxxxxxxxxx{ "countryCode":"CN"}请求参数描述:
| 参数名称 | 参数说明 | 是否必须 | 数据类型 | 备注 |
|---|---|---|---|---|
| countryCode | 国家编码 | true | string | CN,GH,NG,KE,MA |
响应状态:
响应参数示例:
xxxxxxxxxx{ "code": "CN", "name": "China", "type": 0, "children": [{ "code": "R001", "name": "Guangdong", "type": 1, "children": [{ "code": "C001", "name": "Guangzhou", "type": 2, "children": [{ },{}] },{}] },{}]}响应参数描述:
| 参数名称 | 参数说明 | 类型 | 备注 |
|---|---|---|---|
| code | 编码 | string | |
| name | 名称 | string | |
| type | 类型 | int | 0=国家,1=省,2=市,3=区 |
| children | 子区域 | Array |