Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Latest commit

 

History

6 Commits

Folders and files

Repository files navigation

Case-Study

A RESTful API with a single endpoint that fetches the records data.

Run Locally

Go to a directory

  cd /myDirectory

Clone the project

  git clone https://github.com/tawfeeqm/case-study.git

Go to the project directory

  cd case-study

Install dependencies

  npm install

To run tests, run the following command

  npm test

Start the server

  npm start

API Reference

Get List of Records

  POST /v1/api/records

Request

Request Payload Type Format Description
startDate str Date YYYY-MM-DD Required
endDate str Date YYYY-MM-DD Required
minCount int Required
maxCount int Required

Successful Response

Response Payload Type Description
code int 0
msg str Success
records array of objects [{"key":"TAKwGc6Jr4i8Z487","createdAt":"2017-01-28T01:22:14.398Z","totalCount":2800}]

Failed Response

Response Payload Type Description
code int HTTP error code
msg str Error message

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages