Video Geneartion

Installation

JavaScript

npm install solvid

Authentication

  1. Get a key from https://api.solvid.xyz (coming soon)

In JavaScript, you can pass the API key using the authToken parameter when creating the client.

JavaScript

const { SolVid } = require('solvid');

const client = new SolVid ({
  authToken: process.env.SOLVID_API_KEY
});

Polling for Generation Status and Retrieving Video

In JavaScript, use async/await for handling the polling.

Javascript

Javascript

Text to Video

Text to Video Generation Example

JavaScript

Image to Video

With start frame

JavaScript

With start frame, loop

JavaScript

With end frame, loop

JavaScript

Extend video

Extending Video

Extend is currently supported only for generated videos. Please make sure the generation is in completed state before passing it

JavaScript

Reverse Extend Video

Extend is currently supported only for generated videos. Please make sure the generation is in completed state before passing it

JavaScript

Interpolating Between Two Generated Videos

Interpolate is currently supported only for generated videos. Please make sure the generation is in completed state before passing it

Javascript

Generations

Get generation with id

Javascript

List all generations

Javascript

Delete generation

Javascript

Camera Motions

Get all supported camera motions

Javascript

How to get a callback when generation has an update

  • It will get status updates (dreaming/completed/failed)

  • It will also get the video url as part of it when completed

  • It's a POST endpoint you can pass, and request body will have the generation object in it

  • It expected to be called multiple times for a status

  • If the endpoint returns a status code other than 200, it will be retried max 3 times with 100ms delay and the request has a 5s timeout

example

TypeScript

Last updated