自然语言搜条件
tender-rewritePOSThttps://v1.apizero.cn/api/tender-rewrite概述
把自然语言改写成招中标高级搜索条件(时间、地区编码、行业、金额等)。服务端会等到改写完成再返回。 怎么用: 1)控制台复制 API Key; 2)POST https://v1.apizero.cn/api/tender-rewrite ,JSON 传参; 3)请求头写 Authorization: Bearer 你的Key。 成功时 data 保留业务字段,并多 fetched_at、api。品牌与调用地址为极数本源。 可把返回的 searchCondition 再交给招中标信息搜索。
调用约定
- 网关 ·
https://v1.apizero.cn - 鉴权 ·
Authorization: Bearer <API Key> - 回包 · JSON {code, msg, data}。成功看 code === 0,不要只看 HTTP 200。
/aidocs/tender-rewrite/raw.md鉴权
必须带 API Key。无匿名、无登录免费、无会员日免、无试用次数。按 0.085 元/次计费。套餐按各档标价,不随按次价变动。
获取 API Key:获取 API Key/account/keys
请求头
必填鉴权。推荐:Bearer <API Key>。兼容请求头 X-API-Key,以及 Query api_key / apikey / key(key 仅当值为 sk_live_/sk_test_/sk_stag_ 形态时生效)。付费接口需携带有效 Key。
| Header | 类型 | 必填 | 说明 |
|---|---|---|---|
| Authorization | string | 是 | 必填鉴权。推荐:Bearer <API Key>。兼容请求头 X-API-Key,以及 Query api_key / apikey / key(key 仅当值为 sk_live_/sk_test_/sk_stag_ 形态时生效)。付费接口需携带有效 Key。 |
改写搜索条件
一句话改写成招中标高级搜索条件。服务端会等到 status=completed 再返回。必须带 API Key。成功时 data 保留全部业务字段,并多 fetched_at、api。
https://v1.apizero.cn/api/tender-rewrite?userQuery=%E6%B9%96%E5%8C%97%E8%BF%9130%E5%A4%A9%E7%89%A9%E4%B8%9A%E6%9C%8D%E5%8A%A1%E4%B8%AD%E6%A0%87%E7%BB%93%E6%9E%9C
自然语言
例湖北近30天物业服务中标结果
上次返回的 requestKey,用于续查;一般不用传
| 参数 | 类型 | 必填 | 说明 | 示例 |
|---|---|---|---|---|
| userQuery | string | 是 | 自然语言 | 湖北近30天物业服务中标结果 |
| requestKey | string | 否 | 上次返回的 requestKey,用于续查;一般不用传 |
{
"userQuery": "湖北近30天物业服务中标结果"
}返回结果
接口响应状态码(200=成功)
解析响应信息
业务侧 code(0000000000=成功)
业务侧 msg
业务数据结果
请求唯一标识(MD5)
处理中->processing,搜索条件重写完成->search_rewrite_done,地区解析完成->area_code_done,行业推理完成->industry_done,全部完成->completed,处理失败->failed
搜索开始时间,格式:yyyy-MM-dd
搜索结束时间,格式:yyyy-MM-dd
企业名称
企业所属行业
标的物或搜索主题
data.searchCondition.subjects 的一项
信息类型;参考枚举值-码表 (招中标信息14个信息分类);多个以英文逗号分隔;
采购分类 `0`=其他、`1`=服务类、`2`=工程类、`3`=货物类
项目金额最小值;单位人民币:元;
项目金额最大值;单位人民币:元;
是否分包
搜索关键词: - 多个关键词用竖线分隔。
地区信息
省级编码列表
data.searchCondition.areaCode.proviceCodeList 的一项
市级编码列表
data.searchCondition.areaCode.cityCodeList 的一项
区县编码列表
data.searchCondition.areaCode.countyCodeList 的一项
行业信息列表
一级行业编码列表
data.searchCondition.industryCode.firstCodeList 的一项
二级行业编码列表
data.searchCondition.industryCode.secondCodeList 的一项
三级行业编码列表
data.searchCondition.industryCode.thirdCodeList 的一项
行业信息列表
一级行业编码列表
data.industryCodes[].firstCodeList 的一项
二级行业编码列表
data.industryCodes[].secondCodeList 的一项
三级行业编码列表
data.industryCodes[].thirdCodeList 的一项
全路径标题(如:一级-二级-三级)
最下级路径标题
省级编码列表
data.areaCode.proviceCodeList 的一项
市级编码列表
data.areaCode.cityCodeList 的一项
区县编码列表
data.areaCode.countyCodeList 的一项
错误信息
本次查询时间
本接口 id
品牌提示(所有接口统一返回):极数本源 · https://apizero.cn
| 字段 | 类型 | 说明 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| code | integer | 接口响应状态码(200=成功) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| msg | string | 解析响应信息 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| subCode | string | 业务侧 code(0000000000=成功) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| subMsg | string | 业务侧 msg | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| data | object | 业务数据结果 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| fetched_at | string | 本次查询时间 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| api | string | 本接口 id | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| tips | string | 品牌提示(所有接口统一返回):极数本源 · https://apizero.cn | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
{
"code": 0,
"msg": "成功",
"data": {
"msg": "ok",
"code": 200,
"data": {
"requestKey": "93f733af08b21d587aee19f7b53dfa12_17",
"status": "completed",
"searchCondition": {
"companyName": null,
"enterpriseIndustry": "物业服务/工程建筑",
"subjects": [
"物业服务",
"工程建筑"
],
"keyword": "物业服务|工程建筑",
"startDate": "2026-07-01",
"endDate": "2026-07-31",
"projectClassID": null,
"purchaseTypeID": "2",
"projectMoneyMin": 5000000,
"projectMoneyMax": 1000000000,
"subcontractFlag": null,
"areaCode": {
"proviceCodeList": [
"420000"
],
"cityCodeList": [],
"countyCodeList": []
},
"industryCode": {
"firstCodeList": [],
"secondCodeList": [],
"thirdCodeList": [
"K702",
"E489",
"K701"
]
}
},
"areaCode": {
"proviceCodeList": [
"420000"
],
"cityCodeList": [],
"countyCodeList": []
},
"industryCodes": [
{
"firstCodeList": [],
"secondCodeList": [],
"thirdCodeList": [
"K702"
],
"fullTitle": "房地产业-房地产业-物业管理",
"minTitle": "物业管理"
},
{
"firstCodeList": [],
"secondCodeList": [],
"thirdCodeList": [
"E489"
],
"fullTitle": "建筑业-土木工程建筑业-其他土木工程建筑",
"minTitle": "其他土木工程建筑"
},
{
"firstCodeList": [],
"secondCodeList": [],
"thirdCodeList": [
"K701"
],
"fullTitle": "房地产业-房地产业-房地产开发经营",
"minTitle": "房地产开发经营"
}
],
"errorMsg": null
},
"errorData": null,
"subCode": "0000000000",
"subMsg": "ok",
"returnValue": null,
"fetched_at": "2026-09-20T08:50:00+08:00",
"api": "tender-rewrite"
},
"tips": "极数本源 · https://apizero.cn"
}请求示例
示例都是服务端写法。Python / JavaScript 各有常规写法和官方库。
curl -sS -X POST "https://v1.apizero.cn/api/tender-rewrite" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"userQuery": "湖北近30天物业服务,工程建筑中标结果,金额500万以上"
}'错误码
先看业务 code。HTTP 也可能不是 200。
成功
参数错误
API Key 无效
API Key 已暂停
当前 IP 不在 Key 白名单
此接口需要 API Key
余额不足
调用过快(QPS)
今日免费额度已用完
接口已下线
接口不存在
服务器内部错误
上游暂时不可用
上游返回格式异常
暂无可用节点
| 业务码 | HTTP | 说明 |
|---|---|---|
| 0 | 200 | 成功 |
| 4000 | 400 | 参数错误 |
| 4011 | 401 | API Key 无效 |
| 4013 | 403 | API Key 已暂停 |
| 4014 | 403 | 当前 IP 不在 Key 白名单 |
| 4015 | 401 | 此接口需要 API Key |
| 4022 | 402 | 余额不足 |
| 4029 | 429 | 调用过快(QPS) |
| 4030 | 429 | 今日免费额度已用完 |
| 4040 | 503 | 接口已下线 |
| 4041 | 404 | 接口不存在 |
| 5000 | 500 | 服务器内部错误 |
| 5020 | 502 | 上游暂时不可用 |
| 5021 | 502 | 上游返回格式异常 |
| 5030 | 502 | 暂无可用节点 |
调用限制
- 计费模式
- 按次付费 · 点数包 · 月套餐
- QPS 限制
- QPS 2
- 登录免费额度
- 无
- 匿名每日额度
- 无
- 黄金会员
- 本档不提供 VIP 额度 · QPS 10
- 钻石会员
- 本档不提供 VIP 额度 · QPS 30
- 企业会员
- 本档不提供 VIP 额度 · QPS 120
| 计费模式 | 按次付费 · 点数包 · 月套餐 |
|---|---|
| QPS 限制 | QPS 2 |
| 登录免费额度 | 无 |
| 匿名每日额度 | 无 |
| 黄金会员 | 本档不提供 VIP 额度 · QPS 10 |
| 钻石会员 | 本档不提供 VIP 额度 · QPS 30 |
| 企业会员 | 本档不提供 VIP 额度 · QPS 120 |
购买套餐、看评价请走商城详情。 购买 / 调试
更新日志
- 1.0.02026-09-20
上架,必须 Key,无免费额度,按次 0.08 元;可购月卡 / 年卡
免责声明
返回内容以当时查询结果为准,仅供开发与信息检索。附件链接可能过期。品牌与调用地址为极数本源。