3

Until today I have used the plugin "WP REST API (WP API)". Now I want to use the built-in API but can't find any documentation on it. Any idea?

1
  • 2
    For sure I have tried this. But here v2.wp-api.org it says download the plugin. I want to use the core api. Commented Jan 5, 2016 at 19:04

2 Answers 2

4

The WP REST API is being developed for WordPress as a Feature Plugin.

A Feature Plugin is:

... the way for features to be developed for inclusion in WordPress core. This model allows a feature to be built, tested, refined, and polished before it is considered as a merge candidate

source: https://make.wordpress.org/core/handbook/about/release-cycle/features-as-plugins/

Therefore, the WP REST API is the new WordPress built-in API and the documentation for the WP REST API plugin is also the documentation for the built-in WP API. However, not all features from the plugin have been merged into core WordPress yet.

For WordPress 4.4, the best documentation of how to use what is currently built-in into WordPress is documented in this post on the Make WordPress blog:

REST API: Welcome the Infrastructure to Core https://make.wordpress.org/core/2015/10/28/rest-api-welcome-the-infrastructure-to-core/

However, because the merge into WordPress core will be an on-going, phased process, the best way to keep up with changes per release is to track these sources:

2
  • To get all pages I use this URI with the plugin enabled: /wp-json/pages but the same URI without the plugin won't work. Does this feature work on Wp 4.4? Commented Jan 6, 2016 at 9:29
  • 1
    @KlevisMiho Unfortunately, URL endpoints aren't yet a part of core. "In 4.4, the infrastructure is now available as part of core, while the endpoints continue to only be available in the plugin" (from the post linked to above) Commented Jan 8, 2016 at 0:07
0

The REST API infrastructure was added to WordPress core in 4.4 and the endpoints are being added in 4.5 I believe.

tl;dr - half of it is in WordPress so you still need the plugin to add the endpoints until 4.5 is released.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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