Tech Corner - 15. June 2016
header_image

Applying policies without the proxy

It is fairly easy to apply policies to your proxied API hosted in Anypoint Platform: you just create a proxy and then apply runtime policies as the platform manages some things for you.

But what about applying policies but without using a proxy? In one of our projects, we needed to apply HTTP Basic Authentication policy to the endpoint.

The solution consists of two steps:

  1. Use Auto-Discovery element to link your flows with the created API in Anypoint Platform
  2. Link your application running in Anypoint Platform with your Anypoint Organization
  3. Get your client_id, client_secret as described in Step 1 here
  4. Go to Runtime Manager in Anypoint Platform
  5. Choose your application from the list and click Manage Application button
  6. Click Properties tab
  7. Enter following data: anypoint.platform.client_id=<YOUR_CLIENT_ID> anypoint.platform.client_secret=<YOUR_CLIENT_SECRET>
  8. Redeploy your application

READ MORE