Shopify + ReelSDK $0.03 per output minute, first $0.50 free
Product videos for a Shopify catalog
Flow gives up on an HTTP request after 30 s, and nothing you deploy to Shopify runs ffmpeg. ReelSDK renders product videos for $0.03 per output minute: 3 product photos become a 9-second square video with music in about 12 seconds, for $0.0045, ready to attach as product media.
- Product photos in, product video out
- Flow or your app starts it
- A 1,000-product catalog for about $4.50
After Flow sends your HTTP request, it waits for a maximum of 30 seconds for an HTTP response code.
If Flow hasn't received a response after 30 seconds, then it closes the connection to your app.
Later, it retries the request.
Source: Shopify Flow: Send HTTP request
The same job as one call to ReelSDK
curl "https://api.reelsdk.com/v1/slideshow?wait=60" \
-H "Authorization: Bearer $REELSDK_KEY" \
--json '{
"images": [
"https://api.reelsdk.com/f/lib/demo/seville/oranges.jpg",
"https://api.reelsdk.com/f/lib/demo/seville/tapas.jpg",
"https://api.reelsdk.com/f/lib/demo/seville/plaza.jpg"
],
"size": "1080x1080",
"seconds_per_image": 3,
"transition": "fade",
"music": "https://api.reelsdk.com/f/lib/music/chill/calm-currents.mp3"
}'Why ffmpeg breaks here
No server in Shopify, and Flow won't wait
Shopify runs your theme and your Flow workflows, but your app's backend lives with whatever host you deploy it to, so ffmpeg would need a machine there with the binary, the CPU time and a queue. A Flow step that waits for a render is worse: Flow closes the connection after 30 s and sends the request again, which starts a second render of the same product.
So Flow only sends the product id. Your app reads the product's photos through the Admin API, starts a slideshow with ?wait=0 and an Idempotency-Key made from the product id, and answers in about a second. A retry within 24 h gets the same job back. When the video is done, ReelSDK calls your webhook, and productUpdate with a media input adds the mp4 next to the photos. Shopify downloads the file itself, so the 7-day output link only has to last until then.
A 9-second product video costs $0.0045, and a 1,000-product catalog about $4.50. Shopify lets an app add 1,000 videos per store per week, and a ReelSDK key runs 500 jobs a day, so plan a big backfill over a few days. Pricing has the details, and a video made this way is the square format product pages use.
Shopify next to ReelSDK
| Topic | Shopify | ReelSDK |
|---|---|---|
| Running ffmpeg | Nowhere in Shopify, your app's host has to | Slideshows, captions and raw ffmpeg over HTTPS |
| Flow HTTP request | Waits 30 s, then retries | ?wait=0 answers at once with the job id |
| Retries | The same request again | Same Idempotency-Key for 24 h gives the same job |
| Product video | 1 GB, 10 minutes, 3840x2160, 1,000 per store a week | 1080x1080 mp4 for $0.03 per output minute |
| Getting it back | productUpdate media from a URL | Signed webhook with the mp4 link |
Shopify limits from Shopify: manage media for products, checked November 2026.
Set it up
One Flow step and two routes in your app
You need a Shopify app with an Admin API token that has read_products, write_products and write_files, hosted where it can take HTTPS requests. Flow's Send HTTP request needs Shopify Plus, Advanced or Grow; on other plans, call the same route from a products/create webhook or a backfill loop.
Keep the keys on your app's server
The ReelSDK key and webhook secret live in your app host's environment variables, next to the Admin API token. Never put them in a theme, an app block or anything that reaches the storefront.
App environment - REELSDK_KEY
- rsdk_live_...
- REELSDK_WEBHOOK_SECRET
- whsec_...
- SHOPIFY_ADMIN_TOKEN
- shpat_...
- FLOW_TOKEN
- a long random string
- SHOPIFY_STORE
- <store>.myshopify.com
- APP_URL
- https://<your app host>
Send the product from Flow
Trigger: Product created. Action: Send HTTP request, POST to your app's
/flow/product-videowith the headerAuthorization: Bearer {{secrets.flow_token}}and the body{"product_id": "{{product.id}}"}. Flow fills in the product's GID and the route keeps the number at its end. Save the same token as a Flow secret named flow_token.Start the render
The route checks Flow's token, reads up to 10 photos and starts a square slideshow from the first 6. It answers well inside Flow's 30 s.
app/flow/product-video.tsTry it import { timingSafeEqual } from "node:crypto"; const SHOP = process.env.SHOPIFY_STORE!; // your-store.myshopify.com const ADMIN = `https://${SHOP}/admin/api/2026-10/graphql.json`; // Flow sends {"product_id": "{{product.id}}"} with the token from a Flow secret export async function POST(request: Request) { const token = Buffer.from(request.headers.get("authorization") ?? ""); const expected = Buffer.from(`Bearer ${process.env.FLOW_TOKEN}`); if (token.length !== expected.length || !timingSafeEqual(token, expected)) { return new Response("unauthorized", { status: 401 }); } const { product_id } = await request.json(); const id = String(product_id).split("/").pop() ?? ""; if (!/^\d+$/.test(id)) return new Response("unknown product", { status: 400 }); const { data } = await shopify( `query Photos($id: ID!) { product(id: $id) { media(first: 10) { nodes { ... on MediaImage { image { url } } } } } }`, { id: `gid://shopify/Product/${id}` }, ); const nodes = data?.product?.media.nodes ?? []; const images = nodes.map((node) => node.image?.url).filter(Boolean); if (images.length === 0) return Response.json({ skipped: "no photos yet" }); // Flow retries after 30 s, and the same key returns the same job instead of a new render const res = await fetch("https://api.reelsdk.com/v1/slideshow?wait=0", { method: "POST", headers: { Authorization: `Bearer ${process.env.REELSDK_KEY}`, "Content-Type": "application/json", "Idempotency-Key": `product-video-${id}`, }, body: JSON.stringify({ images: images.slice(0, 6), size: "1080x1080", seconds_per_image: 3, transition: "fade", music: "https://api.reelsdk.com/f/lib/music/chill/calm-currents.mp3", webhook_url: `${process.env.APP_URL}/webhooks/reelsdk?product=${id}`, }), }); const created = await res.json(); if (!res.ok) { return new Response(`reelsdk ${res.status}: ${created.error?.message}`, { status: 502 }); } return Response.json({ job: created.job.id }); } export async function shopify(query: string, variables: object) { const res = await fetch(ADMIN, { method: "POST", headers: { "X-Shopify-Access-Token": process.env.SHOPIFY_ADMIN_TOKEN!, "Content-Type": "application/json", }, body: JSON.stringify({ query, variables }), }); if (!res.ok) throw new Error(`Shopify ${res.status}`); return res.json(); }Attach the finished video
The webhook checks the ReelSDK signature before it trusts anything, then adds the mp4 to the product. A 500 makes ReelSDK try again later, up to 6 attempts. Don't use
productSethere: it replaces the product's whole file list.app/webhooks/reelsdk.ts import { createHmac, timingSafeEqual } from "node:crypto"; import { shopify } from "../flow/product-video"; export async function POST(request: Request) { const body = await request.text(); const signature = request.headers.get("reelsdk-signature") ?? ""; if (!verifyReelsdkSignature(signature, body, process.env.REELSDK_WEBHOOK_SECRET!)) { return new Response("invalid signature", { status: 401 }); } const job = JSON.parse(body); const id = new URL(request.url).searchParams.get("product") ?? ""; if (job.status !== "succeeded" || !/^\d+$/.test(id)) return new Response("ok"); // Shopify downloads the mp4 itself and adds it next to the product's photos const { data } = await shopify( `mutation AddVideo($product: ProductUpdateInput!, $media: [CreateMediaInput!]) { productUpdate(product: $product, media: $media) { userErrors { field message } } }`, { product: { id: `gid://shopify/Product/${id}` }, media: [{ originalSource: job.outputs.video, mediaContentType: "VIDEO", alt: "Product video", }], }, ); const errors = data?.productUpdate?.userErrors ?? [{ message: "no response" }]; if (errors.length > 0) { console.error("Shopify refused the video", job.id, errors); return new Response("retry later", { status: 500 }); } return new Response("ok"); } function verifyReelsdkSignature(header: string, body: string, secret: string) { const parts = Object.fromEntries(header.split(",").map((part) => part.split("=", 2))); const age = Math.abs(Date.now() / 1000 - Number(parts.t)); if (!/^[0-9a-f]{64}$/i.test(parts.v1 ?? "") || !(age <= 300)) return false; const expected = createHmac("sha256", secret).update(`${parts.t}.${body}`).digest(); return timingSafeEqual(expected, Buffer.from(parts.v1, "hex")); }
FAQ
Video on Shopify, answered
Can I run ffmpeg inside Shopify?
No. Shopify runs your theme and your Flow workflows, and your app's backend runs on the host you deploy it to. ffmpeg would have to live there. ReelSDK runs the render instead, and your app only sends the photo links.
Why does my Flow workflow render the same product twice?
Flow waits 30 seconds for a response, then closes the connection and retries. If your endpoint waits for a render, the retry starts another one. Answer at once with ?wait=0 and send an Idempotency-Key per product, so a retry within 24 h returns the same job.
How do I add the video to the product without losing the photos?
Use productUpdate with a media input whose originalSource is the mp4 link, and Shopify downloads and adds it. productSet replaces the product's complete list of files, so it would drop anything you leave out.
Can I do the whole catalog at once?
Loop over your products and call the same route for each, 3 at a time. Shopify lets an app create 1,000 videos per store per week and a ReelSDK key runs 500 jobs a day, so a large catalog takes a few days.
What does it cost?
Slideshows cost $0.03 per output minute and music is free, so a 9-second product video is $0.0045 and 1,000 of them about $4.50. The first $0.50 is free and failed jobs cost nothing.
The same fix on other platforms
All integrationsSources, checked November 2026
Ready to build?
Ship video from your app today
Your first $0.50 is free, and one key covers every endpoint.
