Skip to content

use official ai-gateway-provider package for Cloudflare AI Gateway#787

Open
elithrar wants to merge 1 commit intoanomalyco:devfrom
elithrar:fix/cloudflare-ai-gateway-provider-package
Open

use official ai-gateway-provider package for Cloudflare AI Gateway#787
elithrar wants to merge 1 commit intoanomalyco:devfrom
elithrar:fix/cloudflare-ai-gateway-provider-package

Conversation

@elithrar
Copy link
Contributor

@elithrar elithrar commented Feb 3, 2026

Switches the Cloudflare AI Gateway provider from @ai-sdk/openai-compatible to the official ai-gateway-provider package.

The official package:

  • handles cf-aig-authorization header correctly
  • supports the Unified API model format ({provider}/{model})
  • supports fallback providers
  • is maintained by Cloudflare

See: https://developers.cloudflare.com/ai-gateway/integrations/vercel-ai-sdk/

@elithrar
Copy link
Contributor Author

elithrar commented Feb 3, 2026

Companion PR for opencode: anomalyco/opencode#12014

This PR must merge first so that opencode's custom loader can use the updated npm field.

@anomalyco anomalyco deleted a comment from opencode-agent bot Feb 3, 2026
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.

1 participant