canonical: https://jentic.com/apis/magichour.ai/magichour

# Magic Hour API

The Magic Hour API generates and edits video, images, and audio with AI models, in beta. Video tools cover text-to-video, image-to-video, video-to-video, lip sync, face swap, talking photos, auto subtitles, and video translation into a target_language; each job returns an id that you poll for its status, such as queued, rendering, or complete, and its downloads. Image tools generate, edit, upscale, and colorize images, remove backgrounds, and swap faces, heads, or clothes, while audio tools generate speech and clone voices. Generation requests consume account credits, and each project reports credits_charged.

## For AI agents

Generate and edit AI video, images, and audio with Magic Hour: text-to-video, image-to-video, lip sync, face swap, image upscaling, background removal, and voice generation, polled to completion by project id.

## Scope

Does not host or stream finished videos to viewers, edit timelines frame by frame, or publish to social platforms. Use for AI generation and editing of video, images, and audio only.

## Capabilities

- Generate a video from a text prompt or a still image with a chosen model, duration, and aspect_ratio
- Lip-sync, face-swap, or translate an existing video into a target_language
- Generate, edit, or upscale images by scale_factor and remove image backgrounds
- Generate speech with the AI voice generator or clone a voice from an audio asset
- Upload source assets through presigned upload URLs before starting a job
- Poll a video, image, or audio project for status, credits_charged, and download links

## Use cases

### AI agent producing social video through Jentic

A marketing agent turns a product brief into a short clip without anyone wiring the Magic Hour client by hand. Through Jentic it searches for 'generate a video from text', loads the text-to-video operation with its input schema, submits a style prompt with end_seconds and an aspect_ratio of 9:16, then polls the video project until its status is complete. The API key is injected at call time.

Example prompt: Call POST `/v1/text-to-video` with end_seconds 5, aspect_ratio '9:16', and style.prompt 'a dog running on a beach', then poll GET `/v1/video-projects/{id}` until status is complete and return the download URL

### Localising video for new markets

A team with a finished English demo needs versions for other languages. The Magic Hour video translator takes an uploaded video asset, a target_language, and a start and end time, and produces a translated video as a project you poll for status and downloads. Auto subtitles can then be added with the subtitle generator.

Example prompt: Call POST `/v1/files/upload-urls` for one video item, upload the file, then POST `/v1/ai-video-translator` with end_seconds, target_language, and the asset path

### Product photo cleanup

An online shop needs clean product images on a plain background at higher resolution. Magic Hour removes image backgrounds from an uploaded asset and upscales images by a scale_factor, each returning an image project with status and downloads. A batch job loops these calls over a folder of photos.

Example prompt: For each photo, call POST `/v1/image-background-remover` with the uploaded asset, then POST `/v1/ai-image-upscaler` with scale_factor 2, polling GET `/v1/image-projects/{id}` for each result

### Voiceover generation

Explainer clips need narration, and recording takes studio time. The Magic Hour AI voice generator produces speech from a style object, and the voice cloner produces speech in a voice taken from an uploaded audio asset. Results arrive as audio projects with status and download links.

Example prompt: Call POST `/v1/ai-voice-generator` with a style object holding the narration text, then GET `/v1/audio-projects/{id}` until complete

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| POST | `/v1/text-to-video` | Generate a video from text |
| POST | `/v1/image-to-video` | Generate a video from an image |
| POST | `/v1/lip-sync` | Lip-sync a video to audio |
| POST | `/v1/ai-video-translator` | Translate a video |
| POST | `/v1/ai-image-generator` | Generate images |
| POST | `/v1/image-background-remover` | Remove an image background |
| GET | `/v1/video-projects/{id}` | Get video status and downloads |
| POST | `/v1/files/upload-urls` | Generate asset upload URLs |

## Key resources

- **Video projects** — Video jobs from tools such as text-to-video, lip sync, and face swap, with status, credits_charged, and downloads
- **Image projects** — Image jobs from generators, editors, upscaler, and background remover
- **Audio projects** — Voice generator and voice cloner jobs
- **Assets** — Source video, audio, and image files uploaded through presigned upload URLs

## AI readiness

This API is usable in Jentic One now. Its AI-readiness score against Jentic's framework shows where it stands today and where improvements would make it even easier for agents to use.

- **Score:** 59 / 100
- **Maturity:** Foundational
- **Dimensions:**
  - Foundational Compliance: 99 / 100
  - Developer Experience & Jentic Compatibility: 74 / 100
  - AI-Readiness & Agent Experience: 33 / 100
  - Agent Usability: 94 / 100
  - Security: 60 / 100
  - AI Discoverability: 67 / 100
- **View full report:** https://jentic.com/apis/magichour.ai/magichour/scorecard
- **How the score is calculated:** https://docs.jentic.com/reference/api-readiness-framework/overview/
- **More about the dimensions:** https://docs.jentic.com/reference/api-readiness-framework/specification/#dimensional-model-overview

### Score it yourself

Every API in the directory is allowlisted, so you can re-score it with no key required.

- **Score your own API:** https://jentic.com/scorecard.md
- **Scoring CLI agent skill:** https://github.com/jentic/jentic-api-scorecard/blob/main/skills/jentic-api-scorecard/SKILL.md

```sh
npx @jentic/api-scorecard-cli score <openapi-url>
```

## Why Jentic

- **Setup:** Wiring Magic Hour by hand means a bearer key, presigned uploads before each job, and polling projects until they render. Through Jentic you install once, import Magic Hour from the API Directory, store the key once, and your agent calls it.
- **Permission scoping:** Magic Hour gives every tool its own path, such as `/v1/text-to-video` or `/v1/image-background-remover`, and puts the project id in the URL path, so a rule can bound your agent to the tools it needs and to one project at a time. You choose the operations it may call, so credit-heavy video tools or project deletion are not included unless you add them.
- **Credential handling:** Your Magic Hour API key is stored once, encrypted, by your own Jentic One instance and injected at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'generate a video from text' or 'remove an image background', and Jentic returns the matching Magic Hour operation with its input schema so the agent calls the right tool without browsing the reference docs.

## Related APIs

- **Runway** — AI video generation from text and images
- **HeyGen** — AI avatar videos and video translation
- **ElevenLabs** — Text-to-speech and voice cloning
- **Leonardo.Ai** — AI image generation and editing

## FAQ

### What authentication does the Magic Hour API use?

The Magic Hour API authenticates with an API key sent as a bearer token in the Authorization header, per its OpenAPI spec. You create the key in the Magic Hour Developer Hub. Through Jentic the key is stored by your own instance and attached at call time, so the agent never sees it.

### How do I know when a Magic Hour video is ready?

Each generation call returns a project id. Poll GET `/v1/video-projects/{id}`, or the image and audio project equivalents, until status moves from queued and rendering to complete, then read the downloads field. A status of error means the job failed.

### What are the rate limits for the Magic Hour API?

The OpenAPI spec does not specify rate limits. Generation requests consume account credits that vary by tool, model, and settings; check https://docs.magichour.ai for current limits and pricing.

### Is there a Magic Hour MCP server?

You don't need an MCP server to give your agent Magic Hour. Jentic connects it directly from the API Directory: import it, store your API key once, and your agent calls the video, image, and audio tools it needs, discovered on demand rather than loaded into its context up front.

### How do I generate an image-to-video clip through Jentic?

Search Jentic for 'turn an image into a video', load the POST `/v1/image-to-video` operation, and run it with end_seconds and the uploaded image asset, then poll the video project for the result. To run it on your own infrastructure, install Jentic One from its GitHub repo.

### Can I limit what my agent is allowed to do with the Magic Hour API?

Yes. For example, a rule that allows POST `/v1/image-background-remover`, POST `/v1/files/upload-urls`, and GET `/v1/image-projects/{id}` lets the agent clean product photos while it cannot start credit-heavy video jobs or delete projects. Jentic logs each call the agent makes.
