Jun 14, 2021 11:13 PM
Node is unavailable on the server we’re using. So, is there another way to hide the API key using either Vanilla JS or PHP?
Jun 15, 2021 05:38 AM
First of all, you can’t use that API on any client-side JS library or a framework, Because it’s shown everywhere on web and anyone can able to access your data.
Another option is you can use some server side language like NodeJS, PHP, Ruby etc.
Official API client:
Community-built API clients:
You can still find out more from Github.
Jun 15, 2021 06:23 AM
If you use PHP on the server, you can put the API key in an environment variable or store it in a directory outside of the website directory.
Jun 15, 2021 07:48 AM
I’d highly recommend looking into serverless functions here @Tom_Phillips
Here is a quick tutorial using our service - but you can also set up these functions using Node.