Rewards & Loyalty Micro NodeJS API Server_

NodeJS Micro API Server

...

Project Details_

Project_

Development of a Rewards and Loyalty Micro NodeJS API Server

Project Roles:

Software ArchitectureDevelopmentQ&ASupport

Project Tech:

NodeJSExpressJSMongoDB

Rewards & Loyalty Micro NodeJS API Server

Development of a Rewards & Loyalty Micro NodeJS API Server

This project focuses on the development of a Rewards & Loyalty Micro Node.js API Server that enables businesses to create and manage loyalty and rewards programs. The system is designed to make it easy for any frontend web or mobile app to connect and take advantage of the services. The database used is MongoDB, to allow for the data schema to be changed as requirements evolve

The server can create loyalty programs with a range of parameters, such as setting up the number of vouchers available and their expiry date. Users can earn stamps for actions taken, such as making purchases, and when the required number of stamps is reached, the stamps are assigned to a voucher which can be redeemed for a reward. Furthermore, the system supports setting up loyalty programs for groups or communities, sharing programs with friends, assigning unique voucher names, and generating vouchers either automatically or manually. It also allows for the use of QR codes as stamps or vouchers.

Additionally, it features advanced time and date functionality, including start-date, end-date, repeat-interval and repeat-until options, as well as the ability to share loyalty programs with friends. The use of QR codes as stamps or vouchers is also supported.

High Level Overview of the Loyalties & Rewards functionality and features.

The API Microserver's functionality(some) and API Routes.

Authentication & Security

  • Server to Server Token Authentication
  • User to Server Token Authenticaion
  • Token Protected API routes
  • URL and Data sanitization

Users Routes

  • Login
  • Logout
  • Logout All Sessions
  • Logout all sessions
  • Find current User
  • Find All Users
  • Find by User id
  • Update by User id
  • Delete User by id

Stamp Routes

  • Get all stamps
  • Submit a Stamp
  • Join on Stamp
  • Get QR-code Stamp
  • Submit Scanned QR-code Stamp
  • Get Number Stamps Participation Progress

Voucher Routes

  • Get a User's vouchers
  • Get a User's Redeemed Vouchers
  • Get All Vouchers from Facility
  • Post Redeem a Voucher
  • Create a Voucher from available stamps
  • Remove / Disable User's Voucher

Loyalty Program Routes

  • Find a Program
  • Find all Programs
  • Create Program
  • Delete a Program by id
  • Find Community Programs + Members
  • Find Programs with memberships
  • Find Managed Programs

Admin: Users Routes

  • Remove User from a Program
  • Add a User from a Program

Admin: Stamps Routes

  • Get All Users with atleast on stamp for program
  • Get User Stamps for a program
  • Create Stamp for User
  • Delete User's Stamps

Admin: Vouchers Routes

  • Get a User's Vouchers
  • Get a User's Redeemed Vouchers
  • Create Generic Voucher
  • Create Birthday Voucher
  • Update a Generic Voucher
  • Update a Birthday Voucher
  • Update a Voucher Loyalty Program

Admin: Loyalty Programs Routes

  • Add a User to a Program
  • Get an Admin Users Managed Programs
  • Get an Admin Users Managed Program by id
  • Update Community Member

Architecture

The architecture of the system was designed to ensure scalability. The server logic and application flow were laid out in flow charts for easier maintenance and development. The database architecture was designed to ensure that the data was normalized and structured for optimal performance. The server architecture was designed with the specific functionality and features needed in mind, to ensure that the server would be able to handle the demands of the applications. Security was an important factor in the design of the architecture, with measures taken to protect the data and prevent unauthorized access.

Loyalty Program

The loyalty program allows businesses to create customized programs with a range of parameters to suit their requirements. The system keeps track of all the vouchers, stamps, and users that are part of the program. It can also generate vouchers automatically or limit the amount of vouchers available. It supports time and date settings such as start date, end date, repeat interval, and repeat until. Additionally, businesses can share their loyalty program with friends and assign unique voucher names.

  • Can create loyalty programs for a group or community.
  • Can assign unique voucher names.
  • Auto generate vouchers or limit the amount of vouchers.
  • Number of stamps required to get a voucher.
  • Supports time & dates: start-date, end-date, repeat-interval and repeat-until.
  • The option to share the loyalty program with friends.

Vouchers

Voucher are required to redeem for a reward.

  • Vouchers can be generated once all the requirements are met for a voucher. This will include rules like, if the user have the nunber of sufficiant stamps require for a voucher.
  • Vouchers can also be manually created, if its a special type of voucher issued for a user, like a birthday voucher.

Stamps

Stamps are earned or given based on a action. The type of action can be declared when you create the loyalty program.

  • A stamp can either be issued based on a action or by joining a loyalty program, depending on the actions defined.
  • QR stamps can also be generated. When this QR code is scanned it will assign a stamp to the user's account.