Why this is error in realtime API? `ERROR livekit....
# ask-ai
a
Why this is error in realtime API?
ERROR livekit.plugins.openai - OpenAI Realtime API returned an error {"error": "RealtimeError(message=\"Unknown parameter: 'session.tools[0].strict'.\", type='invalid_request_error', code='unknown_parameter', event_id='tools_update_a322fba79a34', param='session.tools[0].strict')", "pid": 18337, "job_id": "AJ_ntpkb2QsQSYe"}
t
Thanks for reaching out, Gamal. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
It looks like the error is happening because the
strict
parameter isn’t recognized in the tool definition for the OpenAI Realtime API integration with LiveKit. No worries, I’m here to help you sort this out! The fields supported for a tool are: • name (required): The function name. • description (optional): A brief explanation of the tool’s purpose. • parameters: A JSON schema defining the function’s input arguments. To fix this, you just need to remove the
strict
parameter from your tool definition. For example, if your tool looks like this:
Copy code
{
    "name": "get_weather",
    "description": "Get weather for a location",
    "parameters": { ... },
    "strict": true
}
Simply update it to:
Copy code
{
    "name": "get_weather",
    "description": "Get weather for a location",
    "parameters": { ... }
}
Just make sure your tool definitions follow the schema and only include those supported fields. If you run into any more questions or need a hand, feel free to reach out—I’m here to help! Sources: plugins/openai/src/realtime/realtime_model.ts | livekit-plugins/livekit-plugins-google/livekit/plugins/google/realtime/real... | Agent Session & Client Integration | livekit/livekit_composite | DeepWiki | OpenAI Realtime API plugin guide | LiveKit Docs