API Spec link
https://github.com/Azure/azure-rest-api-specs/tree/main/specification/apimanagement
API Spec version
2021-08-01
Describe the bug
Description
When enabling system-assigned managed identity on an Azure API Management (APIM) instance using the Microsoft.ApiManagement service's credentials/v2/systemassigned API endpoint, the API returns a 404 NotFound error.
The endpoint path being used is:
/subscriptions//resourceGroups//providers/Microsoft.ApiManagement/service//credentials/v2/systemassigned
This is expected to return the system-assigned managed identity credentials for the APIM instance, but instead returns NotFound.
Expected Behavior
The credentials/v2/systemassigned endpoint should return the system-assigned managed identity details when the managed identity is enabled on the APIM instance.
Actual Behavior
The API returns a 404 NotFound error when querying the credentials/v2/systemassigned endpoint.
Steps to Reproduce
- Create or configure an APIM instance in Azure
- Enable system-assigned managed identity on the APIM instance
- Call the credentials/v2/systemassigned endpoint via REST API
- Observe the 404 NotFound response
Environment
- Azure API Management API version: 2021-08-01
- Region: West Europe (and potentially other regions)
- APIM SKU: Developer
Additional Context
This issue affects automation scenarios where infrastructure as code tools (like Terraform) attempt to configure or verify system-assigned managed identity on APIM instances. The same configuration works when applied via the Azure Portal, suggesting the underlying managed identity is being set up correctly, but the REST API endpoint is not functioning as expected.
Expected behavior
The credentials/v2/systemassigned endpoint should successfully return the system-assigned managed identity configuration (including the tenantId and principalId) for the APIM instance when it has system-assigned managed identity enabled.
Actual behavior
The API returns a 404 NotFound error instead of returning the managed identity configuration. The error response indicates that the credentials/v2/systemassigned endpoint could not be found, even though the APIM instance has system-assigned managed identity enabled.
Reproduction Steps
- Create an Azure API Management instance (any SKU, e.g., Developer)
- Enable system-assigned managed identity on the APIM instance via Azure Portal or Azure CLI
- Make a REST API call to the credentials/v2/systemassigned endpoint:
GET https://management.azure.com/subscriptions//resourceGroups//providers/Microsoft.ApiManagement/service//credentials/v2/systemassigned?api-version=2021-08-01
- Observe the 404 NotFound response instead of the expected managed identity configuration
Environment
- Azure API Management API version: 2021-08-01
- Region: West Europe
- APIM SKU: Developer
- Infrastructure as Code tool: Terraform with azurerm provider
API Spec link
https://github.com/Azure/azure-rest-api-specs/tree/main/specification/apimanagement
API Spec version
2021-08-01
Describe the bug
Description
When enabling system-assigned managed identity on an Azure API Management (APIM) instance using the Microsoft.ApiManagement service's credentials/v2/systemassigned API endpoint, the API returns a 404 NotFound error.
The endpoint path being used is:
/subscriptions//resourceGroups//providers/Microsoft.ApiManagement/service//credentials/v2/systemassigned
This is expected to return the system-assigned managed identity credentials for the APIM instance, but instead returns NotFound.
Expected Behavior
The credentials/v2/systemassigned endpoint should return the system-assigned managed identity details when the managed identity is enabled on the APIM instance.
Actual Behavior
The API returns a 404 NotFound error when querying the credentials/v2/systemassigned endpoint.
Steps to Reproduce
Environment
Additional Context
This issue affects automation scenarios where infrastructure as code tools (like Terraform) attempt to configure or verify system-assigned managed identity on APIM instances. The same configuration works when applied via the Azure Portal, suggesting the underlying managed identity is being set up correctly, but the REST API endpoint is not functioning as expected.
Expected behavior
The credentials/v2/systemassigned endpoint should successfully return the system-assigned managed identity configuration (including the tenantId and principalId) for the APIM instance when it has system-assigned managed identity enabled.
Actual behavior
The API returns a 404 NotFound error instead of returning the managed identity configuration. The error response indicates that the credentials/v2/systemassigned endpoint could not be found, even though the APIM instance has system-assigned managed identity enabled.
Reproduction Steps
GET https://management.azure.com/subscriptions//resourceGroups//providers/Microsoft.ApiManagement/service//credentials/v2/systemassigned?api-version=2021-08-01
Environment