Download raw mp3 audio

June 3, 2026

Table of contents

  1. Request Headers
  2. Query Parameters
  3. Responses
  4. Model
  5. Examples
  6. Try It

Download a generated clip as raw mp3 audio. The answer body is the audio bytes.

Every clip already carries public links to the full-quality m4a and wav files, so this call does not serve them again. Read audio_url and wav_url from GET /music or the job record, and download those files directly.

https://api.useapi.net/v1/flowmusic/music/download?id=id&format=format

Request Headers

Authorization: Bearer {API token}

Query Parameters

  • id is required. An encoded clip id, or the jobid of a completed job (its first clip). The answer is the mp3 itself.
  • format is optional.
    Supported values: mp3 (default).

A clip id looks like user:[email protected]:a1b2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d.

Stems are separate clips. When you separate a song’s stems, Google Flow Music makes one clip for each track. They show up in GET /music under the song’s title with the stem’s name after it: drums, bass, vocals and other. Download each one here with its own id, or use its audio_url or wav_url.

Responses

  • 200 OK

    The file

    You get the mp3 file itself, not JSON, as an attachment. When Google Flow Music cannot make the mp3, you get the clip’s m4a file instead, with the header X-Useapi-Audio-Fallback: m4a.

  • 400 Bad Request

    The request itself is wrong, or no usable Google Flow Music account is added. The error text says what to change.

    {
      "error": "Please configure at least one account at https://useapi.net/docs/api-flowmusic-v1/post-flowmusic-accounts",
      "code": 400
    }
    
    {
      "error": "Invalid JSON: Unexpected token 'o', \"not json\" is not valid JSON",
      "code": 400
    }
    
  • 401 Unauthorized

    The useapi.net API token is missing or wrong.

    A step at Google Flow Music failed with 401: it refused the account’s sign-in. The error text names the step.

    {
      "error": "mp3 transcode failed: 401",
      "code": 401
    }
    
    {
      "error": "useapi.net ⁝ Unauthorized",
      "code": 401
    }
    
  • 402 Payment Required

    The useapi.net subscription is not active.

    {
      "error": "useapi.net ⁝ Your account has no subscription, please subscribe to our services before submitting requests",
      "code": 402
    }
    
  • 404 Not Found

    The account, job or clip does not exist, or is no longer there.

    {
      "error": "no job with id job:2c9a1e3f-6b8d-4f0a-9e7c-1d2b3c4d5e6f-user:[email protected]:flowmusic",
      "code": 404
    }
    
    {
      "error": "Account [email protected] not configured",
      "code": 404
    }
    
  • 409 Conflict

    The job has no finished clip yet. It is still running, or it failed or was cancelled.

    {
      "error": "job job:2c9a1e3f-6b8d-4f0a-9e7c-1d2b3c4d5e6f-user:[email protected]:flowmusic is not completed yet",
      "code": 409
    }
    
  • 429 Too Many Requests

    Google Flow Music refused the request because this account sent too many at once. Retry once a running generation finishes, or a little later.

    {
      "error": "mp3 transcode failed: 429",
      "code": 429
    }
    
  • 500 Internal Server Error

    Something failed on our side.

    A step at Google Flow Music failed with 500. The error text names the step.

    {
      "error": "Cannot read properties of undefined (reading 'email')",
      "code": 500
    }
    
    {
      "error": "mp3 transcode failed: 500",
      "code": 500
    }
    
  • 502 Bad Gateway

    Google Flow Music answered with an error, or did not answer. The error text says what happened.

    {
      "error": "Upstream network failure after 4 attempts: Network connection lost.",
      "code": 502
    }
    
    {
      "error": "Upstream fetch produced no response",
      "code": 502
    }
    
    {
      "error": "mp3 transcode returned an empty body",
      "code": 502
    }
    
  • 503 Service Unavailable

    The Google Flow Music sign-in service did not answer, or another request is renewing the account’s sign-in right now. The account is unchanged. Retry in a minute, or after Retry-After when it is sent. On any call, it can also mean our service was busy for a moment.

    {
      "error": "Another request is refreshing the Google Flow Music sign-in of [email protected] right now. Retry in a few seconds.",
      "code": 503
    }
    
    {
      "error": "Google Flow Music's sign-in service did not answer (500). Retry in a minute.",
      "code": 503
    }
    
  • 596 Account Error

    The account is in an error state. Add it again with POST /accounts.

    {
      "error": "Account [email protected] in error state: Google Flow Music signed out [email protected]: its sign-in can no longer be refreshed (refresh_token_already_used), usually because it was refreshed somewhere else. Add the account again: https://useapi.net/docs/start-here/setup-flowmusic",
      "code": 596
    }
    
    {
      "error": "Google Flow Music signed out [email protected]: its sign-in can no longer be refreshed (refresh_token_already_used), usually because it was refreshed somewhere else. Add the account again: https://useapi.net/docs/start-here/setup-flowmusic",
      "code": 596
    }
    

Model

This call sends the raw mp3 bytes, not JSON, with a Content-Disposition file name: the clip id and .mp3. Only the error answers are JSON, with error and code.

Examples

  • curl "https://api.useapi.net/v1/flowmusic/music/download?id=user:[email protected]:3f9c2a7d-81e6-4b05-a9d2-c4e7b6e14d0c" \
         -H "Authorization: Bearer YOUR_API_TOKEN" \
         --output result.mp3
    
  • import { writeFile } from 'node:fs/promises'
    
    const response = await fetch('https://api.useapi.net/v1/flowmusic/music/download?id=user:[email protected]:3f9c2a7d-81e6-4b05-a9d2-c4e7b6e14d0c', {
      headers: {
        'Authorization': 'Bearer YOUR_API_TOKEN'
      }
    })
    if (response.ok && !(response.headers.get('content-type') ?? '').includes('json')) await writeFile('result.mp3', Buffer.from(await response.arrayBuffer()))
    else console.log(response.status, await response.json())
    
  • import requests
    
    response = requests.get(
        'https://api.useapi.net/v1/flowmusic/music/download',
        params={
            'id': 'user:[email protected]:3f9c2a7d-81e6-4b05-a9d2-c4e7b6e14d0c'
        },
        headers={'Authorization': 'Bearer YOUR_API_TOKEN'},
    )
    if response.ok and 'json' not in response.headers.get('content-type', ''):
        open('result.mp3', 'wb').write(response.content)
    else:
        print(response.status_code, response.json())
    

Try It