Skip to main content

Airtable Integration Guide

Turn your Airtable content calendar into a fully automated publishing pipeline. When a record's status flips to Ready, Airtable runs a script that calls IndReelForge and posts to every connected platform — then writes the result back to your base.

Prerequisites​

StepWhat to do
1. Create a profileDashboard → Profiles → New Profile. The profile name is your user field.
2. Connect socialsOpen the profile and click Connect next to each network.
3. Generate an API keyDashboard → API Keys → New Key (2FA required). Store it safely.

FieldTypePurpose
Video NameSingle line textCaption / title for the post
Video URLURLPublic link to the video (S3, Cloudinary, Drive, etc.)
PlatformsMultiple selectOptions: instagram, tiktok, youtube, x, linkedin, facebook, threads, pinterest, reddit, bluesky, google_business
ProfileSingle line textIndReelForge profile name
StatusSingle selectDraft / Ready / Uploaded / Failed
Upload DateDateAuto-filled when posted
Platform URLsLong textJSON written back with per-platform post IDs

Automation Setup​

  1. Open your base and click Automations in the top bar.
  2. Click + New automation.
  3. Trigger → "When a record matches conditions" → Status is Ready.
  4. Action → "Run a script".
  5. Under Input variables, add:
    • recordId → Current record ID
    • apiKey → your IndReelForge API key (paste directly or use a base secret)
    • userProfile → your IndReelForge profile name

Automation Script​

Paste this into the script editor:

const { recordId, apiKey, userProfile } = input.config();

const table = base.getTable('Videos');
const record = await table.selectRecordAsync(recordId);

const videoUrl = record.getCellValue('Video URL');
const title = record.getCellValue('Video Name');
const platforms = (record.getCellValue('Platforms') || []).map(p => p.name);

// Build multipart form data
const form = new FormData();
form.append('video_url', typeof videoUrl === 'string' ? videoUrl : videoUrl[0].url);
form.append('user', userProfile);
form.append('title', title);
platforms.forEach(p => form.append('platform[]', p));

// Call IndReelForge
const res = await fetch('https://api.indreelforge.com/api/upload', {
method: 'POST',
headers: { Authorization: `Apikey ${apiKey}` },
body: form,
});

const data = await res.json();

// Write result back to Airtable
await table.updateRecordAsync(record, {
Status: data.success ? { name: 'Uploaded' } : { name: 'Failed' },
'Upload Date': new Date(),
'Platform URLs': JSON.stringify(data.platform_statuses || {}, null, 2),
});

output.set('success', data.success);
output.set('upload_id', data.upload_id || '');

Text-Only Posts​

Change the endpoint to /api/upload_text and omit the video fields:

const form = new FormData();
form.append('title', title);
form.append('user', userProfile);
platforms.forEach(p => form.append('platform[]', p));

const res = await fetch('https://api.indreelforge.com/api/upload_text', {
method: 'POST',
headers: { Authorization: `Apikey ${apiKey}` },
body: form,
});

Use /api/upload_photos and append multiple image URLs:

const images = record.getCellValue('Images'); // Attachment field
const form = new FormData();
form.append('user', userProfile);
form.append('title', title);
images.forEach(img => form.append('image_url[]', img.url));
platforms.forEach(p => form.append('platform[]', p));

await fetch('https://api.indreelforge.com/api/upload_photos', {
method: 'POST',
headers: { Authorization: `Apikey ${apiKey}` },
body: form,
});

Auto-Schedule with Queue​

Add add_to_queue=true to let IndReelForge pick the next optimal time slot:

form.append('add_to_queue', 'true');

Configure time slots per profile in Dashboard → Profiles → Queue Settings.


Tips​

TopicDetail
API key securityUse Airtable's Secrets feature (Automations → Secrets) rather than hardcoding the key in the script
Multiple select → string arraygetCellValue('Platforms') returns [{id, name}] objects — always .map(p => p.name)
Attachment fieldsVideo and image attachment cells return arrays; use [0].url for the first item
Rate limitingAdd a Wait step between runs if you automate bulk publishing
Error visibilityWrite data.error back to a Notes field so failures are visible in the base