[wp-trac] [WordPress Trac] #41692: REST API does not return featured_media for Audio/Video

WordPress Trac noreply at wordpress.org
Mon Aug 21 18:40:02 UTC 2017


#41692: REST API does not return featured_media for Audio/Video
----------------------------+-----------------------
 Reporter:  wonderboymusic  |      Owner:
     Type:  defect (bug)    |     Status:  new
 Priority:  normal          |  Milestone:  4.9
Component:  REST API        |    Version:
 Severity:  normal          |   Keywords:  has-patch
  Focuses:                  |
----------------------------+-----------------------
 Audio and Video attachments can have a featured image. This data is not
 currently returned by the REST API `wp/v2/media` endpoint. Part of the
 problem is that the schema for attachments is generated by the Post
 controller, even though the Post controller does not return data for
 attachments. Because the schema is used by the `OPTIONS` endpoint, before
 knowing what mime-type the attachment is, `thumbnail` should be set for
 attachment's attributes so that `featured_media` is added to the responses
 from `wp/v2/media`.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/41692>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list