Tuesday, March 10, 2020

JSON Server

Get a full fake REST API with zero coding in less than 30 sec

Install JSON Server :
npm install -g json-server

Create a db.json file with some data :
{
  "posts": [
    { "id": 1, "title": "json-server", "author": "typicode" }
  ],
  "comments": [
    { "id": 1, "body": "some comment", "postId": 1 }
  ],
  "profile": { "name": "typicode" }
}

Start JSON Server :
json-server --watch db.json
Now if you go to http://localhost:3000/posts/1,
you'll get
{ "id": 1, "title": "json-server", "author": "typicode" }

FillText.com

Introduction

FillText generates JSON datasets for testing or demonstration purposes.

Demos:

http://filltext.com/?rows=20&fname={firstName}&lname={lastName}
fname,lname,telephone,address,city,state,zip
id,email,username,password