跳转到主要内容
POST
/
api
/
v1
/
provider
/
models
/
llm
创建 LLM 模型
curl --request POST \
  --url http://localhost:5300/api/v1/provider/models/llm \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "name": "gpt-4o",
  "provider_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "abilities": [
    "chat",
    "vision"
  ],
  "extra_args": {},
  "prefered_ranking": 0
}
'
{
  "code": 0,
  "data": {
    "uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  }
}

授权

X-API-Key
string
header
必填

请求体

application/json
name
string
必填

模型名称(即模型 ID)

示例:

"gpt-4o"

provider_uuid
string<uuid>
必填

关联的供应商 UUID

abilities
string[]
示例:
["chat", "vision"]
extra_args
object
prefered_ranking
integer
默认值:0

响应

200 - application/json

创建成功

code
integer
示例:

0

data
object