Make WordPress Core

Opened 8 years ago

Closed 4 years ago

#39410 closed enhancement (maybelater)

Add oEmbed Support for Twitch.tv

Reported by: jeffr0's profile jeffr0 Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Embeds Keywords: reporter-feedback needs-patch
Focuses: Cc:

Description

Twitch.tv http://twitch.tv/ is a video hosting/streaming service primarily aimed at gamers that was launched on June 6, 2011. It's not among the list of whitelisted oEmbed providers and I'd like to see that changed so that embedding videos from Twitch is as easy as pasting the URL, similar to how embedding a YouTube video works.

Change History (6)

#1 @ocean90
8 years ago

  • Type changed from feature request to enhancement

Hello @jeffr0, can you please answer the questions on whitelisting providers? This will help us in the decision process.

#2 @johnbillion
8 years ago

  • Keywords reporter-feedback needs-patch added

#3 @jeffr0
8 years ago

Questions answered in order.

Yes the service is mainstream. It's geared towards gamers and launched in 2011. Though core developers may not have heard of it before if they're not into gaming.

Think of it as the YouTube for gamers. It has similar features and backing from a specific demographic.

Yes, the service's Twitter account is verified and has 3.91 million followers https://twitter.com/Twitch

I don't know but Twitch has a document available for developers on how to Embed videos and clips https://dev.twitch.tv/docs/v5/guides/embed-video/

I don't know but they have an entire site dedicated to developers who want to interact with the site https://dev.twitch.tv/

The service is 5 years old

Yes https://en.wikipedia.org/wiki/Twitch.tv

There are a few WordPress plugins that exist that take advantage of the service but none that I could find that add the service as an oEmbed endpoint https://wordpress.org/plugins/search.php?q=twitch

It should also be noted that WordPress.com supports embedding Twitch.tv videos but it requires using a shortcode https://en.support.wordpress.com/videos/twitch-tv-shortcode/

Based on a cursory search of Trac, I didn't see any other tickets proposing that Twitch.tv be added as a whitelisted oEmbed provider

Last edited 8 years ago by jeffr0 (previous) (diff)

#4 @dd32
8 years ago

Example Twitch.tv oembed response: https://api.twitch.tv/v5/oembed?url=https%3A%2F%2Fwww.twitch.tv%2Friotgames%2Fv%2F72749628

sourced from https://github.com/iamcal/oembed/pull/173/files (although I switched that from v4 to v5)
Above link suggests it can handle //clips.twitch.tv/*, //www.twitch.tv/*, //twitch.tv/*

Does the oEmbed endpoint work with WordPress’ oEmbed auto-discovery? If not, could it be made to work with additional HTML tags or attributes being whitelisted?

Having looked at their oEmbed output (at least in that case), it looks like it's just an <iframe> which would infer that oEmbed Discovery would work, however they don't appear to expose the oEmbed Discovery data on the embeddable pages.
I don't see any official docs for the endpoint though.

I feel the best way forward here is for Twitch.tv to officially expose the auto discovery headers for oEmbed (which should mean it'll just work in WordPress) and document their endpoint. In the event they document the endpoint and expose something more than just an iframe, we can then look at whitelisting.

#5 @desrosj
5 years ago

#46075 was marked as a duplicate.

#6 @joemcgill
4 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to maybelater
  • Status changed from new to closed

Looks to me like Twitch has deprecated their oEmbed endpoint altogether. We could still probably create a Twitch block that rendered the iframe markup, but it wouldn't be able to use an oEmbed endpoint, so I'm going to close this for now as a maybelater in case Twitch adds oEmbed in the future.

Note: See TracTickets for help on using tickets.