Magic Hour MCP server for AI agents and assistants

Securely connect your AI agents and chatbots (Claude, ChatGPT, Cursor, etc) with Magic Hour MCP or direct API to generate images, edit videos, transcribe and enhance audio, and manage media assets through natural language.

Magic Hour logoMagic Hour
Api Key

Magic Hour is an AI media creation platform for generating and editing images, videos, and audio through a unified API. It streamlines multimedia production so teams can programmatically create and iterate on visual and audio assets faster.

38 Tools

Try Magic Hour now

Type what you want done — sign in and watch it run live in the Tool Router playground.

TOOL ROUTER PLAYGROUND
Magic Hour
Try asking
TOOLS

Supported Tools

Every Magic Hour action and event your agent gets out of the box.

Create AI Clothes Change

Start a credit-consuming asynchronous clothes-change image job from person and garment images.

Create AI Face Edit

Start a credit-consuming asynchronous edit of facial features in an image.

Create AI GIF

Start a credit-consuming asynchronous prompt-based animation in GIF, MP4, or WebM format.

Create AI Headshot

Start a credit-consuming asynchronous headshot generation from an image containing one detectable face.

Create AI Image

Start a credit-consuming asynchronous text-to-image job.

Create AI Image Edit

Start a credit-consuming asynchronous prompt-based edit of one or more images.

Create AI Meme

Start a credit-consuming asynchronous meme generation from a topic and a documented Magic Hour template.

Create AI QR Code

Start an asynchronous artistic QR-code generation for supplied content.

Create AI Video Edit

Start a credit-consuming asynchronous prompt-based edit of an input video.

Create AI Voice

Start credit-consuming asynchronous speech generation from text using a documented preset voice.

Create AI Voice Clone

Start credit-consuming asynchronous speech generation by cloning an input voice recording.

Create Animation Video

Start one credit-consuming asynchronous animation render with explicit dimensions, frame rate, duration, style, and assets.

Create Audio-to-Video

Start a credit-consuming asynchronous video generation job from audio and optional visual style controls.

Create Background Removal

Start a credit-consuming asynchronous image job that removes a background or replaces it with an optional supplied image.

Create Body Swap

Start a credit-consuming asynchronous body-swap image job that places a person into a scene at the selected resolution.

Create Character Animation Video

Animate a reference character with motion transferred from a source video in a credit-consuming asynchronous job.

Create Character Replacement Video

Replace a source-video subject with a reference character in a credit-consuming asynchronous video job.

Create Face Swap Photo

Start a credit-consuming asynchronous photo face swap using one source face for all detected faces or up to five individual face mappings.

Create Face Swap Video

Start a credit-consuming asynchronous video face-swap job using one image for all detected faces or up to five individual face mappings.

Create Head Swap

Start a credit-consuming asynchronous head-swap image job from body and head images.

Create Image-to-Video

Start a credit-consuming asynchronous video generation job from a still image and optional final frame, prompt, audio, model, and resolution controls.

Create Image Upscale

Start a credit-consuming asynchronous 2x or 4x image upscale.

Create Lip Sync Video

Start a credit-consuming asynchronous lip-sync video job from audio and a file or YouTube video.

Create Photo Colorization

Start a credit-consuming asynchronous colorization of a photo.

Create Subtitled Video

Start a credit-consuming asynchronous job that transcribes speech and burns styled subtitles into an MP4 video.

Create Talking Photo

Start a credit-consuming asynchronous talking-photo video from an image and audio.

Create Text-to-Video

Start a credit-consuming asynchronous video generation job from a text prompt and model/output options.

Create Video-to-Video

Start a credit-consuming asynchronous stylized transformation of an input video.

Delete Audio Project

Permanently delete one rendered Magic Hour audio project by ID.

Delete Image Project

Permanently delete one Magic Hour image project and its rendered images by ID.

Delete Video Project

Permanently delete one rendered Magic Hour video project by ID.

Detect Faces

Start asynchronous face detection for an image or video and return a task ID.

Generate Asset Upload URLs

Generate ordered, expiring signed upload URLs and Magic Hour file paths for image, video, or audio assets.

Get Account

Return the connected Magic Hour account's tier, available credits, identity, and subscription details; use this before generation to check entitlement and balance.

Get Audio Project

Get an audio project's asynchronous status, error, credit charge, and temporary downloads.

Get Face Detection

Get face-detection status and detected face paths by task ID.

Get Image Project

Get an image project's asynchronous status, error, credit charge, and temporary downloads.

Get Video Project

Get a video project's asynchronous status, error, credit charge, and temporary downloads.

SETUP GUIDE

Connect Magic Hour MCP Tool with your Agent

1

Install Composio

typescript
npm install @composio/core ai @ai-sdk/mcp @ai-sdk/openai
Install the Composio SDK and your agent framework
2

Create a session with MCP enabled

typescript
import { Composio } from "@composio/core";

const composio = new Composio();
const { mcp } = await composio.create("your-user-id", {
  toolkits: ["magic_hour"],
  mcp: true,
});
Create a session scoped to Magic Hour and read its MCP URL and headers
3

Connect your agent to the MCP server

typescript
import { createMCPClient } from "@ai-sdk/mcp";
import { openai } from "@ai-sdk/openai";
import { generateText, stepCountIs } from "ai";

