question

Lily-9563 avatar image
0 Votes"
Lily-9563 asked PRADEEPCHEEKATLA-MSFT commented

Using Azure Data Factory to call Azure REST API of Azure API Management

Hi, we try to use Azure Data Factory to call Azure API Management REST API to get data for reporting.
Sample : https://docs.microsoft.com/en-us/rest/api/apimanagement/current-ga/subscription/list

Test okay in Postman, but not sure which Authentication Type should be applied here.
195172-image.png

Need your advice, thank you


azure-data-factoryazure-api-management
image.png (43.2 KiB)
· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hello @Lily-9563,

Following up to see if the below suggestion was helpful. And, if you have any further query do let us know.


  • Please don't forget to click on 130616-image.png or upvote 130671-image.png button whenever the information provided helps you.

0 Votes 0 ·

1 Answer

PRADEEPCHEEKATLA-MSFT avatar image
0 Votes"
PRADEEPCHEEKATLA-MSFT answered PRADEEPCHEEKATLA-MSFT commented

Hello @Lily-9563,

Thanks for the question and using MS Q&A platform.

You can use the below method to call Azure REST API of Azure API Management:


 URL:https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/subscriptions?api-version=2021-08-01
 Method: GET
 Authentication: System Assigned Managed Identity
 Resource: https://management.azure.com/

195426-image.png

In case if you see this error message: {"error":{"code":"AuthorizationFailed","message":"The client '2bxx-cxx9-4xx3-bxx-8xxxxxx9f4' with object id '2bxx-cxx9-4xx3-bxx-8xxxxxx9f' does not have authorization to perform action 'Microsoft.ApiManagement/service/subscriptions/read' over scope '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}’ or the scope is invalid. If access was recently granted, please refresh your credentials."}}

Make sure to grant reader permissions for the ADF as shown below:

195459-image.png

Here is the complete walkthrough on using Azure Data Factory to call Azure REST API of Azure API Management.

195417-adf-webactivity.gif

Hope this will help. Please let us know if any further queries.


  • Please don't forget to click on 130616-image.png or upvote 130671-image.png button whenever the information provided helps you. Original posters help the community find answers faster by identifying the correct answer. Here is how

  • Want a reminder to come back and check responses? Here is how to subscribe to a notification

  • If you are interested in joining the VM program and help shape the future of Q&A: Here is how you can be part of Q&A Volunteer Moderators


image.png (38.9 KiB)
image.png (97.3 KiB)
· 3
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hello @Lily-9563,

Just checking in to see if the above answer helped. If this answers your query, do click Accept Answer and Up-Vote for the same. And, if you have any further query do let us know.

0 Votes 0 ·
Lily-9563 avatar image Lily-9563 PRADEEPCHEEKATLA-MSFT ·

Hi @PRADEEPCHEEKATLA-MSFT thank you so~~~~~~~~ much for such a detailed explanation and GIF. Now I know how to use it. Thank you!!

1 Vote 1 ·

Hello @Lily-9563,

Glad to know it helped. Going forward, I would encourage to use MS Q&A platform for any questions related to Azure.

0 Votes 0 ·