---
title: "Get oEmbed data"
method: GET
path: "/OEmbed"
tags: ["OEmbed"]
---

# Get oEmbed data

`GET /OEmbed`

## Request

- Base URL: `https://video.bunnycdn.com`
- URL: `https://video.bunnycdn.com/OEmbed`
- Auth: none declared
- TypeScript: <https://skmtc.dev/bunny/apis/stream-api/docs/OEmbed/get.ts> (a function with typed inputs; its response is checked against the schema)

Implements the oEmbed specification (oembed.com) for bunny.net video embed URLs, allowing third-party sites and tools to auto-generate an embeddable player for a pasted video link. url must be a bunny.net player URL for an existing video — either the legacy player (e.g. "https://iframe.mediadelivery.net/embed/{libraryId}/{videoId}") or the new player (e.g. "https://player.mediadelivery.net/embed/{libraryId}/{videoId}") — not an arbitrary link. Only the library ID and video ID segments are read, so /play/ URLs are accepted as well as /embed/ ones. For private libraries, the request must satisfy the library's referer restrictions and, separately, a valid token and expires pair if token authentication is enabled — one does not substitute for the other.

## Query parameters

- `url` string, nullable
- `maxWidth` integer, nullable
- `maxHeight` integer, nullable
- `token` string, nullable
- `expires` integer

## Response `200`

The oEmbed data for the video

- VideoOEmbedModel
  - `version` string, nullable: The oEmbed spec version implemented by this response. Always "1.0".
  - `title` string, nullable: The title of the video.
  - `type` string, nullable: The oEmbed resource type. Always "video" for this endpoint.
  - `thumbnail_url` string, nullable: The CDN URL of the video's thumbnail image.
  - `thumbnail_width` integer, nullable: Width in pixels of the thumbnail image. Omitted for custom-uploaded thumbnails, whose dimensions are not known.
  - `thumbnail_height` integer, nullable: Height in pixels of the thumbnail image. Omitted for custom-uploaded thumbnails, whose dimensions are not known.
  - `width` integer: Width in pixels of the embedded player iframe, scaled to fit within maxWidth/maxHeight while preserving the video's aspect ratio.
  - `height` integer: Height in pixels of the embedded player iframe, scaled to fit within maxWidth/maxHeight while preserving the video's aspect ratio.
  - `html` string, nullable: The HTML <iframe> markup required to embed the video player.
  - `provider_name` string, nullable: The name of the embed provider. Always "bunny.net".
  - `provider_url` string, nullable: The URL of the embed provider. Always "https://bunny.net/".

## Other responses

- `400`: The url could not be parsed
- `401`: The video's library is private and no valid token/referer was provided
- `404`: The url is not a recognized bunny.net player URL, or the video library or video does not exist

## Changes

- **2026-11-12** `83116184952f`: 5 info
  - added the non-success response with the status `400`
  - added the non-success response with the status `401`
  - added the non-success response with the status `404`
  - added the optional property `thumbnail_height` to the response with the `200` status
  - …1 more

[Operation history](https://skmtc.dev/bunny/apis/stream-api/changes/OEmbed/get.md)

---

[API](https://skmtc.dev/bunny/apis/stream-api.md) - [All operations](https://skmtc.dev/bunny/apis/stream-api/llms.txt) - [OpenAPI document](https://skmtc.dev/bunny/apis/stream-api/revisions/83116184952f?raw)
