查询后端类型
更新时间:2026-09-07
该接口用于查询可创建的后端类型,以及后端类型为 AI 大模型时可选的模型供应商和接口协议
注意事项:
- AI 大模型条目同时返回预置服务地址,以及由该地址协议推导出的 TLS 模式和 SNI,可直接用于组装创建后端请求
请求结构
Plain Text
1POST /?action=DescribeBackendTypes HTTP/1.1
2Host: bcc.bj.baidubce.com
3Authorization: authorization string
请求头域
除公共头域外,无其它特殊头域。
请求参数
无特殊请求参数。
返回头域
除公共头域,无其它特殊头域。
返回参数
| 参数名称 | 类型 | 描述 |
|---|---|---|
| key | String | 后端类型标识:aiModel/ip/domain/agent,创建后端时作为 backendType 传入 |
| name | String | 后端类型名称,用于界面展示 |
| items | List<AiGwListEnumAiModelUO> | AI 大模型供应商及接口协议列表,仅后端类型为 AI 大模型时返回,其余类型为空 |
错误码
| 错误码 | 错误描述 | HTTP状态码 | 中文解释 |
|---|---|---|---|
| ParamCheckError | Invalid AiModel baseUrl. | 404 | 平台侧 AI 大模型供应商清单中存在非法的模型服务地址(未以 http:// 或 https:// 开头,或地址为空),无法推导服务地址与 TLS 配置,请联系技术支持 |
请求示例
Plain Text
1POST /?action=DescribeBackendTypes HTTP/1.1
2Host: bcc.bj.baidubce.com
3Authorization: bce-auth-v1/f81d3b34e48048fbb2634dc7882d7e21/2015-08-11T04:17:29Z/3600/host/74c506f68c65e26c633bfa104c863fffac5190fdec1ec24b7c03eb5d67d2e1de
返回示例
Plain Text
1HTTP/1.1 200 OK
2x-bce-request-id: 1214cca7-4ad5-451d-9215-71cb844c0a50
3Date: Wed, 03 Dec 2014 06:42:19 GMT
4Content-Type: application/json;charset=UTF-8
5Server: BWS
6
7[
8 {
9 "key": "aiModel",
10 "name": "AI大模型",
11 "items": [
12 {
13 "provider": "qianfan",
14 "showName": "百度智能云千帆",
15 "aiModels": [
16 {
17 "baseUrl": "https://qianfan.baidubce.com/v2",
18 "aiModel": "openai",
19 "backendServiceEndpoint": "qianfan.baidubce.com/v2",
20 "tlsConfigMode": "SIMPLE",
21 "sni": "qianfan.baidubce.com"
22 },
23 {
24 "baseUrl": "https://qianfan.baidubce.com/v2",
25 "aiModel": "raw",
26 "backendServiceEndpoint": "qianfan.baidubce.com/v2",
27 "tlsConfigMode": "SIMPLE",
28 "sni": "qianfan.baidubce.com"
29 }
30 ]
31 }
32 ]
33 },
34 {
35 "key": "ip",
36 "name": "固定IP",
37 "items": null
38 },
39 {
40 "key": "domain",
41 "name": "域名",
42 "items": null
43 },
44 {
45 "key": "agent",
46 "name": "Agent",
47 "items": null
48 }
49]
评价此篇文章
