3

For example http://www.dailymotion.com/video/x61t5f7

HLS video url for video id "x61t5f7" :

http://proxy-079.dc3.dailymotion.com/sec(f4590cdd8be1b6d27cdbb3816c862f1b)/video/327/638/365836723_mp4_h264_aac.m3u8

How to extract this stream_hls_url? Any sample program is there it will be helpful.

The code which we tried is as below,

https://api.dailymotion.com/video/x6bdwlu?fields=id,title,stream_hls_url

We are getting error response as below,

we are getting error response like below, {"error":{"more_info":"https://developer.dailymotion.com/‌​api#error-codes","co‌​de":403,"message":"I‌​nsufficient rights for the fields' parameter of route GET /video/' with value `stream_hls_url'. Required roles: can-read-video-streams, can-read-my-video-streams","type":"access_forbidden"}}

  • Please provide examples of code that you've tried already. – Todd Dec 30 '17 at 14:46
  • https://api.dailymotion.com/video/x6bdwlu?fields=id,title,stream_hls_url we are getting error response like below, {"error":{"more_info":"https:\/\/developer.dailymotion.com\/api#error-codes","code":403,"message":"Insufficient rights for the `fields' parameter of route `GET \/video\/' with value `stream_hls_url'. Required roles: can-read-video-streams, can-read-my-video-streams","type":"access_forbidden"}} – PleaseDontSee Dec 30 '17 at 14:49
  • Sorry, I didn't make myself clear: ideally you should re-edit the question to include the code you've tried so we can see it formatted correctly. – Todd Dec 30 '17 at 16:48
  • 1
    Updated the question as per your suggestion. Thanks – PleaseDontSee Dec 31 '17 at 17:47

1 Answers1

2

You should try this api

https://www.dailymotion.com/player/metadata/video/<VIDEO_ID>?embedder=

There is a "qualities" object which have a url, get a .m3u8 file from this url. This file contain all HLS Video urls of different qualities.

Ahmad
  • 86
  • 6