Skip to content

json with "oneOf" as root causing error for azure openai endpoint #30132

Closed

Description

@Rsirp0c

What version of the Codex App are you using (From “About Codex” dialog)?

Version 26.623.30605

What platform is your computer?

Failed on two computer: Darwin 27.0.0 arm64 arm, Microsoft Windows NT 10.0.26100.0 x64

What issue are you seeing?

I've been using azure openai endpoint, when codex calls certain tool, I get this error:
Invalid schema for function 'automation_update': schema must be a JSON Schema of 'type: "object"', got 'type: "None"

The issue is probably caused by the oneOf field in the automation_update tool definition, which Azure OpenAI does not support:
https://learn.microsoft.com/en-us/azure/foundry/openai/how-to/structured-outputs?tabs=python-secure%2Cdotnet-entra-id&pivots=programming-language-csharp#json-schema-support-and-limitations

What steps can reproduce the bug?

use azure openai endpoint and ask codex to run a bunch of tools, and very likely you'll see this error

Additional information

No response

Activity

  1. added
    appIssues related to the Codex desktop app
    on Jun 25, 2026
  2. added
    bugSomething isn't working
    azureIssues related to the Azure-hosted OpenAI models
    tool-callsIssues related to tool calling
    on Jun 25, 2026
  3. Carlo9013 commented on Jun 26, 2026

    @Carlo9013

    I've also had this same issue with version 26.623.12021

  4. thiagoperes commented on Jun 26, 2026

    @thiagoperes

    This is quite serious, we aren't able to use codex any longer @jif-oai @cconger @anp-oai

  5. keith-dell commented on Jun 26, 2026

    @keith-dell

    Also having the issue on 26.623.31921

  6. notImposterSyndromeIfImposter commented on Jun 26, 2026

    @notImposterSyndromeIfImposter

    Easy to reproduce. I'm a CLI user/don't use automations myself so excuse the clunky usage. Once a thread triggers the automation it's completely dead. Forking prior to the call does restore functionality.

    Break the thread

    Image

    Fork to Restore

    Image
  7. etraut-openai commented on Jun 26, 2026

    @etraut-openai
    Contributor

    This appears to be caused by an out-of-date deployment of code in Azure. The Azure team regularly updates their code to match OpenAI's, but sometimes they lag in their deployment. This problem will likely resolve itself once they redeploy. If you haven't already done so, please report to the folks at Azure. That may help accelerate a fix.

  8. Waffleboy commented on Jun 27, 2026

    @Waffleboy

    There should at least be a warning when updating or fallback code - its quite disruptive and we're caught offguard

  9. thiagoperes commented on Jun 27, 2026

    @thiagoperes

    Still ongoing

  10. Waffleboy commented on Jun 29, 2026

    @Waffleboy

    For those who are affected and can't wait for them to fix this issue - download an older version here https://github.com/nooblyf/codex-releases/releases/tag/2026-06-12

  11. TreeOfLearning commented on Jun 30, 2026

    @TreeOfLearning

    This appears to be caused by an out-of-date deployment of code in Azure. The Azure team regularly updates their code to match OpenAI's, but sometimes they lag in their deployment. This problem will likely resolve itself once they redeploy. If you haven't already done so, please report to the folks at Azure. That may help accelerate a fix.

    @etraut-openai It worked before with older versions of codex (see comment above, 2026-06-12 is fine). Is there any reason why a fallback can't be added to this codebase so that threads don't get "bricked" in the event of an outdated API?

  12. DreamstarDS commented on Jul 1, 2026

    @DreamstarDS

    need fix

  13. IamLizu commented on Jul 1, 2026

    @IamLizu

    On 26.623.81905, with Azure OpenAI provider.

  14. trrwilson commented on Jul 1, 2026

    @trrwilson

    Sharing from the AOAI/Foundry side at Microsoft, the problem's been root-caused and a fix is rolling out ASAP.

    As @etraut-openai described, this stemmed from a recent (last few weeks) extension of Responses API non-strict schema support not yet being fully reflected in AOAI's configuration.

    We're following up to see how we can better coordinate to catch these issues sooner. It's a particularly tricky class of problems: extended schema component support within schema payload is a lot more subtle than new, typed properties on an API, and that makes it tough for both defensively handling it (in Codex) as well as comprehensively anticipating it (in 1-to-1 AOAI support). Tricky or not, though, it's important.

  15. david-liang commented on Jul 2, 2026

    @david-liang

    On 26.623.81905, with Azure OpenAI provider.

    same here.

  16. yidasanqian commented on Jul 2, 2026

    @yidasanqian

    same 。trace

  17. welsonsxc commented on Jul 6, 2026

    @welsonsxc

    I am broken. I am helpless. I am exhausted. I am silent

  18. Ahmet-Dedeler commented on Jul 15, 2026

    @Ahmet-Dedeler

    guys the issue still exists, whats going on? using gpt 5.6 sol via azure

  19. Waffleboy commented on Jul 15, 2026

    @Waffleboy

    For those who are affected and can't wait for them to fix this issue - download an older version here https://github.com/nooblyf/codex-releases/releases/tag/2026-06-12

    Quoting my reply for those who just scrolled to the end. Older releases still work.

  20. Ahmet-Dedeler commented on Jul 15, 2026

    @Ahmet-Dedeler

    Confirmed this is still failing on July 15, 2026, and reproduced it directly against Azure's Responses API (so this is not just a Codex client/thread issue).

    Environment:

    • Codex Desktop: 26.707.72221
    • Azure AI Services resource: East US, S0
    • Deployment: gpt-5.6-sol / GlobalStandard (model version 2026-07-09)
    • Endpoint: POST /openai/v1/responses, Entra bearer auth

    Minimal result:

    • Function parameters with a top-level oneOf -> HTTP 400: Invalid schema for function 'automation_update_repro': schema must be a JSON Schema of 'type: "object"', got 'type: "None"'.
    • The same request changed to a top-level {"type":"object", ...} -> HTTP 200.

    Failing request IDs for Microsoft to trace:

    • x-request-id: 116b61d6-f9d8-9de2-86c9-194a8ee7dcb6
    • apim-request-id: 2ddfab1f-841c-4ac4-9080-9a0d8b38fabd
    • Region header: East US
    • Timestamp: 2026-07-15 07:00:45 UTC

    So the rollout mentioned on July 1 either has not reached this East US path/current model stack, or this has regressed. A local proxy that rewrites top-level oneOf into an object schema unblocks Codex, but users should not need that workaround.

    @trrwilson could the Azure team check the request IDs / rollout status? Please keep this issue open until the direct API reproduction succeeds without schema rewriting.

  21. Rsirp0c commented on Jul 15, 2026

    @Rsirp0c
    Author

    @Ahmet-Dedeler Thanks for your feedback, this is indeed failing again on gpt-5.6-sol. I'm working with azure team on this!

  22. Rsirp0c commented on Jul 16, 2026

    @Rsirp0c
    Author

    @Ahmet-Dedeler gpt-56-sol is fixed. Let me know if you're still seeing other issues

  23. changed the title [-]automation_update tool json start with "oneOf" causing error for azure openai endpoint[/-] [+]json with "oneOf" as root causing error for azure openai endpoint[/+] on Jul 16, 2026
  24. Rsirp0c commented on Jul 26, 2026

    @Rsirp0c
    Author

    Everyone, seems like this problem is stable now. Closing the issue!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    appIssues related to the Codex desktop appautomationsazureIssues related to the Azure-hosted OpenAI modelsbugSomething isn't workingtool-callsIssues related to tool calling

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions