Open frenchyacinthe opened 4 years ago
Hi ! I'm a newbie trying to help, but I don't get which part do you copy to download the video with the .m38u url.
For your first example, do you download the video with this command ? youtube-dl https://hlstv5mplus-vh.akamaihd.net/i/hls/3e/4634928_,300,700,1400,2100,k.mp4.csmil/master.m3u8
Sorry for bothering you
Yes. Pasting the .m3u8 into youtube-dl allows to download the stream using the generic routine.
Also, it looks like a recent commit might be fixing support for https://revoir.tv5monde.com/ videos
These can be rolled into the existing tv5mondeplus extractor
The tv5unis.ca pages are quite different and need a separate extractor. The site JS needs to be reversed to get the media links from the page.
Checklist
Example URLs
Description
Site may be geo-blocked outside Canada or certain countries.
At this time, videos can be downloaded by manually retrieving the .m3u8 url in the source and pasting it into youtube-dl. Would love to automate this process. Here are copies of the relevant information in the source:
from tv5monde.com
<div class="video_player_loader" id="ldr-guid-dcc0d242-cf27-3928-a2f6-b3a9e47a8669" data-guid="dcc0d242-cf27-3928-a2f6-b3a9e47a8669" data-active="true" data-broadcast='{"files":[{"format":"m3u8","url":"https:\/\/hlstv5mplus-vh.akamaihd.net\/i\/hls\/3e\/4634928_,300,700,1400,2100,k.mp4.csmil\/master.m3u8"}],"primary":"html5","token":false}' data-duration="299" data-width="100%" data-aspectratio="16:9" data-preload="auto" data-autostart="true" data-image="https://vodhdimg.tv5monde.com/tv5mondeplus/images/4634928.jpg" data-skin="seven" data-metadata='{"player":{"name":"jwplayer","version":"7"},"application":{"code":"revoir"},"content":{"title":"destination_saint_malo","series":"destination_francophonie","duration":299}}' data-statistics='{"active":true,"api":"at_internet","mode":"clip","refresh":10,"embedded":false,"application":"38","type":"video","series":"destination_francophonie","title":"destination_saint_malo","chapters":["tv5monde","culture","destination_francophonie"],"publish_date":"2017_03_15"}' data-advertising='{"active":true,"api":"freewheel","client":"vast","client_version":"3","tag":"","scale":[],"site":"www.tv5monderevoir.com","sitepage":"tv5monderevoir\/videos","position":"preroll","env":"prod","protocol":"https","admessage":"fin de la publicit\u00e9 dans xx secondes","skip":false,"skipoffset":5,"skipmessage":"passer dans xx","skiptext":"passer"}' data-probe='{"active":true,"api":"conviva"}' style="position: relative; width: 100%; margin: 0; height: 0; padding: 0 0 56.25%; color: #ffffff;">
from tv5unis.ca
<script id="__NEXT_DATA__" type="application/json">{"dataManager":"[]","props":{"pageProps":{"collectionSlug":"les-fleches-dargent"},"apolloState":{"ROOT_QUERY":{"alerts":[],"videoPlayerPage({\"rootProductSlug\":\"les-fleches-dargent\"})":{"type":"id","generated":true,"id":"$ROOT_QUERY.videoPlayerPage({\"rootProductSlug\":\"les-fleches-dargent\"})","typename":"ArtisanPage"}},"ArtisanBlocksPageMetaData:50":{"id":"50","blockType":"PAGE_META_DATA","blockConfiguration":{"type":"id","generated":true,"id":"$ArtisanBlocksPageMetaData:50.blockConfiguration","typename":"ArtisanBlocksPageMetaDataContent"},"__typename":"ArtisanBlocksPageMetaData"},"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration":{"title":"Les Flèches d'Argent | TV5Unis","description":"Les Flèches d'Argent : créées par Ferdinand Porsche, ces voitures mythiques ont dominé tous les Grands Prix entre 1934 et 1939. Hitler a récupéré leur technologie pour s'en servir dans ses avions, ses blindés, et autres machines de guerre.","keywords":"Documentaires historiques ","language":"fr-CA","canonicalUrl":null,"jsonLd":"{\"@context\":\"http://schema.org\",\"@type\":\"Movie\",\"copyrightYear\":2015,\"countryOfOrigin\":{\"@context\":\"http://schema.org\",\"@type\":\"Country\",\"name\":\"Belgique\"},\"description\":\"Les Flèches d'Argent : créées par Ferdinand Porsche, ces voitures mythiques ont dominé tous les Grands Prix entre 1934 et 1939. Hitler a récupéré leur technologie pour s'en servir dans ses avions, ses blindés, et autres machines de guerre.\",\"image\":\"https://s3.ca-central-1.amazonaws.com/tv5-tv5unis-mogador-qa/Images/BEE/00778842_P0050086.jpg\",\"inLanguage\":\"fr\",\"keywords\":\"Documentaires historiques \",\"name\":\"Les Flèches d'Argent\",\"productionCompany\":{\"@context\":\"http://schema.org\",\"@type\":\"Organization\",\"legalName\":\"RTBF\"},\"timeRequired\":\"PT3120S\",\"url\":\"https://www.tv5unis.ca/les-fleches-dargent\",\"video\":{\"@context\":\"http://schema.org\",\"@type\":\"VideoObject\",\"description\":\"Les Flèches d'Argent : créées par Ferdinand Porsche, ces voitures mythiques ont dominé tous les Grands Prix entre 1934 et 1939. Hitler a récupéré leur technologie pour s'en servir dans ses avions, ses blindés, et autres machines de guerre.\",\"duration\":\"PT3120S\",\"inLanguage\":\"fr\",\"name\":\"Les Flèches d'Argent\",\"regionsAllowed\":[{\"@context\":\"http://schema.org\",\"@type\":\"Place\",\"address\":{\"addressCountry\":\"CA\"}}],\"thumbnailUrl\":\"https://s3.ca-central-1.amazonaws.com/tv5-tv5unis-mogador-qa/Images/BEE/00778842_P0050086.jpg\",\"uploadDate\":\"2020-01-28T01:00:31Z\",\"url\":\"https://www.tv5unis.ca/videos/les-fleches-dargent\"}}","productMetaData":{"type":"id","generated":true,"id":"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.productMetaData","typename":"ProductMetaData"},"ogTags":[{"type":"id","generated":true,"id":"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.0","typename":"OgTag"},{"type":"id","generated":true,"id":"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.1","typename":"OgTag"},{"type":"id","generated":true,"id":"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.2","typename":"OgTag"},{"type":"id","generated":true,"id":"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.3","typename":"OgTag"},{"type":"id","generated":true,"id":"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.4","typename":"OgTag"},{"type":"id","generated":true,"id":"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.5","typename":"OgTag"}],"__typename":"PageMetaDataConfiguration"},"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.productMetaData":{"title":"Les Flèches d'Argent","seasonName":null,"episodeNumber":null,"keywords":"Documentaires historiques ","fmcApplicationId":null,"__typename":"ProductMetaData"},"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.0":{"property":"og:description","content":"Les Flèches d'Argent : créées par Ferdinand Porsche, ces voitures mythiques ont dominé tous les Grands Prix entre 1934 et 1939. Hitler a récupéré leur technologie pour s'en servir dans ses avions, ses blindés, et autres machines de guerre.","__typename":"OgTag"},"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.1":{"property":"og:image","content":"https://image-proxy.tv5unis.ca/pipeline?url=https%3A%2F%2Fs3.ca-central-1.amazonaws.com%2Ftv5-tv5unis-mogador-qa%2FImages%2FBEE%2F00778842_P0050086.jpg\u0026operations=%5B%7B%22operation%22%3A%22resize%22%2C%22params%22%3A%7B%22height%22%3A1125%2C%22width%22%3A2000%7D%7D%5D","__typename":"OgTag"},"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.2":{"property":"og:locale","content":"fr_CA","__typename":"OgTag"},"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.3":{"property":"og:site_name","content":"TV5Unis","__typename":"OgTag"},"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.4":{"property":"og:title","content":"Les Flèches d'Argent | TV5Unis","__typename":"OgTag"},"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration.ogTags.5":{"property":"og:type","content":"website","__typename":"OgTag"},"$ArtisanBlocksPageMetaData:50.blockConfiguration":{"pageMetaDataConfiguration":{"type":"id","generated":true,"id":"$ArtisanBlocksPageMetaData:50.blockConfiguration.pageMetaDataConfiguration","typename":"PageMetaDataConfiguration"},"__typename":"ArtisanBlocksPageMetaDataContent"},"ArtisanBlocksVideoPlayer:123":{"id":"123","blockType":"VIDEO_PLAYER","blockConfiguration":{"type":"id","generated":true,"id":"$ArtisanBlocksVideoPlayer:123.blockConfiguration","typename":"ArtisanBlocksVideoPlayerContent"},"__typename":"ArtisanBlocksVideoPlayer"},"Product:54329":{"id":"54329","title":"Les Flèches d'Argent","slug":"les-fleches-dargent","episodeNumber":null,"seasonNumber":null,"seasonName":null,"productType":"MOVIE","shortSummary":"Les Flèches d'Argent : créées par Ferdinand Porsche, ces voitures mythiques ont dominé tous les Grands Prix entre 1934 et 1939. Hitler a récupéré leur technologie pour s'en servir dans ses avions, ses blindés, et autres machines de guerre.","duration":3120,"tags":{"type":"json","json":["Documentaires historiques "]},"category":{"type":"id","generated":false,"id":"Category:3","typename":"Category"},"collection":null,"mainLandscapeImage":{"type":"id","generated":true,"id":"$Product:54329.mainLandscapeImage","typename":"Image"},"channel":{"type":"id","generated":false,"id":"Channel:1","typename":"Channel"},"nextViewableProduct":null,"rating":null,"season":null,"trailerParent":null,"videoElement":{"type":"id","generated":false,"id":"Video:9381","typename":"Video"},"viewedProgress":null,"__typename":"Product"},"Category:3":{"id":"3","label":"DOCUMENTAIRE","__typename":"Category"},"$Product:54329.mainLandscapeImage":{"url":"https://image-proxy.tv5unis.ca/pipeline?url=https%3A%2F%2Fs3.ca-central-1.amazonaws.com%2Ftv5-tv5unis-mogador-qa%2FImages%2FBEE%2F00778842_P0050086.jpg\u0026operations=%5B%7B%22operation%22%3A%22extract%22%2C%22params%22%3A%7B%22areaheight%22%3A1125%2C%22areawidth%22%3A2000%2C%22height%22%3A1125%2C%22left%22%3A0%2C%22top%22%3A0%2C%22width%22%3A2000%7D%7D%2C%7B%22operation%22%3A%22resize%22%2C%22params%22%3A%7B%22height%22%3A1125%2C%22width%22%3A2000%7D%7D%5D","__typename":"Image"},"Channel:1":{"id":"1","identity":"TV5","__typename":"Channel"},"Video:9381":{"id":"9381","creditsTimestamp":3085,"ads":[{"type":"id","generated":true,"id":"Video:9381.ads.0","typename":"VideoAd"}],"encodings":{"type":"id","generated":true,"id":"$Video:9381.encodings","typename":"VideoEncodings"},"subtitles":[{"type":"id","generated":true,"id":"Video:9381.subtitles.0","typename":"VideoSubtitle"}],"__typename":"Video"},"Video:9381.ads.0":{"format":"VMAP","url":"https://api.tv5unis.ca/vmap/9381","__typename":"VideoAd"},"$Video:9381.encodings.dash":{"url":null,"__typename":"VideoEncoding"},"$Video:9381.encodings":{"dash":{"type":"id","generated":true,"id":"$Video:9381.encodings.dash","typename":"VideoEncoding"},"hls":{"type":"id","generated":true,"id":"$Video:9381.encodings.hls","typename":"VideoEncoding"},"progressive":{"type":"id","generated":true,"id":"$Video:9381.encodings.progressive","typename":"VideoEncoding"},"smooth":{"type":"id","generated":true,"id":"$Video:9381.encodings.smooth","typename":"VideoEncoding"},"__typename":"VideoEncodings"},"$Video:9381.encodings.hls":{"url":"https://bellvps1.content.video.llnw.net/smedia/6f18a5b788684fb8a0f7ab799378c30c/1w/NzHEu7E9aIwVkvgOkdgtDwOEydRtWh4LWhFgWh0hU/07085118-f63c94af7526eca34d6cec1dfed1e900c44edb79.m3u8","__typename":"VideoEncoding"},"$Video:9381.encodings.progressive":{"url":"https://bellvps1.content.video.llnw.net/smedia/6f18a5b788684fb8a0f7ab799378c30c/MT/HUUzht-4CVzXQqntGr9iVaWLGM1n3qv3nlGUwF27M/07085118.mp4","__typename":"VideoEncoding"},"$Video:9381.encodings.smooth":{"url":"https://bellvps1.mfs.video.llnw.net/smedia/6f18a5b788684fb8a0f7ab799378c30c/1w/NzHEu7E9aIwVkvgOkdgtDwOEydRtWh4LWhFgWh0hU/mss/07085118.ism/manifest","__typename":"VideoEncoding"},"Video:9381.subtitles.0":{"language":"fr","url":"http://bellvps1.content.video.llnw.net/smedia/6f18a5b788684fb8a0f7ab799378c30c/1w/NzHEu7E9aIwVkvgOkdgtDwOEydRtWh4LWhFgWh0hU/vtt/1/fr.vtt","__typename":"VideoSubtitle"},"$ArtisanBlocksVideoPlayer:123.blockConfiguration":{"product":{"type":"id","generated":false,"id":"Product:54329","typename":"Product"},"__typename":"ArtisanBlocksVideoPlayerContent"},"$ROOT_QUERY.videoPlayerPage({\"rootProductSlug\":\"les-fleches-dargent\"})":{"blocks":[{"type":"id","generated":false,"id":"ArtisanBlocksPageMetaData:50","typename":"ArtisanBlocksPageMetaData"},{"type":"id","generated":false,"id":"ArtisanBlocksVideoPlayer:123","typename":"ArtisanBlocksVideoPlayer"}],"__typename":"ArtisanPage"}}},"page":"/player","query":{"collectionSlug":"les-fleches-dargent"},"buildId":"1.3.5","runtimeConfig":{"ALLOW_SITE_INDEXATION":"true","API_BASE_URL":"https://api.tv5unis.ca","API_GRAPHQL_PATH":"/graphql","BITMOVIN_KEY":"aec19d4d-710d-4a39-acd7-c21df37d7f4d","CANONICAL_HOST":"www.tv5unis.ca","CHROMECAST_APP_ID":"","COMSCORE_DEBUG":"false","COMSCORE_ID":"22293430","DEBUG_ANALYTICS":"false","ENVIRONMENT":"production","FIREBASE_API_KEY":"AIzaSyBRRiD0sBDnDJNHhD-Iz4n2qTA68arB_gc","FIREBASE_AUTH_DOMAIN":"tv5unis-28d02.firebaseapp.com","FIREBASE_DATABASE_URL":"https://tv5unis-28d02.firebaseio.com","FIREBASE_PROJECT_ID":"tv5unis-28d02","GOOGLE_TAG_MANAGER_ID":"GTM-TD56VC9","M32_ENABLE_TRACKING_PIXEL":"false","MIREGO_LINK":"https://www.mirego.com/fr","RELATED_APP_STORE_LINK":"https://apps.apple.com/ca/app/tv5unis-vid%C3%A9o-sur-demande/id447681452","RELATED_APP_STORE_LINK_APP_ID":"447681452","RELATED_FIRE_TV_LINK":"https://www.amazon.ca/TV5-Qu%C3%A9bec-Canada-TV5Unis-demande/dp/B07ZQNQH69","RELATED_GOOGLE_PLAY_LINK":"https://play.google.com/store/apps/details?id=ca.tv5.video","SENTRY_DSN":"https://5959377ba5d84f0ba2ac5f6aeba6100f:a664ade039554fcfa357b1a99f6f9f6b@sentry.io/1437787","SENTRY_ENVIRONMENT":"production","SOCIAL_TV5_FACEBOOK_LINK":"https://www.facebook.com/TV5.ca","SOCIAL_TV5_INSTAGRAM_LINK":"https://www.instagram.com/tv5.ca","SOCIAL_TV5_YOUTUBE_LINK":"https://www.youtube.com/channel/UCgszR8my6qWpHs-kSC_KJdQ","SOCIAL_UNIS_FACEBOOK_LINK":"https://www.facebook.com/unistv","SOCIAL_UNIS_INSTAGRAM_LINK":"https://www.instagram.com/unistv","SOCIAL_UNIS_YOUTUBE_LINK":"https://www.youtube.com/channel/UCQlHXDEmgWzZ6aO_sjr4B3w"}}</script>