Add video session nativescript-background-http

video
plugins

#1

good morning everyone
i want to ask how to make nativescript-background-http support upload video
i try test to change var session = bghttp.session(“image-upload”); to var session = bghttp.session(“video-upload”);

var bghttp = require("nativescript-background-http");
 
var session = bghttp.session("image-upload");
 
var request = {
    url: "http://myserver.com",
    method: "POST",
    headers: {
        "Content-Type": "application/octet-stream",
        "File-Name": "bigpig.jpg"
    },
    description: "{ 'uploading': 'bigpig.jpg' }"
};
 
var task = session.uploadFile("file/path/bigpig.jpg", request);
 
task.on("progress", logEvent);
task.on("error", logEvent);
task.on("complete", logEvent);
 
function logEvent(e) {
    console.log(e.eventName);
}

but not working on my case