跳到主要内容

获取可使用的模型列表

GET /v1/models

有用户登录获取用户分组下的可用列表,无用户登录获取default分组下的可用列表 header中有Authorization字段 则查询key对应的token下配置的模型列表

返回示例

{
"data": [
{
"id": "gpt-3.5-turbo-16k",
"object": "model",
"created": 1626777600,
"owned_by": "OpenAI",
"permission": [
{
"id": "modelperm-LwHkVFn8AcMItP432fKKDIKJ",
"object": "model_permission",
"created": 1626777600,
"allow_create_engine": true,
"allow_sampling": true,
"allow_logprobs": true,
"allow_search_indices": false,
"allow_view": true,
"allow_fine_tuning": false,
"organization": "*",
"group": null,
"is_blocking": false
}
],
"root": "gpt-3.5-turbo-16k",
"parent": null
}
]
}

返回结果

状态码状态码含义说明数据模型
200OKnoneInline

返回数据结构

状态码 200

名称类型必选约束中文名说明
» data[object]truenonenone
»» idstringtruenone模型IDnone
»» objectstringtruenonemodelnone
»» createdintegertruenone创建时间none
»» owned_bystringtruenone开发者none
»» permission[object]¦nulltruenonenone
»»» idstringtruenonenone
»»» objectstringtruenonenone
»»» createdintegertruenonenone
»»» allow_create_enginebooleantruenonenone
»»» allow_samplingbooleantruenonenone
»»» allow_logprobsbooleantruenonenone
»»» allow_search_indicesbooleantruenonenone
»»» allow_viewbooleantruenonenone
»»» allow_fine_tuningbooleantruenonenone
»»» organizationstringtruenonenone
»»» groupnulltruenonenone
»»» is_blockingbooleantruenonenone
»» rootstringtruenone模型名称none
»» parentnulltruenone父节点none

数据模型