Skip to main content
Use luma/photon-1 with the Comfy Router API. Luma provides the model; Router gives it the shared authentication and request route below.

Quick start

Create a key at platform.comfy.org/profile/api-keys and export it as COMFY_API_KEY. The Python and TypeScript snippets use the Comfy SDKs (pip install comfy-sdk, npm install @comfyorg/sdk); the cURL snippet is the same call over raw HTTP. Model ID: luma/photon-1 Endpoint: POST https://api.comfy.org/v2/models/luma/photon-1

Schema

Input

Router has not published an authored input schema for this model yet: GET /v2/models/luma/photon-1/openapi.json returns an open object with x-comfy-input-schema-authored: false. Router forwards the body to Luma unchanged, so Luma’s own API reference is authoritative for the request fields, and nothing is validated server side.

Output

object
The assets of an image generation. image is the result; video and progress_video belong to the Dream Machine VIDEO operation, which shares this status route, and Luma sends them here as explicit nulls.
string (uri)
The URL of the generated image — the leaf a luma/photon-* generation fills. Null until the generation reaches completed.Format: uri
string (uri)
Always null on an image generation; it is the in-flight preview Luma publishes while a VIDEO generation runs.Format: uri
string (uri)
Always null on an image generation; the luma/ray-* video models fill it instead.Format: uri
string (date-time)
The date and time when the generation was createdFormat: date-time
string
The reason for the state of the generation
string
The type of the generation — always image on this operationPossible values: image
string (uuid)
The ID of the generationFormat: uuid
string
The model used for the generation
object
The image generation request, echoed back inside the terminal document. Luma serialises every field of its request model, writing an explicit null into each one the caller did not set, so read a field’s presence from its VALUE rather than from the key.
string
default:"\"16:9\""
The aspect ratio of the generationPossible values: 1:1, 16:9, 9:16, 4:3, 3:4, 21:9, 9:21
string (uri)
The callback URL for the generationFormat: uri
object
object
An image identity as it comes BACK inside the terminal document. Same shape as LumaImageIdentity, with its members nullable for the reason LumaImageRefEcho gives.
string (uri)[]
The URLs of the image identity
string
Always image when set, echoing the operation. Null when the caller did not send one, for the reason this whole echo object exists.
object[]
An image reference as it comes BACK inside the terminal document. Same shape as LumaImageRef, with each member nullable because Luma echoes an unset one as an explicit null rather than omitting it.
string (uri)
The URL of the image referenceFormat: uri
number
The weight of the image reference
string
default:"\"photon-1\""
The image model used for the generationPossible values: photon-1, photon-flash-1
object
A modify-image reference as it comes BACK inside the terminal document. Same shape as LumaModifyImageRef, with its members nullable for the reason LumaImageRefEcho gives.
string (uri)
The URL of the image referenceFormat: uri
number
The weight of the modify image reference
string
The prompt of the generation
object[]
An image reference as it comes BACK inside the terminal document. Same shape as LumaImageRef, with each member nullable because Luma echoes an unset one as an explicit null rather than omitting it.
string (uri)
The URL of the image referenceFormat: uri
number
The weight of the image reference
string
The state of the generationPossible values: queued, dreaming, completed, failed

Examples

Output

Before you ship

Save one Idempotency-Key for each call and reuse it for retries. Router can hold the connection for up to 10 minutes. The SDKs handle authentication; raw HTTP clients send the headers themselves. Use X-Comfy-Error-Type to classify a failure. A 422 means Router rejected the input before calling the provider. Download generated assets promptly because result URLs can expire.

Headers

Authentication, idempotency, request IDs, error buckets, retry pacing, spend limits.

Using the Router API

Find models, inspect schemas, and retry safely.

Limitations

What Router does not do today, and what to use instead.