refresh if theres loading or server error
- This microservice produces the UTC as well as unix date when the endpoint is satisfied.
- The API endpoint is
https://timestamp-microservice-sd.glitch.me/api/timestamp/:date_string?
- Returns current UTC and unix date if no
date_string
is passed. - If the date string is
valid
the api returns a JSON, having the structure: e.g.{"unix": 1479663089000 ,"utc": "Sun, 20 Nov 2016 17:31:29 GMT"}
- If the date string is
invalid
the api returns a JSON having the structure{"error" : "Invalid Date" }
- https://timestamp-microservice-sd.glitch.me/api/timestamp/2020-05-29
- https://timestamp-microservice-sd.glitch.me/api/timestamp/1590769211006
{"unix":1590769211006,"utc":"Fri, 29 May 2020 16:20:11 GMT"}
- cd into the project folder
- in powershell or similar terminal, run 'npm install --save'
- then run 'node server.js'
- app starts at specified port number