Skip to main content
POST
/
v1
/
spaces
/
completions
/
{space_id}
/
function
Chat Completion with Function Call
curl --request POST \
  --url https://api.duplik.cn/v1/spaces/completions/{space_id}/function \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "model_name": "<string>",
  "max_tokens": 123,
  "system_message": "<string>",
  "function": {},
  "user_message": "<string>"
}
'
{
  "name": "<string>",
  "arguments": {}
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

space_id
integer
required

Body

application/json
function
object
required
user_message
string
required
model_name
string
max_tokens
integer
system_message
string

Response

Successful Response

name
string
arguments
object