I've just installed Wordpress 4.7. One of the mentions in the announcement is that it features a REST API.
My understanding is:
- The Wordpress REST API plugin is not needed anymore, because supposely it has already been merged with core in Wordpress 4.7.
- The Wordpress REST API is enabled by default
However, I notice that in a vanilla Wordpress 4.7 install, none of the endpoints seems to work (for example http://examples.com/wp-json/wp/v2/posts
).
How can I tell if the new REST API is really activated? Can the REST API be enabled or disabled with the vanilla Wordpress UI, or should I install a third party plugin to do so?
<link rel='https://api.w.org/' href='https://example.com/wp-json/' />
Seems to just work on my sites.grep -r "<link rel='https://api.w.org/'" .
in thehtml
directory, it returns one hit in file./wp-includes/rest-api.php
with this text:echo "<link rel='https://api.w.org/' href='" . esc_url( $api_root ) . "' />\n";
<link href="http://example.com/wp-json/" rel="https://api.w.org/">