luma_2/uni-1, served by Comfy Router from Luma 2.
Input: Text, Image · Output: Image
Quick start
Create a key in your Comfy workspace and export it asCOMFY_API_KEY. The Python and TypeScript snippets use the Comfy SDKs (pip install comfy-sdk and npm install @comfyorg/sdk); the cURL snippet is the same call over raw HTTP.
Model ID: luma_2/uni-1
Endpoint: POST https://api.comfy.org/v2/models/luma_2/uni-1
- Wait for the result
- Queue and collect later
The same body, sent to
POST https://api.comfy.org/v2/models/luma_2/uni-1/requests. Router answers 201 with a request_id as soon as the run is admitted, and the result is collected once it is ready, from this process or another one. Queued delivery walks through status, cancellation and collection.Schema
Input
Output aspect ratio. The ray-3.2 video models support the subset 9:16, 3:4, 1:1, 4:3, 16:9, 21:9.Possible values:
3:1, 2:1, 21:9, 16:9, 3:2, 4:3, 1:1, 3:4, 2:3, 9:16, 1:2, 1:3Reference images for style/content guidance. Up to 9 for type ‘image’, up to 8 for type ‘image_edit’.
UUID of a prior completed generation to reuse as the source. Used by ray-3.2 video_edit / video_reframe.
MIME type. Required with data (and with url for video sources, e.g. video/mp4 on video_edit / video_reframe).
Model to use. uni-1 / uni-1-max for image generation, ray-3.2 for video generation, editing, and reframing.
Reference to an image or video. Used for style/content guidance, guided generation, video-edit/video-reframe sources, and guide keyframes. Provide exactly one of generation_id, url, or data.
UUID of a prior completed generation to reuse as the source. Used by ray-3.2 video_edit / video_reframe.
MIME type. Required with data (and with url for video sources, e.g. video/mp4 on video_edit / video_reframe).
The kind of generation to perform. image/image_edit are produced by the uni-1 / uni-1-max models; video/video_edit/video_reframe are produced by the ray-3.2 model.Possible values:
image, image_edit, video, video_edit, video_reframeVideo output settings for ray-3.2. Only the fields that affect validation and billing are modelled here; additional fields (edit controls, source_position) are forwarded to Luma untouched.
Clip duration for ray-3.2 video / video_edit. Defaults to 5s. HDR generation (type video) is restricted to 5s.Possible values:
5s, 10sReference to an image or video. Used for style/content guidance, guided generation, video-edit/video-reframe sources, and guide keyframes. Provide exactly one of generation_id, url, or data.
UUID of a prior completed generation to reuse as the source. Used by ray-3.2 video_edit / video_reframe.
MIME type. Required with data (and with url for video sources, e.g. video/mp4 on video_edit / video_reframe).
Not available yet: requests with exr_export=true are rejected with 400 until Luma ships EXR delivery. Will export an EXR file alongside the MP4 (requires hdr true). Rejected for video_reframe.
Output-frame positions for
keyframes, same length; 0–120 for 5s, 0–240 for 10s. Forwarded untouched.Guide-frame images (1–64), mutually exclusive with start_frame/end_frame. Billed at the requested duration; a keyframes request is never a single-keyframe extend.
UUID of a prior completed generation to reuse as the source. Used by ray-3.2 video_edit / video_reframe.
MIME type. Required with data (and with url for video sources, e.g. video/mp4 on video_edit / video_reframe).
Output resolution for ray-3.2 video. Defaults to 720p. 360p is the draft tier. HDR requires 720p or 1080p.Possible values:
360p, 540p, 720p, 1080pReference to an image or video. Used for style/content guidance, guided generation, video-edit/video-reframe sources, and guide keyframes. Provide exactly one of generation_id, url, or data.
UUID of a prior completed generation to reuse as the source. Used by ray-3.2 video_edit / video_reframe.
MIME type. Required with data (and with url for video sources, e.g. video/mp4 on video_edit / video_reframe).
GET /v2/models/luma_2/uni-1/openapi.json, the same document it validates a call against before the request reaches the provider.
Output
Machine-readable failure code for programmatic handlingPossible values:
content_moderated, generation_failed, budget_exhausted, output_not_foundHuman-readable failure description, populated only on a FAILED generation.
null on a successful one.The kind of generation to perform. image/image_edit are produced by the uni-1 / uni-1-max models; video/video_edit/video_reframe are produced by the ray-3.2 model.Possible values:
image, image_edit, video, video_edit, video_reframeExamples
Input
Output
Before you ship
The SDKs create anIdempotency-Key and reuse it for automatic retries. For manual retries, reuse the original key. Router can hold the connection for up to 10 minutes.
When a request fails, Router sends an X-Comfy-Error-Type response header explaining why. A 422 means Router rejected the input before calling the provider, and a 413 means the request body was larger than Router accepts. Download generated assets promptly because result URLs can expire.
Any size limit named in a field description above is the provider’s own bound on that field, quoted from the provider’s specification. Router applies a separate cap to the whole request body, which base64-encoded media counts against: see request body size.
This page documents one partner model called through Comfy Router. The same comfy-sdk / @comfyorg/sdk package also ships a second client, for running a whole ComfyUI workflow graph on Comfy Cloud: Comfy(api_key=...) / new Comfy({ apiKey }), with client.workflows, client.assets and client.jobs. See Comfy SDKs.
Headers
Authentication, idempotency, request IDs, error buckets, retry pacing, spend limits.
Using the Router API
Model discovery, validation errors, retries, and billing.
Limitations
What Router does not do today, and what to use instead.