Skip to content

fix(ai-gateway): bypass access check for direct BYOK#2982

Merged
chrarnoldus merged 1 commit intomainfrom
fix/bypass-access-check-direct-byok
May 1, 2026
Merged

fix(ai-gateway): bypass access check for direct BYOK#2982
chrarnoldus merged 1 commit intomainfrom
fix/bypass-access-check-direct-byok

Conversation

@kilo-code-bot
Copy link
Copy Markdown
Contributor

@kilo-code-bot kilo-code-bot Bot commented May 1, 2026

Summary

  • Set bypassAccessCheck: true for direct BYOK provider results in get-provider.ts.
  • Per apps/web/src/lib/ai-gateway/AGENTS.md, direct BYOK models must not be passed through checkOrganizationModelRestrictions since enabling them already requires explicit admin action.
  • No behavior change today because the access check is currently a deny list, but this guards against future reverts.

Verification

N/A — single-line boolean flip aligning code with documented policy.

Visual Changes

N/A

Reviewer Notes

The access check is currently a deny list so this is a no-op in practice; the change exists to prevent accidental regressions if the check semantics change.

Per apps/web/src/lib/ai-gateway/AGENTS.md, direct BYOK models must not be
passed through checkOrganizationModelRestrictions since enabling them
already requires explicit admin action.
@kilo-code-bot
Copy link
Copy Markdown
Contributor Author

kilo-code-bot Bot commented May 1, 2026

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Files Reviewed (1 files)
  • apps/web/src/lib/ai-gateway/providers/get-provider.ts

Reviewed by gpt-5.5-20260423 · 170,629 tokens

@chrarnoldus chrarnoldus merged commit 5231c94 into main May 1, 2026
13 checks passed
@chrarnoldus chrarnoldus deleted the fix/bypass-access-check-direct-byok branch May 1, 2026 10:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants