WordPress REST API App

Half for fun, half as a side-project for Kokoen, I am creating an app that helps you get information from any WordPress site whose REST API is accessible.

Surprisingly, most of the people don’t know this: WordPress ships with a strong and ready to use REST API that let you perform almost any kind of action: reading, creating, editing and deleting all types of content and users. But even worse: not many developers are taking advantage of this REST API.

What can you do with the WordPress REST API?

Your imagination only limits the possibilities.

Making the Dashboard more interactive is the primary use that WordPress itself and most of the plugins are doing nowadays. They use the API to interact with the database directly using JavaScript on the browser, without having to use PHP and reload the page every time the users need to perform any action.

However, most of the plugins and themes don’t make enough use of API in my opinion. Especially themes are still being very classic here. I don’t see too many of them allowing the user to create a Single Page Application (SPA), even though it should be straightforward for the developers to recode their themes to allow this, or use at least some of the advantages that Single Page Applications offer.

But making the Dashboard more interactive or creating Single Page Applications themes is only a small part of what can be done: building web/mobile/desktop apps to manage WordPress or delivering content to be consumed in other CMS/Platforms are some ideas.

What do we want to do with the app we are creating?

As I mentioned above, I am creating it half for fun (I must recognize I haven’t used the REST API as much as I could have) and half for a side-project for Kokoen that has not a final purpose yet: we are still exploring what can be most useful for our clients and us. There is only one thing decided: we will open source it shortly.

The app is not useful right now, it lets you only read the posts, get a list of pages, users, categories and tags, with a limit of 100 items for each of those. But this is just the beginning. It is made with the Ionic Framework, which is based in Angular since we would like to build both a web and a mobile app.

WordPress REST API App