Search code examples
azureazure-application-gateway

Modify response and validate request parameters using Azure App Gateway


I want to use Azure Application Gateway as my front end for all web requests. There are few things I want to do with it (like I was able to do with AWS API Gateway), which are not mentioned on Azure Application Gateway features. Please tell me if Azure App Gateway can do following:

  1. Can generate APIs from Open API 3.0 definition file
  2. Validate the input request
  3. Perform response transformation (get response from downstream service & transform it before sending to front end)

Solution

  • According to Microsoft Docs

    Azure API Management is AWS-service API gateway equivalent in Azure , if you are looking for similar features. It makes it quick to start standing up new APIs and versioning them.

    Azure API Gateway which is similar to AWS’s offering is more suitable if you are using Microsoft Azure and has good support for Azure functions. An API gateway is a component or tool of an API management approach

    1. If you have a legacy back-end web service that has a basic authentication scheme, you can add some additional security by placing APIM in frontend, and requiring subscription keys. Leverage your existing firewall to ensure only your APIM instance can communicate with your back-end API
    2. You can import and publish an OpenAPI Specification backend API. In the Create from OpenAPI specification window, you can create api from open api file. See Tutorial .
    3. There are a lot of customizations that are possible through the use of API policies. This could be transforming XML to JSON or vice versa, modifying headers, restricting parameters, redirecting to different end-points depending on the message body.
    4. We can Add the validate-jwt policy to validate the OAuth token for every incoming request. By configuring your Azure API Management instance to protect an API, by using the OAuth 2.0 protocol with Azure Active Directory (Azure AD).

    Note: Azure Application Gateway, Amazon API Gateway, and Azure App Service are alternatives for Azure API Management.

    Also see this SO reference.