To setup the API mask you will need to fork this repository, and set up a Netlify Account. Then in Netlify create a project, and connect your forked repo.
In the next steps you will be asked to make a few customizations.
- Make up an API key, this is the API key you will use on your Wordpress plugins. Write it down in your notes.
- Set the name of your new netlify program, from 3 random words to something that makes sense. Like "apiMask-for-Iterable" or whatever is fitting.
- Add your Real Iterable API Key to the Environment Variables.
- Add your fake wordpress Key to the Environemnt variables.
- Copy your netlify project url, and paste it into your API endpoint.
--- Now your plugin will ask Netlify to make the API Calls, (an added layer of security)
---- The hacker needs to both hack Wordpress and Netlify.... Impossible!!!
- Maybe you want to do more than just use the mask with the Universal Email Preference Center, and Iterable... in that case here are a few extra steps.
- Clone your forked repo to your desktop and open it up with VS Code,
- Install the Netlify CLI
- Modify the code to add more routes, fliters and functionality.
- Post in the forum about what you have done.
If you have any questions ask away! Lets build this community!