Deployed App https://nodeqraphql-service.herokuapp.com/api
Please Note an Auth token (passed as Authorization: Bearer {authToken}
) signed with the provided Service account credentials is required to access the server routes.
- Fetch an order a given order uid.
order(uid)
- Fetch all orders between a given booking date range. It should take fromDate and toDate unix timestamps.
orders(fromDate, toDate)
- Fetch all order for a given customer email customer.email. It should take email field.
orders(email)
-
Create a new order in the orders collection. It should accept the title, bookingDate, address
addOrder(title, bookingDate, customer, address)
and customer fields. -
Delete the order for the given order uid.
deleteOrder(uid)
-
Delete all orders for a given customer email customer.email.
deleteOrder(email)
- Clone repo locally git clone
git@github.com:OluwmayowaF/node-graphql-service.git
- Run
npm install
in root directory - Setup Environment with
.env.example
file provided for either Firebase - For Dev
- Run
npm run dev
** Dev relies on Firebase local emulator (Set the required environment variables)
- For Prod
- Run build
npm run build
- Start Server
npm run serve
- Run build