Apps Script + ReelSDK $0.30 per short up to 60 s, first $0.50 free

Videos from Google Sheets with Apps Script

One ReelSDK short per sheet row costs $0.30 up to 60 s, with the script, scenes, voice and captions made for you. Apps Script ends every run at 6 minutes and can't start ffmpeg, and a short takes about a minute and a half to render, so the script queues one job per row and a 1-minute trigger collects the videos.

  • One row in, one short out
  • Key in Script Properties
  • Status and video link written back to the row
Apps Script quotas on a consumer account, and the error when a trigger runs out

Script runtime: 6 min / execution

Triggers total runtime: 90 min / day

Service using too much computer time for one day.

Source: Apps Script quotas

The same job as one call to ReelSDK

curl "https://api.reelsdk.com/v1/shorts?wait=300" \
  -H "Authorization: Bearer $REELSDK_KEY" \
  --json '{
    "topic": "Three facts about the Giralda tower in Seville",
    "duration_s": 30,
    "aspect": "9:16",
    "style": "watercolor"
  }'
200 in about a minute and a half: a 30-second 1080x1920 watercolor short with 8 scenes, a title and a post captionTry it

Why ffmpeg breaks here

6 minutes a run and no programs

Apps Script runs your JavaScript on Google's servers with services like UrlFetchApp and SpreadsheetApp, and nothing that starts a program, so ffmpeg is out. Each run ends at 6 minutes, and time-driven triggers share 90 minutes a day on a consumer account and 6 hours on Workspace. A short takes about a minute and a half to render, so a script that waits for each row runs out of time before the fourth.

Webhooks don't fit either. A web app's doPost answers through a redirect to a one-time URL at script.googleusercontent.com, and ReelSDK counts a 3xx as a failed delivery and tries again. So the script polls: queueShorts sends each new row with ?wait=0 and writes the job id, and a trigger every minute asks GET /v1/jobs/{id} about the rows still running, then deletes itself when none are left.

A short costs $0.30 up to 60 s and $0.45 up to 90 s, with the script, images, voice, music and captions included. Failed jobs are free and pricing lists the rest. Watch a Giralda short made this way.

Apps Script next to ReelSDK

Apps Script next to ReelSDK
TopicApps ScriptReelSDK
Running ffmpegNo way to start a programShorts, slideshows, captions and raw ffmpeg over HTTPS
Time per run6 min per execution?wait=0 answers at once with a job id
Daily budget90 min of trigger time, 20,000 fetches on consumer accounts500 jobs a day per key, 3 at once
Getting resultsdoPost replies through a redirectPoll GET /v1/jobs/{id} from a trigger
SecretsScript PropertiesAuthorization: Bearer with that value

Google Apps Script limits from Apps Script quotas, checked November 2026.

Set it up

One sheet, one script, one trigger

