3

How to chain multiple APIs on the same URL using Azure API management?

I have two APIs the user store and that user recources api.

I want to build rest api so resources will related to user.

Mycompany/users/[email protected]/resources.

User store api is mycompany/users Resources api is mycompany/resources.

I dont want to build additional service that will consolidate this two apis.

Thanks

3 Answers 3

3

Additionally you can use 'send-request' policy, that will call another API endpoint and store the result in declared variable. This is what worked for me.

In my case I had hit another URL after getting response of first APIs. Same can be done in inbound policy also before getting response and similarly you can hit multiple APIs.

Policy snippet.

enter image description here

2

You can create a single API in API Management that points to multiple different backend APIs. Use the set-backend-service policy to change the backend API for certain operations.

1
  • Thanks this is exactly what I search for.
    – Dani
    Commented Dec 20, 2016 at 17:18
1

I followed steps provided in this https://www.c-sharpcorner.com/blogs/api-aggregation-using-azure-apim link and able to combine two API responses within one API call.

It tells how to aggregate or chain more than one API responses in API management

1
  • 1
    Although your answer could be 100% correct, it might also become 100% useless if that link is moved, changed, merged into another one or the main site just disappears... :-( Therefore, please edit your answer, and copy the relevant steps from the link into your answer, thereby guaranteeing your answer for 100% of the lifetime of this site! ;-) You can always leave the link in at the bottom of your answer as a source for your material... Commented Mar 2, 2020 at 8:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.