Heartbeat + WP REST API at WordCamp NYC

Thanks to the organizers, volunteers, and everyone attending WordCamp NYC for a great event!

Below, you can find the slides and code for my talk on the Heartbeat API for WordPress.

In this presentation, I also included a sample for a custom WordPress API endpoint (hat/tip Ryan McCue) for causing the WordPress admin to honk via a GET request (which is decidedly unRESTful, but equal to the way the Tesla Model S API works). I then provided this URL to the audience prior to discussing the code for much hilarity.

https://twitter.com/alpha1beta/status/496018182571048960

The code’s after the break. But think twice about deploying it on a production server, since it allows others to annoy you with unauthenticated requests. The JSON REST API plugin is required prior to the JSON API’s introduction in WordPress Core itself.

You can download the slides in PDF, and see the slides inline from Speaker Deck below.

Continue reading Heartbeat + WP REST API at WordCamp NYC