Overview
This node generates videos from images using the PiAPI Dream Machine service. It transforms a single input image into a short video clip based on a descriptive text prompt and various customizable parameters such as model choice, duration, aspect ratio, and frame position.
Common scenarios where this node is beneficial include:
- Creating dynamic video content from static images for social media or marketing.
- Generating artistic or AI-enhanced video clips from user-provided images.
- Automating video generation workflows where input images are processed into short videos with specific styles or durations.
For example, you can provide an image URL or binary image data along with a prompt describing the desired video effect, select a model version, specify the video length and aspect ratio, and receive a generated video output that animates or transforms the original image accordingly.
Properties
| Name | Meaning |
|---|---|
| Prompt | Descriptive text prompt guiding the video generation process. |
| Image Source | Source of the input image: either a URL or binary data. |
| Image URL | URL of the image to transform into a video (used if Image Source is "URL"). |
| Binary Property | Name of the binary property containing the image data (used if Image Source is "Binary Data"). |
| Frame Position | Position of the image in the video sequence: First Frame (frame0) or Last Frame (frame1). |
| Model Name | The model used for video generation: "Ray v1" or "Ray v2". |
| Duration | Duration of the generated video in seconds (currently only 5 seconds supported). |
| Aspect Ratio | Aspect ratio of the generated video: Portrait (9:16, 3:4), Square (1:1), Landscape (4:3, 16:9), Cinematic (21:9). |
| Service Mode | Service mode for processing the task: Default (user workspace setting), Pay-as-you-go, or Host-your-account. |
| Wait for Completion | Whether to wait for the video generation task to complete before returning results (true/false). |
Output
The node outputs JSON data representing the response from the PiAPI Dream Machine video generation API. This includes details about the created task and, if waiting for completion is enabled, the final video generation result.
The output JSON typically contains:
- Task metadata including task ID.
- Video generation status and results when completed.
- Any error messages if the request failed.
No direct binary video data is output by the node; instead, the output JSON will contain URLs or references to the generated video hosted by the service.
Dependencies
- Requires an API key credential for the PiAPI Dream Machine service.
- Uses internal helper functions to make authenticated HTTP requests to the PiAPI endpoint.
- The node expects the environment to have network access to the PiAPI service endpoints.
Troubleshooting
- Invalid image data: If binary data is provided but is not an image MIME type, the node throws an error. Ensure the binary input is a valid image format.
- Missing image data: If no usable image data is found in the specified binary property, an error is thrown. Verify the binary property name and that the input contains valid image data.
- API request failures: Network issues or invalid credentials may cause errors during the API call. Check your API key configuration and network connectivity.
- Task completion timeout: If waiting for completion is enabled but the task takes too long or fails, the node may throw an error or return incomplete results.
- Use the "Continue On Fail" option to handle errors gracefully within workflows.