There is a problem when you want to call an API hosted in an Azure API management (APIm) instance if it is a consumption SKU.
Getting around it is easy.
Lets say you need to call a service you have made. That service has to be hosted behind an Azure API management instance. There might be many reasons, but the main one is that the service need to be protected using APIm.
You create a new Logic App and you want use the built in connector for APIm.
You find the consumption instance and select it. The API you created shows up in the Logic App.
In my case the API is simply calling a dummy Logic App.
You fill what you need in order to connect to the API. In my case I only need a SubscriptionID.
You click save and you will get this error:
Failed to save Logic App <your name here>. The API Management service hosting the API <pointing to your APIm instance> could not be found
I think this is due to how the connector works in Logic Apps. The connector gets its configuration in a different way than how it saves that configuration. An APIm consumption SKU is different from a regular one. It does not have any external IP-address, since it is a shared service. Several consumption instances are probably hosted on the same servers which makes me think that is why the Logic App cannot find it when it saves.
I would consider this a bug, rather than not supported.
You have to work around the problem and use the ever useful HTTP action. You can always call the API using its DNS name (or address of you prefer).
Comments are closed.