This is a backend relay API made for Rapyd starliner app. It uses firebase(firestore) for database and makes request to rapyd API on behalf of client.
- To get started, git clone this repository onto your machine and open the working directory:
- Install the dependencies using
npm install
git clone https://github.com/8mn/rapyd-backend-relay.git
cd rapyd-backend-relay
npm install
- If you haven't already, create your Rapyd Client Portal account so you can access everything you need to get started.
- Head over to Rapyd. From your sandbox account in the Rapyd Client Portal, locate your Secret key and Access key. You can find these by selecting 'Developers' from the left navigation.
- Copy and paste your access and secret key as shown below.
- Spin up a new Firebase project and download service account keys.
- Follow the steps mentioned here to convert your firebase service account to base 64 string
-
APP_URIis url of the app when you deployed it, it is required for verifying signature sent by Rapyd webhook. -
If you want to use it locally, Follow this article and use ngrok.
-
the url will of the form
THIS_APP_URL/hook -
Rename the
.env.exampleto.envand insert the above credentials like so:
ACCESS_KEY="YOUR_RAPYD_ACCESS_KEY"
SECRET_KEY="YOUR_RAPYD_SECRET_KEY"
APP_URI=""
GOOGLE_CONFIG_BASE64=""
npm run start
the web server will now be accessible at https://localhost:5000
If you have any questions/suggestions, Contact me
- My Email:
hey@mnsh.me - Twitter: @oimanish