Skip to content

Use OpenAI Azure without APIKEY #31342

@Uranium2

Description

@Uranium2

Question

With the recent changes with github copilot billing, I've reach my quota in few days instead of a full month.

I've seen that it is possible to connect opencode with Azure OpenAI, but it seems that it is only with an APIKEY. In my company there's a security policy that block the usage of APIKEY.

Does anyone have an example to how to connect to an Azure OpenAI with Oauth2 ? I can connect to the ressource with the python SDK and making an az login in my terminal. Maybe there's a script that could generate the Token to put inside the opencode configuration file at each time we start opencode?

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions