The QuickStart App shows you how to integrate the FriendlyScore WebComponent in NodeJS. Please download the QuickStart App from Github. In order to run the App, you will first need to obtain the FriendlyScore API keys.
By default, the QuickStart App is running on localhost on port 3000. If you want to run it on a different host and port you must set a new origin at Developer Console.
client_secret from FriendlyScore API keys.
|sandbox||Use this environment to test your integration|
|production||Production API environment|
Start the App
# Begin by cloning the following GitHub repository git clone https://github.com/FriendlyScore/FriendlyScore-Quickstart-NodeJS-Example.git # Go to the downloaded directory cd FriendlyScore-Quickstart-NodeJS-Example # Install NodeJS modules npm install # Set the host and port of the QuickStart app export LISTEN_PORT=3000 export LISTEN_HOST=127.0.0.1 # Set user reference. This will be used to identify the user. export USER_REFERENCE='YOUR_USER_REFERENCE' # Point base URL to FriendlyScore Sandbox API export BASE_URL='https://sandbox.friendlyscore.com' # Set client Id and client secret with your Sandbox API keys from the Dashboard # (Your API keys can be found at https://friendlyscore.com/company/keys) export CLIENT_ID='YOUR_CLIENT_ID' export CLIENT_SECRET='YOUR_CLIENT_SECRET' # Start the Node App and go to http://127.0.0.1:3000 node index.js
You can find all the code for FriendlyScore Connect for web, iOS and Android on our GitHub.