Skip to main content
GET
Get Task

Get Task

Retrieve the current status, input, and output of a previously created task. If the task is still in progress, sunor will live-poll the upstream provider and return the latest status.

Request

Path parameters

string
required
The task ID returned from the Create Task endpoint.

Headers

string
required
Your API key.

Response

number
HTTP status code (200 on success).
object
string
The unique task identifier.
string
The model used (e.g., "suno").
string
The task type ("music", "lyrics", "upload", or "concat").
string
Current task status. One of: "pending", "running", "success", "failure", "timeout".
number
Credits charged (or frozen) for this task.
object
The original input parameters submitted with the task.
string | null
The delivery format this task was created with, or null for the provider’s original. When set to "mp3", audio_url points at a converted copy. See audio_format on Create Task.
object | null
The task output. null while the task is still processing. Contains model-specific results on completion.
string | null
Error message if the task failed. null otherwise.
string
ISO 8601 timestamp of task creation.
string | null
ISO 8601 timestamp of task completion. null if not yet completed.

Status values

Audio URL lifetime

audio_url is valid for 7 days after the task completes. After that it returns 404 permanently. If you need the audio for longer, download and store it yourself.
Cover art (image_url, image_large_url) is served by the model provider and is not covered by this window.

Contract

The fields listed on this page are the response contract, and they hold across provider changes: every one of them has been present on every clip we have returned. output.result also carries additional fields from the upstream model provider. Those are passed through as-is. They are not part of the contract, they differ between providers, and they may appear or disappear without notice — build against the documented fields.

Audio format

By default audio_url points at the file exactly as the provider produced it. Today that is Opus audio in an MP4 container, served with an .m4a extension. That combination is worth knowing about, because .m4a normally implies AAC and not every client handles Opus in this container — Apple’s CoreAudio, which every iOS and macOS app sits on, cannot decode it at all. If your pipeline is affected, pass audio_format: "mp3" when creating the task and audio_url will point at an MP3 instead. Derive the concrete format from the response’s Content-Type rather than from the URL’s extension or from the format the provider was using the last time you looked.

Output format

The output field structure depends on the task type. All outputs share a common wrapper:
string
The task type ("music", "lyrics", "upload", or "concat").
string
Internal processing status: "queued", "processing", "completed", or "failed".
string | null
Processing progress (e.g., "50%", "100%").
string | null
Reason for failure, if any.
array | object | null
The task-specific result. Shape varies by task type (see below).

Output by task type

result is an array of clip objects. Each music generation typically returns one or more clip variations.

Example responses

Task in progress

200

Task completed (music)

200

Task failed

200

Polling strategy

Tasks typically take 30 seconds to 5 minutes to complete, depending on the task type and upstream provider load.
Poll the Get Task endpoint every 5-10 seconds until the status is "success", "failure", or "timeout". Avoid polling more frequently than once per second.

Polling example

Errors