Title: Plugin function information
Last modified: March 22, 2019

---

# Plugin function information

 *  Resolved [ravi5155](https://wordpress.org/support/users/ravi5155/)
 * (@ravi5155)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/plugin-function-information/)
 * Hello,
 * Currently I am implementing a plugin,
    Is it possible to get woo wallet functions
   into another plugin. For example : there is a plugin X and i want to access woo_wallet()-
   >wallet->get_wallet_balance($user_id); in plugin X.
 * Also i am unable to do cookie authentication for restful api.
    I had followed
   the link [https://developer.wordpress.org/rest-api/using-the-rest-api/authentication/](https://developer.wordpress.org/rest-api/using-the-rest-api/authentication/)
   Please provide proper example for the same.

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Plugin Author [Subrata Mal](https://wordpress.org/support/users/subratamal/)
 * (@subratamal)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/plugin-function-information/#post-11341989)
 * [@ravi5155](https://wordpress.org/support/users/ravi5155/)
 * Yes you can use `woo_wallet()->wallet->get_wallet_balance($user_id);` to fetch
   a perticualr users current wallet balance.
 * Regarding REST API authentication please check if default WordPress route is 
   working or not.
 *  Thread Starter [ravi5155](https://wordpress.org/support/users/ravi5155/)
 * (@ravi5155)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/plugin-function-information/#post-11342020)
 * Thank you for your immediate response.
 * I know i can can use woo_wallet()->wallet->get_wallet_balance($user_id); to fetch
   a perticular users current wallet balance.
 * But the problem is i am getting woo_wallet as undefined.
    I have created a new
   folder in plugins/testplug/code.php in this I am trying to access the same. Please
   let me know which file to include in my code.php file so that i can access woo
   wallet classes and methods.
 *  Plugin Author [Subrata Mal](https://wordpress.org/support/users/subratamal/)
 * (@subratamal)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/plugin-function-information/#post-11342044)
 * Please use WordPress init hook [https://developer.wordpress.org/reference/hooks/init/](https://developer.wordpress.org/reference/hooks/init/)

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Plugin function information’ is closed to new replies.

 * ![](https://ps.w.org/woo-wallet/assets/icon-256x256.png?rev=3360666)
 * [Wallet for WooCommerce](https://wordpress.org/plugins/woo-wallet/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woo-wallet/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woo-wallet/)
 * [Active Topics](https://wordpress.org/support/plugin/woo-wallet/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woo-wallet/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woo-wallet/reviews/)

## Tags

 * [restapi](https://wordpress.org/support/topic-tag/restapi/)

 * 3 replies
 * 2 participants
 * Last reply from: [Subrata Mal](https://wordpress.org/support/users/subratamal/)
 * Last activity: [7 years, 2 months ago](https://wordpress.org/support/topic/plugin-function-information/#post-11342044)
 * Status: resolved