To Upload a Policy to Exchange

Custom policies need to be published to Exchange so users can obtain and apply them to APIs. API Manager lists custom policies published as assets of the Organization.

Anypoint Exchange provides a Maven facade that enables Maven clients to publish and consume assets using Maven and publish custom policies to Exchange.

You must have a unique artifact name and organization ID to publish your asset.

  1. Add the Maven facade as a repository in the distribution management section of your project’s POM file:

           <name>Corporate Repository</name>
  2. Add a property called exchange.url in the properties section of your project’s POM file:

<organization id>/maven
  3. Get your organization ID from Access Management > Organization:

    • Click the name of your organization.

    • Copy the UUID from the browser address. For example, copy 2a4b93c3-7899-4ea7-9374-f787744d8784 from the URL.

  4. Replace the placeholder <organization id>.

  5. Add the following maven plugin to the plugins section of your project POM file. This enables the upload of the YAML and JAR files:

  6. Optionally, define the <name> and <description> in the project POM to set the name and description of the Exchange asset. Also define tags in Exchange by adding the <tags> attribute inside the properties section of the POM.

  7. Update the settings.xml file in your Maven .m2 directory with your Exchange credentials.

    Example settings.xml file

    <?xml version="1.0" encoding="UTF-8"?>
    <settings xmlns=""
  8. Run mvn deploy to publish the policy to Exchange.

    The custom policy is now available for you to apply to APIs that belong to the specified organization.

We use cookies to make interactions with our websites and services easy and meaningful, to better understand how they are used and to tailor advertising. You can read more and make your cookie choices here. By continuing to use this site you are giving us your consent to do this.