i want to ask about wordpress plugins how i can know that the plugin support api and can be used to build apps with Rest-api and some platform like React Native to build apps.

the plugin need users to login and also every user has custom training programs and diets .

Thank you !

  • Search the code for 'register_rest_route' to see if it adds its own REST API endpoints. There's an old AJAX mechanism it might use too. But if it stores the custom training plans and diets as custom post types then you can just read them through the regular JSON API, so unless it has specific actions you need to trigger you might not need a specific endpoint. But you can always ask the plugin author, or even add an API to an existing plugin yourself? – Rup Aug 23 at 7:22

There's no trick. If a plugin has an API that is intended for you to use externally, such as in a React Native app, then its developer would document it.

So all you can do is check if the plugin has developer documentation, and whether that documentation includes a REST API or similar. For example, WooCommerce has a REST API for some of its functionality, which is documented here. If a developer has created something like that for their plugin, then it's probably safe to use their API in your app. If they have not, then it either doesn't exist, or is not safe to use.

While some WordPress functionality, like Custom Post Types, can result in certain plugin data being accessible via the WordPress REST API, you can't be sure of what data and functionality is accessible, in what format, and whether it's safe for external use, unless it's documented.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.