feat: support cloudflare AI Gateway flavored azure openai (#715)

* feat: support cloudflare AI Gateway flavored azure openai

Signed-off-by: STRRL <im@strrl.dev>

* test: add test for cloudflare azure fullURL

---------

Signed-off-by: STRRL <im@strrl.dev>
Co-authored-by: STRRL <im@strrl.dev>
This commit is contained in:
wurui
2024-04-24 20:08:58 +08:00
committed by GitHub
parent 2d58f8f4b8
commit c84ab5f6ae
3 changed files with 48 additions and 5 deletions

View File

@@ -16,9 +16,10 @@ const (
type APIType string
const (
APITypeOpenAI APIType = "OPEN_AI"
APITypeAzure APIType = "AZURE"
APITypeAzureAD APIType = "AZURE_AD"
APITypeOpenAI APIType = "OPEN_AI"
APITypeAzure APIType = "AZURE"
APITypeAzureAD APIType = "AZURE_AD"
APITypeCloudflareAzure APIType = "CLOUDFLARE_AZURE"
)
const AzureAPIKeyHeader = "api-key"