POST
/
generate-video
cURL
curl --request POST \
  --url https://nano-gpt.com/api/generate-video \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '{
  "model": "longstories",
  "prompt": "A serene lake at sunset with gentle ripples on the water",
  "script": "<string>",
  "conversationUUID": "<string>",
  "projectId": "<string>",
  "framework": "default",
  "shortRequestEnhancer": false,
  "targetLengthInWords": 70,
  "targetLengthInSeconds": 123,
  "directorNotes": "Warm, cozy lighting with focus on people interacting",
  "aspectRatio": "9:16",
  "scriptConfig": {
    "style": "default",
    "targetLengthInSeconds": 30
  },
  "imageConfig": {
    "model": "hidream_dev",
    "loraConfig": {
      "loraSlug": "ghibsky-comic-book"
    }
  },
  "videoConfig": {
    "enabled": true,
    "model": "kling_v2_1_std_5s"
  },
  "voiceoverConfig": {
    "enabled": true,
    "voiceId": "zWDA589rUKXuLnPRDtAG"
  },
  "captionsConfig": {
    "captionsEnabled": true,
    "captionsStyle": "tiktok"
  },
  "effectsConfig": {
    "transition": "fade",
    "floating": true
  },
  "musicConfig": {
    "enabled": true,
    "musicSlug": "gentle_ambient_loop",
    "volume": 0.3,
    "loop": true
  },
  "voice": "pNInz6obpgDQGcFmaJgB",
  "captionsShow": true,
  "captionsStyle": "default",
  "effects": {
    "transition": "fade",
    "floating": false
  },
  "quality": "medium",
  "motion": {
    "enabled": false,
    "strength": 3
  },
  "music": "video-creation/music/dramatic_cinematic_score.mp3",
  "duration": "5s",
  "aspect_ratio": "16:9",
  "negative_prompt": "blur, distort, and low quality",
  "cfg_scale": 0.5,
  "imageDataUrl": "<string>",
  "imageAttachmentId": "<string>",
  "prompt_optimizer": true,
  "num_inference_steps": 30,
  "pro_mode": false,
  "resolution": "720p",
  "num_frames": 123,
  "frames_per_second": 16,
  "seed": 123,
  "enable_safety_checker": true,
  "showExplicitContent": false,
  "enable_prompt_expansion": true,
  "acceleration": true,
  "shift": 123,
  "age_slider": 18,
  "audioEnabled": false,
  "video_quality": "Standard",
  "aspect": "Portrait"
}'
{
  "runId": "<string>",
  "projectId": "<string>",
  "status": "pending",
  "model": "<string>",
  "cost": 123,
  "paymentSource": "<string>",
  "remainingBalance": 123
}

Authorizations

x-api-key
string
header
required

Body

application/json

Parameters for video generation across different models and providers

The body is of type object.

Response

202
application/json

Video generation request submitted successfully (asynchronous processing)

The response is of type object.