Ian Dunn

Ian Dunn

WordPress Developer

Menu

Skip to content
  • Home
  • About
  • Archives
  • Contact

Tag Archives: REST API

Exposing Custom Post Type Meta for Only a Single API Endpoint

I ran into an undocumented and unexpected problem when registering custom post type meta fields for the REST API. register_meta() exposes meta fields in all REST API endpoints, which can lead to privacy leaks. To avoid that, it can be called conditionally.

Continue reading...

Posted on March 30, 2017 by Ian Dunn. Posted in WordPress | Tagged Custom Post Types, Post Meta, Privacy, register_meta(), register_rest_field(), REST API | 2 Comments

Logging WordPress REST API errors

I wanted a simple logger for errors in REST API requests and didn’t find one online, so I wrote this one:  

Continue reading...

Posted on February 5, 2016 by Ian Dunn. Posted in WordPress | Tagged Logging, REST API | 3 Comments

Subscribe via Email

Feeds & Profiles

  • RSS
  • WordPress.org
  • GitHub
  • HackerOne
  • LinkedIn