ai& · Schema

CreateChatCompletionResponse

Artificial IntelligenceJapanInferenceMachine LearningStartups

Properties

Name Type Description
id string
object string
created integer
model string
choices array
usage object
system_fingerprint string
View JSON Schema on GitHub

JSON Schema

aiand-com-create-chat-completion-response-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/aiand-com/json-schema/aiand-com-create-chat-completion-response-schema.json",
  "title": "CreateChatCompletionResponse",
  "x-generated": "2026-11-01",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/aiand-com-openapi.json#/components/schemas/CreateChatCompletionResponse",
  "type": "object",
  "properties": {
    "id": {
      "type": "string"
    },
    "object": {
      "type": "string",
      "const": "chat.completion"
    },
    "created": {
      "type": "integer"
    },
    "model": {
      "type": "string"
    },
    "choices": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "finish_reason": {
            "type": "string",
            "enum": [
              "stop",
              "length",
              "tool_calls",
              "content_filter",
              "function_call"
            ]
          },
          "index": {
            "type": "integer"
          },
          "message": {
            "type": "object",
            "properties": {
              "role": {
                "type": "string",
                "const": "assistant"
              },
              "content": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "refusal": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "tool_calls": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string",
                      "const": "function"
                    },
                    "function": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "type": "string"
                        },
                        "arguments": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "name",
                        "arguments"
                      ]
                    }
                  },
                  "required": [
                    "id",
                    "type",
                    "function"
                  ]
                }
              },
              "annotations": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "const": "url_citation"
                    },
                    "url_citation": {
                      "type": "object",
                      "properties": {
                        "end_index": {
                          "type": "integer"
                        },
                        "start_index": {
                          "type": "integer"
                        },
                        "url": {
                          "type": "string"
                        },
                        "title": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "end_index",
                        "start_index",
                        "url",
                        "title"
                      ]
                    }
                  },
                  "required": [
                    "type",
                    "url_citation"
                  ]
                }
              }
            },
            "required": [
              "role",
              "content"
            ],
            "additionalProperties": true
          },
          "logprobs": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "content": {
                "type": [
                  "array",
                  "null"
                ],
                "items": {
                  "type": "object",
                  "properties": {
                    "token": {
                      "type": "string"
                    },
                    "logprob": {
                      "type": "number"
                    },
                    "bytes": {
                      "type": [
                        "array",
                        "null"
                      ],
                      "items": {
                        "type": "integer"
                      }
                    }
                  },
                  "required": [
                    "token",
                    "logprob"
                  ],
                  "additionalProperties": true
                }
              },
              "refusal": {
                "type": [
                  "array",
                  "null"
                ],
                "items": {
                  "type": "object",
                  "properties": {
                    "token": {
                      "type": "string"
                    },
                    "logprob": {
                      "type": "number"
                    },
                    "bytes": {
                      "type": [
                        "array",
                        "null"
                      ],
                      "items": {
                        "type": "integer"
                      }
                    }
                  },
                  "required": [
                    "token",
                    "logprob"
                  ],
                  "additionalProperties": true
                }
              }
            },
            "required": [
              "content",
              "refusal"
            ]
          }
        },
        "required": [
          "finish_reason",
          "index",
          "message",
          "logprobs"
        ]
      }
    },
    "usage": {
      "$ref": "#/$defs/CompletionUsage"
    },
    "system_fingerprint": {
      "type": "string"
    }
  },
  "required": [
    "id",
    "object",
    "created",
    "model",
    "choices"
  ],
  "additionalProperties": true,
  "$defs": {
    "CompletionUsage": {
      "type": "object",
      "properties": {
        "prompt_tokens": {
          "type": "integer"
        },
        "completion_tokens": {
          "type": "integer"
        },
        "total_tokens": {
          "type": "integer"
        },
        "prompt_tokens_details": {
          "type": "object",
          "properties": {
            "cached_tokens": {
              "type": "integer"
            },
            "audio_tokens": {
              "type": "integer"
            }
          },
          "additionalProperties": true
        },
        "completion_tokens_details": {
          "type": "object",
          "properties": {
            "reasoning_tokens": {
              "type": "integer"
            },
            "audio_tokens": {
              "type": "integer"
            },
            "accepted_prediction_tokens": {
              "type": "integer"
            },
            "rejected_prediction_tokens": {
              "type": "integer"
            }
          },
          "additionalProperties": true
        }
      },
      "required": [
        "prompt_tokens",
        "completion_tokens",
        "total_tokens"
      ]
    }
  }
}

Work with this as data

Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for schemas

4 MCP tools reach this
  • find_json_schemasBrowse and filter every JSON Schema in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/aiand-com-create-chat-completion-response"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.