GhostfeedGhostfeed MCPv13.2.0
REST API

Songs and voiceovers

Make a song with exact lyrics or an instrumental, or a voiceover in one or more voices, then read word timings to cut scenes to the audio.

POST /api/v2/generate/audio/text_to_music

WRITE

MCP twin: text_to_music

Make one song with vocals singing the exact lyrics, or an instrumental, for an ad. One call returns two versions and costs 1 credit. Write the lyric first (hook in the first seconds, one 6-9 word line per scene). text_to_music takes no references. prompt is required: the style, in under 25 words: genre, vocal, tempo or BPM, mood, production. Never an artist or band name; the provider refuses them. The server never writes it for you. settings: lyrics, instrumental, duration, vocalGender, avoid; each model lists its own values in list_audio_models, and a setting left out takes the model’s default. No preset: this task adds no server text, and systemPrompt is refused; put the style in prompt and the words in settings.lyrics. model is required (there is no default): one whose list_audio_models entry lists text_to_music; use the one marked recommended unless the user asks for another. Anything not listed, and any old field, is refused with the field to send instead. Reuse idempotencyKey to retry the same call without paying twice. title is required (1-80 characters): it names the card and is the song’s title. When it is done, generation.outputs are its two versions (type audio, each with a url, its durationSeconds and words: when each word is sung; an instrumental has no words).

Workspace-scoped writes name workspace in the body (or as a ?workspace= query param on a bodyless DELETE); the X-Workspace-Id header is for reads only.

Request body
{
  "type": "object",
  "properties": {
    "model": {
      "type": "string",
      "minLength": 1,
      "maxLength": 100,
      "description": "Required. The model id; it must offer this task. There is no default model."
    },
    "prompt": {
      "description": "Your own text: what to make or change (on text_to_music, the style). The server never writes prompt text for you. Required on text tasks, image_edit and models that need one; text_to_speech takes none.",
      "type": "string",
      "maxLength": 30000
    },
    "systemPrompt": {
      "description": "The task's preset. Leave it out to use the preset (get_preset shows its text), send text to replace it, or null to send none. Refused where the task and model have no preset: put your text in prompt.",
      "anyOf": [
        {
          "type": "string",
          "maxLength": 30000
        },
        {
          "type": "null"
        }
      ]
    },
    "references": {
      "default": [],
      "description": "In the order the model should see them; each task says which types go where. Leave it out when the task takes none.",
      "maxItems": 20,
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "image",
              "video",
              "upload",
              "avatar",
              "product",
              "template",
              "audio"
            ],
            "description": "What the id points at."
          },
          "id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "pattern": "^[^\\s/:]+$",
            "description": "The id for its type: image: a frame id (frameId from list_images, or outputs[].id of a reaction_frame generation; not an avatar_image output); video: a video id (videoId from list_videos, or outputs[].id of a reaction_video generation); upload: an upload mediaId (from complete_media_upload); avatar: an avatar id (avatarId from list_avatars); product: a product image id (id from list_product_images); template: a Template id (id from list_video_templates, or outputs[].id of a reaction_import, reaction_crop or reaction_smart_crop generation); audio: a song version or voiceover take id (outputs[].id of a music or voiceover generation)."
          },
          "at": {
            "description": "Seconds into the Template. Only on clone_image's first reference, when it is a template.",
            "type": "number",
            "minimum": 0
          },
          "frame": {
            "description": "Only on reference_to_video, on an image, where the model's list_video_models entry says frames: true: \"first\" opens the video exactly on this image, \"last\" ends it on this image. The other references still guide the video.",
            "type": "string",
            "enum": [
              "first",
              "last"
            ]
          }
        },
        "required": [
          "type",
          "id"
        ],
        "additionalProperties": false
      }
    },
    "title": {
      "description": "Short name for the card; get_generation returns it as title. Required on audio tasks (80 characters at most), where it is also the song's title.",
      "type": "string",
      "minLength": 1,
      "maxLength": 100
    },
    "idempotencyKey": {
      "description": "Resending the same call with this key returns the same job and never charges twice.",
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    },
    "settings": {
      "description": "Only the settings this task and model have; anything else is refused. Leave one out for its default.",
      "type": "object",
      "properties": {
        "lyrics": {
          "description": "The exact words to sing, with section tags such as [Verse] and [Chorus] on their own lines. Sung exactly as written. Required unless instrumental is true, which ignores them.",
          "type": "string",
          "minLength": 1,
          "maxLength": 5000
        },
        "instrumental": {
          "description": "true makes music with no vocals; any lyrics are then ignored. Left out, false.",
          "type": "boolean"
        },
        "duration": {
          "description": "The song length in whole seconds; each model lists its range. Left out, sized from the lyric at about 2.5 sung words per second (an instrumental: 30 s).",
          "type": "integer",
          "exclusiveMinimum": 0,
          "maximum": 9007199254740991
        },
        "vocalGender": {
          "description": "A hint for the lead voice; the model does not guarantee it.",
          "type": "string",
          "enum": [
            "male",
            "female"
          ]
        },
        "avoid": {
          "description": "Styles or sounds to keep out, for example \"long instrumental intro, autotune\".",
          "type": "string",
          "minLength": 1,
          "maxLength": 1000
        }
      },
      "additionalProperties": false
    },
    "workspace": {
      "type": "string",
      "minLength": 1,
      "description": "The workspace slug, name or id to make it in. MCP only."
    }
  },
  "required": [
    "model",
    "workspace"
  ],
  "$schema": "http://json-schema.org/draft-07/schema#",
  "additionalProperties": {}
}
Example response
{
  "success": true,
  "data": {
    "workspace": {
      "id": "6a18c36ee586c7e44e4ece67",
      "name": "Client A",
      "slug": "client-a"
    },
    "generation": {
      "id": "gen_8f3c2a10-4b1d-4e7a-9c55-2d1e0f6a7b88",
      "kind": "music",
      "state": "queued",
      "title": "Sleep, Finally",
      "input": {
        "task": "text_to_music",
        "model": "suno_v6",
        "title": "Sleep, Finally",
        "prompt": "indie pop, female lead, 100 BPM, warm",
        "settings": {
          "lyrics": "[Chorus]\nCounting every sheep in the county\nSleep, finally",
          "duration": 10
        },
        "references": []
      },
      "outputs": [],
      "creditsSpent": 1,
      "createdAt": "2026-11-01T12:00:00.000Z",
      "updatedAt": "2026-11-01T12:00:00.000Z",
      "task": "text_to_music"
    },
    "prompt": {
      "inspectWith": "get_generation_prompt"
    },
    "nextSteps": "Poll get_generation. When it is done, generation.outputs are its two versions (type audio, each with a url, its durationSeconds and words: when each word is sung or spoken). Do not repeat a successful generation."
  }
}

