Skip to main content
POST
Estimate the price of a text-to-music generation request
Estimate the cost of a text-to-music job before submitting it.

Authorizations

Authorization
string
header
required

Sanctum personal access token, sent as Authorization: Bearer <token>. The token is opaque — it carries no claims and no embedded expiry, so do not attempt to decode it. Issue and revoke tokens from your account dashboard.

Headers

Accept
enum<string>
default:application/json
required
Available options:
application/json

Body

application/json

Music generation parameters for price calculation.

Every example in this schema is a working set for the model example shown — they are not defaults and not portable. Sizes, step counts, frame counts and frame rates are all per-model: read info.limits and info.defaults for the model you actually intend to use from GET /api/v2/models. Substituting a different model while keeping these values is the most common source of a 422.

model
string
required

The model to use for music generation. Available models can be retrieved via the GET /api/v2/models endpoint.

Example:

"AceStep_1_5_Turbo"

duration
number
required

Duration in seconds (10-600). The accepted range is model-specific — read info.limits.min_duration/max_duration for your model from GET /api/v2/models. Some models additionally cap duration per output format via info.limits.max_duration_by_format.

Example:

30

inference_steps
integer
required

Number of diffusion inference steps (1-100). Use 8 for turbo models, 32+ for base models. The accepted range is model-specific — read info.limits.min_steps/max_steps for your model from GET /api/v2/models; several models pin it to a single value.

Example:

8

Response

Calculated price for text2music inference.

data
object