interviewstreet / reqres-public

A hosted REST-API ready to respond to your AJAX requests

Home Page:http://reqres.in

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ReqRes

ReqRes is a bare-bones ExpressJS application.

Docs & Demos ⇒

Installation

  • Clone repo
  • Make sure Node.js is installed on your machine
  • npm install
  • node app.js or use Nodemon

Testing

npm test

This generates the final data set file and runs unit tests against the available routes.

Tour

  • app.js - this is where we create the Express app and define all of our routes
  • index.js - this is the main file for the callback routes
  • config.json - this houses the pagination details & fake session token
  • resources_config.json - this houses the configurations specific to a particular resource
  • resources/*.json - this houses the individual resource data JSON files. The name of the file should be the name of the resource and the file should contain an array of items of that resource. Example: resources/movies.json
  • compile_data.js - run this using node compile_data.js to generate the final data-set file data.json.
  • data.json - this is the final data-set file. It is generated by joining all the individual resource JSON files.

About

A hosted REST-API ready to respond to your AJAX requests

http://reqres.in


Languages

Language:JavaScript 62.5%Language:CSS 16.7%Language:SCSS 11.7%Language:HTML 8.9%Language:Dockerfile 0.1%Language:Procfile 0.0%