Skip to main content

Overview

Create UGC-style videos that look authentic and engaging - perfect for social media content. UGC Videos combine AI avatars with natural-sounding scripts to create realistic spokesperson videos.

Quick Example

const response = await fetch('https://api.tryhooked.ai/v1/project/create/ugc-video', {
  method: 'POST',
  headers: {
    'x-api-key': process.env.HOOKED_API_KEY,
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    script: 'Check out this amazing product! It’s super easy to use and I love the results.',
    avatarId: '2',
    voiceId: 'confident_voice_id'',
    caption: {
      preset: 'wrap1',
      alignment: 'bottom',
      disabled: false
    },
    aspectRatio: 'ratio_9_16',
    language: 'en'
  })
});

const data = await response.json();
console.log('Video ID:', data.data.videoId);
console.log('Project ID:', data.data.projectId);

Complete Example

const createUGCVideo = async () => {
  const response = await fetch('https://api.tryhooked.ai/v1/project/create/ugc-video', {
    method: 'POST',
    headers: {
      'x-api-key': process.env.HOOKED_API_KEY,
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({
      name: 'Welcome Video',
      script: 'Hey there! Thanks for checking out our channel. We create awesome content every week, so make sure to subscribe and hit that notification bell!',
      avatarId: '2',
      voiceId: 'confident_voice_id'',
      caption: {
        preset: 'tiktok',
        alignment: 'bottom',
        disabled: false
      },
      aspectRatio: 'ratio_9_16',
      language: 'en',
      musicId: 'music_upbeat_01',
      webhook: 'https://yoursite.com/webhook',
      metadata: {
        channelId: 'my-channel',
        videoType: 'welcome'
      }
    })
  });

  return await response.json();
};

Tips for UGC Videos

Be authentic: Write scripts that sound natural and conversational, not scripted
Keep it short: 15-60 seconds works best for social media content
Use 9:16 format: Vertical videos perform better on TikTok, Reels, and Shorts
Match voice to avatar: Choose a voice that matches the avatar’s appearance for authenticity
Use webhooks: Always use webhooks in production instead of polling for video status

Effective Script Formulas

FormulaExample
Conversational Greeting”Hey! How’s it going? I wanted to share something cool with you…”
Personal Story”So I tried this yesterday and I was blown away…”
Quick Tip”Quick tip that changed everything for me…”
Testimonial Style”I’ve been using this for a month now and here’s my honest review…”
Friendly Update”Hey everyone! Just wanted to give you a quick update…”

Caption Presets

Available caption presets for the caption.preset field:
PresetDescription
defaultDefault caption style with bold text and shadow effects
beastBold uppercase style with Komika font
umiYellow glowing text style
tiktokViral & trendy style, perfect for social media
wrap1Wrapped style with red background highlight
wrap2Wrapped style with blue background highlight (uppercase)
arielBold uppercase style with purple highlight
hookedBrand style with purple background
classicClean, simple captions with black background (Default)
activeGreen background with bold text
bubbleWhite background bubble style
glassGlassmorphic transparency effect
comicComic Sans font with colorful style
glowPink and orange glow effects
pastelSoft pastel pink background
neonGreen neon glow effect
retroTVRetro TV style with cyan glow
redRed glow effect with white text
markerYellow marker/highlighter style
modernContemporary white background style
blueBlue background style
vividVibrant pink background with uppercase text

Use Cases

  • Testimonials: Authentic-looking customer testimonials
  • Social Media Content: TikTok, Instagram Reels, YouTube Shorts
  • Personal Messages: Video messages for customers or team
  • Quick Updates: Company updates or announcements
  • Educational Content: Quick tips or how-to videos

Handling the Webhook Response

// Express.js webhook handler
app.post('/webhook', (req, res) => {
  const { data, status, message } = req.body;

  if (status === "COMPLETED") {
    const { videoId, status: videoStatus, url, shareUrl, metadata } = data;
    console.log('Video completed!');
    console.log('Video ID:', videoId);
    console.log('Download URL:', url);
    console.log('Share URL:', shareUrl);
    console.log('Channel:', metadata.channelId);

    // Save to your database, notify team, etc.
  }

  res.status(200).send('OK');
});