const client = await createMCPClient({
  transport: { type: "http", url: mcp.url, headers: mcp.headers },
});

const { text } = await generateText({
  model: openai("gpt-5.6-sol"),
  tools: await client.tools(),
  prompt: "Generate three 16:9 hero image variations",
  stopWhen: stepCountIs(10),
});

console.log(text);
await client.close();
Pass the session's MCP URL and headers to your agent and run a Magic Hour request
SETUP GUIDE

Connect Magic Hour API Tool with your Agent

1

Install Composio

typescript
npm install @composio/core @composio/openai openai
Install the Composio SDK, the OpenAI provider, and the OpenAI SDK
2

Create a Composio session

typescript
import OpenAI from "openai";
import { Composio } from "@composio/core";
import { OpenAIResponsesProvider } from "@composio/openai";

const composio = new Composio({ provider: new OpenAIResponsesProvider() });
const client = new OpenAI();

const session = await composio.create("your-user-id", { toolkits: ["magic_hour"] });
const tools = await session.tools();
Initialize Composio with the OpenAI Responses provider and create a session scoped to Magic Hour
3

Run Magic Hour tools with your agent

typescript
let response = await client.responses.create({
  model: "gpt-5.6-sol",
  tools,
  input: [{ role: "user", content: "Generate three 16:9 hero image variations" }],
});

while (response.output.some((o) => o.type === "function_call")) {
  const outputs = await composio.provider.handleToolCalls(session, response.output);
  response = await client.responses.create({
    model: "gpt-5.6-sol",
    tools,
    previous_response_id: response.id,
    input: outputs,
  });
}

console.log(response.output_text);
Send a request, execute the Magic Hour tool calls through the session, and print the final answer

Why Use Composio?

AI Native Magic Hour Integration

  • Supports both Magic Hour MCP and direct API based integrations
  • Structured, LLM-friendly schemas for reliable tool execution
  • Rich coverage for reading, writing, and querying your Magic Hour data

Managed Auth

  • Built-in OAuth handling with automatic token refresh and rotation
  • Central place to manage, scope, and revoke Magic Hour access
  • Per user and per environment credentials instead of hard-coded keys

Agent Optimized Design

  • Tools are tuned using real error and success rates to improve reliability over time
  • Comprehensive execution logs so you always know what ran, when, and on whose behalf

Enterprise Grade Security

  • Fine-grained RBAC so you control which agents and users can access Magic Hour
  • Scoped, least privilege access to Magic Hour resources
  • Full audit trail of agent actions to support review and compliance

Rolling this out across your team?

Give your team centralized access control across every framework with Composio’s MCP Gateway.

EXPLORE MCP GATEWAY
FAQ

Frequently asked questions

Yes, Magic Hour requires you to configure your own API key credentials. Once set up, Composio handles secure credential storage and API request handling for you.

Yes! Composio's Tool Router enables agents to use multiple toolkits. Learn more.

Yes. Composio is SOC 2 Type II compliant and is built to keep your Magic Hour connection and credentials secure. OAuth tokens and API keys are encrypted, and sensitive customer data is protected at rest and in transit.

Composio also undergoes independent security testing and continuously monitors its systems for security threats. You can review the latest reports and policies in the Composio Trust Center.

Composio maintains and updates all toolkit integrations automatically, so your agents always work with the latest API versions.

Create the key in your Magic Hour account settings, then paste it once on Composio's connection page. Composio stores it encrypted and uses it only for the Magic Hour actions your agent runs. Nobody else in your workspace can read it, and you can revoke it inside Magic Hour at any time.

When you connect a Magic Hour account through Composio, every action runs under that account, so anything the agent creates, sends, or changes shows up in Magic Hour as done by you. Keep an approval step in your prompt for actions with side effects, such as sending or deleting, and have the agent draft first.

Whatever the credentials you connect allow inside Magic Hour. If Magic Hour lets you scope a key to specific permissions, create a scoped one so the agent can only do what you intend. You can revoke the key inside Magic Hour at any time.

Yes. Composio supports multiple connected accounts for the same app, and that works in Claude, ChatGPT, or any other assistant you connect through Composio. Give each Magic Hour connection a name such as work or personal, and the assistant uses the one you mention in the request. Each account keeps its own credentials and nothing is merged.

The connection stops working the moment Magic Hour rejects the old key. Create a new key in Magic Hour and reconnect the account from the Composio dashboard or by asking your agent to reconnect Magic Hour. Nothing else changes.

Composio's free Hobby plan includes 100,000 tool calls per month with no credit card, which covers most personal Magic Hour use. Paid plans add higher limits and team features. Your Magic Hour plan and its API limits still apply as usual.

Built-in connectors usually give one AI access to a limited set of apps. Many people use Composio because it lets their AI connect to more apps than it normally supports, or connect to multiple accounts for the same app (e.g. connect Claude to multiple Magic Hour accounts).

With Composio, you connect Magic Hour once and then use it across different AI assistants without setting it up separately in each one. Connect your apps to Composio once, then connect Composio to whichever AI you use, whether that's Claude, ChatGPT, Hermes, or your own custom assistant.

Start with Magic Hour.It takes 30 seconds.

Managed auth, hosted MCP servers, and every Magic Hour tool your agent needs.Free to start.

Start building