Skip to content

This is a small application that uses the ClementineJS boilerplate to provide a timestamp service.

Notifications You must be signed in to change notification settings

StevenXL/fcc-timestamp-microservice

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FreeCodeCamp - Timestamp Microservice

This repository contains a small full-stack Javascript web application.

This was done in order to complete the timestamp microservice challenge from FreeCodeCamp.

This repository will return a JSON representation of the unix timestamp and natural date, given a proper query string to the / endpoint.

Live Version

This application can be found live on Heroku.

Installation and Startup

To run this application locally, first install the dependencies by running npm install in the root directory of the application.

Then, start the server by running nodejs server.js. Note: Replace nodejs with node if your system's executable is called node.

Usage

The application will parse the query string passed into the / endpoint, and return JSON with a unix property and a natural property. These properties represent the unix timestamp and a human-readable date, respectively.

Example Input

https://still-spire-9161.herokuapp.com/December%2015,%202015
https://still-spire-9161.herokuapp.com/1450137600

Example Output

{ "unix": 1450137600, "natural": "December 15, 2015" }

About

This is a small application that uses the ClementineJS boilerplate to provide a timestamp service.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published