Skip to content

feat: add Azure AI Foundry support for Anthropic#11312

Closed
maxruby wants to merge 1 commit intoRooCodeInc:mainfrom
maxruby:codex/azure-ai-foundry-anthropic
Closed

feat: add Azure AI Foundry support for Anthropic#11312
maxruby wants to merge 1 commit intoRooCodeInc:mainfrom
maxruby:codex/azure-ai-foundry-anthropic

Conversation

@maxruby
Copy link

@maxruby maxruby commented Feb 8, 2026

Related GitHub Issue

Closes: #

Roo Code Task Context (Optional)

Description

Test Procedure

Pre-Submission Checklist

  • Issue Linked: This PR is linked to an approved GitHub Issue (see "Related GitHub Issue" above).
  • Scope: My changes are focused on the linked issue (one major feature/fix per PR).
  • Self-Review: I have performed a thorough self-review of my code.
  • Testing: New and/or updated tests have been added to cover my changes (if applicable).
  • Documentation Impact: I have considered if my changes require documentation updates (see "Documentation Updates" section below).
  • Contribution Guidelines: I have read and agree to the Contributor Guidelines.

Screenshots / Videos

Documentation Updates

Additional Notes

Get in Touch


Important

Add Azure AI Foundry support to Anthropic integration with new configuration options and tests.

  • Behavior:
    • Adds support for Azure AI Foundry in AnthropicHandler with new options anthropicEndpointMode, anthropicMessagesUrlOverride, and anthropicAuthHeaderMode.
    • Updates createMessage and completePrompt to handle Azure AI Foundry requests.
    • Adds error handling for missing anthropicMessagesUrlOverride in Foundry mode.
  • Configuration:
    • Updates provider-settings.ts to include new schema fields for anthropicEndpointMode, anthropicMessagesUrlOverride, and anthropicAuthHeaderMode.
    • Updates Anthropic.tsx to include UI elements for configuring Azure AI Foundry settings.
  • Testing:
    • Adds tests in anthropic.spec.ts for Azure AI Foundry mode, including URL override and auth header selection.
    • Updates openai.spec.ts to ensure compatibility with Azure AI Foundry endpoints.
  • Misc:
    • Bumps version to 3.47.3-maxruby.1 in package.json.

This description was created by Ellipsis for cd0ab10. You can customize this summary. It will automatically update as commits are pushed.

@dosubot dosubot bot added size:L This PR changes 100-499 lines, ignoring generated files. Enhancement New feature or request labels Feb 8, 2026
@roomote
Copy link
Contributor

roomote bot commented Feb 8, 2026

Rooviewer Clock   See task

Found 3 issues to address before merging:

  • Bug: useAzureAiFoundry auto-detection in anthropic.ts ignores explicit anthropicEndpointMode of "anthropic" when a stale anthropicMessagesUrlOverride is present, silently forcing Foundry mode
  • Merge blocker: package.json version bumped to personal pre-release tag 3.47.3-maxruby.1 -- should be reverted to 3.47.3
  • i18n: Hardcoded English strings in Anthropic.tsx instead of using t() translation function

Mention @roomote in a comment to request specific changes to this pull request or fix all unresolved issues.

@maxruby maxruby closed this Feb 8, 2026
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap Feb 8, 2026
const apiKeyFieldName =
this.options.anthropicBaseUrl && this.options.anthropicUseAuthToken ? "authToken" : "apiKey"
const messagesUrlOverride = this.getAnthropicMessagesUrlOverride()
const useAzureAiFoundry = this.options.anthropicEndpointMode === "azure-ai-foundry" || !!messagesUrlOverride
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: if a user explicitly sets anthropicEndpointMode to "anthropic" but has a leftover anthropicMessagesUrlOverride value (e.g. from previously using Azure AI Foundry mode), the || !!messagesUrlOverride condition still forces Foundry mode. The explicit mode setting is ignored. The UI also doesn't clear anthropicMessagesUrlOverride when switching back to Anthropic mode, so this scenario is easy to trigger. The auto-detection fallback should only apply when anthropicEndpointMode is unset, not when it's explicitly "anthropic".

Suggested change
const useAzureAiFoundry = this.options.anthropicEndpointMode === "azure-ai-foundry" || !!messagesUrlOverride
const useAzureAiFoundry = this.options.anthropicEndpointMode === "azure-ai-foundry" || (this.options.anthropicEndpointMode == null && !!messagesUrlOverride)

Fix it with Roo Code or mention @roomote and request a fix.

"description": "%extension.description%",
"publisher": "RooVeterinaryInc",
"version": "3.47.3",
"version": "3.47.3-maxruby.1",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This pre-release version tag (3.47.3-maxruby.1) should be reverted before merging. It will break the release pipeline and misidentify the extension version.

Suggested change
"version": "3.47.3-maxruby.1",
"version": "3.47.3",

Fix it with Roo Code or mention @roomote and request a fix.

</VSCodeButtonLink>
)}
<div className="flex flex-col gap-1">
<label className="block font-medium mb-1">Endpoint Mode</label>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file has several hardcoded English strings ("Endpoint Mode", "Anthropic (default)", "Azure AI Foundry (Anthropic-compatible)", "Messages Endpoint URL", "Deployment Name (Model Override)", "Auth Header") while the rest of the component uses t() for i18n. These should be added to the translation files and referenced via the translation function for consistency.

Fix it with Roo Code or mention @roomote and request a fix.

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

Labels

Enhancement New feature or request size:L This PR changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant