Video Projects

What this API does

Create the same Video To Video you can make in the browser, but programmatically, so you can automate it, run it at scale, or connect it to your own app or workflow.

Good for

  • Automation and batch processing
  • Adding video to video into apps, pipelines, or tools

How it works (3 steps)

  1. Upload your inputs (video, image, or audio) with Generate Upload URLs and copy the file_path.
  2. Send a request to create a video to video job with the basic fields.
  3. Check the job status until it's complete, then download the result from downloads.

Key options

  • Inputs: usually a file, sometimes a YouTube link, depending on project type
  • Resolution: output size and plan requirements vary by workflow and model. Some workflows derive output size from the input video.
  • Extra fields: e.g. face_swap_mode, start_seconds/end_seconds, or a text prompt

Cost
Credits are charged when the job is queued (credits_charged in the response). Tools billed per frame charge an estimate and settle to the frames that actually render once the job finishes; tools billed per second charge the final amount upfront. Failed jobs are refunded.

For detailed examples, see the product page.

post/v1/video-to-video

Request

  • Base URL
    https://api.magichour.ai
  • URL
    https://api.magichour.ai/v1/video-to-video
  • Auth
    HTTP bearer

Request body

namestring

Give your video a custom name for easy identification.

start_secondsnumber float required

Start time of your clip (seconds). Must be ≥ 0.

end_secondsnumber float required

End time of your clip (seconds). Must be greater than start_seconds.

fps_resolution'FULL' | 'HALF'

Determines whether the resulting video will have the same frame per second as the original video, or half.

  • FULL - the result video will have the same FPS as the input video
  • HALF - the result video will have half the FPS as the input video

Example request

{
  "name": "My Video To Video video",
  "end_seconds": 5,
  "fps_resolution": "HALF",
  "style": {
    "art_style": "Minecraft",
    "version": "default",
    "prompt_type": "default",
    "prompt": "A cinematic scene with warm lighting",
    "model": "default"
  },
  "assets": {
    "video_source": "file",
    "video_file_path": "api-assets/id/1234.mp4"
  }
}

Response

Success

idstring required

Unique ID of the video. Use it with the Get video Project API to fetch status and downloads.

credits_chargedinteger required

The amount of credits deducted from your account to generate the video. If the status is not 'complete', this value is an estimate and may be adjusted upon completion based on the actual FPS of the output video.

If video generation fails, credits will be refunded, and this field will be updated to include the refund.

Example response

{
  "id": "cuid-example",
  "credits_charged": 450
}

Changes

    • info

      added the non-success response with the status

    • info

      removed the Not Found enum value from the response property for the response status

    • info

      removed the Unauthorized enum value from the response property for the response status

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status

    • info

      added the non-success response with the status