How to get started?

WordPress 3.5+

Install our plugin

Start developing with the APIs

WP JSON API Plugin v1.0.1

Build with our easy JSON API plugin for WordPress. If you need APIs to log in, register or get an authenticated users info, our plugin supports a wide array of API functionality not only for WordPress Users but WooCommerce Customers too.

API features:

    WordPress
  • - Register/Sign Up API for Users
  • - Login (with email or username)
  • - Get Users Info
  • - Update Users Info
  • - Update Users Password
  • WooCommerce
  • - Get Customers Info (Billing and Shipping)
  • - Update Customers details

This plugin is also mobile-friendly so you can build WordPress/WooCommerce functionality into your mobile app.

If the app uses Flutter, you can download our wp_json_api Flutter package from pub.dev

Once you have installed our plugin you can start calling the new APIs available

An example request to Login

#1 Get Nonce token

URL[GET]: mysite.com/wp-json/wpapp/auth/v1/nonce

RESULT

				
{
 "data": {
    "nonce": "23d7fb8de7", // this is the nonce
    "root": "https://yoursite.com/wp-json/",
    "expiry": 1586551281
  },
  "message": "",
  "status": 200
}
			
		

#2 Login with a user

URL[POST]: mysite.com/wp-json/wpapp/api/v1/user/login?auth=email

POST Paylaod

				
{
    "nonce":" nonce from previous request", // add nonce here
    "email":"user@gmail.com",
    "password":"password1"
}
			
		

RESULT

				
{
  "data": {
    "user_token": "21361e2f8c89dad033ba2bb93fa68443d806fabad2d9eesdlcm", // USE this for future requests in the Authorization header e.g. Bearer 21361e2f8c89dad033ba2bb93fa68443d806fabad2d9eemke
    "expiry": 0
  },
  "message": "",
  "status": 200
}
			
		
Read full documentation here