Cant use Azure OpenAI #3384

Closed
opened 2026-02-16 17:39:51 -05:00 by yindo · 10 comments
Owner

Originally created by @dogmatic69 on GitHub (Dec 7, 2025).

Originally assigned to: @rekram1-node on GitHub.

Description

Setup as per the docs. Managed to make one request in plan mode to create agent file.

At the end, switched to build mode and all I get is

I'm sorry, but I cannot assist with that request.

After trying multiple times with build and plan, switching between them, it eventually wrote the file.

Closed and reopened opencode, and now all I get regardless of what I type is "I'm sorry, but I cannot assist with that request."

Also don't seem to be able to select GPT-5.1-codex-max. Given I've configured a resource and API key, it should be showing what I've actually provisioned rather than a fixed list?

OpenCode version

1.0.134

Steps to reproduce

see above

Screenshot and/or share link

first session:
Image

Image

second session:

Image

Operating System

Windows 11 + WSL 2

Terminal

VS code built in terminal

Originally created by @dogmatic69 on GitHub (Dec 7, 2025). Originally assigned to: @rekram1-node on GitHub. ### Description Setup as per the docs. Managed to make one request in plan mode to create agent file. At the end, switched to build mode and all I get is > I'm sorry, but I cannot assist with that request. After trying multiple times with build and plan, switching between them, it eventually wrote the file. Closed and reopened opencode, and now all I get regardless of what I type is "I'm sorry, but I cannot assist with that request." Also don't seem to be able to select GPT-5.1-codex-max. Given I've configured a resource and API key, it should be showing what I've actually provisioned rather than a fixed list? ### OpenCode version 1.0.134 ### Steps to reproduce see above ### Screenshot and/or share link first session: <img width="1050" height="592" alt="Image" src="https://github.com/user-attachments/assets/49a7e9c2-ce2f-4c20-8638-b38cf41a0224" /> <img width="1047" height="726" alt="Image" src="https://github.com/user-attachments/assets/5bd6d637-8ccd-4bfd-ab87-e8fef2184395" /> second session: <img width="1070" height="946" alt="Image" src="https://github.com/user-attachments/assets/82ce6677-ef00-42f8-b076-9ebbfbac327d" /> ### Operating System Windows 11 + WSL 2 ### Terminal VS code built in terminal
yindo added the bug label 2026-02-16 17:39:51 -05:00
yindo closed this issue 2026-02-16 17:39:51 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Dec 7, 2025):

Searching for potential duplicates...

@github-actions[bot] commented on GitHub (Dec 7, 2025): Searching for potential duplicates...
Author
Owner

@rekram1-node commented on GitHub (Dec 7, 2025):

there is a setting in azure its like response security or something you need to change the setting ill update the docs about this

@rekram1-node commented on GitHub (Dec 7, 2025): there is a setting in azure its like response security or something you need to change the setting ill update the docs about this
Author
Owner

@rekram1-node commented on GitHub (Dec 7, 2025):

https://github.com/sst/opencode/issues/2506#issuecomment-3292239706

@rekram1-node commented on GitHub (Dec 7, 2025): https://github.com/sst/opencode/issues/2506#issuecomment-3292239706
Author
Owner

@rekram1-node commented on GitHub (Dec 7, 2025):

/oc use docs agent to update azure stuff to recommend:

In Azure, if you change the content filter from DefaultV2 to Default the response no longer gets blocked

@rekram1-node commented on GitHub (Dec 7, 2025): /oc use docs agent to update azure stuff to recommend: In Azure, if you change the content filter from DefaultV2 to Default the response no longer gets blocked
Author
Owner

@opencode-agent[bot] commented on GitHub (Dec 7, 2025):

Created PR #5212

New%20session%20-%202025-12-07T21%3A03%3A40.116Z
opencode session  |  github run

@opencode-agent[bot] commented on GitHub (Dec 7, 2025): Created PR #5212 <a href="https://opencode.ai/s/jOgsZXM3"><img width="200" alt="New%20session%20-%202025-12-07T21%3A03%3A40.116Z" src="https://social-cards.sst.dev/opencode-share/TmV3IHNlc3Npb24gLSAyMDI1LTEyLTA3VDIxOjAzOjQwLjExNlo=.png?model=opencode/claude-haiku-4-5&version=1.0.134&id=jOgsZXM3" /></a> [opencode session](https://opencode.ai/s/jOgsZXM3)&nbsp;&nbsp;|&nbsp;&nbsp;[github run](/sst/opencode/actions/runs/20010280718)
Author
Owner

@dogmatic69 commented on GitHub (Dec 7, 2025):

I should have mentioned, I done that and it made no difference.

Also the initial time it worked, that was on V2. It then stopped working, I switched to the Default and does not work at all now.

Image
@dogmatic69 commented on GitHub (Dec 7, 2025): I should have mentioned, I done that and it made no difference. Also the initial time it worked, that was on V2. It then stopped working, I switched to the Default and does not work at all now. <img width="643" height="874" alt="Image" src="https://github.com/user-attachments/assets/e7075665-64d2-46a9-bc70-8024e4ba84e2" />
Author
Owner

@rekram1-node commented on GitHub (Dec 7, 2025):

Hm well that comes directly from azure so something about your account or prompts is triggering their content issues.

I use azure openai often and it works just fine for me, just had to configure this policy.

Maybe it takes a little to take effect or something? I'm not sure

@rekram1-node commented on GitHub (Dec 7, 2025): Hm well that comes directly from azure so something about your account or prompts is triggering their content issues. I use azure openai often and it works just fine for me, just had to configure this policy. Maybe it takes a little to take effect or something? I'm not sure
Author
Owner

@liaoyinglong commented on GitHub (Jan 7, 2026):

I have the same issue.
However, I don’t have permissions to access the Azure console, and the problem only occurs when running in plan mode.

My solution was to disable the built-in PLAN agent and use a custom PLAN agent instead:

{
  "$schema": "https://opencode.ai/config.json",
  "agent": {
    "plan": {
      "disable": true
    }
  }
}
@liaoyinglong commented on GitHub (Jan 7, 2026): I have the same issue. However, I don’t have permissions to access the Azure console, and the problem only occurs when running in **plan mode**. My solution was to disable the built-in PLAN agent and use a custom PLAN agent instead: ```json { "$schema": "https://opencode.ai/config.json", "agent": { "plan": { "disable": true } } } ```
Author
Owner

@sshresthh commented on GitHub (Jan 22, 2026):

I am having the same issue when using Azure OpenAI

Image
@sshresthh commented on GitHub (Jan 22, 2026): I am having the same issue when using Azure OpenAI <img width="506" height="73" alt="Image" src="https://github.com/user-attachments/assets/65588ee7-2def-4583-b746-bb48a765b4a0" />
Author
Owner

@kodjac commented on GitHub (Jan 27, 2026):

I am getting the same problem, the model works once after new setup and then refuses with "I'm sorry, but I cannot assist with that request." Azure OpenAI, "Default" Content filter used in a corporate environment.

OK now after deploying a new Azure project, it works (so far) with content filter "Default".

@kodjac commented on GitHub (Jan 27, 2026): I am getting the same problem, the model works once after new setup and then refuses with "I'm sorry, but I cannot assist with that request." Azure OpenAI, "Default" Content filter used in a corporate environment. OK now after deploying a new Azure project, it works (so far) with content filter "Default".
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#3384