Custom Policy Examples

The add or remove header policies, available on Anypoint Exchange, are examples of custom policies. Follow the step-by-step procedures to download and look at the code. This topic and subtopics cover the downloading, set up, and how to apply these policies.

To download add or remove header policies:

  1. Login to Anypoint Platform and go to Exchange.

  2. Search for and download the following assets from Exchange:

    • Add Request Headers Policy

    • Remove Request Headers Policy

    • Add Response Headers Policy

    • Remove Response Headers Policy

  3. Unzip each policy archive.

An xml and yaml file appears in each of the folders created by unzipping the archives. For example, the add-request-header-policy folder contains the following files:

  • add-request.xml

  • add-request.yaml

You use these files to set up the policy as described later.

In this topic: