diff --git a/api_definitions/AzureOpenAI_OpenAPI.json b/api_definitions/AzureOpenAI_OpenAPI.json index 45d90ac..0ee0d14 100644 --- a/api_definitions/AzureOpenAI_OpenAPI.json +++ b/api_definitions/AzureOpenAI_OpenAPI.json @@ -7,10 +7,10 @@ }, "servers": [ { - "url": "https://example.openai.azure.com/openai", + "url": "https://demodeployment-aoai-apim.openai.azure.com/openai", "variables": { "endpoint": { - "default": "example.openai.azure.com" + "default": "demodeployment-aoai-apim.openai.azure.com" } } } @@ -26,20 +26,11 @@ } ], "paths": { - "/deployments/{deployment-id}/chat/completions": { + "/responses": { "post": { "summary": "Creates a completion for the chat message", "operationId": "ChatCompletions_Create", - "parameters": [ - { - "in": "path", - "name": "deployment-id", - "required": true, - "schema": { - "type": "string", - "description": "Deployment id of the model which was deployed." - } - }, + "parameters": { "in": "query", "name": "api-version", @@ -49,8 +40,7 @@ "example": "2023-03-15-preview", "description": "api version" } - } - ], + }, "requestBody": { "required": true, "content": { @@ -178,7 +168,7 @@ ] }, "example": { - "model": "gpt-35-turbo", + "model": "gpt-5-mini", "messages": [ { "role": "user", diff --git a/public-apim.bicep b/public-apim.bicep index 84d1eba..4cd127b 100644 --- a/public-apim.bicep +++ b/public-apim.bicep @@ -11,16 +11,16 @@ param location string = resourceGroup().location param apiManagementSku string = 'Developer' @description('The name of the API publisher. This information is used by API Management.') -param apiManagementPublisherName string = 'Contoso' +param apiManagementPublisherName string = 'Nick' @description('The email address of the API publisher. This information is used by API Management.') -param apiManagementPublisherEmail string = 'admin@contoso.com' +param apiManagementPublisherEmail string = '1@1.1' @description('Provide the Name of the Azure Open AI service.') -param apiServiceNamePrimary string = 'Insert_Your_Azure_OpenAi_Name_Here' +param apiServiceNamePrimary string = 'demodeployment-aoai-apim' @description('Provide the Resource Group Name of the Azure Open AI service.') -param apiServiceRgPrimary string = 'Insert_Resource_Group_Name_Here' +param apiServiceRgPrimary string = 'aoai-apim' @description('If you want to provide resiliency when single region exceeds quota, then select Multi and provide URL to an additional Azure OpenAI endpoint. Otherwise, maintain default entry of Single and only provide one Azure OpenAI endpoint.') @allowed([ @@ -45,7 +45,7 @@ var apiServiceUrlSecondary = 'https://${apiServiceNameSecondary}.openai.azure.co var openApiXmlRetry = enableRetryPolicy ? 'https://raw.githubusercontent.com/microsoft/AzureOpenAI-with-APIM/main/apim_policies/AOAI_Policy-Managed_Identity_with_Retry_SingleRegion.xml' : 'https://raw.githubusercontent.com/microsoft/AzureOpenAI-with-APIM/main/apim_policies/AOAI_Policy-Managed_Identity.xml' var openApiXml = azureOpenAiRegionType == 'Multi' ? 'https://raw.githubusercontent.com/microsoft/AzureOpenAI-with-APIM/main/apim_policies/AOAI_Policy-Managed_Identity_with_Retry_MultiRegion.xml' : openApiXmlRetry -var openApiJson = 'https://raw.githubusercontent.com/microsoft/AzureOpenAI-with-APIM/main/api_definitions/AzureOpenAI_OpenAPI.json' +var openApiJson = 'https://github.com/dinhviet44/AzureOpenAI-with-APIM-AIO/blob/main/api_definitions/AzureOpenAI_OpenAPI.json' var apiManagementSkuCount = 1