Miguel Febres
Miguel Febres

Reputation: 2183

Get backends associated to an API Management Service

Is there any way to get the list of backends of a specific API Management Service using Azure CLI?

enter image description here

az apim documentation does not have any method to list the backends.

I tried to iterate the operations of one of the APIs, but they don't have the backend information. Is it possible?

Upvotes: 0

Views: 470

Answers (1)

Sridevi
Sridevi

Reputation: 22352

I tried to reproduce the same in my environment and got below results:

I have one API Management service named sriapim01 with below backends:

enter image description here

Note that, you can only use either PowerShell or REST API or ARM templates to list the backends of API Management service.

In my case, I used below PowerShell commands and got backends list successfully like below:

$apimContext = New-AzApiManagementContext -ResourceGroupName "rgname" -ServiceName "APIM name"
Get-AzApiManagementBackend -Context $apimContext

Response:

enter image description here

To list the backends via REST API, you can refer below MS document:

Backend - List By Service - (Azure APIM) | Microsoft

Upvotes: 1

Related Questions