Generate a Song from an Image

Generate a song from an image by analyzing it and creating music based on visual content. The process can optionally include custom lyrics, voice conversion, and various musical parameters.

post/v1/image_to_song

Request

  • Base URL
    https://api.musicgpt.com/api/public
  • Auth
    API key in header Authorization

Request body multipart/form-data

OR

Example request

{
  "image_url": "https://mybucket.s3.amazonaws.com/image.png",
  "prompt": "Generate a relaxing acoustic track inspired by this scene.",
  "lyrics": "Let the colors of the sunset fill your heart.",
  "negative_tags": "no heavy metal, avoid loud drums",
  "key": "C major",
  "webhook_url": "https://example.com/webhook"
}

Response

Successfully initiated image-to-song task

successboolean
messagestring
task_idstring
conversion_id_1string
conversion_id_2string
etainteger

Estimated processing time in seconds

credit_estimatenumber float

Example response

{
  "success": true,
  "message": "Message Published To Queue",
  "task_id": "task_12345",
  "conversion_id_1": "conv_12345",
  "conversion_id_2": "conv_54321",
  "eta": 300,
  "credit_estimate": 150.5
}

Changes

No recorded changes to this operation across all 1 revision of this API.