How to upload videos
3min
Tus Client is available for JavaScript, React Native, Flutter, PHP, Dot NET, and many others, view the full list here.
Use this method to get TUS' session parameters: hostname of the server to upload, secure token.
The general sequence of actions for a direct upload of a video is as follows:
- Create video entity via POST method
- Get TUS' session parameters (you are here now) https://api.teyuto.tv/v2/videos/{idVideo}/signed/upload
- Upload file via TUS client, choose your implementation on
Final endpoint for uploading is constructed using the following template: "https://{hostname}/upload/". Also you have to provide token, client_id, video_id as metadata too.
A short javascript example is shown below, based on tus-js-client. Variable "data" below is the result of this API request.
Please, note that we support 2.x version only of tus-js-client.
Updated 13 May 2024
Did this page help you?