Hodlers
- NodeJS
- DynamoDB (Database)
- SendGrid (Sending Emails)
- node-schedule (Running Cron Job)
- AWS S3 Bucket (To Store Image)
URL : localhost:3009/create/auction
Method : POST
payload : form-data => because it contains item image also
1st param is a file
2nd param is
auctionData :
{
"endTime": 1549055317000,
"itemDesc": "This is a super bus",
"itemName": "bus",
"startAmount": "45000",
"startTime": 1556719117000
}
Note: auctionData's above all fields are mandatory.
Need to put start-time and end-time in form of EPOCH 13 digit => https://www.epochconverter.com/
Functionality : It submit item for Auction, Contains all Fields Validation.
URL : localhost:3009/create/user
Method : POST
payload:
{
"email":"[email protected]",
"name":"yogendra incred",
"password":"12345611"
}
Functionality : It create authenticated user who can do bidding for items , Contains all Fields Validation.
URL : localhost:3009/login
Method : POST
payload:
{
"email":"[email protected]",
"password":"12345611"
}
Functionality : User can login so that he/she can do bidding . Contains All Fields Validation
In Response, JWT_TOKEN will be received for that user which can be used in other route if that user wants
to perform any actions , like checking his/her all bids
Resposne :
{
"status": "true",
"info": "Successfully Loged In",
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJlbWFpbCI6InlvZ2VuZHJhLnNheGVuYUBpbmNyZWQuY29tIiwiaWF0IjoxNTU2ODEwNTkwfQ.wwWXpCgxp6oa9Z75iDpwd-Wq_D018qqBIRf8amyz4W4"
}
URL : localhost:3009/submit/bid
Method : POST
Header :
apiKey : JWT_TOKEN_OF_LOGEDIN_USER
payload :
{
"amount":"75000",
"itemId":"1556805300070"
}
Functionality : Logged In user can submit bid for item with passed itemId in payload, Contains All Field Validation
URL : localhost:3009/view/bid
Method : GET
Header :
apiKey : JWT_TOKEN_OF_LOGEDIN_USER
Functionality : Get All bid details of the Logged In User
URL : localhost:3009/fetch/all/item
Method : GET
Functionality : Get ALL item in Auction
URL : localhost:3009/fetch/item/:itemId
example : localhost:3009/fetch/item/1556801886187
Method : GET
Functionality : Full Item details for the passed itemId
If the item is already auctioned it gives the details of buyer and the amount
If the item is currently in auction, it list the highest bid amount
URL : localhost:3009/logout
Method : DELETE
Header :
apiKey : JWT_TOKEN_OF_LOGEDIN_USER
Functionality : Log out the LogedIn User
Runing a task to automatically finding the winner of each auction when it hits the endTime.
Sending an email to all users who bid for the item with details of the winner and final
amount.
https://documenter.getpostman.com/view/2416522/SWEB2G2w?version=latest
Yogendra Saxena