Since the WordPress 4.7 “Vaughan” release, each WordPress installation includes REST API endpoints to access and manipulate its content. These endpoints will be the foundation for the next generation of WordPress websites and applications.
Today we’re releasing a brand new Open Source WordPress API console. You can use it to try these endpoints and explore the results. The console works for any website on WordPress.com and also for any self-hosted WordPress installation.
Using the console with WordPress.com APIs
You can use this application today to make read and write requests to the WordPress.com API or the WordPress REST API for any website hosted on WordPress.com or using Jetpack. Visit the new version of the application here: https://developer.wordpress.com/docs/api/console/
Using the console with your self-hosted WordPress sites
To use the console with your self-hosted WordPress installation(s), you’ll need to download the application from GitHub, configure it, and run it on your local machine. You’ll also need to install the WP REST API – OAuth 1.0a Server plugin on your WordPress site. The Application Passwords plugin is another option – but – if you use this plugin, make sure that your site is running over HTTPS. Otherwise, this configuration is insecure.
Full installation and configuration instructions are on the GitHub repository.
The console is a React/Redux application based on
create-react-app that persists its state to
We have a few more features planned that we think you’ll like.
- We can use the new console application to allow you to easily generate and save OAuth2 tokens for your WordPress.com API Applications. As compared to implementing the OAuth2 flow yourself, this will be a much easier way to obtain an API token for testing your applications.
- We also plan to ship the console as a regular WordPress plugin, replacing the existing older plugin.
- We can allow you to add/edit self-hosted WordPress websites on our hosted version of the console and persist them to
localStorage. This way you’ll be able to query your WordPress sites without having to install the console yourself.
As usual, the new console is open source, and we hope this will be a tool that will benefit the entire WordPress community.
If you find a bug, think of a new feature, or want to make some modifications to the API console, feel free to look through existing issues and open a new issue or a PR on the GitHub repository. We welcome all contributions.