The API response provides a unified view of a web page's metadata and embeddable content.
Key Response Fields
id: The short URL ID (if available) and the canonical URL.url: The canonical URL of the requested content.rel: An array of use cases for the primary embed (e.g., ["player", "ssl"]).html: The responsive embed code for the primary media option.meta: An object containing semantic attributes (e.g., title, description, author, site, keywords) in a unified naming format.links: An object containing arrays of embed options grouped by their functional rel type. Common rel types include:player: Embed widgets (e.g., video players).thumbnail: Image previews.app: Application-specific embeds.image: Direct image links.reader: Article reader views.survey: Survey embeds.icon / logo: Site branding assets.
Note on Data Types: If a rel group contains only one element, the API wraps it as a single object instead of an array.
{
"id": "ACcM3Y",
"url": "http://coub.com/view/2pc24rpb",
"rel": ["player", "ssl"],
"html": "<div ... </div>",
"meta": {
"title": "PARADISE BEACH",
"description": "Ilya Trushin",
"author": "Ilya Trushin",
"site": "Coub",
"canonical": "http://coub.com/view/2pc24rpb"
},
"links": {
"player": [{
"media": { "aspect-ratio": 1.777778 },
"href": "//coub.com/embed/2pc24rpb",
"rel": ["player", "ssl", "html5"],
"type": "text/html",
"html": "<div ... </div>"
}],
"thumbnail": [{
"media": { "height": 360, "width": 640 },
"rel": ["thumbnail"],
"type": "image",
"href": "http://cdn1.aka ... med_1381670134_00040.jpg"
}]
}
}