<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: useapi.net</title>
    <description>The latest articles on DEV Community by useapi.net (@useapi).</description>
    <link>https://dev.to/useapi</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1161316%2Ffeb14d20-dbec-4923-bdaa-dca61f4e5527.png</url>
      <title>DEV Community: useapi.net</title>
      <link>https://dev.to/useapi</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/useapi"/>
    <language>en</language>
    <item>
      <title>How to Make an AI Music Video from a Song with the PixVerse API</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Wed, 11 Nov 2026 19:58:30 +0000</pubDate>
      <link>https://dev.to/useapi/how-to-make-an-ai-music-video-from-a-song-with-the-pixverse-api-14f9</link>
      <guid>https://dev.to/useapi/how-to-make-an-ai-music-video-from-a-song-with-the-pixverse-api-14f9</guid>
      <description>&lt;h3&gt;
  
  
  Introduction
&lt;/h3&gt;

&lt;p&gt;The useapi.net &lt;a href="https://useapi.net/docs/api-pixverse-v2" rel="noopener noreferrer"&gt;PixVerse API&lt;/a&gt; turns a song and one character photo into a finished, lip-synced AI music video with a single REST call, &lt;a href="https://useapi.net/docs/api-pixverse-v2/post-pixverse-music-video-create" rel="noopener noreferrer"&gt;POST music-video/create&lt;/a&gt;, using &lt;a href="https://pixverse.ai" rel="noopener noreferrer"&gt;PixVerse&lt;/a&gt;'s One-Click MV engine on the PixVerse subscription you already pay for. The first music video on every PixVerse account is free, at any length and in 1080p, even on a free Basic plan, which otherwise makes video only up to 540p. After that a minute of song costs $2.40 on Premium at 720p, against $4.00 on PixVerse's own developer API (as of November 2026).&lt;/p&gt;

&lt;p&gt;To show what it does, we made a whole music video from scratch, all through useapi.net: an original song with the &lt;a href="https://useapi.net/docs/api-flowmusic-v1" rel="noopener noreferrer"&gt;Flow Music API&lt;/a&gt;, a dancer with &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-images" rel="noopener noreferrer"&gt;Nano Banana 2.1&lt;/a&gt; on the &lt;a href="https://useapi.net/docs/api-google-flow-v1" rel="noopener noreferrer"&gt;Google Flow API&lt;/a&gt;, then the full 2½-minute video at 1080p. This page has every prompt, every request, the timings, the prices and the results. useapi.net is a &lt;a href="https://useapi.net/docs/legal#affiliation--third-party-services" rel="noopener noreferrer"&gt;third-party&lt;/a&gt; API, not affiliated with PixVerse or Google.&lt;/p&gt;

&lt;h3&gt;
  
  
  Pricing
&lt;/h3&gt;

&lt;p&gt;One minute of song costs (PixVerse bills every second, rounded to the nearest second):&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Mode and quality&lt;/th&gt;
&lt;th&gt;&lt;a href="https://docs.platform.pixverse.ai/one-click-vibemv-44144151e0" rel="noopener noreferrer"&gt;Official API&lt;/a&gt;&lt;/th&gt;
&lt;th&gt;Premium $60/mo&lt;br&gt;&lt;small&gt;15,000 cr/mo&lt;/small&gt;
&lt;/th&gt;
&lt;th&gt;Pro $30/mo&lt;br&gt;&lt;small&gt;6,000 cr/mo&lt;/small&gt;
&lt;/th&gt;
&lt;th&gt;Ultra $199/mo&lt;br&gt;&lt;small&gt;25,000 cr/mo&lt;/small&gt;
&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;performance&lt;/code&gt; or &lt;code&gt;expressive&lt;/code&gt;, 720p&lt;/td&gt;
&lt;td&gt;$4.00&lt;br&gt;&lt;small&gt;15 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$2.40&lt;br&gt;&lt;small&gt;10 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$3.00&lt;br&gt;&lt;small&gt;10 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$4.78&lt;br&gt;&lt;small&gt;10 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;performance&lt;/code&gt; or &lt;code&gt;expressive&lt;/code&gt;, 1080p&lt;/td&gt;
&lt;td&gt;$6.00&lt;br&gt;&lt;small&gt;22.5 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$3.60&lt;br&gt;&lt;small&gt;15 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$4.50&lt;br&gt;&lt;small&gt;15 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$7.16&lt;br&gt;&lt;small&gt;15 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;storytelling&lt;/code&gt;, 720p&lt;/td&gt;
&lt;td&gt;not sold&lt;/td&gt;
&lt;td&gt;$4.80&lt;br&gt;&lt;small&gt;20 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$6.00&lt;br&gt;&lt;small&gt;20 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$9.55&lt;br&gt;&lt;small&gt;20 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;storytelling&lt;/code&gt;, 1080p&lt;/td&gt;
&lt;td&gt;not sold&lt;/td&gt;
&lt;td&gt;$9.60&lt;br&gt;&lt;small&gt;40 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$12.00&lt;br&gt;&lt;small&gt;40 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$19.10&lt;br&gt;&lt;small&gt;40 cr/s&lt;/small&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The first music video on every PixVerse account is free, at any length and in 1080p, even on a free Basic plan. Prices as of November 2026.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Our 2½-minute 1080p video below was the free one of a Basic account. On Premium it would have cost $9.12.&lt;/li&gt;
&lt;li&gt;PixVerse's developer API has one music video workflow and no &lt;code&gt;expressive&lt;/code&gt; or &lt;code&gt;storytelling&lt;/code&gt; mode, which the PixVerse website and this API both offer.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Start using the API
&lt;/h3&gt;

&lt;p&gt;A single $15/month subscription covers every API on useapi.net — one token, all services. You connect up to 3 accounts per service, each with its own website subscription, and useapi.net handles the REST API, load balancing, and polling. Need more accounts? Each extra subscription is $10/month and adds 3 more accounts per service.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://buy.stripe.com/8x2aEX4Bd8Vh9PMg4qeUU03" rel="noopener noreferrer"&gt;Subscribe — $15/month&lt;/a&gt; &lt;a href="https://pay.boomfi.xyz/38UTma36Rv0DrY8NlH1r2SEG7VK" rel="noopener noreferrer"&gt;Pay with crypto&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;Pricing and volume options&lt;/a&gt; — full refund within the first 14 days if you have fewer than 50 successful generations. Already subscribed? Change the quantity in the &lt;a href="https://billing.stripe.com/p/login/28obM4fZld0JaHu6oo" rel="noopener noreferrer"&gt;Stripe Customer Portal&lt;/a&gt; instead of buying again.&lt;/p&gt;

&lt;h3&gt;
  
  
  Example: a 2½-minute AI music video made from one song on a free account
&lt;/h3&gt;

&lt;p&gt;A 2½-minute song at 1080p in &lt;code&gt;performance&lt;/code&gt; mode with lyric captions, made on a free PixVerse account at no cost (normally 2,280 credits). It took 15 minutes 44 seconds:&lt;/p&gt;



&lt;p&gt;PixVerse planned 17 shots from the song, kept the dancer from our photo in almost every one of them (afro, black sunglasses, tied-up white shirt, blue cycling shorts), lip-synced her to the vocals, built bright retro sets with floating cubes, music notes and a gramophone, and timed the captions to the sung words. Nobody edited anything.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 1. Write the song with Flow Music
&lt;/h3&gt;

&lt;p&gt;The &lt;a href="https://useapi.net/docs/api-flowmusic-v1" rel="noopener noreferrer"&gt;Flow Music API&lt;/a&gt; generates a complete song from a style prompt and your lyrics on Google's Lyria models. We wanted a hard, minimal party rap with chants and stop-and-drop breaks, so the prompt spells out the beat, the voice and the structure:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl --location &lt;span class="s1"&gt;'https://api.useapi.net/v1/flowmusic/music'&lt;/span&gt; \
--header &lt;span class="s1"&gt;'Authorization: Bearer user:12345-…'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'model="lyria-3.5"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'prompt="1990 pop-rap dance hit, 133 BPM, hard minimal drum machine beat with booming 808 kick and big gated hand claps, one repeating staccato funk bass-and-synth riff in the style of an early-80s funk sample looped through the whole song, sparse arrangement, confident sassy female MC with a strong low voice chanting short rhythmic lines on the beat, punchy shouted hooks, mixed gang vocal chants answering oh-oh oh-oh-oh, hard stops where the whole beat cuts out for a shouted line then slams back in, party dance floor energy, classic 1990 MTV rap anthem sound"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'lyrics="[Verse 1]
Ooh, that bassline hits me so hard
Makes me jump up off the boulevard
…
[Verse 2]
Step to the left, now step to the right
Spin on the floor till the morning light
…"'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;One request returns two takes in about a minute. We kept the first one, about 2½ minutes long. Lyria rewrote part of our lyrics while it sang and named the song "Can't Stop This", which is why the captions use the lyrics it returned, not the ones we sent:&lt;/p&gt;

&lt;p&gt;🎧 &lt;a href="https://useapi.net/docs/articles/pixverse-music-video-api#step-1-write-the-song-with-flow-music" rel="noopener noreferrer"&gt;Play on useapi.net&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Getting here took four tries. A synth-pop song with clear vocals came out too sweet, a generic pop-rap prompt came out bland, and a male MC voice didn't fit a female dancer. Spelling out the minimal 808 beat, the looped funk riff, the chanted delivery and the hard stops is what got the sound.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 2. Make the dancer with Nano Banana 2.1
&lt;/h3&gt;

&lt;p&gt;The character photo decides who performs. PixVerse keeps the face, hair and outfit from it in almost every shot, so the photo needs a full body, a clearly visible face and a look that tells the story. We made it with Nano Banana 2.1 (&lt;code&gt;nano-banana-2&lt;/code&gt; on the &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-images" rel="noopener noreferrer"&gt;Google Flow API&lt;/a&gt;), two images per request at 9:16:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl --location &lt;span class="s1"&gt;'https://api.useapi.net/v1/google-flow/images'&lt;/span&gt; \
--header &lt;span class="s1"&gt;'Authorization: Bearer user:12345-…'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'model="nano-banana-2"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'aspectRatio="9:16"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'count="2"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'prompt="Still frame from a 1990 rap music video shot on 35mm film: a sexy, athletic, fit young woman rapper dancing in the sunny parking lot outside the Oakland Coliseum, clear blue sky, a boombox at her feet, dancers clapping behind her. Her look: black sunglasses, a white cropped jacket tied up at the front over a toned stomach, tight royal blue cycling shorts, gold chains, gold hoop earrings, white high-tops, voluminous curls. Rapping mid-line with lips clearly visible, full body in frame, face toward the camera, warm film colors, sharp focus"'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Fpixverse%2F2026-11-10-music-video-article%2Fnano-banana-2-1-character-oakland-coliseum-dancer.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Fpixverse%2F2026-11-10-music-video-article%2Fnano-banana-2-1-character-oakland-coliseum-dancer.jpg" alt="Nano Banana 2.1 character: a dancer in a tied-up white shirt and blue cycling shorts outside the Oakland Coliseum" width="768" height="1376"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Our first dancers looked like stock photos. What made the difference was describing the picture as a still from an old music video shot on film, naming a real place and period clothes, and asking for the lips to be visible for lip-sync.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 3. Upload the song and the photo
&lt;/h3&gt;

&lt;p&gt;Upload both files to your PixVerse account with &lt;a href="https://useapi.net/docs/api-pixverse-v2/post-pixverse-files" rel="noopener noreferrer"&gt;POST files&lt;/a&gt; and keep the &lt;code&gt;path&lt;/code&gt; of each. Upload the song as MP3: PixVerse refused an M4A file in our tests. With several PixVerse accounts connected, add &lt;code&gt;?email=&lt;/code&gt; to the upload and &lt;code&gt;email&lt;/code&gt; to the requests below to pick one, for example the account whose free music video you want to use.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl --location &lt;span class="s1"&gt;'https://api.useapi.net/v2/pixverse/files/'&lt;/span&gt; \
--header &lt;span class="s1"&gt;'Authorization: Bearer user:12345-…'&lt;/span&gt; \
--header &lt;span class="s1"&gt;'Content-Type: audio/mpeg'&lt;/span&gt; \
--data-binary &lt;span class="s1"&gt;'@cant-stop-this.mp3'&lt;/span&gt;
&lt;span class="c"&gt;# {"path": "upload/8aa34c5f-7f33-4fdc-af40-7357909102cb.mp3", "duration": 151.968, …}&lt;/span&gt;

curl --location &lt;span class="s1"&gt;'https://api.useapi.net/v2/pixverse/files/'&lt;/span&gt; \
--header &lt;span class="s1"&gt;'Authorization: Bearer user:12345-…'&lt;/span&gt; \
--header &lt;span class="s1"&gt;'Content-Type: image/jpeg'&lt;/span&gt; \
--data-binary &lt;span class="s1"&gt;'@dancer.jpg'&lt;/span&gt;
&lt;span class="c"&gt;# {"result": [{"path": "upload/66952750-badc-473b-b2a2-721197e96e7d.jpeg", …}]}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 4. Check the price, then make the video
&lt;/h3&gt;

&lt;p&gt;Every request can be quoted first, for free. &lt;code&gt;quote: true&lt;/code&gt; returns the exact price and creates nothing:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl --location &lt;span class="s1"&gt;'https://api.useapi.net/v2/pixverse/music-video/create'&lt;/span&gt; \
--header &lt;span class="s1"&gt;'Authorization: Bearer user:12345-…'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'audio_path="upload/8aa34c5f-7f33-4fdc-af40-7357909102cb.mp3"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'image_path="upload/66952750-badc-473b-b2a2-721197e96e7d.jpeg"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'mode="performance"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'music_genre="hip_hop"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'subtitles="true"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'aspect_ratio="16:9"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'quality="1080p"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'quote="true"'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"quote"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"mode"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"performance"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"quality"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"1080p"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"bill_seconds"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;152&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"credits_per_second"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;15&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"list_cost_credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2280&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"cost_credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"free"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"has_enough_credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;cost_credits: 0&lt;/code&gt; and &lt;code&gt;free: true&lt;/code&gt; mean the account's free music video applies. Drop &lt;code&gt;quote&lt;/code&gt; and add the lyrics, one line per caption, to make it. curl reads a multi-line field from a file with &lt;code&gt;&amp;lt;&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl --location &lt;span class="s1"&gt;'https://api.useapi.net/v2/pixverse/music-video/create'&lt;/span&gt; \
--header &lt;span class="s1"&gt;'Authorization: Bearer user:12345-…'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'audio_path="upload/8aa34c5f-7f33-4fdc-af40-7357909102cb.mp3"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'image_path="upload/66952750-badc-473b-b2a2-721197e96e7d.jpeg"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'mode="performance"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'music_genre="hip_hop"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'subtitles="true"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'lyrics=&amp;lt;lyrics.txt'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'aspect_ratio="16:9"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'quality="1080p"'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The answer carries the &lt;code&gt;video_id&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"video_id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-pixverse:you@example.com-video:642767619916505"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"project_id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;192080023076656&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"mode"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"performance"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"quality"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"1080p"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"aspect_ratio"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"16:9"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"bill_seconds"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;152&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"credits_per_second"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;15&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"list_cost_credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2280&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"cost_credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"free"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 5. Wait for it and download it
&lt;/h3&gt;

&lt;p&gt;Poll &lt;a href="https://useapi.net/docs/api-pixverse-v2/get-pixverse-music-video-video_id" rel="noopener noreferrer"&gt;GET music-video/&lt;code&gt;video_id&lt;/code&gt;&lt;/a&gt; until &lt;code&gt;status&lt;/code&gt; is &lt;code&gt;succeeded&lt;/code&gt; or &lt;code&gt;failed&lt;/code&gt;, or pass a &lt;code&gt;replyUrl&lt;/code&gt; with the create request and get the result by callback. A 30-second song took about 5 minutes to render, the 2½-minute song about 16 minutes. Save this as &lt;a href="https://github.com/useapi/pixverse-api/blob/main/music-video/poll.mjs" rel="noopener noreferrer"&gt;&lt;code&gt;poll.mjs&lt;/code&gt;&lt;/a&gt; and run it with &lt;code&gt;node poll.mjs&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;token&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;process&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="no"&gt;USEAPI_TOKEN&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;video_id&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-pixverse:you@example.com-video:642767619916505"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;res&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nb"&gt;fetch&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sb"&gt;`https://api.useapi.net/v2/pixverse/music-video/${video_id}`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="n"&gt;headers&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nc"&gt;Authorization&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sb"&gt;`Bearer ${token}`&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;mv&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;res&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nb"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;mv&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;status&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;mv&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;status&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="s2"&gt;"succeeded"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nb"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;mv&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;video&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;url&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;mv&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;files&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="k"&gt;break&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;mv&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;status&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="s2"&gt;"failed"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nb"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;mv&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;error&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="k"&gt;break&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nb"&gt;Promise&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;r&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;setTimeout&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;r&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;20000&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;video.url&lt;/code&gt; is the finished mp4. &lt;code&gt;files&lt;/code&gt; holds the extras: the same video without captions, the timed lyrics as an &lt;code&gt;.ass&lt;/code&gt; subtitle file (for a song with vocals), and the key images and clips PixVerse cut together. For our song that was 17 images and 17 clips, handy if you want to re-edit it yourself. PixVerse's media server refuses downloads that don't send a browser-like &lt;code&gt;User-Agent&lt;/code&gt;, so set one if a script gets &lt;code&gt;403&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;A runnable version of these steps, for a whole list of songs at once, is the &lt;a href="https://github.com/useapi/pixverse-api/tree/main/music-video" rel="noopener noreferrer"&gt;&lt;code&gt;music-video/&lt;/code&gt; example&lt;/a&gt; on GitHub: it quotes each job for free, makes the videos and downloads them with every extra file.&lt;/p&gt;

&lt;h3&gt;
  
  
  More examples
&lt;/h3&gt;

&lt;p&gt;Three shorter videos from the same tests, each with a different mode or style.&lt;/p&gt;

&lt;h4&gt;
  
  
  Performance, &lt;code&gt;auto&lt;/code&gt; style, 9:16 at 720p
&lt;/h4&gt;

&lt;p&gt;A 30-second song clip and a Nano Banana 2.1 dancer on a neon street at night. With &lt;code&gt;style: auto&lt;/code&gt; PixVerse chose its own set, a plush retro lounge with chandeliers, disco balls and backup dancers. 300 credits, 5 minutes 21 seconds.&lt;/p&gt;

&lt;p&gt;The song and the character that went in:&lt;/p&gt;

&lt;p&gt;🎧 &lt;a href="https://useapi.net/docs/articles/pixverse-music-video-api#performance-auto-style-916-at-720p" rel="noopener noreferrer"&gt;Play on useapi.net&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Fpixverse%2F2026-11-10-music-video-article%2Fnano-banana-2-1-character-neon-street-dancer.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Fpixverse%2F2026-11-10-music-video-article%2Fnano-banana-2-1-character-neon-street-dancer.jpg" alt="Nano Banana 2.1 character: a dancer in a black jacket on a neon street at night" width="768" height="1376"&gt;&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl --location &lt;span class="s1"&gt;'https://api.useapi.net/v2/pixverse/music-video/create'&lt;/span&gt; \
--header &lt;span class="s1"&gt;'Authorization: Bearer user:12345-…'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'audio_path="upload/881729de-53f0-47bd-8e46-d2c93a8a751f.mp3"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'image_path="upload/51b3b775-5f85-4016-a946-4de6ba35c042.jpeg"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'mode="performance"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'style="auto"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'aspect_ratio="9:16"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'quality="720p"'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The music video that came out:&lt;/p&gt;



&lt;h4&gt;
  
  
  Expressive, &lt;code&gt;custom&lt;/code&gt; style, 16:9 at 1080p
&lt;/h4&gt;

&lt;p&gt;A 21-second song clip and a black-and-white Nano Banana 2.1 studio portrait of a dancer in a fedora and blazer. &lt;code&gt;style: custom&lt;/code&gt; with no separate style image uses the character photo as the style, so the whole video stays black and white. 315 credits, 5 minutes 22 seconds.&lt;/p&gt;

&lt;p&gt;The song and the character that went in:&lt;/p&gt;

&lt;p&gt;🎧 &lt;a href="https://useapi.net/docs/articles/pixverse-music-video-api#expressive-custom-style-169-at-1080p" rel="noopener noreferrer"&gt;Play on useapi.net&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Fpixverse%2F2026-11-10-music-video-article%2Fnano-banana-2-1-character-black-white-dancer.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Fpixverse%2F2026-11-10-music-video-article%2Fnano-banana-2-1-character-black-white-dancer.jpg" alt="Nano Banana 2.1 character: a black-and-white photo of a dancer in a fedora, white shirt and blazer" width="768" height="1376"&gt;&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl --location &lt;span class="s1"&gt;'https://api.useapi.net/v2/pixverse/music-video/create'&lt;/span&gt; \
--header &lt;span class="s1"&gt;'Authorization: Bearer user:12345-…'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'audio_path="upload/90f95193-2c91-4a42-a506-930d4c964c45.mp3"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'image_path="upload/ff4265e2-bdd5-490a-83bb-f77a34d2761b.jpeg"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'mode="expressive"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'style="custom"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'aspect_ratio="16:9"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'quality="1080p"'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The music video that came out:&lt;/p&gt;



&lt;h4&gt;
  
  
  Performance on an instrumental, 9:16 at 720p
&lt;/h4&gt;

&lt;p&gt;A 10-second instrumental beat from Flow Music and the same dancer as the main video. With no vocals there is nothing to lip-sync, so PixVerse makes a dance video on a sunny Mediterranean street. 100 credits, 3 minutes 13 seconds.&lt;/p&gt;

&lt;p&gt;The beat that went in:&lt;/p&gt;

&lt;p&gt;🎧 &lt;a href="https://useapi.net/docs/articles/pixverse-music-video-api#performance-on-an-instrumental-916-at-720p" rel="noopener noreferrer"&gt;Play on useapi.net&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl --location &lt;span class="s1"&gt;'https://api.useapi.net/v2/pixverse/music-video/create'&lt;/span&gt; \
--header &lt;span class="s1"&gt;'Authorization: Bearer user:12345-…'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'audio_path="upload/23f6fdc4-8882-4b65-a70e-7a1a8b9c9761.mp3"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'image_path="upload/66952750-badc-473b-b2a2-721197e96e7d.jpeg"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'mode="performance"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'style="auto"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'aspect_ratio="9:16"'&lt;/span&gt; \
--form &lt;span class="s1"&gt;'quality="720p"'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The music video that came out:&lt;/p&gt;



&lt;h3&gt;
  
  
  Modes and styles
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Mode&lt;/th&gt;
&lt;th&gt;What it makes&lt;/th&gt;
&lt;th&gt;Styles&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;performance&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;the character sings the song with lip-sync&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;auto&lt;/code&gt;, &lt;code&gt;custom&lt;/code&gt; and 16 looks such as &lt;code&gt;cinematic&lt;/code&gt;, &lt;code&gt;underground&lt;/code&gt;, &lt;code&gt;lo_fi&lt;/code&gt;, &lt;code&gt;claymation&lt;/code&gt;, &lt;code&gt;retro_game&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;expressive&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;emotional, atmospheric shots of the character&lt;/td&gt;
&lt;td&gt;the same 18&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;storytelling&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;a storyline from your &lt;code&gt;prompt&lt;/code&gt;, one or two characters&lt;/td&gt;
&lt;td&gt;18 of its own, such as &lt;code&gt;photorealistic&lt;/code&gt;, &lt;code&gt;anime&lt;/code&gt;, &lt;code&gt;cyberpunk&lt;/code&gt;, &lt;code&gt;ghibli&lt;/code&gt;, &lt;code&gt;lego_blocks&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The full lists, lyric captions, aspect ratios and the built-in &lt;a href="https://useapi.net/docs/api-pixverse-v2/get-pixverse-music-video-library" rel="noopener noreferrer"&gt;library&lt;/a&gt; of 13 songs, 15 characters and 28 style images are on the &lt;a href="https://useapi.net/docs/api-pixverse-v2/post-pixverse-music-video-create" rel="noopener noreferrer"&gt;endpoint page&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Questions
&lt;/h3&gt;

&lt;h4&gt;
  
  
  Is there a PixVerse music video API?
&lt;/h4&gt;

&lt;p&gt;Yes. useapi.net's &lt;a href="https://useapi.net/docs/api-pixverse-v2" rel="noopener noreferrer"&gt;PixVerse API&lt;/a&gt; makes music videos from your song on your PixVerse subscription, in all three modes of PixVerse's One-Click MV. On Premium a minute of song at 720p costs $2.40, against $4.00 on PixVerse's own developer API, which has no expressive or storytelling mode (as of November 2026).&lt;/p&gt;

&lt;h4&gt;
  
  
  Can I make an AI music video for free?
&lt;/h4&gt;

&lt;p&gt;Yes. Through useapi.net the first music video on any PixVerse account, even a free Basic one, costs nothing at any length (ours ran 2½ minutes), in any mode and at 1080p, and a &lt;code&gt;quote&lt;/code&gt; shows &lt;code&gt;free: true&lt;/code&gt; while it is unused. On PixVerse's own developer API the same 2½-minute 1080p video would cost $15.20 (22.5 credits a second at 225 credits per dollar, as of November 2026).&lt;/p&gt;

&lt;h4&gt;
  
  
  Can an API lip-sync a singer to my song?
&lt;/h4&gt;

&lt;p&gt;Yes. In &lt;code&gt;performance&lt;/code&gt; mode the useapi.net PixVerse API lip-syncs the character from your photo to the song's vocals, with no separate lip-sync step, as in our video above. Use a full-body photo with the face and lips clearly visible. At 1080p it costs $3.60 a minute on Premium, against $6.00 on PixVerse's own developer API (as of November 2026).&lt;/p&gt;

&lt;h4&gt;
  
  
  Do I need lyrics to get captions?
&lt;/h4&gt;

&lt;p&gt;No. Through useapi.net, &lt;code&gt;subtitles: true&lt;/code&gt; alone makes PixVerse transcribe the vocals and time the captions, and &lt;code&gt;lyrics&lt;/code&gt;, one line per caption, fixes the spelling. Every video also comes with a copy without captions, and a song with vocals also gets the &lt;code&gt;.ass&lt;/code&gt; subtitle file. Captions work in &lt;code&gt;expressive&lt;/code&gt; mode too, which PixVerse's developer API doesn't offer (as of November 2026).&lt;/p&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;A song, a photo and one API call make a finished music video, and with Flow Music and the Google Flow API the song and the photo can come from the same useapi.net subscription. Start with the free music video on your PixVerse account, then see &lt;a href="https://useapi.net/docs/api-pixverse-v2/post-pixverse-music-video-create" rel="noopener noreferrer"&gt;POST music-video/create&lt;/a&gt; for every option.&lt;/p&gt;

&lt;p&gt;Visit our &lt;a href="https://discord.gg/w28uK3cnmF" rel="noopener noreferrer"&gt;Discord Server&lt;/a&gt; or &lt;a href="https://t.me/use_api" rel="noopener noreferrer"&gt;Telegram Channel&lt;/a&gt; for any support questions and concerns.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>api</category>
      <category>video</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>Can You Use Your Google AI Subscription Through an API? What Plus, Pro and Ultra Get You</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Sat, 07 Nov 2026 23:26:23 +0000</pubDate>
      <link>https://dev.to/useapi/can-you-use-your-google-ai-subscription-through-an-api-what-plus-pro-and-ultra-get-you-1lll</link>
      <guid>https://dev.to/useapi/can-you-use-your-google-ai-subscription-through-an-api-what-plus-pro-and-ultra-get-you-1lll</guid>
      <description>&lt;h3&gt;
  
  
  The short answer
&lt;/h3&gt;

&lt;p&gt;Yes, through useapi.net. Your &lt;a href="https://gemini.google/subscriptions/" rel="noopener noreferrer"&gt;Google AI plan&lt;/a&gt; (Plus, Pro or Ultra) comes with monthly allowances for Google's creative tools. useapi.net turns each one into an API:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-google-flow-v1" rel="noopener noreferrer"&gt;Google Flow API&lt;/a&gt;: videos from your Flow credits, and images that use none&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-google-vids-v1" rel="noopener noreferrer"&gt;Google Vids API&lt;/a&gt;: videos, talking avatars and speech from your Vids seconds&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1" rel="noopener noreferrer"&gt;Gemini Notebook API (NotebookLM API)&lt;/a&gt;: podcasts, slides and research from your Notebook usage&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-flowmusic-v1" rel="noopener noreferrer"&gt;Flow Music API&lt;/a&gt;: songs from the Flow Music credits your plan includes&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;On Ultra $199.99, a month of it is worth about $3,919 on Google's own APIs (as of November 2026).&lt;/p&gt;

&lt;p&gt;The Gemini API itself isn't part of the plan. Google bills it separately, per second of video and per image. Pro and Ultra include a small monthly &lt;a href="https://developers.google.com/program/plans-and-pricing" rel="noopener noreferrer"&gt;Google Cloud credit&lt;/a&gt; for it: $10 on Pro, $40 on Ultra $99.99 and $100 on Ultra $199.99. Even $100 buys only about 96 fifteen-second Omni 1.2 Flash videos there.&lt;/p&gt;

&lt;h3&gt;
  
  
  Everything one plan makes in a month
&lt;/h3&gt;

&lt;p&gt;What a single Google AI plan adds up to through useapi.net each month, and what the same output would cost on Google's own APIs (as of November 2026).&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;One month&lt;/th&gt;
&lt;th&gt;Ultra $199.99&lt;/th&gt;
&lt;th&gt;Ultra $99.99&lt;/th&gt;
&lt;th&gt;Pro $19.99&lt;/th&gt;
&lt;th&gt;Plus $4.99&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;strong&gt;Google Flow&lt;/strong&gt;&lt;br&gt;&lt;small&gt;one pool of credits, pick one row&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;25,000 cr&lt;/td&gt;
&lt;td&gt;10,000 cr&lt;/td&gt;
&lt;td&gt;1,000 cr&lt;/td&gt;
&lt;td&gt;200 cr&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Veo 3.1 Fast videos&lt;br&gt;&lt;small&gt;8 s, 1080p&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;2,500&lt;/td&gt;
&lt;td&gt;1,000&lt;/td&gt;
&lt;td&gt;50&lt;/td&gt;
&lt;td&gt;10&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;or Veo 3.1 Lite videos&lt;br&gt;&lt;small&gt;8 s, 1080p&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;5,000&lt;/td&gt;
&lt;td&gt;2,000&lt;/td&gt;
&lt;td&gt;100&lt;/td&gt;
&lt;td&gt;20&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;or Omni 1.1 Flash videos&lt;br&gt;&lt;small&gt;10 s, 1080p&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;1,666&lt;/td&gt;
&lt;td&gt;666&lt;/td&gt;
&lt;td&gt;66&lt;/td&gt;
&lt;td&gt;13&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;or Omni 1.2 Flash videos&lt;br&gt;&lt;small&gt;10 s, 1080p, free upscale&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;833&lt;/td&gt;
&lt;td&gt;333&lt;/td&gt;
&lt;td&gt;33&lt;/td&gt;
&lt;td&gt;6&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;or Omni 1.2 Flash videos&lt;br&gt;&lt;small&gt;15 s, 720p&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;416&lt;/td&gt;
&lt;td&gt;166&lt;/td&gt;
&lt;td&gt;16&lt;/td&gt;
&lt;td&gt;3&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;or 4K video upscales&lt;br&gt;&lt;small&gt;clips up to 10 s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;500&lt;/td&gt;
&lt;td&gt;200&lt;/td&gt;
&lt;td&gt;—&lt;/td&gt;
&lt;td&gt;—&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;strong&gt;Google Flow, no credits&lt;/strong&gt;&lt;br&gt;&lt;small&gt;on top of the pool&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Veo 3.1 Lite videos&lt;br&gt;&lt;small&gt;lower priority, 8 s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;1,000+ a day&lt;/td&gt;
&lt;td&gt;—&lt;/td&gt;
&lt;td&gt;—&lt;/td&gt;
&lt;td&gt;—&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Video upscales to 1080p&lt;br&gt;&lt;small&gt;clips up to 10 s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;free&lt;/td&gt;
&lt;td&gt;free&lt;/td&gt;
&lt;td&gt;free&lt;/td&gt;
&lt;td&gt;free&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Nano Banana images&lt;br&gt;&lt;small&gt;Pro, 2.1, 2 Lite, upscaled&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;~500 a day, 4K&lt;/td&gt;
&lt;td&gt;included, 4K&lt;/td&gt;
&lt;td&gt;included, 2K&lt;/td&gt;
&lt;td&gt;included, 2K&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;strong&gt;Google Vids&lt;/strong&gt;&lt;br&gt;&lt;small&gt;own allowance, on top&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;10,000 s&lt;/td&gt;
&lt;td&gt;2,500 s&lt;/td&gt;
&lt;td&gt;500 s&lt;/td&gt;
&lt;td&gt;60 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Omni 1.2 Flash videos&lt;br&gt;&lt;small&gt;15 s, 1080p&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;666&lt;/td&gt;
&lt;td&gt;166&lt;/td&gt;
&lt;td&gt;33&lt;/td&gt;
&lt;td&gt;4&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Talking avatar videos&lt;br&gt;&lt;small&gt;up to 30 s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;500&lt;/td&gt;
&lt;td&gt;125&lt;/td&gt;
&lt;td&gt;25&lt;/td&gt;
&lt;td&gt;6&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Images&lt;br&gt;&lt;small&gt;basic, about 1 MP&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;1,000&lt;/td&gt;
&lt;td&gt;300&lt;/td&gt;
&lt;td&gt;30&lt;/td&gt;
&lt;td&gt;up to 50&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Speech&lt;br&gt;&lt;small&gt;30 voices&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;included&lt;/td&gt;
&lt;td&gt;included&lt;/td&gt;
&lt;td&gt;included&lt;/td&gt;
&lt;td&gt;included&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;strong&gt;Flow Music&lt;/strong&gt;&lt;br&gt;&lt;small&gt;own credits, on top&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;30,000 cr&lt;/td&gt;
&lt;td&gt;30,000 cr&lt;/td&gt;
&lt;td&gt;10,000 cr&lt;/td&gt;
&lt;td&gt;3,000 cr&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Lyria 3.5 songs&lt;br&gt;&lt;small&gt;full songs&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;6,000&lt;/td&gt;
&lt;td&gt;6,000&lt;/td&gt;
&lt;td&gt;2,000&lt;/td&gt;
&lt;td&gt;600&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;strong&gt;Gemini Notebook&lt;/strong&gt;&lt;br&gt;&lt;small&gt;own limits, on top&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Podcasts&lt;br&gt;&lt;small&gt;per 5-hour window&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;181&lt;/td&gt;
&lt;td&gt;~45&lt;/td&gt;
&lt;td&gt;9&lt;/td&gt;
&lt;td&gt;~4&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;strong&gt;Google Cloud credits&lt;/strong&gt;&lt;br&gt;&lt;small&gt;for the Gemini API&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$100&lt;/td&gt;
&lt;td&gt;$40&lt;/td&gt;
&lt;td&gt;$10&lt;/td&gt;
&lt;td&gt;—&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;strong&gt;Worth on Google's APIs&lt;/strong&gt;&lt;br&gt;&lt;small&gt;videos and songs&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;$3,919&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;$1,699&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;$259&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;$64&lt;/strong&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;ul&gt;
&lt;li&gt;Google Flow credits are one pool. A plan makes the Veo 3.1 Fast videos, or one of the "or" rows, or a mix of them, never all of them. Everything below the pool is a separate allowance and adds on top.&lt;/li&gt;
&lt;li&gt;Flow upscales a video to 1080p for free up to 10 seconds and charges 1 credit for each second over that (&lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-videos-upscale" rel="noopener noreferrer"&gt;video upscale&lt;/a&gt;, &lt;a href="https://support.google.com/flow/answer/16526234" rel="noopener noreferrer"&gt;Google's Flow credits page&lt;/a&gt;). So every 1080p row in the Flow pool counts clips of 10 seconds or shorter. A 4K upscale takes 50 credits from the pool, on Ultra only. In Vids, 1080p uses the same seconds as 720p.&lt;/li&gt;
&lt;li&gt;The worth row counts the Flow pool as Veo 3.1 Fast at 1080p ($0.96 a video on Google's API), the Vids videos at 1080p ($1.56) and the songs at $0.08. That is 13 to 20 times each plan's price.&lt;/li&gt;
&lt;li&gt;The "1,000+ a day" Veo 3.1 Lite videos and "~500 a day" images are what our busiest Ultra $199.99 accounts reach, not limits Google publishes. Lower-priority Lite runs only for the owner of that plan.&lt;/li&gt;
&lt;li&gt;The Vids counts are Google's figures, and our Pro test account showed exactly 25 avatar videos. Google notes that some plans share one limit between avatars and video clips. On Plus, images and voice-overs share 50 credits a month. Pro and Ultra list voice-over as unlimited, while our test accounts showed a counter of 50 uses a month. Google has no API for talking avatars.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  What each plan makes in a month
&lt;/h3&gt;

&lt;p&gt;What each Google AI plan makes through useapi.net, and what one item costs on Google's own API (as of November 2026). A video costs its share of the plan: the plan price divided by what the plan makes.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;What it makes&lt;/th&gt;
&lt;th&gt;Official API&lt;/th&gt;
&lt;th&gt;Ultra $199.99/m&lt;br&gt;&lt;small&gt;25,000 cr, 10,000 s&lt;/small&gt;
&lt;/th&gt;
&lt;th&gt;Ultra $99.99/m&lt;br&gt;&lt;small&gt;10,000 cr, 2,500 s&lt;/small&gt;
&lt;/th&gt;
&lt;th&gt;Pro $19.99/m&lt;br&gt;&lt;small&gt;1,000 cr, 500 s&lt;/small&gt;
&lt;/th&gt;
&lt;th&gt;Plus $4.99/m&lt;br&gt;&lt;small&gt;200 cr, 60 s&lt;/small&gt;
&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Omni 1.2 in Flow&lt;br&gt;&lt;small&gt;720p, 15 s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;a href="https://ai.google.dev/gemini-api/docs/pricing" rel="noopener noreferrer"&gt;$1.04&lt;/a&gt;&lt;br&gt;&lt;small&gt;$0.07/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.48 / 60 cr&lt;br&gt;&lt;small&gt;416 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.60 / 60 cr&lt;br&gt;&lt;small&gt;166 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$1.20 / 60 cr&lt;br&gt;&lt;small&gt;16 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$1.50 / 60 cr&lt;br&gt;&lt;small&gt;3 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Omni 1.1 in Flow&lt;br&gt;&lt;small&gt;720p, 10 s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;a href="https://ai.google.dev/gemini-api/docs/pricing" rel="noopener noreferrer"&gt;$1.01&lt;/a&gt;&lt;br&gt;&lt;small&gt;$0.10/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.12 / 15 cr&lt;br&gt;&lt;small&gt;1,666 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.15 / 15 cr&lt;br&gt;&lt;small&gt;666 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.30 / 15 cr&lt;br&gt;&lt;small&gt;66 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.37 / 15 cr&lt;br&gt;&lt;small&gt;13 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Omni 1.2 in Vids&lt;br&gt;&lt;small&gt;720p, 15 s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;a href="https://ai.google.dev/gemini-api/docs/pricing" rel="noopener noreferrer"&gt;$1.04&lt;/a&gt;&lt;br&gt;&lt;small&gt;$0.07/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.30 / 15 s&lt;br&gt;&lt;small&gt;666 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.60 / 15 s&lt;br&gt;&lt;small&gt;166 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.60 / 15 s&lt;br&gt;&lt;small&gt;33 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$1.25 / 15 s&lt;br&gt;&lt;small&gt;4 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Omni 1.2 in Vids&lt;br&gt;&lt;small&gt;1080p, 15 s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;a href="https://ai.google.dev/gemini-api/docs/pricing" rel="noopener noreferrer"&gt;$1.56&lt;/a&gt;&lt;br&gt;&lt;small&gt;$0.104/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.30 / 15 s&lt;br&gt;&lt;small&gt;666 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.60 / 15 s&lt;br&gt;&lt;small&gt;166 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.60 / 15 s&lt;br&gt;&lt;small&gt;33 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$1.25 / 15 s&lt;br&gt;&lt;small&gt;4 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Veo 3.1 Fast&lt;br&gt;&lt;small&gt;Flow, 720p, 8 s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;a href="https://cloud.google.com/gemini-enterprise-agent-platform/generative-ai/pricing" rel="noopener noreferrer"&gt;$0.80&lt;/a&gt;&lt;br&gt;&lt;small&gt;$0.10/s&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.08 / 10 cr&lt;br&gt;&lt;small&gt;2,500 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.10 / 10 cr&lt;br&gt;&lt;small&gt;1,000 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.40 / 20 cr&lt;br&gt;&lt;small&gt;50 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.50 / 20 cr&lt;br&gt;&lt;small&gt;10 videos/mo&lt;/small&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;span&gt;Nano Banana Pro&lt;br&gt;&lt;small&gt;Flow image&lt;/small&gt;&lt;/span&gt;&lt;/td&gt;
&lt;td&gt;
&lt;a href="https://ai.google.dev/gemini-api/docs/pricing" rel="noopener noreferrer"&gt;$0.134&lt;/a&gt;&lt;br&gt;&lt;small&gt;per image&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;&lt;span&gt;$0 / 0 cr&lt;br&gt;&lt;small&gt;~500 a day&lt;/small&gt;&lt;/span&gt;&lt;/td&gt;
&lt;td&gt;&lt;span&gt;$0 / 0 cr&lt;br&gt;&lt;small&gt;included&lt;/small&gt;&lt;/span&gt;&lt;/td&gt;
&lt;td&gt;&lt;span&gt;$0 / 0 cr&lt;br&gt;&lt;small&gt;included&lt;/small&gt;&lt;/span&gt;&lt;/td&gt;
&lt;td&gt;&lt;span&gt;$0 / 0 cr&lt;br&gt;&lt;small&gt;included&lt;/small&gt;&lt;/span&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Lyria 3.5 song&lt;br&gt;&lt;small&gt;Flow Music&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;a href="https://ai.google.dev/gemini-api/docs/pricing" rel="noopener noreferrer"&gt;$0.08&lt;/a&gt;&lt;br&gt;&lt;small&gt;per song&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.033 / 5 cr&lt;br&gt;&lt;small&gt;6,000 songs/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.017 / 5 cr&lt;br&gt;&lt;small&gt;6,000 songs/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.010 / 5 cr&lt;br&gt;&lt;small&gt;2,000 songs/mo&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.008 / 5 cr&lt;br&gt;&lt;small&gt;600 songs/mo&lt;/small&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Notebook&lt;br&gt;&lt;small&gt;podcasts per 5 h&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;a href="https://docs.cloud.google.com/gemini/enterprise/notebooklm-enterprise/docs/api-notebooks" rel="noopener noreferrer"&gt;Enterprise&lt;/a&gt;&lt;br&gt;&lt;small&gt;Preview&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;181&lt;/td&gt;
&lt;td&gt;~45&lt;/td&gt;
&lt;td&gt;9&lt;/td&gt;
&lt;td&gt;~4&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Cloud credits&lt;br&gt;&lt;small&gt;Gemini API use&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;—&lt;/td&gt;
&lt;td&gt;$100/mo&lt;/td&gt;
&lt;td&gt;$40/mo&lt;/td&gt;
&lt;td&gt;$10/mo&lt;/td&gt;
&lt;td&gt;—&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;ul&gt;
&lt;li&gt;The Notebook row counts the Audio Overviews (podcasts) one full 5-hour window can start, by Google's own estimates. Plus and Ultra $99.99 are scaled by Google's &lt;a href="https://support.google.com/gemininotebook/answer/17670842" rel="noopener noreferrer"&gt;published multipliers&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Each Flow video and image needs a captcha, which the API solves. Your first account gets 300 free, then your own &lt;a href="https://useapi.net/docs/start-here/setup-google-flow#configure-captcha-providers" rel="noopener noreferrer"&gt;captcha provider&lt;/a&gt; costs about $0.80 to $3.00 per 1,000.&lt;/li&gt;
&lt;li&gt;Plan prices are Google's US prices. The &lt;a href="https://useapi.net/docs/api-google-flow-v1#pricing" rel="noopener noreferrer"&gt;Google Flow&lt;/a&gt; and &lt;a href="https://useapi.net/docs/api-google-vids-v1#pricing" rel="noopener noreferrer"&gt;Google Vids&lt;/a&gt; price tables list every model on every plan.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Google Flow: Veo 3.1, Omni Flash and Nano Banana
&lt;/h3&gt;

&lt;p&gt;The &lt;a href="https://useapi.net/docs/api-google-flow-v1" rel="noopener noreferrer"&gt;Google Flow API&lt;/a&gt; makes Veo 3.1 Fast, Quality and Lite videos and Omni 1.2 Flash and Omni 1.1 Flash videos from the plan's Flow credits. It also makes Nano Banana Pro, 2.1 and 2 Lite images, which use no credits, and upscales videos and images.&lt;/p&gt;

&lt;p&gt;On Google's side, Veo 3.1 runs on &lt;a href="https://cloud.google.com/gemini-enterprise-agent-platform/generative-ai/pricing" rel="noopener noreferrer"&gt;Agent Platform&lt;/a&gt; at $0.10 a second for Fast at 720p and $0.12 at 1080p. Omni 1.2 Flash and Nano Banana run on the &lt;a href="https://ai.google.dev/gemini-api/docs/pricing" rel="noopener noreferrer"&gt;Gemini API&lt;/a&gt;. Both need a Google Cloud project with billing. The &lt;a href="https://useapi.net/docs/articles/veo-3-1-api-pricing" rel="noopener noreferrer"&gt;Veo 3.1 API pricing&lt;/a&gt; article compares every Veo price.&lt;/p&gt;

&lt;h3&gt;
  
  
  Google Vids: Omni 1.2 Flash and talking avatars
&lt;/h3&gt;

&lt;p&gt;The &lt;a href="https://useapi.net/docs/api-google-vids-v1" rel="noopener noreferrer"&gt;Google Vids API&lt;/a&gt; makes Omni 1.2 Flash videos of 3 to 15 seconds with sound, at 720p or 1080p for the same seconds, and extends, edits and upscales them. It also makes &lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos-avatar" rel="noopener noreferrer"&gt;talking avatar videos&lt;/a&gt; of up to 30 seconds, &lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-speech" rel="noopener noreferrer"&gt;speech&lt;/a&gt; in 30 voices and basic images. None of these use video seconds.&lt;/p&gt;

&lt;p&gt;Google publishes no Vids API. The same model on the Gemini API costs $0.07 a second at 720p and $0.104 at 1080p. Vids asks for no captcha. Its seconds are shared by everyone on a Google family plan. The &lt;a href="https://useapi.net/docs/articles/gemini-omni-1-2-flash-api" rel="noopener noreferrer"&gt;Omni 1.2 Flash guide&lt;/a&gt; runs one scene in Flow and one in Vids.&lt;/p&gt;

&lt;h3&gt;
  
  
  Gemini Notebook (NotebookLM): podcasts, video and Deep Research
&lt;/h3&gt;

&lt;p&gt;The &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1" rel="noopener noreferrer"&gt;Gemini Notebook API (NotebookLM API)&lt;/a&gt; turns web pages, PDFs and YouTube videos into Audio Overviews (podcasts), Video Overviews, slide decks, infographics, reports and quizzes, and runs chat with citations and Deep Research. Cinematic Video Overviews need Pro or Ultra.&lt;/p&gt;

&lt;p&gt;Notebook has no credits. Each job uses part of the account's usage, which refills every 5 hours up to a weekly limit: Plus gets 2 times the free limits, Pro 4 times, and Ultra 5 or 20 times Pro's. Google's own &lt;a href="https://docs.cloud.google.com/gemini/enterprise/notebooklm-enterprise/docs/api-notebooks" rel="noopener noreferrer"&gt;Gemini Notebook Enterprise API&lt;/a&gt; is in Preview, needs Enterprise licenses in a Google Cloud project and covers notebooks, sources, sharing and Audio Overviews only.&lt;/p&gt;

&lt;h3&gt;
  
  
  Google Flow Music: Lyria 3.5 songs
&lt;/h3&gt;

&lt;p&gt;Every paid Google AI plan also includes &lt;a href="https://www.flowmusic.app" rel="noopener noreferrer"&gt;Google Flow Music&lt;/a&gt; credits, separate from Flow credits. Plus gets &lt;a href="https://support.google.com/googleone/answer/16882689" rel="noopener noreferrer"&gt;3,000 credits a month&lt;/a&gt;, Pro &lt;a href="https://support.google.com/googleone/answer/14534406" rel="noopener noreferrer"&gt;10,000&lt;/a&gt; and Ultra &lt;a href="https://support.google.com/googleone/answer/16286513" rel="noopener noreferrer"&gt;30,000&lt;/a&gt;. You claim them once: sign in at flowmusic.app with the same Google account and let Flow Music see your Google One membership.&lt;/p&gt;

&lt;p&gt;The &lt;a href="https://useapi.net/docs/api-flowmusic-v1" rel="noopener noreferrer"&gt;Flow Music API&lt;/a&gt; makes full songs with vocals or instrumentals on Lyria 3.5 and Lyria 3 Pro, at 5 credits a song. It also makes covers, remixes and extends, and splits songs into four stems. Google offers Flow Music only as a website. On the Gemini API a Lyria 3.5 song costs $0.08, and a generated song can't be edited there.&lt;/p&gt;

&lt;h3&gt;
  
  
  One Google account, four allowances
&lt;/h3&gt;

&lt;p&gt;Flow credits, Vids seconds, Notebook usage and Flow Music credits are counted separately, and none of them takes from another. Connect the same Google account to all four APIs and it uses every allowance: Omni 1.2 Flash videos in Flow and in Vids on top of each other, podcasts and Deep Research from Notebook, and songs from Flow Music. Each API has its own setup page (&lt;a href="https://useapi.net/docs/start-here/setup-google-flow" rel="noopener noreferrer"&gt;Flow&lt;/a&gt;, &lt;a href="https://useapi.net/docs/start-here/setup-google-vids" rel="noopener noreferrer"&gt;Vids&lt;/a&gt;, &lt;a href="https://useapi.net/docs/start-here/setup-gemini-notebook" rel="noopener noreferrer"&gt;Notebook&lt;/a&gt;, &lt;a href="https://useapi.net/docs/start-here/setup-flowmusic" rel="noopener noreferrer"&gt;Flow Music&lt;/a&gt;), and one useapi.net subscription covers all four.&lt;/p&gt;

&lt;h3&gt;
  
  
  Which plan to pick
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Ultra $199.99 is the only plan with &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-videos" rel="noopener noreferrer"&gt;Veo 3.1 Lite at lower priority&lt;/a&gt;, which uses no credits at all. Google publishes no limit, and our busiest accounts make 1,000+ of these videos a day, on top of the 25,000 monthly credits. It also has the lowest price per video: Veo 3.1 Fast at $0.08, and a fifteen-second Omni 1.2 Flash video at $0.30 in Vids or $0.48 in Flow.&lt;/li&gt;
&lt;li&gt;Ultra $99.99 costs half as much but has no lower-priority Veo 3.1 Lite. It makes 1,000 Veo 3.1 Fast videos at $0.10 and 166 Vids videos at $0.60, with the same 6,000 songs.&lt;/li&gt;
&lt;li&gt;Pro is the plan to start with. It makes 50 Veo 3.1 Fast videos a month at $0.40, half Google's price, 33 fifteen-second Vids videos at $0.60 and 2,000 Lyria 3.5 songs. On Pro, make Omni 1.2 Flash in Vids: in Flow it costs $1.20, more than the Gemini API's $1.04.&lt;/li&gt;
&lt;li&gt;Plus can cost more per video than Google's API. A fifteen-second 720p Omni 1.2 Flash video is $1.50 in Flow and $1.25 in Vids, against $1.04. Veo 3.1 Fast is still cheaper, $0.50 against $0.80, but only 10 a month. Plus fits songs (600 a month), Nano Banana images and Gemini Notebook better than video.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Questions
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Does Google AI Ultra include Gemini API access?
&lt;/h3&gt;

&lt;p&gt;Through useapi.net, Ultra $199.99 makes 2,500 Veo 3.1 Fast videos, 666 Omni 1.2 Flash videos in Vids and 6,000 songs a month, worth about $3,919 on Google's APIs (as of November 2026). The plan itself includes no Gemini API usage. It comes with &lt;a href="https://developers.google.com/program/plans-and-pricing" rel="noopener noreferrer"&gt;Google Cloud credits&lt;/a&gt; of $100 a month ($40 on Ultra $99.99), which you activate in the Google Developer Program. That buys about 96 fifteen-second Omni 1.2 Flash videos.&lt;/p&gt;

&lt;h3&gt;
  
  
  Can I use my Google AI Pro plan with an API?
&lt;/h3&gt;

&lt;p&gt;Through useapi.net, yes: Pro's 1,000 Flow credits, 500 Vids seconds and 10,000 Flow Music credits run over REST. They make 50 Veo 3.1 Fast videos a month at $0.40 each, against $0.80 on Google's Agent Platform. They also make 33 fifteen-second Omni 1.2 Flash videos in Vids at $0.60, against $1.04 on the Gemini API, and 2,000 Lyria 3.5 songs, worth $160 there (as of November 2026). Nano Banana images use no credits.&lt;/p&gt;

&lt;h3&gt;
  
  
  How many Veo 3.1 videos does Google AI Ultra make?
&lt;/h3&gt;

&lt;p&gt;Through useapi.net, Ultra $199.99 makes 2,500 eight-second Veo 3.1 Fast videos a month at $0.08 each, against $0.80 on Google's &lt;a href="https://cloud.google.com/gemini-enterprise-agent-platform/generative-ai/pricing" rel="noopener noreferrer"&gt;Agent Platform&lt;/a&gt;, and Ultra $99.99 makes 1,000 at $0.10 (as of November 2026). Ultra $199.99 also runs Veo 3.1 Lite at lower priority for no credits, about 1,000 or more a day on our busiest accounts.&lt;/p&gt;

&lt;h3&gt;
  
  
  Is there a NotebookLM API?
&lt;/h3&gt;

&lt;p&gt;Through useapi.net, yes, for regular Google accounts: the Gemini Notebook API (NotebookLM API) runs Audio and Video Overviews, slides, chat with citations and Deep Research on your Google AI plan, the free one included. Google's own &lt;a href="https://docs.cloud.google.com/gemini/enterprise/notebooklm-enterprise/docs/api-notebooks" rel="noopener noreferrer"&gt;Enterprise API&lt;/a&gt; is in Preview, needs Enterprise licenses in a Google Cloud project and has no Video Overviews, chat or Deep Research (as of November 2026).&lt;/p&gt;

&lt;h3&gt;
  
  
  Can a free Google account use it?
&lt;/h3&gt;

&lt;p&gt;Through useapi.net, yes, in Flow and Notebook. A free account's 50 Flow credits a day make 2 Veo 3.1 Fast videos, 5 Lite ones or one 10-second 720p Omni 1.2 Flash video, and Nano Banana images use no credits. Notebook starts about 2 Audio Overviews per 5-hour window. The Gemini API has no free tier for Omni 1.2 Flash or Nano Banana Pro (as of November 2026). Vids is the exception: the free accounts we tested had no video seconds.&lt;/p&gt;

&lt;h3&gt;
  
  
  Sources
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Google, &lt;a href="https://gemini.google/subscriptions/" rel="noopener noreferrer"&gt;Google AI plans&lt;/a&gt; and the &lt;a href="https://gemini.google/subscriptions/?plans=developer" rel="noopener noreferrer"&gt;Developer plans&lt;/a&gt;, read November 7, 2026&lt;/li&gt;
&lt;li&gt;Google, &lt;a href="https://developers.google.com/program/plans-and-pricing" rel="noopener noreferrer"&gt;Google Developer Program plans&lt;/a&gt; (Google Cloud credits per plan) and &lt;a href="https://blog.google/innovation-and-ai/technology/developers-tools/gdp-premium-ai-pro-ultra/" rel="noopener noreferrer"&gt;New developer tools for Google AI Pro and Ultra subscribers&lt;/a&gt;, January 27, 2026&lt;/li&gt;
&lt;li&gt;Google One Help, Flow Music benefits of &lt;a href="https://support.google.com/googleone/answer/16882689" rel="noopener noreferrer"&gt;Google AI Plus&lt;/a&gt;, &lt;a href="https://support.google.com/googleone/answer/14534406" rel="noopener noreferrer"&gt;Google AI Pro&lt;/a&gt; and &lt;a href="https://support.google.com/googleone/answer/16286513" rel="noopener noreferrer"&gt;Google AI Ultra&lt;/a&gt;, read November 7, 2026&lt;/li&gt;
&lt;li&gt;Google, &lt;a href="https://ai.google.dev/gemini-api/docs/pricing" rel="noopener noreferrer"&gt;Gemini API pricing&lt;/a&gt; (Omni 1.2 Flash, Nano Banana, Lyria 3.5), read November 7, 2026&lt;/li&gt;
&lt;li&gt;Google Cloud, &lt;a href="https://cloud.google.com/gemini-enterprise-agent-platform/generative-ai/pricing" rel="noopener noreferrer"&gt;Agent Platform pricing&lt;/a&gt; (Veo 3.1), read November 7, 2026&lt;/li&gt;
&lt;li&gt;Google, &lt;a href="https://support.google.com/flow/answer/16526234" rel="noopener noreferrer"&gt;Flow credits&lt;/a&gt;, &lt;a href="https://support.google.com/docs/answer/15609411" rel="noopener noreferrer"&gt;Gemini in Google Vids&lt;/a&gt; and &lt;a href="https://support.google.com/gemininotebook/answer/17670842" rel="noopener noreferrer"&gt;Gemini Notebook usage limits&lt;/a&gt;, read November 7, 2026&lt;/li&gt;
&lt;li&gt;Google Cloud, &lt;a href="https://docs.cloud.google.com/gemini/enterprise/notebooklm-enterprise/docs/api-notebooks" rel="noopener noreferrer"&gt;Gemini Notebook Enterprise API&lt;/a&gt;, read November 7, 2026&lt;/li&gt;
&lt;li&gt;useapi.net price tables: &lt;a href="https://useapi.net/docs/api-google-flow-v1#pricing" rel="noopener noreferrer"&gt;Google Flow API&lt;/a&gt;, &lt;a href="https://useapi.net/docs/api-google-vids-v1#pricing" rel="noopener noreferrer"&gt;Google Vids API&lt;/a&gt;, &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1#pricing" rel="noopener noreferrer"&gt;Gemini Notebook API&lt;/a&gt; and &lt;a href="https://useapi.net/docs/api-flowmusic-v1#pricing" rel="noopener noreferrer"&gt;Flow Music API&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Start using the API
&lt;/h3&gt;

&lt;p&gt;A single $15/month subscription covers every API on useapi.net — one token, all services. You connect up to 3 accounts per service, each with its own website subscription, and useapi.net handles the REST API, load balancing, and polling. Need more accounts? Each extra subscription is $10/month and adds 3 more accounts per service.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://buy.stripe.com/8x2aEX4Bd8Vh9PMg4qeUU03" rel="noopener noreferrer"&gt;Subscribe — $15/month&lt;/a&gt; &lt;a href="https://pay.boomfi.xyz/38UTma36Rv0DrY8NlH1r2SEG7VK" rel="noopener noreferrer"&gt;Pay with crypto&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;Pricing and volume options&lt;/a&gt; — full refund within the first 14 days if you have fewer than 50 successful generations. Already subscribed? Change the quantity in the &lt;a href="https://billing.stripe.com/p/login/28obM4fZld0JaHu6oo" rel="noopener noreferrer"&gt;Stripe Customer Portal&lt;/a&gt; instead of buying again.&lt;/p&gt;

</description>
      <category>googleai</category>
      <category>gemini</category>
      <category>api</category>
      <category>ai</category>
    </item>
    <item>
      <title>How to Generate Kling 4.0 Video via the Kling API</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Sun, 25 Oct 2026 18:00:02 +0000</pubDate>
      <link>https://dev.to/useapi/how-to-generate-kling-40-video-via-the-kling-api-5h25</link>
      <guid>https://dev.to/useapi/how-to-generate-kling-40-video-via-the-kling-api-5h25</guid>
      <description>&lt;h3&gt;
  
  
  Introduction
&lt;/h3&gt;

&lt;p&gt;Kling 4.0 launched in the Kling app on October 15, 2026, and Kling's own developer API still lists it as coming soon (as of October 18, 2026), so the way to call it from code today is the useapi.net Kling API: send &lt;code&gt;"model_name": "kling-v4-0"&lt;/code&gt; to &lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-videos-text2video" rel="noopener noreferrer"&gt;POST /videos/text2video&lt;/a&gt; and it runs on your &lt;a href="https://kling.ai/app/membership/membership-plan" rel="noopener noreferrer"&gt;Kling AI website subscription&lt;/a&gt;. useapi.net is a &lt;a href="https://useapi.net/docs/legal#affiliation--third-party-services" rel="noopener noreferrer"&gt;third-party&lt;/a&gt; API, not affiliated with &lt;a href="https://kling.ai/app" rel="noopener noreferrer"&gt;Kling AI&lt;/a&gt; or &lt;a href="https://www.kuaishou.com/en" rel="noopener noreferrer"&gt;Kuaishou Technology&lt;/a&gt;. Kling 4.0 makes 3 to 30 second clips at 720p or 1080p, always with a stereo soundtrack, and adds the &lt;code&gt;21:9&lt;/code&gt; aspect ratio and keyframes between the start and end frames.&lt;/p&gt;

&lt;p&gt;This guide is one real run. We asked Kling 4.0 for the cheapest clip it makes, 3 seconds at 720p, on a Kling Pro subscription. The job finished in about 2 minutes and took 27 Kling credits off the balance (300,290 to 297,590 in the account's hundredths of a credit), about $0.30 at the Pro plan's credit price. Every response below is from that run, with the account email left out.&lt;/p&gt;

&lt;h3&gt;
  
  
  Before you start
&lt;/h3&gt;

&lt;p&gt;You need a useapi.net &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt; and a Kling account connected through &lt;a href="https://useapi.net/docs/start-here/setup-kling" rel="noopener noreferrer"&gt;Setup Kling&lt;/a&gt;. Kling 4.0 at 1080p needs a paid Kling plan. Export the token so the &lt;code&gt;curl&lt;/code&gt; examples run as they are:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;USEAPI_TOKEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"user:1234-..."&lt;/span&gt;      &lt;span class="c"&gt;# your useapi.net API token&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;KLING_EMAIL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"you@example.com"&lt;/span&gt;     &lt;span class="c"&gt;# your connected Kling account&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;email&lt;/code&gt; is optional in the request body: without it, the API picks one of your Kling accounts that has a free job slot (&lt;code&gt;429&lt;/code&gt; when every account is busy). With more than one account, note which account ran the job (&lt;a href="https://useapi.net/docs/api-kling-v1/get-kling-tasks-task_id" rel="noopener noreferrer"&gt;GET tasks/&lt;code&gt;task_id&lt;/code&gt;&lt;/a&gt; explains how to find it), because polling the task needs that account's &lt;code&gt;email&lt;/code&gt;. If Kling hasn't opened Kling 4.0 to your account yet, the create call returns &lt;code&gt;403&lt;/code&gt; with &lt;code&gt;AUTH.VPrivilegeEscalation&lt;/code&gt;, and nothing is charged.&lt;/p&gt;

&lt;h3&gt;
  
  
  Kling 4.0 at a glance
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;Kling 4.0 (&lt;code&gt;kling-v4-0&lt;/code&gt;)&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Duration&lt;/td&gt;
&lt;td&gt;3 to 30 seconds, default 5&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Resolution&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;std&lt;/code&gt; 720p, &lt;code&gt;pro&lt;/code&gt; 1080p (paid Kling plan). No 4K or HDR yet&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Aspect ratio&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;16:9&lt;/code&gt;, &lt;code&gt;9:16&lt;/code&gt;, &lt;code&gt;1:1&lt;/code&gt;, &lt;code&gt;21:9&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Audio&lt;/td&gt;
&lt;td&gt;Always on, stereo&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Prompt&lt;/td&gt;
&lt;td&gt;Up to 8000 characters&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Shots&lt;/td&gt;
&lt;td&gt;Kling may cut the clip into several shots, or you write up to 6 shot prompts (15 seconds in total)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Credits per second&lt;/td&gt;
&lt;td&gt;10 at 720p, 15 at 1080p (Kling Pro, Premier and Ultra+ subscribers pay 10% less)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The same model is on three endpoints: &lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-videos-text2video" rel="noopener noreferrer"&gt;text-to-video&lt;/a&gt;, &lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-videos-image2video-frames" rel="noopener noreferrer"&gt;image-to-video&lt;/a&gt; with start, end and keyframe images, and &lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-videos-omni" rel="noopener noreferrer"&gt;Omni&lt;/a&gt; with reference images, elements, videos and voices. The credit price is the same on all three.&lt;/p&gt;

&lt;h3&gt;
  
  
  Generate a Kling 4.0 video in two calls
&lt;/h3&gt;

&lt;p&gt;Generation is asynchronous. The create call answers right away with a task, and you poll the task until it is final.&lt;/p&gt;

&lt;h4&gt;
  
  
  1. Submit the job
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-videos-text2video" rel="noopener noreferrer"&gt;POST /videos/text2video&lt;/a&gt; with &lt;code&gt;model_name&lt;/code&gt; set to &lt;code&gt;kling-v4-0&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s -X POST &lt;span class="s2"&gt;"https://api.useapi.net/v1/kling/videos/text2video"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{
    "email": "'&lt;/span&gt;&lt;span class="s2"&gt;"$KLING_EMAIL"&lt;/span&gt;&lt;span class="s1"&gt;'",
    "model_name": "kling-v4-0",
    "mode": "std",
    "duration": "3",
    "aspect_ratio": "16:9",
    "prompt": "A small paper boat sails across a rain puddle on a city sidewalk at dusk, neon signs reflect and ripple in the water, raindrops patter around it and a tram bell rings in the distance, low camera at water level"
  }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The answer came back in about a second. The parts that matter, from our run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"task"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;324332112308198&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"m2v_aio2video"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"status_name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"submitted"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"status_final"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"works"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"status_name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"submitted"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"status_final"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"message"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;""&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"userPoints"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"points"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"total"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;297590&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;task.id&lt;/code&gt; is the id you poll. &lt;code&gt;userPoints.total&lt;/code&gt; is the balance after the charge, in hundredths of a credit, so 297590 is 2,975.90 credits. The task's &lt;code&gt;arguments&lt;/code&gt; echo what Kling received: &lt;code&gt;kling_version&lt;/code&gt; 4.0, &lt;code&gt;model_mode&lt;/code&gt; std, &lt;code&gt;enable_audio&lt;/code&gt; true and &lt;code&gt;prefer_multi_shots&lt;/code&gt; true. Kling 4.0 always turns audio on, and it may cut the clip into shots on its own. The create call is the paid step, so don't resend it after a timeout. Poll or list your tasks instead.&lt;/p&gt;

&lt;h4&gt;
  
  
  2. Poll for the result
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-kling-v1/get-kling-tasks-task_id" rel="noopener noreferrer"&gt;GET /tasks/&lt;code&gt;task_id&lt;/code&gt;&lt;/a&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s &lt;span class="s2"&gt;"https://api.useapi.net/v1/kling/tasks/324332112308198?email=$KLING_EMAIL"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Ours read &lt;code&gt;processing&lt;/code&gt; for about 2 minutes, then:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;99&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"status_name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"succeed"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"status_final"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"works"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"workId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;324332112317252&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"status_name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"succeed"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"resource"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="nl"&gt;"resource"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"https://v15-kling.klingai.com/bs2/upload-ylab-stunt-sgp/....mp4"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="nl"&gt;"height"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;720&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="nl"&gt;"width"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1280&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="nl"&gt;"duration"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;3041&lt;/span&gt;
      &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;]&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The MP4 is 1280×720, 3.04 seconds, H.264 video with a two-channel AAC soundtrack. A task is done when &lt;code&gt;status_final&lt;/code&gt; is &lt;code&gt;true&lt;/code&gt;, and &lt;code&gt;status_name: "succeed"&lt;/code&gt; means it worked. The other final statuses are failures, listed on &lt;a href="https://useapi.net/docs/api-kling-v1/get-kling-tasks-task_id#model" rel="noopener noreferrer"&gt;GET /tasks/&lt;code&gt;task_id&lt;/code&gt;&lt;/a&gt;. Pass a &lt;code&gt;replyUrl&lt;/code&gt; in the create body if you'd rather get a webhook than poll.&lt;/p&gt;

&lt;h4&gt;
  
  
  3. Download the master
&lt;/h4&gt;

&lt;p&gt;Free Kling plans get a watermarked &lt;code&gt;works[0].resource.resource&lt;/code&gt;. On a paid plan, &lt;a href="https://useapi.net/docs/api-kling-v1/get-kling-assets-download" rel="noopener noreferrer"&gt;GET /assets/download&lt;/a&gt; returns a &lt;code&gt;cdnUrl&lt;/code&gt; to the clean file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s &lt;span class="s2"&gt;"https://api.useapi.net/v1/kling/assets/download?email=$KLING_EMAIL&amp;amp;workIds=324332112317252&amp;amp;fileTypes=MP4"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Longer, wider and 1080p
&lt;/h3&gt;

&lt;p&gt;Change three fields and keep the rest. A 10-second 1080p cinema-wide clip:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"model_name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"kling-v4-0"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"mode"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"pro"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"duration"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"10"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"aspect_ratio"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"21:9"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"prompt"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"..."&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That costs 150 credits (15 per second), or 135 on a Kling Pro or Ultra plan. &lt;code&gt;duration&lt;/code&gt; goes up to &lt;code&gt;30&lt;/code&gt;. To direct the cuts yourself, send &lt;code&gt;shot_1_prompt&lt;/code&gt; with &lt;code&gt;shot_1_duration&lt;/code&gt;, &lt;code&gt;shot_2_prompt&lt;/code&gt; with &lt;code&gt;shot_2_duration&lt;/code&gt; and so on, up to 6 shots and 15 seconds in total, in place of &lt;code&gt;prompt&lt;/code&gt; and &lt;code&gt;duration&lt;/code&gt;. &lt;code&gt;negative_prompt&lt;/code&gt; and &lt;code&gt;cfg_scale&lt;/code&gt; don't apply to Kling 4.0.&lt;/p&gt;

&lt;h3&gt;
  
  
  Image-to-video with keyframes
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-videos-image2video-frames" rel="noopener noreferrer"&gt;POST /videos/image2video-frames&lt;/a&gt; with &lt;code&gt;model_name: kling-v4-0&lt;/code&gt; takes a start frame (&lt;code&gt;image&lt;/code&gt;, required), an optional end frame (&lt;code&gt;image_tail&lt;/code&gt;) and up to 9 keyframes in between (&lt;code&gt;keyframe_1&lt;/code&gt; to &lt;code&gt;keyframe_9&lt;/code&gt;), in order. That is up to 10 images in total, and at most the duration in seconds plus one, so a 5-second clip takes up to 6 images. Upload each image with &lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-assets" rel="noopener noreferrer"&gt;POST /assets&lt;/a&gt; first and pass the returned URLs:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s -X POST &lt;span class="s2"&gt;"https://api.useapi.net/v1/kling/videos/image2video-frames"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{
    "email": "'&lt;/span&gt;&lt;span class="s2"&gt;"$KLING_EMAIL"&lt;/span&gt;&lt;span class="s1"&gt;'",
    "model_name": "kling-v4-0",
    "mode": "std",
    "duration": "5",
    "image": "https://example.com/start.jpg",
    "keyframe_1": "https://example.com/middle.jpg",
    "image_tail": "https://example.com/end.jpg",
    "prompt": "the boat drifts from the puddle into the gutter stream"
  }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The aspect ratio comes from the start image. You poll and download the result the same way as above.&lt;/p&gt;

&lt;h3&gt;
  
  
  Omni with references and voices
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-videos-omni" rel="noopener noreferrer"&gt;POST /videos/omni&lt;/a&gt; with &lt;code&gt;omni_version: v4&lt;/code&gt; runs Kling 4.0 with up to 10 reference images, 7 elements (IMAGE and VIDEO), 5 reference videos of 3 to 30 seconds each (30 seconds in total) and 3 voices, including your own voice saved with &lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-videos-voices" rel="noopener noreferrer"&gt;POST /videos/voices&lt;/a&gt;. Reference them in the prompt as &lt;code&gt;@image_1&lt;/code&gt;, &lt;code&gt;@video_1&lt;/code&gt; or &lt;code&gt;@voice_1&lt;/code&gt;. Omni 4.0 doesn't take start and end frames, so use image-to-video above for those. The &lt;a href="https://useapi.net/docs/articles/kling-omni-bash" rel="noopener noreferrer"&gt;Kling Omni tutorial&lt;/a&gt; walks through the reference workflows.&lt;/p&gt;

&lt;h3&gt;
  
  
  Batch-generate with the script
&lt;/h3&gt;

&lt;p&gt;The &lt;a href="https://github.com/useapi/kling-api/tree/main/kling-4" rel="noopener noreferrer"&gt;&lt;code&gt;kling-4&lt;/code&gt; example&lt;/a&gt; in the &lt;code&gt;kling-api&lt;/code&gt; GitHub repo reads Kling 4.0 prompts from &lt;a href="https://github.com/useapi/kling-api/blob/main/kling-4/prompts.json" rel="noopener noreferrer"&gt;&lt;code&gt;prompts.json&lt;/code&gt;&lt;/a&gt; (text-to-video, 21:9 and multi-shot) or &lt;code&gt;prompts-frames.json&lt;/code&gt; (start, end and keyframe images), checks each one against the documented limits before it spends credits, submits it, polls the task and downloads the clean master. Run it with Node.js v21 or newer:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git clone https://github.com/useapi/kling-api.git
&lt;span class="nb"&gt;cd&lt;/span&gt; kling-api/kling-4
node ./kling4.mjs &lt;span class="s2"&gt;"$USEAPI_TOKEN"&lt;/span&gt; &lt;span class="s2"&gt;"$KLING_EMAIL"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;a href="https://useapi.net/docs/articles/kling-bash" rel="noopener noreferrer"&gt;Kling v3 tutorial&lt;/a&gt; explains the script line by line.&lt;/p&gt;

&lt;h3&gt;
  
  
  What it costs
&lt;/h3&gt;

&lt;p&gt;Kling 4.0 uses the credits of your Kling AI website subscription, at the rates in the table above, and useapi.net adds no per-video charge. On Kling Pro ($32.56 a month for 3,000 credits), that comes to about $0.10 a second at 720p and $0.15 at 1080p, so a 5-second 720p video uses 45 credits and the plan makes about 66 of them a month (as of October 2026). The &lt;a href="https://useapi.net/docs/api-kling-v1" rel="noopener noreferrer"&gt;cost calculator&lt;/a&gt; on the Kling API page prices every model on each Kling plan.&lt;/p&gt;

&lt;p&gt;Kling's own &lt;a href="https://kling.ai/dev/pricing" rel="noopener noreferrer"&gt;developer API&lt;/a&gt; sells prepaid video packs from $700 instead, separate from the app subscriptions (as of October 2026).&lt;/p&gt;

&lt;h3&gt;
  
  
  The same from an AI assistant
&lt;/h3&gt;

&lt;p&gt;The hosted &lt;a href="https://useapi.net/docs/api-kling-v1/mcp" rel="noopener noreferrer"&gt;Kling MCP server&lt;/a&gt; at &lt;code&gt;https://api.useapi.net/v1/kling/mcp&lt;/code&gt; exposes the same calls as 45 tools for Claude Code, Cursor and VS Code, Kling 4.0 included. Ask for "a 5-second Kling 4.0 clip of …" and the assistant calls &lt;code&gt;kling_text_to_video&lt;/code&gt; with &lt;code&gt;model_name: kling-v4-0&lt;/code&gt; on your account.&lt;/p&gt;

&lt;h3&gt;
  
  
  Examples
&lt;/h3&gt;

&lt;h6&gt;
  
  
  Kling 4.0 » &lt;code&gt;kling-v4-0&lt;/code&gt;, text-to-video, &lt;code&gt;std&lt;/code&gt; 720p, 3 seconds, &lt;code&gt;16:9&lt;/code&gt;, the run above
&lt;/h6&gt;



&lt;p&gt;The prompt is in step 1. 27 Kling credits on a Pro plan, about 2 minutes, with its stereo soundtrack.&lt;/p&gt;

&lt;h3&gt;
  
  
  Frequently asked questions
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Is there a Kling 4.0 API?&lt;/strong&gt; Through useapi.net, yes: the Kling API already runs Kling 4.0 on your Kling AI website subscription, from a prompt, from start, end and key frames, or from Omni references and voices. Kling's own &lt;a href="https://kling.ai/dev" rel="noopener noreferrer"&gt;developer site&lt;/a&gt; lists the Kling 4.0 API as coming soon (as of October 18, 2026), and its developer plans are sold separately from the app subscriptions.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is the model name for Kling 4.0?&lt;/strong&gt; Through useapi.net, Kling 4.0 is &lt;code&gt;kling-v4-0&lt;/code&gt; in the &lt;code&gt;model_name&lt;/code&gt; field of &lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-videos-text2video" rel="noopener noreferrer"&gt;POST /videos/text2video&lt;/a&gt; and &lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-videos-image2video-frames" rel="noopener noreferrer"&gt;POST /videos/image2video-frames&lt;/a&gt;, and &lt;code&gt;omni_version: v4&lt;/code&gt; on &lt;a href="https://useapi.net/docs/api-kling-v1/post-kling-videos-omni" rel="noopener noreferrer"&gt;POST /videos/omni&lt;/a&gt;. &lt;code&gt;negative_prompt&lt;/code&gt; and &lt;code&gt;cfg_scale&lt;/code&gt; don't apply to it, and the credit price is the same on all three endpoints.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Does Kling 4.0 need a paid Kling plan?&lt;/strong&gt; Through useapi.net, Kling 4.0 at 720p (&lt;code&gt;mode: std&lt;/code&gt;) runs on every Kling AI website subscription, and 1080p (&lt;code&gt;mode: pro&lt;/code&gt;) needs a paid one. A &lt;code&gt;403&lt;/code&gt; with &lt;code&gt;AUTH.VPrivilegeEscalation&lt;/code&gt; means Kling hasn't opened the model to that account yet, and nothing is charged. On Kling Pro, Premier and Ultra+, every Kling 4.0 video costs 10% less.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I turn audio off?&lt;/strong&gt; Through useapi.net, no: Kling 4.0 always makes a stereo soundtrack and doesn't accept &lt;code&gt;enable_audio&lt;/code&gt;, so leave the field out. Our test video came back with two-channel AAC audio next to H.264 video. For a video without sound, use Kling v3 (&lt;code&gt;kling-v3-0&lt;/code&gt;) instead, where &lt;code&gt;enable_audio: false&lt;/code&gt; turns the sound off.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How long can a Kling 4.0 video be?&lt;/strong&gt; Through useapi.net, a Kling 4.0 video runs 3 to 30 seconds in one generation, set with &lt;code&gt;duration&lt;/code&gt;, while Kling v3 stops at 15 seconds. When you write the shots yourself with &lt;code&gt;shot_1_prompt&lt;/code&gt; to &lt;code&gt;shot_6_prompt&lt;/code&gt;, the total stays within 15 seconds, and a single prompt may still be cut into several shots by Kling.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Do I need a Kling developer account or API key?&lt;/strong&gt; Through useapi.net, no: you need a useapi.net &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt; and a Kling account connected once through &lt;a href="https://useapi.net/docs/start-here/setup-kling" rel="noopener noreferrer"&gt;Setup Kling&lt;/a&gt;, with no Kling developer account and no prepaid pack. The same token works on the hosted &lt;a href="https://useapi.net/docs/api-kling-v1/mcp" rel="noopener noreferrer"&gt;Kling MCP server&lt;/a&gt;, so Claude Code, Cursor or VS Code can make Kling 4.0 videos for you.&lt;/p&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;Kling 4.0 is one field away from any Kling call you already make: set &lt;code&gt;model_name&lt;/code&gt; to &lt;code&gt;kling-v4-0&lt;/code&gt; and pick a duration up to 30 seconds. The full model reference is on the &lt;a href="https://useapi.net/docs/api-kling-v1" rel="noopener noreferrer"&gt;Kling API&lt;/a&gt; page, and the runnable code is in the &lt;a href="https://github.com/useapi/kling-api" rel="noopener noreferrer"&gt;&lt;code&gt;kling-api&lt;/code&gt; GitHub repo&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Visit our &lt;a href="https://discord.gg/w28uK3cnmF" rel="noopener noreferrer"&gt;Discord Server&lt;/a&gt; or &lt;a href="https://t.me/use_api" rel="noopener noreferrer"&gt;Telegram Channel&lt;/a&gt; for any support questions and concerns.&lt;/p&gt;

</description>
      <category>kling40api</category>
      <category>kling4api</category>
      <category>klingv40</category>
      <category>klingapi</category>
    </item>
    <item>
      <title>Is There a Meta Muse Video API? Official API, Free Tools and a Hosted API (2026)</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Sun, 18 Oct 2026 19:03:42 +0000</pubDate>
      <link>https://dev.to/useapi/is-there-a-meta-muse-video-api-official-api-free-tools-and-a-hosted-api-2026-1enc</link>
      <guid>https://dev.to/useapi/is-there-a-meta-muse-video-api-official-api-free-tools-and-a-hosted-api-2026-1enc</guid>
      <description>&lt;h3&gt;
  
  
  Does Meta Muse have a video API?
&lt;/h3&gt;

&lt;p&gt;Meta has no Muse video API: its official &lt;a href="https://dev.meta.ai/docs/models" rel="noopener noreferrer"&gt;Model API&lt;/a&gt; sells the Muse Image model and the Muse Wonder and Muse Spark text models, and none of them outputs video. The 10-second videos with sound that Muse makes at &lt;a href="https://muse.ai" rel="noopener noreferrer"&gt;muse.ai&lt;/a&gt; are reached through third-party tools that drive the Muse agent on your &lt;a href="https://www.meta.com/help/subscriptions/1021145227643680/" rel="noopener noreferrer"&gt;Muse website subscription&lt;/a&gt;, such as the hosted &lt;a href="https://useapi.net/docs/api-muse-v1" rel="noopener noreferrer"&gt;useapi.net Muse API&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;There are three kinds of options:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Meta's Model API, if you need Muse images or the Muse text models. It sells Muse Image at $0.01 per image, and Muse Wonder (launched on October 12, 2026) at $4 per million input tokens and $20 per million output tokens (&lt;a href="https://dev.meta.ai/docs/pricing-rate-limits" rel="noopener noreferrer"&gt;Meta pricing&lt;/a&gt;, &lt;a href="https://techcrunch.com/2026/10/12/meta-releases-its-first-frontier-model-muse-wonder" rel="noopener noreferrer"&gt;TechCrunch&lt;/a&gt;).&lt;/li&gt;
&lt;li&gt;Free self-hosted tools, such as &lt;a href="https://github.com/czg86389-hub/muse2api" rel="noopener noreferrer"&gt;muse2api&lt;/a&gt;, an open-source server that wraps muse.ai in OpenAI-compatible endpoints, and local MCP bridges such as &lt;a href="https://github.com/duclm1x1/Muse-Chat-MCP" rel="noopener noreferrer"&gt;Muse-Chat-MCP&lt;/a&gt;, which drives your logged-in Chrome. You run them on your own machine or server.&lt;/li&gt;
&lt;li&gt;Hosted APIs: per-request resellers such as &lt;a href="https://museai.suncodevn.com" rel="noopener noreferrer"&gt;museai.suncodevn.com&lt;/a&gt;, which sell credit packs, and the &lt;a href="https://useapi.net/docs/api-muse-v1" rel="noopener noreferrer"&gt;useapi.net Muse API&lt;/a&gt;, which runs on your Muse website subscription with no per-video charge, over REST and as a hosted &lt;a href="https://useapi.net/docs/api-muse-v1/mcp" rel="noopener noreferrer"&gt;MCP server&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;This page is written by the useapi.net maintainers and compares what each option offers from its own documentation.&lt;/p&gt;

&lt;h3&gt;
  
  
  Compared
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;useapi.net&lt;/th&gt;
&lt;th&gt;Meta Model API&lt;/th&gt;
&lt;th&gt;muse2api&lt;/th&gt;
&lt;th&gt;Per-request resellers&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Muse video generation&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;No (no video model)&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Chat with the Muse agent at muse.ai&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;No (Muse Wonder and Spark models, not the agent)&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Hosted, nothing to install or run&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;No (Docker or a VPS)&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Sign in with email and password, no cookies to copy, session renewed for you&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;API key&lt;/td&gt;
&lt;td&gt;No (browser cookies pushed by an extension)&lt;/td&gt;
&lt;td&gt;No (cookie pools)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;No per-video charge&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;no video&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;No (credits per video, also when it runs on your Meta account)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Hosted MCP server for Claude Code, Cursor, VS Code&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;not in its docs&lt;/td&gt;
&lt;td&gt;not in its docs&lt;/td&gt;
&lt;td&gt;not in its docs&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Price&lt;/td&gt;
&lt;td&gt;Your Muse website subscription&lt;br&gt;&lt;small&gt;the free plan made about 30 to 50 videos a week&lt;/small&gt;
&lt;/td&gt;
&lt;td&gt;$0.01 per image, text models per token&lt;/td&gt;
&lt;td&gt;Free, you host it&lt;/td&gt;
&lt;td&gt;6 credits a video, packs from $3.90 for 500 credits&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;small&gt;From each option's own documentation and pricing on October 18, 2026: Meta &lt;a href="https://dev.meta.ai/docs/models" rel="noopener noreferrer"&gt;models&lt;/a&gt; and &lt;a href="https://dev.meta.ai/docs/pricing-rate-limits" rel="noopener noreferrer"&gt;pricing&lt;/a&gt;, &lt;a href="https://github.com/czg86389-hub/muse2api" rel="noopener noreferrer"&gt;muse2api&lt;/a&gt; v1.6.1, and museai.suncodevn.com's &lt;a href="https://museai.suncodevn.com/api/billing/plans" rel="noopener noreferrer"&gt;published plans&lt;/a&gt; as the per-request example (on your Meta account it charges 4 credits a video on its Developer and Pro plans). useapi.net is a third-party API and is not affiliated with Meta.&lt;/small&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Why useapi.net for Meta Muse video
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-video" rel="noopener noreferrer"&gt;POST /jobs/video&lt;/a&gt; makes a video of about 10 seconds at about 720p, with sound, from text, a photo or another video. Lines written in quotes are spoken, so a single photo becomes a talking photo, and a person in a clip can be swapped for someone from a photo.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-chats" rel="noopener noreferrer"&gt;POST /chats&lt;/a&gt; talks to the whole Muse agent at muse.ai, with its answers streamed live over Server-Sent Events, and you can &lt;a href="https://useapi.net/docs/api-muse-v1/live-browser-guide" rel="noopener noreferrer"&gt;watch and take over its web browser&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;The hosted &lt;a href="https://useapi.net/docs/api-muse-v1/mcp" rel="noopener noreferrer"&gt;MCP server&lt;/a&gt; has 37 tools and adds to Claude Code, Cursor or VS Code with one line. It is listed in the official MCP Registry as &lt;code&gt;net.useapi/muse&lt;/code&gt;, and there is nothing to install.&lt;/li&gt;
&lt;li&gt;There is nothing to run on your machine, with no server to deploy, no browser to keep open and no extension to install. Jobs keep running when your laptop is off.&lt;/li&gt;
&lt;li&gt;You add the account once with its email and password, and we keep it signed in and renew its 30-day Muse session, with no cookies to copy or refresh.&lt;/li&gt;
&lt;li&gt;It runs on your Muse website subscription, and the free plan works. Each video uses about 2 to 3 percent of the free plan's weekly allowance in our tests.&lt;/li&gt;
&lt;li&gt;Each subscription adds 3 Muse accounts, and a job without an &lt;code&gt;email&lt;/code&gt; goes to a healthy account with allowance left and a free slot.&lt;/li&gt;
&lt;li&gt;A job can wait for the finished file, or you send &lt;code&gt;async: true&lt;/code&gt; and the job record is posted to your &lt;code&gt;replyUrl&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;A ready-made &lt;a href="https://n8n.io/workflows/20989" rel="noopener noreferrer"&gt;n8n template&lt;/a&gt; and an &lt;a href="https://github.com/useapi/muse-api/tree/main/skills/muse-video" rel="noopener noreferrer"&gt;agent skill&lt;/a&gt; get you started, with no per-image or per-video charge from us.&lt;/li&gt;
&lt;/ul&gt;



&lt;p&gt;&lt;small&gt;A Muse video made through the useapi.net API: the rider from a photo swapped into a clip Muse made from a still image. Every request is in the &lt;a href="https://useapi.net/docs/articles/muse-images-videos#8-swap-the-rider-in-the-video" rel="noopener noreferrer"&gt;tutorial&lt;/a&gt;.&lt;/small&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  How to start
&lt;/h3&gt;

&lt;p&gt;What the Muse account needs:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Muse is available only in the US and Canada (&lt;a href="https://about.fb.com/news/2026/09/introducing-muse-small-business/" rel="noopener noreferrer"&gt;Meta&lt;/a&gt;), so create the account there. Once it is added, you can call the API from anywhere.&lt;/li&gt;
&lt;li&gt;Finish Muse's onboarding at &lt;a href="https://muse.ai" rel="noopener noreferrer"&gt;muse.ai&lt;/a&gt;, including Meta's age check, and create one image there.&lt;/li&gt;
&lt;li&gt;The account must have email + password sign-in, because the API signs in with the email and password. A Meta account that signs in only with an emailed code has no password yet: create one in &lt;a href="https://accountscenter.meta.com/password_and_security/" rel="noopener noreferrer"&gt;Meta Accounts Center&lt;/a&gt; (Password and security), then add the account here. Without a password the add is refused with &lt;code&gt;400&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Use the account only for the API, with no other automation tools on it. Opening it at muse.ai in a browser is fine.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Then:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Get a useapi.net &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Add your Muse account once with &lt;a href="https://useapi.net/docs/start-here/setup-muse" rel="noopener noreferrer"&gt;Setup Muse&lt;/a&gt;. The free Muse plan works.&lt;/li&gt;
&lt;li&gt;Make a 10-second video with sound in one call:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -X POST https://api.useapi.net/v1/muse/jobs/video \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{"prompt": "A golden retriever runs along a beach at sunset while the camera tracks beside it. A man off screen calls: \"Good boy, come here!\" In exactly 16:9 aspect ratio."}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The request waits for the video, which took 60 to 140 seconds in our tests, and answers with the job record. The video is the first &lt;code&gt;assetId&lt;/code&gt; in &lt;code&gt;result.assets[]&lt;/code&gt;: download it with &lt;a href="https://useapi.net/docs/api-muse-v1/get-muse-assets-assetId" rel="noopener noreferrer"&gt;GET /assets/&lt;code&gt;assetId&lt;/code&gt;&lt;/a&gt;. A slower job answers &lt;code&gt;202&lt;/code&gt;, and you fetch it with &lt;a href="https://useapi.net/docs/api-muse-v1/get-muse-jobs-jobid" rel="noopener noreferrer"&gt;GET /jobs/&lt;code&gt;jobid&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Or add the &lt;a href="https://useapi.net/docs/api-muse-v1/mcp" rel="noopener noreferrer"&gt;MCP server&lt;/a&gt; to Claude Code with one line:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;claude mcp add --transport http useapi-muse https://api.useapi.net/v1/muse/mcp --header &lt;span class="s2"&gt;"Authorization: Bearer YOUR_API_TOKEN"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Step-by-step tutorial: &lt;a href="https://useapi.net/docs/articles/muse-images-videos" rel="noopener noreferrer"&gt;How to Generate AI Videos and Images with the Meta Muse API&lt;/a&gt; (talking photos, image to video, person swap, photo restoration). Runnable code: &lt;a href="https://github.com/useapi/muse-api" rel="noopener noreferrer"&gt;useapi/muse-api&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  开始使用
&lt;/h3&gt;

&lt;p&gt;每月 15 美元的订阅即可使用 useapi.net 上的所有 API：一个 Token，所有服务。每个服务最多绑定 3 个你自己的账号，useapi.net 负责 REST 接口、负载均衡和轮询。需要更多账号？每增加一个订阅每月 10 美元，每个服务再多 3 个账号。&lt;/p&gt;

&lt;p&gt;&lt;a href="https://buy.stripe.com/8x2aEX4Bd8Vh9PMg4qeUU03" rel="noopener noreferrer"&gt;订阅 — 每月 15 美元&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;没有国际信用卡？可以&lt;a href="https://pay.boomfi.xyz/38UTma36Rv0DrY8NlH1r2SEG7VK" rel="noopener noreferrer"&gt;用加密货币订阅&lt;/a&gt;（加密货币付款不退款）。价格与批量方案见&lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;订阅页面&lt;/a&gt;。用 Stripe 付款，首次购买 14 天内、且成功生成少于 50 次可全额退款。已经订阅？请在 &lt;a href="https://billing.stripe.com/p/login/28obM4fZld0JaHu6oo" rel="noopener noreferrer"&gt;Stripe 客户门户&lt;/a&gt; 修改数量，无需重新购买。&lt;/p&gt;

&lt;h3&gt;
  
  
  Start using the API
&lt;/h3&gt;

&lt;p&gt;A single $15/month subscription covers every API on useapi.net — one token, all services. You connect up to 3 accounts per service, each with its own website subscription, and useapi.net handles the REST API, load balancing, and polling. Need more accounts? Each extra subscription is $10/month and adds 3 more accounts per service.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://buy.stripe.com/8x2aEX4Bd8Vh9PMg4qeUU03" rel="noopener noreferrer"&gt;Subscribe — $15/month&lt;/a&gt; &lt;a href="https://pay.boomfi.xyz/38UTma36Rv0DrY8NlH1r2SEG7VK" rel="noopener noreferrer"&gt;Pay with crypto&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;Pricing and volume options&lt;/a&gt; — full refund within the first 14 days if you have fewer than 50 successful generations. Already subscribed? Change the quantity in the &lt;a href="https://billing.stripe.com/p/login/28obM4fZld0JaHu6oo" rel="noopener noreferrer"&gt;Stripe Customer Portal&lt;/a&gt; instead of buying again.&lt;/p&gt;

&lt;h3&gt;
  
  
  Frequently asked questions
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Is there a Muse API?&lt;/strong&gt; Through useapi.net, yes: &lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-video" rel="noopener noreferrer"&gt;POST /jobs/video&lt;/a&gt; makes an MP4 of about 10 seconds at about 720p with sound, from a prompt, up to 9 images, 3 videos or 3 audio files, and a line written in quotes is spoken. Meta's official &lt;a href="https://dev.meta.ai/docs/pricing-rate-limits" rel="noopener noreferrer"&gt;Model API&lt;/a&gt; sells the Muse Image model at $0.01 per image, but as of October 2026 it has no video generation and no API for the Muse agent at muse.ai, where the videos are made.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Is there a Meta Muse API key?&lt;/strong&gt; Through useapi.net, no Meta key is needed: one useapi.net &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt; calls the Muse API, and you add your Muse account once with its email and password at &lt;a href="https://useapi.net/docs/start-here/setup-muse" rel="noopener noreferrer"&gt;Setup Muse&lt;/a&gt;. Create that account in the US or Canada, where Muse is available, and after that you can call the API from anywhere.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is a good muse2api alternative?&lt;/strong&gt; Through useapi.net, the Muse API is hosted, so there is nothing to run: no Docker, no browser extension and no cookies to push, and we keep the account signed in and renew its session. It has image and video jobs with webhooks, streamed chat with the agent, and a hosted MCP server with 37 tools.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Is there a free Muse API?&lt;/strong&gt; Through useapi.net, the Muse API works on the free Muse plan, where one account made roughly 30 to 50 videos a week in our tests. Once one account's allowance is used up, new jobs go to your other accounts, and the paid Power ($20 a month) and Maximum ($100 a month) plans raise it (as of October 2026).&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Where do my Muse videos and images go?&lt;/strong&gt; Through useapi.net, Muse runs on your Muse website subscription, so every image and video it makes also sits in that account's Library at muse.ai. The &lt;a href="https://useapi.net/docs/api-muse-v1/get-muse-assets" rel="noopener noreferrer"&gt;Library endpoints&lt;/a&gt; list and download them, and you can pass any of them into a new job by its asset id.&lt;/p&gt;

&lt;h3&gt;
  
  
  Sources
&lt;/h3&gt;

&lt;p&gt;Checked on October 18, 2026:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Meta Model API: &lt;a href="https://dev.meta.ai/docs/models" rel="noopener noreferrer"&gt;models&lt;/a&gt; (inputs and outputs of each model) and &lt;a href="https://dev.meta.ai/docs/pricing-rate-limits" rel="noopener noreferrer"&gt;pricing&lt;/a&gt; (Muse Image $0.01 per image, Muse Wonder $4 / $20 and Muse Spark $1.25 / $4.25 per million input / output tokens)&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://techcrunch.com/2026/10/12/meta-releases-its-first-frontier-model-muse-wonder" rel="noopener noreferrer"&gt;TechCrunch, October 12, 2026&lt;/a&gt;: Meta releases Muse Wonder&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://github.com/czg86389-hub/muse2api" rel="noopener noreferrer"&gt;czg86389-hub/muse2api&lt;/a&gt; README, v1.6.1: OpenAI-compatible chat, image and video endpoints, Docker Compose deployment, session cookies sent by a Chrome extension or a Tampermonkey script, MIT license&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://github.com/duclm1x1/Muse-Chat-MCP" rel="noopener noreferrer"&gt;duclm1x1/Muse-Chat-MCP&lt;/a&gt; README: a local MCP server that drives Chrome with Playwright&lt;/li&gt;
&lt;li&gt;museai.suncodevn.com &lt;a href="https://museai.suncodevn.com/api/billing/plans" rel="noopener noreferrer"&gt;plans&lt;/a&gt; and &lt;a href="https://museai.suncodevn.com/api/v1/config" rel="noopener noreferrer"&gt;request costs&lt;/a&gt;: chat 1, image 3 and video 6 credits, 20 free credits, 500 credits for $3.90, 1,000 for $15.70, 6,000 for $58.60&lt;/li&gt;
&lt;li&gt;useapi.net: the &lt;a href="https://useapi.net/docs/api-muse-v1" rel="noopener noreferrer"&gt;Muse API reference&lt;/a&gt;, &lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-video" rel="noopener noreferrer"&gt;POST /jobs/video&lt;/a&gt;, &lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-accounts" rel="noopener noreferrer"&gt;POST /accounts&lt;/a&gt; and the &lt;a href="https://useapi.net/docs/api-muse-v1/mcp" rel="noopener noreferrer"&gt;MCP server&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>metamusevideoapi</category>
      <category>museapi</category>
      <category>metamuseapi</category>
      <category>metamuseapikey</category>
    </item>
    <item>
      <title>How to Turn a Song or YouTube Link into Sheet Music with the Mureka API</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Sun, 18 Oct 2026 18:35:01 +0000</pubDate>
      <link>https://dev.to/useapi/how-to-turn-a-song-or-youtube-link-into-sheet-music-with-the-mureka-api-536b</link>
      <guid>https://dev.to/useapi/how-to-turn-a-song-or-youtube-link-into-sheet-music-with-the-mureka-api-536b</guid>
      <description>&lt;h3&gt;
  
  
  Introduction
&lt;/h3&gt;

&lt;p&gt;The useapi.net Mureka API turns a song into sheet music with one call: send one of your &lt;a href="https://www.mureka.ai" rel="noopener noreferrer"&gt;Mureka&lt;/a&gt; songs, a YouTube link or an uploaded MP3 to &lt;a href="https://useapi.net/docs/api-mureka-v1/post-mureka-music-score" rel="noopener noreferrer"&gt;POST /music/score&lt;/a&gt; and get back a zip with a MusicXML file, a staff-notation PDF and a numbered-notation PDF of the melody, chords and lyrics, for 10 Mureka Gold. It is the Score tool from mureka.ai, made callable from code, for songwriters who want a lead sheet of a song they made, teachers who need a melody on paper, and developers building music apps. useapi.net is a &lt;a href="https://useapi.net/docs/legal#affiliation--third-party-services" rel="noopener noreferrer"&gt;third-party&lt;/a&gt; API, not affiliated with Mureka or &lt;a href="https://www.kunlun.com/" rel="noopener noreferrer"&gt;Kunlun Tech&lt;/a&gt;, and it runs on your own Mureka account.&lt;/p&gt;

&lt;p&gt;This guide is one real run. We scored a 2:30 indie-pop song made earlier on the same account. The call answered in about 10 seconds, took 10 Gold off the balance (52 to 42), and the zip held a 4-page staff score, a 3-page numbered-notation score and a MusicXML file that opens in MuseScore. Every response below is from that run, with the account ids replaced.&lt;/p&gt;

&lt;h3&gt;
  
  
  Before you start
&lt;/h3&gt;

&lt;p&gt;You need a useapi.net &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt; and a Mureka account connected through &lt;a href="https://useapi.net/docs/start-here/setup-mureka" rel="noopener noreferrer"&gt;Setup Mureka&lt;/a&gt;, with at least 10 Gold left on it. The steps use &lt;code&gt;curl&lt;/code&gt;, &lt;code&gt;jq&lt;/code&gt; and two shell variables:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;USEAPI_TOKEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"user:1234-..."&lt;/span&gt;   &lt;span class="c"&gt;# your useapi.net API token&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ACCOUNT&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"12345678901234"&lt;/span&gt;        &lt;span class="c"&gt;# your Mureka account id, from GET /accounts&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;account&lt;/code&gt; can be left out when you have one Mureka account connected, or when you score a &lt;code&gt;song_id&lt;/code&gt;, which already names its account. &lt;a href="https://useapi.net/docs/api-mureka-v1/get-mureka-accounts" rel="noopener noreferrer"&gt;GET /accounts&lt;/a&gt; lists the ids.&lt;/p&gt;

&lt;h3&gt;
  
  
  Pick the source: a song, a YouTube link or an audio file
&lt;/h3&gt;

&lt;p&gt;The score endpoint takes exactly one source: a &lt;code&gt;song_id&lt;/code&gt; or a &lt;code&gt;url&lt;/code&gt;. The audio must be 10 seconds to 10 minutes long. Mureka recommends a solo song with clear vocals, a steady tempo and a consistent rhythm, and says songs with tempo changes or frequent rhythm changes are not supported well.&lt;/p&gt;

&lt;h4&gt;
  
  
  A song on your Mureka account
&lt;/h4&gt;

&lt;p&gt;Any song you made on Mureka works, whether through the API or on mureka.ai. List your songs with &lt;a href="https://useapi.net/docs/api-mureka-v1/get-mureka-music" rel="noopener noreferrer"&gt;GET /music&lt;/a&gt; to find its &lt;code&gt;song_id&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s &lt;span class="s2"&gt;"https://api.useapi.net/v1/mureka/music/?account=$ACCOUNT"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  &lt;span class="o"&gt;|&lt;/span&gt; jq -r &lt;span class="s1"&gt;'.list[] | .songs[]? | "\(.song_id)  \(.title)"'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;user:1234-mureka:12345678901234-song:33445566  Coffee Makes My Day
user:1234-mureka:12345678901234-song:33445567  Coffee Makes My Day
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Each generation makes two songs, so a title shows up twice. Pick the take you want. If you are making the song in the same script, see the job flow below.&lt;/p&gt;

&lt;h4&gt;
  
  
  A YouTube link
&lt;/h4&gt;

&lt;p&gt;Pass the YouTube link as &lt;code&gt;url&lt;/code&gt;. The API fetches the audio itself, which adds up to 15 seconds to the call. The files in the zip take the video's title unless you set &lt;code&gt;title&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;To check the length before you spend Gold, &lt;a href="https://useapi.net/docs/api-mureka-v1/get-mureka-files-youtube" rel="noopener noreferrer"&gt;GET /files/youtube&lt;/a&gt; returns the soundtrack's &lt;code&gt;duration&lt;/code&gt; in milliseconds:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s &lt;span class="s2"&gt;"https://api.useapi.net/v1/mureka/files/youtube/?account=$ACCOUNT&amp;amp;url=https://www.youtube.com/watch?v=VIDEO_ID"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; jq &lt;span class="s1"&gt;'{name, duration}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A video longer than 10 minutes needs trimming before you score it. That same call returns a &lt;code&gt;cos_url&lt;/code&gt; link to the MP3. Download it, cut the part you want, and upload it as described next. Score music you have the rights to use.&lt;/p&gt;

&lt;h4&gt;
  
  
  An audio file you upload
&lt;/h4&gt;

&lt;p&gt;Upload an MP3 with &lt;a href="https://useapi.net/docs/api-mureka-v1/post-mureka-files-vocal" rel="noopener noreferrer"&gt;POST /files/vocal&lt;/a&gt; or &lt;a href="https://useapi.net/docs/api-mureka-v1/post-mureka-files" rel="noopener noreferrer"&gt;POST /files&lt;/a&gt;, then pass the &lt;code&gt;url&lt;/code&gt; from the response. Files uploaded with POST /files/vocal stay private to your account. Files uploaded with POST /files go into Mureka's reference collection, which every Mureka user can see, and that call also needs a &lt;code&gt;genre&lt;/code&gt; and a &lt;code&gt;mood&lt;/code&gt;. For a recording you want to keep to yourself, use POST /files/vocal:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s &lt;span class="s2"&gt;"https://api.useapi.net/v1/mureka/files/vocal/?account=$ACCOUNT&amp;amp;title=my-demo"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: audio/mpeg"&lt;/span&gt; \
  --data-binary @my-demo.mp3 &lt;span class="o"&gt;|&lt;/span&gt; jq -r .url
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;code&gt;url&lt;/code&gt; is a &lt;code&gt;https://static-cos.mureka.ai/…&lt;/code&gt; link, and that is what the score call takes.&lt;/p&gt;

&lt;h3&gt;
  
  
  Make the score: one call, no job to poll
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-mureka-v1/post-mureka-music-score" rel="noopener noreferrer"&gt;POST /music/score&lt;/a&gt; waits for the result and answers with the zip link, usually in 5 to 15 seconds. Unlike song creation, there is no &lt;code&gt;jobid&lt;/code&gt; to poll. From a song:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s --max-time 120 -X POST &lt;span class="s2"&gt;"https://api.useapi.net/v1/mureka/music/score"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{ "song_id": "user:1234-mureka:12345678901234-song:33445566" }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Ours answered &lt;code&gt;200&lt;/code&gt; in 10.4 seconds:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"title"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Coffee Makes My Day"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"url"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"https://static-cos.mureka.ai/cos-prod/skm/music-staff/20261018/c8c500e3-....zip"&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;From a YouTube link or an uploaded file, send &lt;code&gt;url&lt;/code&gt; instead, with an optional &lt;code&gt;title&lt;/code&gt; for the file names (up to 100 characters):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s --max-time 120 -X POST &lt;span class="s2"&gt;"https://api.useapi.net/v1/mureka/music/score"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{
    "account": "'&lt;/span&gt;&lt;span class="s2"&gt;"$ACCOUNT"&lt;/span&gt;&lt;span class="s1"&gt;'",
    "url": "https://www.youtube.com/watch?v=VIDEO_ID",
    "title": "My Song"
  }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then download and unpack the zip:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s -o score.zip &lt;span class="s2"&gt;"https://static-cos.mureka.ai/cos-prod/skm/music-staff/20261018/c8c500e3-....zip"&lt;/span&gt;
unzip score.zip
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The score call is a paid action, so do not retry it blindly after a timeout. Give &lt;code&gt;curl&lt;/code&gt; a generous &lt;code&gt;--max-time&lt;/code&gt; and read the answer once.&lt;/p&gt;

&lt;p&gt;When the song comes from the same script, wait for its job before you score it. &lt;a href="https://useapi.net/docs/api-mureka-v1/post-mureka-music-create" rel="noopener noreferrer"&gt;POST /music/create&lt;/a&gt; with &lt;code&gt;async: true&lt;/code&gt; returns a &lt;code&gt;jobid&lt;/code&gt;, and &lt;a href="https://useapi.net/docs/api-mureka-v1/get-mureka-jobs-jobid" rel="noopener noreferrer"&gt;GET /jobs/&lt;code&gt;jobid&lt;/code&gt;&lt;/a&gt; shows &lt;code&gt;status: "completed"&lt;/code&gt; with the two songs in &lt;code&gt;response.songs[]&lt;/code&gt;. Score the &lt;code&gt;song_id&lt;/code&gt; of the take you want. The &lt;a href="https://useapi.net/docs/articles/mureka-bash" rel="noopener noreferrer"&gt;Mureka song tutorial&lt;/a&gt; covers that flow end to end.&lt;/p&gt;

&lt;h3&gt;
  
  
  What's in the zip
&lt;/h3&gt;

&lt;p&gt;Three files, named after the song's title:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Coffee Makes My Day_staff.musicxml          224,420 bytes
Coffee Makes My Day_staff.pdf                88,308 bytes
Coffee Makes My Day_numbered_notation.pdf    57,602 bytes
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;&amp;lt;title&amp;gt;_staff.musicxml&lt;/code&gt; is a MusicXML 4.0 score with two parts. &lt;code&gt;Vocal&lt;/code&gt; carries the melody with the lyrics under the notes, and &lt;code&gt;Chords&lt;/code&gt; carries the chord symbols. Ours came out in A major, 4/4, at 88 BPM, 112 measures long.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;&amp;lt;title&amp;gt;_staff.pdf&lt;/code&gt; is the same score in staff notation, ready to print. Ours ran to 4 pages.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;&amp;lt;title&amp;gt;_numbered_notation.pdf&lt;/code&gt; is the melody in numbered notation (jianpu, where &lt;code&gt;1&lt;/code&gt; is the tonic, here &lt;code&gt;1=A&lt;/code&gt;), with the chords above and the lyrics below. Ours ran to 3 pages.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Page 1 of both PDFs is in Examples. The words under the notes are transcribed from the recording, so read them against your lyrics. Our second line came out as "Leave a head of dreams behind" where the song's lyrics say "Leave the heavy dreams behind".&lt;/p&gt;

&lt;h4&gt;
  
  
  Open the MusicXML in MuseScore
&lt;/h4&gt;

&lt;p&gt;The MusicXML opens in &lt;a href="https://musescore.org" rel="noopener noreferrer"&gt;MuseScore&lt;/a&gt;, Sibelius, Finale, Dorico and most other notation software. In MuseScore Studio:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Choose File → Open and pick &lt;code&gt;&amp;lt;title&amp;gt;_staff.musicxml&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;The score opens with the &lt;code&gt;Vocal&lt;/code&gt; and &lt;code&gt;Chords&lt;/code&gt; staves, the lyrics and the chord symbols.&lt;/li&gt;
&lt;li&gt;Press play to hear the melody, fix any notes or words, transpose it with Tools → Transpose, and export it with File → Export as PDF, MIDI or audio.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Keep the zip's PDFs for a quick print, and use the MusicXML when you want to edit.&lt;/p&gt;

&lt;h3&gt;
  
  
  Limits and costs
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Limit&lt;/th&gt;
&lt;th&gt;Value&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Cost&lt;/td&gt;
&lt;td&gt;10 Mureka Gold per score, from your Mureka account&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Audio length&lt;/td&gt;
&lt;td&gt;10 seconds to 10 minutes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Time&lt;/td&gt;
&lt;td&gt;About 5 to 15 seconds, plus up to 15 seconds to fetch a YouTube link&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Source&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;song_id&lt;/code&gt; or &lt;code&gt;url&lt;/code&gt;, not both (sending both answers &lt;code&gt;400&lt;/code&gt;)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;url&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;A YouTube link, or a file URL from POST /files or POST /files/vocal, up to 2,048 characters&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;title&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Up to 100 characters, used when the source is a &lt;code&gt;url&lt;/code&gt;. A &lt;code&gt;song_id&lt;/code&gt; keeps the song's own title&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Not enough Gold&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;412&lt;/code&gt; with &lt;code&gt;User balance is not enough to operate&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Scoring the same YouTube link again returned the earlier zip, with its original file names, and was not charged in our tests. API access is a flat &lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;useapi.net subscription&lt;/a&gt; for every supported service, with no per-call charge from us, and the Gold comes from your own &lt;a href="https://www.mureka.ai/subscribe" rel="noopener noreferrer"&gt;Mureka plan&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  The same from an AI assistant
&lt;/h3&gt;

&lt;p&gt;The hosted &lt;a href="https://useapi.net/docs/api-mureka-v1/mcp" rel="noopener noreferrer"&gt;Mureka MCP server&lt;/a&gt; gives Claude Code, Cursor, VS Code and other MCP clients the whole Mureka API as 40 tools, with nothing to install. In Claude Code:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;claude mcp add --transport http useapi-mureka https://api.useapi.net/v1/mureka/mcp --header &lt;span class="s2"&gt;"Authorization: Bearer YOUR_API_TOKEN"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then ask in plain words, for example "Turn this YouTube video into sheet music" or "Make sheet music of my last song". The assistant calls &lt;code&gt;mureka_get_sheet_music&lt;/code&gt; with a &lt;code&gt;song_id&lt;/code&gt; or a &lt;code&gt;url&lt;/code&gt; and hands back the zip link. It can also make the song itself, import a YouTube link with &lt;code&gt;mureka_import_youtube&lt;/code&gt;, or upload an MP3 with &lt;code&gt;mureka_upload_vocal&lt;/code&gt;. The server is listed in the official MCP Registry as &lt;code&gt;net.useapi/mureka&lt;/code&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Examples
&lt;/h3&gt;

&lt;p&gt;What this run made, with no edits.&lt;/p&gt;

&lt;h6&gt;
  
  
  Source » "Coffee Makes My Day", Mureka V9, 2:30
&lt;/h6&gt;

&lt;p&gt;🎧 &lt;a href="https://useapi.net/docs/articles/mureka-sheet-music#examples" rel="noopener noreferrer"&gt;Play on useapi.net&lt;/a&gt;&lt;/p&gt;

&lt;h6&gt;
  
  
  POST /music/score » page 1 of each PDF
&lt;/h6&gt;

&lt;p&gt;Click a page to open the full PDF.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.useapi.net/articles/2026-10-18-mureka-sheet-music/mureka-score-coffee-makes-my-day-staff.pdf" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-18-mureka-sheet-music%2Fmureka-score-coffee-makes-my-day-staff-page1.png" alt="Mureka API sheet music: Coffee Makes My Day in staff notation, Vocal and Chords staves with lyrics, page 1 of 4" width="800" height="1132"&gt;&lt;/a&gt;&lt;/p&gt;
Staff notation, page 1 of 4



&lt;p&gt;&lt;a href="https://media.useapi.net/articles/2026-10-18-mureka-sheet-music/mureka-score-coffee-makes-my-day-numbered-notation.pdf" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-18-mureka-sheet-music%2Fmureka-score-coffee-makes-my-day-numbered-notation-page1.png" alt="Mureka API sheet music: Coffee Makes My Day in numbered (jianpu) notation with chords and lyrics, page 1 of 3" width="800" height="1131"&gt;&lt;/a&gt;&lt;/p&gt;
Numbered notation, page 1 of 3



&lt;p&gt;All three files from the zip: &lt;a href="https://media.useapi.net/articles/2026-10-18-mureka-sheet-music/mureka-score-coffee-makes-my-day-staff.pdf" rel="noopener noreferrer"&gt;staff PDF&lt;/a&gt; · &lt;a href="https://media.useapi.net/articles/2026-10-18-mureka-sheet-music/mureka-score-coffee-makes-my-day-numbered-notation.pdf" rel="noopener noreferrer"&gt;numbered notation PDF&lt;/a&gt; · &lt;a href="https://media.useapi.net/articles/2026-10-18-mureka-sheet-music/mureka-score-coffee-makes-my-day-staff.musicxml" rel="noopener noreferrer"&gt;MusicXML&lt;/a&gt;&lt;/p&gt;

&lt;h6&gt;
  
  
  From a YouTube link » "Who Is It"
&lt;/h6&gt;

&lt;p&gt;A score made from a YouTube link, from our &lt;a href="https://useapi.net/blog/261016" rel="noopener noreferrer"&gt;Mureka characters, remix and sheet music post&lt;/a&gt;, which also scores three more songs:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.useapi.net/blog/2026-10-16-261016/who-is-it-staff.pdf" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Fblog%2F2026-10-16-261016%2Fwho-is-it-staff-page1.png" alt="Who Is It, from the YouTube link, page 1 of 8" width="800" height="1131"&gt;&lt;/a&gt;&lt;/p&gt;
"Who Is It", from the YouTube link, page 1 of 8



&lt;h3&gt;
  
  
  Frequently asked questions
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Is there an audio to sheet music API?&lt;/strong&gt; Yes. &lt;a href="https://useapi.net/docs/api-mureka-v1/post-mureka-music-score" rel="noopener noreferrer"&gt;POST /music/score&lt;/a&gt; in the useapi.net Mureka API takes a song, a YouTube link or an uploaded MP3 and returns MusicXML plus staff and numbered-notation PDFs, in one call that answers in seconds.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;How do I turn a YouTube video into sheet music?&lt;/strong&gt; Send the link as &lt;code&gt;url&lt;/code&gt; to POST /music/score. The API fetches the audio, and the zip uses the video's title unless you pass &lt;code&gt;title&lt;/code&gt;. The video's audio must be 10 seconds to 10 minutes long, and &lt;a href="https://useapi.net/docs/api-mureka-v1/get-mureka-files-youtube" rel="noopener noreferrer"&gt;GET /files/youtube&lt;/a&gt; shows its length beforehand.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;How do I convert an MP3 to MusicXML?&lt;/strong&gt; Upload the MP3 with &lt;a href="https://useapi.net/docs/api-mureka-v1/post-mureka-files-vocal" rel="noopener noreferrer"&gt;POST /files/vocal&lt;/a&gt;, which keeps it private to your account, and pass the returned &lt;code&gt;url&lt;/code&gt; to POST /music/score. The &lt;code&gt;&amp;lt;title&amp;gt;_staff.musicxml&lt;/code&gt; file in the zip is the MusicXML.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Is it free?&lt;/strong&gt; No, but through useapi.net each score costs 10 Mureka Gold from your Mureka account, about 1.5 to 2 cents on a Mureka web plan, against 20 cents a song on the &lt;a href="https://platform.mureka.ai/pricing" rel="noopener noreferrer"&gt;official Mureka API&lt;/a&gt; (as of October 2026). The API answers &lt;code&gt;412&lt;/code&gt; when the balance is too low. Scoring the same YouTube link twice returned the earlier zip without a second charge in our tests. API access is a flat &lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;useapi.net subscription&lt;/a&gt;, with no per-call charge from us.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;What kind of music transcribes well?&lt;/strong&gt; A solo song with clear vocals, a steady tempo and a consistent rhythm, per Mureka. Tempo changes and frequent rhythm changes are not supported well. The score holds the main melody, the chords and the lyrics, not every instrument.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Can I get the stems or MIDI of every instrument instead?&lt;/strong&gt; That is a different tool. &lt;a href="https://useapi.net/docs/api-mureka-v1/post-mureka-music-stems" rel="noopener noreferrer"&gt;POST /music/stems&lt;/a&gt; splits one of your songs into up to 12 stems with MIDI.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;Visit our &lt;a href="https://discord.gg/w28uK3cnmF" rel="noopener noreferrer"&gt;Discord Server&lt;/a&gt; or &lt;a href="https://t.me/use_api" rel="noopener noreferrer"&gt;Telegram Channel&lt;/a&gt; for any support questions and concerns.&lt;/p&gt;

&lt;p&gt;The runnable version of this tutorial is in &lt;a href="https://github.com/useapi/mureka-api/tree/main/sheet-music" rel="noopener noreferrer"&gt;mureka-api/sheet-music&lt;/a&gt;: one Node.js or Python script that takes a song id, a YouTube link or an MP3 and saves the unzipped sheet music. The same &lt;a href="https://github.com/useapi/mureka-api" rel="noopener noreferrer"&gt;GitHub repo&lt;/a&gt; has examples for songs, lyrics and instrumentals.&lt;/p&gt;

&lt;p&gt;An AI assistant can make the sheet music for you too: the hosted &lt;a href="https://useapi.net/docs/api-mureka-v1/mcp" rel="noopener noreferrer"&gt;Mureka MCP server&lt;/a&gt; works with Claude Code, Cursor and VS Code, on your own Mureka account.&lt;/p&gt;

</description>
      <category>murekaapi</category>
      <category>sheetmusicapi</category>
      <category>audiotosheetmusicapi</category>
      <category>youtubetosheetmusic</category>
    </item>
    <item>
      <title>How to Chat with Google Flow Agent via the Google Flow API</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Sun, 18 Oct 2026 02:46:43 +0000</pubDate>
      <link>https://dev.to/useapi/how-to-chat-with-google-flow-agent-via-the-google-flow-api-467a</link>
      <guid>https://dev.to/useapi/how-to-chat-with-google-flow-agent-via-the-google-flow-api-467a</guid>
      <description>&lt;h3&gt;
  
  
  Introduction
&lt;/h3&gt;

&lt;p&gt;The useapi.net Google Flow API lets your code chat with Google Flow Agent, the creative assistant built into &lt;a href="https://flow.google.com" rel="noopener noreferrer"&gt;Google Flow&lt;/a&gt;: start a chat with one &lt;code&gt;curl&lt;/code&gt;, stream its replies, approve what it wants to spend and download the images and videos it makes. Google offers &lt;a href="https://support.google.com/labs/answer/17093911" rel="noopener noreferrer"&gt;Flow Agent&lt;/a&gt; only inside the Flow web app, with no public API (as of October 2026). useapi.net is a &lt;a href="https://useapi.net/docs/legal#affiliation--third-party-services" rel="noopener noreferrer"&gt;third-party&lt;/a&gt; API, not affiliated with Google, and the chat runs on your Google Flow account, free or paid. Chatting with the agent costs no credits, and the images and videos it makes cost the usual Flow price.&lt;/p&gt;

&lt;p&gt;This guide is one real run, start to finish. We asked the agent for two product shots of a ceramic coffee mug and a 6-second video of it, approved the spend, collected the media, then asked for a revision and rejected that one. Every response below is from that run, trimmed and with the account's email replaced.&lt;/p&gt;

&lt;p&gt;The agent plans the work itself. It picks the tools and models, guided by the project's settings, and it keeps the whole conversation on Google's side, so a chat can go on hours or days later with full context. The &lt;a href="https://useapi.net/docs/api-google-flow-v1/agent" rel="noopener noreferrer"&gt;Agent Overview&lt;/a&gt; covers every rule and limit.&lt;/p&gt;

&lt;h3&gt;
  
  
  Before you start
&lt;/h3&gt;

&lt;p&gt;You need a useapi.net &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt; and a Google account connected through &lt;a href="https://useapi.net/docs/start-here/setup-google-flow" rel="noopener noreferrer"&gt;Setup Google Flow&lt;/a&gt;. The agent works on every Google AI plan, including a free account, and what it can generate follows the account's plan, the same as &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-images" rel="noopener noreferrer"&gt;POST /images&lt;/a&gt; and &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-videos" rel="noopener noreferrer"&gt;POST /videos&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Each turn uses one captcha, solved by the API with your &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-accounts-captcha-providers" rel="noopener noreferrer"&gt;captcha providers&lt;/a&gt; or the free captcha credits of your first account. You do not send anything for it.&lt;/p&gt;

&lt;p&gt;The steps use &lt;code&gt;curl&lt;/code&gt;, &lt;code&gt;jq&lt;/code&gt; and three shell variables:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;USEAPI_TOKEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"user:12345-..."&lt;/span&gt;   &lt;span class="c"&gt;# your useapi.net API token&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;EMAIL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"john@gmail.com"&lt;/span&gt;           &lt;span class="c"&gt;# a connected Google Flow account&lt;/span&gt;
&lt;span class="nv"&gt;API&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"https://api.useapi.net/v1/google-flow/agent"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Every call below is also in the &lt;a href="https://www.postman.com/useapinet/useapi-net" rel="noopener noreferrer"&gt;Postman collection&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  How a chat works
&lt;/h3&gt;

&lt;p&gt;A turn is one message from you and everything the agent does in reply. A chat runs one turn at a time:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-agent-chats" rel="noopener noreferrer"&gt;POST /agent/chats&lt;/a&gt; starts a chat and answers &lt;code&gt;202&lt;/code&gt; with a &lt;code&gt;chatId&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-google-flow-v1/get-google-flow-agent-chats-chatId-stream" rel="noopener noreferrer"&gt;GET /agent/chats/&lt;code&gt;chatId&lt;/code&gt;/stream&lt;/a&gt; follows the agent live over Server-Sent Events.&lt;/li&gt;
&lt;li&gt;When the agent wants to spend credits, it stops and asks. &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-agent-chats-chatId-approval" rel="noopener noreferrer"&gt;POST /agent/chats/&lt;code&gt;chatId&lt;/code&gt;/approval&lt;/a&gt; answers.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-agent-chats-chatId-messages" rel="noopener noreferrer"&gt;POST /agent/chats/&lt;code&gt;chatId&lt;/code&gt;/messages&lt;/a&gt; sends the next message.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-google-flow-v1/get-google-flow-agent-chats-chatId" rel="noopener noreferrer"&gt;GET /agent/chats/&lt;code&gt;chatId&lt;/code&gt;&lt;/a&gt; reads the whole chat, with fresh media links.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Step 1: Start a chat
&lt;/h3&gt;

&lt;p&gt;Send the brief as &lt;code&gt;message&lt;/code&gt;. The call returns as soon as Google has accepted the turn, which usually takes a few seconds and can take up to about 100 seconds, so give &lt;code&gt;curl&lt;/code&gt; a 150-second timeout:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s --max-time 150 -X POST &lt;span class="s2"&gt;"$API/chats"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{
    "email": "'&lt;/span&gt;&lt;span class="s2"&gt;"$EMAIL"&lt;/span&gt;&lt;span class="s1"&gt;'",
    "message": "Create two product shots of a matte sage-green ceramic coffee mug on a light oak table in soft morning window light, square format, with Nano Banana 2.1. Then make one 6 second video of the same mug with steam slowly rising from the coffee, with Omni 1.1 Flash."
  }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Ours answered &lt;code&gt;202&lt;/code&gt; in about 10 seconds:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"chatId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"c-u12345-email:john@gmail.com-project:74262ac8-a54f-4ad7-80d7-3d44a4d6c6c1-chat:55023a0f-5e70-4545-bb4a-d878038dcf35-bot:google-flow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"email"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"john@gmail.com"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"running"&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;code&gt;chatId&lt;/code&gt; names the account and the project, so later calls need neither. It contains &lt;code&gt;:&lt;/code&gt; and &lt;code&gt;@&lt;/code&gt;, so URL-encode it in the path. Keep both forms:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;CHATID&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"c-u12345-email:john@gmail.com-project:74262ac8-...-bot:google-flow"&lt;/span&gt;
&lt;span class="nv"&gt;CHAT&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -rn --arg v &lt;span class="s2"&gt;"$CHATID"&lt;/span&gt; &lt;span class="s1"&gt;'$v|@uri'&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Without &lt;code&gt;projectId&lt;/code&gt;, the chat lives in the account's own agent project, created on its first chat and named like &lt;code&gt;My Agents Work Fri, Oct 16&lt;/code&gt;, which keeps agent work apart from your other Flow media. You can also attach up to 7 images, a video, 5 voices and 7 characters to any message with the same &lt;code&gt;@&lt;/code&gt;-mention syntax as &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-videos" rel="noopener noreferrer"&gt;POST /videos&lt;/a&gt;, see &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-agent-chats#request-body" rel="noopener noreferrer"&gt;POST /agent/chats&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 2: Stream the reply
&lt;/h3&gt;

&lt;p&gt;Open the stream with &lt;code&gt;-N&lt;/code&gt; so events print as they arrive. The browser's &lt;code&gt;EventSource&lt;/code&gt; cannot send the &lt;code&gt;Authorization&lt;/code&gt; header, so use &lt;code&gt;fetch()&lt;/code&gt; or any HTTP client in an app:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s -N &lt;span class="s2"&gt;"$API/chats/$CHAT/stream"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A new stream first sends a &lt;code&gt;chat&lt;/code&gt; event, replays the chat's history, then sends &lt;code&gt;replayed&lt;/code&gt;. Everything after &lt;code&gt;replayed&lt;/code&gt; is live. Here the first turn had already ended when we connected, so it came in the replay. The agent stated its plan, then asked for permission to spend 10 credits on 2 images and 1 video (&lt;code&gt;ui&lt;/code&gt; and other long fields left out):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight http"&gt;&lt;code&gt;&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;chat&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;"chatId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"c-u12345-email:john@gmail.com-project:74262ac8-...-bot:google-flow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"waiting_approval"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"turns"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mf"&gt;505e78d&lt;/span&gt;&lt;span class="mi"&gt;7&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;bd79&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;4938&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;b0ec&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;8117bdb933dc&lt;/span&gt;
&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;message&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"1:505e78d7-..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"items"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"I'm going to generate two images of a matte sage-green ceramic coffee mug, then I'll create a 6-second video of the same mug with rising steam using Omni 1.1 Flash."&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;00c21a03&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;a687&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;4173&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;9fd9&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;190fcdf2447b&lt;/span&gt;
&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;message&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"1:00c21a03-..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"items"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"tool_call"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"tool"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"open_chat_panel"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"args"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;"_synthetic"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"tool_call"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"tool"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"ask_for_permission"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"args"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;"num_total"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"total_cost"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"num_videos"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"num_images"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="n"&gt;approval&lt;/span&gt;
&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;approval&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"cost"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"images"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"videos"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s2"&gt;"total"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;replayed&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;"turns"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The events you act on:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Event&lt;/th&gt;
&lt;th&gt;What it means&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;message&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;One complete message of the agent: its text, thinking, tool calls and tool results&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;approval&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;The agent asks before it spends &lt;code&gt;cost&lt;/code&gt; Flow credits&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;turn&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;A turn ended: &lt;code&gt;completed&lt;/code&gt;, &lt;code&gt;waiting_approval&lt;/code&gt; or &lt;code&gt;failed&lt;/code&gt; with an &lt;code&gt;error&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;media&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;An image or video the agent made, or a change of its status, with its &lt;code&gt;url&lt;/code&gt; once &lt;code&gt;completed&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;A &lt;code&gt;keepalive&lt;/code&gt; comes every 15 seconds. One stream covers the whole chat across turns, so leave it open while you approve and send messages. If it drops, reconnect with the last &lt;code&gt;id&lt;/code&gt; in the &lt;code&gt;Last-Event-ID&lt;/code&gt; header and it picks up where it left off. A turn keeps running when you close the stream, so nothing is lost.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 3: Approve spending
&lt;/h3&gt;

&lt;p&gt;In the &lt;code&gt;ask&lt;/code&gt; approval mode the agent stops before it spends anything. The chat's &lt;code&gt;status&lt;/code&gt; is &lt;code&gt;waiting_approval&lt;/code&gt; and the &lt;code&gt;approval&lt;/code&gt; event shows the cost. Answer with &lt;code&gt;approve&lt;/code&gt;, &lt;code&gt;always&lt;/code&gt; or &lt;code&gt;reject&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s --max-time 150 -X POST &lt;span class="s2"&gt;"$API/chats/$CHAT/approval"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{ "decision": "approve" }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The answer starts a new turn, the same as a message from you:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"chatId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"c-u12345-email:john@gmail.com-project:74262ac8-...-bot:google-flow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"email"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"john@gmail.com"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"running"&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;On the open stream, turn 2 queued the video, made both images and ended within about 30 seconds. The agent's &lt;code&gt;choices&lt;/code&gt; (&lt;code&gt;Option 1&lt;/code&gt;, &lt;code&gt;Option 2&lt;/code&gt;) are the tiles the Flow web app shows for each result:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;5feb&lt;/span&gt;&lt;span class="mf"&gt;253e-0848&lt;/span&gt;&lt;span class="mi"&gt;-422a&lt;/span&gt;&lt;span class="err"&gt;-&lt;/span&gt;&lt;span class="n"&gt;bcb8&lt;/span&gt;&lt;span class="mi"&gt;-936995b3c0df&lt;/span&gt;
&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;message&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"2:5feb253e-..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"items"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"tool_result"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"tool"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"generate_video_from_text"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"result"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"queued"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"media_id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"5732c66d-a971-4cd0-92d2-508ef0aecc07"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"display_name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"Steam rising from coffee mug"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"model_key"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"abra_t2v_6s"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"aspect_ratio"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"VIDEO_ASPECT_RATIO_LANDSCAPE"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="n"&gt;m&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;5732c66d&lt;/span&gt;&lt;span class="err"&gt;-&lt;/span&gt;&lt;span class="n"&gt;a971&lt;/span&gt;&lt;span class="mi"&gt;-4cd0-92d2&lt;/span&gt;&lt;span class="mf"&gt;-508ef&lt;/span&gt;&lt;span class="mi"&gt;0aecc07&lt;/span&gt;
&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;media&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"referenceId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"user:12345-email:6a6f...-video:5732c66d-a971-4cd0-92d2-508ef0aecc07"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"mediaId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"5732c66d-a971-4cd0-92d2-508ef0aecc07"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"video"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"queued"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"tool"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"generate_video_from_text"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"abra_t2v_6s"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"displayName"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"Steam rising from coffee mug"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="n"&gt;m&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mf"&gt;377ecb&lt;/span&gt;&lt;span class="mi"&gt;33&lt;/span&gt;&lt;span class="err"&gt;-&lt;/span&gt;&lt;span class="n"&gt;ab2c&lt;/span&gt;&lt;span class="mi"&gt;-4bce-92d4-7bfcf53a9af2&lt;/span&gt;
&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;media&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"referenceId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"user:12345-email:6a6f...-image:377ecb33-ab2c-4bce-92d4-7bfcf53a9af2"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"mediaId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"377ecb33-ab2c-4bce-92d4-7bfcf53a9af2"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"image"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"completed"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"tool"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"generate_image"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"displayName"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"Ceramic coffee mug on table"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"url"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"https://flow-content.google/image/377ecb33-...?Expires=...&amp;amp;Signature=..."&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mf"&gt;4e37b&lt;/span&gt;&lt;span class="mi"&gt;051&lt;/span&gt;&lt;span class="err"&gt;-&lt;/span&gt;&lt;span class="n"&gt;c49c&lt;/span&gt;&lt;span class="mi"&gt;-4331&lt;/span&gt;&lt;span class="err"&gt;-&lt;/span&gt;&lt;span class="n"&gt;bc0c&lt;/span&gt;&lt;span class="mi"&gt;-06ccc539b950&lt;/span&gt;
&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;message&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"2:4e37b051-..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"items"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"I've generated your two product shots. Your 6-second video has been scheduled and is waiting in the queue due to high demand. Feel free to check back in a few minutes."&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="n"&gt;end&lt;/span&gt;
&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;turn&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"completed"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;always&lt;/code&gt; approves and also switches the project to the &lt;code&gt;auto&lt;/code&gt; mode, so the agent stops asking in every chat of the project. &lt;code&gt;reject&lt;/code&gt; declines, shown in step 5. Sending a new message instead of answering also moves on without generating.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 4: Get the media
&lt;/h3&gt;

&lt;p&gt;Images are ready when the turn ends. Videos usually finish a minute or two later, and the stream sends a second &lt;code&gt;media&lt;/code&gt; event for the video when it does. Ours came less than a minute after the turn ended:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="n"&gt;m&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;5732c66d&lt;/span&gt;&lt;span class="err"&gt;-&lt;/span&gt;&lt;span class="n"&gt;a971&lt;/span&gt;&lt;span class="mi"&gt;-4cd0-92d2&lt;/span&gt;&lt;span class="mf"&gt;-508ef&lt;/span&gt;&lt;span class="mi"&gt;0aecc07&lt;/span&gt;
&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;media&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"referenceId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"user:12345-email:6a6f...-video:5732c66d-a971-4cd0-92d2-508ef0aecc07"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"mediaId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"5732c66d-a971-4cd0-92d2-508ef0aecc07"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"video"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"completed"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"tool"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"generate_video_from_text"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"abra_t2v_6s"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"displayName"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"Steam rising from coffee mug"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"url"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"https://flow-content.google/video/5732c66d-...?Expires=...&amp;amp;Signature=..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"durationSec"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;6&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Download each &lt;code&gt;url&lt;/code&gt; while it is fresh:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s -L -o mug-steam.mp4 &lt;span class="s2"&gt;"https://flow-content.google/video/5732c66d-...?Expires=...&amp;amp;Signature=..."&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The links point to Google and expire about 6 hours after they are issued. Read the chat again with GET /agent/chats/&lt;code&gt;chatId&lt;/code&gt; for fresh ones, or get one item's link from &lt;a href="https://useapi.net/docs/api-google-flow-v1/get-google-flow-assets-mediagenerationid" rel="noopener noreferrer"&gt;GET /assets/&lt;code&gt;mediaGenerationId&lt;/code&gt;&lt;/a&gt; with its &lt;code&gt;referenceId&lt;/code&gt;. The &lt;code&gt;referenceId&lt;/code&gt; also works as &lt;code&gt;referenceImage_N&lt;/code&gt; or &lt;code&gt;referenceVideo_1&lt;/code&gt; in &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-images" rel="noopener noreferrer"&gt;POST /images&lt;/a&gt;, &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-videos" rel="noopener noreferrer"&gt;POST /videos&lt;/a&gt; and your next agent message. The two images and the 1280×720 video are in Examples.&lt;/p&gt;

&lt;p&gt;The run spent 10 credits: the two Nano Banana 2.1 images cost 0 on this account's plan, and the 6-second Omni 1.1 Flash video cost 10.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 5: Continue or revise
&lt;/h3&gt;

&lt;p&gt;Send the next message to the same chat. Google keeps the conversation, so the agent knows which video "the video" is:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s --max-time 150 -X POST &lt;span class="s2"&gt;"$API/chats/$CHAT/messages"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{ "message": "Nice. Revise the video: make it 8 seconds, with a slow camera push-in toward the mug while the steam rises." }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It answered &lt;code&gt;202&lt;/code&gt; with &lt;code&gt;"turn": 3&lt;/code&gt;, and the agent asked again, this time for 12 credits:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;id: 3:approval
event: approval
data: {"turn":3,"cost":12,"images":0,"videos":1,"total":1}

id: 3:end
event: turn
data: {"turn":3,"status":"waiting_approval"}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We had our video, so we declined:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s --max-time 150 -X POST &lt;span class="s2"&gt;"$API/chats/$CHAT/approval"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{ "decision": "reject" }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Turn 4 ended with a reply and no new image or video, and no credits were spent:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mf"&gt;91e06fb&lt;/span&gt;&lt;span class="mi"&gt;7&lt;/span&gt;&lt;span class="err"&gt;-&lt;/span&gt;&lt;span class="n"&gt;ba5b&lt;/span&gt;&lt;span class="mf"&gt;-4e32&lt;/span&gt;&lt;span class="err"&gt;-&lt;/span&gt;&lt;span class="n"&gt;b2a6&lt;/span&gt;&lt;span class="err"&gt;-&lt;/span&gt;&lt;span class="n"&gt;ce210be491ba&lt;/span&gt;
&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;message&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"4:91e06fb7-..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"items"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"I've cancelled that generation. Are there any changes you'd like to make to the prompt or concept before we try again?"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="n"&gt;end&lt;/span&gt;
&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;turn&lt;/span&gt;
&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="s2"&gt;"completed"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Sending a message while a turn runs answers &lt;code&gt;409&lt;/code&gt;, so wait for the &lt;code&gt;turn&lt;/code&gt; event first. To pick one of the agent's choices, send the choice's text as the next message, as the Flow web app does.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 6: Read, list, rename and delete chats
&lt;/h3&gt;

&lt;p&gt;Read the whole chat from Google at any time. Each turn carries your message, everything the agent did and the media with fresh links:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s &lt;span class="s2"&gt;"$API/chats/$CHAT"&lt;/span&gt; -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Our chat after the four turns (&lt;code&gt;agent&lt;/code&gt; items and &lt;code&gt;media&lt;/code&gt; cut down, &lt;code&gt;ui&lt;/code&gt; left out):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"chatId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"c-u12345-email:john@gmail.com-project:74262ac8-...-bot:google-flow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"email"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"john@gmail.com"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"projectId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"74262ac8-a54f-4ad7-80d7-3d44a4d6c6c1"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"title"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Sage Green Ceramic Mug Concept"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"created"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-10-18T00:47:54.000Z"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"updated"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-10-18T00:50:47.236Z"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"idle"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"pendingApproval"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"lastError"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"turns"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"message"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Create two product shots of a matte sage-green ceramic coffee mug ..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"references"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"agent"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"I'm going to generate two images of a matte sage-green ceramic coffee mug, then I'll create a 6-second video ..."&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"tool_call"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"tool"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"ask_for_permission"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"args"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"num_total"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"total_cost"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"num_videos"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"num_images"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
      &lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"media"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"message"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Approve"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"references"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"agent"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"tool_call"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"tool"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"generate_video_from_text"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"args"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"duration"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;6&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"aspect_ratio"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"16:9"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"model_display_name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Omni 1.1 Flash"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"prompt"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Cinematic product video of a matte sage-green ceramic coffee mug ..."&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"tool_call"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"tool"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"generate_image"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"args"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"aspect_ratio"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"1:1"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"prompt"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"A professional product shot of a matte sage-green ceramic coffee mug ..."&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"I've generated your two product shots. Your 6-second video has been scheduled ..."&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
      &lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"media"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"referenceId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-email:6a6f...-video:5732c66d-..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"video"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"completed"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"abra_t2v_6s"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"displayName"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Steam rising from coffee mug"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"url"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"https://flow-content.google/video/5732c66d-..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"durationSec"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;6&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"referenceId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-email:6a6f...-image:377ecb33-..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"image"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"completed"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"displayName"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Ceramic coffee mug on table"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"url"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"https://flow-content.google/image/377ecb33-..."&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"referenceId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-email:6a6f...-image:a2d3cd0c-..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"image"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"completed"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"displayName"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Ceramic coffee mug on wooden sur…"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"url"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"https://flow-content.google/image/a2d3cd0c-..."&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
      &lt;span class="p"&gt;]&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"message"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Nice. Revise the video: make it 8 seconds, ..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"references"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"agent"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"..."&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"media"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"turn"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"message"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Reject"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"references"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"agent"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"text"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"I've cancelled that generation. Are there any changes you'd like to make to the prompt or concept before we try again?"&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"media"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;]&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Google titled the chat on its own. The &lt;code&gt;status&lt;/code&gt; is &lt;code&gt;idle&lt;/code&gt; once nothing runs, and &lt;code&gt;pendingApproval&lt;/code&gt; holds the cost while the agent waits. Pass &lt;code&gt;?media=false&lt;/code&gt; for a faster read without the link refresh.&lt;/p&gt;

&lt;p&gt;List an account's chats, newest activity first. The list comes from Google, so it also holds chats started in the Flow web app in the same project, and it is how you find a lost &lt;code&gt;chatId&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s &lt;span class="s2"&gt;"$API/chats?email=$EMAIL"&lt;/span&gt; -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Rename a chat. The new title shows in the Flow web app too:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s -X PATCH &lt;span class="s2"&gt;"$API/chats/$CHAT"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{ "title": "Sage mug product shoot" }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"chatId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"c-u12345-email:john@gmail.com-project:74262ac8-...-bot:google-flow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"title"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Sage mug product shoot"&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The list then read:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"chats"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"chatId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"c-u12345-email:john@gmail.com-project:74262ac8-...-chat:55023a0f-...-bot:google-flow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"email"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"john@gmail.com"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"title"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Sage mug product shoot"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"created"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-10-18T00:47:54.000Z"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"updated"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-10-18T00:51:01.773Z"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"running"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"chatId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"c-u12345-email:john@gmail.com-project:74262ac8-...-chat:1d9d42ed-...-bot:google-flow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"email"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"john@gmail.com"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"title"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Stylish Female Character Action Sequence"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"created"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-10-17T03:50:34.000Z"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"updated"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-10-17T04:57:26.375Z"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"running"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;]&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Delete a chat's conversation. It answers &lt;code&gt;204&lt;/code&gt; with no body, the chat leaves the list and the Flow web app, and the images and videos it made stay in the project:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s -X DELETE &lt;span class="s2"&gt;"$API/chats/$CHAT"&lt;/span&gt; -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Rename and delete answer &lt;code&gt;409&lt;/code&gt; while a turn runs.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 7: Settings for approval, instructions and default models
&lt;/h3&gt;

&lt;p&gt;Each Flow project has agent settings, the same as the agent panel in the Flow web app. &lt;a href="https://useapi.net/docs/api-google-flow-v1/get-google-flow-agent-settings" rel="noopener noreferrer"&gt;GET /agent/settings&lt;/a&gt; reads them, and also lists the image and video models the account's Google plan has, with what one image or video costs on that plan:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s &lt;span class="s2"&gt;"$API/settings?email=$EMAIL"&lt;/span&gt; -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://useapi.net/docs/api-google-flow-v1/put-google-flow-agent-settings" rel="noopener noreferrer"&gt;PUT /agent/settings&lt;/a&gt; changes only the fields you send. Before the run we set the &lt;code&gt;ask&lt;/code&gt; mode and the defaults:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s -X PUT &lt;span class="s2"&gt;"$API/settings"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{
    "email": "'&lt;/span&gt;&lt;span class="s2"&gt;"$EMAIL"&lt;/span&gt;&lt;span class="s1"&gt;'",
    "approval": "ask",
    "imageDefaults": { "model": "nano-banana-2", "aspectRatio": "1:1", "count": 2 },
    "videoDefaults": { "model": "omni-flash", "aspectRatio": "16:9", "count": 1 }
  }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The response is the project's settings after the change:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"projectId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"74262ac8-a54f-4ad7-80d7-3d44a4d6c6c1"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"approval"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"ask"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"instructions"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"imageDefaults"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"nano-banana-2"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"aspectRatio"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"1:1"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"count"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"videoDefaults"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"omni-flash"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"aspectRatio"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"16:9"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"count"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"models"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"image"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"nano-banana-pro"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"label"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Nano Banana Pro"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"nano-banana-2-lite"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"label"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Nano Banana 2 Lite"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"nano-banana-2"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"label"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Nano Banana 2.1"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"video"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"omni-flash"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"label"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Omni 1.1 Flash"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;4&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"veo-3.1-lite"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"label"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Veo 3.1 - Lite"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"veo-3.1-fast"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"label"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Veo 3.1 - Fast"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;10&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"model"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"veo-3.1-quality"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"label"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Veo 3.1 - Quality"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"credits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;]&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;credits&lt;/code&gt; is the lowest cost of one image or video on the account's plan, so a longer or higher-resolution video costs more: our 6-second 720p Omni 1.1 Flash video cost 10, and the 8-second revision would have cost 12. Your plan may show different numbers. The settings fields:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;approval&lt;/code&gt;: &lt;code&gt;ask&lt;/code&gt; (the agent stops and shows the cost) or &lt;code&gt;auto&lt;/code&gt; (it spends without asking).&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;instructions&lt;/code&gt;: up to 3 standing instructions the agent follows in every chat of the project, each with optional reference images. The array replaces the project's instructions, so send the full list.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;imageDefaults&lt;/code&gt; and &lt;code&gt;videoDefaults&lt;/code&gt;: the model, aspect ratio and count the agent uses when a message does not say otherwise, picked from &lt;code&gt;models&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The settings apply to every chat in the project, including chats in the Flow web app.&lt;/p&gt;

&lt;h3&gt;
  
  
  The same from an AI assistant
&lt;/h3&gt;

&lt;p&gt;The hosted &lt;a href="https://useapi.net/docs/api-google-flow-v1/mcp" rel="noopener noreferrer"&gt;Google Flow MCP server&lt;/a&gt; gives Claude Code, Cursor, VS Code and other MCP clients the same chat as 12 tools, with nothing to install. In Claude Code:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;claude mcp add --transport http useapi-google-flow https://api.useapi.net/v1/google-flow/mcp --header &lt;span class="s2"&gt;"Authorization: Bearer YOUR_API_TOKEN"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then ask the assistant for the mug shots in plain words. The assistant sends the brief with &lt;code&gt;flow_agent_chat&lt;/code&gt; and answers the agent's request to spend credits with &lt;code&gt;flow_agent_answer_approval&lt;/code&gt;. The server is listed in the official MCP Registry as &lt;code&gt;net.useapi/google-flow&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;To see a full chat client first, open the &lt;a href="https://useapi.net/demos/google-flow/" rel="noopener noreferrer"&gt;live demo&lt;/a&gt;. Paste your API token, pick an account and chat with the agent, with its images and videos inline, attachments, approval cards and settings. Its source is five small files with no build step on GitHub in &lt;a href="https://github.com/useapi/google-flow-api/tree/main/demo" rel="noopener noreferrer"&gt;google-flow-api/demo&lt;/a&gt;, and the &lt;a href="https://useapi.net/docs/api-google-flow-v1/agent-demo" rel="noopener noreferrer"&gt;Agent Live Demo&lt;/a&gt; page maps each feature to its API call.&lt;/p&gt;

&lt;h3&gt;
  
  
  Examples
&lt;/h3&gt;

&lt;p&gt;What this run made, with no edits. The prompts are the agent's own, written from our brief.&lt;/p&gt;

&lt;h6&gt;
  
  
  Nano Banana 2.1 » two product shots of the sage-green mug (turn 2)
&lt;/h6&gt;

&lt;p&gt;&lt;/p&gt;&lt;a href="https://media.useapi.net/articles/2026-10-17-google-flow-agent-chat/flow-agent-sage-mug-shot-1-nano-banana-2-1.jpg" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-17-google-flow-agent-chat%2Fflow-agent-sage-mug-shot-1-nano-banana-2-1.jpg" alt="Google Flow Agent result: a matte sage-green ceramic mug on a light oak table in soft morning light, made with Nano Banana 2.1" width="800" height="800"&gt;&lt;/a&gt;Option 1, "Ceramic coffee mug on table"&lt;br&gt;
&lt;a href="https://media.useapi.net/articles/2026-10-17-google-flow-agent-chat/flow-agent-sage-mug-shot-2-nano-banana-2-1.jpg" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-17-google-flow-agent-chat%2Fflow-agent-sage-mug-shot-2-nano-banana-2-1.jpg" alt="Google Flow Agent result: a close-up of the sage-green mug with coffee, a brass spoon and an open book in morning sun, made with Nano Banana 2.1" width="800" height="800"&gt;&lt;/a&gt;Option 2, the close-up&lt;p&gt;&lt;/p&gt;

&lt;p&gt;Both 1024×1024 JPEG, 0 credits on this account's plan.&lt;/p&gt;

&lt;h6&gt;
  
  
  Omni 1.1 Flash » 6 seconds of steam rising from the mug (turn 2)
&lt;/h6&gt;



&lt;p&gt;1280×720 with sound, 6 seconds, 10 credits.&lt;/p&gt;

&lt;p&gt;Related tutorials: &lt;a href="https://useapi.net/docs/articles/google-flow-bash" rel="noopener noreferrer"&gt;Veo 3.1 video via the Google Flow API&lt;/a&gt;, &lt;a href="https://useapi.net/docs/articles/omni-flash-bash" rel="noopener noreferrer"&gt;audio-native video with Omni Flash&lt;/a&gt; and &lt;a href="https://useapi.net/docs/articles/google-flow-images-bash" rel="noopener noreferrer"&gt;Nano Banana images via the Google Flow API&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Frequently asked questions
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Is there a Google Flow Agent API?&lt;/strong&gt; Through useapi.net, yes: the &lt;a href="https://useapi.net/docs/api-google-flow-v1/agent" rel="noopener noreferrer"&gt;Agent API&lt;/a&gt; starts chats, streams the replies over Server-Sent Events, answers approvals and returns the images and videos, on every Google AI subscription, a free account included. Google offers &lt;a href="https://support.google.com/labs/answer/17093911" rel="noopener noreferrer"&gt;Flow Agent&lt;/a&gt; only inside the Flow web app, with no public API of its own (as of October 2026).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;How much does chatting with Google Flow Agent cost?&lt;/strong&gt; Through useapi.net, chatting costs no Flow credits, and what the agent makes costs the usual Flow price, which the &lt;code&gt;ask&lt;/code&gt; mode shows before anything is spent. The 6-second 720p Omni 1.1 Flash video in this run comes to $0.08 on Google AI Ultra $199.99, against $0.61 on the official &lt;a href="https://ai.google.dev/gemini-api/docs/pricing" rel="noopener noreferrer"&gt;Gemini API&lt;/a&gt; (as of October 2026).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Do chats started in the Flow web app show up in the API?&lt;/strong&gt; Through useapi.net, yes, when they are in the same project. &lt;a href="https://useapi.net/docs/api-google-flow-v1/get-google-flow-agent-chats" rel="noopener noreferrer"&gt;GET /agent/chats&lt;/a&gt; lists them, and every endpoint above works on them. Chats started through the API show up in the web app too. Pass &lt;code&gt;projectId&lt;/code&gt; from &lt;a href="https://useapi.net/docs/api-google-flow-v1/get-google-flow-assets-projects-email" rel="noopener noreferrer"&gt;GET /assets/projects/&lt;code&gt;email&lt;/code&gt;&lt;/a&gt; to work in a project other than the agent's own.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Can I get a webhook instead of holding a stream open?&lt;/strong&gt; Through useapi.net, yes. Pass &lt;code&gt;replyUrl&lt;/code&gt; to &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-agent-chats#callback" rel="noopener noreferrer"&gt;POST /agent/chats&lt;/a&gt;, the messages call or the approval call, and the API sends one &lt;code&gt;POST&lt;/code&gt; with the turn's messages, media, status and any pending approval when the turn ends. Videos usually arrive there still &lt;code&gt;queued&lt;/code&gt;, so get their links from GET or the stream's &lt;code&gt;media&lt;/code&gt; events.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;What are the limits?&lt;/strong&gt; Through useapi.net a chat runs one turn at a time, an account runs at most 3 turns at once, and a turn lasts up to 10 minutes, which is Google's own limit. Google also caps agent messages per account per day without publishing the number, and the API answers &lt;code&gt;429&lt;/code&gt; for that account until midnight UTC. See &lt;a href="https://useapi.net/docs/api-google-flow-v1/agent#limits" rel="noopener noreferrer"&gt;Limits&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;Visit our &lt;a href="https://discord.gg/w28uK3cnmF" rel="noopener noreferrer"&gt;Discord Server&lt;/a&gt; or &lt;a href="https://t.me/use_api" rel="noopener noreferrer"&gt;Telegram Channel&lt;/a&gt; for any support questions and concerns.&lt;/p&gt;

&lt;p&gt;Check our &lt;a href="https://github.com/useapi/google-flow-api" rel="noopener noreferrer"&gt;GitHub repo&lt;/a&gt; with code examples, including the agent chat client in &lt;a href="https://github.com/useapi/google-flow-api/tree/main/demo" rel="noopener noreferrer"&gt;&lt;code&gt;demo/&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;An AI assistant can chat with Google Flow Agent for you too: the hosted &lt;a href="https://useapi.net/docs/api-google-flow-v1/mcp" rel="noopener noreferrer"&gt;Google Flow MCP server&lt;/a&gt; works with Claude Code, Cursor and VS Code, on your Google Flow account.&lt;/p&gt;

</description>
      <category>googleflowagentapi</category>
      <category>googleflowagent</category>
      <category>flowagentapi</category>
      <category>googleflowapi</category>
    </item>
    <item>
      <title>NotebookLM API Options in 2026: Google Enterprise API, Free Libraries or a Hosted API</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Fri, 16 Oct 2026 21:18:44 +0000</pubDate>
      <link>https://dev.to/useapi/notebooklm-api-options-in-2026-google-enterprise-api-free-libraries-or-a-hosted-api-3cch</link>
      <guid>https://dev.to/useapi/notebooklm-api-options-in-2026-google-enterprise-api-free-libraries-or-a-hosted-api-3cch</guid>
      <description>&lt;h3&gt;
  
  
  Does NotebookLM have an API?
&lt;/h3&gt;

&lt;p&gt;Not for regular Google accounts. Google renamed NotebookLM to Gemini Notebook in July 2026, and its only official API is the &lt;a href="https://docs.cloud.google.com/gemini/enterprise/notebooklm-enterprise/docs/api-notebooks" rel="noopener noreferrer"&gt;Gemini Notebook Enterprise API&lt;/a&gt;: a Preview API for Enterprise licenses in a Google Cloud project, which manages notebooks and sources and creates Audio Overviews.&lt;/p&gt;

&lt;p&gt;If you want to automate NotebookLM on an ordinary free or paid Google account, there are three kinds of options:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Google's Enterprise API&lt;/strong&gt;, if your organisation buys Enterprise licenses.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Free open-source libraries and local MCP servers&lt;/strong&gt;, such as &lt;a href="https://github.com/teng-lin/notebooklm-py" rel="noopener noreferrer"&gt;notebooklm-py&lt;/a&gt; and &lt;a href="https://github.com/jacob-bd/gemini-notebook-mcp-cli" rel="noopener noreferrer"&gt;gemini-notebook-mcp-cli&lt;/a&gt;, which you install and run on your own machine.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;A hosted API&lt;/strong&gt;, such as the &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1" rel="noopener noreferrer"&gt;useapi.net NotebookLM API (Gemini Notebook API)&lt;/a&gt;, which runs on our servers with your own Google account, over REST and as a hosted &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/mcp" rel="noopener noreferrer"&gt;MCP server&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;This page is written by the useapi.net maintainers and compares what each option offers from its own documentation.&lt;/p&gt;

&lt;h3&gt;
  
  
  Compared
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;useapi.net&lt;/th&gt;
&lt;th&gt;notebooklm-py&lt;/th&gt;
&lt;th&gt;gemini-notebook-mcp-cli&lt;/th&gt;
&lt;th&gt;Google Enterprise API&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Hosted, nothing to install or run locally&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Hosted MCP server for Claude Code, Cursor, VS Code&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;❌ (local only)&lt;/td&gt;
&lt;td&gt;❌ (local only)&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Works on free and paid consumer Google accounts&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Sign-in without copying cookies; session kept fresh for you&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;REST API from any language&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Webhook when a job finishes&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Automatic load balancing across Google accounts&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Ready-to-import n8n templates&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Price&lt;/td&gt;
&lt;td&gt;$15/month, every useapi.net API&lt;/td&gt;
&lt;td&gt;Free&lt;/td&gt;
&lt;td&gt;Free&lt;/td&gt;
&lt;td&gt;Enterprise licenses&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;small&gt;From each project's own documentation on October 16, 2026: notebooklm-py v0.8.5, gemini-notebook-mcp-cli v0.15.5, Gemini Notebook Enterprise API (Preview). useapi.net is a third-party API and is not affiliated with Google.&lt;/small&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Why useapi.net instead of a free library
&lt;/h3&gt;

&lt;p&gt;useapi.net is a third-party API and is not affiliated with Google.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Nothing to run on your machine.&lt;/strong&gt; The API is hosted, so jobs keep running when your laptop is off: no Chromium download, no local server, no tunnel and no browser left open.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Sign in once, we keep you signed in.&lt;/strong&gt; The guided browser &lt;a href="https://useapi.net/docs/start-here/setup-gemini-notebook" rel="noopener noreferrer"&gt;setup&lt;/a&gt; connects your Google account once, and we keep the session fresh, with no cookies to copy or refresh. If Google ever signs it out, you get an email with a one-minute re-add link.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;A hosted &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/mcp" rel="noopener noreferrer"&gt;MCP server&lt;/a&gt;, 56 tools.&lt;/strong&gt; Add it to Claude Code, Cursor or VS Code with one line. Nothing to install, and every notebook, source, chat and Studio output is available to your AI assistant.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Plain REST from any language.&lt;/strong&gt; Call it from Node.js, Python, bash, n8n, Make or a cron job with an API token. A Postman collection and an LLM-friendly spec cover every endpoint.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Jobs tracked for you, with webhooks.&lt;/strong&gt; Every podcast, video, slide deck and research run is a server-side job. Poll it, or pass &lt;code&gt;replyUrl&lt;/code&gt; and get the finished result posted to your endpoint.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Several Google accounts, balanced automatically.&lt;/strong&gt; Connect 3 accounts per subscription, up to 100; each new job goes to one that is healthy, has a free slot and still has usage left.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Links in, podcast out.&lt;/strong&gt; Send URLs or text to one endpoint and get an Audio Overview, Video Overview, slide deck or quiz back, with no notebook setup.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Ready-made &lt;a href="https://n8n.io/workflows/20476" rel="noopener noreferrer"&gt;n8n workflows&lt;/a&gt; and an agent skill&lt;/strong&gt;, on your free or paid Google plan, for a flat &lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;$15/month&lt;/a&gt; that covers every useapi.net API.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  What the useapi.net NotebookLM API covers
&lt;/h3&gt;

&lt;p&gt;Everything you do in NotebookLM, from code:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Notebooks and sources.&lt;/strong&gt; Create, copy and share notebooks and group them in collections. Add web pages, YouTube videos, pasted text, uploaded files (PDF, Word, PowerPoint, EPUB, audio, video), Google Drive files and ebooks from your Google Play Books library.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Chat with citations.&lt;/strong&gt; Ask questions grounded in your sources, with numbered citations and follow-up conversations.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Research.&lt;/strong&gt; Discover sources and run Deep Research, then import the sources and the report.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Every Studio output.&lt;/strong&gt; Audio Overviews (deep dive, brief, critique, debate), Video Overviews (including short and cinematic), slide decks, infographics, reports, data tables, quizzes, flashcards and mind maps, with revise, retry, copy and export.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Usage you can see.&lt;/strong&gt; Each account's live usage in Google's 5-hour and weekly windows.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The full list is in the &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1" rel="noopener noreferrer"&gt;API reference&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  How to start
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Get a useapi.net &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Connect a Google account once with the guided &lt;a href="https://useapi.net/docs/start-here/setup-gemini-notebook" rel="noopener noreferrer"&gt;NotebookLM setup&lt;/a&gt;. The free Google plan works.&lt;/li&gt;
&lt;li&gt;Turn a web page into a podcast with one call:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-X&lt;/span&gt; POST https://api.useapi.net/v1/gemini-notebook/artifacts &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"Authorization: Bearer &lt;/span&gt;&lt;span class="nv"&gt;$USEAPI_TOKEN&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="s1"&gt;'{"type": "audio", "urls": ["https://en.wikipedia.org/wiki/Apollo_11"]}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Or add the &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/mcp" rel="noopener noreferrer"&gt;MCP server&lt;/a&gt; to Claude Code with one line:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;claude mcp add &lt;span class="nt"&gt;--transport&lt;/span&gt; http useapi-gemini-notebook https://api.useapi.net/v1/gemini-notebook/mcp &lt;span class="nt"&gt;--header&lt;/span&gt; &lt;span class="s2"&gt;"Authorization: Bearer YOUR_API_TOKEN"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Step-by-step tutorials: &lt;a href="https://useapi.net/docs/articles/gemini-notebook-bash" rel="noopener noreferrer"&gt;Deep Research, chat and Audio Overviews with curl&lt;/a&gt;, &lt;a href="https://useapi.net/docs/articles/notebooklm-podcast-example" rel="noopener noreferrer"&gt;a real podcast example&lt;/a&gt; and &lt;a href="https://useapi.net/docs/articles/notebooklm-n8n-podcast" rel="noopener noreferrer"&gt;RSS feeds to podcasts with n8n&lt;/a&gt;. Runnable code: &lt;a href="https://github.com/useapi/notebooklm-api" rel="noopener noreferrer"&gt;useapi/notebooklm-api&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Start using the API
&lt;/h3&gt;

&lt;p&gt;A single &lt;strong&gt;$15/month&lt;/strong&gt; subscription covers every API on useapi.net — one token, all services. You connect up to 3 of your own provider accounts per service, and useapi.net handles the REST API, load balancing, and polling.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://buy.stripe.com/8x2aEX4Bd8Vh9PMg4qeUU03" rel="noopener noreferrer"&gt;Subscribe — $15/month&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;Pricing, crypto payment, and volume options&lt;/a&gt; — full refund within the first 14 days if you have fewer than 50 successful generations.&lt;/p&gt;

&lt;h3&gt;
  
  
  Frequently asked questions
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Is there a free NotebookLM API?&lt;/strong&gt; Google offers no free API for regular accounts. Free open-source libraries exist and run on your own machine. The useapi.net API is $15/month, works on the free Google plan, and has a full refund within 14 days if you made fewer than 50 successful generations.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Is there a NotebookLM API key?&lt;/strong&gt; Not from Google for regular accounts. With useapi.net you use a useapi.net API token and connect your Google account once.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I use NotebookLM from Python?&lt;/strong&gt; Yes. The useapi.net API is plain REST, so any HTTP client works. The &lt;a href="https://github.com/useapi/notebooklm-api" rel="noopener noreferrer"&gt;examples repository&lt;/a&gt; has Node.js, Python and bash scripts and a Colab notebook.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Is there a NotebookLM MCP server?&lt;/strong&gt; Yes. The hosted &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/mcp" rel="noopener noreferrer"&gt;useapi.net NotebookLM MCP server&lt;/a&gt; has 56 tools and is listed in the official MCP Registry as &lt;code&gt;net.useapi/gemini-notebook&lt;/code&gt;. You add it to Claude Code, Cursor or VS Code with one line, with nothing to install.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Do I have to copy cookies or keep a browser open?&lt;/strong&gt; No. You sign in once through the guided setup, and we keep the session fresh. If Google ever signs the account out, you get an email with a link to re-add it.&lt;/p&gt;

</description>
      <category>notebooklm</category>
      <category>api</category>
      <category>mcp</category>
      <category>ai</category>
    </item>
    <item>
      <title>How to Generate AI Images and Videos with the Muse API</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Mon, 12 Oct 2026 06:14:53 +0000</pubDate>
      <link>https://dev.to/useapi/how-to-generate-ai-images-and-videos-with-the-muse-api-274</link>
      <guid>https://dev.to/useapi/how-to-generate-ai-images-and-videos-with-the-muse-api-274</guid>
      <description>&lt;h3&gt;
  
  
  Introduction
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;The &lt;a href="https://useapi.net/docs/api-muse-v1" rel="noopener noreferrer"&gt;useapi.net Muse API&lt;/a&gt; drives &lt;a href="https://muse.ai" rel="noopener noreferrer"&gt;Muse&lt;/a&gt;, Meta's personal AI agent, from code: one POST makes an image or a 10-second video with spoken dialogue, and every file it makes is an &lt;a href="https://useapi.net/docs/api-muse-v1/get-muse-assets-assetId" rel="noopener noreferrer"&gt;asset id&lt;/a&gt; the next job can take as an input.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The API runs on your own Muse account, and the free plan works. This walkthrough takes three ordinary photos, a vintage BMW motorcycle, a red-haired rider and the beach below the Golden Gate Bridge, and turns them into one picture of her riding that motorcycle through the surf. The picture then becomes a video in which she shouts a line, and in a third job a different woman, taken from a fourth photo, replaces her in that video while the ride stays the same. Along the way it makes images from text, and it restores and colorizes a hundred-year-old portrait that then looks up and speaks. Every request below is the one that made the media on this page.&lt;/p&gt;



&lt;p&gt;&lt;small&gt;The rider from a photo, swapped into a clip Muse made from a still image (step 8).&lt;/small&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  What it cost
&lt;/h3&gt;

&lt;p&gt;useapi.net is an API, not an image or video service of its own. Every call runs on a Muse account you add through &lt;a href="https://useapi.net/docs/start-here/setup-muse" rel="noopener noreferrer"&gt;Setup Muse&lt;/a&gt;, and uses that account's weekly Muse allowance. Muse reports it as a whole percent used, so a single image often shows no change. You pay useapi.net a flat &lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;$15/month&lt;/a&gt; for every API we offer, with no per-image or per-video charge.&lt;/p&gt;

&lt;p&gt;What each step used on the free plan, taken from &lt;code&gt;percentUsed&lt;/code&gt; before and after it, and how long each job took:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Step&lt;/th&gt;
&lt;th&gt;Endpoint&lt;/th&gt;
&lt;th&gt;Output&lt;/th&gt;
&lt;th&gt;Allowance used&lt;/th&gt;
&lt;th&gt;Time&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Text to image, 9:16&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-image" rel="noopener noreferrer"&gt;POST /jobs/image&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;1152×2048&lt;/td&gt;
&lt;td&gt;not measured&lt;/td&gt;
&lt;td&gt;30 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Text to image, exactly 16:9&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-image" rel="noopener noreferrer"&gt;POST /jobs/image&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;2048×1152&lt;/td&gt;
&lt;td&gt;0%&lt;/td&gt;
&lt;td&gt;21 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Rider + motorcycle + beach&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-image" rel="noopener noreferrer"&gt;POST /jobs/image&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;2048×1152&lt;/td&gt;
&lt;td&gt;0%&lt;/td&gt;
&lt;td&gt;31 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;The ride as a video&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-video" rel="noopener noreferrer"&gt;POST /jobs/video&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;1280×720, 10 s&lt;/td&gt;
&lt;td&gt;3%&lt;/td&gt;
&lt;td&gt;88 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Restore an old photo&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-image" rel="noopener noreferrer"&gt;POST /jobs/image&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;1344×1792&lt;/td&gt;
&lt;td&gt;1%&lt;/td&gt;
&lt;td&gt;34 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;The portrait speaks&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-video" rel="noopener noreferrer"&gt;POST /jobs/video&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;832×1104, 10 s&lt;/td&gt;
&lt;td&gt;2%&lt;/td&gt;
&lt;td&gt;68 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Swap the rider&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-video" rel="noopener noreferrer"&gt;POST /jobs/video&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;1248×704, 10 s&lt;/td&gt;
&lt;td&gt;3%&lt;/td&gt;
&lt;td&gt;138 s&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Uploads use no allowance. On the free plan a video used 2 to 3 percent of the week and an image 0 to 1 percent, so one free account makes roughly 30 to 50 videos a week, or several hundred images (step 9).&lt;/p&gt;

&lt;h3&gt;
  
  
  Before you start
&lt;/h3&gt;

&lt;p&gt;You need a useapi.net &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt; and a Muse account added through &lt;a href="https://useapi.net/docs/start-here/setup-muse" rel="noopener noreferrer"&gt;Setup Muse&lt;/a&gt;. Before you add the account:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Finish Muse's onboarding at &lt;a href="https://muse.ai" rel="noopener noreferrer"&gt;muse.ai&lt;/a&gt;, including Meta's age check, and create one image there.&lt;/li&gt;
&lt;li&gt;The account must have email + password sign-in, because the API signs in with the email and password. A Meta account that signs in only with an emailed code has no password yet: create one in &lt;a href="https://accountscenter.meta.com/password_and_security/" rel="noopener noreferrer"&gt;Meta Accounts Center&lt;/a&gt; (Password and security), then add the account here. Without a password the add is refused with &lt;code&gt;400&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Use the account only for the API, with no other automation tools on it. Opening it at muse.ai in a browser is fine.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Every call is also in the &lt;a href="https://useapi.net/assets/postman/muse-v1.json" rel="noopener noreferrer"&gt;Postman collection&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Also in Chinese: &lt;a href="https://useapi.net/docs/articles/muse-api-zh" rel="noopener noreferrer"&gt;中文教程&lt;/a&gt;. The whole walkthrough is also on GitHub as one script, in Node.js and Python: &lt;a href="https://github.com/useapi/muse-api/tree/main/images-videos" rel="noopener noreferrer"&gt;&lt;code&gt;images-videos/&lt;/code&gt;&lt;/a&gt; in &lt;a href="https://github.com/useapi/muse-api" rel="noopener noreferrer"&gt;useapi/muse-api&lt;/a&gt;, plus an &lt;a href="https://github.com/useapi/muse-api/tree/main/skills/muse-video" rel="noopener noreferrer"&gt;agent skill&lt;/a&gt; for Claude Code and Codex.&lt;/p&gt;

&lt;p&gt;The steps use &lt;code&gt;curl&lt;/code&gt;, &lt;code&gt;jq&lt;/code&gt; and these variables and helpers:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;USEAPI_TOKEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"user:12345-..."&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;EMAIL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"example@gmail.com"&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;MUSE_PASSWORD&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"..."&lt;/span&gt;   &lt;span class="c"&gt;# the Muse account password, used once in step 1&lt;/span&gt;
&lt;span class="nv"&gt;API&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;https://api.useapi.net/v1/muse
&lt;span class="nv"&gt;AUTH&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt;
enc&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt; jq -rn --arg v &lt;span class="s2"&gt;"$1"&lt;/span&gt; &lt;span class="s1"&gt;'$v|@uri'&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="o"&gt;}&lt;/span&gt;
post&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt; curl -sS -X POST &lt;span class="s2"&gt;"$API/$1"&lt;/span&gt; -H &lt;span class="s2"&gt;"$AUTH"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; -d &lt;span class="s2"&gt;"$2"&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="o"&gt;}&lt;/span&gt;
get&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt; curl -sS &lt;span class="s2"&gt;"$API/$1"&lt;/span&gt; -H &lt;span class="s2"&gt;"$AUTH"&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="o"&gt;}&lt;/span&gt;
upload&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt; curl -sS -X POST &lt;span class="s2"&gt;"$API/assets?email=$(enc "&lt;/span&gt;&lt;span class="nv"&gt;$EMAIL&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt; -H &lt;span class="s2"&gt;"$AUTH"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: $2"&lt;/span&gt; --data-binary @&lt;span class="s2"&gt;"$1"&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; jq -r .assetId&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="o"&gt;}&lt;/span&gt;
download&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt; curl -sSf &lt;span class="s2"&gt;"$API/assets/$(enc "&lt;/span&gt;&lt;span class="nv"&gt;$1&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt; -H &lt;span class="s2"&gt;"$AUTH"&lt;/span&gt; -o &lt;span class="s2"&gt;"$2"&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="o"&gt;}&lt;/span&gt;

&lt;span class="c"&gt;# run a job async: submit it, poll GET /jobs/{jobid} every 10 s, save the final job record to $1&lt;/span&gt;
run&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;local&lt;/span&gt; job id
  &lt;span class="nv"&gt;job&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;post &lt;span class="s2"&gt;"$2"&lt;/span&gt; &lt;span class="s2"&gt;"$(jq '. + {async: true}' &amp;lt;&amp;lt;&amp;lt; "&lt;/span&gt;&lt;span class="nv"&gt;$3&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
  &lt;span class="nv"&gt;id&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r .jobid &lt;span class="o"&gt;&amp;lt;&amp;lt;&amp;lt;&lt;/span&gt; &lt;span class="s2"&gt;"$job"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
  &lt;span class="k"&gt;while&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt; &lt;span class="s2"&gt;"$(jq -r .status &amp;lt;&amp;lt;&amp;lt; "&lt;/span&gt;&lt;span class="nv"&gt;$job&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; started &lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="k"&gt;do&lt;/span&gt;
    sleep 10
    &lt;span class="nv"&gt;job&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;get &lt;span class="s2"&gt;"jobs/$(enc "&lt;/span&gt;&lt;span class="nv"&gt;$id&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
  &lt;span class="k"&gt;done&lt;/span&gt;
  &lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"$job"&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="s2"&gt;"$1"&lt;/span&gt;
  jq &lt;span class="s1"&gt;'{status, error, text: .result.text, asset: .result.assets[0].assetId}'&lt;/span&gt; &lt;span class="s2"&gt;"$1"&lt;/span&gt;
&lt;span class="o"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Every generation runs as a job. Without &lt;code&gt;async&lt;/code&gt;, a POST waits up to about 100 seconds and returns the finished job record, or &lt;code&gt;202&lt;/code&gt; with the job still running. A video here took 68 to 138 seconds, so &lt;code&gt;run&lt;/code&gt; sends every job with &lt;code&gt;async: true&lt;/code&gt; and polls &lt;a href="https://useapi.net/docs/api-muse-v1/get-muse-jobs-jobid" rel="noopener noreferrer"&gt;GET /jobs/&lt;code&gt;jobid&lt;/code&gt;&lt;/a&gt;. If &lt;code&gt;run&lt;/code&gt; prints any &lt;code&gt;status&lt;/code&gt; other than &lt;code&gt;completed&lt;/code&gt;, read its &lt;code&gt;error&lt;/code&gt; before going on.&lt;/p&gt;

&lt;p&gt;To be called back instead of polling, add &lt;code&gt;replyUrl: "https://example.com/hooks/muse"&lt;/code&gt; (and optionally &lt;code&gt;replyRef&lt;/code&gt;) to any body below. The API then sends one &lt;code&gt;POST&lt;/code&gt; of the final job record, as JSON, to that URL.&lt;/p&gt;

&lt;p&gt;Ids contain &lt;code&gt;:&lt;/code&gt; and &lt;code&gt;@&lt;/code&gt;, so &lt;code&gt;enc&lt;/code&gt; URL-encodes them whenever they go into a URL path. All inputs of one job must live on the same Muse account, so the uploads pin &lt;code&gt;email&lt;/code&gt;, and a job runs on the account that holds its inputs.&lt;/p&gt;

&lt;h3&gt;
  
  
  How it was built
&lt;/h3&gt;

&lt;h4&gt;
  
  
  1. Add the account
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-accounts" rel="noopener noreferrer"&gt;POST /accounts&lt;/a&gt; takes the Muse account's email and password. The API signs in once, keeps the 30-day session and renews it itself. Muse emails the account a login code at each sign-in. That email is only a notice, nothing needs to be entered.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;post accounts &lt;span class="s2"&gt;"$(jq -n --arg email "&lt;/span&gt;&lt;span class="nv"&gt;$EMAIL&lt;/span&gt;&lt;span class="s2"&gt;" --arg password "&lt;/span&gt;&lt;span class="nv"&gt;$MUSE_PASSWORD&lt;/span&gt;&lt;span class="s2"&gt;" '{email: $email, password: $password}')"&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; jq &lt;span class="s1"&gt;'{health, maxJobs, quota}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The answer shows &lt;code&gt;health: "OK"&lt;/code&gt;, &lt;code&gt;maxJobs&lt;/code&gt; (2 by default) and the account's plan and usage, here &lt;code&gt;tier: "HATCH_FREE"&lt;/code&gt;, the free plan. If it answers &lt;code&gt;596&lt;/code&gt; instead, Meta wants a security check: sign in once at muse.ai in a browser, complete it, and post the same email and password again.&lt;/p&gt;

&lt;h4&gt;
  
  
  2. Upload the photos
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-assets" rel="noopener noreferrer"&gt;POST /assets&lt;/a&gt; takes the raw file as the body, up to 8.6 MB, and writes it into the account's Muse workspace. Nothing is stored at useapi.net. The answer's &lt;code&gt;assetId&lt;/code&gt; is what a job takes as &lt;code&gt;image_N&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;BMW&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;upload bmw.jpeg image/jpeg&lt;span class="o"&gt;)&lt;/span&gt;
&lt;span class="nv"&gt;RIDER&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;upload rider.jpeg image/jpeg&lt;span class="o"&gt;)&lt;/span&gt;
&lt;span class="nv"&gt;BEACH&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;upload beach.jpeg image/jpeg&lt;span class="o"&gt;)&lt;/span&gt;
&lt;span class="nv"&gt;OLD_PHOTO&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;upload old-photo.jpeg image/jpeg&lt;span class="o"&gt;)&lt;/span&gt;
&lt;span class="nv"&gt;PINK&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;upload pink-hair.jpeg image/jpeg&lt;span class="o"&gt;)&lt;/span&gt;
&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"$BMW"&lt;/span&gt;
&lt;span class="c"&gt;# user:12345-email:6578616d706c6540676d61696c2e636f6d-image:7db53e7a1f0979cbab6ff46ec3f0a35b60e6ee579a0d738a9628cf46a0c7a0f5.jpg&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;/p&gt;&lt;a href="https://media.useapi.net/articles/2026-10-12-muse-api-zh/muse-input-motorcycle.jpg" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-input-motorcycle.jpg" alt="&lt;code&gt;image_1&lt;/code&gt; — the motorcycle&amp;quot;&gt;&lt;/a&gt;&lt;figcaption&gt;&lt;code&gt;image_1&lt;/code&gt; — the motorcycle&lt;/figcaption&gt;&lt;br&gt;
&lt;a href=" rel="noopener noreferrer" width="800" height="450"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-input-redhead.jpg" alt="&lt;code&gt;image_2&lt;/code&gt; — the rider&amp;quot;&gt;&lt;/a&gt;&lt;figcaption&gt;&lt;code&gt;image_2&lt;/code&gt; — the rider&lt;/figcaption&gt;&lt;br&gt;
&lt;a href=" rel="noopener noreferrer" width="768" height="1344"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-input-beach.jpg" alt="&lt;code&gt;image_3&lt;/code&gt; — the beach&amp;quot;&gt;&lt;/a&gt;&lt;figcaption&gt;&lt;code&gt;image_3&lt;/code&gt; — the beach&lt;/figcaption&gt;&lt;br&gt;
&lt;a href=" rel="noopener noreferrer" width="800" height="534"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-input-oldphoto.jpg" alt="the old portrait" width="685" height="900"&gt;&lt;/a&gt;the old portrait&lt;br&gt;
&lt;a href="https://media.useapi.net/articles/2026-10-12-muse-api-zh/muse-input-pinkhair.webp" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-input-pinkhair.webp" alt="the second rider" width="768" height="1344"&gt;&lt;/a&gt;the second rider&lt;p&gt;&lt;/p&gt;

&lt;p&gt;&lt;small&gt;The five inputs: the motorcycle, the rider, the beach, the old portrait and the second rider.&lt;/small&gt;&lt;/p&gt;

&lt;p&gt;The asset id is built from the file's content, so uploading the same file to the same account again returns the same id and writes nothing.&lt;/p&gt;

&lt;h4&gt;
  
  
  3. Images from text
&lt;/h4&gt;

&lt;p&gt;Muse has no aspect-ratio parameter: the prompt says it. A vertical portrait first:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;run portrait.json jobs/image &lt;span class="s2"&gt;"$(jq -n '{prompt: "&lt;/span&gt;Vertical 9:16 full-body portrait photo: a confident young woman biker with long wavy fiery red hair, green eyes and freckles, &lt;span class="k"&gt;in&lt;/span&gt; a worn black leather jacket, dark jeans and boots, standing &lt;span class="k"&gt;in&lt;/span&gt; a rain-soaked neon alley at dusk, looking straight at the camera, cinematic lighting, photorealistic.&lt;span class="s2"&gt;"}')"&lt;/span&gt;
download &lt;span class="s2"&gt;"$(jq -r '.result.assets[0].assetId' portrait.json)"&lt;/span&gt; portrait.webp
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-a2.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-a2.webp" alt="Text to image at 9:16" width="800" height="1422"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;small&gt;&lt;a href="https://media.useapi.net/articles/2026-10-12-muse-api-zh/muse-a2.webp" rel="noopener noreferrer"&gt;open in new tab&lt;/a&gt;&lt;/small&gt;&lt;/p&gt;

&lt;p&gt;That came back at exactly 9:16, 1152×2048. A landscape version asked as &lt;code&gt;Cinematic 16:9 landscape photo: …&lt;/code&gt; came back 1920×1280, which is 3:2. Writing the ratio as &lt;code&gt;in exactly 16:9 aspect ratio&lt;/code&gt; fixed it:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;run bmw-noir.json jobs/image &lt;span class="s2"&gt;"$(jq -n '{prompt: "&lt;/span&gt;In exactly 16:9 aspect ratio &lt;span class="o"&gt;(&lt;/span&gt;landscape&lt;span class="o"&gt;)&lt;/span&gt;, a cinematic photo of a vintage 1920s black BMW motorcycle with white pinstripes, spoked wheels and a brown leather saddle, parked on wet cobblestones at night &lt;span class="k"&gt;in&lt;/span&gt; San Francisco, the Golden Gate Bridge glowing through fog &lt;span class="k"&gt;in&lt;/span&gt; the distance, neo-noir moonlight, reflections on the wet street, shot on 35mm film.&lt;span class="s2"&gt;"}')"&lt;/span&gt;
download &lt;span class="s2"&gt;"$(jq -r '.result.assets[0].assetId' bmw-noir.json)"&lt;/span&gt; bmw-noir.webp
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-a5.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-a5.webp" alt="Text to image at exactly 16:9" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;small&gt;&lt;a href="https://media.useapi.net/articles/2026-10-12-muse-api-zh/muse-a5.webp" rel="noopener noreferrer"&gt;open in new tab&lt;/a&gt;&lt;/small&gt;&lt;/p&gt;

&lt;p&gt;Muse answered "That 16:9 frame with the bridge ghosting through the fog is pure neo-noir. Enjoy." Its reply is in &lt;code&gt;result.text&lt;/code&gt;.&lt;/p&gt;

&lt;h4&gt;
  
  
  4. Three photos into one picture
&lt;/h4&gt;

&lt;p&gt;Up to 9 images go into one job as &lt;code&gt;image_1&lt;/code&gt;..&lt;code&gt;image_9&lt;/code&gt;, and the prompt names them. Here the motorcycle is &lt;code&gt;image_1&lt;/code&gt;, the rider &lt;code&gt;image_2&lt;/code&gt; and the beach &lt;code&gt;image_3&lt;/code&gt;. The prompt asks Muse to use the photographed beach as it is, so the Golden Gate Bridge stays where it was in the photo.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;run beach-ride.json jobs/image &lt;span class="s2"&gt;"$(jq -n --arg bmw "&lt;/span&gt;&lt;span class="nv"&gt;$BMW&lt;/span&gt;&lt;span class="s2"&gt;" --arg rider "&lt;/span&gt;&lt;span class="nv"&gt;$RIDER&lt;/span&gt;&lt;span class="s2"&gt;" --arg beach "&lt;/span&gt;&lt;span class="nv"&gt;$BEACH&lt;/span&gt;&lt;span class="s2"&gt;" \
  '{image_1: $bmw, image_2: $rider, image_3: $beach,
  prompt: "&lt;/span&gt;In exactly 16:9 aspect ratio &lt;span class="o"&gt;(&lt;/span&gt;landscape&lt;span class="o"&gt;)&lt;/span&gt;, a cinematic photo: the woman from image_2 &lt;span class="o"&gt;(&lt;/span&gt;her face, long wavy red hair, light blue top and jeans&lt;span class="o"&gt;)&lt;/span&gt; riding the exact vintage motorcycle from image_1 along the shoreline of the beach &lt;span class="k"&gt;in&lt;/span&gt; image_3, the front wheel cutting through the shallow surf and throwing spray, bright afternoon sun, her hair streaming &lt;span class="k"&gt;in&lt;/span&gt; the wind, photorealistic. Use the beach, rocks and Golden Gate Bridge from image_3 as the background exactly as photographed: same position, same orientation, not mirrored or redrawn. Keep her face and the motorcycle&lt;span class="s1"&gt;'\''&lt;/span&gt;s design exactly as &lt;span class="k"&gt;in&lt;/span&gt; the images.&lt;span class="s2"&gt;"}')"&lt;/span&gt;
&lt;span class="nv"&gt;BEACH_RIDE&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r &lt;span class="s1"&gt;'.result.assets[0].assetId'&lt;/span&gt; beach-ride.json&lt;span class="o"&gt;)&lt;/span&gt;
download &lt;span class="s2"&gt;"$BEACH_RIDE"&lt;/span&gt; beach-ride.webp
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-g1.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-g1.webp" alt="The rider, the motorcycle and the beach in one picture" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;small&gt;&lt;a href="https://media.useapi.net/articles/2026-10-12-muse-api-zh/muse-g1.webp" rel="noopener noreferrer"&gt;open in new tab&lt;/a&gt;&lt;/small&gt;&lt;/p&gt;

&lt;p&gt;31 seconds, and no visible change in the weekly allowance.&lt;/p&gt;

&lt;h4&gt;
  
  
  5. The picture as a video, no re-upload
&lt;/h4&gt;

&lt;p&gt;&lt;code&gt;BEACH_RIDE&lt;/code&gt; is the id of a file Muse made. It is already in the account's workspace, so it goes straight into the next job as &lt;code&gt;image_1&lt;/code&gt;, with no download and no upload. &lt;code&gt;Animate image_1&lt;/code&gt; makes a clip that starts from the picture and keeps its shape, and the line in quotes is spoken.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;run surf.json jobs/video &lt;span class="s2"&gt;"$(jq -n --arg img "&lt;/span&gt;&lt;span class="nv"&gt;$BEACH_RIDE&lt;/span&gt;&lt;span class="s2"&gt;" '{image_1: $img,
  prompt: "&lt;/span&gt;Animate image_1 into a cinematic video &lt;span class="k"&gt;in&lt;/span&gt; exactly 16:9 aspect ratio &lt;span class="o"&gt;(&lt;/span&gt;landscape&lt;span class="o"&gt;)&lt;/span&gt;: she rides the vintage motorcycle along the shoreline, the front wheel slices through the shallow waves and sends spray flying, the old engine roars, she raises one fist and shouts with a laugh: \&lt;span class="s2"&gt;"Nothing beats this view!\" The camera tracks alongside her. The beach, the rocks and the Golden Gate Bridge stay exactly as in image_1 (same orientation). Keep her face and the motorcycle exactly as in image_1."&lt;/span&gt;&lt;span class="o"&gt;}&lt;/span&gt;&lt;span class="s1"&gt;')"
SURF=$(jq -r '&lt;/span&gt;.result.assets&lt;span class="o"&gt;[&lt;/span&gt;0&lt;span class="o"&gt;]&lt;/span&gt;.assetId&lt;span class="s1"&gt;' surf.json)
download "$SURF" surf.mp4
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;p&gt;10 seconds at 1280×720 with sound. Muse said "Done. 10 seconds, 16:9 landscape, straight from your image — no edits, no upscaling."&lt;/p&gt;

&lt;p&gt;The first try of this exact job failed after 37 seconds: Muse answered that "the video worker glitched out before it rendered anything, so no clip was made". The API reports an answer like that as &lt;code&gt;503&lt;/code&gt;, nothing made, and the same request worked when run again. A refusal on content grounds is a &lt;code&gt;403&lt;/code&gt; instead, and needs a different prompt.&lt;/p&gt;

&lt;h4&gt;
  
  
  6. Restore and colorize an old photo
&lt;/h4&gt;

&lt;p&gt;An image job can also repair an image. The old portrait is a faded sepia photo of 685×900 pixels, 3:4. The prompt lists what to fix and insists on the same frame.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;run restored.json jobs/image &lt;span class="s2"&gt;"$(jq -n --arg img "&lt;/span&gt;&lt;span class="nv"&gt;$OLD_PHOTO&lt;/span&gt;&lt;span class="s2"&gt;" '{image_1: $img,
  prompt: "&lt;/span&gt;Restore the old photograph image_1 as a high-quality modern photo: remove the scratches, dust, stains, fading and grain, recover sharp detail &lt;span class="k"&gt;in&lt;/span&gt; the face, hair and fabric, and colorize it naturally &lt;span class="o"&gt;(&lt;/span&gt;warm natural skin tones, dark brown hair, ivory tulle shawl, a soft pink rose with green leaves, a muted warm background&lt;span class="o"&gt;)&lt;/span&gt;. Keep the exact same person, expression, pose, framing and crop, and the same portrait aspect ratio as image_1 &lt;span class="o"&gt;(&lt;/span&gt;3:4, 685×900&lt;span class="o"&gt;)&lt;/span&gt;: &lt;span class="k"&gt;do&lt;/span&gt; not crop, extend or reframe it.&lt;span class="s2"&gt;"}')"&lt;/span&gt;
&lt;span class="nv"&gt;RESTORED&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r &lt;span class="s1"&gt;'.result.assets[0].assetId'&lt;/span&gt; restored.json&lt;span class="o"&gt;)&lt;/span&gt;
download &lt;span class="s2"&gt;"$RESTORED"&lt;/span&gt; restored.webp
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;/p&gt;&lt;a href="https://media.useapi.net/articles/2026-10-12-muse-api-zh/muse-input-oldphoto.jpg" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-input-oldphoto.jpg" alt="Before: the original, 685×900" width="685" height="900"&gt;&lt;/a&gt;Before: the original, 685×900&lt;br&gt;
&lt;a href="https://media.useapi.net/articles/2026-10-12-muse-api-zh/muse-e1.webp" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-12-muse-api-zh%2Fmuse-e1.webp" alt="After: restored and colorized, 1344×1792" width="800" height="1067"&gt;&lt;/a&gt;After: restored and colorized, 1344×1792&lt;p&gt;&lt;/p&gt;

&lt;p&gt;The result is 1344×1792, the same 3:4 frame at about twice the size, with the same pose and crop. Muse said "Done — restored, de-grained, and colorized, same framing and pose."&lt;/p&gt;

&lt;h4&gt;
  
  
  7. The portrait comes to life
&lt;/h4&gt;

&lt;p&gt;The restored image goes straight into a video job. The clip keeps the portrait's shape, so it came back 832×1104.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;run portrait-video.json jobs/video &lt;span class="s2"&gt;"$(jq -n --arg img "&lt;/span&gt;&lt;span class="nv"&gt;$RESTORED&lt;/span&gt;&lt;span class="s2"&gt;" '{image_1: $img,
  prompt: "&lt;/span&gt;Animate image_1 into a video with the same portrait frame: the young woman slowly lifts her eyes to the camera, her smile widens, she gently touches the rose on her shoulder and says softly: \&lt;span class="s2"&gt;"It has been a hundred years... and you still remember me.\" A light breeze moves a few strands of her hair, soft window light, the camera stays still with a very slow push-in. Keep her face exactly as in image_1."&lt;/span&gt;&lt;span class="o"&gt;}&lt;/span&gt;&lt;span class="s1"&gt;')"
download "$(jq -r '&lt;/span&gt;.result.assets&lt;span class="o"&gt;[&lt;/span&gt;0&lt;span class="o"&gt;]&lt;/span&gt;.assetId&lt;span class="s1"&gt;' portrait-video.json)" portrait.mp4
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;h4&gt;
  
  
  8. Swap the rider in the video
&lt;/h4&gt;

&lt;p&gt;A video job also takes videos. &lt;code&gt;video_1&lt;/code&gt; is the surf clip from step 5, and &lt;code&gt;image_1&lt;/code&gt; is the photo of a second woman with pink hair in two buns. The prompt asks Muse to replace the rider and keep everything else, and gives her a new line.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;run swap.json jobs/video &lt;span class="s2"&gt;"$(jq -n --arg vid "&lt;/span&gt;&lt;span class="nv"&gt;$SURF&lt;/span&gt;&lt;span class="s2"&gt;" --arg img "&lt;/span&gt;&lt;span class="nv"&gt;$PINK&lt;/span&gt;&lt;span class="s2"&gt;" '{video_1: $vid, image_1: $img,
  prompt: "&lt;/span&gt;Edit video_1: replace the rider with the woman from image_1 &lt;span class="o"&gt;(&lt;/span&gt;her face, pink hair &lt;span class="k"&gt;in&lt;/span&gt; two buns, colorful makeup and tattoos&lt;span class="o"&gt;)&lt;/span&gt;, and keep everything &lt;span class="k"&gt;else&lt;/span&gt; the same: the motorcycle, the beach, the waves and spray, the Golden Gate Bridge, the light, the camera move and the timing. Instead of the original line she shouts: \&lt;span class="s2"&gt;"Catch me if you can, San Francisco!\" Keep the 16:9 frame and the same length."&lt;/span&gt;&lt;span class="o"&gt;}&lt;/span&gt;&lt;span class="s1"&gt;')"
download "$(jq -r '&lt;/span&gt;.result.assets&lt;span class="o"&gt;[&lt;/span&gt;0&lt;span class="o"&gt;]&lt;/span&gt;.assetId&lt;span class="s1"&gt;' swap.json)" swap.mp4
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;/p&gt;Before: the original rider&lt;br&gt;
After: the rider from the photo&lt;p&gt;&lt;/p&gt;

&lt;p&gt;At 138 seconds this was the slowest job of the walkthrough, which is why every job here runs async. The clip is the same ride with the other woman on the motorcycle, shouting the new line. Muse said "Done. She's in, 10 seconds, 16:9, same ride, same bridge, same waves."&lt;/p&gt;

&lt;h4&gt;
  
  
  9. Check the weekly allowance
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-muse-v1/get-muse-accounts-email" rel="noopener noreferrer"&gt;GET /accounts/&lt;code&gt;email&lt;/code&gt;&lt;/a&gt; reads the account's plan and usage live:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;get &lt;span class="s2"&gt;"accounts/$(enc "&lt;/span&gt;&lt;span class="nv"&gt;$EMAIL&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; jq &lt;span class="s1"&gt;'{session, quota}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;quota.percentUsed&lt;/code&gt; is the share of the week used, in whole percent, and &lt;code&gt;quota.resetsAt&lt;/code&gt; is when it starts over, a week after it began. The three videos above used 2 to 3 percent each and the images 0 or 1. Over the whole test session, which also ran two jobs not shown here, the free account went from 16 to 28 percent. When an account runs out, new jobs without &lt;code&gt;email&lt;/code&gt; go to your other accounts, and a job pinned to it answers &lt;code&gt;412&lt;/code&gt; until &lt;code&gt;resetsAt&lt;/code&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  What we learned
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Write the aspect ratio as &lt;code&gt;in exactly 16:9 aspect ratio&lt;/code&gt;. &lt;code&gt;Cinematic 16:9 landscape photo&lt;/code&gt; came back 3:2 once.&lt;/li&gt;
&lt;li&gt;Every video is about 10 seconds. A prompt asking for 5 seconds still got 10.&lt;/li&gt;
&lt;li&gt;An image-to-video clip keeps the shape of its image unless the prompt asks for another one: &lt;code&gt;in exactly 9:16 aspect ratio&lt;/code&gt; turned our 16:9 beach picture into a vertical 720×1280 clip, re-framed rather than stretched.&lt;/li&gt;
&lt;li&gt;Lines written in quotes in a video prompt are spoken.&lt;/li&gt;
&lt;li&gt;Pass generated files on by &lt;code&gt;assetId&lt;/code&gt;. They stay in the account's workspace, so a chain of edits needs no downloads in between.&lt;/li&gt;
&lt;li&gt;Say what must stay the same. "Same position, same orientation, not mirrored or redrawn" kept the real beach in the composite.&lt;/li&gt;
&lt;li&gt;A &lt;code&gt;503&lt;/code&gt; with Muse's own words such as "glitched out" is worth running again. A &lt;code&gt;403&lt;/code&gt; is a refusal and needs a different prompt.&lt;/li&gt;
&lt;li&gt;Send videos with &lt;code&gt;async: true&lt;/code&gt;. A sync request waits about 100 seconds, and the swap took 138.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Frequently asked questions
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Is there an API for Meta Muse (muse.ai)?&lt;/strong&gt; useapi.net offers one: the &lt;a href="https://useapi.net/docs/api-muse-v1" rel="noopener noreferrer"&gt;Muse API&lt;/a&gt; runs Muse on your own account. You add the account with its email and password, then make images with &lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-image" rel="noopener noreferrer"&gt;POST /jobs/image&lt;/a&gt; and videos with &lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-video" rel="noopener noreferrer"&gt;POST /jobs/video&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Does it work on the free Muse plan?&lt;/strong&gt; Yes. Everything on this page was made on the free plan (&lt;code&gt;HATCH_FREE&lt;/code&gt;), which has a weekly allowance. A video used 2 to 3 percent of it and an image 0 to 1 percent.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How do I set the aspect ratio, length or resolution?&lt;/strong&gt; In the prompt. There are no parameters for them. The aspect ratio is followed when written as &lt;code&gt;in exactly 16:9 aspect ratio&lt;/code&gt;. Videos are always about 10 seconds at about 720p, with sound.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I use my own photos and videos?&lt;/strong&gt; Yes. Upload them with &lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-assets" rel="noopener noreferrer"&gt;POST /assets&lt;/a&gt;, up to 8.6 MB each, and pass the &lt;code&gt;assetId&lt;/code&gt; as &lt;code&gt;image_1&lt;/code&gt;..&lt;code&gt;image_9&lt;/code&gt;; &lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-video" rel="noopener noreferrer"&gt;video jobs&lt;/a&gt; also take &lt;code&gt;video_1&lt;/code&gt;..&lt;code&gt;video_3&lt;/code&gt; and &lt;code&gt;audio_1&lt;/code&gt;..&lt;code&gt;audio_3&lt;/code&gt;. All inputs of one job must be on the same account.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How do I make a photo talk?&lt;/strong&gt; Pass it as &lt;code&gt;image_1&lt;/code&gt; to &lt;a href="https://useapi.net/docs/api-muse-v1/post-muse-jobs-video" rel="noopener noreferrer"&gt;POST /jobs/video&lt;/a&gt; with a prompt like &lt;code&gt;Animate image_1: … she says softly: "…"&lt;/code&gt;, as in step 7.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can it replace a person in a video?&lt;/strong&gt; Yes. Pass the clip as &lt;code&gt;video_1&lt;/code&gt; and a photo of the new person as &lt;code&gt;image_1&lt;/code&gt;, and ask Muse to replace the person and keep everything else, as in step 8.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why did my sync request return 202?&lt;/strong&gt; The job was still running after about 100 seconds. It keeps running on our side. Fetch it with &lt;a href="https://useapi.net/docs/api-muse-v1/get-muse-jobs-jobid" rel="noopener noreferrer"&gt;GET /jobs/&lt;code&gt;jobid&lt;/code&gt;&lt;/a&gt;, or send long jobs with &lt;code&gt;async: true&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why did Muse email me a login code?&lt;/strong&gt; The API signed in to the account, which happens when you add it and when the session is renewed, about once every 30 days. The code needs no action. See &lt;a href="https://useapi.net/docs/start-here/setup-muse#what-to-expect" rel="noopener noreferrer"&gt;Setup Muse&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;Visit our &lt;a href="https://discord.gg/w28uK3cnmF" rel="noopener noreferrer"&gt;Discord Server&lt;/a&gt; or &lt;a href="https://t.me/use_api" rel="noopener noreferrer"&gt;Telegram Channel&lt;/a&gt; for any support questions and concerns.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>api</category>
      <category>tutorial</category>
      <category>meta</category>
    </item>
    <item>
      <title>How to Make AI Influencer Videos with Avatars via the Google Vids API</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Fri, 09 Oct 2026 05:20:29 +0000</pubDate>
      <link>https://dev.to/useapi/how-to-make-ai-influencer-videos-with-avatars-via-the-google-vids-api-3ide</link>
      <guid>https://dev.to/useapi/how-to-make-ai-influencer-videos-with-avatars-via-the-google-vids-api-3ide</guid>
      <description>&lt;h3&gt;
  
  
  Introduction
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;The &lt;a href="https://useapi.net/docs/api-google-vids-v1" rel="noopener noreferrer"&gt;useapi.net Google Vids API&lt;/a&gt; makes talking AI influencer videos from avatars: save a picture and one of 30 Gemini voices once with POST /avatars, then pass the avatar's id to any &lt;a href="https://blog.google/products-and-platforms/products/workspace/gemini-omni-in-google-vids/" rel="noopener noreferrer"&gt;Gemini Omni 1.1 Flash&lt;/a&gt; clip, where it speaks the lines you write in the prompt.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The API runs on your own &lt;a href="https://docs.google.com/videos" rel="noopener noreferrer"&gt;Google Vids&lt;/a&gt; account. This walkthrough makes two influencers and launches a sneaker with them. Mia's avatar comes from a portrait made with the API, and Leo's is drawn by Google from a written description. They present the AeroLoop, a made-up sneaker, on a theater stage in one 10-second clip with both avatars and a product image, and two extends take it to 30 seconds. An edit moves the scene to a rooftop, and two more clips show what the same calls make without avatars. Every request below is the one that made the media on this page, with the ids replaced and &lt;code&gt;async: true&lt;/code&gt; added by the &lt;code&gt;run&lt;/code&gt; helper.&lt;/p&gt;



&lt;p&gt;&lt;small&gt;The finished 30-second clip at &lt;code&gt;720p&lt;/code&gt;: one 10-second generation and two 10-second extends (steps 6 to 8).&lt;/small&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  What it cost
&lt;/h3&gt;

&lt;p&gt;useapi.net is an API, not a video service of its own. Every call runs on a Google account you connect through &lt;a href="https://useapi.net/docs/start-here/setup-google-vids" rel="noopener noreferrer"&gt;Setup Google Vids&lt;/a&gt;, on a paid Google AI plan, and uses that account's monthly Vids allowance: seconds of video and a count of images. Google AI Ultra $199 gets 10,000 seconds of video and 1,000 images a month. You pay useapi.net a flat &lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;$15/month&lt;/a&gt; for every API we offer, with no per-clip charge. See &lt;a href="https://useapi.net/docs/api-google-vids-v1#plans-and-monthly-allowances" rel="noopener noreferrer"&gt;Plans and monthly allowances&lt;/a&gt; for the other plans.&lt;/p&gt;

&lt;p&gt;What each kept result used, taken from the change in &lt;code&gt;result.quota&lt;/code&gt;, and how long each job took (&lt;code&gt;result.elapsedMs&lt;/code&gt;):&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Step&lt;/th&gt;
&lt;th&gt;Endpoint&lt;/th&gt;
&lt;th&gt;Allowance used&lt;/th&gt;
&lt;th&gt;Time&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Mia's portrait&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-images" rel="noopener noreferrer"&gt;POST /images&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;1 image&lt;/td&gt;
&lt;td&gt;9 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;The AeroLoop product shot&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-images" rel="noopener noreferrer"&gt;POST /images&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;1 image&lt;/td&gt;
&lt;td&gt;9 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Mia's avatar, from her portrait&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-avatars" rel="noopener noreferrer"&gt;POST /avatars&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;nothing&lt;/td&gt;
&lt;td&gt;about 2 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Leo's avatar, from a description&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-avatars" rel="noopener noreferrer"&gt;POST /avatars&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;1 image&lt;/td&gt;
&lt;td&gt;about 20 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;The 10-second launch clip&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos" rel="noopener noreferrer"&gt;POST /videos&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;10 s&lt;/td&gt;
&lt;td&gt;38 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Extend to 20 seconds&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos-extend" rel="noopener noreferrer"&gt;POST /videos/extend&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;10 s&lt;/td&gt;
&lt;td&gt;70 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Extend to 30 seconds&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos-extend" rel="noopener noreferrer"&gt;POST /videos/extend&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;10 s&lt;/td&gt;
&lt;td&gt;85 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Upscale the 20 seconds to 1080p&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos-upscale" rel="noopener noreferrer"&gt;POST /videos/upscale&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;20 s&lt;/td&gt;
&lt;td&gt;62 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Rooftop edit&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos-edit" rel="noopener noreferrer"&gt;POST /videos/edit&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;10 s&lt;/td&gt;
&lt;td&gt;64 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Edit of the 30-second clip&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos-edit" rel="noopener noreferrer"&gt;POST /videos/edit&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;10 s&lt;/td&gt;
&lt;td&gt;87 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Product hero clip&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos" rel="noopener noreferrer"&gt;POST /videos&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;10 s&lt;/td&gt;
&lt;td&gt;62 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;The pigeon&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos" rel="noopener noreferrer"&gt;POST /videos&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;5 s&lt;/td&gt;
&lt;td&gt;54 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Total&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;85 s of video, 3 images&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;An extend uses only the seconds it adds, not the length of the clip. An upscale uses the clip's full length again, and an edit uses the length of the clip it returns. &lt;code&gt;720p&lt;/code&gt; and &lt;code&gt;1080p&lt;/code&gt; cost the same when you generate. A clip you generate again costs its seconds again.&lt;/p&gt;

&lt;h4&gt;
  
  
  What a 10-second Omni clip costs
&lt;/h4&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Where&lt;/th&gt;
&lt;th&gt;One 10-second Omni 1.1 Flash clip&lt;/th&gt;
&lt;th&gt;10-second clips a month&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Google's metered &lt;a href="https://ai.google.dev/gemini-api/docs/pricing" rel="noopener noreferrer"&gt;Gemini API&lt;/a&gt;
&lt;/td&gt;
&lt;td&gt;about $1.01 at &lt;code&gt;720p&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;as many as you pay for&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;a href="https://useapi.net/docs/api-google-flow-v1" rel="noopener noreferrer"&gt;Google Flow API&lt;/a&gt; on Google AI Ultra ($199)&lt;/td&gt;
&lt;td&gt;15 credits, about $0.12&lt;/td&gt;
&lt;td&gt;about 1,666&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;a href="https://useapi.net/docs/api-google-vids-v1" rel="noopener noreferrer"&gt;Google Vids API&lt;/a&gt; on Google AI Ultra ($199)&lt;/td&gt;
&lt;td&gt;10 seconds of allowance, about $0.20&lt;/td&gt;
&lt;td&gt;about 1,000, shared by the family plan&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Flow and Vids on the same Ultra account&lt;/td&gt;
&lt;td&gt;about $0.07&lt;/td&gt;
&lt;td&gt;about 2,666&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The Gemini API bills Omni 1.1 Flash at 5,792 tokens per second of &lt;code&gt;720p&lt;/code&gt; video, at $17.50 per million tokens. At that rate, 2,666 ten-second clips would cost about $2,700 a month, against one Ultra plan and the $15 useapi.net subscription. Prices as of October 2026.&lt;/p&gt;

&lt;h3&gt;
  
  
  Before you start
&lt;/h3&gt;

&lt;p&gt;You need a useapi.net &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt; and a Google account on a paid Google AI plan connected through &lt;a href="https://useapi.net/docs/start-here/setup-google-vids" rel="noopener noreferrer"&gt;Setup Google Vids&lt;/a&gt;. A free Google account gets no Vids allowance: it can still be added, but only makes avatars. Every call is also in the &lt;a href="https://www.postman.com/useapinet/useapi-net/collection/29112081-9ef3d017-d44c-4f43-a4cb-7351b9b265df" rel="noopener noreferrer"&gt;Postman collection&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Also in Chinese: &lt;a href="https://useapi.net/docs/articles/google-vids-api-zh" rel="noopener noreferrer"&gt;中文教程&lt;/a&gt;. The whole pipeline is also on GitHub as one script, in Node.js and Python: &lt;a href="https://github.com/useapi/google-vids-api/tree/main/influencer-avatars" rel="noopener noreferrer"&gt;&lt;code&gt;influencer-avatars/&lt;/code&gt;&lt;/a&gt; in &lt;a href="https://github.com/useapi/google-vids-api" rel="noopener noreferrer"&gt;useapi/google-vids-api&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The steps use &lt;code&gt;curl&lt;/code&gt;, &lt;code&gt;jq&lt;/code&gt; and these variables and helpers:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;USEAPI_TOKEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"user:12345-..."&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;EMAIL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"user@example.com"&lt;/span&gt;
&lt;span class="nv"&gt;API&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;https://api.useapi.net/v1/google-vids
&lt;span class="nv"&gt;AUTH&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt;
enc&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt; jq -rn --arg v &lt;span class="s2"&gt;"$1"&lt;/span&gt; &lt;span class="s1"&gt;'$v|@uri'&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="o"&gt;}&lt;/span&gt;
post&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt; curl -sS -X POST &lt;span class="s2"&gt;"$API/$1"&lt;/span&gt; -H &lt;span class="s2"&gt;"$AUTH"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; -d &lt;span class="s2"&gt;"$2"&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="o"&gt;}&lt;/span&gt;
get&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt; curl -sS &lt;span class="s2"&gt;"$API/$1"&lt;/span&gt; -H &lt;span class="s2"&gt;"$AUTH"&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="o"&gt;}&lt;/span&gt;
download&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt; curl -sSf &lt;span class="s2"&gt;"$API/media/$(enc "&lt;/span&gt;&lt;span class="nv"&gt;$1&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt; -H &lt;span class="s2"&gt;"$AUTH"&lt;/span&gt; -o &lt;span class="s2"&gt;"$2"&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="o"&gt;}&lt;/span&gt;

&lt;span class="c"&gt;# run a video job async: submit it, poll GET /jobs/{jobid} every 10 s, save the final job record to $1&lt;/span&gt;
run&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;local&lt;/span&gt; job id
  &lt;span class="nv"&gt;job&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;post &lt;span class="s2"&gt;"$2"&lt;/span&gt; &lt;span class="s2"&gt;"$(jq '. + {async: true}' &amp;lt;&amp;lt;&amp;lt; "&lt;/span&gt;&lt;span class="nv"&gt;$3&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
  &lt;span class="nv"&gt;id&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r .jobid &lt;span class="o"&gt;&amp;lt;&amp;lt;&amp;lt;&lt;/span&gt; &lt;span class="s2"&gt;"$job"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
  &lt;span class="k"&gt;while&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt; &lt;span class="s2"&gt;"$(jq -r .status &amp;lt;&amp;lt;&amp;lt; "&lt;/span&gt;&lt;span class="nv"&gt;$job&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; processing &lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="k"&gt;do&lt;/span&gt;
    sleep 10
    &lt;span class="nv"&gt;job&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;get &lt;span class="s2"&gt;"jobs/$(enc "&lt;/span&gt;&lt;span class="nv"&gt;$id&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
  &lt;span class="k"&gt;done&lt;/span&gt;
  &lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"$job"&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="s2"&gt;"$1"&lt;/span&gt;
  jq &lt;span class="s1"&gt;'{status, error, duration: .result.duration, resolution: .result.resolution, videoLeft: .result.quota.video.left}'&lt;/span&gt; &lt;span class="s2"&gt;"$1"&lt;/span&gt;
&lt;span class="o"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Every generation runs as a job. Without &lt;code&gt;async&lt;/code&gt;, a POST waits up to about 100 seconds and returns the finished job record, or &lt;code&gt;202&lt;/code&gt; with the job still running. A new 10-second clip took 38 to 62 seconds here, and extends, edits and the upscale took 62 to 87. Some take longer than the sync wait, so &lt;code&gt;run&lt;/code&gt; submits video jobs with &lt;code&gt;async: true&lt;/code&gt; and polls &lt;a href="https://useapi.net/docs/api-google-vids-v1/get-google-vids-jobs-jobid" rel="noopener noreferrer"&gt;GET /jobs/&lt;code&gt;jobid&lt;/code&gt;&lt;/a&gt;. If &lt;code&gt;run&lt;/code&gt; prints any &lt;code&gt;status&lt;/code&gt; other than &lt;code&gt;completed&lt;/code&gt;, stop there and read its &lt;code&gt;error&lt;/code&gt;: the lines after it expect a finished clip.&lt;/p&gt;

&lt;p&gt;To be called back instead of polling, add &lt;code&gt;replyUrl: "https://example.com/hooks/vids"&lt;/code&gt; (and optionally &lt;code&gt;replyRef: "launch-push-in"&lt;/code&gt;) to any body below. The API then sends one &lt;code&gt;POST&lt;/code&gt; of the final job record, as JSON, to that URL when the job completes or fails.&lt;/p&gt;

&lt;p&gt;Ids contain &lt;code&gt;:&lt;/code&gt; and &lt;code&gt;@&lt;/code&gt;, so &lt;code&gt;enc&lt;/code&gt; URL-encodes them whenever they go into a URL path. Every input of one video must come from the same Google account. The images and the upload pin &lt;code&gt;email&lt;/code&gt;, Mia's avatar inherits the portrait's account, and a video job runs on the account that holds its inputs. The pigeon clip has no inputs, so add &lt;code&gt;email&lt;/code&gt; to it if you connect more than one account.&lt;/p&gt;

&lt;h3&gt;
  
  
  How it was built
&lt;/h3&gt;

&lt;h4&gt;
  
  
  1. Mia's portrait
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-images" rel="noopener noreferrer"&gt;POST /images&lt;/a&gt; makes one JPEG per call, here in portrait (&lt;code&gt;9:16&lt;/code&gt;, 768×1376) with the &lt;code&gt;photography&lt;/code&gt; style.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;post images &lt;span class="s2"&gt;"$(jq -n --arg email "&lt;/span&gt;&lt;span class="nv"&gt;$EMAIL&lt;/span&gt;&lt;span class="s2"&gt;" '{email: $email, aspectRatio: "&lt;/span&gt;9:16&lt;span class="s2"&gt;", style: "&lt;/span&gt;photography&lt;span class="s2"&gt;",
  prompt: "&lt;/span&gt;Full-length studio portrait of a confident 24-year-old female fashion influencer, platinum bob, oversized cream hoodie, wide-leg cargo pants, gold hoops, plain light-grey backdrop, facing camera&lt;span class="s2"&gt;"}')"&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; mia-portrait.json
&lt;span class="nv"&gt;MIA_IMAGE&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r .result.mediaId mia-portrait.json&lt;span class="o"&gt;)&lt;/span&gt;
download &lt;span class="s2"&gt;"$MIA_IMAGE"&lt;/span&gt; mia-portrait.jpg
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-07-google-vids-influencer-avatars-id%2Fvids-influencer-mia-portrait-1007.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-07-google-vids-influencer-avatars-id%2Fvids-influencer-mia-portrait-1007.jpg" alt="Mia, a generated full-length portrait of a fashion influencer in a cream hoodie and cargo pants, made with POST /images" width="768" height="1376"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Generated images stay available for a few hours only. Make the avatar from it right away, and see the product hero clip for using an image later.&lt;/p&gt;

&lt;h4&gt;
  
  
  2. The AeroLoop product shot
&lt;/h4&gt;

&lt;p&gt;The same call in landscape (&lt;code&gt;16:9&lt;/code&gt;, 1376×768) gives the product reference the clips use.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;post images &lt;span class="s2"&gt;"$(jq -n --arg email "&lt;/span&gt;&lt;span class="nv"&gt;$EMAIL&lt;/span&gt;&lt;span class="s2"&gt;" '{email: $email, aspectRatio: "&lt;/span&gt;16:9&lt;span class="s2"&gt;", style: "&lt;/span&gt;photography&lt;span class="s2"&gt;",
  prompt: "&lt;/span&gt;The AeroLoop sneaker: chunky white-and-electric-blue running shoe with a translucent air sole, on a concrete pedestal, dramatic side light, dark background&lt;span class="s2"&gt;"}')"&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; aeroloop.json
&lt;span class="nv"&gt;SHOE_IMAGE&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r .result.mediaId aeroloop.json&lt;span class="o"&gt;)&lt;/span&gt;
download &lt;span class="s2"&gt;"$SHOE_IMAGE"&lt;/span&gt; aeroloop.jpg
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-07-google-vids-influencer-avatars-id%2Fvids-influencer-aeroloop-product-1007.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-07-google-vids-influencer-avatars-id%2Fvids-influencer-aeroloop-product-1007.jpg" alt="The AeroLoop sneaker, a white and electric-blue running shoe with a translucent sole on a concrete pedestal, made with POST /images" width="800" height="447"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  3. Pick the voices
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/get-google-vids-voices" rel="noopener noreferrer"&gt;GET /voices&lt;/a&gt; lists the 30 voices with Google's English sample of each. It is public and needs no token. Mia speaks with &lt;code&gt;Aoede&lt;/code&gt; (Vids calls it Tova, style "Breezy") and Leo with &lt;code&gt;Puck&lt;/code&gt; (Neo, "Upbeat"). &lt;code&gt;POST /avatars&lt;/code&gt; takes either name.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -sS &lt;span class="s2"&gt;"$API/voices"&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; jq -r &lt;span class="s1"&gt;'.voices[] | "\(.name)\t\(.voice)\t\(.style)\t\(.preview)"'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  4. Mia's avatar from her portrait
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-avatars" rel="noopener noreferrer"&gt;POST /avatars&lt;/a&gt; with &lt;code&gt;image&lt;/code&gt; set to the portrait's &lt;code&gt;mediaId&lt;/code&gt; saves Mia as an avatar on the same account in about 2 seconds. It costs nothing beyond the image.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;post avatars &lt;span class="s2"&gt;"$(jq -n --arg img "&lt;/span&gt;&lt;span class="nv"&gt;$MIA_IMAGE&lt;/span&gt;&lt;span class="s2"&gt;" '{name: "&lt;/span&gt;Mia&lt;span class="s2"&gt;", voice: "&lt;/span&gt;Aoede&lt;span class="s2"&gt;", image: $img}')"&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; mia-avatar.json
&lt;span class="nv"&gt;MIA_AVATAR_ID&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r .avatarId mia-avatar.json&lt;span class="o"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"avatarId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-avatar:eyJnIjoiaDM5…"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Mia"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"voice"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Tova"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"voiceId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Aoede"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"voiceStyle"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Breezy"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"voicePreview"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"https://ssl.gstatic.com/docs/videos/audio/voice_samples/gemini-v4s-tts/1.1/en/Aoede.wav"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"email"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user@example.com"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"source"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"image"&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;An avatar cannot be made from your own photo. A real person's avatar is Google's likeness feature, which needs a live selfie video and a phone check in the browser, so &lt;code&gt;POST /avatars&lt;/code&gt; refuses an uploaded photo with &lt;code&gt;400&lt;/code&gt;. Use an image made with the API, as here, or a description, as in the next step.&lt;/p&gt;

&lt;h4&gt;
  
  
  5. Leo's avatar from a description
&lt;/h4&gt;

&lt;p&gt;With &lt;code&gt;appearance&lt;/code&gt; instead of &lt;code&gt;image&lt;/code&gt;, Google draws the person. &lt;code&gt;outfit&lt;/code&gt; and &lt;code&gt;shot&lt;/code&gt; are optional, and so are &lt;code&gt;expression&lt;/code&gt; and &lt;code&gt;details&lt;/code&gt;. Drawing the picture uses 1 image of the allowance, and the response carries it as &lt;code&gt;previewMediaId&lt;/code&gt;. In our runs a description avatar came out 1280×720 (16:9), whatever &lt;code&gt;shot&lt;/code&gt; we picked.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;post avatars &lt;span class="s2"&gt;"$(jq -n --arg email "&lt;/span&gt;&lt;span class="nv"&gt;$EMAIL&lt;/span&gt;&lt;span class="s2"&gt;" '{email: $email, name: "&lt;/span&gt;Leo&lt;span class="s2"&gt;", voice: "&lt;/span&gt;Puck&lt;span class="s2"&gt;", shot: "&lt;/span&gt;upper-body&lt;span class="s2"&gt;",
  appearance: "&lt;/span&gt;a 26-year-old white European male streetwear influencer with short textured hair with a fade and a confident half-smile&lt;span class="s2"&gt;",
  outfit: "&lt;/span&gt;black puffer vest over a white tee, silver chain&lt;span class="s2"&gt;"}')"&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; leo-avatar.json
&lt;span class="nv"&gt;LEO_AVATAR_ID&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r .avatarId leo-avatar.json&lt;span class="o"&gt;)&lt;/span&gt;
download &lt;span class="s2"&gt;"$(jq -r .previewMediaId leo-avatar.json)"&lt;/span&gt; leo-avatar.jpg
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"avatarId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-avatar:eyJnIjoiaDM5…"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Leo"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"voice"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Neo"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"voiceId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Puck"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"voiceStyle"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Upbeat"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"voicePreview"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"https://ssl.gstatic.com/docs/videos/audio/voice_samples/gemini-v4s-tts/1.1/en/Puck.wav"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"email"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user@example.com"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"source"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"generated"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"previewMediaId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-image:eyJ1IjoiaHR0…"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"look"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"appearance"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"a 26-year-old white European male streetwear influencer with short textured hair with a fade and a confident half-smile"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"outfit"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"black puffer vest over a white tee, silver chain"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"shot"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"upper-body"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-07-google-vids-influencer-avatars-id%2Fvids-influencer-leo-avatar-from-description-1007.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-07-google-vids-influencer-avatars-id%2Fvids-influencer-leo-avatar-from-description-1007.jpg" alt="Leo, an avatar Google drew from a description: a young man in a black puffer vest over a white tee with a silver chain, 1280x720" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Both avatars stay in the account's Vids document until you delete them with &lt;a href="https://useapi.net/docs/api-google-vids-v1/delete-google-vids-avatars-avatarId" rel="noopener noreferrer"&gt;DELETE /avatars/&lt;code&gt;avatarId&lt;/code&gt;&lt;/a&gt;. &lt;a href="https://useapi.net/docs/api-google-vids-v1/get-google-vids-avatars" rel="noopener noreferrer"&gt;GET /avatars&lt;/a&gt; lists them, with their ids, whenever you need them again:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;get &lt;span class="s2"&gt;"avatars?email=$(enc "&lt;/span&gt;&lt;span class="nv"&gt;$EMAIL&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; jq -r &lt;span class="s1"&gt;'.avatars[] | "\(.name)\t\(.voiceId)\t\(.avatarId)"'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  6. The launch: two avatars and the product in one clip
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos" rel="noopener noreferrer"&gt;POST /videos&lt;/a&gt; takes up to 3 references in all, avatars (&lt;code&gt;avatar_1&lt;/code&gt;..&lt;code&gt;avatar_3&lt;/code&gt;) and images (&lt;code&gt;referenceImage_1&lt;/code&gt;..&lt;code&gt;referenceImage_3&lt;/code&gt;) together. In the prompt, &lt;code&gt;@avatar_1&lt;/code&gt;, &lt;code&gt;@avatar_2&lt;/code&gt; and &lt;code&gt;@referenceImage_1&lt;/code&gt; stand for them, and each avatar speaks its quoted line in its own voice. The product image's &lt;code&gt;mediaId&lt;/code&gt; goes in directly: the API fetches the image and uploads it on that account.&lt;/p&gt;



&lt;p&gt;&lt;small&gt;10 seconds, &lt;code&gt;720p&lt;/code&gt;, 38 seconds to generate.&lt;/small&gt;&lt;/p&gt;

&lt;p&gt;The same clip with the visible Gemini ✦ removed by our &lt;a href="https://github.com/useapi/google-vids-api/tree/main/watermark-remover" rel="noopener noreferrer"&gt;watermark remover&lt;/a&gt;, with one command: &lt;code&gt;python3 vids_watermark_remover.py launch-10s.mp4&lt;/code&gt;.&lt;/p&gt;



&lt;p&gt;&lt;small&gt;The remover works on clips as generated and on upscales of them, at &lt;code&gt;720p&lt;/code&gt; and &lt;code&gt;1080p&lt;/code&gt;. It does not work on extended or edited clips: Google feeds the marked clip back to the model, which repaints the star into the picture. The invisible SynthID watermark is not touched.&lt;/small&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  7. Extend to 20 seconds
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos-extend" rel="noopener noreferrer"&gt;POST /videos/extend&lt;/a&gt; adds 3 to 10 seconds and returns the whole clip with a new &lt;code&gt;mediaId&lt;/code&gt;. An extend takes only the clip and a prompt, not the avatars, so the prompt describes the new action and names people by what they wear ("the man in the black puffer vest"). A fan in a red hoodie storms the stage.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;PROMPT&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;cat &lt;span class="o"&gt;&amp;lt;&amp;lt;&lt;/span&gt;&lt;span class="s1"&gt;'EOF'&lt;/span&gt;
A young man &lt;span class="k"&gt;in&lt;/span&gt; a red hoodie climbs onto the stage from the front right edge and plants himself to the right of the man &lt;span class="k"&gt;in&lt;/span&gt; the black puffer vest, an arm&lt;span class="s1"&gt;'s length away, so all three stand apart in a row with nobody overlapping. Visibly overexcited, he waves a thick stack of banknotes in his right hand above his head and screams: "Take my money!" The man in the black puffer vest laughs, raises both palms toward him and says: "Whoa, whoa, buddy, be patient!" The blonde woman in the cream hoodie laughs, holding the sneaker. Only these three people are on stage. Same stage, same LED screen with WEAR AEROLOOP, same wide steady shot.
EOF
)
run launch-20s.json videos/extend "$(jq -n --arg id "$LAUNCH_10S" --arg p "$PROMPT" '&lt;/span&gt;&lt;span class="o"&gt;{&lt;/span&gt;mediaId: &lt;span class="nv"&gt;$id&lt;/span&gt;, prompt: &lt;span class="nv"&gt;$p&lt;/span&gt;, duration: 10&lt;span class="o"&gt;}&lt;/span&gt;&lt;span class="s1"&gt;')"
LAUNCH_20S=$(jq -r .result.mediaId launch-20s.json)
download "$LAUNCH_20S" launch-20s.mp4
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;p&gt;&lt;small&gt;20 seconds, &lt;code&gt;720p&lt;/code&gt;, 70 seconds to generate. It used 10 seconds of allowance, the seconds it added.&lt;/small&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  8. Extend to 30 seconds
&lt;/h4&gt;

&lt;p&gt;The second extend continues the 20-second clip.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;PROMPT&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;cat &lt;span class="o"&gt;&amp;lt;&amp;lt;&lt;/span&gt;&lt;span class="s1"&gt;'EOF'&lt;/span&gt;
The blonde woman &lt;span class="k"&gt;in&lt;/span&gt; the cream hoodie turns to the camera with a big smile and says: &lt;span class="s2"&gt;"AeroLoop drops Friday. Link in bio!"&lt;/span&gt; Right after that, the young man &lt;span class="k"&gt;in&lt;/span&gt; the red hoodie throws ALL of his banknotes out over the audience &lt;span class="k"&gt;in&lt;/span&gt; one big toss, keeping none, and the bills flutter down over their heads. From &lt;span class="k"&gt;then&lt;/span&gt; on his hands are completely empty: he holds no money at all. Then all three cheer together, the man &lt;span class="k"&gt;in&lt;/span&gt; the black puffer vest and the young man &lt;span class="k"&gt;in&lt;/span&gt; the red hoodie throwing their empty fists &lt;span class="k"&gt;in&lt;/span&gt; the air, as blue and white confetti rains down over the stage. Only these three people are on stage. Same stage, same LED screen with WEAR AEROLOOP, same wide steady shot.
EOF
&lt;span class="o"&gt;)&lt;/span&gt;
run launch-30s.json videos/extend &lt;span class="s2"&gt;"$(jq -n --arg id "&lt;/span&gt;&lt;span class="nv"&gt;$LAUNCH_20S&lt;/span&gt;&lt;span class="s2"&gt;" --arg p "&lt;/span&gt;&lt;span class="nv"&gt;$PROMPT&lt;/span&gt;&lt;span class="s2"&gt;" '{mediaId: $id, prompt: $p, duration: 10}')"&lt;/span&gt;
&lt;span class="nv"&gt;LAUNCH_30S&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r .result.mediaId launch-30s.json&lt;span class="o"&gt;)&lt;/span&gt;
download &lt;span class="s2"&gt;"$LAUNCH_30S"&lt;/span&gt; launch-30s.mp4
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;p&gt;The result is the finished clip: 30 seconds, &lt;code&gt;720p&lt;/code&gt;, 85 seconds to generate, and again 10 seconds of allowance. You can keep going: chains of extends work up to 40 seconds, for example four 10-second steps. Past that, Google keeps only about the first 31 seconds of the source and adds the new seconds after them, so the longest clip is about 41 seconds.&lt;/p&gt;

&lt;h4&gt;
  
  
  9. Upscale to 1080p
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos-upscale" rel="noopener noreferrer"&gt;POST /videos/upscale&lt;/a&gt; turns a &lt;code&gt;720p&lt;/code&gt; clip into &lt;code&gt;1080p&lt;/code&gt; and keeps its length. It works on clips of up to 20 seconds, so we upscaled the 20-second clip from step 7, not the 30-second one. It used the clip's 20 seconds again and took 62 seconds.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;run launch-20s-1080p.json videos/upscale &lt;span class="s2"&gt;"$(jq -n --arg id "&lt;/span&gt;&lt;span class="nv"&gt;$LAUNCH_20S&lt;/span&gt;&lt;span class="s2"&gt;" '{mediaId: $id}')"&lt;/span&gt;
download &lt;span class="s2"&gt;"$(jq -r .result.mediaId launch-20s-1080p.json)"&lt;/span&gt; launch-20s-1080p.mp4
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;p&gt;&lt;small&gt;The 20-second clip, upscaled to 1920×1080.&lt;/small&gt;&lt;/p&gt;

&lt;p&gt;Why not the 30-second clip: Google returned it at 1920×1080, but with its frames out of order, three times out of three. The confetti ending flickered in before the fan arrived. The 20-second clip came back in order, and the Vids editor itself stops at 20 seconds, so the API refuses upscales of clips longer than 20 seconds with &lt;code&gt;400&lt;/code&gt;, before anything is charged.&lt;/p&gt;

&lt;p&gt;So for a &lt;code&gt;1080p&lt;/code&gt; clip:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Make, extend and edit at &lt;code&gt;720p&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Upscale the clip once it is finished, while it is 20 seconds or shorter.&lt;/li&gt;
&lt;li&gt;For a longer clip, stay at &lt;code&gt;720p&lt;/code&gt;, set &lt;code&gt;resolution: "1080p"&lt;/code&gt; on the last extend only, or extend at &lt;code&gt;1080p&lt;/code&gt; throughout and accept softer faces.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Examples
&lt;/h3&gt;

&lt;p&gt;More from the same account and inputs: an edit, a product clip from a start image, and a text-only clip.&lt;/p&gt;

&lt;h4&gt;
  
  
  Move the launch to a rooftop
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos-edit" rel="noopener noreferrer"&gt;POST /videos/edit&lt;/a&gt; changes a generated clip by prompt and returns a new clip. The source goes in &lt;code&gt;video&lt;/code&gt;. This edit of the 10-second launch clip used 10 seconds and took 64 seconds.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;run launch-rooftop.json videos/edit &lt;span class="s2"&gt;"$(jq -n --arg v "&lt;/span&gt;&lt;span class="nv"&gt;$LAUNCH_10S&lt;/span&gt;&lt;span class="s2"&gt;" \
  '{video: $v, prompt: "&lt;/span&gt;Move the whole scene to a rooftop at sunset, with the city skyline behind them. Same two people, same action, same words.&lt;span class="s2"&gt;"}')"&lt;/span&gt;
download &lt;span class="s2"&gt;"$(jq -r .result.mediaId launch-rooftop.json)"&lt;/span&gt; launch-rooftop.mp4
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;p&gt;An edit works on up to 10 seconds. The same edit of the 30-second clip, with "Same three people", came back 10 seconds long: the first 10 seconds, moved to the rooftop. It used 10 seconds of allowance. To get a longer edited clip, edit the 10-second clip and extend the result, since an extend accepts an edited clip.&lt;/p&gt;



&lt;p&gt;&lt;small&gt;The edit of the 30-second clip: 10 seconds back.&lt;/small&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  A product hero clip from a start image
&lt;/h4&gt;

&lt;p&gt;With &lt;code&gt;startImage&lt;/code&gt; the clip opens on that image. A generated image's link expires within hours, so we uploaded the saved &lt;code&gt;aeroloop.jpg&lt;/code&gt; with &lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-assets" rel="noopener noreferrer"&gt;POST /assets&lt;/a&gt; and passed its &lt;code&gt;assetId&lt;/code&gt;. A single clip has no extends, so it was made at &lt;code&gt;1080p&lt;/code&gt; directly.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;SHOE_ASSET&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;curl -sS -X POST &lt;span class="s2"&gt;"$API/assets?email=$(enc "&lt;/span&gt;&lt;span class="nv"&gt;$EMAIL&lt;/span&gt;&lt;span class="s2"&gt;")"&lt;/span&gt; -H &lt;span class="s2"&gt;"$AUTH"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: image/jpeg"&lt;/span&gt; \
  --data-binary @aeroloop.jpg &lt;span class="o"&gt;|&lt;/span&gt; jq -r .assetId&lt;span class="o"&gt;)&lt;/span&gt;
run hero.json videos &lt;span class="s2"&gt;"$(jq -n --arg img "&lt;/span&gt;&lt;span class="nv"&gt;$SHOE_ASSET&lt;/span&gt;&lt;span class="s2"&gt;" '{startImage: $img, duration: 10, resolution: "&lt;/span&gt;1080p&lt;span class="s2"&gt;", aspectRatio: "&lt;/span&gt;landscape&lt;span class="s2"&gt;",
  prompt: "&lt;/span&gt;Slow 360° orbit around the sneaker, blue light rippling through the translucent sole, dust sparkling &lt;span class="k"&gt;in&lt;/span&gt; the air, cinematic.&lt;span class="s2"&gt;"}')"&lt;/span&gt;
download &lt;span class="s2"&gt;"$(jq -r .result.mediaId hero.json)"&lt;/span&gt; hero.mp4
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;p&gt;&lt;small&gt;10 seconds, &lt;code&gt;1080p&lt;/code&gt;.&lt;/small&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  A pigeon in AeroLoops
&lt;/h4&gt;

&lt;p&gt;A text-only clip, in portrait at &lt;code&gt;1080p&lt;/code&gt; (1080×1920). The 5 seconds took 54 seconds to generate and used 5 seconds of allowance.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;run pigeon.json videos &lt;span class="s2"&gt;"$(jq -n '{duration: 5, resolution: "&lt;/span&gt;1080p&lt;span class="s2"&gt;", aspectRatio: "&lt;/span&gt;portrait&lt;span class="s2"&gt;",
  prompt: "&lt;/span&gt;A pigeon &lt;span class="k"&gt;in&lt;/span&gt; tiny white-and-electric-blue AeroLoop sneakers struts down a city sidewalk like a runway model, head bobbing to the beat. Pedestrians stop and film it with their phones. It pauses, does a slow-motion hair flip with its head feathers, and struts on. Funny, sunny, shot on a phone at pigeon height.&lt;span class="s2"&gt;"}')"&lt;/span&gt;
download &lt;span class="s2"&gt;"$(jq -r .result.mediaId pigeon.json)"&lt;/span&gt; pigeon.mp4
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;p&gt;The pigeon at &lt;code&gt;1080p&lt;/code&gt; portrait (1080×1920), with the ✦ removed the same way: &lt;code&gt;python3 vids_watermark_remover.py pigeon-5s.mp4&lt;/code&gt;. The script reads the frame size, works out where the star is and how big (it scales with the short side, so here it is 1.5 times the &lt;code&gt;720p&lt;/code&gt; star), reverses the blend on all 120 frames, re-encodes the video at CRF 18 and copies the audio unchanged. The 5-second clip took about 10 seconds on a 14-core PC, the same as the 10-second &lt;code&gt;720p&lt;/code&gt; launch clip above. It needs Python 3.8+, &lt;code&gt;numpy&lt;/code&gt; and &lt;code&gt;ffmpeg&lt;/code&gt;; see the &lt;a href="https://github.com/useapi/google-vids-api/tree/main/watermark-remover" rel="noopener noreferrer"&gt;watermark remover&lt;/a&gt; on GitHub.&lt;/p&gt;



&lt;h3&gt;
  
  
  What we learned
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;A &lt;code&gt;1080p&lt;/code&gt; clip behaves like an upscaled &lt;code&gt;720p&lt;/code&gt; one. Build a chain of extends at &lt;code&gt;720p&lt;/code&gt;: at &lt;code&gt;1080p&lt;/code&gt; the faces got softer and more waxy at every step.&lt;/li&gt;
&lt;li&gt;Upscale only clips of up to 20 seconds. Our 30-second upscale came back with its frames out of order every time.&lt;/li&gt;
&lt;li&gt;Generate a single clip at &lt;code&gt;1080p&lt;/code&gt; if you want &lt;code&gt;1080p&lt;/code&gt; and won't extend it. It costs the same as &lt;code&gt;720p&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Write an extend prompt about the new action only. The extend gets the clip, not the avatars, so name people by what they wear.&lt;/li&gt;
&lt;li&gt;Put a prop in a person's hands in the first sentence that mentions them. A verb like "lifts" made the sneaker appear from nowhere.&lt;/li&gt;
&lt;li&gt;Say what must not happen. The fan kept a stack of banknotes until the prompt said his hands were empty.&lt;/li&gt;
&lt;li&gt;Reuse avatars by &lt;code&gt;avatarId&lt;/code&gt;. Each avatar is a fixed picture and voice, kept until you delete it.&lt;/li&gt;
&lt;li&gt;Make avatars and clips from a generated image within a few hours, or upload the saved file with &lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-assets" rel="noopener noreferrer"&gt;POST /assets&lt;/a&gt; first.&lt;/li&gt;
&lt;li&gt;Edit clips of up to 10 seconds. A longer clip comes back as its first 10 seconds.&lt;/li&gt;
&lt;li&gt;Expect on-screen text to waver. The backdrop's "WEAR AEROLOOP" is misspelled in some frames.&lt;/li&gt;
&lt;li&gt;Every MP4 has Google's visible Gemini ✦ in the bottom-right corner and an invisible SynthID watermark (see &lt;a href="https://useapi.net/docs/api-google-vids-v1#watermark" rel="noopener noreferrer"&gt;Watermark&lt;/a&gt;). Our &lt;a href="https://github.com/useapi/google-vids-api/tree/main/watermark-remover" rel="noopener noreferrer"&gt;watermark remover&lt;/a&gt; takes the visible sparkle off a downloaded clip.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Frequently asked questions
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;How do I make an AI influencer video through an API?&lt;/strong&gt; Create an avatar with &lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-avatars" rel="noopener noreferrer"&gt;POST /avatars&lt;/a&gt;, from a description or from an image made with &lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-images" rel="noopener noreferrer"&gt;POST /images&lt;/a&gt;, and give it a voice from &lt;a href="https://useapi.net/docs/api-google-vids-v1/get-google-vids-voices" rel="noopener noreferrer"&gt;GET /voices&lt;/a&gt;. Then pass its &lt;code&gt;avatarId&lt;/code&gt; as &lt;code&gt;avatar_1&lt;/code&gt; to &lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos" rel="noopener noreferrer"&gt;POST /videos&lt;/a&gt; and write its lines in quotes in the prompt.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I make an avatar from my own photo?&lt;/strong&gt; No. Google treats an avatar of a real person as its likeness feature, which needs a live selfie video and a phone check in the browser. The API refuses an uploaded photo with &lt;code&gt;400&lt;/code&gt;. Use a picture made with &lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-images" rel="noopener noreferrer"&gt;POST /images&lt;/a&gt; or describe the person with &lt;code&gt;appearance&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How many avatars can one clip have?&lt;/strong&gt; Up to 3 references in all, avatars and images together. This walkthrough used two avatars and one product image.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Does an avatar look and sound the same in every video?&lt;/strong&gt; It uses the same picture and the same voice every time you pass its &lt;code&gt;avatarId&lt;/code&gt;, since both are saved with the avatar in the account's Vids document. The clip around it still varies from take to take. &lt;a href="https://useapi.net/docs/api-google-vids-v1/get-google-vids-avatars" rel="noopener noreferrer"&gt;GET /avatars&lt;/a&gt; lists your avatars, including ones made in the Google Vids web app.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can two avatars talk to each other in one clip?&lt;/strong&gt; Yes. Pass &lt;code&gt;avatar_1&lt;/code&gt; and &lt;code&gt;avatar_2&lt;/code&gt; and give each a quoted line in the prompt, as in step 6.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I make a vertical 9:16 video for TikTok or Reels?&lt;/strong&gt; Yes. Set &lt;code&gt;aspectRatio: "portrait"&lt;/code&gt; on &lt;a href="https://useapi.net/docs/api-google-vids-v1/post-google-vids-videos" rel="noopener noreferrer"&gt;POST /videos&lt;/a&gt; for 720×1280, or 1080×1920 at &lt;code&gt;1080p&lt;/code&gt;, as in the pigeon clip. An extend can also turn a landscape clip into portrait.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How long can a video be?&lt;/strong&gt; A generated clip is 3 to 10 seconds. Extends add 3 to 10 seconds each, up to about 41 seconds in all, and each one uses only the seconds it adds.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What does it cost?&lt;/strong&gt; A flat &lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;$15/month&lt;/a&gt; to useapi.net, plus the Vids allowance of your own Google AI plan: Ultra $199 gets 10,000 seconds of video and 1,000 images a month. Everything kept on this page used 85 seconds and 3 images (see What it cost).&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why did my sync request return 202?&lt;/strong&gt; The job was still running after about 100 seconds. It keeps running on our side. Fetch it with &lt;a href="https://useapi.net/docs/api-google-vids-v1/get-google-vids-jobs-jobid" rel="noopener noreferrer"&gt;GET /jobs/&lt;code&gt;jobid&lt;/code&gt;&lt;/a&gt;, or send long jobs with &lt;code&gt;async: true&lt;/code&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;Visit our &lt;a href="https://discord.gg/w28uK3cnmF" rel="noopener noreferrer"&gt;Discord Server&lt;/a&gt; or &lt;a href="https://t.me/use_api" rel="noopener noreferrer"&gt;Telegram Channel&lt;/a&gt; for any support questions and concerns.&lt;/p&gt;

&lt;p&gt;Check our &lt;a href="https://github.com/useapi/google-vids-api" rel="noopener noreferrer"&gt;GitHub repo&lt;/a&gt; with code examples.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>api</category>
      <category>tutorial</category>
      <category>video</category>
    </item>
    <item>
      <title>How to Turn Web Pages, YouTube Videos and RSS Feeds into NotebookLM Podcasts with n8n</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Mon, 05 Oct 2026 05:53:18 +0000</pubDate>
      <link>https://dev.to/useapi/how-to-turn-web-pages-youtube-videos-and-rss-feeds-into-notebooklm-podcasts-with-n8n-1m0g</link>
      <guid>https://dev.to/useapi/how-to-turn-web-pages-youtube-videos-and-rss-feeds-into-notebooklm-podcasts-with-n8n-1m0g</guid>
      <description>&lt;h3&gt;
  
  
  Introduction
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Two free n8n workflows send your links to NotebookLM through the &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1" rel="noopener noreferrer"&gt;useapi.net NotebookLM API (Gemini Notebook API)&lt;/a&gt; and bring back the finished podcast as an &lt;code&gt;.m4a&lt;/code&gt; file.&lt;/strong&gt; One is a form where you paste web pages and YouTube videos. The other watches a blog's RSS feed and turns every week's new posts into one episode. Both use only core n8n nodes and run on your own Google account, including a free one.&lt;/p&gt;

&lt;p&gt;The episode below came from the RSS workflow, pointed at Google's AI blog feed with &lt;code&gt;format&lt;/code&gt; set to &lt;code&gt;brief&lt;/code&gt; and &lt;code&gt;length&lt;/code&gt; to &lt;code&gt;short&lt;/code&gt;. Run once by hand, it picked up the two posts from the past week and produced a 1 min 43 s episode in 3 min 23 s.&lt;/p&gt;

&lt;p&gt;🎧 &lt;a href="https://useapi.net/docs/articles/notebooklm-n8n-podcast#introduction" rel="noopener noreferrer"&gt;Play on useapi.net&lt;/a&gt;&lt;br&gt;
&lt;small&gt;"Google AI Fights Cyberattacks and Disease", made by the RSS workflow from the Google AI blog feed, brief format, short length, 1 min 43 s, generated in 3 min 23 s&lt;/small&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  The two workflows
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Workflow&lt;/th&gt;
&lt;th&gt;What it does&lt;/th&gt;
&lt;th&gt;File&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Links to podcast&lt;/td&gt;
&lt;td&gt;A form: paste web pages and YouTube links, pick a format and a length, get the &lt;code&gt;.m4a&lt;/code&gt; back&lt;/td&gt;
&lt;td&gt;&lt;a href="https://github.com/useapi/notebooklm-api/blob/main/n8n/notebooklm-podcast.json" rel="noopener noreferrer"&gt;&lt;code&gt;notebooklm-podcast.json&lt;/code&gt;&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;RSS feed to weekly podcast&lt;/td&gt;
&lt;td&gt;Every Monday at 7:00, the newest posts of a feed become one episode&lt;/td&gt;
&lt;td&gt;&lt;a href="https://github.com/useapi/notebooklm-api/blob/main/n8n/notebooklm-rss-podcast.json" rel="noopener noreferrer"&gt;&lt;code&gt;notebooklm-rss-podcast.json&lt;/code&gt;&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Both files are in the &lt;a href="https://github.com/useapi/notebooklm-api/tree/main/n8n" rel="noopener noreferrer"&gt;notebooklm-api&lt;/a&gt; repository on GitHub, MIT-licensed. They were tested on self-hosted n8n 2.41.&lt;/p&gt;

&lt;h3&gt;
  
  
  How they work
&lt;/h3&gt;

&lt;p&gt;The form workflow asks for a title, the links (up to 50, one per line), the podcast format and the length. Then it:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;creates a notebook with &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-notebooks" rel="noopener noreferrer"&gt;POST /notebooks&lt;/a&gt; and adds the links with &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sources" rel="noopener noreferrer"&gt;POST /sources&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;checks the notebook every 10 seconds until Google has read every source.&lt;/li&gt;
&lt;li&gt;starts the Audio Overview with &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-artifacts" rel="noopener noreferrer"&gt;POST /artifacts&lt;/a&gt; and polls &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-jobs-jobid" rel="noopener noreferrer"&gt;GET /jobs&lt;/a&gt; every 20 seconds.&lt;/li&gt;
&lt;li&gt;downloads the &lt;code&gt;.m4a&lt;/code&gt; as binary data for the next node.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The RSS workflow does the same from a Schedule Trigger. It reads the feed, keeps the posts published in the last &lt;code&gt;lookbackDays&lt;/code&gt; days (7 by default), newest first and at most &lt;code&gt;maxPosts&lt;/code&gt; (5), and puts them in one notebook named &lt;code&gt;&amp;lt;showName&amp;gt;, &amp;lt;date&amp;gt;&lt;/code&gt;. A week with no new posts makes no episode. The schedule runs in your n8n instance's time zone.&lt;/p&gt;

&lt;p&gt;The formats are &lt;code&gt;deep_dive&lt;/code&gt;, &lt;code&gt;brief&lt;/code&gt;, &lt;code&gt;critique&lt;/code&gt; and &lt;code&gt;debate&lt;/code&gt;, and the lengths are &lt;code&gt;short&lt;/code&gt;, &lt;code&gt;default&lt;/code&gt; and &lt;code&gt;long&lt;/code&gt;. The Settings node (form) or Feed settings node (RSS) also holds &lt;code&gt;language&lt;/code&gt;, for example &lt;code&gt;es&lt;/code&gt;, &lt;code&gt;pt_BR&lt;/code&gt; or &lt;code&gt;zh_Hans&lt;/code&gt;, and &lt;code&gt;email&lt;/code&gt;, which you leave empty unless you want one specific Google account.&lt;/p&gt;

&lt;h3&gt;
  
  
  Set it up
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Get a useapi.net &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt; and connect your Google account with the &lt;a href="https://useapi.net/docs/start-here/setup-gemini-notebook" rel="noopener noreferrer"&gt;NotebookLM setup&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;In n8n, import the file with Workflows → Import from File.&lt;/li&gt;
&lt;li&gt;Create a Header Auth credential, for example called &lt;code&gt;useapi.net API token&lt;/code&gt;, with Name &lt;code&gt;Authorization&lt;/code&gt; and Value &lt;code&gt;Bearer &amp;lt;your API token&amp;gt;&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Select that credential on the six HTTP Request nodes: Create notebook, Add sources, Check sources, Generate Audio Overview, Check job and Download audio.&lt;/li&gt;
&lt;li&gt;For the form, click Execute workflow to test it, or publish (activate) the workflow and open its form URL. For RSS, put your feed in the Feed settings node, click Execute workflow to try it, then publish (activate) it.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;A short brief takes about 3 to 10 minutes. Add a Google Drive, S3, Telegram or podcast-host node after Download audio to send each episode where you need it. If you change the RSS schedule, change &lt;code&gt;lookbackDays&lt;/code&gt; to match, for example a daily run with &lt;code&gt;lookbackDays: 1&lt;/code&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  When something goes wrong
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;A &lt;code&gt;401&lt;/code&gt; on the first HTTP node means the credential is missing or the token is wrong. Check that the value starts with &lt;code&gt;Bearer&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;A &lt;code&gt;429&lt;/code&gt; on Generate Audio Overview means the Google account is out of NotebookLM usage for now, and the run stops there. The response carries &lt;code&gt;retryAt&lt;/code&gt; when Google names the reset time. To make more episodes, connect more Google accounts through the &lt;a href="https://useapi.net/docs/start-here/setup-gemini-notebook" rel="noopener noreferrer"&gt;NotebookLM setup&lt;/a&gt; and leave &lt;code&gt;email&lt;/code&gt; empty. New notebooks then go to the least busy account, so the next run can land on one that still has usage.&lt;/li&gt;
&lt;li&gt;A failed job stops the workflow with the error Google returned.&lt;/li&gt;
&lt;li&gt;A source that ends in &lt;code&gt;error&lt;/code&gt;, for example a YouTube video without captions, is skipped and the episode uses the rest.&lt;/li&gt;
&lt;li&gt;The workflows keep polling until the sources are read and the job finishes. Stop a run that has been polling for more than about 20 minutes.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  What it costs
&lt;/h3&gt;

&lt;p&gt;A flat &lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;$15/month&lt;/a&gt; for useapi.net, which covers every useapi.net API. There is no charge per episode. NotebookLM's usage limits come from your Google plan, and each subscription lets you connect 3 Google accounts, up to 100 in total, to make more. See &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1#run-notebooklm-at-scale" rel="noopener noreferrer"&gt;Run NotebookLM at scale&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  More ways to use the NotebookLM API
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/articles/notebooklm-podcast-example" rel="noopener noreferrer"&gt;A real example&lt;/a&gt;: one podcast, a video overview and an infographic from the same two sources.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/articles/gemini-notebook-bash" rel="noopener noreferrer"&gt;The full tutorial&lt;/a&gt;: every Studio output, chat with citations and Deep Research, with &lt;code&gt;curl&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://github.com/useapi/notebooklm-api" rel="noopener noreferrer"&gt;GitHub examples&lt;/a&gt;: Node.js, Python, a Colab notebook and an agent skill for Claude Code and Codex.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Frequently asked questions
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Does NotebookLM have an API?&lt;/strong&gt; Google offers a NotebookLM Enterprise API to Google Cloud customers with Enterprise licenses. Of the Studio outputs, it makes Audio Overviews only. The &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1" rel="noopener noreferrer"&gt;useapi.net NotebookLM API&lt;/a&gt; drives your own Google account instead, free or paid, and covers every Studio output.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Do I need n8n Cloud?&lt;/strong&gt; No. Both workflows use only core nodes. They were tested on self-hosted n8n and need nothing Cloud-only.&lt;/p&gt;

&lt;h3&gt;
  
  
  Start using the API
&lt;/h3&gt;

&lt;p&gt;A single &lt;strong&gt;$15/month&lt;/strong&gt; subscription covers every API on useapi.net — one token, all services. You connect up to 3 of your own provider accounts per service, and useapi.net handles the REST API, load balancing, and polling.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://buy.stripe.com/8x2aEX4Bd8Vh9PMg4qeUU03" rel="noopener noreferrer"&gt;Subscribe — $15/month&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;Pricing, crypto payment, and volume options&lt;/a&gt; — full refund within the first 14 days if you have fewer than 50 successful generations.&lt;/p&gt;

</description>
      <category>notebooklm</category>
      <category>n8n</category>
      <category>automation</category>
      <category>ai</category>
    </item>
    <item>
      <title>How to Make UGC Video Ads in n8n with the Google Flow API</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Sun, 04 Oct 2026 00:25:41 +0000</pubDate>
      <link>https://dev.to/useapi/how-to-make-ugc-video-ads-in-n8n-with-the-google-flow-api-3b2n</link>
      <guid>https://dev.to/useapi/how-to-make-ugc-video-ads-in-n8n-with-the-google-flow-api-3b2n</guid>
      <description>&lt;h3&gt;
  
  
  Introduction
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;A free n8n template makes AI UGC video ads through the &lt;a href="https://useapi.net/docs/api-google-flow-v1" rel="noopener noreferrer"&gt;useapi.net Google Flow API&lt;/a&gt;: one form, up to five products, a consistent Omni 1.1 Flash presenter and voice, and 140 Flow credits for the default ad with four takes of each clip.&lt;/strong&gt; There is no code to write. You open one form URL and click through it, and every free step has a page to pick or re-roll before the clips spend any credits.&lt;/p&gt;

&lt;p&gt;UGC ads are the one-person-talking-to-a-phone videos that fill TikTok, Reels and Shorts. Making them with AI is easy to start and hard to finish, because the presenter's face drifts, the voice changes from clip to clip, and the product on the table turns into a different product. This workflow is built around those three problems. The face and the voice are saved together as one character, every product gets a four-view reference sheet or your real photo, and every clip is filmed in one scene you picked.&lt;/p&gt;

&lt;p&gt;The video model is &lt;a href="https://deepmind.google/models/model-cards/gemini-omni-flash/" rel="noopener noreferrer"&gt;Omni 1.1 Flash&lt;/a&gt;, Google's audio-native model, so the presenter speaks the lines you write, in the voice you picked, with lip sync, in one generation. If you would rather do it in code, the &lt;a href="https://useapi.net/docs/articles/google-flow-ugc-product-video" rel="noopener noreferrer"&gt;UGC product video tutorial&lt;/a&gt; builds a similar video with plain API calls in first-and-last-frame mode, which pins the set exactly but cannot carry a picked voice.&lt;/p&gt;



&lt;strong&gt;"My beauty secrets"&lt;/strong&gt;, a deadpan parody ad&lt;br&gt;&lt;small&gt;made with this n8n template, 1080p, 32 seconds&lt;/small&gt;



&lt;h3&gt;
  
  
  What you need
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;An &lt;a href="https://n8n.io" rel="noopener noreferrer"&gt;n8n&lt;/a&gt; instance. The workflow uses only core n8n nodes, with no community nodes. It was tested on self-hosted n8n 2.41.&lt;/li&gt;
&lt;li&gt;A useapi.net account with an &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt;. One &lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;$15/month subscription&lt;/a&gt; covers every useapi.net API, with no per-call surcharge.&lt;/li&gt;
&lt;li&gt;A Google account &lt;a href="https://useapi.net/docs/start-here/setup-google-flow" rel="noopener noreferrer"&gt;connected to useapi.net&lt;/a&gt;, on a paid &lt;a href="https://one.google.com/ai" rel="noopener noreferrer"&gt;Google AI&lt;/a&gt; plan. Omni 1.1 Flash video needs a paid plan and spends its Flow credits.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  How to import the n8n UGC ad template
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Download &lt;a href="https://github.com/useapi/google-flow-api/blob/main/n8n/ugc-ad-factory.json" rel="noopener noreferrer"&gt;&lt;code&gt;ugc-ad-factory.json&lt;/code&gt;&lt;/a&gt; from the example repo, and in n8n choose &lt;strong&gt;Workflows → Import from File&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Create a &lt;strong&gt;Header Auth&lt;/strong&gt; credential whose Name is &lt;code&gt;Authorization&lt;/code&gt; and Value is &lt;code&gt;Bearer &amp;lt;your API token&amp;gt;&lt;/code&gt;, then select it on every HTTP Request node.&lt;/li&gt;
&lt;li&gt;Publish (activate) the workflow and open the URL of the &lt;strong&gt;Start form&lt;/strong&gt; node.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The form is the whole interface. Nothing in the canvas needs editing to make an ad, and the defaults produce a working ad on the first run: a friendly presenter at a bathroom vanity showing a vitamin C serum, with a short intro and a call to action at the end.&lt;/p&gt;

&lt;h3&gt;
  
  
  The pages, one by one
&lt;/h3&gt;

&lt;h4&gt;
  
  
  Setup
&lt;/h4&gt;

&lt;p&gt;The first page asks only for the shape of the ad: the Google account email, where the presenter comes from, how many products (1 to 5), whether to add an intro and a closing clip, vertical 9:16 or horizontal 16:9, and how many takes to film of each clip (1 to 4, default 4). The next page then asks for exactly that many details, with no empty fields.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-01-setup.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-01-setup.png" alt="The setup page of the n8n UGC ad form: account, presenter source, number of products, intro, closing, format and takes" width="800" height="685"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  Details
&lt;/h4&gt;

&lt;p&gt;Here you describe the presenter, the voice, the scene and every clip. Each clip is one sentence of action plus the line in quotes, for example: &lt;em&gt;The presenter picks up the serum, holds it up so the label faces the camera, and says: "This vitamin C serum goes on first every morning."&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Depending on what you chose on the setup page, this page can take photos or an ID instead of descriptions:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Photos of the presenter. One clear photo is enough, and a second one in three-quarter view saves a step. Google screens real faces, so a photo of a real person may be refused when the video is made.&lt;/li&gt;
&lt;li&gt;A saved character ID from an earlier run on the same Google account. It brings the face and the voice, and skips the next three pages.&lt;/li&gt;
&lt;li&gt;A photo of each product. It is used as it is, or turned into a four-view sheet if you choose that option.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-02-details.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-02-details.png" alt="The details page: the presenter, the voice, the scene and what is said in each clip" width="800" height="2209"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  Presenter and second angle
&lt;/h4&gt;

&lt;p&gt;Four presenters are generated from your description. Pick one, or re-roll four new ones with a note such as "older, shorter hair". The next page makes four three-quarter views of the same face, because a second angle helps the face hold in video. A single uploaded photo starts the workflow at the second-angle page, and two photos skip straight to the voice.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-03-presenters.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-03-presenters.png" alt="Four generated presenter candidates to pick from or re-roll" width="800" height="655"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-04-angles.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-04-angles.png" alt="Four three-quarter views of the picked presenter" width="800" height="655"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  Voice
&lt;/h4&gt;

&lt;p&gt;Four of Google's preset voices read your sample line, and you play them in the page. Pick one, or ask for four more, optionally with a new delivery note such as "calmer, British accent". The picked voice and the two angles are saved as one character, and that character is used in every clip, which is what keeps the voice the same across the ad.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-05-voices.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-05-voices.png" alt="The voice page: preset voices reading the sample line, with players" width="800" height="655"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  Product images
&lt;/h4&gt;

&lt;p&gt;Each product gets four reference sheets, each showing the same product from four angles. Pick one per product, or re-roll any single product while the others keep their picks. An uploaded photo appears as it is, with nothing to choose.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-06-products.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-06-products.png" alt="Four four-view sheets for each product: a rat poison night cream, garden shears and a cheese grater" width="800" height="1076"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  Scene
&lt;/h4&gt;

&lt;p&gt;Four candidates of the presenter with every product in one frame. Every clip is filmed in the scene you pick, so this is where you choose the set, the framing and where each product stands. This page is the last free step, and it shows what the clips will cost before you continue, for example "3 clips × 4 takes ≈ 140 credits".&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-07-scenes.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-07-scenes.png" alt="Scene candidates with the presenter and all three products, and the credit cost of the clips" width="800" height="897"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  Takes
&lt;/h4&gt;

&lt;p&gt;All the takes play in the page, one row per clip. Pick the best take of each clip, or re-roll only the clips you don't like. If Google refuses a clip, the page shows why and puts the clip's action in an editable box. In testing, a refused "lifts the shears in front of the chest" went through on the first try as "points at the shears on the table". Choose 1080p or 720p for the final video.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-08-takes.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-08-takes.png" alt="The takes page: every take plays in the page, pick one per clip or re-roll" width="800" height="2022"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  Your ad
&lt;/h4&gt;

&lt;p&gt;The last page plays the finished ad and links the MP4. The MP4 is joined on request by the workflow's own download URL, so nothing is stored in n8n, and the clips stay in your Flow account. Your n8n URL must be reachable from the browser you use. If a join between two clips has a pause or clips a word, set how much is cut from the start or end of each clip and re-join, which is free and takes about half a minute. The page also shows the character ID, so the same presenter, with the same face and voice, can front your next ad.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-09-your-ad.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-09-your-ad.png" alt="The last page: the joined ad, the MP4 download, the cut points between clips and the saved character ID" width="800" height="1406"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  How long it takes
&lt;/h3&gt;

&lt;p&gt;The image pages are quick, and slower when captcha needs retries. The clips take 5 to 15 minutes, and the upscale and join a few more. While a step runs, the button turns into a status panel that says what is being made, how long it usually takes, and how long it has been working. Refreshing the page brings you to the next one when it is ready.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-07b-working-clips.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-10-03-google-flow-n8n-ugc-ads%2Fn8n-ugc-v3-07b-working-clips.png" alt="The status panel while the clips are being filmed: what is being made, how long it usually takes, and a running clock" width="780" height="451"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  How much does an AI UGC ad cost?
&lt;/h3&gt;

&lt;p&gt;Everything except the video clips is free: the presenters, angles, voices, character, product sheets, scenes, the 1080p upscale and the final join. Each Omni 1.1 Flash take spends Flow credits from your Google AI plan, the same as making it in Flow yourself: 7, 10, 12 or 15 credits for a 4, 6, 8 or 10 second clip at 720p.&lt;/p&gt;

&lt;p&gt;The default ad is a 6-second intro, one 10-second product clip and a 6-second closing, which is 35 credits per round of takes and 140 credits with four takes of each clip.&lt;/p&gt;

&lt;p&gt;The same ad on the official &lt;a href="https://ai.google.dev/gemini-api/docs/pricing" rel="noopener noreferrer"&gt;Gemini API&lt;/a&gt; is billed per second of video and per image. Omni 1.1 Flash costs about $0.10 per second of 720p video there, and a Nano Banana Pro image $0.134. The table compares one finished ad with four takes of every clip and one round of images, before any re-rolls, leaving out the flat useapi.net subscription:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Ad (4 takes per clip)&lt;/th&gt;
&lt;th&gt;Official Gemini API&lt;/th&gt;
&lt;th&gt;useapi.net, Flow Pro&lt;/th&gt;
&lt;th&gt;useapi.net, Flow Ultra&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Default: intro 6 s, one product 10 s, closing 6 s&lt;/td&gt;
&lt;td&gt;$11.06&lt;/td&gt;
&lt;td&gt;$2.80&lt;/td&gt;
&lt;td&gt;$1.40&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Parody above: intro 6 s, three products 10 s each&lt;/td&gt;
&lt;td&gt;$17.81&lt;/td&gt;
&lt;td&gt;$4.40&lt;/td&gt;
&lt;td&gt;$2.20&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Largest: intro 6 s, five products 10 s each, closing 6 s&lt;/td&gt;
&lt;td&gt;$29.43&lt;/td&gt;
&lt;td&gt;$7.60&lt;/td&gt;
&lt;td&gt;$3.80&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The official column is the video seconds at $0.10 plus the images at $0.134 each (16, 24 and 32 images). The useapi.net columns are the Flow credits at about $0.02 each on Pro and $0.01 on Ultra, with images free. That is about 4 times cheaper on Pro and 8 times cheaper on Ultra, and every re-roll of an image costs nothing instead of $0.134. The per-plan figures come from the &lt;a href="https://useapi.net/docs/api-google-flow-v1#pricing" rel="noopener noreferrer"&gt;Google Flow price comparison&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Re-rolling a clip costs its takes again, and a refused clip costs nothing. The full credit table is on &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-videos#model-capabilities" rel="noopener noreferrer"&gt;POST /videos&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  How to keep the face and voice consistent across clips
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;One character holds the face and the voice. It is made from two angles of the presenter plus the voice you picked, through &lt;a href="https://useapi.net/docs/api-google-flow-v1/post-google-flow-characters" rel="noopener noreferrer"&gt;POST /characters&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Every clip is filmed in reference mode with up to four inputs: the character, the scene you picked, the product handled in that clip (if any), and the voice. In the test ads the voice stayed within the range a single speaker covers from line to line, across every clip.&lt;/li&gt;
&lt;li&gt;Each clip's action ends with the presenter putting the product back where it was, so the table looks the same at every cut.&lt;/li&gt;
&lt;li&gt;Takes absorb the rest. Reference mode lets the model reinterpret the scene a little, so framing can shift slightly between clips and the occasional take is off. Several takes per clip give you a choice, and picking costs nothing extra.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  When something goes wrong
&lt;/h3&gt;

&lt;p&gt;Every API call's result is sorted into one of three kinds, and each kind is handled differently.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Kind&lt;/th&gt;
&lt;th&gt;Examples&lt;/th&gt;
&lt;th&gt;What the workflow does&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Temporary&lt;/td&gt;
&lt;td&gt;captcha failures, &lt;code&gt;429&lt;/code&gt;, Google &lt;code&gt;503&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Retries automatically, up to five times 5 seconds apart, then shows the failure with a re-roll, or a stop page if the character can't be created. A clip that already went through is never submitted twice&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Refused&lt;/td&gt;
&lt;td&gt;Google's content filters, such as &lt;code&gt;PUBLIC_ERROR_DANGER_FILTER&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Shows the reason and asks you to change the description or the action&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Dead end&lt;/td&gt;
&lt;td&gt;a wrong token, an account that isn't connected, a plan that can't use the model&lt;/td&gt;
&lt;td&gt;Stops with a page that says what to fix&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The account, its plan and its Flow credits are checked right after the details page, and the credits again just before the clips, so a dead end stops the run before anything is spent.&lt;/p&gt;

&lt;p&gt;If upscaling a clip fails, that clip stays 720p and the last page offers to retry just the failed ones, which is free.&lt;/p&gt;

&lt;h3&gt;
  
  
  Customize it
&lt;/h3&gt;

&lt;p&gt;The &lt;strong&gt;Settings&lt;/strong&gt; node holds the defaults for the details page, the image model (&lt;code&gt;nano-banana-pro&lt;/code&gt;) and the number of captcha attempts per request. The clip prompt is in the &lt;strong&gt;Clip requests&lt;/strong&gt; node. Everything the workflow calls is a documented endpoint, so any step can be changed with the &lt;a href="https://useapi.net/docs/api-google-flow-v1" rel="noopener noreferrer"&gt;Google Flow API reference&lt;/a&gt; at hand.&lt;/p&gt;

&lt;h3&gt;
  
  
  Examples
&lt;/h3&gt;

&lt;p&gt;Both were made with this workflow and are Omni 1.1 Flash output, re-encoded to a smaller size for hosting.&lt;/p&gt;

&lt;strong&gt;"My beauty secrets"&lt;/strong&gt;, a parody beauty ad&lt;br&gt;&lt;small&gt;made with this n8n template, 1080p, 32 seconds&lt;/small&gt;



&lt;strong&gt;Uploaded presenter photo and product photo&lt;/strong&gt;&lt;br&gt;&lt;small&gt;coffee, two products, 16:9, 15 s&lt;/small&gt;



&lt;h3&gt;
  
  
  Frequently asked questions
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Do I need to write any code?&lt;/strong&gt; No. You import one JSON file, add one credential and open a form. The workflow can be read and changed in n8n like any other, but making an ad never needs it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I use my own product photos?&lt;/strong&gt; Yes. Upload a PNG, JPEG or WebP of up to 20 MB on the details page. It is used as it is, or turned into a four-view sheet if the product gets turned around on camera.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I use a real person as the presenter?&lt;/strong&gt; You can upload photos of a presenter, but Google screens identifiable people, so a real face may be refused when the clips are made. A generated presenter avoids that, and the saved character ID lets you reuse the same one in every ad on the same Google account.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Does the voice stay the same in every clip?&lt;/strong&gt; Yes, when the character has a voice, which every character this workflow creates does. The voice you pick is saved in the character together with the face, and every clip is made from that character. Picking from four previews also means you hear the voice before any clip is made.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can it make square videos?&lt;/strong&gt; No. Omni 1.1 Flash makes vertical (9:16) and horizontal (16:9) video, and the form offers those two formats.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How many products can one ad show?&lt;/strong&gt; Up to five, each with its own clip, plus the optional intro and closing, so seven clips at most.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Does it work on n8n Cloud?&lt;/strong&gt; It uses only core n8n nodes, so it should, but it has only been tested on self-hosted n8n 2.41. The one requirement is that the browser can reach your n8n URL, because the last page plays the ad from the workflow's own download URL.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How long does one ad take?&lt;/strong&gt; The free pages are quick, and every re-roll adds a little. The clips take 5 to 15 minutes, and the upscale and join a few more.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What does an ad cost?&lt;/strong&gt; The &lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;useapi.net subscription&lt;/a&gt; is a flat $15 a month, and the clips spend the Flow credits of your Google AI plan, 7 to 15 per take depending on length. The default ad with four takes per clip is 140 credits. See the cost section.&lt;/p&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;Visit our &lt;a href="https://discord.gg/w28uK3cnmF" rel="noopener noreferrer"&gt;Discord Server&lt;/a&gt; or &lt;a href="https://t.me/use_api" rel="noopener noreferrer"&gt;Telegram Channel&lt;/a&gt; for any support questions and concerns.&lt;/p&gt;

&lt;p&gt;Check our &lt;a href="https://github.com/useapi/google-flow-api" rel="noopener noreferrer"&gt;GitHub repo&lt;/a&gt; with code examples.&lt;/p&gt;

</description>
      <category>n8n</category>
      <category>omniflash</category>
      <category>ugc</category>
      <category>ai</category>
    </item>
    <item>
      <title>How to Automate NotebookLM with the Gemini Notebook API: Deep Research, Chat, Audio Overviews and a Lot More</title>
      <dc:creator>useapi.net</dc:creator>
      <pubDate>Wed, 30 Sep 2026 03:43:30 +0000</pubDate>
      <link>https://dev.to/useapi/how-to-automate-notebooklm-with-the-gemini-notebook-api-deep-research-chat-audio-overviews-and-a-5cmj</link>
      <guid>https://dev.to/useapi/how-to-automate-notebooklm-with-the-gemini-notebook-api-deep-research-chat-audio-overviews-and-a-5cmj</guid>
      <description>&lt;h3&gt;
  
  
  Introduction
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;The &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1" rel="noopener noreferrer"&gt;useapi.net Gemini Notebook API&lt;/a&gt; is a REST API for Google's &lt;a href="https://notebook.google.com" rel="noopener noreferrer"&gt;Gemini Notebook&lt;/a&gt;, formerly NotebookLM, that you can call from any language that can send an HTTP request.&lt;/strong&gt; It drives your own Google account: notebooks, sources, grounded chat, notes, web research, sharing and every Studio artifact. It also runs unattended: jobs spread across your connected accounts by remaining usage and are tracked server-side, so nobody has to watch the usage limits or decide when the next batch can start (see the FAQ).&lt;/p&gt;

&lt;p&gt;Four sources and two research questions went in, and 30 minutes of API calls later the notebook held an Audio Overview, an 11-minute Video Overview, a slide deck, an infographic, a Deep Research report and every text artifact Studio makes. Everything below is real output, and every call that made it is further down the page.&lt;/p&gt;

&lt;h3&gt;
  
  
  Sources and prompts
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Input&lt;/th&gt;
&lt;th&gt;What it is&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Web page&lt;/td&gt;
&lt;td&gt;
&lt;a href="https://en.wikipedia.org/wiki/Apollo_11" rel="noopener noreferrer"&gt;Apollo 11 on Wikipedia&lt;/a&gt;, 27,095 words&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;YouTube video&lt;/td&gt;
&lt;td&gt;
&lt;a href="https://www.youtube.com/watch?v=xUcYQ7slmRw" rel="noopener noreferrer"&gt;A New Look at the Apollo 11 Landing Site&lt;/a&gt;, NASA Goddard&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Pasted text&lt;/td&gt;
&lt;td&gt;One paragraph, "Why Apollo 11 almost did not land"&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;PDF upload&lt;/td&gt;
&lt;td&gt;The same Wikipedia article as a 3.8 MB PDF&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Chat question&lt;/td&gt;
&lt;td&gt;"What went wrong during the descent, and how did the crew handle it?", then "How much fuel was left when they landed?"&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Discover sources&lt;/td&gt;
&lt;td&gt;"Apollo 11 lunar module guidance computer alarms"&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Deep Research&lt;/td&gt;
&lt;td&gt;"Why did the Apollo 11 landing nearly abort?"&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  Results
&lt;/h3&gt;

&lt;strong&gt;Video Overview&lt;/strong&gt; — explainer, whiteboard style, 11 min 50 s&lt;br&gt;&lt;small&gt;the first 90 seconds, cut without re-encoding for our media host · [step 18](#18-a-video-overview-and-a-slide-deck)&lt;/small&gt;



&lt;p&gt;&lt;a href="https://media.useapi.net/articles/2026-09-29-gemini-notebook-bash/gemini-notebook-tutorial-pro-slides-presenter-apollo11-slide1-0929.png" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-09-29-gemini-notebook-bash%2Fgemini-notebook-tutorial-pro-slides-presenter-apollo11-slide1-0929.png" alt="Slide 1 of the Apollo 11 Mission deck generated by the Gemini Notebook API" width="800" height="447"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;strong&gt;Slide deck&lt;/strong&gt; — presenter format, 8 slides, &lt;code&gt;pdf&lt;/code&gt; + &lt;code&gt;pptx&lt;/code&gt;&lt;br&gt;&lt;small&gt;[the whole deck as PDF](https://media.useapi.net/articles/2026-09-29-gemini-notebook-bash/gemini-notebook-tutorial-pro-slides-presenter-apollo11-deck-0929.pdf) · [step 18](#18-a-video-overview-and-a-slide-deck)&lt;/small&gt;



&lt;p&gt;&lt;a href="https://media.useapi.net/articles/2026-09-29-gemini-notebook-bash/gemini-notebook-tutorial-pro-slides-presenter-apollo11-slide2-0929.png" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-09-29-gemini-notebook-bash%2Fgemini-notebook-tutorial-pro-slides-presenter-apollo11-slide2-0929.png" alt="Slide 2 before the revision" width="800" height="447"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;strong&gt;Slide 2&lt;/strong&gt; as generated



&lt;p&gt;&lt;a href="https://media.useapi.net/articles/2026-09-29-gemini-notebook-bash/gemini-notebook-tutorial-pro-slides-presenter-apollo11-slide2-revised-timeline-0929.png" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-09-29-gemini-notebook-bash%2Fgemini-notebook-tutorial-pro-slides-presenter-apollo11-slide2-revised-timeline-0929.png" alt="Slide 2 after the revision, redrawn as a timeline" width="800" height="447"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;strong&gt;Slide 2 revised&lt;/strong&gt; — "Make this slide a simple timeline graphic."&lt;br&gt;&lt;small&gt;51 seconds · [step 19](#19-revise-one-slide)&lt;/small&gt;



&lt;p&gt;&lt;a href="https://media.useapi.net/articles/2026-09-29-gemini-notebook-bash/gemini-notebook-tutorial-pro-infographic-sketch-note-apollo11-0929.png" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmedia.useapi.net%2Farticles%2F2026-09-29-gemini-notebook-bash%2Fgemini-notebook-tutorial-pro-infographic-sketch-note-apollo11-0929.png" alt="Apollo 11 Mission Infographic Overview generated by the Gemini Notebook API" width="800" height="1433"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;strong&gt;Infographic&lt;/strong&gt; — portrait, sketch note, 1536 × 2752&lt;br&gt;&lt;small&gt;1 min 45 s · [step 11](#11-an-audio-overview-and-an-infographic)&lt;/small&gt;



&lt;p&gt;🎧 &lt;a href="https://useapi.net/docs/articles/gemini-notebook-bash#results" rel="noopener noreferrer"&gt;Play on useapi.net&lt;/a&gt;&lt;/p&gt;
&lt;strong&gt;Audio Overview&lt;/strong&gt; — brief, short, 1 min 31 s&lt;br&gt;&lt;small&gt;"Fifty Seconds of Fuel and Lunar Isolation" · 4 min 36 s to generate · [step 11](#11-an-audio-overview-and-an-infographic)&lt;/small&gt;



&lt;p&gt;And as text or JSON, ready to use in your own app:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Result&lt;/th&gt;
&lt;th&gt;What came back&lt;/th&gt;
&lt;th&gt;Time&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Chat answer&lt;/td&gt;
&lt;td&gt;4,237 characters with 21 numbered citations, and a follow-up in the same conversation&lt;/td&gt;
&lt;td&gt;35 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Discover sources&lt;/td&gt;
&lt;td&gt;10 web pages with one-line descriptions, 3 imported&lt;/td&gt;
&lt;td&gt;16 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Deep Research&lt;/td&gt;
&lt;td&gt;A 26,878-character cited report on 30 web sources, imported as a source&lt;/td&gt;
&lt;td&gt;3 min 40 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Quiz&lt;/td&gt;
&lt;td&gt;6 questions with answer options, hints and rationales&lt;/td&gt;
&lt;td&gt;33 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Flashcards&lt;/td&gt;
&lt;td&gt;20 cards&lt;/td&gt;
&lt;td&gt;18 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Mind map&lt;/td&gt;
&lt;td&gt;A JSON tree of the whole topic&lt;/td&gt;
&lt;td&gt;92 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Briefing report&lt;/td&gt;
&lt;td&gt;27,282 characters of Markdown&lt;/td&gt;
&lt;td&gt;79 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Data table&lt;/td&gt;
&lt;td&gt;12 rows of alarms and anomalies with their causes&lt;/td&gt;
&lt;td&gt;32 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Source guide&lt;/td&gt;
&lt;td&gt;Google's summary and key topics of the Wikipedia page&lt;/td&gt;
&lt;td&gt;1 s&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  What it cost
&lt;/h3&gt;

&lt;p&gt;useapi.net is an API, not a hosted Gemini Notebook. Every call runs on a Google account of your own, which you connect once through &lt;a href="https://useapi.net/docs/start-here/setup-gemini-notebook" rel="noopener noreferrer"&gt;Setup Gemini Notebook&lt;/a&gt;, and everything it makes lives in that account. Gemini Notebook itself is free on a free Google account, and paid Google AI plans raise its limits.&lt;/p&gt;

&lt;p&gt;You pay useapi.net a flat &lt;a href="https://useapi.net/docs/subscription" rel="noopener noreferrer"&gt;$15/month&lt;/a&gt; for API access to every supported service, and nothing per generation. Each subscription lets you connect 3 Google accounts, up to 100 in total. With more than one connected, the API load-balances across them: omit &lt;code&gt;email&lt;/code&gt; and a new notebook goes to the least busy account, and a one-shot &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-artifacts#one-shot-requests" rel="noopener noreferrer"&gt;POST /artifacts&lt;/a&gt; runs on an account with a free job slot and enough usage left for the job. &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-jobs" rel="noopener noreferrer"&gt;GET /jobs&lt;/a&gt; shows the load on every account.&lt;/p&gt;

&lt;p&gt;Google meters it with a usage budget per account that refills every 5 hours, plus a weekly budget. Everything on this page used about 35% of a Google AI Pro account's 5-hour budget, across two windows (10% for the first script, 25% for the second, mostly the video and the slide deck), and 1.7% of its week. How many of each you can start with a full 5-hour budget, counting each job at Google's own estimate (so these are minimums):&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Studio action&lt;/th&gt;
&lt;th&gt;Free&lt;/th&gt;
&lt;th&gt;Pro&lt;/th&gt;
&lt;th&gt;Ultra&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Audio Overview&lt;/td&gt;
&lt;td&gt;2&lt;/td&gt;
&lt;td&gt;9&lt;/td&gt;
&lt;td&gt;181&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Video Overview&lt;/td&gt;
&lt;td&gt;2&lt;/td&gt;
&lt;td&gt;9&lt;/td&gt;
&lt;td&gt;183&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Video Overview, short&lt;/td&gt;
&lt;td&gt;2&lt;/td&gt;
&lt;td&gt;11&lt;/td&gt;
&lt;td&gt;229&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Video Overview, cinematic&lt;/td&gt;
&lt;td&gt;not available&lt;/td&gt;
&lt;td&gt;1&lt;/td&gt;
&lt;td&gt;25&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Report&lt;/td&gt;
&lt;td&gt;23&lt;/td&gt;
&lt;td&gt;92&lt;/td&gt;
&lt;td&gt;1846&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Table&lt;/td&gt;
&lt;td&gt;16&lt;/td&gt;
&lt;td&gt;67&lt;/td&gt;
&lt;td&gt;1355&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Quiz&lt;/td&gt;
&lt;td&gt;43&lt;/td&gt;
&lt;td&gt;175&lt;/td&gt;
&lt;td&gt;3478&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Flashcards&lt;/td&gt;
&lt;td&gt;52&lt;/td&gt;
&lt;td&gt;212&lt;/td&gt;
&lt;td&gt;4285&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Infographic&lt;/td&gt;
&lt;td&gt;9&lt;/td&gt;
&lt;td&gt;37&lt;/td&gt;
&lt;td&gt;745&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Slide deck&lt;/td&gt;
&lt;td&gt;1&lt;/td&gt;
&lt;td&gt;7&lt;/td&gt;
&lt;td&gt;146&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Mind map&lt;/td&gt;
&lt;td&gt;66&lt;/td&gt;
&lt;td&gt;263&lt;/td&gt;
&lt;td&gt;5217&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Chat question&lt;/td&gt;
&lt;td&gt;62&lt;/td&gt;
&lt;td&gt;243&lt;/td&gt;
&lt;td&gt;4897&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-accounts-email" rel="noopener noreferrer"&gt;GET /accounts/&lt;code&gt;email&lt;/code&gt;&lt;/a&gt; shows each account's live usage, reset times and every action's current estimate.&lt;/p&gt;

&lt;h3&gt;
  
  
  How it was built
&lt;/h3&gt;

&lt;p&gt;Two scripts ran back to back: the first (steps 1 to 14) built and researched the notebook and generated the audio, infographic and quiz, the second (steps 15 to 19) made everything else on the same notebook. Both are at the end of the page. Each step shows its result, and its &lt;code&gt;curl&lt;/code&gt; request with the response it got is one click away.&lt;/p&gt;

&lt;p&gt;You need a useapi.net &lt;a href="https://useapi.net/docs/start-here/setup-useapi" rel="noopener noreferrer"&gt;API token&lt;/a&gt; and a Google account connected through &lt;a href="https://useapi.net/docs/start-here/setup-gemini-notebook" rel="noopener noreferrer"&gt;Setup Gemini Notebook&lt;/a&gt;. Every call is also in the &lt;a href="https://www.postman.com/useapinet/useapi-net/collection/29112081-40696e39-d128-417e-984b-fe1b97e7bb00" rel="noopener noreferrer"&gt;Postman collection&lt;/a&gt; if you'd rather click than script. The steps use these variables:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;USEAPI_TOKEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"user:12345-..."&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;EMAIL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"user@example.com"&lt;/span&gt;
&lt;span class="nv"&gt;API&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;https://api.useapi.net/v1/gemini-notebook
enc&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt; jq -rn --arg v &lt;span class="s2"&gt;"$1"&lt;/span&gt; &lt;span class="s1"&gt;'$v|@uri'&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt; &lt;span class="o"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The ids the API returns name the account they belong to and contain &lt;code&gt;:&lt;/code&gt; and &lt;code&gt;@&lt;/code&gt;, so they are URL-encoded (&lt;code&gt;enc&lt;/code&gt;) whenever they go into a URL path. Studio generation and research run as jobs: the default &lt;code&gt;mode: sync&lt;/code&gt; waits up to 90 seconds and returns the finished result, or &lt;code&gt;202&lt;/code&gt; with the running job, and &lt;code&gt;mode: async&lt;/code&gt; returns &lt;code&gt;201&lt;/code&gt; with a &lt;code&gt;jobid&lt;/code&gt; at once. Poll &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-jobs-jobid" rel="noopener noreferrer"&gt;GET /jobs/&lt;code&gt;jobid&lt;/code&gt;&lt;/a&gt; or pass &lt;code&gt;replyUrl&lt;/code&gt; for a webhook.&lt;/p&gt;

&lt;h4&gt;
  
  
  1. Create a notebook
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-notebooks" rel="noopener noreferrer"&gt;POST /notebooks&lt;/a&gt; on the connected account. Omit &lt;code&gt;email&lt;/code&gt; and the API picks the least busy of your accounts.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -sS -X POST &lt;span class="s2"&gt;"$API/notebooks"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s2"&gt;"$(jq -n --arg email "&lt;/span&gt;&lt;span class="nv"&gt;$EMAIL&lt;/span&gt;&lt;span class="s2"&gt;" '{email: $email, title: "&lt;/span&gt;Apollo 11&lt;span class="s2"&gt;"}')"&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; tee notebook.json
&lt;span class="nv"&gt;NOTEBOOK&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r .notebook notebook.json&lt;span class="o"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It returned, in full (&lt;a href="https://useapi.net/assets/articles/gemini-notebook-bash/step-01-notebook.json" rel="noopener noreferrer"&gt;step-01-notebook.json&lt;/a&gt;):&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"notebook"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-notebook:62600bab-4082-4ee6-8fc3-955cee0c69cf"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"email"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user@example.com"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"title"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Apollo 11"&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;h4&gt;
  
  
  2. Add a web page, a YouTube video and pasted text
&lt;/h4&gt;

&lt;p&gt;One &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sources" rel="noopener noreferrer"&gt;POST /sources&lt;/a&gt; call takes up to 50 &lt;code&gt;urls&lt;/code&gt; (YouTube links become video sources) plus pasted &lt;code&gt;text&lt;/code&gt;. A file in the account's Google Drive goes in the same call as &lt;code&gt;drive: [{fileId, mimeType, name}]&lt;/code&gt;, and &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sources-sync" rel="noopener noreferrer"&gt;POST /sources/sync&lt;/a&gt; re-imports it after it changes.&lt;/p&gt;

&lt;h4&gt;
  
  
  3. Upload a file
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sources-upload" rel="noopener noreferrer"&gt;POST /sources/upload&lt;/a&gt; takes the file as the raw request body, with its MIME type as &lt;code&gt;Content-Type&lt;/code&gt;: PDF, Word, PowerPoint, EPUB, Markdown, text, CSV, audio, video or an image.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -sS -X POST &lt;span class="s2"&gt;"$API/sources/upload?notebook=$(enc "&lt;/span&gt;&lt;span class="nv"&gt;$NOTEBOOK&lt;/span&gt;&lt;span class="s2"&gt;")&amp;amp;name=01-apollo11-wikipedia.pdf"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: application/pdf"&lt;/span&gt; \
  --data-binary @01-apollo11-wikipedia.pdf
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It returned, in full (&lt;a href="https://useapi.net/assets/articles/gemini-notebook-bash/step-03-upload.json" rel="noopener noreferrer"&gt;step-03-upload.json&lt;/a&gt;):&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"notebook"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-notebook:62600bab-4082-4ee6-8fc3-955cee0c69cf"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"source"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-source:62600bab-4082-4ee6-8fc3-955cee0c69cf:6e04a6ea-cd2d-44cb-8be5-66f48be21a0d"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"title"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"01-apollo11-wikipedia.pdf"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"preparing"&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;h4&gt;
  
  
  4. Wait until every source is ready
&lt;/h4&gt;

&lt;p&gt;Google processes each source before it can be used. The 3.8 MB PDF took about 45 seconds, the others were ready at once.&lt;/p&gt;

&lt;h4&gt;
  
  
  5. See what a source is about
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-sources-source" rel="noopener noreferrer"&gt;GET /sources/&lt;code&gt;source&lt;/code&gt;&lt;/a&gt; returns Google's summary and key topics of one source, and with &lt;code&gt;?content=true&lt;/code&gt; the full text Google indexed from it. For the Wikipedia page the topics were Apollo spaceflight, Lunar landing, Space Race, Mission personnel and Space exploration.&lt;/p&gt;

&lt;h4&gt;
  
  
  6. Ask a question
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-chat" rel="noopener noreferrer"&gt;POST /chat&lt;/a&gt; answers from the sources with numbered citations, each naming its source and quoting the passage. This answer took 35 seconds and carried 21 citations. Send the same &lt;code&gt;conversation&lt;/code&gt; with the next question to keep the context (step 15).&lt;/p&gt;

&lt;h4&gt;
  
  
  7. Keep the answer as a note
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-notes" rel="noopener noreferrer"&gt;POST /notes&lt;/a&gt; saves text in the notebook. Notes can be listed, edited and deleted, and step 16 turns this one into a source.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -sS -X POST &lt;span class="s2"&gt;"$API/notes"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s2"&gt;"$(jq -n --arg nb "&lt;/span&gt;&lt;span class="nv"&gt;$NOTEBOOK&lt;/span&gt;&lt;span class="s2"&gt;" --arg a "&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r .answer chat.json&lt;span class="o"&gt;)&lt;/span&gt;&lt;span class="s2"&gt;" '{notebook: $nb, title: "&lt;/span&gt;What went wrong during the descent&lt;span class="s2"&gt;", content: $a}')"&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; tee note.json
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It returned, in full (&lt;a href="https://useapi.net/assets/articles/gemini-notebook-bash/step-07-note.json" rel="noopener noreferrer"&gt;step-07-note.json&lt;/a&gt;):&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"notebook"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-notebook:62600bab-4082-4ee6-8fc3-955cee0c69cf"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"note"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-note:62600bab-4082-4ee6-8fc3-955cee0c69cf:3ae0d70e-29eb-4f70-804e-0fe6c936f35f"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"title"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"What went wrong during the descent"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"content"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"During the lunar descent of Apollo 11's Lunar Module *Eagle*, a cascade of unexpected technical anomalies and environmental hazards threatened the landing, requiring rapid problem-solving from both the crew and Mission Control [1-6].\n\n---\n\n### **1. Overshooting the Planned Landing Target**\n* **What went wrong:** As descent began, Neil Armstrong and Buzz Aldrin noticed they were passing lunar landmarks two to three seconds early, meaning *Eagle* was traveling too fast and would land miles downrange of their intended target [3, 7]. Flight controllers suspected this was caused by lunar gravitational anomalies (mascons), extra air pressure in the docking tunnel, or unmodeled forces during earlier maneuvers [3, 7].\n* **How it was handled:** The crew monitored their position closely, maintained composure, and prepared to adapt to landing further west than planned [2, 3, 5, 7].\n\n---\n\n### **2. Computer Program Alarms (1201 and 1202)**\n* **What went wrong:** Five minutes into the descent burn, at about 6,000 feet above the surface, the Lunar Module Guidance Computer (LGC) raised unexpected **1201 and 1202 program alarms** [1, 4, 6]. These indicated \"executive overflows\"—the computer was receiving more data than it could process in real-time and had to postpone lower-priority tasks [1, 4]. The root cause was later identified as a radar hardware mismatch that fed spurious data from the rendezvous radar into the computer while the landing radar was also active [8-10].\n* **How it was handled:** \n  * **Mission Control:** Computer engineer **Jack Garman** recognized that the alarms were safe as long as they remained intermittent [1, 4]. Guidance Officer **Steve Bales** agreed, and CAPCOM **Charles Duke** relayed the \"GO\" call to the crew [1, 4].\n  * **Onboard Software:** Software engineered under **Margaret Hamilton** at MIT was designed to drop lower-priority tasks and prioritize critical guidance calculations, preventing a system crash or an automatic abort [11, 12].\n\n---\n\n### **3. Hazardous Landing Terrain (West Crater)**\n* **What went wrong:** When Armstrong looked out his window, he saw that the automated guidance system was targeting a boulder-strewn area surrounding a 300-foot-wide crater (West crater) [2, 5, 6]. Touching down there would have risked flipping or damaging the lander [2, 5].\n* **How it was handled:** Armstrong took **semi-automatic manual control** of *Eagle* to fly past the boulder field and find clear ground [2, 5, 6, 13, 14]. While Armstrong focused entirely on flying the spacecraft, **Buzz Aldrin called out altitude and navigation data** continuously to keep him informed [2, 5].\n\n---\n\n### **4. Dwindling Fuel and Blinding Lunar Dust**\n* **What went wrong:** Extending the flight to find a clear landing site consumed critical propellant [13, 14]. At 100 feet above the surface, the lander had only about **90 seconds of fuel remaining** [13, 14]. Additionally, the engine exhaust kicked up a blinding cloud of fine lunar dust that obscured the surface, making it difficult to judge motion and speed [14, 15].\n* **How it was handled:** Armstrong picked out large rocks projecting above the dust cloud to visually gauge *Eagle*'s horizontal speed [14, 15]. He cleared a smaller crater and brought the lander down smoothly with roughly **25 to 50 seconds of fuel remaining** before a forced abort would have become necessary [13, 14, 16, 17].\n\n---\n\n### **5. Engine Shutdown and Touchdown**\n* **What went wrong:** When a 67-inch probe hanging from *Eagle*'s footpads touched the Moon, Aldrin called \"Contact light!\" [10, 15, 18]. Engine shutdown was supposed to occur immediately to avoid gas pressure build-up under the craft, but in the intensity of the moment, Armstrong delayed shutting down the engine for about three seconds [15, 18].\n* **How it was handled:** *Eagle* settled safely on the Moon without damage [15, 18]. The crew immediately ran through post-landing checklists to secure the engine, after which Armstrong announced: *\"Houston, Tranquility Base here. The Eagle has landed\"* [10, 15, 19-21].\n\n💡 Would you like to explore what happened during the moonwalk itself, or look into the close calls the crew faced during their liftoff and ascent from the lunar surface?"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"note"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"created"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-09-29T04:57:19.000Z"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"updated"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-09-29T04:57:19.000Z"&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;h4&gt;
  
  
  8. Find more sources on the web
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-research" rel="noopener noreferrer"&gt;POST /research&lt;/a&gt; with &lt;code&gt;type: "fast"&lt;/code&gt; is Gemini Notebook's Discover sources. It returned 10 web pages in 16 seconds. Nothing enters the notebook until &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-research-import" rel="noopener noreferrer"&gt;POST /research/import&lt;/a&gt;, and three were picked. Two came back: Google could not fetch the third page (a Stack Exchange question), so it is left out of the answer and listed in the notebook with status &lt;code&gt;error&lt;/code&gt;. An import waits until Google has fetched every page, about a minute and a half here. If Google takes longer, the API answers &lt;code&gt;504&lt;/code&gt; after about two minutes and the import usually still completes, so check the notebook before you retry. Never retry blindly, since that adds every source twice.&lt;/p&gt;

&lt;h4&gt;
  
  
  9. Start a Deep Research run
&lt;/h4&gt;

&lt;p&gt;&lt;code&gt;type: "deep"&lt;/code&gt; runs Deep Research: Google reads dozens of web pages and writes a cited report. It takes minutes, so it starts async here and is collected in step 12, after the Studio jobs.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -sS -X POST &lt;span class="s2"&gt;"$API/research"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s2"&gt;"$(jq -n --arg nb "&lt;/span&gt;&lt;span class="nv"&gt;$NOTEBOOK&lt;/span&gt;&lt;span class="s2"&gt;" '{notebook: $nb, type: "&lt;/span&gt;deep&lt;span class="s2"&gt;", query: "&lt;/span&gt;Why did the Apollo 11 landing nearly abort?&lt;span class="s2"&gt;", mode: "&lt;/span&gt;async&lt;span class="s2"&gt;"}')"&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; tee deep.json
&lt;span class="nv"&gt;DEEP&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r .jobid deep.json&lt;span class="o"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It returned, in full (&lt;a href="https://useapi.net/assets/articles/gemini-notebook-bash/step-09-deep-research-submit.json" rel="noopener noreferrer"&gt;step-09-deep-research-submit.json&lt;/a&gt;):&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"jobid"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"job:e2af6631-3d2b-4630-87b1-e115620e0c4e-user:12345-user@example.com-bot:gemini_notebook"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"email"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user@example.com"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"research"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"processing"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"notebook"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-notebook:62600bab-4082-4ee6-8fc3-955cee0c69cf"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"created_at"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-09-29T04:59:08.701Z"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"request"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"notebook"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-notebook:62600bab-4082-4ee6-8fc3-955cee0c69cf"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"deep"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"query"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Why did the Apollo 11 landing nearly abort?"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;h4&gt;
  
  
  10. A quiz
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-artifacts" rel="noopener noreferrer"&gt;POST /artifacts&lt;/a&gt; with &lt;code&gt;type: "quiz"&lt;/code&gt;. It finished in 33 seconds, within the 90-second sync wait, so the call returned the finished quiz: 6 questions in &lt;code&gt;result.content.quiz&lt;/code&gt;, each with answer options, a hint and a rationale per option. Quizzes, flashcards and mind maps are JSON, ready to render in your own app.&lt;/p&gt;

&lt;h4&gt;
  
  
  11. An Audio Overview and an infographic
&lt;/h4&gt;

&lt;p&gt;Audio and video take minutes, so both went in async and were polled. The infographic finished in 1 minute 45 seconds, the Audio Overview in 4 minutes 36 seconds. Each finished job lists its files, and every file link goes through &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-artifacts-download" rel="noopener noreferrer"&gt;GET /artifacts/download&lt;/a&gt; with your token (&lt;code&gt;m4a&lt;/code&gt;, &lt;code&gt;mp4&lt;/code&gt;, &lt;code&gt;pdf&lt;/code&gt;, &lt;code&gt;pptx&lt;/code&gt;, &lt;code&gt;png&lt;/code&gt;). Both are shown in Results.&lt;/p&gt;

&lt;h4&gt;
  
  
  12. Collect the Deep Research report
&lt;/h4&gt;

&lt;p&gt;The Deep Research run from step 9 finished in 3 minutes 40 seconds, while the Studio jobs ran: "Anatomy of a Lunar Descent: Systems Architecture, Hardware Anomaly, and Human Decision-Making in the Apollo 11 Landing Near-Abort", 26,878 characters of Markdown with &lt;code&gt;[cite: n]&lt;/code&gt; markers, on 30 sources, 24 of them cited. Imported as a source (3,146 words), it grounds every later answer and artifact. &lt;code&gt;urls: []&lt;/code&gt; with &lt;code&gt;report: true&lt;/code&gt; imports the report alone, and leaving &lt;code&gt;urls&lt;/code&gt; out imports it with every cited source, as the app's Import button does.&lt;/p&gt;

&lt;h4&gt;
  
  
  13. Share the notebook
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sharing" rel="noopener noreferrer"&gt;POST /sharing&lt;/a&gt; with a public link lets anyone with it view the notebook, and &lt;code&gt;allowCopies: false&lt;/code&gt; stops them duplicating it. &lt;code&gt;people: [{email, role}]&lt;/code&gt; invites someone as &lt;code&gt;viewer&lt;/code&gt; or &lt;code&gt;editor&lt;/code&gt; (Google emails them), &lt;code&gt;role: "remove"&lt;/code&gt; takes the access away, and &lt;code&gt;link: "restricted"&lt;/code&gt; makes the notebook private again.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -sS -X POST &lt;span class="s2"&gt;"$API/sharing"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s2"&gt;"$(jq -n --arg nb "&lt;/span&gt;&lt;span class="nv"&gt;$NOTEBOOK&lt;/span&gt;&lt;span class="s2"&gt;" '{notebook: $nb, link: "&lt;/span&gt;public&lt;span class="s2"&gt;", allowCopies: false}')"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It returned, in full (&lt;a href="https://useapi.net/assets/articles/gemini-notebook-bash/step-13-sharing.json" rel="noopener noreferrer"&gt;step-13-sharing.json&lt;/a&gt;):&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"notebook"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-notebook:62600bab-4082-4ee6-8fc3-955cee0c69cf"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"people"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"email"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user@example.com"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"role"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"owner"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"User"&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"link"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"public"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"allowCopies"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;h4&gt;
  
  
  14. What the first script used
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-accounts-email" rel="noopener noreferrer"&gt;GET /accounts/&lt;code&gt;email&lt;/code&gt;&lt;/a&gt; reads the account's usage. Steps 1 to 13 took the 5-hour window from 9.6% to 19.5% and its week from 7.0% to 7.5%, in 9 minutes 20 seconds end to end.&lt;/p&gt;

&lt;h4&gt;
  
  
  15. Ask a follow-up question
&lt;/h4&gt;

&lt;p&gt;The second script starts here, on the same notebook. The &lt;code&gt;conversation&lt;/code&gt; from step 6 makes the answer build on the earlier turns: &lt;em&gt;"When the Lunar Module Eagle touched down, it had 216 pounds (98 kg) of usable fuel remaining"&lt;/em&gt;, with 5 citations.&lt;/p&gt;

&lt;h4&gt;
  
  
  16. Turn the note into a source
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-notes-source" rel="noopener noreferrer"&gt;POST /notes/source&lt;/a&gt; turns the note from step 7 into a Markdown source that later answers can cite.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -sS -X POST &lt;span class="s2"&gt;"$API/notes/source"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s2"&gt;"$(jq -n --arg n "&lt;/span&gt;&lt;span class="nv"&gt;$(&lt;/span&gt;jq -r .note note.json&lt;span class="o"&gt;)&lt;/span&gt;&lt;span class="s2"&gt;" '{note: $n}')"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It returned, in full (&lt;a href="https://useapi.net/assets/articles/gemini-notebook-bash/step-16-note-to-source.json" rel="noopener noreferrer"&gt;step-16-note-to-source.json&lt;/a&gt;):&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"notebook"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-notebook:62600bab-4082-4ee6-8fc3-955cee0c69cf"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"source"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"user:12345-user@example.com-source:62600bab-4082-4ee6-8fc3-955cee0c69cf:f9aa14ef-446a-445a-8d94-b45b1b9a5045"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"title"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"What went wrong during the descent"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"markdown"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"ready"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"words"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;656&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"created"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-09-29T05:49:29.000Z"&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;h4&gt;
  
  
  17. Flashcards, a mind map, a report and a data table
&lt;/h4&gt;

&lt;p&gt;Four sync calls, one after another: the flashcards in 18 seconds, the data table in 32, the report in 79 and the mind map in 92. The mind map outlived the 90-second sync wait, so it answered &lt;code&gt;202&lt;/code&gt; and was polled to the end. Flashcards come back as &lt;code&gt;result.content.flashcards&lt;/code&gt; (20 cards of front &lt;code&gt;f&lt;/code&gt; and back &lt;code&gt;b&lt;/code&gt;), the mind map as a JSON tree in &lt;code&gt;result.content&lt;/code&gt;, the briefing report as 27,282 characters of Markdown in &lt;code&gt;result.text&lt;/code&gt;, and the data table as &lt;code&gt;result.table&lt;/code&gt;, the header row first. The table's first rows, with the cells shortened and the Source column left out here:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Time&lt;/th&gt;
&lt;th&gt;Alarm or event&lt;/th&gt;
&lt;th&gt;Cause&lt;/th&gt;
&lt;th&gt;What the crew or Mission Control did&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Five minutes into the descent burn / MET 102:38:00–102:38:22 / PDI + 316 seconds&lt;/td&gt;
&lt;td&gt;1202 program alarm&lt;/td&gt;
&lt;td&gt;Computer overload (Executive overflow: no core sets available). High-frequency counter increment requests …&lt;/td&gt;
&lt;td&gt;Buzz Aldrin checked the alarm code using Verb 90 Noun 50 (and Verb 05 Noun 09 at PDI + 322 seconds). Computer …&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;MET 102:36:55&lt;/td&gt;
&lt;td&gt;Slow spacecraft rotation rate during pitch-over/spin maneuver&lt;/td&gt;
&lt;td&gt;Autopilot rate switch was set at 5 deg/sec.&lt;/td&gt;
&lt;td&gt;Neil Armstrong switched the autopilot rate switch from 5 deg/sec to 25 deg/sec.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;As descent began / Not in source&lt;/td&gt;
&lt;td&gt;Overshooting the Planned Landing Target / Downrange Position Offset (Trajectory shifted 3,000 ft downrange …&lt;/td&gt;
&lt;td&gt;Residual pressure in the docking tunnel during separation, lunar gravitational anomalies (mascons), and …&lt;/td&gt;
&lt;td&gt;The crew monitored their position closely, maintained composure, and prepared to adapt to landing further …&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h4&gt;
  
  
  18. A Video Overview and a slide deck
&lt;/h4&gt;

&lt;p&gt;Both async. The slide deck finished in 5 minutes 10 seconds: 8 slides, with &lt;code&gt;pdf&lt;/code&gt; and &lt;code&gt;pptx&lt;/code&gt; files and one image per slide in &lt;code&gt;result.slides&lt;/code&gt;. The Video Overview took 14 minutes and runs 11 minutes 50 seconds, a 720p &lt;code&gt;mp4&lt;/code&gt; of 59 MB. Both are shown in Results.&lt;/p&gt;

&lt;h4&gt;
  
  
  19. Revise one slide
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-artifacts-revise" rel="noopener noreferrer"&gt;POST /artifacts/revise&lt;/a&gt; redrew slide 2 from a prompt in 51 seconds. The revision is a new artifact with its own &lt;code&gt;artifact&lt;/code&gt; id, its job's result is the whole deck again with the new slide 2, and the original deck stays in the notebook. Before and after are shown in Results.&lt;/p&gt;

&lt;p&gt;The second script used about 25% of the 5-hour window and 1.2% of the week. The Video Overview and the slide deck are the expensive ones, at Google's estimate of about 11% and 14% each.&lt;/p&gt;

&lt;h3&gt;
  
  
  Shortcuts
&lt;/h3&gt;

&lt;p&gt;For a single artifact you do not need to manage a notebook. Send the sources straight to &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-artifacts#one-shot-requests" rel="noopener noreferrer"&gt;POST /artifacts&lt;/a&gt;: the API creates a notebook on one of your accounts with a free job slot whose usage window allows the job, waits for the sources, generates, and can delete the notebook afterwards for text-only types. If it answers &lt;code&gt;202&lt;/code&gt; (the job outlived the 90-second wait), poll its &lt;code&gt;jobid&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -sS -X POST &lt;span class="s2"&gt;"$API/artifacts"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{"type": "quiz", "urls": ["https://en.wikipedia.org/wiki/Apollo_11"], "deleteNotebook": true}'&lt;/span&gt; \
  &lt;span class="o"&gt;|&lt;/span&gt; jq &lt;span class="s1"&gt;'{status, questions: (.result.content.quiz | length)}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To be told when a job finishes instead of polling, pass &lt;code&gt;replyUrl&lt;/code&gt; (and optionally &lt;code&gt;replyRef&lt;/code&gt;) with &lt;code&gt;mode: async&lt;/code&gt;, on Studio jobs and research alike. The API sends one POST with the same job record &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-jobs-jobid" rel="noopener noreferrer"&gt;GET /jobs/&lt;code&gt;jobid&lt;/code&gt;&lt;/a&gt; returns. &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/delete-gemini-notebook-jobs-jobid" rel="noopener noreferrer"&gt;DELETE /jobs/&lt;code&gt;jobid&lt;/code&gt;&lt;/a&gt; stops a research run you no longer need.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -sS -X POST &lt;span class="s2"&gt;"$API/research"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $USEAPI_TOKEN"&lt;/span&gt; -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s2"&gt;"$(jq -n --arg nb "&lt;/span&gt;&lt;span class="nv"&gt;$NOTEBOOK&lt;/span&gt;&lt;span class="s2"&gt;" '{notebook: $nb, type: "&lt;/span&gt;deep&lt;span class="s2"&gt;", query: "&lt;/span&gt;How did the Apollo guidance computer recover from overloads?&lt;span class="s2"&gt;", mode: "&lt;/span&gt;async&lt;span class="s2"&gt;", replyUrl: "&lt;/span&gt;https://example.com/hooks/notebook&lt;span class="s2"&gt;", replyRef: "&lt;/span&gt;order-42&lt;span class="s2"&gt;"}')"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  More of the API
&lt;/h3&gt;

&lt;p&gt;The rest of the API, on an Apollo 11 notebook like the one above:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-notebooks-guide" rel="noopener noreferrer"&gt;GET /notebooks/guide&lt;/a&gt; returned Google's summary of the whole notebook, three suggested reports such as "Explain the technical challenges faced during the Eagle's lunar descent.", and three suggested chat questions.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-chat-settings" rel="noopener noreferrer"&gt;POST /chat/settings&lt;/a&gt; with the persona "You are a NASA flight controller. Answer in two sentences." made the next answers short and in that voice. &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-chat" rel="noopener noreferrer"&gt;GET /chat&lt;/a&gt; then returned the conversation's four turns, oldest first, and &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/delete-gemini-notebook-chat" rel="noopener noreferrer"&gt;DELETE /chat&lt;/a&gt; cleared it.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-notes" rel="noopener noreferrer"&gt;POST /notes&lt;/a&gt; with &lt;code&gt;conversation&lt;/code&gt; saved that whole conversation as one note, "Chat History", question and answer by turn.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-notes-mindmap" rel="noopener noreferrer"&gt;POST /notes/mindmap&lt;/a&gt; made a mind map note, "Apollo 11 Mission", with six branches from "Background &amp;amp; Goals" to "Legacy &amp;amp; Artifacts".&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-labels" rel="noopener noreferrer"&gt;POST /labels&lt;/a&gt; with &lt;code&gt;auto: "all"&lt;/code&gt; grouped both sources under a "Space Exploration" label. Labels of your own take a name and an emoji, and &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-labels-label" rel="noopener noreferrer"&gt;POST /labels/&lt;code&gt;label&lt;/code&gt;&lt;/a&gt; renames them and moves sources in and out.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-notebooks-copy" rel="noopener noreferrer"&gt;POST /notebooks/copy&lt;/a&gt; copied the notebook with its two sources and two Studio artifacts.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-accounts" rel="noopener noreferrer"&gt;POST /accounts&lt;/a&gt; with &lt;code&gt;outputLanguage: "es"&lt;/code&gt; switched the account's Studio output to Spanish, and back.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-research" rel="noopener noreferrer"&gt;POST /research&lt;/a&gt; with &lt;code&gt;source: "drive"&lt;/code&gt; searches the account's Google Drive instead of the web. It found a Word &lt;code&gt;.docx&lt;/code&gt; and a Google Doc about Apollo 11, and &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-research-import" rel="noopener noreferrer"&gt;POST /research/import&lt;/a&gt; added them as Drive sources. After the Doc was edited in Drive, &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-sources-source" rel="noopener noreferrer"&gt;GET /sources/&lt;code&gt;source&lt;/code&gt;&lt;/a&gt; reported it &lt;code&gt;inSync: false&lt;/code&gt;, and a few seconds later the notebook held the new text. &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sources-sync" rel="noopener noreferrer"&gt;POST /sources/sync&lt;/a&gt; re-imports a changed Drive file on request.&lt;/li&gt;
&lt;li&gt;A preset report takes extra &lt;code&gt;instructions&lt;/code&gt;: a briefing "for a high-school class, in under 300 words" came back as 1,946 characters.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  What the NotebookLM API can do
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Step&lt;/th&gt;
&lt;th&gt;Endpoint&lt;/th&gt;
&lt;th&gt;What it does&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Create a notebook&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-notebooks" rel="noopener noreferrer"&gt;POST /notebooks&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Creates an empty notebook on one of your connected accounts.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Add sources&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sources" rel="noopener noreferrer"&gt;POST /sources&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Web pages and YouTube videos (&lt;code&gt;urls&lt;/code&gt;, up to 50 per call), pasted &lt;code&gt;text&lt;/code&gt; and Google Drive files (&lt;code&gt;drive&lt;/code&gt;).&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Upload a file&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sources-upload" rel="noopener noreferrer"&gt;POST /sources/upload&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;The file is the raw request body: PDF, Word, PowerPoint, EPUB, Markdown, text, CSV, audio, video or an image.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Read a source&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-sources-source" rel="noopener noreferrer"&gt;GET /sources/&lt;code&gt;source&lt;/code&gt;&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Google's summary and key topics of one source, and with &lt;code&gt;content=true&lt;/code&gt; the text Google indexed.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Ask&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-chat" rel="noopener noreferrer"&gt;POST /chat&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;An answer from the sources with numbered citations. Pass &lt;code&gt;conversation&lt;/code&gt; for a follow-up.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Keep notes&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-notes" rel="noopener noreferrer"&gt;POST /notes&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Notes in the notebook. A note can become a source.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Research&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-research" rel="noopener noreferrer"&gt;POST /research&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;fast&lt;/code&gt; finds sources on the web in seconds, &lt;code&gt;deep&lt;/code&gt; runs Deep Research and writes a cited report.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Import research&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-research-import" rel="noopener noreferrer"&gt;POST /research/import&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Adds the sources a research run found, and its report, to the notebook.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Generate&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-artifacts" rel="noopener noreferrer"&gt;POST /artifacts&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;audio&lt;/code&gt;, &lt;code&gt;video&lt;/code&gt;, &lt;code&gt;report&lt;/code&gt;, &lt;code&gt;interactive_report&lt;/code&gt;, &lt;code&gt;table&lt;/code&gt;, &lt;code&gt;quiz&lt;/code&gt;, &lt;code&gt;flashcards&lt;/code&gt;, &lt;code&gt;mindmap&lt;/code&gt;, &lt;code&gt;infographic&lt;/code&gt; or &lt;code&gt;slides&lt;/code&gt;, each with its own options.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Revise a slide&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-artifacts-revise" rel="noopener noreferrer"&gt;POST /artifacts/revise&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Redraws one slide of a finished deck from a prompt.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Follow a job&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-jobs-jobid" rel="noopener noreferrer"&gt;GET /jobs/&lt;code&gt;jobid&lt;/code&gt;&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;The status and, once finished, the result.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Download&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-artifacts-download" rel="noopener noreferrer"&gt;GET /artifacts/download&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;The artifact's file (&lt;code&gt;m4a&lt;/code&gt;, &lt;code&gt;mp4&lt;/code&gt;, &lt;code&gt;pdf&lt;/code&gt;, &lt;code&gt;pptx&lt;/code&gt;, &lt;code&gt;png&lt;/code&gt;), streamed with your API token.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Share&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sharing" rel="noopener noreferrer"&gt;POST /sharing&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Invite people as viewers or editors, turn the public link on or off, and limit viewers to chat only.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Copy a notebook&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-notebooks-copy" rel="noopener noreferrer"&gt;POST /notebooks/copy&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;A copy with every source and Studio artifact, on the same account.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Notebook guide&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-notebooks-guide" rel="noopener noreferrer"&gt;GET /notebooks/guide&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Google's summary of the whole notebook, suggested reports and suggested chat questions.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Chat history and settings&lt;/td&gt;
&lt;td&gt;
&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-chat" rel="noopener noreferrer"&gt;GET /chat&lt;/a&gt;, &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/delete-gemini-notebook-chat" rel="noopener noreferrer"&gt;DELETE /chat&lt;/a&gt;, &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-chat-settings" rel="noopener noreferrer"&gt;POST /chat/settings&lt;/a&gt;
&lt;/td&gt;
&lt;td&gt;A conversation's turns, delete the history, and set the chat's goal, persona and answer length.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Source labels&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-labels" rel="noopener noreferrer"&gt;POST /labels&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Google labels the sources by topic, or you make and edit your own labels.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Mind map note&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-notes-mindmap" rel="noopener noreferrer"&gt;POST /notes/mindmap&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;A mind map made in one call and kept as a note.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Output language&lt;/td&gt;
&lt;td&gt;&lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-accounts" rel="noopener noreferrer"&gt;POST /accounts&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;The language Google writes Studio artifacts in, for the whole account.&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-artifacts#options-by-type" rel="noopener noreferrer"&gt;POST /artifacts&lt;/a&gt; page lists every Studio type's options.&lt;/p&gt;

&lt;h3&gt;
  
  
  Run both scripts yourself
&lt;/h3&gt;

&lt;p&gt;Both scripts save every response under a timestamped folder. The first builds the notebook, the second takes the notebook, conversation and note ids the first one printed.&lt;/p&gt;

&lt;p&gt;Both scripts are also in the &lt;a href="https://github.com/useapi/gemini-notebook-api" rel="noopener noreferrer"&gt;gemini-notebook-api GitHub repo&lt;/a&gt;, with Node.js and Python examples that turn URLs into an Audio Overview podcast and save a Deep Research report as Markdown.&lt;/p&gt;

&lt;h3&gt;
  
  
  Frequently asked questions
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Is Gemini Notebook the same as NotebookLM?&lt;/strong&gt; Yes. Gemini Notebook is Google's current name for NotebookLM, and the &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1" rel="noopener noreferrer"&gt;useapi.net Gemini Notebook API&lt;/a&gt; works as a NotebookLM API: notebooks, sources, chat, Deep Research and every Studio artifact over REST.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I generate a NotebookLM Audio Overview (podcast) through an API?&lt;/strong&gt; Yes. &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-artifacts" rel="noopener noreferrer"&gt;POST /artifacts&lt;/a&gt; with &lt;code&gt;type: "audio"&lt;/code&gt; generates an Audio Overview (&lt;code&gt;deep_dive&lt;/code&gt;, &lt;code&gt;brief&lt;/code&gt;, &lt;code&gt;critique&lt;/code&gt; or &lt;code&gt;debate&lt;/code&gt;) and returns an &lt;code&gt;m4a&lt;/code&gt; file. The short brief in this walkthrough took about 4 and a half minutes.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How does the API reach my Gemini Notebook?&lt;/strong&gt; The &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1" rel="noopener noreferrer"&gt;useapi.net Gemini Notebook API&lt;/a&gt; drives your own Google account over REST, with a single useapi.net API token. You connect the account once through &lt;a href="https://useapi.net/docs/start-here/setup-gemini-notebook" rel="noopener noreferrer"&gt;Setup Gemini Notebook&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Does it work on a free Google account?&lt;/strong&gt; Yes. Every call on this page also runs on a free account, Deep Research included. Paid Google AI plans raise the usage budget and unlock Cinematic video: Google AI Pro gives an account about four times Free's budget, and Google AI Ultra about twenty times Pro's (see What it cost).&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Which source types can I add?&lt;/strong&gt; Web pages and YouTube videos by URL, pasted text, files in the account's Google Drive (Google Docs included), and uploaded PDF, Word, PowerPoint, EPUB, Markdown, text, CSV, audio, video and image files. See &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sources" rel="noopener noreferrer"&gt;POST /sources&lt;/a&gt; and &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sources-upload" rel="noopener noreferrer"&gt;POST /sources/upload&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why did my YouTube video end with status error?&lt;/strong&gt; Google reads a YouTube video from its captions. A video with no captions at all, as with some official music videos, fails without a reason. Upload the audio or video file with &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-sources-upload" rel="noopener noreferrer"&gt;POST /sources/upload&lt;/a&gt; instead, and Google transcribes it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is the difference between fast and deep research?&lt;/strong&gt; &lt;code&gt;fast&lt;/code&gt; (Discover sources) returns about ten relevant web pages with one-line descriptions in seconds. &lt;code&gt;deep&lt;/code&gt; (Deep Research) reads dozens of pages for a few minutes and writes a cited report. Its result lists the pages it found and marks the ones the report cites. Both only suggest: nothing enters the notebook until &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-research-import" rel="noopener noreferrer"&gt;POST /research/import&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How long does a generation take?&lt;/strong&gt; Flashcards, a quiz and a data table take well under a minute, a mind map, a report or an infographic one to two minutes, an Audio Overview three to five minutes, a slide deck about five to seven, and Video Overviews ten minutes or more. See &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/post-gemini-notebook-artifacts#what-you-get-back" rel="noopener noreferrer"&gt;POST /artifacts&lt;/a&gt; for each type.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Do I have to watch the jobs and usage limits myself?&lt;/strong&gt; No. Connect several Google accounts and the API spreads the work: each new job goes to an account that is healthy, has a free job slot and still has usage left for that type. Jobs are tracked on our side, so you poll &lt;a href="https://useapi.net/docs/api-gemini-notebook-v1/get-gemini-notebook-jobs-jobid" rel="noopener noreferrer"&gt;GET /jobs/&lt;code&gt;jobid&lt;/code&gt;&lt;/a&gt; or pass &lt;code&gt;replyUrl&lt;/code&gt; and get the finished job posted to your webhook. When every account is out of usage, the &lt;code&gt;429&lt;/code&gt; carries &lt;code&gt;retryAt&lt;/code&gt; whenever Google names the reset time, so your code decides how to handle the load: wait until then, route the next batch to another account, or slow down. No one has to check in.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What happens when an account runs out of its usage window?&lt;/strong&gt; Google refuses the generation. The call answers &lt;code&gt;429&lt;/code&gt;, or the job fails with &lt;code&gt;error.code: "quota"&lt;/code&gt; when it started async, with the reset time when Google names it. Connect more accounts: one-shot requests skip accounts whose last-known usage blocks the job, and new notebooks go to the least busy account.&lt;/p&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;Visit our &lt;a href="https://discord.gg/w28uK3cnmF" rel="noopener noreferrer"&gt;Discord Server&lt;/a&gt; or &lt;a href="https://t.me/use_api" rel="noopener noreferrer"&gt;Telegram Channel&lt;/a&gt; for any support questions and concerns.&lt;/p&gt;

&lt;p&gt;Check our &lt;a href="https://github.com/useapi/gemini-notebook-api" rel="noopener noreferrer"&gt;GitHub repo&lt;/a&gt; with code examples.&lt;/p&gt;

</description>
      <category>notebooklm</category>
      <category>gemini</category>
      <category>ai</category>
      <category>api</category>
    </item>
  </channel>
</rss>
