Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rufat/orderdelivery
An order delivery back-end source code.
https://github.com/rufat/orderdelivery
api async await delivery experiment expressjs google-maps latitude longitude nodejs order
Last synced: 24 days ago
JSON representation
An order delivery back-end source code.
- Host: GitHub
- URL: https://github.com/rufat/orderdelivery
- Owner: rufat
- License: mit
- Created: 2018-09-16T19:47:18.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-10-18T23:23:27.000Z (over 5 years ago)
- Last Synced: 2024-11-14T02:26:03.922Z (3 months ago)
- Topics: api, async, await, delivery, experiment, expressjs, google-maps, latitude, longitude, nodejs, order
- Language: JavaScript
- Homepage:
- Size: 39.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Usage
-------------
**Note:** If you're using *Ubuntu*, run the "start.sh" shell script. If not, you have to install the MongoDB, NodeJS and NPM manually.
1. Use your [Google Distance Matrix](https://cloud.google.com/maps-platform/routes/) API key and put into config.json.
2. Run MongoDB: `npm run db`
3. Run ExpressJS server: `npm start`
4. Run unit testing: `npm test`API
-------------
`/order` **[POST]**
**Description:** Place an order.
**Body (JSON):**{
origin: ["", "longitude"],
destination: ["", ""]
}
`/order/:orderId` **[PUT]**
**Description:** Take order.
**Body (JSON):**{
status:
}
`/orders` **[GET]**
**Description:** Listing all the orders. Pagination supported.
**Query:**?page=&limit=