{"id":20679717,"url":"https://github.com/ricardofiorani/oembed","last_synced_at":"2025-04-19T23:52:37.511Z","repository":{"id":35207907,"uuid":"215300130","full_name":"ricardofiorani/oembed","owner":"ricardofiorani","description":"PHP OEmbed wrapper for well-known video platforms and services","archived":false,"fork":false,"pushed_at":"2023-04-03T11:05:48.000Z","size":91,"stargazers_count":39,"open_issues_count":9,"forks_count":7,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-04-19T23:52:32.739Z","etag":null,"topics":["dailymotion","embed","facebook","giphy","kickstarter","oembed","php","thumbnails","twitch","twitter","video","video-embed","vimeo","youtube"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ricardofiorani.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-10-15T13:01:34.000Z","updated_at":"2025-01-06T02:35:13.000Z","dependencies_parsed_at":"2024-11-16T21:27:25.192Z","dependency_job_id":"0c6ce268-9ed9-4548-9382-1a77934b254b","html_url":"https://github.com/ricardofiorani/oembed","commit_stats":{"total_commits":37,"total_committers":1,"mean_commits":37.0,"dds":0.0,"last_synced_commit":"72c962f459976a78c6792c6723eb2eb6a3ec03b1"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ricardofiorani%2Foembed","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ricardofiorani%2Foembed/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ricardofiorani%2Foembed/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ricardofiorani%2Foembed/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ricardofiorani","download_url":"https://codeload.github.com/ricardofiorani/oembed/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249830852,"owners_count":21331357,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dailymotion","embed","facebook","giphy","kickstarter","oembed","php","thumbnails","twitch","twitter","video","video-embed","vimeo","youtube"],"created_at":"2024-11-16T21:27:16.921Z","updated_at":"2025-04-19T23:52:37.467Z","avatar_url":"https://github.com/ricardofiorani.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# OEmbed\n![Build Status](https://github.com/ricardofiorani/oembed/actions/workflows/ci.yml/badge.svg)\n[![Minimum PHP Version](https://img.shields.io/packagist/php-v/ricardofiorani/php-legofy.svg)](https://php.net/)\n[![License](https://poser.pugx.org/ricardofiorani/oembed/license.png)](https://packagist.org/packages/ricardofiorani/oembed)\n[![Total Downloads](https://poser.pugx.org/ricardofiorani/oembed/d/total.png)](https://packagist.org/packages/ricardofiorani/oembed)\n[![Coding Standards](https://img.shields.io/badge/cs-PSR--4-yellow.svg)](https://github.com/php-fig-rectified/fig-rectified-standards)\n\nOEmbed is a PHP library to assist you retrieving data from providers that supports OEmbed.  \nIt was built to be a successor of `ricardofiorani/php-video-url-parser`.\n\n## Installation\n\nInstall the latest version with\n\n```bash\n$ composer require ricardofiorani/oembed\n```\n\n## Requirements\n* PHP 7.4\n* A PSR-18 implementation\n* A PSR-17 implementation of `RequestFactory` and `UriFactory` \n\n## Basic Usage\n```php\n\u003c?php declare(strict_types=1);\n\nuse Your\\PSR7Implementation\\Uri;\nuse RicardoFiorani\\OEmbed\\OEmbed;\n\nrequire __DIR__ . '/vendor/autoload.php';\n\n$service = new OEmbed();\n\n$uri = new Uri('https://www.dailymotion.com/video/x804zfb?playlist=x6ymns');\n\n$result = $service-\u003eget(\n    $uri,\n    480,\n    300,\n    ['omitscript' =\u003e true]\n);\n\necho (string)$result; //will render the HTML (in case of \"video\" or \"rich\") or URL (in case of \"photo\")\n```\n\n## Services supported (and tested)\n- Dailymotion\n- Deviantart.com\n- Facebook*\n- Gfycat\n- Giphy\n- Instagram*\n- Kickstarter\n- Me.me\n- Reddit\n- Soundcloud\n- Spotify\n- Twitch\n- Twitter\n- Vimeo\n- Youtube\n\n\u003e *Facebook and Instagram requires authentication  \n\u003e Please see https://developers.facebook.com/docs/instagram/oembed  \n\u003e Also please see the example at the bottom of this doc \n## Services supported but not tested\n- 23HQ\n- Abraia\n- Adways\n- Alpha App Net\n- Altru\n- amCharts Live Editor\n- Animatron\n- Animoto\n- Apester\n- ArcGIS StoryMaps\n- Archivos\n- Audioboom\n- AudioClip\n- Audiomack\n- AudioSnaps\n- Avocode\n- AxiomNinja\n- Backtracks\n- Beautiful.AI\n- Blackfire.io\n- Blogcast\n- Box Office Buz\n- BrioVR\n- Buttondown\n- Byzart Project\n- Cacoo\n- Carbon Health\n- CatBoat\n- Ceros\n- ChartBlocks\n- chirbit.com\n- CircuitLab\n- Clipland\n- Clyp\n- CoCo Corp\n- CodeHS\n- Codepen\n- Codepoints\n- CodeSandbox\n- CollegeHumor\n- Commaful\n- Coub\n- Crowd Ranking\n- Cyrano Systems\n- Daily Mile\n- Datawrapper\n- Deseret News\n- Didacte\n- Digiteka\n- Dipity\n- DocDroid\n- Dotsub\n- DTube\n- edocr\n- eduMedia\n- EgliseInfo\n- Embed Articles\n- Embedery\n- Embedly\n- Ethfiddle\n- Eyrie\n- Fader\n- Faithlife TV\n- Firework\n- FITE\n- Flat\n- Flickr\n- Flourish\n- Fontself\n- FOX SPORTS Australia\n- FrameBuzz\n- FunnyOrDie\n- Geograph Britain and Ireland\n- Geograph Channel Islands\n- Geograph Germany\n- Getty Images\n- Gifnote\n- GloriaTV\n- GT Channel\n- Gyazo\n- hearthis.at\n- hihaho\n- Homey\n- HuffDuffer\n- Hulu\n- iFixit\n- IFTTT\n- iHeartRadio\n- Indaco\n- Infogram\n- Infoveave\n- Injurymap\n- Inoreader\n- inphood\n- iSnare Articles\n- Issuu\n- ivlismusic\n- Jovian\n- KakaoTv\n- Kidoju\n- Kirim.Email\n- Kit\n- Kitchenbowl\n- Knacki\n- Knowledge Pad\n- LearningApps.org\n- Lille.Pod\n- Livestream\n- Ludus\n- MathEmbed\n- Matterport\n- MediaLab\n- Medienarchiv der Künste - Zürcher Hochschule der Künste\n- Mermaid Ink\n- Microlink\n- Microsoft Stream\n- MixCloud\n- Moby Picture\n- Modelo\n- MorphCast\n- Music Box Maniacs\n- myBeweeg\n- Namchey\n- nanoo.tv\n- Nasjonalbiblioteket\n- Natural Atlas\n- nfb.ca\n- Odds.com.au\n- Odesli (formerly Songlink)\n- Official FM\n- Omniscope\n- On Aol\n- Ora TV\n- Orbitvu\n- Oumy\n- Outplayed.tv\n- Overflow\n- OZ\n- Padlet\n- Pastery\n- PingVP\n- Pinpoll\n- Pixdor\n- Podbean\n- Polaris Share\n- Poll Daddy\n- Port\n- Portfolium\n- posiXion\n- Qualifio\n- Quiz.biz\n- Quizz.biz\n- RadioPublic\n- RapidEngage\n- ReleaseWire\n- Replit\n- RepubHub\n- ReverbNation\n- RiffReporter\n- Roomshare\n- RoosterTeeth\n- Rumble\n- Runkit\n- Sapo Videos\n- Screen9\n- Screencast.com\n- Screenr\n- ScribbleMaps\n- Scribd\n- SendtoNews\n- ShortNote\n- Shoudio\n- Show the Way, actionable location info\n- Simplecast\n- Sizzle\n- Sketchfab\n- SlideShare\n- SmashNotes\n- SmugMug\n- SocialExplorer\n- Soundsgood\n- SpeakerDeck\n- Spotful\n- Spreaker\n- Stanford Digital Repository\n- Streamable\n- StreamOneCloud\n- Sutori\n- Sway\n- TED\n- The New York Times\n- They Said So\n- TickCounter\n- TikTok\n- Toornament\n- Topy\n- Tuxx\n- tvcf\n- TypeCast\n- Typlog\n- Ubideo\n- University of Cambridge Map\n- UnivParis1.Pod\n- UOL\n- Ustream\n- uStudio, Inc.\n- Utposts\n- Uttles\n- VeeR VR\n- Verse\n- VEVO\n- VideoJug\n- Vidlit\n- Vidmizer\n- Vidyard\n- Viously\n- Viziosphere\n- Vizydrop\n- Vlipsy\n- VLIVE\n- Vlurb\n- VoxSnap\n- Wave.video\n- wecandeo\n- Wiredrive\n- Wistia, Inc.\n- wizer.me\n- Wokwi\n- Wootled\n- WordPress.com\n- Xpression\n- Yes, I Know IT!\n- YFrog\n- Zeplin\n- ZingSoft\n- ZnipeTV\n- Zoomable\n- Plus all not mentioned available on https://oembed.com/providers.json\n\n\n## Currently Supported PHP Versions\n* PHP 7.4 || PHP 8.0 || PHP 8.1\n\n## Facebook and Instagram requiring authentication\nYeah I know, it sucks having to create an FB app and generate a token.  \n\nAnyway, there is two ways (maybe more but I can only think of two now) of making this lib work with FB and IG.\n\n### Method 1\nYou make a custom HTTP client (implementing `\\Psr\\Http\\Client\\ClientInterface`) and instructs it to retrieve the token following Facebook guidelines.\n\n### Method 2\nEasier way, you just send your Application ID and Secret as an extra parameter to the endpoint and that's it.\n\n```php\n$service = new OEmbed();\n\n$uri = new Uri('https://www.facebook.com/FacebookDeutschland/videos/2403439749688130/');\n\n$result = $service-\u003eget(\n    $uri,\n    480,\n    300,\n    ['access_token' =\u003e `{$appId}|{$appSecret}`]\n);\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fricardofiorani%2Foembed","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fricardofiorani%2Foembed","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fricardofiorani%2Foembed/lists"}