POST /api/v2/generate/audio/text_to_speech

WRITE

MCP twin: text_to_speech

Make one voiceover take: a narrator reading a script, or two or more speakers in one conversation, in voices from list_voices. Costs 1 credit per started 1,000 characters. Write the script for the ear first, word for word. text_to_speech takes no references. text_to_speech reads settings.lines; it takes no prompt. settings: lines, speed; each model lists its own values in list_audio_models, and a setting left out takes the model’s default. No preset: this task adds no server text, and systemPrompt is refused; the script goes in settings.lines. model is required (there is no default): one whose list_audio_models entry lists text_to_speech; use the one marked recommended unless the user asks for another. Anything not listed, and any old field, is refused with the field to send instead. Reuse idempotencyKey to retry the same call without paying twice. title is required (1-80 characters): it names the card. When it is done, generation.outputs holds the one take (type audio, with a url, its durationSeconds and words: when each word is spoken).

Workspace-scoped writes name workspace in the body (or as a ?workspace= query param on a bodyless DELETE); the X-Workspace-Id header is for reads only.

Request body
{
  "type": "object",
  "properties": {
    "model": {
      "type": "string",
      "minLength": 1,
      "maxLength": 100,
      "description": "Required. The model id; it must offer this task. There is no default model."
    },
    "prompt": {
      "description": "Your own text: what to make or change (on text_to_music, the style). The server never writes prompt text for you. Required on text tasks, image_edit and models that need one; text_to_speech takes none.",
      "type": "string",
      "maxLength": 30000
    },
    "systemPrompt": {
      "description": "The task's preset. Leave it out to use the preset (get_preset shows its text), send text to replace it, or null to send none. Refused where the task and model have no preset: put your text in prompt.",
      "anyOf": [
        {
          "type": "string",
          "maxLength": 30000
        },
        {
          "type": "null"
        }
      ]
    },
    "references": {
      "default": [],
      "description": "In the order the model should see them; each task says which types go where. Leave it out when the task takes none.",
      "maxItems": 20,
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "image",
              "video",
              "upload",
              "avatar",
              "product",
              "template",
              "audio"
            ],
            "description": "What the id points at."
          },
          "id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "pattern": "^[^\\s/:]+$",
            "description": "The id for its type: image: a frame id (frameId from list_images, or outputs[].id of a reaction_frame generation; not an avatar_image output); video: a video id (videoId from list_videos, or outputs[].id of a reaction_video generation); upload: an upload mediaId (from complete_media_upload); avatar: an avatar id (avatarId from list_avatars); product: a product image id (id from list_product_images); template: a Template id (id from list_video_templates, or outputs[].id of a reaction_import, reaction_crop or reaction_smart_crop generation); audio: a song version or voiceover take id (outputs[].id of a music or voiceover generation)."
          },
          "at": {
            "description": "Seconds into the Template. Only on clone_image's first reference, when it is a template.",
            "type": "number",
            "minimum": 0
          },
          "frame": {
            "description": "Only on reference_to_video, on an image, where the model's list_video_models entry says frames: true: \"first\" opens the video exactly on this image, \"last\" ends it on this image. The other references still guide the video.",
            "type": "string",
            "enum": [
              "first",
              "last"
            ]
          }
        },
        "required": [
          "type",
          "id"
        ],
        "additionalProperties": false
      }
    },
    "title": {
      "description": "Short name for the card; get_generation returns it as title. Required on audio tasks (80 characters at most), where it is also the song's title.",
      "type": "string",
      "minLength": 1,
      "maxLength": 100
    },
    "idempotencyKey": {
      "description": "Resending the same call with this key returns the same job and never charges twice.",
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    },
    "settings": {
      "description": "Only the settings this task and model have; anything else is refused. Leave one out for its default.",
      "type": "object",
      "properties": {
        "lines": {
          "description": "Required. The script in speaking order, one entry per line or speaker turn, within the model's maxCharacters in all (5000 at most). One voice for a narrator; a voice per speaker for a conversation (only on a model that takes several voices).",
          "minItems": 1,
          "maxItems": 40,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "text": {
                "type": "string",
                "minLength": 1,
                "maxLength": 5000,
                "description": "The exact words, spoken as written."
              },
              "voice": {
                "type": "string",
                "minLength": 1,
                "maxLength": 100,
                "description": "A voice id from list_voices."
              }
            },
            "required": [
              "text",
              "voice"
            ],
            "additionalProperties": false
          }
        },
        "speed": {
          "description": "Speaking speed, 0.7-1.2; 1 is normal. Only on models that list it.",
          "type": "number",
          "minimum": 0.7,
          "maximum": 1.2
        }
      },
      "additionalProperties": false
    },
    "workspace": {
      "type": "string",
      "minLength": 1,
      "description": "The workspace slug, name or id to make it in. MCP only."
    }
  },
  "required": [
    "model",
    "workspace"
  ],
  "$schema": "http://json-schema.org/draft-07/schema#",
  "additionalProperties": {}
}
Example response
{
  "success": true,
  "data": {
    "workspace": {
      "id": "6a18c36ee586c7e44e4ece67",
      "name": "Client A",
      "slug": "client-a"
    },
    "generation": {
      "id": "gen_1d7e9b44-0c2f-4a63-8e1b-5f9a2c3d4e51",
      "kind": "voiceover",
      "state": "queued",
      "title": "Sleep ad narration",
      "input": {
        "task": "text_to_speech",
        "model": "elevenlabs_multilingual_v2",
        "title": "Sleep ad narration",
        "settings": {
          "lines": [
            {
              "text": "Counting sheep never worked for me. Then I tried one small change before bed.",
              "voice": "EkK5I93UQWFDigLMpZcX"
            }
          ]
        },
        "references": []
      },
      "outputs": [],
      "creditsSpent": 1,
      "createdAt": "2026-11-01T12:00:00.000Z",
      "updatedAt": "2026-11-01T12:00:00.000Z",
      "task": "text_to_speech"
    },
    "prompt": {
      "inspectWith": "get_generation_prompt"
    },
    "nextSteps": "Poll get_generation. When it is done, generation.outputs hold the one take (type audio, each with a url, its durationSeconds and words: when each word is sung or spoken). Do not repeat a successful generation."
  }
}

