#71 ✓resolved
Mark Paschal

Return video information in oEmbed for videos

Reported by Mark Paschal | March 12th, 2011 @ 11:54 AM

The oEmbed endpoint for a video does not yet return video specific information. For example, one video has this for its oEmbed data:

{
    "author_name": "andre", 
    "author_url": "http://mlkshk.com/user/andre", 
    "height": 360, 
    "provider_name": "MLKSHK", 
    "provider_url": "http://mlkshk.com/", 
    "title": "Minamisanriku footage", 
    "type": "photo", 
    "url": "http://mlkshk.com/r/XSM", 
    "version": "1.0", 
    "width": 480
}

Instead I would expect an oEmbed video, such as:

{
    "author_name": "andre",
    "author_url": "http://mlkshk.com/user/andre",
    "height": 360,
    "html": "<iframe class=\"youtube-player\" type=\"text/html\" width=\"550\" height=\"339\" src=\"http://www.youtube.com/embed/6JVpy0L5z7s?rnd=0.374508428366&autoplay=0\" frameborder=\"0\"></iframe>",
    "provider_name": "MLKSHK",
    "provider_url": "http://mlkshk.com/",
    "thumbnail_height": 480,
    "thumbnail_url": "http://mlkshk.com/r/XSM",
    "thumbnail_width": 640,
    "title": "Minamisanriku footage",
    "type": "video",
    "version": "1.0",
    "width": 480
}

(Modulo the parts I made up, of course.)

Comments and changes to this ticket

  • Andre Torrez

    Andre Torrez March 12th, 2011 @ 02:58 PM

    • State changed from “new” to “open”

    I'm hesitant to make MLKSHK a source for embeds that way. Would it be too odd to have /r/ simply return the JSON embed I have stored that came from the provider? We're actually storing videos as "link" objects, since in the backend all someone is doing it storing a link to a video, we're just showing the video inline.

    Heck, I'd even like to have /r/ return the URL they gave us. Good? Bad?

  • Mark Paschal

    Mark Paschal March 15th, 2011 @ 04:54 PM

    That makes total sense. In that case it might be nice to expose that in the API, by calling it a link and providing no video specific data, like:

    {
        "author_name": "andre",
        "author_url": "http://mlkshk.com/user/andre",
        "provider_name": "MLKSHK",
        "provider_url": "http://mlkshk.com/",
        "title": "Minamisanriku footage",
        "type": "link",
        "url": "http://www.youtube.com/watch?v=6JVpy0L5z7s",
        "version": "1.0"
    }
    
  • Andre Torrez

    Andre Torrez March 16th, 2011 @ 04:02 PM

    • State changed from “open” to “resolved”

    This is done. I still return width and height, but they should be ignored. I leave them for people who might want to use them for the resulting video (I know, I said I didn't want to be a source for the oembed, I just figure someone might want it).

  • Andre Torrez

    Andre Torrez March 16th, 2011 @ 04:02 PM

    Done, in dev! Not live yet.

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

MLKSHK it's fun for the whole family.

Shared Ticket Bins

People watching this ticket

Tags

Referenced by

Pages