Is there an API for bbPress?

谁都会走 提交于 2019-12-11 00:57:45

问题


I'm searching for an API for bbPress. I've searched here on SO but the posts I'm seeing are quite old. So is there an api for bbPress. If yes, please how do I access it?

If no, is there anyway I can implement user registration and login via an Android app?


回答1:


Also, check this repository: https://github.com/buddypress/BP-REST

In general, BuddyPress REST API is in development. Current focus will be on members management and their profile fields. You can also check https://bpdevel.wordpress.com site, that's a development blog, where Boone is taking care of all the REST things (see latest posts).

User registration and log in can be implemented independently from BuddyPress, using default WordPress endpoints, that were shipped with the latest WordPress 4.7.




回答2:


All BuddyPress offers for API Documentation is the Codex: https://codex.buddypress.org/

If you want to know if there is a function that does x, then just look in the respective file and that should give you the information for the hooks you need, for example if it’s something to do with activity, then look at bp-activity.php I know this isn't perfect but it should give you what you are looking for. All the function names are very descriptive, so it shouldn’t take more than a few seconds to find a function that fits your needs.

Database classes can be found in these files: bp-{component name}/bp-{component name}-classes-php

Template functions can be found here: bp-{component name}/bp-{component name}-templatetags-php

Once you realize how files and functions within files are organized it should be pretty easy to find what you are looking for exactly. Hope this helps!

Alternatively, you could do something like webview around the login/registration page. Not ideal I know but is an option if you don't want to go through the hassle.




回答3:


There is a bbPress API, which leverages WP JSON API v1.0:

https://github.com/thenbrent/BB-API

But you should consider upgrading it to v2.0 of an API, as it's much better.



来源:https://stackoverflow.com/questions/41319487/is-there-an-api-for-bbpress

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!