GET /api/v2/audio/models

READ

MCP twin: list_audio_models

The models text_to_music and text_to_speech take, as list_image_models and list_video_models list theirs. Each model has its id (send it as model), label and tasks (the task tools it offers, each with this model’s facts for that task; one model per task is marked recommended: true, use it unless the request needs another). A song model’s text_to_music lists durationRange (whole seconds) and promptLimits (how long the style may be, refused with prompt_too_long when longer). A speech model’s text_to_speech lists dialogue (several voices and audio tags such as [excited] in one take), takesSpeed (settings.speed) and maxCharacters (the most one take reads, all lines together); its voices come from list_voices with this model. Free.

No parameters.

Example response
{
  "success": true,
  "data": {
    "models": [
      {
        "id": "suno_v6",
        "label": "Suno V6",
        "tasks": [
          {
            "task": "text_to_music",
            "promptRequired": true,
            "references": {
              "image": {
                "min": 0,
                "max": 0
              },
              "video": {
                "min": 0,
                "max": 0
              },
              "audio": {
                "min": 0,
                "max": 0
              },
              "total": {
                "min": 0,
                "max": 0
              }
            },
            "durationRange": {
              "min": 10,
              "max": 360
            },
            "preset": null,
            "recommended": true,
            "promptLimits": [
              {
                "max": 1000,
                "unit": "characters",
                "countsPreset": false
              }
            ]
          }
        ]
      },
      {
        "id": "elevenlabs_v4",
        "label": "ElevenLabs v4",
        "tasks": [
          {
            "task": "text_to_speech",
            "promptRequired": false,
            "references": {
              "image": {
                "min": 0,
                "max": 0
              },
              "video": {
                "min": 0,
                "max": 0
              },
              "audio": {
                "min": 0,
                "max": 0
              },
              "total": {
                "min": 0,
                "max": 0
              }
            },
            "dialogue": true,
            "takesSpeed": false,
            "maxCharacters": 2000,
            "preset": null,
            "recommended": true
          }
        ]
      }
    ],
    "nextSteps": "tasks lists the task tools each model offers (call the tool named after the task, with this id as model; there is no default model), each with this model’s facts for that task: aspectRatios, promptRequired, references (counts per media and clip seconds), sourceSeconds where the length comes from a source, durations with defaultDuration, modes with defaultMode where the model has a mode setting (settings.mode), endFrame: true where image_to_video also takes a second image as the video’s last frame, frames: true where reference_to_video takes frame: \"first\" or \"last\" on an image reference, its preset id (null when it has none), and promptLimits: how long the prompt may be (max in bytes or characters; countsPreset says the preset or a systemPrompt counts too), refused with prompt_too_long when longer. One model per task is marked recommended: true; use it unless the user asks for another. Read a preset’s text with get_preset; leave systemPrompt out to use it, send text to replace it, or null to remove it. systemPrompt is refused where preset is null."
  }
}

