The Merchant Dummy Top-Up Application is a demonstration app that allows users to top up their wallets using Globiance. This app consists of two main components: the User Interface (UI) and the Server. The UI is built with modern web technologies, and the server is implemented using Express and PostgreSQL. The application listens to webhooks provided by Globiance to handle payment notifications and updates.
- Node.js version >= 20.12.0
- PostgreSQL database
- Create a
.env
file by copying from.env.example
and make necessary changes according to the deployment environment.
change directory to web
$ cd web
run command to start local server
$ npm run start
change directory to web
$ cd web
run command to build production ready package
$ npm run build
- Create a
.env
file by copying from.env.example
. - Set the environment variables in the
.env
file. Example:
PORT=
DB_HOST=
DB_DATABASE=
DB_USERNAME=
DB_PASSWORD=
DB_PORT=
JWT_SECRET=
- Use the provided
docker-compose.yml
file to initiate the PostgreSQL database:
$ docker-compose up -d
- Change directory to the server directory:
$ cd Server
- Install server dependencies:
$ npm install
- Start the server:
$ npm run start
- Configure the webhook by following the instructions provided by Globiance: Globiance Webhook Setup
- Ensure all environment variables are correctly set in the
.env
file. - Refer to the Globiance documentation for detailed instructions on webhook configuration.
This guide provides a comprehensive setup for both the UI and server components of the Merchant Dummy Top-Up application, facilitating a seamless integration and deployment process.