How is Gcore video hosting organized?
Video Hosting refers to cloud storage of videos that are ready to be distributed and watched on end devices via the public internet. You can upload original video files in different formats, we process the videos in various ways, and we save the result to our internal storage. As a result, you get videos in HLS/MP4 format with subtitles, timeline previews, and other features available. You can upload videos to the storage via the Gcore Customer Portal or API. Learn how to add a video via the Gcore Customer Portal. Upload of videos via API can be done in three ways, which we describe in detail in this article. Quickly navigate to your chosen method here:- Copy from external storage
- Upload from a local device
- Batch upload to migrate a vast number of videos from other services
The original video provided from your side must strictly comply with the input parameters and codec requirements described in the Input Parameters and Codecs documentation.Only videos that follow these specifications (supported protocols, video/audio codecs, profiles, GOP structure, and bitrate constraints) can be accepted by the uploader servers and reliably transcoded for further distribution. Any deviation from the documented requirements may cause the connection to be rejected or lead to unstable transcoding and delivery.
Video upload and processing statuses
Statuses of video processing are described in the Video Status article.Priority of processing
Every uploaded video enters a processing queue. Scheduling is influenced by two levels of priority:- Global priority – Managed automatically by the system on global scale. You cannot influence on it. It depends on converter availability in the processing cluster. This ensures that even without a dedicated region (this an option for enterprises), your videos usually start processing without significant delay.
- Account priority – Applied within your account. You can control it explicitly using the priority attribute.
priority
field in uploaded videos. This field controls scheduling order for video processing tasks within your account. It lets you influence transcoding queue behavior when some jobs should be processed earlier than others (e.g., urgent uploads or sub-user on higher service tiers).
Field priority
in POST /streaming/videos
method:
- Type: integer
- Range: -10 … 10
- -10 = lowest priority (processed after others)
- 0 = default priority
- 10 = highest priority (processed first)
Copy from external storage
In the section, we explain how to copy and migrate files from a third-party, external storage to the Gcore Video Streaming. We will explain the process, offer an example API request, then explain how it works.Overview
If your videos are available by public HTTPS URL, this is the best option to copy video files directly from external storage. Available protocols for migration:- HTTP/HTTPS public access from external video hosting services, such as Vimeo or Mux
- HTTP/HTTPS public access from S3-like storages, such as AWS or Azure
- SFTP protocol
The original file must be in MP4 format or one of the following formats: 3g2, 3gp, asf, avi, dif, dv, flv, f4v, m4v, mov, mp4, mpeg, mpg, mts, m2t, m2ts, qt, wmv, vob, mkv, ogv, webm, vob, ogg, mxf, quicktime, x-ms-wmv, mpeg-tts, vnd.dlna.mpeg-tts.
- Good link :
https://demo-files.gvideo.io/gcore.mp4
(13,8MB from S3 storage) - Good SFTP template :
sftp://login:password@domain.com/path/file.mp4
- Bad link (because of chunked HLS format):
https://demo-files.gvideo.io/hls/master.m3u8
origin_url
in the POST API request. The original video will be downloaded for Video Hosting on our server side.
Note : You can only upload one video per request.
Example of API request
Here is an example of the API request to set a task for copying a video from external storage:How it works
Here’s how it works on our end. We attempt to download a file three times, expecting a 200 OK response to access your provided link. If the download fails, the video entity will stay in the “Empty” status, and details will be added to the fielderror
. You need to delete the empty video entity and try to create a new one with the correct origin URL.
Once successfully uploaded and processed, the video will be available in the Customer Portal. You can check the status of the video by the GET API request or via webhook notifications.
Upload from a local device
When you develop your service, a video must be uploaded from the local host (your backend) or by users from a browser or mobile app. We use the TUS resumable upload protocol for uploading files, which works by cutting the video for upload into small segments and, if an interruption occurs, continuing from the point of interruption. The uploading process consists of three steps.Step 1. Create a video entity and get a video identifier
Specify the main parameters, and do not use theorigin_url
attribute in the POST API request.
Example of the request:
Step 2. Get TUS session parameters
To upload a file, you must get a TUS server URL and secret token. Specify the “id” parameter from step 1 and get the TUS session parameters. Example of the request:servers
: A list of available servers to upload the file; you can use any of them.token
: A secret token for starting the TUS session, valid for 4 hours which is long enough because as soon as the session starts, the token is no longer needed.video
: A copy of the main data pertaining to your video entity.
Step 3. Upload file via TUS chunked protocol
For uploading, use the session parameters taken from the previous step:chunksize
number is given in bytes. Take care to choose the chunk size appropriately:
- The larger the size of a chunk, the faster each chunk will be uploaded using the maximum bandwidth. But in the case of failure to upload, TUS will only start uploading from the last successful chunk, which may have been some time ago. So with large sizes, the speed will be faster, but if it fails, the additional reupload time will be significant.
- With small sizes, the risk of uploading errors decreases. However, due to the features of HTTP (handshakes, etc.) for each chunk’s request, the upload speed will significantly reduce. So small chunk sizes mean a slow but reliable upload speed.
InfoTransmitted data must comply with the rules for the Upload-Metadata header, including:
- Header fields must be comma-separated.
- All values are encoded using the Base64 scheme.
- All keys are unique.
token
, video_id
, and client_id
to find out the upload functionality of the TUS protocol:

- JS: We support 2.x version of tus-js-client, for details check out GitHub
- Android: Gcore’s open-source Kotlin demo app
- iOS: Gcore’s open-source Swift demo app
- Other implementation options can be found on the official TUS website
- HTTP 405 Method Not Allowed. Unexpected response while creating upload session; check parameters of the request.
- HTTP 429 Too Many Requests. Try to send a request later.
- HTTP 500 Internal Server Error :
- Error: token invalid (null) – check the format of parameters, encoding in base64, separation of parameters and key-value pairs.
- Error: token invalid (eyJhbGciOi…) – the same as above.
- Error: token video (12345) does not match this video (23456)
- Error: token client (123) does not match this client (234)
AI extra processing
When uploading a video, it is possible to automatically create subtitles based on AI. Use parametersauto_transcribe_audio_language: auto|<language_code>
and auto_translate_subtitles_language: default|<language_codes,>
when creating a new video via API.
Read more on the page Generate and translate AI captions for a new VOD.
Batch upload to migrate a vast number of videos from other services
When moving a huge collection of video files, batch upload is the best method. This option will be available soon. Please ask our support team for details. We can help you to migrate from several storage types. We have compiled a list of storage types with instructions on how to get an HTTP link to access the file:- Google Drive
- Amazon S3 (step 1: Setting permissions for website access, step 2: Get the list of objects)
- Vimeo
- Mux
- Dropbox
- General SFTP or S3 storage with HTTP file access