Send one short call to a backend and model, to check the setup.
POST
/admin/backends/{backendId}/test
const url = 'https://example.com/api/v1/admin/backends/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/test';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"model":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/api/v1/admin/backends/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/test \ --header 'Content-Type: application/json' \ --data '{ "model": "example" }'Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters”backendId
required
string format: uuid
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
model
required
string
Examplegenerated
{ "model": "example"}Responses
Section titled “ Responses ”The outcome.
Media typeapplication/json
object
ok
required
boolean
answer
string
error
string
tokens_in
integer format: int64
tokens_out
integer format: int64
estimated
boolean
duration_ms
required
integer format: int64
Examplegenerated
{ "ok": true, "answer": "example", "error": "example", "tokens_in": 1, "tokens_out": 1, "estimated": true, "duration_ms": 1}default
Section titled “default”An error.
Media typeapplication/problem+json
RFC 9457 problem details with a stable code.
object
type
required
string
title
required
string
status
required
integer
detail
string
instance
string
code
required
A stable machine-readable error code.
string
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example", "code": "example"}