Skip to main content
Use the OpenAI SDK for operations that MKA1 exposes with a compatible request and response contract. Use the MKA1 SDK for MKA1-specific resources such as saved agents, Compute, repositories, and resource permissions. The OpenAI SDK tabs in these guides use the OpenAI TypeScript client. They authenticate with an MKA1 API key, not an OpenAI key.

Install the client

Send a response request

OpenAI SDK
For a private deployment, replace the host with your deployment’s API gateway and retain the /api/v1/llm/ path. Use a model ID available in your organization; auto resolves through its configured model registry and routing policy.

Choose the matching example

Guides for Responses, Conversations, Files, and Vector stores include OpenAI SDK examples for supported operations. Compatibility is operation-specific. An OpenAI method’s existence does not mean MKA1 implements every OpenAI feature or parameter. In particular, MKA1 eval suites, saved agents, and Compute jobs have their own APIs. Fields the gateway drops lists the Responses parameters that are accepted but do not reach every model.

Use Responses instead of Chat Completions

Chat Completions (/api/v1/llm/chat/completions) has been deprecated since 18 February 2026 in favor of Responses. It is still supported, and no removal date has been set. Use Responses for new integrations. Chat Completions responses carry two headers that signal the deprecation:
  • Deprecation: @1771372800: the date the deprecation took effect, as a Unix timestamp.
  • Link: </api/v1/llm/responses>; rel="successor-version": the endpoint that replaces it.
Some models, such as the GPT-5 family, are available only through Responses. Sending one of them to Chat Completions returns 400 with the error code model_endpoint_mismatch. Send the request to /api/v1/llm/responses instead.

Call speech endpoints directly

MKA1 speech endpoints are under /api/v1/llm/speech/, not OpenAI’s /audio/ paths. Text to speech is POST /api/v1/llm/speech/tts, and transcription is POST /api/v1/llm/speech/transcriptions. The OpenAI SDK’s audio methods call the /audio/ paths, so they do not work with MKA1. Use the MKA1 SDK, the CLI, or HTTP, as shown in Speech.

Identify an application user

For a server-side integration, attach the end-user header when configuring your client or on the relevant request:
OpenAI SDK
See End-user identity for scoping and API reference for the exact MKA1 contract.