Map Remote

This feature is really useful if you want to point your application to a different environment. This can be useful if, for example, you are debugging a Production issue and you need to quickly point your Prod build to a non-Prod environment but want to avoid rebuilding and redeploying the application. It can be a great time saver. You can achieve a similar result by using the Rewrite feature.


In this tutorial we will redirect traffic from an OpenBank API endpoint to a Github gist.

Prerequisites

Go to the OpenBank API Products’ endpoint

Open Chrome and go to NAB’s Products endpoint

You should now get an error about about a “Missing mandatory header”

Enable SSL Proxying

In Charles, right click the OpenBank request and click the “Enable SSL Proxying” option

The Request(s) you want to modify must be decrypted before you can use the Map Remote feature with it

Reload the page on Chrome

Return to Charles where you should now get a 406 error. Request details should be displayed in plain text

Copy URL

Right click the Request and click the “Copy URL” option

Open Map Remote screen

Tools -> Map Remote -> tick the “Enable Map Remote” checkbox

Define what to “Map Remote”

We will send users to a Github Gist page (which is JSON file) every time they go NAB Products’ endpoint

Configure URLs to map to

Click Add and configure as follows:

Check the URL has been changed

On Chrome when you go to OpenBank endpoint you should see the data from the Github gist

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: