In the docs: <https://docs.livekit.io/agents/model...
# ask-ai
g
In the docs: https://docs.livekit.io/agents/models/realtime/plugins/azure-openai/, it is said that we need to use
OPENAI_API_VERSION=2024-10-01-preview
where as in in Microsoft docs here, it is clearly stated that API version is
2025-08-28
is the current one and
2024-10-01-preview
is retired. How to use the latest API version when using Open AI Realtime models?
t
Thanks for reaching out, Yaseen. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
Thanks — you're right to call this out. You're seeing a mismatch between LiveKit's example and Microsoft's current guidance. • The correct Azure OpenAI Realtime API version to use is 2025-08-28;
2024-10-01-preview
is retired. • In LiveKit you can override the example value by passing the API version when configuring the Azure realtime model plugin via
api_version
/
apiVersion
. Use
"2025-08-28"
there to call the supported endpoint. Examples: • Python:
Copy code
from livekit.plugins import openai

session = AgentSession(
    llm=openai.realtime.RealtimeModel.with_azure(
        azure_deployment="<your-deployment>",
        api_key="<your-api-key>",
        api_version="2025-08-28",
    )
)
• Node.js:
Copy code
const session = new voice.AgentSession({
  llm: openai.realtime.RealtimeModel.withAzure({
    azureDeployment: "<your-deployment>",
    apiKey: "<your-api-key>",
    apiVersion: "2025-08-28",
  })
});
If you want, tell me which SDK/language and how you're currently initializing the plugin and I’ll give a snippet tailored to your code. Sources: Azure OpenAI Realtime API and LiveKit | LiveKit Docs