Generate AI videos with OpenAI Sora 2 & upload to Google Drive
Who's it for This template is designed for filmmakers, content creators, social media managers, and AI developers who want to harness OpenAI's Sora 2 for creating physically accurate, cinematic videos with synchronize...
Template notes
Who's it for This template is designed for filmmakers, content creators, social media managers, and AI developers who want to harness OpenAI's Sora 2 for creating physically accurate, cinematic videos with synchronized audio. Whether you're generating realistic scenes from text prompts or reference images with proper physics simulation, creating multi-shot sequences with persistent world state, or producing content with integrated dialogue and sound effects, this workflow streamlines the entire video generation process from prompt to preview and Google Drive upload.
What it does This workflow: Accepts a text prompt, optional reference image, OpenAI API key, and generation settings via form submission Validates reference image format (jpg, png, or webp only) Sends the prompt and optional reference to the Sora 2 API endpoint to request video generation Continuously polls the video rendering status (queued → in progress → completed) Waits 30 seconds between status checks to avoid rate limiting Handles common generation errors with descriptive error messages Automatically fetches the generated video once rendering is complete Downloads the final .mp4 file Uploads the resulting video to your Google Drive Displays the download link and video preview/screenshot upon completion
How to set up
1. Get Your OpenAI API Key
You'll need an OpenAI API key to use this workflow. Here's the general process:
1. Create an OpenAI account at https://platform.openai.com 2. Set up billing - Add payment information to enable API access 3. Generate your API key through the API keys section in your OpenAI dashboard 4. Copy and save your key immediately - you won't be able to view it again!
⚠️ Important: Your API key will start with sk- and should be kept secure. If you lose it, you'll need to generate a new one.
2. Connect Google Drive Add your Google Drive OAuth2 credential to n8n Grant necessary permissions for file uploads