OneOffTech / laravel-tus-upload

A package for handling resumable file uploads in a Laravel application via the http://tus.io/ resumable file upload protocol.
https://oneofftech.xyz/open-source/
MIT License
50 stars 13 forks source link

[Question] Does this package work with other tus-clients #30

Closed yasalkhatib closed 4 years ago

yasalkhatib commented 4 years ago

Hello, Thanks for the awesome package.

Does this package work with any tus-client e.g. "tus-client-android", or it only works with the javascript client the library provides?

Thanks in advance for your help.

avvertix commented 4 years ago

The file transfer happens via the TUS protocol, so any client should work.

There is an authorization step that we added before the file transfer can happen. This step was added to ensure that the user has the rights to upload a file in the application and so to obtain the token for the specific upload (otherwise the user was not identifiable) and the tus endpoint url. The included JS client does that before using the official TUS JS client for the transfer.

If you send the file via the Android client you should do the authorization before in your application and then pass the file and the metadata to the tus client.

yasalkhatib commented 4 years ago

Thank you for your reply!

I will try that.