Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

devsdocs/bunny_dart

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

95 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

(WIP) Dart Wrapper for Bunny.net APIs

pub package

Supporting various endpoints, including TUS Resumable Upload for efficient video uploads, ensuring seamless integration and enhanced performance.

import 'package:bunny_dart/bunny_dart.dart';

const streamKey = 'YOUR_BUNNY_STREAM_KEY';
const libraryId = 12345;

void main() async {
  final bunnyStreamLibrary = BunnyStream(streamKey).library(libraryId);

  final store = BunnyTusFileStore('tus/fingerprint/path');

  final upload = await bunnyStreamLibrary.createVideoWithTusUpload(
    title: 'Video Title',
    videoFile: XFile('path/to/video.mp4'),
    store: store,
    maxChunkSize: 512 * 1024,
  );

  await upload!.startUpload(
            onStart: (p0, p1) {},
            onProgress: (sended, total, speed, eta) {},
            onComplete: () {},
            measureUploadSpeed: true,
            forceNewUpload: attempt > 3, // Force new upload on retry
          );
}

Credit: https://github.com/tomassasovsky/tus_client

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

  •  

Packages

No packages published

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.