HighLevel - Senior Software Engineer (Paltform) - Assignment
HighLevel - Senior Software Engineer (Paltform) - Assignment
Problem Statement:
Design and implement a backend service for Wallet
system supporting
• Setup wallet
• Credit / Debit transactions
• Fetching transactions on wallet
• Get wallet details
Description:
Create the following APIs for implementing a wallet
system.
1. Initialize wallet
1. Setup a new wallet with initial balance.
2. API endpoint → /setup
3.
Request [POST] Response
2. Credit/Debit amount
1. This API should credit/debit the requested
amount to the wallet.
2. API endpoint → /transact/:walletId
3.
Request [POST] Response
‘Recharge’ }
2. API endpoint →
/transactions?walletId={walletId}&skip={skip}
&limit={limit}
3.
E.g {
walletId=’2434343’&skip=
id,
10&limit
walletId:
=25 string,
amount:
number,
balance:
number,
description:
string, date:
<JS Date
obj>, type:
‘CREDIT’/’DE
BIT’
},
…...
]
1. _id: Transaction id
2. walletId: Id of wallet
3.
}
Example:
Consider the following set of operations that can be
operated for the task.
1. id - system generated id
2. walletId - id of wallet
3. GET
/transactions?walletId=1243434&skip=0&limit=10
type: ‘CREDIT’
},
{
id:
‘54452
1’’,
walletId: ‘1243434’,
amount: 10,
balance: 10,
description:
‘Setup’, date,
type: ‘CREDIT’
}
]
4. GET /wallet/1243434
1. Returns
{
id:’1243434’,
balance: 12.4,
name:
‘Wallet A’
date
UI (Compulsory):
Create a simple 2 page web app to show wallet
balance and transactions.
1.Pagination of data
• MongoDB
• MySQL
• Firebase
Notes:
1. dev-highlevel