Skip to main content

Overview

Create UGC-style advertising content that looks authentic and engaging - perfect for social media campaigns. UGC Ads combine AI avatars with natural-sounding scripts to create convincing spokesperson videos.

Quick Example

const response = await fetch('https://api.tryhooked.ai/v1/project/create/ugc-ads', {
  method: 'POST',
  headers: {
    'x-api-key': process.env.HOOKED_API_KEY,
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    script: 'Hey everyone! I just got this amazing product and I had to share my experience with you.',
    avatarId: 'avatar_casual_01',
    voiceId: 'enthusiastic_voice_id',
    caption: {
      preset: 'tiktok',
      alignment: 'bottom',
      disabled: false
    },
    adSettings: {
      bRollType: "rounded-cover",
      removeAvatarBackground: true
    },
    aspectRatio: 'ratio_9_16',
    language: 'en',
    webhook: 'https://yoursite.com/webhook',
  })
});

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

Complete Example

const createUGCAd = async () => {
  const response = await fetch('https://api.tryhooked.ai/v1/project/create/ugc-ads', {
    method: 'POST',
    headers: {
      'x-api-key': process.env.HOOKED_API_KEY,
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({
      name: 'UGC Demo',
      script: 'Stop scrolling! I need to tell you about something incredible. I was skeptical at first, but after trying this for just one week... I\'m never going back.',
      avatarId: 'avatar_influencer_01',
      voiceId: 'confident_voice_id',
      musicId: 'trending_music_01',
      caption: {
        preset: 'wrap1',
        alignment: 'top',
        disabled: false
      },
      media: [
        {
          id: 'product_video',
          type: 'video',
          title: 'Product Demo',
          url: 'https://your-cdn.com/demo.mp4',
          durationInFrames: 200,
          isAIGenerated: true
        },
        {
          id: 'product_image',
          type: 'image',
          title: 'Product Shot',
          url: 'https://your-cdn.com/product.jpg',
          durationInFrames: 75,
          isAIGenerated: false
        }
      ],
      adSettings: {
        bRollType: 'rounded-cover',
        removeAvatarBackground: true
      },
      aspectRatio: 'ratio_9_16',
      language: 'en',
      webhook: 'https://yoursite.com/webhook',
      metadata: {
        campaignId: 'q1-campaign',
        abTestVariant: 'B'
      }
    })
  });

  return await response.json();
};

Tips for UGC Ads

Be authentic: Write scripts that sound natural and conversational, not salesy
Hook in 2 seconds: Start with attention-grabbing words like “Stop scrolling!” or “POV:“
Use 9:16 format: Vertical videos perform better on TikTok, Reels, and Shorts
Keep it short: 15-30 seconds works best for social media ads
Add B-roll: Product shots and demos increase engagement and credibility

Effective Script Formulas

FormulaExample
Problem → Solution”I used to struggle with X… then I found this!”
Skeptic → Believer”I didn’t believe the hype, but after trying it…”
Before → After”My mornings used to be chaos. Now look at this!”
Social Proof”Everyone’s been asking about my secret. Here it is!”
Urgency”They’re almost sold out! I had to share before it’s gone”

B-Roll Display Types

TypeBest For
downAvatar on top, product on bottom - great for demos
upProduct on top, avatar on bottom - focus on product
leftAvatar on right, product on left - balanced layout
rightAvatar on left, product on right - balanced layout
rounded-coverRounded avatar overlay - modern look
full-widthB-roll only - when product should be the star

Use Cases

  • Product Reviews: Authentic-looking testimonials
  • Unboxing Videos: Product reveal content
  • Social Media Ads: TikTok, Instagram Reels, Facebook ads
  • Comparison Ads: Side-by-side product comparisons
  • Tutorial Teasers: Quick how-to previews

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('Campaign:', metadata.campaignId);

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

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