Skip to main content
Glama

image_to_video

Generate a Kling video from a prompt and first-frame image via RunAPI, returning task ID, status, and output URLs.

Instructions

Create a Kling task on RunAPI (image to video). Returns a task id, status, and output URLs.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNoGeneration mode. Declared type: string. Known values: "std", "pro".
waitNoPoll until the task reaches a terminal status.
modelNoRunAPI model slug for this model line.
promptYesVideo description; reference media with matching numbered markers. Declared type: string.
cfg_scaleNoGuidance scale (0-1). Declared type: number.
timeout_msNo
aspect_ratioNoOutput aspect ratio. Declared type: string.
callback_urlNoWebhook URL for async notifications. Declared type: string.
enable_soundNoSound generation must remain disabled. Declared type: boolean.
negative_promptNoNegative prompt. Declared type: string.
duration_secondsNoDuration in seconds. Declared type: integer. Known values: 5, 10, 3, 4, 6, 7, 8, 9, 11, 12, 13, 14, 15.
poll_interval_msNo
output_resolutionNoOutput resolution. Declared type: string. Known values: "720p", "1080p", "4k".
reference_video_urlNoPublic HTTP(S) MP4 or MOV reference video URL; cannot be combined with last_frame_image_url. Declared type: string.
last_frame_image_urlNoPublic HTTP(S) JPG, JPEG, or PNG final-frame image URL; cannot be combined with reference_image_urls or reference_video_url. Declared type: string.
reference_image_urlsNoOrdered public HTTP(S) JPG, JPEG, or PNG reference image URLs; cannot be combined with last_frame_image_url. Declared type: array.
reference_video_typeNoUse the video as a base edit or feature reference. Declared type: string. Known values: "base", "feature".
first_frame_image_urlYesPublic HTTP(S) JPG, JPEG, or PNG first-frame image URL. Declared type: string.
preserve_reference_video_audioNoPreserve the reference video's original audio. Declared type: boolean.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed27 schema fields changedv0.3.0
    • addedInput schema / additionalProperties
      Added value: +{}
    • changedInput schema / properties / aspect_ratio / description
      Previous value: -"Output aspect ratio."New value: +"Output aspect ratio. Declared type: string."
    • changedInput schema / properties / callback_url / description
      Previous value: -"Webhook URL for async notifications."New value: +"Webhook URL for async notifications. Declared type: string."
    • changedInput schema / properties / cfg_scale / description
      Previous value: -"Guidance scale (0-1)."New value: +"Guidance scale (0-1). Declared type: number."
    • removedInput schema / properties / duration_seconds / anyOf
      Removed value: -[
      -  {
      -    "const": 5,
      -    "type": "number"
      -  },
      -  {
      -    "const": 10,
      -    "type": "number"
      -  },
      -  {
      -    "const": 3,
      -    "type": "number"
      -  },
      -  {
      -    "const": 4,
      -    "type": "number"
      -  },
      -  {
      -    "const": 6,
      -    "type": "number"
      -  },
      -  {
      -    "const": 7,
      -    "type": "number"
      -  },
      -  {
      -    "const": 8,
      -    "type": "number"
      -  },
      -  {
      -    "const": 9,
      -    "type": "number"
      -  },
      -  {
      -    "const": 11,
      -    "type": "number"
      -  },
      -  {
      -    "const": 12,
      -    "type": "number"
      -  },
      -  {
      -    "const": 13,
      -    "type": "number"
      -  },
      -  {
      -    "const": 14,
      -    "type": "number"
      -  },
      -  {
      -    "const": 15,
      -    "type": "number"
      -  }
      -]
    • changedInput schema / properties / duration_seconds / description
      Previous value: -"Duration in seconds."New value: +"Duration in seconds. Declared type: integer. Known values: 5, 10, 3, 4, 6, 7, 8, 9, 11, 12, 13, 14, 15."
    • addedInput schema / properties / duration_seconds / type
      Added value: +"integer"
    • changedInput schema / properties / enable_sound / description
      Previous value: -"Sound generation must remain disabled."New value: +"Sound generation must remain disabled. Declared type: boolean."
    • changedInput schema / properties / first_frame_image_url / description
      Previous value: -"Public HTTP(S) JPG, JPEG, or PNG first-frame image URL."New value: +"Public HTTP(S) JPG, JPEG, or PNG first-frame image URL. Declared type: string."
    • changedInput schema / properties / last_frame_image_url / description
      Previous value: -"Public HTTP(S) JPG, JPEG, or PNG final-frame image URL; cannot be combined with reference_image_urls or reference_video_url."New value: +"Public HTTP(S) JPG, JPEG, or PNG final-frame image URL; cannot be combined with reference_image_urls or reference_video_url. Declared type: string."
    • removedInput schema / properties / mode / anyOf
      Removed value: -[
      -  {
      -    "const": "std",
      -    "type": "string"
      -  },
      -  {
      -    "const": "pro",
      -    "type": "string"
      -  }
      -]
    • changedInput schema / properties / mode / description
      Previous value: -"Generation mode."New value: +"Generation mode. Declared type: string. Known values: \"std\", \"pro\"."
    • addedInput schema / properties / mode / type
      Added value: +"string"
    • removedInput schema / properties / model / enum
      Removed value: -[
      -  "kling-o1",
      -  "kling-v2.1-master-image-to-video",
      -  "kling-v2.1-pro",
      -  "kling-v2.1-standard",
      -  "kling-v2.5-turbo-image-to-video-pro",
      -  "kling-v2.6",
      -  "kling-v3-omni",
      -  "kling-v3-turbo-image-to-video"
      -]
    • changedInput schema / properties / negative_prompt / description
      Previous value: -"Negative prompt."New value: +"Negative prompt. Declared type: string."
    • removedInput schema / properties / output_resolution / anyOf
      Removed value: -[
      -  {
      -    "const": "720p",
      -    "type": "string"
      -  },
      -  {
      -    "const": "1080p",
      -    "type": "string"
      -  },
      -  {
      -    "const": "4k",
      -    "type": "string"
      -  }
      -]
    • changedInput schema / properties / output_resolution / description
      Previous value: -"Output resolution."New value: +"Output resolution. Declared type: string. Known values: \"720p\", \"1080p\", \"4k\"."
    • addedInput schema / properties / output_resolution / type
      Added value: +"string"
    • changedInput schema / properties / preserve_reference_video_audio / description
      Previous value: -"Preserve the reference video's original audio."New value: +"Preserve the reference video's original audio. Declared type: boolean."
    • changedInput schema / properties / prompt / description
      Previous value: -"Video description; reference media with matching numbered markers."New value: +"Video description; reference media with matching numbered markers. Declared type: string."
    • removedInput schema / properties / prompt / maxLength
      Removed value: -2500
    • removedInput schema / properties / prompt / minLength
      Removed value: -1
    • changedInput schema / properties / reference_image_urls / description
      Previous value: -"Ordered public HTTP(S) JPG, JPEG, or PNG reference image URLs; cannot be combined with last_frame_image_url."New value: +"Ordered public HTTP(S) JPG, JPEG, or PNG reference image URLs; cannot be combined with last_frame_image_url. Declared type: array."
    • removedInput schema / properties / reference_video_type / anyOf
      Removed value: -[
      -  {
      -    "const": "base",
      -    "type": "string"
      -  },
      -  {
      -    "const": "feature",
      -    "type": "string"
      -  }
      -]
    • changedInput schema / properties / reference_video_type / description
      Previous value: -"Use the video as a base edit or feature reference."New value: +"Use the video as a base edit or feature reference. Declared type: string. Known values: \"base\", \"feature\"."
    • addedInput schema / properties / reference_video_type / type
      Added value: +"string"
    • changedInput schema / properties / reference_video_url / description
      Previous value: -"Public HTTP(S) MP4 or MOV reference video URL; cannot be combined with last_frame_image_url."New value: +"Public HTTP(S) MP4 or MOV reference video URL; cannot be combined with last_frame_image_url. Declared type: string."
  2. Changed15 schema fields changedv0.2.0
    • removedInput schema / additionalProperties
      Removed value: -false
    • addedInput schema / properties / duration_seconds / anyOf
      Added value: +[
      +  {
      +    "const": 5,
      +    "type": "number"
      +  },
      +  {
      +    "const": 10,
      +    "type": "number"
      +  },
      +  {
      +    "const": 3,
      +    "type": "number"
      +  },
      +  {
      +    "const": 4,
      +    "type": "number"
      +  },
      +  {
      +    "const": 6,
      +    "type": "number"
      +  },
      +  {
      +    "const": 7,
      +    "type": "number"
      +  },
      +  {
      +    "const": 8,
      +    "type": "number"
      +  },
      +  {
      +    "const": 9,
      +    "type": "number"
      +  },
      +  {
      +    "const": 11,
      +    "type": "number"
      +  },
      +  {
      +    "const": 12,
      +    "type": "number"
      +  },
      +  {
      +    "const": 13,
      +    "type": "number"
      +  },
      +  {
      +    "const": 14,
      +    "type": "number"
      +  },
      +  {
      +    "const": 15,
      +    "type": "number"
      +  }
      +]
    • removedInput schema / properties / duration_seconds / enum
      Removed value: -[
      -  5,
      -  10,
      -  3,
      -  4,
      -  6,
      -  7,
      -  8,
      -  9,
      -  11,
      -  12,
      -  13,
      -  14,
      -  15
      -]
    • removedInput schema / properties / duration_seconds / type
      Removed value: -"number"
    • addedInput schema / properties / mode / anyOf
      Added value: +[
      +  {
      +    "const": "std",
      +    "type": "string"
      +  },
      +  {
      +    "const": "pro",
      +    "type": "string"
      +  }
      +]
    • removedInput schema / properties / mode / enum
      Removed value: -[
      -  "std",
      -  "pro"
      -]
    • removedInput schema / properties / mode / type
      Removed value: -"string"
    • addedInput schema / properties / output_resolution / anyOf
      Added value: +[
      +  {
      +    "const": "720p",
      +    "type": "string"
      +  },
      +  {
      +    "const": "1080p",
      +    "type": "string"
      +  },
      +  {
      +    "const": "4k",
      +    "type": "string"
      +  }
      +]
    • removedInput schema / properties / output_resolution / enum
      Removed value: -[
      -  "720p",
      -  "1080p",
      -  "4k"
      -]
    • removedInput schema / properties / output_resolution / type
      Removed value: -"string"
    • addedInput schema / properties / poll_interval_ms / maximum
      Added value: +9007199254740991
    • addedInput schema / properties / reference_video_type / anyOf
      Added value: +[
      +  {
      +    "const": "base",
      +    "type": "string"
      +  },
      +  {
      +    "const": "feature",
      +    "type": "string"
      +  }
      +]
    • removedInput schema / properties / reference_video_type / enum
      Removed value: -[
      -  "base",
      -  "feature"
      -]
    • removedInput schema / properties / reference_video_type / type
      Removed value: -"string"
    • addedInput schema / properties / timeout_ms / maximum
      Added value: +9007199254740991
  3. Addedv0.1.13
  4. Removedv0.1.9
  5. Changed7 schema fields changedv0.1.2
    • addedInput schema / properties / aspect_ratio / type
      Added value: +"string"
    • addedInput schema / properties / callback_url / type
      Added value: +"string"
    • addedInput schema / properties / first_frame_image_url / type
      Added value: +"string"
    • addedInput schema / properties / last_frame_image_url / type
      Added value: +"string"
    • addedInput schema / properties / negative_prompt / type
      Added value: +"string"
    • addedInput schema / properties / prompt / type
      Added value: +"string"
    • addedInput schema / required
      Added value: +[
      +  "prompt",
      +  "first_frame_image_url"
      +]
  6. First observedv0.1.1

TDQS

B3.2/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden, and it does disclose the async task pattern by stating it returns a task id, status, and output URLs. However, it omits auth/who can call, cost implications (a sibling check_pricing exists), and the fact that wait defaults to true (a blocking call by default), which are non-obvious behavioral traits.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two short, front-loaded sentences with no wasted words; the create action and return shape are both immediate. It is efficient, though slightly clipped for a tool of this complexity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 19-parameter, no-annotation, no-output-schema generation tool the description is thin. It does describe the return values (task id, status, output URLs), which compensates for the missing output schema, but leaves async/polling behavior, exclusivity constraints, and cost context unaddressed.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 89%, so the schema already documents almost all 19 parameters. The description adds no parameter-level meaning (e.g., interaction rules like reference_video_url vs last_frame_image_url, or the mutually exclusive frame options), so it stays at the high-coverage baseline.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource ('Create a Kling task') and parenthetically scopes it to image-to-video, which implicitly separates it from the text_to_video and extend_video siblings. It stops short of naming those alternatives explicitly, so it is clear but not fully self-differentiating.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no when-to-use guidance at all: nothing tells the agent how this differs from text_to_video, motion_control, or extend_video, nor when to prefer wait=true polling versus a callback_url. Usage must be inferred entirely from the name.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.