[wp-trac] [WordPress Trac] #34207: Leverage the REST API structure for the oEmbed endpoint

WordPress Trac noreply at wordpress.org
Thu Oct 8 07:36:01 UTC 2015


#34207: Leverage the REST API structure for the oEmbed endpoint
-------------------------+-------------------------
 Reporter:  swissspidy   |       Owner:  swissspidy
     Type:  enhancement  |      Status:  assigned
 Priority:  normal       |   Milestone:  4.4
Component:  Embeds       |     Version:
 Severity:  normal       |  Resolution:
 Keywords:  has-patch    |     Focuses:
-------------------------+-------------------------
Changes (by swissspidy):

 * keywords:  needs-patch => has-patch


Comment:

 Consider this being my contribution to the REST API :)

 [attachment:34207.diff 34207.diff] does the following:

 * Remove unneeded query vars
 * Registers the API route in `WP_oEmbed_Controller`
 * Removes `wp_oembed_parse_query ` in favour of `wp_oembed_register_route`
 * Introduces `_oembed_rest_pre_serve_request` to handle XML format
 * Updates tests

 All in all these are rather small changes, which just shows us how easy it
 is to work with the API.

 I'd like @rmccue and @pento to have a look at this.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/34207#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list