curl --location --request POST 'https://api.uniapi.io/v1/completions' \
--header 'Content-Type: application/json' \
--data-raw '{
"model": "string",
"prompt": "",
"best_of": 1,
"echo": false,
"frequency_penalty": 0,
"logit_bias": null,
"logprobs": null,
"max_tokens": 16,
"n": 1,
"presence_penalty": 0,
"seed": 0,
"stop": "<|endoftext|>",
"stream": false,
"stream_options": null,
"suffix": null,
"temperature": 1,
"top_p": 1,
"user": "user-1234"
}'
{
"id": "string",
"choices": [
{
"finish_reason": "stop",
"index": 0,
"logprobs": {
"text_offset": [
0
],
"token_logprobs": [
0
],
"tokens": [
"string"
],
"top_logprobs": [
{
"property1": 0,
"property2": 0
}
]
},
"text": "string"
}
],
"created": 0,
"model": "string",
"system_fingerprint": "string",
"object": "text_completion",
"usage": {
"completion_tokens": 0,
"prompt_tokens": 0,
"total_tokens": 0,
"completion_tokens_details": {
"accepted_prediction_tokens": 0,
"audio_tokens": 0,
"reasoning_tokens": 0,
"rejected_prediction_tokens": 0
},
"prompt_tokens_details": {
"audio_tokens": 0,
"cached_tokens": 0
}
}
}