[wp-trac] [WordPress Trac] #44748: Ability to register custom embeds to built-in endpoints

WordPress Trac noreply at wordpress.org
Tue Aug 7 13:15:39 UTC 2018


#44748: Ability to register custom embeds to built-in endpoints
-----------------------------+------------------------------
 Reporter:  k1sul1           |       Owner:  (none)
     Type:  feature request  |      Status:  new
 Priority:  normal           |   Milestone:  Awaiting Review
Component:  REST API         |     Version:
 Severity:  normal           |  Resolution:
 Keywords:  needs-patch      |     Focuses:
-----------------------------+------------------------------

Comment (by TimothyBlynJacobs):

 Hi k1sul1,

 This is supported. You can see some more information about it in the
 [docs](https://developer.wordpress.org/rest-api/extending-the-rest-api
 /modifying-responses/#adding-links-to-the-api-response).

 You’ll probably want to use [`rest_prepare_post`
 filter](https://github.com/WordPress/wordpress-develop/blob/master/src/wp-
 includes/rest-api/endpoints/class-wp-rest-posts-controller.php#L1617) as
 well.

 Nested embeds are not currently supported.

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


More information about the wp-trac mailing list