GET
/
v1
/
chat
/
completions
{
  "data": [
    {
      "choices": [
        {
          "finish_reason": "<string>",
          "index": 1,
          "logprobs": "<any>",
          "message": {
            "annotations": "<any>",
            "audio": "<any>",
            "content": "<string>",
            "refusal": "<string>",
            "role": "<string>",
            "tool_calls": [
              {
                "function": {
                  "arguments": "<string>",
                  "name": "<string>"
                },
                "id": "<string>",
                "type": "<string>"
              }
            ]
          }
        }
      ],
      "created": 1,
      "id": "<string>",
      "model": "<string>",
      "object": "<string>",
      "service_tier": "<string>",
      "system_fingerprint": "<string>",
      "usage": {
        "completion_tokens": 1,
        "completion_tokens_details": "<any>",
        "prompt_tokens": 1,
        "prompt_tokens_details": "<any>",
        "total_tokens": 1
      }
    }
  ],
  "first_id": "<string>",
  "has_more": true,
  "last_id": "<string>",
  "object": "<string>"
}

Query Parameters

after
string

Identifier for the last chat completion from the previous pagination request.

limit
integer

Number of Chat Completions to retrieve.

Required range: x >= 0
metadata
object

A list of metadata keys to filter the Chat Completions by. Example: metadata[key1]=value1&metadata[key2]=value2

model
string

The model used to generate the Chat Completions.

order
string

Sort order for Chat Completions by timestamp. Use asc for ascending order or desc for descending order. Defaults to asc.

Response

200
application/json

Chat completions listed successfully

The response is of type object.