Quick overview
Triggers on new Shopify products, writes a motion prompt with OpenAI, animates the main image into a 5-second Sisif video, attaches the MP4 to the product via the Admin GraphQL API, falls back to Google Drive on failure, and reports the outcome in Slack.
How it works
- Triggers when a product is created in Shopify.
- Extracts the product title, type, description, and main image URL, and skips processing if no HTTPS image URL is available.
- Uses OpenAI to generate a short image-to-video motion prompt from the product details, then sends the prompt and image URL to Sisif to start video generation.
- Polls Sisif every 30 seconds until the render is READY, stops on ERROR/REFUNDED, or times out after 40 checks.
- When the video is ready, downloads the MP4, requests a Shopify staged upload target via the Admin GraphQL API, uploads the file to the staged target, and updates the product to attach the video as media.
- If Shopify upload/attach fails, downloads the MP4 and uploads it to Google Drive as a fallback.
- Posts a Slack message indicating whether the video was attached in Shopify, saved to Google Drive, or failed/timed out during rendering.
Setup
- Add a Shopify Access Token credential for a custom app with read_products and write_products (and write_files if required), and set your shop subdomain and Admin API version in the workflow configuration.
- Create a Sisif API key at https://sisif.ai/users/api-keys/ and add it as an HTTP Bearer Auth credential used by the Sisif generate and status requests.
- Add an OpenAI API credential for the chat model used to write the motion prompt.
- Add Google Drive OAuth2 credentials and set the target Drive folder ID for fallback uploads.
- Add Slack credentials and set the destination channel name in the workflow configuration.