loopback framework / demo friends management Rest API
Example of basic Friends Management Rest API application developed with Strongloop/Loopback JS.
- All below API have common error handling like:
Verify email address are registered email.
Verify both email are not equal. (For some API)
Verify parameter consist two email. (For some API)
- API to create a friend connection between two email addresses.
Check email one is not blocked by email two.
- API to retrieve the friends list for an email address.
- API to retrieve the common friends list between two email addresses.
- API to subscribe to updates from an email address.
Subscribe not equal to make friend.
- API to block updates from an email address.
If friend relationship exist, no longer received updates.
Else, no new friends connection can be added.
- API to retrieve all email addresses that can receive updates from an email address.
Has not blocked updates.
Has a friend connection.
Has been @mentioned in the update.
My main goal for this is to give new programmers some code to look at and talk about.
Open your terminal
$ git clone https://github.com/kankongmeng/loopback-friends-management.git
$ cd loopback-friends-management
$ npm install
$ npm start
Remarks: You can use sample registered email from below or register email using SPUser API.
Live Demo: https://loopback-friends-management.herokuapp.com/explorer/#!/SPUser/SPUser_find
Live Demo: https://loopback-friends-management.herokuapp.com/explorer/
Live Demo: https://loopback-friends-management.herokuapp.com/explorer/#!/FriendManagement/FriendManagement_makeFriend