-
Notifications
You must be signed in to change notification settings - Fork 0
Media Upload
Media Upload endpoints for API usage.
All calls are made on the standard api endpoint:
https://api-prod.maxloapi.com
Take a list of hashes and get upload parameters for those files.
POST /api/1/volume/<volume_id>/upload
user_session_key - string - provided in query string or body
volume_id - number - Volume to upload file hash for.
file_list - array of object - Array of files to upload
-
file_hash - string - The hash of the file.
-
file_size - number - The size of the file.
200 OK
upload_list - array of object - Array of results.
-
file_hash - string - The hash of the file.
-
file_size - number - The size of the file.
-
skip_upload - boolean - (optional) The file is already uploaded or not required.
-
no_active_file - boolean - (optional) The file is not needed by any active media file in that volume.
-
signed_opts - object - (optional) Signed options to upload the file.
-
host - string - Host for the upload
-
method - string - Method for the upload
-
path - string - Path for the upload
-
host - string - Host for the upload
-
url - string - Complete url for the upload
-
headers - object - Key value object of headers to include in the upload.
-
-
s3_bucket_id - number - (optional) Bucket ID for the upload.
upload_disabled - boolean - (optional) Uploads to this bucket are
disabled by policy. upload_list will be empty if this is true.
403 Forbidden
Not logged in
Confirm an upload is complete for a single s3 object.
POST /api/1/volume/<volume_id>/s3_object
user_session_key - string - provided in query string or body
volume_id - number - Volume to upload file hash for.
s3_bucket_id - number - The s3_bucket_id from the upload list.
file_hash - string - The hash of the file.
file_size - number - The size of the file.
200 OK
Success
403 Forbidden
Not logged in
Create or resume a multipart upload for an object. You should use this endpoint before each part upload to verify the part is needed. It is highly advised you randomize part upload order to parallelize correctly with other clients. See File Hashing for details on creating the parts list correctly.
POST /api/1/volume/<volume_id>/multipart
user_session_key - string - provided in query string or body
volume_id - number - Volume to upload file hash for.
file_hash - string - The hash of the file.
file_size - number - The size of the file.
part_list - array of object - Array of parts for the upload
-
part_hash - string - The hash of the part.
-
part_size - number - The size of the part.
200 OK
Success
skip_upload - boolean - (optional) Skip upload.
no_active_file - boolean - (optional) No active media file with that
file_hash.
s3_bucket_id - number - Bucket ID for the upload.
upload_id - string - Upload ID for the upload.
upload_list - array of object - Array of results.
-
part_hash - string - The hash of the file.
-
part_size - number - The size of the file.
-
signed_opts - object - (optional) Signed options to upload the file.
-
host - string - Host for the upload
-
method - string - Method for the upload
-
path - string - Path for the upload
-
host - string - Host for the upload
-
url - string - Complete url for the upload
-
headers - object - Key value object of headers to include in the upload.
-
403 Forbidden
Not logged in
Complete a multipart upload for an object.
POST /api/1/volume/<volume_id>/multipart_complete
user_session_key - string - provided in query string or body
volume_id - number - Volume to upload file hash for.
file_hash - string - The hash of the file.
file_size - number - The size of the file.
s3_bucket_id - number - The s3_bucket_id from the upload list.
upload_id - string - The upload ID for the upload.
part_list - array of object - Array of parts for the upload
-
part_hash - string - The hash of the part.
-
part_size - number - The size of the part.
201 Created
Completed the upload and the file is available for download.
200 OK
Success. The upload was already complete.
404 Not Found
The upload was not found for the specified parameters.