API V3 - malsubrata/woo-wallet GitHub Wiki
We are using WC REST API Authentication
For TeraWallet REST API Authentication Please see https://woocommerce.github.io/woocommerce-rest-api-docs/#authentication
-
Method:
GET -
Data Params
email=[email]*user emailper_page=[integer]transaction per pagepage=[integer]current page -
Success Response:
-
Code: 200
Content:Array([0] => stdClass Object([transaction_id] => 74[user_id] => 1[date] => 2018-04-16 17:04:52[type] => credit[amount] => 3.60[balance] => 289.20[details] => Wallet credit through cashback #16-111-04[currency] => DKK[blog_id] => 1)[1] => stdClass Object([transaction_id] => 73[user_id] => 1[date] => 2018-04-16 17:04:51[type] => debit[amount] => 18.00[balance] => 285.60[details] => For order payment Subrata #16-111-04[currency] => DKK[blog_id] => 1))
-
-
Error Response:
-
Code: 401 UNAUTHORIZED
Content:stdClass Object([code] => rest_forbidden[message] => Sorry, you are not allowed to do that.[data] => stdClass Object([status] => 401))
OR
-
Code: invalid_username
Content:stdClass Object([code] => invalid_username[message] => ERROR: Invalid username. Lost your password?[data] =>)
-
Code: 401 UNAUTHORIZED
-
Method:
GET -
Data Params
email=[email]*user email -
Success Response:
-
Code: 200
Content:BALANCE
-
Code: 200
-
Error Response:
-
Code: 401 UNAUTHORIZED
Content:stdClass Object([code] => rest_forbidden[message] => Sorry, you are not allowed to do that.[data] => stdClass Object([status] => 401))
OR
-
Code: invalid_username
Content:stdClass Object([code] => invalid_username[message] => ERROR: Invalid username. Lost your password?[data] =>)
-
Code: 401 UNAUTHORIZED
-
Method:
POST -
Data Params
email=[email]*user emailtype=[string]*tarnsaction typedebitorcreditamount=[decimal]*transaction amountnote=[string]optional transaction description -
Success Response:
-
Code: 200
Content:TRANSACTION ID
-
Code: 200
-
Error Response:
-
Code: 401 UNAUTHORIZED
Content:stdClass Object([code] => rest_forbidden[message] => Sorry, you are not allowed to do that.[data] => stdClass Object([status] => 401))
OR
-
Code: invalid_username
Content:stdClass Object([code] => invalid_username[message] => ERROR: Invalid username. Lost your password?[data] =>)
-
Code: 401 UNAUTHORIZED