add listener on online/offline event to automatically stop download when
connection loss
update done request to send credentials (it allows backend to properly
remove session-uuid from request.session)
add try-catch to prevent stitch errors. If error appends chunks are
removed
add build_auth_request to create an API authentication request
add a custom decorator to implement two legged API authentication