Hello, Welcome to MS Q&A
Please try once with updated api spec
{
"openapi": "3.0.1",
"info": {
"title": "test",
"description": "",
"version": "1.0"
},
"servers": [
{
"url": "https://myapiruftisoiqarzg.azure-api.net"
}
],
"paths": {
"/test/op1": {
"get": {
"summary": "op1",
"operationId": "op1",
"responses": {
"200": {
"description": "Successful response"
}
}
}
}
},
"components": {
"securitySchemes": {
"apiKeyHeader": {
"type": "apiKey",
"name": "Ocp-Apim-Subscription-Key",
"in": "header"
},
"apiKeyQuery": {
"type": "apiKey",
"name": "subscription-key",
"in": "query"
}
}
},
"security": [
{
"apiKeyHeader": []
},
{
"apiKeyQuery": []
}
]
}
Changes Made:
- Server URL: Changed
url
in theservers
section tohttps://myapiruftisoiqarzg.azure-api.net
without additional path segments, as APIM will handle the/test
segment based on the operation. - Path: Updated the path to
/test/op1
, aligning it with the APIM frontend path in the operation. - Response Description: Added a brief description for clarity.
This spec should now align with the expected routing and configuration in APIM. After updating, re-import this specification into APIM to apply the changes.
Also Check the following settings in your Function App:
- CORS Settings: If CORS is enabled, ensure APIM’s domain (
myapiruftisoiqarzg.azure-api.net
) is added as an allowed origin. - IP Restrictions: Ensure there are no IP restrictions blocking APIM’s traffic in your Function App’s Networking settings.
If still issue occur , please let us know
Thanks
Deepanshu