Skip to main content
GET
Python

Authorizations

Authorization
string
header
required

An account API key. Send it as Authorization: Bearer <key>.

Path Parameters

id
string
required

The request id from the x-request-id response header, or the id of a chat response body.

Response

The request: its model, usage, charge and timing.

One request the caller's key made, as the request log keeps it.

id
string
required

The request id: the x-request-id header of the response.

Example:

"4f9c2a7e1b3d48c6a0e5f7b9d2c4e6a8"

object
string
required

Always request.

Example:

"request"

created_at
integer<int64>
required

Unix seconds when the request arrived.

stream
boolean
required

Whether the client asked for a stream.

status_code
integer<int32>
required

The HTTP status NagaAI answered with.

Required range: x >= 0
latency_ms
integer<int32>
required

Milliseconds from the request's arrival to the end of the response.

Required range: x >= 0
usage
object
required

The tokens the request counted. Zero for a model that is not billed by tokens; charges holds its units.

cost
string
required

Credits charged for the request, as a decimal string. "0" for a request that was not charged.

Example:

"0.00012345"

charges
object[]
required

What the charge is made of, one line per unit billed: tokens, images, seconds, characters. Empty for a request that was not charged.

response_id
string | null

The id of the response body (chatcmpl-…, resp_…, msg_…), for a chat request that got one.

model
string | null

The model that answered, by its id in GET /v1/models. Absent when the request was refused before a model was chosen.

kind
string | null

The kind of model: chat, image, video, speech, transcription, embeddings or moderation.

operation
string | null

What the request asked the model to do, such as chat, image_generation or transcription.

status
string | null

How the model's answer ended: completed, incomplete or failed. Absent for a request that got no answer from a model.

incomplete_reason
string | null

Why the answer ended early, such as max_output_tokens or content_filter, when status is incomplete.

ttft_ms
integer<int32> | null

Milliseconds to the first token of a stream. Absent for a request that did not stream one.

Required range: x >= 0