How to get an download link or stream li ...

How to get an download link or stream link from url in Flutter?

Dec 08, 2023

If you want to get an download link or stream link, you can use a direct_link package that developed by me.

This package supported :

  • Facebook

  • Instagram

  • Youtube

  • Twitter

  • Dailymotion

  • Vimeo

  • VK

  • SoundCloud

  • Tiktok

  • Reddit

  • Threads

Usage

You can use check class to check your link is supported in this package and get response data.

var directLink = DirectLink();

var data = await directLink.check('url'); // add your url

if (data != null) {
  print(data.title);
  print(data.thumbnail);
  print(data.duration);

  for (var e in data.links!) {
    print(e.type);
    print(e.quality);
    print(e.link);
  }
}

This package is made with a puppeteer package for desktop platforms. So if you use this package for desktop platforms, you can use executablePath in the parameter.

var directLink = DirectLink(executablePath: 'your path');
Gefällt dir dieser Beitrag?

Kaufe thitlwincoder einen Kaffee

Mehr von thitlwincoder