---
title: "Generate music — estimate"
method: POST
path: "/v1/ai/music/estimate"
tags: ["Music"]
---

# Generate music — estimate

`POST /v1/ai/music/estimate`

## Request

- Base URL: `https://apihub.co.il`
- URL: `https://apihub.co.il/v1/ai/music/estimate`
- Auth: HTTP bearer

Price the request without executing it. Same body as `POST /v1/ai/music`.

## Request body

- object
  - `avoid` string[]: With `sections`: what the whole track must not have
  - `prompt` string: Genre, mood, instruments, tempo — or lyrics. With `sections` it is the overall style
  - `duration` number: seconds (with `sections`: their sum)
  - `sections` object[]: Music timed to your video: consecutive sections, each exactly `duration` seconds — quiet under a story, a hit on the reveal, a build before the payoff
    - `name` string, required: e.g. intro, tension, the reveal, drop, outro
    - `avoid` string[]: What this section must not have
    - `lyrics` string[]: Sung lines (only when instrumental is false)
    - `styles` string[], required: What this section sounds like: instruments, energy, dynamics
    - `duration` number, required: seconds — the section lasts exactly this long
  - `instrumental` boolean

## Response `200`

Estimate

- Estimate
  - `operation` string
  - `estimated_credits` number
  - `credits_to_reserve` number
  - `estimated_usage` object
  - `note` string, nullable
  - `balance` object
    - `available` number
  - `sufficient` boolean

---

[API](https://skmtc.dev/apihub/apis/apihub-one-api-for-chat-image-video-ai.md) · [All operations](https://skmtc.dev/apihub/apis/apihub-one-api-for-chat-image-video-ai/llms.txt) · [OpenAPI document](https://skmtc.dev/apihub/apis/apihub-one-api-for-chat-image-video-ai/revisions/a8caa42835ce?raw)
