API Reference
The VidioClient is the main entry point for interacting with the VIDIO API from Python. Use it to upload files, create highlight reel jobs, check job status, render outputs, and wait for processing to complete.
The client model
The VidioClient provides a simple interface for working with the VIDIO API. After creating a client with your API key, you can upload input files, create highlight reel jobs, poll job status, render outputs, and wait for jobs to finish.
Properties
Methods
VidioClient(api_key)Initialize client
Creates a new VidioClient instance.
Parameters
Returns
A configured VidioClient instance.
from vidio import VidioClient
import os
client = VidioClient(
api_key=os.getenv("VIDIO_API_KEY")
)client.upload(file_path)Upload file
Uploads a local file to VIDIO and returns an upload result containing the input key.
Parameters
Returns
An upload result object containing `input_key`.
result = client.upload("/path/to/video.mp4")
print(result.input_key)client.create_highlight_reel(input_keys, video_category, output_length, aspect_ratio)Create highlight reel
Creates a highlight reel job from one or more uploaded input files.
Parameters
upload(). The order of input keys determines the order of media in the output video.ball-sports. It can be podcast, ball-sports, non-ball-sports, beauty-product-demo, wedding, travel, others. For best results, specify the category that most closely matches your content. If your content doesn't fit any category, use others.landscape, portrait, or square.Returns
A job object containing `job_id` and status information.
job = client.create_highlight_reel(
input_keys=[result.input_key],
video_category="ball-sports",
output_length=30,
aspect_ratio="landscape",
)
print(job.job_id)
print(job.status)client.get_job(job_id)Get job
Fetches the current status of a job.
Parameters
Returns
A job object with the latest status.
job_status = client.get_job(job.job_id)
print(job_status.status)client.wait_for_job(job_id)Wait for job
Polls the API until the highlight reel job reaches a completed state.
Parameters
Returns
The final completed job object.
final_job = client.wait_for_job(job.job_id)
print(final_job.status)client.render(job_id)Render output
Starts rendering an output video for a completed highlight reel job.
Parameters
Returns
A render result object with render status.
render_result = client.render(
job_id=job.job_id
)
print(render_result.status)client.wait_for_render(job_id)Wait for render
Polls until the render finishes and the output is ready.
Parameters
Returns
The final render result object.
final_render = client.wait_for_render(job.job_id)
print(final_render.output_url)