pub struct VideosClient<'a> { /* private fields */ }Expand description
Domain client for video generation endpoints.
Implementations§
Source§impl<'a> VideosClient<'a>
impl<'a> VideosClient<'a>
Sourcepub async fn create(
&self,
request: &VideoGenerationRequest,
) -> Result<VideoGenerationResponse, OpenRouterError>
pub async fn create( &self, request: &VideoGenerationRequest, ) -> Result<VideoGenerationResponse, OpenRouterError>
Submit a video generation request (POST /videos).
Sourcepub async fn list_models(&self) -> Result<Vec<VideoModel>, OpenRouterError>
pub async fn list_models(&self) -> Result<Vec<VideoModel>, OpenRouterError>
List available video generation models (GET /videos/models).
Sourcepub async fn get_generation(
&self,
job_id: &str,
) -> Result<VideoGenerationResponse, OpenRouterError>
pub async fn get_generation( &self, job_id: &str, ) -> Result<VideoGenerationResponse, OpenRouterError>
Poll a submitted video generation (GET /videos/{jobId}).
Sourcepub async fn get_content(
&self,
job_id: &str,
index: Option<u32>,
) -> Result<Vec<u8>, OpenRouterError>
pub async fn get_content( &self, job_id: &str, index: Option<u32>, ) -> Result<Vec<u8>, OpenRouterError>
Download video output bytes for a completed job (GET /videos/{jobId}/content).
Trait Implementations§
Source§impl<'a> Clone for VideosClient<'a>
impl<'a> Clone for VideosClient<'a>
Source§fn clone(&self) -> VideosClient<'a>
fn clone(&self) -> VideosClient<'a>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl<'a> Copy for VideosClient<'a>
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for VideosClient<'a>
impl<'a> !UnwindSafe for VideosClient<'a>
impl<'a> Freeze for VideosClient<'a>
impl<'a> Send for VideosClient<'a>
impl<'a> Sync for VideosClient<'a>
impl<'a> Unpin for VideosClient<'a>
impl<'a> UnsafeUnpin for VideosClient<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more