Visit JQuery/Bootstrap based Single page frontend which accesses above restful api
Source Code for the above example can be found here
You can try https://reqbin.com/ to send api hits to test the above restful api
API Authentication
API Authentication can be done in numerous ways. One was is to use JSON Web Tokens. UsmanLive also present how a json web token based authentication can be implemented via following routes
Route
Method
Input
Comments
try
http://usmanlive.com/wp-json/api/auth/register
POST
{“name”:”-“,”email”:”-“,”password”:”-“}
Registers a User if not registered already else returns an error