pe=file][multiple]&quot;, {onchange: upload})
])

function upload(e) {
    var files = e.target.files

    var body = new FormData()
    for (var i = 0; i &lt; files.length; i++) {
        body.append(&quot;file&quot; + i, files[i])
    }

    m.request({
        method: &quot;POST&quot;,
        url: &quot;/api/v1/upload&quot;,
        body: body,
    })
}</code></pre>
<hr>
<h3 id=monitoring-progress><a href=#monitoring-progress>Monitoring progress</a></h3>
<p>Sometimes, if a request is inherently slow (e.