Ir al contenido

Luma Photon

Integrar

ID del modelo luma-photon
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/luma-photon?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "A red fox trots through fresh snow at sunrise, soft golden light, shallow depth of field"
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

Esta solicitud: ≈0,019 $ 19 créditos de API Ejecutar en esta página

Obtener clave de API
Luma AI Texto a imagen

Generador de texto a imagen con siete relaciones de aspecto, incluida la ultrapanorámica 21:9 y la vertical 9:21

Luma AI · Imagen

Tu primer resultado aparecerá aquí

Crea una solicitud a continuación y ejecútala con tu clave de API. Las salidas se copian en nuestro almacenamiento, conservadas para siempre o 7 días gratis.

Crear una solicitud

Los controles se generan a partir del esquema del modelo. El código y el precio se actualizan al modificarlos.

•obligatorio 88 / 5000
aspect_ratio predeterminado 1:1

Relación de aspecto del vídeo de salida.

Avanzado enable_safety_checker
POST /run/luma-photon?wait=20 presupuesto → 0,019 $
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/luma-photon?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "A red fox trots through fresh snow at sunrise, soft golden light, shallow depth of field"
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

Ejecutar esta solicitud

Tu clave permanece en este navegador: solo se envía a la Doitong API y solo se guarda en localStorage si marcas Recordar. Obtener una clave de API

Acerca de Luma Photon

Crea imágenes a partir de un `prompt` de texto de hasta 5000 caracteres. `aspect_ratio` puede ser 16:9, 9:16, 1:1, 4:3, 3:4, 21:9 o 9:21, con 1:1 como valor predeterminado. Es la variante estándar de solo texto de la familia Photon, sin entrada de imagen.

Parámetros

NombreTipo PredeterminadoPermitido Descripción
promptobligatorio
Tipostring
≤ 5000 caracteres≥ 3 caracteres
aspect_ratioopcional
Tipoenum
Predeterminado1:1
16:99:161:14:33:421:99:21
Relación de aspecto del vídeo de salida.
enable_safety_checkeropcional
Tipoboolean
Predeterminadotrue
La moderación puede relajarse estableciendo false, siempre que la persona que realiza la solicitud esté autorizada.
obligatorio

Salida

GET /requests/req_8k2m4q7x1z9c3v5b6n0p2r4t
{
  "id": "req_8k2m4q7x1z9c3v5b6n0p2r4t",
  "object": "request",
  "model": "luma-photon",
  "status": "succeeded",
  "created_at": "2026-10-20T12:00:00Z",
  "started_at": "2026-10-20T12:00:02Z",
  "completed_at": "2026-10-20T12:00:09Z",
  "queue_position": null,
  "cost": {
    "credits": 19,
    "usd": "0.019",
    "charged": 19,
    "refunded": 0
  },
  "input": {
    "prompt": "A red fox trots through fresh snow at sunrise, soft golden light, shallow depth of field"
  },
  "output": {
    "images": [
      {
        "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
        "content_type": "image/jpeg",
        "file_name": "0-output.jpeg",
        "file_size": 1843200
      }
    ]
  },
  "outputs": [
    {
      "type": "image",
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
      "content_type": "image/jpeg",
      "file_size": 1843200,
      "width": 1024,
      "height": 768,
      "stored": true
    }
  ],
  "error": null,
  "metrics": {
    "inference_seconds": 6.8
  },
  "urls": {
    "self": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t",
    "cancel": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t/cancel"
  }
}
Tus archivos, tú eligesCada outputs[].url es una copia en nuestro almacenamiento: conservada para siempre (con pago por GB-mes) o 7 días gratis, según la configuración de tu cuenta o ?storage=.
La misma estructura en todos los modelostype, url, content_type, width, height y duration, tanto para imágenes como para vídeo y audio. output es el objeto de resultado propio del modelo.
Campos de salida
images
array of object {url, content_type, file_name, file_size}Imagen producida mediante generación.

Más modelos: Texto a imagen

Para agentes de IA: esta página en Markdown está en https://doitong.com/es-ES/developers/models/luma-photon.md. Todos los modelos y guías: https://doitong.com/developers/llms.txt