You need a Google Sheet with a tab named Shorts and the columns Topic, Status, Job and Video, plus a ReelSDK key. Anyone who can edit the script can read its Script Properties, so keep edit access to people you trust.

  1. Store the key in Script Properties

    Open Extensions, Apps Script, then Project Settings, and add a script property REELSDK_KEY. The code reads it with PropertiesService.getScriptProperties(), so it never sits in the code or the sheet.

    Script property
    Property
    REELSDK_KEY
    Value
    rsdk_live_...
  2. Paste the script and queue the rows

    queueShorts sends rows that have a topic and no status until the key has 3 jobs running, then installs the trigger. Run it once from the editor to grant the spreadsheet, external request and trigger permissions.

    Code.gsTry it
    const API = "https://api.reelsdk.com/v1";
    const SHEET = "Shorts";
    
    function key_() {
      const key = PropertiesService.getScriptProperties().getProperty("REELSDK_KEY");
      if (!key) throw new Error("Add REELSDK_KEY under Project Settings, Script Properties");
      return key;
    }
    
    function reelsdk_(method, path, body) {
      const options = {
        method,
        headers: { Authorization: "Bearer " + key_() },
        muteHttpExceptions: true,
      };
      if (body) {
        options.contentType = "application/json";
        options.payload = JSON.stringify(body);
      }
    
      const res = UrlFetchApp.fetch(API + path, options);
      const data = JSON.parse(res.getContentText());
    
      // A failed job answers 422 or 500 with the job, and a key with 3 jobs running answers 429
      if (data.job) return data.job;
      if (res.getResponseCode() === 429) return null;
      throw new Error(path + ": " + data.error.message);
    }
    
    // Columns: Topic, Status, Job, Video. Rows with a topic and no status get a short
    function queueShorts() {
      const sheet = SpreadsheetApp.getActive().getSheetByName(SHEET);
      const rows = sheet.getDataRange().getValues();
    
      for (let i = 1; i < rows.length; i++) {
        const [topic, status] = rows[i];
        if (!topic || status) continue;
    
        const body = { topic, duration_s: 30, aspect: "9:16", style: "watercolor" };
        const job = reelsdk_("post", "/shorts?wait=0", body);
        if (!job) break;
        sheet.getRange(i + 1, 2, 1, 2).setValues([[job.status, job.id]]);
      }
    
      const triggers = ScriptApp.getProjectTriggers();
      if (!triggers.some((t) => t.getHandlerFunction() === "collectShorts")) {
        ScriptApp.newTrigger("collectShorts").timeBased().everyMinutes(1).create();
      }
    }
    
    function collectShorts() {
      const sheet = SpreadsheetApp.getActive().getSheetByName(SHEET);
      const rows = sheet.getDataRange().getValues();
      let pending = 0;
    
      for (let i = 1; i < rows.length; i++) {
        const [topic, status, id] = rows[i];
        if (topic && !status) pending++;
        if (status !== "queued" && status !== "running") continue;
    
        const job = reelsdk_("get", "/jobs/" + id);
        const video = job.status === "succeeded" ? job.outputs.video : "";
        sheet.getRange(i + 1, 2, 1, 3).setValues([[job.status, id, video]]);
        if (job.status === "queued" || job.status === "running") pending++;
      }
    
      // Rows still waiting for a slot go out now; with nothing left, we stop spending trigger minutes
      if (pending > 0) {
        queueShorts();
      } else {
        for (const t of ScriptApp.getProjectTriggers()) {
          if (t.getHandlerFunction() === "collectShorts") ScriptApp.deleteTrigger(t);
        }
      }
    }
    
  3. Let the trigger collect the videos

    collectShorts runs every minute, fills in the status and the mp4 link, sends waiting rows as slots free up, and removes its own trigger when no row is left to send or collect. Output links last 7 days: to keep a short, fetch it with UrlFetchApp, which takes responses up to 50 MB, and save the blob to Drive.

FAQ

Video on Google Apps Script, answered

Can Apps Script run ffmpeg?

No. Apps Script runs JavaScript on Google's servers with Google's services and UrlFetchApp, and it can't start a program. Send the work to ReelSDK with UrlFetchApp and write the video link back into the sheet.

How do I get around the 6-minute limit?

Don't wait inside the run. Queue each row with ?wait=0, which answers at once with a job id, and let a time-driven trigger check the jobs every minute. Each check takes a moment, so a whole sheet fits in the daily trigger budget.

Why not use a webhook into doPost?

Apps Script answers web app requests through a redirect to script.googleusercontent.com, and ReelSDK treats any 3xx as a failed delivery. Polling from a trigger avoids that, and a webhook works fine if you point it at a server of your own.

Where does the API key go?

In Script Properties, read with PropertiesService.getScriptProperties(). Never in a cell or in the code. Editors of the script can see script properties, so share edit access with care.

What does it cost?

A short is $0.30 up to 60 s and $0.45 up to 90 s, script, images, voice, music and captions included. The first $0.50 is free and failed jobs cost nothing.

All integrations

Ready to build?

Ship video from your app today

Your first $0.50 is free, and one key covers every endpoint.

Moonlit lake with a lit cabin under the mountains