GET /api/v2/audio/voices

READ

MCP twin: list_voices

The voices a text_to_speech model reads (the voice of each line in settings.lines): id, name and previewUrl, a short sample of the voice. Pass model (from list_audio_models) for that model's voices; left out, the recommended speech model's. Names are the only description, so choose by listening: offer the person a few voices to hear and pick from. Free.

Query parameters
{
  "type": "object",
  "properties": {
    "model": {
      "description": "A speech model id from list_audio_models; its voices. Leave it out for the recommended one.",
      "type": "string",
      "minLength": 1
    }
  },
  "$schema": "http://json-schema.org/draft-07/schema#"
}
Example response
{
  "success": true,
  "data": {
    "model": "elevenlabs_v4",
    "voices": [
      {
        "id": "EkK5I93UQWFDigLMpZcX",
        "name": "James",
        "previewUrl": "https://storage.googleapis.com/eleven-public-prod/database/workspace/48ab3aae468d4e9baded4b1693820088/voices/EkK5I93UQWFDigLMpZcX/xvjT3EK4vD3zlwfawHeV.mp3"
      }
    ]
  }
}

POST /api/v2/audio/timings

READ

MCP twin: get_audio_timings

Word timings of one finished song version or voiceover, for cutting the audio at word or line breaks and timing scenes to it. Returns durationSeconds and words [{ word, startSeconds, endSeconds }] in speaking order. Sung timings are approximate: listen around a cut before relying on it. An instrumental has no words; a voiceover has them for every line, its audio tags left out. Free.

Workspace-scoped writes name workspace in the body (or as a ?workspace= query param on a bodyless DELETE); the X-Workspace-Id header is for reads only.

Request body
{
  "type": "object",
  "properties": {
    "generationId": {
      "type": "string",
      "pattern": "^gen_[0-9a-f-]{36}$",
      "description": "The generation id of a finished song or voiceover."
    },
    "trackId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200,
      "description": "The id of one of its outputs (a song has two versions; a voiceover has one)."
    },
    "workspace": {
      "type": "string",
      "minLength": 1,
      "description": "Required write target: a workspace slug or id from list_workspaces. Writes never inherit the connection default."
    }
  },
  "required": [
    "generationId",
    "trackId",
    "workspace"
  ],
  "$schema": "http://json-schema.org/draft-07/schema#"
}
Example response
{
  "success": true,
  "data": {
    "workspace": {
      "id": "6a18c36ee586c7e44e4ece67",
      "name": "Client A",
      "slug": "client-a"
    },
    "generationId": "gen_8f3c2a10-4b1d-4e7a-9c55-2d1e0f6a7b88",
    "trackId": "95c707ee-1997-44fa-a168-569c34e4a62b",
    "durationSeconds": 8.36,
    "words": [
      {
        "word": "Sleep",
        "startSeconds": 0.71,
        "endSeconds": 1.56
      },
      {
        "word": "finally,",
        "startSeconds": 1.72,
        "endSeconds": 4.05
      }
    ]
  }
}