{
  "openapi": "3.1.0",
  "info": {
    "title": "Wave API",
    "version": "1.0.0",
    "description": "API thống nhất của Wave để tạo nhạc, ảnh và video. Mọi route dùng khóa API dạng `Authorization: Bearer sk_live_...`, trừ `/files/{id}` và `/api/v1/media/{id}` (id chính là quyền truy cập). Base URL là origin đang phục vụ tài liệu này (`/openapi.json`). Lỗi trả về dạng `{\"error\":{\"code\",\"message\"}}`; riêng facade OpenAI (`/api/v1/images/generations`, `/edits`) dùng envelope `{\"error\":{\"message\",\"type\",\"code\",\"param\"}}`."
  },
  "servers": [
    {
      "url": "/",
      "description": "Cùng origin với trang này: host đang phục vụ /openapi.json và /docs/."
    }
  ],
  "security": [
    {
      "apiKey": []
    }
  ],
  "tags": [
    {
      "name": "account",
      "description": "Thông tin khóa API"
    },
    {
      "name": "jobs",
      "description": "Gửi và theo dõi job"
    },
    {
      "name": "images",
      "description": "Ảnh: mỗi loại job một trang"
    },
    {
      "name": "music",
      "description": "Nhạc: mỗi loại job một trang"
    },
    {
      "name": "models",
      "description": "Danh sách model và giá"
    },
    {
      "name": "files",
      "description": "Kết quả và media"
    },
    {
      "name": "openai",
      "description": "Facade tương thích OpenAI Images"
    }
  ],
  "paths": {
    "/api/v1/me": {
      "get": {
        "operationId": "getMe",
        "tags": [
          "account"
        ],
        "summary": "Thông tin khóa API hiện tại",
        "description": "Trả về khách hàng, khóa, trạng thái, giới hạn tốc độ và phạm vi (scope) của khóa.",
        "responses": {
          "200": {
            "description": "Principal của khóa.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Me"
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          }
        }
      }
    },
    "/api/v1/wallet": {
      "get": {
        "operationId": "getWallet",
        "tags": [
          "account"
        ],
        "summary": "Số dư ví của khách hàng",
        "description": "Ví VND của khách hàng sở hữu khóa. `held_vnd` là tiền đang giữ cho job chưa xong; job mới bị từ chối `INSUFFICIENT_BALANCE` khi giá vượt `available_vnd`.",
        "responses": {
          "200": {
            "description": "Ví của khách hàng.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Wallet"
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          }
        }
      }
    },
    "/api/v1/music/jobs": {
      "post": {
        "operationId": "submitMusicJob",
        "tags": [
          "jobs"
        ],
        "summary": "Gửi job nhạc",
        "description": "Kind mặc định là `music.generate`; các kind `music.*` khác chọn qua trường `kind`. Body JSON tối đa 1 MiB. Multipart: part text là từng field JSON (true/false/số/null/`{`/`[` được ép kiểu, còn lại là chuỗi), hoặc một part `request` chứa cả object; part file `audio` (tối đa 20 MiB mỗi file, mashup tối đa 2 file, `music.claim_check` tối đa 15 file) là nguồn âm thanh. Với `music.claim_check`, gửi part `kind` (hoặc `request`) trước các part `audio`: khi đó body được tới 15 file × 20 MiB, nếu không thì 41 MiB.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicJobRequest"
              },
              "examples": {
                "generate": {
                  "summary": "music.generate",
                  "value": {
                    "kind": "music.generate",
                    "prompt": "[Verse]\n...",
                    "style": "pop, female vocal",
                    "title": "My song"
                  }
                },
                "upload_cover_url": {
                  "summary": "music.upload_cover · audio_url",
                  "value": {
                    "kind": "music.upload_cover",
                    "audio_url": "https://example.com/song.mp3",
                    "style": "acoustic",
                    "title": "Cover",
                    "prompt": "[Verse]\n...",
                    "advanced_fallback": true
                  }
                },
                "claim_check": {
                  "summary": "music.claim_check · audio_urls",
                  "value": {
                    "kind": "music.claim_check",
                    "audio_urls": [
                      "https://example.com/song-1.mp3",
                      "https://example.com/song-2.mp3"
                    ],
                    "titles": [
                      "Song 1",
                      "Song 2"
                    ],
                    "callback_url": "https://example.com/wave-callback"
                  }
                }
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/MusicMultipartRequest"
              },
              "examples": {
                "upload_cover_file": {
                  "summary": "music.upload_cover · audio file",
                  "value": {
                    "kind": "music.upload_cover",
                    "style": "acoustic",
                    "title": "Cover",
                    "prompt": "[Verse]\n...",
                    "audio": "song.mp3"
                  }
                },
                "claim_check": {
                  "summary": "music.claim_check · multipart audio",
                  "value": {
                    "kind": "music.claim_check",
                    "titles": "[\"Song 1\",\"Song 2\"]",
                    "audio": [
                      "song-1.mp3",
                      "song-2.mp3"
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/images/jobs": {
      "post": {
        "operationId": "submitImageJob",
        "tags": [
          "jobs"
        ],
        "summary": "Gửi job ảnh",
        "description": "Kind mặc định là `image.generate`; `image.edit` chọn qua trường `kind`. Provider do `model` quyết định (chatgpt: `gpt-image-1`; flow: `nano-banana-2-lite`, `nano-banana-2`, `nano-banana-pro`; grok: `grok-imagine`, `grok-imagine-pro`; bỏ trống/`auto` để Wave chọn). Field provider không hỗ trợ bị từ chối (400) trừ khi `drop_unsupported: true`. Multipart: part file `image` (nguồn của image.edit, đúng một) và `reference` (ảnh tham chiếu, flow).",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ImageJobRequest"
              },
              "examples": {
                "generate": {
                  "summary": "image.generate",
                  "value": {
                    "kind": "image.generate",
                    "prompt": "A red fox in snow",
                    "aspect_ratio": "16:9"
                  }
                },
                "edit_url": {
                  "summary": "image.edit · image_url",
                  "value": {
                    "kind": "image.edit",
                    "prompt": "Make it night",
                    "image_url": "https://example.com/photo.png"
                  }
                }
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/ImageMultipartRequest"
              },
              "examples": {
                "edit_file": {
                  "summary": "image.edit · image file",
                  "value": {
                    "kind": "image.edit",
                    "prompt": "Make it night",
                    "image": "photo.png"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/videos/jobs": {
      "post": {
        "operationId": "submitVideoJob",
        "tags": [
          "jobs"
        ],
        "summary": "Gửi job video",
        "description": "Kind duy nhất là `video.generate`. Provider do `model` quyết định (flow: `veo-3.1-lite`, `veo-3.1-fast`, `veo-3.1-quality`, `omni-flash`; grok: `grok-imagine-video`; bỏ trống/`auto` để Wave chọn). Chế độ suy ra từ nguồn: không ảnh → text-to-video, `start_image` → image-to-video, `start_image`+`end_image` → nội suy (flow), `references` → ingredients (flow). Multipart: part file `start_image`, `end_image`, `reference`.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VideoGenerateRequest"
              },
              "examples": {
                "text": {
                  "summary": "video.generate · text",
                  "value": {
                    "prompt": "A drone shot over a beach at sunset",
                    "aspect_ratio": "16:9",
                    "duration_s": 8
                  }
                },
                "start_url": {
                  "summary": "video.generate · start_image URL",
                  "value": {
                    "prompt": "The camera slowly zooms in",
                    "start_image": {
                      "url": "https://example.com/frame.png"
                    }
                  }
                }
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/VideoMultipartRequest"
              },
              "examples": {
                "start_file": {
                  "summary": "video.generate · start_image file",
                  "value": {
                    "prompt": "The camera slowly zooms in",
                    "start_image": "frame.png"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/models": {
      "get": {
        "operationId": "listMusicModels",
        "tags": [
          "models"
        ],
        "summary": "Model nhạc đang có giá",
        "description": "Mọi cặp (kind, model) của medium music có giá và có provider; `enabled` cho biết hiện có tài khoản phục vụ được không.",
        "responses": {
          "200": {
            "$ref": "#/components/responses/ModelList"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/images/models": {
      "get": {
        "operationId": "listImageModels",
        "tags": [
          "models"
        ],
        "summary": "Model ảnh đang có giá",
        "responses": {
          "200": {
            "$ref": "#/components/responses/ModelList"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/videos/models": {
      "get": {
        "operationId": "listVideoModels",
        "tags": [
          "models"
        ],
        "summary": "Model video đang có giá",
        "responses": {
          "200": {
            "$ref": "#/components/responses/ModelList"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/jobs": {
      "get": {
        "operationId": "listJobs",
        "tags": [
          "jobs"
        ],
        "summary": "Liệt kê job",
        "description": "Job của khách hàng, mới nhất trước. Phân trang bằng `cursor` trả về trong response; vắng `cursor` nghĩa là hết.",
        "parameters": [
          {
            "name": "kind",
            "in": "query",
            "description": "Lọc theo kind.",
            "schema": {
              "$ref": "#/components/schemas/JobKind"
            }
          },
          {
            "name": "status",
            "in": "query",
            "description": "Lọc theo trạng thái kết thúc.",
            "schema": {
              "type": "string",
              "enum": [
                "succeeded",
                "failed"
              ]
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "Giá trị `cursor` của trang trước (chuỗi mờ).",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Trang job.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/JobList"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/jobs/{id}": {
      "get": {
        "operationId": "getJob",
        "tags": [
          "jobs"
        ],
        "summary": "Xem một job",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Job.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Job"
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/files/{id}": {
      "get": {
        "operationId": "getFile",
        "tags": [
          "files"
        ],
        "summary": "Tải kết quả",
        "description": "Không cần khóa API: id 128-bit là quyền truy cập. Chuyển hướng 302 tới URL ký ngắn hạn khi kết quả còn, 410 `EXPIRED` khi hết hạn, 404 khi không có.",
        "security": [],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "302": {
            "description": "Chuyển hướng tới URL tải (Cache-Control: private, max-age=60).",
            "headers": {
              "Location": {
                "schema": {
                  "type": "string",
                  "format": "uri"
                }
              }
            }
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "410": {
            "$ref": "#/components/responses/Gone"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/media/{id}": {
      "get": {
        "operationId": "streamMedia",
        "tags": [
          "files"
        ],
        "summary": "Phát audio đang tạo",
        "description": "Không cần khóa API; id là object upstream trong `stream_url` của item preview. Hỗ trợ Range dạng `bytes=a-` và `bytes=a-b` (206); dạng khác trả cả file (200). Khi rendition không seek được, Range bị bỏ qua.",
        "security": [],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "format",
            "in": "query",
            "schema": {
              "type": "string",
              "enum": [
                "mp3",
                "m4a"
              ],
              "default": "mp3"
            }
          },
          {
            "name": "Range",
            "in": "header",
            "schema": {
              "type": "string"
            },
            "example": "bytes=0-"
          }
        ],
        "responses": {
          "200": {
            "description": "Cả file audio.",
            "headers": {
              "Content-Type": {
                "schema": {
                  "type": "string"
                }
              },
              "Accept-Ranges": {
                "schema": {
                  "type": "string"
                }
              },
              "Content-Disposition": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "audio/mpeg": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "audio/mp4": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              }
            }
          },
          "206": {
            "description": "Một phần file theo Range.",
            "headers": {
              "Content-Range": {
                "schema": {
                  "type": "string"
                }
              },
              "Content-Length": {
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "audio/mpeg": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "audio/mp4": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "416": {
            "$ref": "#/components/responses/RangeNotSatisfiable"
          },
          "502": {
            "$ref": "#/components/responses/BadGateway"
          }
        }
      }
    },
    "/api/v1/media/{id}/lyrics": {
      "get": {
        "operationId": "getMediaLyrics",
        "tags": [
          "files"
        ],
        "summary": "Lời bài hát có thời gian",
        "description": "Không cần khóa API; cùng mô hình quyền với `/api/v1/media/{id}`.",
        "security": [],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Từng từ và mốc thời gian (Cache-Control: private, max-age=3600).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AlignedLyrics"
                }
              }
            }
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "502": {
            "$ref": "#/components/responses/BadGateway"
          }
        }
      }
    },
    "/api/v1/images/generations": {
      "post": {
        "operationId": "openaiImageGenerations",
        "tags": [
          "openai"
        ],
        "summary": "Tạo ảnh (OpenAI facade)",
        "description": "Chạy đồng bộ một job `image.generate` và trả về dạng OpenAI; SDK OpenAI trỏ `base_url=<wave>/api/v1` dùng được ngay. Chờ tối đa `server.direct_timeout` (mặc định 10 phút); hết giờ trả 504 kèm `job_id` để lấy kết quả qua `GET /api/v1/jobs/{id}`. Field lạ → 400; `stream:true` → 400.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OpenAIImageGenerationRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Ảnh đã tạo.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OpenAIImagesResponse"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/OpenAIBadRequest"
          },
          "401": {
            "$ref": "#/components/responses/OpenAIUnauthorized"
          },
          "402": {
            "$ref": "#/components/responses/OpenAIInsufficientQuota"
          },
          "403": {
            "$ref": "#/components/responses/OpenAIForbidden"
          },
          "404": {
            "$ref": "#/components/responses/OpenAINotFound"
          },
          "429": {
            "$ref": "#/components/responses/OpenAIRateLimit"
          },
          "502": {
            "$ref": "#/components/responses/OpenAIServerError"
          },
          "504": {
            "$ref": "#/components/responses/OpenAITimeout"
          }
        }
      }
    },
    "/api/v1/images/edits": {
      "post": {
        "operationId": "openaiImageEdits",
        "tags": [
          "openai"
        ],
        "summary": "Sửa ảnh (OpenAI facade)",
        "description": "Multipart với đúng một file `image` và `prompt`; chạy đồng bộ một job `image.edit`. `n` phải là 1; `mask` không hỗ trợ (400); `stream=true` → 400. Hết giờ chờ trả 504 kèm `job_id`.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/OpenAIImageEditRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Ảnh đã sửa.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OpenAIImagesResponse"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/OpenAIBadRequest"
          },
          "401": {
            "$ref": "#/components/responses/OpenAIUnauthorized"
          },
          "402": {
            "$ref": "#/components/responses/OpenAIInsufficientQuota"
          },
          "403": {
            "$ref": "#/components/responses/OpenAIForbidden"
          },
          "404": {
            "$ref": "#/components/responses/OpenAINotFound"
          },
          "429": {
            "$ref": "#/components/responses/OpenAIRateLimit"
          },
          "502": {
            "$ref": "#/components/responses/OpenAIServerError"
          },
          "504": {
            "$ref": "#/components/responses/OpenAITimeout"
          }
        }
      }
    },
    "/api/v1/music/jobs/generate": {
      "post": {
        "operationId": "submitMusicGenerate",
        "tags": [
          "music"
        ],
        "summary": "Tạo bài hát",
        "description": "**`music.generate`**\n\n### Chức năng\nTạo bài hát mới từ mô tả hoặc từ lời bạn viết.\n\n### Bắt buộc\n- **prompt**: Mô tả bài hát (vd `bài ballad buồn về mưa`). Nếu gửi thêm `style` và `title` thì `prompt` là lời bài hát.\n\n### Tuỳ chọn\n- **model** (string): Bỏ trống/`auto` để Wave chọn.\n- **instrumental** (boolean): Không có lời hát.\n- **style** (string): Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`.\n- **title** (string): Tên bài (custom mode).\n- **negative_style** (string): Phong cách cần tránh.\n- **duration_s** (integer): Cần chế độ custom và model v5.5/v6 (hoặc auto).\n- **persona_id** (string): Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó.\n- **vocal_gender** (string): Giọng mong muốn: `m` (nam) hoặc `f` (nữ).\n- **style_weight** (number): Mức bám theo `style`, 0..1.\n- **weirdness** (number): Mức thử nghiệm, lạ của kết quả, 0..1.\n- **audio_weight** (number): Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/generate \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"prompt\": \"[Verse]\\n...\", \"style\": \"ballad, female vocal\", \"title\": \"Rain\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Mỗi job trả về 2 bài (2 item).\n2. Chỉ gửi `prompt` là chế độ đơn giản: Wave tự viết lời. Gửi `style` + `title` là chế độ tuỳ chỉnh: `prompt` là lời của bạn.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicGenerateBody"
              },
              "examples": {
                "generate": {
                  "summary": "music.generate",
                  "value": {
                    "prompt": "[Verse]\n...",
                    "style": "pop, female vocal",
                    "title": "My song"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/extend": {
      "post": {
        "operationId": "submitMusicExtend",
        "tags": [
          "music"
        ],
        "summary": "Nối dài bài hát",
        "description": "**`music.extend`**\n\n### Chức năng\nViết tiếp một bài Wave đã tạo, từ một giây bạn chọn.\n\n### Bắt buộc\n- **clip_id**: Id của bài do Wave tạo (lấy trong `items[].meta.clip_id` của job trước).\n- **continue_at**: Giây bắt đầu phần nối.\n\n### Tuỳ chọn\n- **model** (string): Bỏ trống/`auto` để Wave chọn.\n- **prompt** (string): Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom.\n- **instrumental** (boolean): Không có lời hát.\n- **style** (string): Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`.\n- **title** (string): Tên bài (custom mode).\n- **negative_style** (string): Phong cách cần tránh.\n- **duration_s** (integer): Cần chế độ custom và model v5.5/v6 (hoặc auto).\n- **persona_id** (string): Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó.\n- **vocal_gender** (string): Giọng mong muốn: `m` (nam) hoặc `f` (nữ).\n- **style_weight** (number): Mức bám theo `style`, 0..1.\n- **weirdness** (number): Mức thử nghiệm, lạ của kết quả, 0..1.\n- **audio_weight** (number): Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/extend \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"clip_id\": \"b5f2…\", \"continue_at\": 120, \"prompt\": \"[Verse 2]\\n...\", \"style\": \"ballad\", \"title\": \"Rain (extended)\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Mỗi job trả về 2 bài (2 item).",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicExtendBody"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/cover": {
      "post": {
        "operationId": "submitMusicCover",
        "tags": [
          "music"
        ],
        "summary": "Cover bài đã tạo",
        "description": "**`music.cover`**\n\n### Chức năng\nLàm lại một bài Wave đã tạo theo phong cách mới, giữ giai điệu.\n\n### Bắt buộc\n- **clip_id**: Id của bài do Wave tạo (lấy trong `items[].meta.clip_id` của job trước).\n\n### Tuỳ chọn\n- **model** (string): Bỏ trống/`auto` để Wave chọn.\n- **prompt** (string): Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom.\n- **instrumental** (boolean): Không có lời hát.\n- **style** (string): Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`.\n- **title** (string): Tên bài (custom mode).\n- **negative_style** (string): Phong cách cần tránh.\n- **duration_s** (integer): Cần chế độ custom và model v5.5/v6 (hoặc auto).\n- **persona_id** (string): Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó.\n- **vocal_gender** (string): Giọng mong muốn: `m` (nam) hoặc `f` (nữ).\n- **style_weight** (number): Mức bám theo `style`, 0..1.\n- **weirdness** (number): Mức thử nghiệm, lạ của kết quả, 0..1.\n- **audio_weight** (number): Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n- **start_s** (number): Đi cùng end_s; cửa sổ cover.\n- **end_s** (number): Phải lớn hơn start_s.\n\n### Ví dụ\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/cover \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"clip_id\": \"b5f2…\", \"style\": \"acoustic guitar\", \"title\": \"Rain (acoustic)\", \"prompt\": \"[Verse]\\n...\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Mỗi job trả về 2 bài (2 item).\n2. Muốn cover file audio của bạn thì dùng **Upload cover**.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicCoverBody"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/infill": {
      "post": {
        "operationId": "submitMusicInfill",
        "tags": [
          "music"
        ],
        "summary": "Thay một đoạn",
        "description": "**`music.infill`**\n\n### Chức năng\nThay một đoạn (ít nhất 10 giây) trong bài, giữ phần còn lại.\n\n### Bắt buộc\n- **clip_id / audio_url**: Bài cần sửa: bài Wave đã tạo, hoặc file của bạn.\n- **start_s, end_s**: Đoạn cần thay, tính bằng giây.\n- **full_lyrics**: Toàn bộ lời bài hát sau khi sửa.\n- **style**: Phong cách nhạc, vd `pop, giọng nữ`.\n- **title**: Tên bài.\n- **prompt**: Lời bài hát. Không cần nếu `instrumental: true`.\n\n### Tuỳ chọn\n- **model** (string): Bỏ trống/`auto` để Wave chọn.\n- **instrumental** (boolean): Không có lời hát.\n- **negative_style** (string): Phong cách cần tránh.\n- **duration_s** (integer): Cần chế độ custom và model v5.5/v6 (hoặc auto).\n- **persona_id** (string): Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó.\n- **vocal_gender** (string): Giọng mong muốn: `m` (nam) hoặc `f` (nữ).\n- **style_weight** (number): Mức bám theo `style`, 0..1.\n- **weirdness** (number): Mức thử nghiệm, lạ của kết quả, 0..1.\n- **audio_weight** (number): Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n- **audio** (file): Chỉ có trong `multipart/form-data`: file audio nguồn (tối đa 20 MiB), thay cho `audio_url`.\n\n### Ví dụ\n**Gửi file (multipart/form-data)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/infill \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -F 'clip_id=b5f2…' \\\n  -F 'start_s=30' \\\n  -F 'end_s=45' \\\n  -F 'full_lyrics=...' \\\n  -F 'prompt=[Chorus] ...' \\\n  -F 'style=pop' \\\n  -F 'title=Rain' \\\n  -F audio=@song.mp3\n```\n\n**Gửi URL (JSON)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/infill \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"clip_id\": \"b5f2…\", \"start_s\": 30, \"end_s\": 45, \"full_lyrics\": \"...\", \"prompt\": \"[Chorus]\\n...\", \"style\": \"pop\", \"title\": \"Rain\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Mỗi job trả về 2 bài (2 item).",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicInfillJson"
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/MusicInfillMultipart"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/add-vocals": {
      "post": {
        "operationId": "submitMusicAddVocals",
        "tags": [
          "music"
        ],
        "summary": "Thêm giọng hát",
        "description": "**`music.add_vocals`**\n\n### Chức năng\nThêm giọng hát vào một bản nhạc không lời bạn tải lên.\n\n### Bắt buộc\n- **audio** (file, multipart) hoặc **audio_url** (URL, JSON): nguồn cần xử lý.\n- **style**: Phong cách nhạc, vd `pop, giọng nữ`.\n- **title**: Tên bài.\n- **prompt**: Lời bài hát.\n\n### Tuỳ chọn\n- **model** (string): Bỏ trống/`auto` để Wave chọn.\n- **instrumental** (boolean): Không có lời hát.\n- **negative_style** (string): Phong cách cần tránh.\n- **duration_s** (integer): Cần chế độ custom và model v5.5/v6 (hoặc auto).\n- **persona_id** (string): Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó.\n- **vocal_gender** (string): Giọng mong muốn: `m` (nam) hoặc `f` (nữ).\n- **style_weight** (number): Mức bám theo `style`, 0..1.\n- **weirdness** (number): Mức thử nghiệm, lạ của kết quả, 0..1.\n- **audio_weight** (number): Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n**Gửi file (multipart/form-data)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/add-vocals \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -F 'style=pop, male vocal' \\\n  -F 'title=With vocals' \\\n  -F 'prompt=[Verse] ...' \\\n  -F audio=@song.mp3\n```\n\n**Gửi URL (JSON)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/add-vocals \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"audio_url\": \"https://example.com/beat.mp3\", \"style\": \"pop, male vocal\", \"title\": \"With vocals\", \"prompt\": \"[Verse]\\n...\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Mỗi job trả về 2 bài (2 item).",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicAddVocalsJson"
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/MusicAddVocalsMultipart"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/add-instrumental": {
      "post": {
        "operationId": "submitMusicAddInstrumental",
        "tags": [
          "music"
        ],
        "summary": "Thêm nhạc nền",
        "description": "**`music.add_instrumental`**\n\n### Chức năng\nThêm nhạc nền cho một file giọng hát bạn tải lên.\n\n### Bắt buộc\n- **audio** (file, multipart) hoặc **audio_url** (URL, JSON): nguồn cần xử lý.\n- **style**: Phong cách nhạc, vd `pop, giọng nữ`.\n- **title**: Tên bài.\n\n### Tuỳ chọn\n- **model** (string): Bỏ trống/`auto` để Wave chọn.\n- **prompt** (string): Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom.\n- **instrumental** (boolean): Không có lời hát.\n- **negative_style** (string): Phong cách cần tránh.\n- **duration_s** (integer): Cần chế độ custom và model v5.5/v6 (hoặc auto).\n- **persona_id** (string): Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó.\n- **vocal_gender** (string): Giọng mong muốn: `m` (nam) hoặc `f` (nữ).\n- **style_weight** (number): Mức bám theo `style`, 0..1.\n- **weirdness** (number): Mức thử nghiệm, lạ của kết quả, 0..1.\n- **audio_weight** (number): Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n**Gửi file (multipart/form-data)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/add-instrumental \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -F 'style=lofi' \\\n  -F 'title=With backing' \\\n  -F audio=@song.mp3\n```\n\n**Gửi URL (JSON)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/add-instrumental \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"audio_url\": \"https://example.com/vocal.mp3\", \"style\": \"lofi\", \"title\": \"With backing\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Mỗi job trả về 2 bài (2 item).\n2. Không gửi `prompt`: file của bạn chính là giọng hát.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicAddInstrumentalJson"
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/MusicAddInstrumentalMultipart"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/upload-cover": {
      "post": {
        "operationId": "submitMusicUploadCover",
        "tags": [
          "music"
        ],
        "summary": "Upload cover",
        "description": "**`music.upload_cover`**\n\n### Chức năng\nTải file nhạc của bạn lên, Wave làm lại theo phong cách mới và giữ giai điệu.\n\n### Bắt buộc\n- **audio** (file, multipart) hoặc **audio_url** (URL, JSON): nguồn cần xử lý.\n\n### Tuỳ chọn\n- **model** (string): Bỏ trống/`auto` để Wave chọn.\n- **prompt** (string): Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom.\n- **instrumental** (boolean): Không có lời hát.\n- **style** (string): Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`.\n- **title** (string): Tên bài (custom mode).\n- **negative_style** (string): Phong cách cần tránh.\n- **duration_s** (integer): Cần chế độ custom và model v5.5/v6 (hoặc auto).\n- **persona_id** (string): Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó.\n- **vocal_gender** (string): Giọng mong muốn: `m` (nam) hoặc `f` (nữ).\n- **style_weight** (number): Mức bám theo `style`, 0..1.\n- **weirdness** (number): Mức thử nghiệm, lạ của kết quả, 0..1.\n- **audio_weight** (number): Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n- **advanced_fallback** (boolean): Khi Suno từ chối audio tải lên, cùng job này tiếp tục bằng luồng `music.advanced_cover` (wave tự chọn cách biến đổi audio) và bị tính giá của `music.advanced_cover`.\n\n### Ví dụ\n**Gửi file (multipart/form-data)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/upload-cover \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -F 'style=acoustic' \\\n  -F 'title=Cover' \\\n  -F 'prompt=[Verse] ...' \\\n  -F 'advanced_fallback=true' \\\n  -F audio=@song.mp3\n```\n\n**Gửi URL (JSON)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/upload-cover \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"audio_url\": \"https://example.com/song.mp3\", \"style\": \"acoustic\", \"title\": \"Cover\", \"prompt\": \"[Verse]\\n...\", \"advanced_fallback\": true}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Mỗi job trả về 2 bài (2 item).\n2. Nếu Suno từ chối file (thường vì bản quyền), bật `advanced_fallback: true` để Wave tự chuyển sang **Advanced cover**. Khi đó tính giá Advanced cover.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicUploadCoverJson"
              },
              "examples": {
                "upload_cover_url": {
                  "summary": "music.upload_cover · audio_url",
                  "value": {
                    "audio_url": "https://example.com/song.mp3",
                    "style": "acoustic",
                    "title": "Cover",
                    "prompt": "[Verse]\n...",
                    "advanced_fallback": true
                  }
                }
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/MusicUploadCoverMultipart"
              },
              "examples": {
                "upload_cover_file": {
                  "summary": "music.upload_cover · audio file",
                  "value": {
                    "style": "acoustic",
                    "title": "Cover",
                    "prompt": "[Verse]\n...",
                    "audio": "song.mp3"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/advanced-cover": {
      "post": {
        "operationId": "submitMusicAdvancedCover",
        "tags": [
          "music"
        ],
        "summary": "Advanced cover",
        "description": "**`music.advanced_cover`**\n\n### Chức năng\nCover file nhạc mà Suno từ chối khi upload. Wave tự biến đổi audio rồi mới cover.\n\n### Bắt buộc\n- **audio** (file, multipart) hoặc **audio_url** (URL, JSON): nguồn cần xử lý.\n\n### Tuỳ chọn\n- **model** (string): Bỏ trống/`auto` để Wave chọn.\n- **prompt** (string): Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom.\n- **instrumental** (boolean): Không có lời hát.\n- **style** (string): Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`.\n- **title** (string): Tên bài (custom mode).\n- **negative_style** (string): Phong cách cần tránh.\n- **duration_s** (integer): Cần chế độ custom và model v5.5/v6 (hoặc auto).\n- **persona_id** (string): Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó.\n- **vocal_gender** (string): Giọng mong muốn: `m` (nam) hoặc `f` (nữ).\n- **style_weight** (number): Mức bám theo `style`, 0..1.\n- **weirdness** (number): Mức thử nghiệm, lạ của kết quả, 0..1.\n- **audio_weight** (number): Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n**Gửi file (multipart/form-data)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/advanced-cover \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -F 'style=acoustic' \\\n  -F 'title=Cover' \\\n  -F 'prompt=[Verse] ...' \\\n  -F audio=@song.mp3\n```\n\n**Gửi URL (JSON)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/advanced-cover \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"audio_url\": \"https://example.com/song.mp3\", \"style\": \"acoustic\", \"title\": \"Cover\", \"prompt\": \"[Verse]\\n...\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Mỗi job trả về 2 bài (2 item).\n2. Body giống hệt **Upload cover**; chỉ khác đường dẫn. Chạy lâu hơn và giá cao hơn.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicAdvancedCoverJson"
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/MusicAdvancedCoverMultipart"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/upload-extend": {
      "post": {
        "operationId": "submitMusicUploadExtend",
        "tags": [
          "music"
        ],
        "summary": "Upload và nối dài",
        "description": "**`music.upload_extend`**\n\n### Chức năng\nTải file nhạc của bạn lên và viết tiếp từ một giây bạn chọn.\n\n### Bắt buộc\n- **audio** (file, multipart) hoặc **audio_url** (URL, JSON): nguồn cần xử lý.\n\n### Tuỳ chọn\n- **model** (string): Bỏ trống/`auto` để Wave chọn.\n- **prompt** (string): Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom.\n- **instrumental** (boolean): Không có lời hát.\n- **style** (string): Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`.\n- **title** (string): Tên bài (custom mode).\n- **negative_style** (string): Phong cách cần tránh.\n- **duration_s** (integer): Cần chế độ custom và model v5.5/v6 (hoặc auto).\n- **persona_id** (string): Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó.\n- **vocal_gender** (string): Giọng mong muốn: `m` (nam) hoặc `f` (nữ).\n- **style_weight** (number): Mức bám theo `style`, 0..1.\n- **weirdness** (number): Mức thử nghiệm, lạ của kết quả, 0..1.\n- **audio_weight** (number): Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n- **continue_at** (number): Giây trong audio đã tải lên, nơi phần nối bắt đầu.\n\n### Ví dụ\n**Gửi file (multipart/form-data)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/upload-extend \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -F 'continue_at=60' \\\n  -F 'style=pop' \\\n  -F 'title=Extended' \\\n  -F 'prompt=[Verse 2] ...' \\\n  -F audio=@song.mp3\n```\n\n**Gửi URL (JSON)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/upload-extend \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"audio_url\": \"https://example.com/song.mp3\", \"continue_at\": 60, \"style\": \"pop\", \"title\": \"Extended\", \"prompt\": \"[Verse 2]\\n...\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Mỗi job trả về 2 bài (2 item).",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicUploadExtendJson"
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/MusicUploadExtendMultipart"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/mashup": {
      "post": {
        "operationId": "submitMusicMashup",
        "tags": [
          "music"
        ],
        "summary": "Mashup 2 bài",
        "description": "**`music.mashup`**\n\n### Chức năng\nTrộn hai bài thành một bài mới.\n\n### Bắt buộc\n- **audio** (file, multipart) hoặc **audio_urls** (URL, JSON): nguồn cần xử lý.\n\n### Tuỳ chọn\n- **model** (string): Bỏ trống/`auto` để Wave chọn.\n- **prompt** (string): Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom.\n- **instrumental** (boolean): Không có lời hát.\n- **style** (string): Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`.\n- **title** (string): Tên bài (custom mode).\n- **negative_style** (string): Phong cách cần tránh.\n- **duration_s** (integer): Cần chế độ custom và model v5.5/v6 (hoặc auto).\n- **persona_id** (string): Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó.\n- **vocal_gender** (string): Giọng mong muốn: `m` (nam) hoặc `f` (nữ).\n- **style_weight** (number): Mức bám theo `style`, 0..1.\n- **weirdness** (number): Mức thử nghiệm, lạ của kết quả, 0..1.\n- **audio_weight** (number): Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n- **audio_url** (string): URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB).\n\n### Ví dụ\n**Gửi file (multipart/form-data)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/mashup \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -F 'style=edm' \\\n  -F 'title=Mashup' \\\n  -F 'prompt=[Verse] ...' \\\n  -F audio=@song-1.mp3 \\\n  -F audio=@song-2.mp3\n```\n\n**Gửi URL (JSON)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/mashup \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"audio_urls\": [\"https://example.com/a.mp3\", \"https://example.com/b.mp3\"], \"style\": \"edm\", \"title\": \"Mashup\", \"prompt\": \"[Verse]\\n...\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Mỗi job trả về 2 bài (2 item).",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicMashupJson"
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/MusicMashupMultipart"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/sounds": {
      "post": {
        "operationId": "submitMusicSounds",
        "tags": [
          "music"
        ],
        "summary": "Hiệu ứng âm thanh",
        "description": "**`music.sounds`**\n\n### Chức năng\nTạo hiệu ứng âm thanh hoặc đoạn nhạc ngắn từ mô tả.\n\n### Bắt buộc\n- **prompt**: Mô tả âm thanh, vd `tiếng mưa rơi trên mái tôn`.\n\n### Tuỳ chọn\n- **model** (string): Bỏ trống/`auto` để Wave chọn.\n- **loop** (boolean): Tạo âm thanh lặp liền mạch.\n- **tempo** (integer): Nhịp, BPM.\n- **key** (string): Giọng (tông) nhạc.\n- **grab_lyrics** (boolean): Trả thêm mốc thời gian từng từ trong `meta` của item.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/sounds \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"prompt\": \"rain on a tin roof\", \"loop\": true}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicSoundsBody"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/lyrics": {
      "post": {
        "operationId": "submitMusicLyrics",
        "tags": [
          "music"
        ],
        "summary": "Viết lời",
        "description": "**`music.lyrics`**\n\n### Chức năng\nViết lời bài hát từ một mô tả ngắn. Không tạo nhạc.\n\n### Bắt buộc\n- **prompt**: Mô tả ngắn (tối đa 200 ký tự).\n\n### Tuỳ chọn\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/lyrics \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"prompt\": \"a love song about Hanoi in autumn\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicLyricsBody"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/wav": {
      "post": {
        "operationId": "submitMusicWav",
        "tags": [
          "music"
        ],
        "summary": "Xuất WAV",
        "description": "**`music.wav`**\n\n### Chức năng\nLấy file WAV chất lượng cao của một bài Wave đã tạo.\n\n### Bắt buộc\n- **clip_id**: Id của bài do Wave tạo (lấy trong `items[].meta.clip_id` của job trước).\n\n### Tuỳ chọn\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/wav \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"clip_id\": \"b5f2…\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicClipBody"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/mp4": {
      "post": {
        "operationId": "submitMusicMp4",
        "tags": [
          "music"
        ],
        "summary": "Xuất video MP4",
        "description": "**`music.mp4`**\n\n### Chức năng\nLấy video MP4 (nhạc + hình) của một bài Wave đã tạo.\n\n### Bắt buộc\n- **clip_id**: Id của bài do Wave tạo (lấy trong `items[].meta.clip_id` của job trước).\n\n### Tuỳ chọn\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/mp4 \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"clip_id\": \"b5f2…\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicClipBody"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/midi": {
      "post": {
        "operationId": "submitMusicMidi",
        "tags": [
          "music"
        ],
        "summary": "Xuất MIDI",
        "description": "**`music.midi`**\n\n### Chức năng\nLấy file MIDI của một bài Wave đã tạo.\n\n### Bắt buộc\n- **clip_id**: Id của bài do Wave tạo (lấy trong `items[].meta.clip_id` của job trước).\n\n### Tuỳ chọn\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/midi \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"clip_id\": \"b5f2…\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicClipBody"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/cover-art": {
      "post": {
        "operationId": "submitMusicCoverArt",
        "tags": [
          "music"
        ],
        "summary": "Ảnh bìa",
        "description": "**`music.cover_art`**\n\n### Chức năng\nTạo ảnh bìa cho một bài Wave đã tạo.\n\n### Bắt buộc\n- **clip_id**: Id của bài do Wave tạo (lấy trong `items[].meta.clip_id` của job trước).\n\n### Tuỳ chọn\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/cover-art \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"clip_id\": \"b5f2…\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicClipBody"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/vocal-removal": {
      "post": {
        "operationId": "submitMusicVocalRemoval",
        "tags": [
          "music"
        ],
        "summary": "Tách giọng / tách nhạc cụ",
        "description": "**`music.vocal_removal`**\n\n### Chức năng\nTách giọng hát khỏi nhạc nền, hoặc tách từng nhạc cụ.\n\n### Bắt buộc\n- **clip_id / audio_url**: Bài cần tách: bài Wave đã tạo, hoặc file của bạn.\n\n### Tuỳ chọn\n- **audio** (file): Chỉ có trong `multipart/form-data`: file audio nguồn (tối đa 20 MiB), thay cho `audio_url`.\n- **type** (string): `separate_vocal`: tách lời và nhạc nền; `split_stem`: tách thành nhiều stem; `split_stem_advanced`: lấy một stem chọn bằng `stem_name`.\n- **stem_name** (string): Bắt buộc với `split_stem_advanced`, không dùng với type khác.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n**Gửi file (multipart/form-data)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/vocal-removal \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -F 'type=separate_vocal' \\\n  -F audio=@song.mp3\n```\n\n**Gửi URL (JSON)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/vocal-removal \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"audio_url\": \"https://example.com/song.mp3\", \"type\": \"separate_vocal\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. `type`: `separate_vocal` (giọng + nhạc nền), `split_stem` (nhiều nhạc cụ), `split_stem_advanced` (một nhạc cụ, chọn bằng `stem_name`).",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicVocalRemovalJson"
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/MusicVocalRemovalMultipart"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/persona": {
      "post": {
        "operationId": "submitMusicPersona",
        "tags": [
          "music"
        ],
        "summary": "Tạo persona",
        "description": "**`music.persona`**\n\n### Chức năng\nLưu giọng hát và phong cách của một bài để dùng lại cho bài sau.\n\n### Bắt buộc\n- **clip_id**: Id của bài do Wave tạo (lấy trong `items[].meta.clip_id` của job trước).\n- **name**: Tên persona.\n- **description**: Mô tả persona.\n\n### Tuỳ chọn\n- **vocal_start_s** (number): Giây bắt đầu đoạn giọng hát dùng để tạo persona.\n- **vocal_end_s** (number): Phải lớn hơn vocal_start_s.\n- **style** (string): Thẻ phong cách của persona.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/persona \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"clip_id\": \"b5f2…\", \"name\": \"Mai voice\", \"description\": \"clear, warm female voice\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Dùng `persona_id` trong kết quả cho trường `persona_id` khi tạo bài.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicPersonaBody"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/music/jobs/claim-check": {
      "post": {
        "operationId": "submitMusicClaimCheck",
        "tags": [
          "music"
        ],
        "summary": "Kiểm tra claim YouTube",
        "description": "**`music.claim_check`**\n\n### Chức năng\nKiểm tra bài hát có bị YouTube Content ID claim không.\n\n### Bắt buộc\n- **audio** (file, multipart) hoặc **audio_urls** (URL, JSON): nguồn cần xử lý.\n\n### Tuỳ chọn\n- **titles** (array): Tên bài theo thứ tự bài (các part `audio` multipart trước, rồi `audio_urls`); số phần tử bằng số bài.\n- **watch_minutes** (integer): Theo dõi claim bao lâu sau khi tải lên.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n\n### Ví dụ\n**Gửi file (multipart/form-data)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/claim-check \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -F 'titles=[\"Song 1\", \"Song 2\"]' \\\n  -F 'callback_url=https://example.com/wave-callback' \\\n  -F audio=@song-1.mp3 \\\n  -F audio=@song-2.mp3\n```\n\n**Gửi URL (JSON)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/music/jobs/claim-check \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"audio_urls\": [\"https://example.com/song-1.mp3\", \"https://example.com/song-2.mp3\"], \"titles\": [\"Song 1\", \"Song 2\"], \"callback_url\": \"https://example.com/wave-callback\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.\n\n### Lưu ý\n1. Bài bị claim có kết quả sau khoảng 2 phút. Job xong sau khoảng 70 phút; lúc đó bài không bị claim mới là `clear`.\n2. `result` mỗi bài: `audio`, `lyrics`, `copyright` hoặc `clear`.\n3. Giá tính theo số bài.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/MusicClaimCheckMultipart"
              },
              "examples": {
                "claim_check": {
                  "summary": "music.claim_check · multipart audio",
                  "value": {
                    "titles": "[\"Song 1\",\"Song 2\"]",
                    "audio": [
                      "song-1.mp3",
                      "song-2.mp3"
                    ]
                  }
                }
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MusicClaimCheckJson"
              },
              "examples": {
                "claim_check": {
                  "summary": "music.claim_check · audio_urls",
                  "value": {
                    "audio_urls": [
                      "https://example.com/song-1.mp3",
                      "https://example.com/song-2.mp3"
                    ],
                    "titles": [
                      "Song 1",
                      "Song 2"
                    ],
                    "callback_url": "https://example.com/wave-callback"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/images/jobs/generate": {
      "post": {
        "operationId": "submitImageGenerate",
        "tags": [
          "images"
        ],
        "summary": "Tạo ảnh",
        "description": "**`image.generate`**\n\n### Chức năng\nTạo ảnh từ mô tả.\n\n### Bắt buộc\n- **prompt**: Mô tả ảnh.\n\n### Tuỳ chọn\n- **model** (string): `auto`, `gpt-image-1`, `nano-banana-2-lite`, `nano-banana-2`, `nano-banana-pro`, `grok-imagine`, `grok-imagine-pro` (tiền tố `chatgpt/`, `flow/`, `grok/` được chấp nhận).\n- **aspect_ratio** (string): Tỉ lệ khung; tập giá trị theo provider (xem mô tả).\n- **count** (integer): Số ảnh, 1..4.\n- **drop_unsupported** (boolean): Bỏ các trường provider không hỗ trợ thay vì trả 400; trường bị bỏ được ghi trong `dropped`.\n- **seed** (integer): flow.\n- **references** (array): Ảnh tham chiếu (flow, tối đa 10 kể cả nguồn edit).\n- **negative_prompt** (string): Không provider ảnh nào hỗ trợ; cần drop_unsupported.\n- **resolution** (string): Chỉ cho video; bị từ chối trên ảnh trừ khi drop_unsupported.\n- **duration_s** (integer): Chỉ cho video.\n- **start_image** (string): Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`.\n- **end_image** (string): Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`.\n- **provider_options** (object): Theo provider; chỉ grok dùng: `{\"grok\":{\"nsfw\",\"watermark\",\"skip_upsampler\"}}`.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n- **reference** (file): Chỉ có trong `multipart/form-data`: ảnh tham chiếu (flow), mỗi part một file, tối đa 20 MiB mỗi file; tính chung với `references`.\n\n### Ví dụ\n**Gửi file (multipart/form-data)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/images/jobs/generate \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -F 'prompt=a red fox in snow' \\\n  -F 'aspect_ratio=16:9' \\\n  -F reference=@photo.png\n```\n\n**Gửi URL (JSON)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/images/jobs/generate \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"prompt\": \"a red fox in snow\", \"aspect_ratio\": \"16:9\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ImageGenerateJson"
              },
              "examples": {
                "generate": {
                  "summary": "image.generate",
                  "value": {
                    "prompt": "A red fox in snow",
                    "aspect_ratio": "16:9"
                  }
                }
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/ImageGenerateMultipart"
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    },
    "/api/v1/images/jobs/edit": {
      "post": {
        "operationId": "submitImageEdit",
        "tags": [
          "images"
        ],
        "summary": "Sửa ảnh",
        "description": "**`image.edit`**\n\n### Chức năng\nSửa một ảnh bạn gửi theo mô tả.\n\n### Bắt buộc\n- **image** (file, multipart) hoặc **image_url** (URL, JSON): nguồn cần xử lý.\n- **prompt**: Cách sửa ảnh.\n\n### Tuỳ chọn\n- **model** (string): `auto`, `gpt-image-1`, `nano-banana-2-lite`, `nano-banana-2`, `nano-banana-pro`, `grok-imagine`, `grok-imagine-pro` (tiền tố `chatgpt/`, `flow/`, `grok/` được chấp nhận).\n- **aspect_ratio** (string): Tỉ lệ khung; tập giá trị theo provider (xem mô tả).\n- **count** (integer): Số ảnh, 1..4.\n- **drop_unsupported** (boolean): Bỏ các trường provider không hỗ trợ thay vì trả 400; trường bị bỏ được ghi trong `dropped`.\n- **seed** (integer): flow.\n- **references** (array): Ảnh tham chiếu (flow, tối đa 10 kể cả nguồn edit).\n- **negative_prompt** (string): Không provider ảnh nào hỗ trợ; cần drop_unsupported.\n- **resolution** (string): Chỉ cho video; bị từ chối trên ảnh trừ khi drop_unsupported.\n- **duration_s** (integer): Chỉ cho video.\n- **start_image** (string): Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`.\n- **end_image** (string): Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`.\n- **provider_options** (object): Theo provider; chỉ grok dùng: `{\"grok\":{\"nsfw\",\"watermark\",\"skip_upsampler\"}}`.\n- **callback_url** (string): URL nhận callback khi job đổi giai đoạn; body là `Job`.\n- **reference** (file): Chỉ có trong `multipart/form-data`: ảnh tham chiếu (flow), mỗi part một file, tối đa 20 MiB mỗi file; tính chung với `references`.\n\n### Ví dụ\n**Gửi file (multipart/form-data)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/images/jobs/edit \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -F 'prompt=make it night' \\\n  -F image=@photo.png\n```\n\n**Gửi URL (JSON)**\n```bash\ncurl -X POST https://wave.31.56.109.92.compute.verda.run/api/v1/images/jobs/edit \\\n  -H 'Authorization: Bearer <API_KEY>' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"prompt\": \"make it night\", \"image_url\": \"https://example.com/photo.png\"}'\n```\n\n### Theo dõi kết quả\nGọi `GET /api/v1/jobs/{id}` với `id` vừa nhận, hoặc gửi `callback_url` để Wave gọi bạn khi xong. Job lỗi thì không bị trừ tiền.",
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ImageEditJson"
              },
              "examples": {
                "edit_url": {
                  "summary": "image.edit · image_url",
                  "value": {
                    "prompt": "Make it night",
                    "image_url": "https://example.com/photo.png"
                  }
                }
              }
            },
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/ImageEditMultipart"
              },
              "examples": {
                "edit_file": {
                  "summary": "image.edit · image file",
                  "value": {
                    "prompt": "Make it night",
                    "image": "photo.png"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "202": {
            "$ref": "#/components/responses/JobAccepted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalError"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "apiKey": {
        "type": "http",
        "scheme": "bearer",
        "description": "Khóa API `sk_live_...` trong header `Authorization: Bearer <key>`."
      }
    },
    "parameters": {
      "IdempotencyKey": {
        "name": "Idempotency-Key",
        "in": "header",
        "required": false,
        "description": "Trở thành `request_id` của job (tối đa 200 ký tự). Gửi lại cùng khóa với cùng body trả về job cũ; khác body → 409 `IDEMPOTENCY_MISMATCH`. Bỏ trống thì Wave tự sinh.",
        "schema": {
          "type": "string",
          "maxLength": 200
        }
      }
    },
    "responses": {
      "JobAccepted": {
        "description": "Job đã được nhận và xếp hàng.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Job"
            }
          }
        }
      },
      "ModelList": {
        "description": "Danh sách model.",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "required": [
                "models"
              ],
              "properties": {
                "models": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ModelEntry"
                  }
                }
              }
            }
          }
        }
      },
      "BadRequest": {
        "description": "Yêu cầu không hợp lệ: `INVALID_REQUEST`, `INVALID_INPUT`, `NO_PRICE`, `MODEL_UNAVAILABLE`, `SENSITIVE_WORD_ERROR`, `ADMISSION_INVALID`, `UNKNOWN_SOURCE_CLIP`, `AFFINITY_MISMATCH`.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "Unauthorized": {
        "description": "Thiếu hoặc sai khóa API (`UNAUTHORIZED`).",
        "headers": {
          "WWW-Authenticate": {
            "schema": {
              "type": "string"
            },
            "example": "Bearer realm=\"wave\""
          }
        },
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "PaymentRequired": {
        "description": "Số dư không đủ (`INSUFFICIENT_BALANCE`).",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "Forbidden": {
        "description": "Khóa không được phép (`SCOPE_DENIED`), tài khoản bị khóa (`CUSTOMER_SUSPENDED`) hoặc chưa xác minh email (`EMAIL_UNVERIFIED`).",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "NotFound": {
        "description": "Không tìm thấy (`NOT_FOUND`).",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "Conflict": {
        "description": "Xung đột: `IDEMPOTENCY_MISMATCH` hoặc `CONFLICT` (audio chưa sẵn sàng).",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "Gone": {
        "description": "Kết quả đã hết hạn (`EXPIRED`).",
        "headers": {
          "Cache-Control": {
            "schema": {
              "type": "string"
            },
            "example": "no-store"
          }
        },
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            },
            "example": {
              "error": {
                "code": "EXPIRED",
                "message": "this file has expired"
              }
            }
          }
        }
      },
      "RangeNotSatisfiable": {
        "description": "Range nằm ngoài kích thước file; không có body.",
        "headers": {
          "Content-Range": {
            "schema": {
              "type": "string"
            },
            "example": "bytes */1234567"
          }
        }
      },
      "TooManyRequests": {
        "description": "Vượt giới hạn tốc độ của khóa (`RATE_LIMITED`).",
        "headers": {
          "Retry-After": {
            "description": "Số giây nên chờ.",
            "schema": {
              "type": "integer",
              "minimum": 1
            }
          }
        },
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "BadGateway": {
        "description": "Upstream không phục vụ được (`UPSTREAM_UNAVAILABLE`).",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "InternalError": {
        "description": "Lỗi nội bộ (`INTERNAL`).",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "OpenAIBadRequest": {
        "description": "`invalid_request_error`: body/field sai (`param` chỉ field), `content_policy_violation`, `upstream_rejected`, `invalid_input`, `model_unavailable`, `no_price`, `idempotency_mismatch`, `unknown_source_clip`, `affinity_mismatch`.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/OpenAIError"
            }
          }
        }
      },
      "OpenAIUnauthorized": {
        "description": "`invalid_api_key`.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/OpenAIError"
            }
          }
        }
      },
      "OpenAIInsufficientQuota": {
        "description": "`insufficient_quota`.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/OpenAIError"
            }
          }
        }
      },
      "OpenAIForbidden": {
        "description": "`scope_denied` (scope, tài khoản bị khóa, email chưa xác minh).",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/OpenAIError"
            }
          }
        }
      },
      "OpenAINotFound": {
        "description": "`not_found`.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/OpenAIError"
            }
          }
        }
      },
      "OpenAIRateLimit": {
        "description": "`rate_limit_error` / `rate_limit_exceeded` (giới hạn khóa, backlog hoặc upstream).",
        "headers": {
          "Retry-After": {
            "schema": {
              "type": "integer",
              "minimum": 1
            }
          }
        },
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/OpenAIError"
            }
          }
        }
      },
      "OpenAIServerError": {
        "description": "`server_error`: job thất bại (code là mã lỗi job viết thường, kèm `job_id`) hoặc `missing_image`.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/OpenAIError"
            }
          }
        }
      },
      "OpenAITimeout": {
        "description": "`server_error` / `timeout`: hết giờ chờ, job vẫn chạy; `job_id` để poll `GET /api/v1/jobs/{id}`.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/OpenAIError"
            }
          }
        }
      }
    },
    "schemas": {
      "ErrorCode": {
        "type": "string",
        "description": "Mã lỗi Wave. Mã trả ngay khi gọi API: INVALID_REQUEST, NOT_FOUND, UNAUTHORIZED, SCOPE_DENIED, CUSTOMER_SUSPENDED, EMAIL_UNVERIFIED, RATE_LIMITED, NO_PRICE, INSUFFICIENT_BALANCE, IDEMPOTENCY_MISMATCH, BACKLOG, CONFLICT, INTERNAL, UPSTREAM_UNAVAILABLE, MODEL_UNAVAILABLE, ADMISSION_INVALID, UNKNOWN_SOURCE_CLIP, AFFINITY_MISMATCH, INVALID_INPUT. Các mã còn lại là lỗi kết thúc của job (`Job.error.code`). `EXPIRED` chỉ có ở `GET /files/{id}`.",
        "enum": [
          "INVALID_REQUEST",
          "NOT_FOUND",
          "UNAUTHORIZED",
          "SCOPE_DENIED",
          "CUSTOMER_SUSPENDED",
          "EMAIL_UNVERIFIED",
          "RATE_LIMITED",
          "NO_PRICE",
          "INSUFFICIENT_BALANCE",
          "IDEMPOTENCY_MISMATCH",
          "BACKLOG",
          "CONFLICT",
          "INTERNAL",
          "QUEUE_TIMEOUT",
          "PROCESSING_TIMEOUT",
          "AFFINITY_DEAD",
          "ADMISSION_INVALID",
          "MODEL_UNAVAILABLE",
          "SUBMISSION_UNKNOWN",
          "NOTHING_DELIVERED",
          "SOURCE_FETCH_FAILED",
          "CAPTCHA_CAPACITY",
          "CAPTCHA_SOLVE_FAILED",
          "CAPTCHA_UNAVAILABLE",
          "CAPTCHA_TOKEN_REJECTED",
          "POOL_EXHAUSTED",
          "ACCOUNT_AUTH",
          "UPSTREAM_REJECTED",
          "UPSTREAM_UNAVAILABLE",
          "UPSTREAM_RATE_LIMIT",
          "EMPTY_UPSTREAM_RESULT",
          "GENERATION_FAILED",
          "GENERATION_TIMEOUT",
          "UNKNOWN_SOURCE_CLIP",
          "AFFINITY_MISMATCH",
          "INVALID_INPUT",
          "SENSITIVE_WORD_ERROR",
          "UPLOAD_FAILED",
          "EXPIRED"
        ]
      },
      "Error": {
        "type": "object",
        "description": "Envelope lỗi chung.",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "object",
            "required": [
              "code",
              "message"
            ],
            "properties": {
              "code": {
                "$ref": "#/components/schemas/ErrorCode"
              },
              "message": {
                "type": "string"
              }
            }
          }
        }
      },
      "OpenAIError": {
        "type": "object",
        "description": "Envelope lỗi của facade OpenAI.",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "object",
            "required": [
              "message",
              "type"
            ],
            "properties": {
              "message": {
                "type": "string"
              },
              "type": {
                "type": "string",
                "enum": [
                  "invalid_request_error",
                  "insufficient_quota",
                  "rate_limit_error",
                  "server_error"
                ]
              },
              "code": {
                "type": "string",
                "description": "`invalid_api_key`, `insufficient_quota`, `rate_limit_exceeded`, `scope_denied`, `content_policy_violation`, `upstream_rejected`, `not_found`, `timeout`, `missing_image`, hoặc mã lỗi Wave viết thường (`invalid_request`, `model_unavailable`, ...)."
              },
              "param": {
                "type": "string",
                "description": "Field gây lỗi khi là lỗi validate của facade."
              },
              "job_id": {
                "type": "string",
                "description": "Mở rộng của Wave: id job khi job đã được tạo (504 hoặc job thất bại)."
              }
            }
          }
        }
      },
      "Me": {
        "type": "object",
        "required": [
          "customer_id",
          "api_key_id",
          "customer_status",
          "rate_limit_per_minute",
          "scope"
        ],
        "properties": {
          "customer_id": {
            "type": "string"
          },
          "api_key_id": {
            "type": "string"
          },
          "customer_status": {
            "type": "string",
            "enum": [
              "active",
              "suspended",
              "closed"
            ]
          },
          "rate_limit_per_minute": {
            "type": "integer"
          },
          "scope": {
            "description": "Phạm vi của khóa; null hoặc mảng rỗng = không giới hạn ở trục đó.",
            "oneOf": [
              {
                "type": "null"
              },
              {
                "type": "object",
                "properties": {
                  "kinds": {
                    "type": "array",
                    "items": {
                      "$ref": "#/components/schemas/JobKind"
                    }
                  },
                  "models": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            ]
          }
        }
      },
      "Wallet": {
        "type": "object",
        "required": [
          "balance_vnd",
          "held_vnd",
          "available_vnd"
        ],
        "properties": {
          "balance_vnd": {
            "type": "integer",
            "description": "Số dư trong ví (VND)."
          },
          "held_vnd": {
            "type": "integer",
            "description": "Đang giữ cho các job chưa kết thúc (VND)."
          },
          "available_vnd": {
            "type": "integer",
            "description": "balance_vnd − held_vnd: số tiền job mới có thể dùng (VND)."
          }
        },
        "example": {
          "balance_vnd": 4975000,
          "held_vnd": 25000,
          "available_vnd": 4950000
        }
      },
      "JobKind": {
        "type": "string",
        "enum": [
          "music.generate",
          "music.extend",
          "music.cover",
          "music.add_vocals",
          "music.add_instrumental",
          "music.upload_cover",
          "music.advanced_cover",
          "music.upload_extend",
          "music.mashup",
          "music.infill",
          "music.lyrics",
          "music.persona",
          "music.cover_art",
          "music.vocal_removal",
          "music.midi",
          "music.wav",
          "music.mp4",
          "music.sounds",
          "music.claim_check",
          "image.generate",
          "image.edit",
          "video.generate"
        ]
      },
      "ModelEntry": {
        "type": "object",
        "required": [
          "kind",
          "model",
          "provider",
          "unit_vnd",
          "enabled"
        ],
        "properties": {
          "kind": {
            "$ref": "#/components/schemas/JobKind"
          },
          "model": {
            "type": "string",
            "description": "Tên model trong bảng giá; `*` là giá cho `auto`."
          },
          "provider": {
            "type": "string",
            "description": "`suno`, `chatgpt`, `flow`, `grok`, hoặc `auto` khi nhiều provider cùng phục vụ dòng `*`."
          },
          "unit_vnd": {
            "type": "integer",
            "description": "Giá một đơn vị (VND)."
          },
          "enabled": {
            "type": "boolean",
            "description": "Hiện có tài khoản phục vụ được."
          }
        }
      },
      "JobList": {
        "type": "object",
        "required": [
          "jobs"
        ],
        "properties": {
          "jobs": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Job"
            }
          },
          "cursor": {
            "type": "string",
            "description": "Có khi còn trang sau."
          }
        }
      },
      "Job": {
        "type": "object",
        "description": "Trạng thái job; cùng shape trong response và trong callback.",
        "required": [
          "id",
          "kind",
          "medium",
          "status",
          "model",
          "requested_model",
          "quantity",
          "delivered",
          "items",
          "request_id",
          "created_at"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "kind": {
            "$ref": "#/components/schemas/JobKind"
          },
          "medium": {
            "type": "string",
            "enum": [
              "music",
              "image",
              "video"
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "succeeded",
              "failed"
            ]
          },
          "progress": {
            "type": "string",
            "description": "Chỉ có khi job đang chạy và có tiến độ: `text` (đã có lời/tiêu đề), `first` (item đầu nghe được qua `stream_url`), `partial` (một số item đã có kết quả trong `meta`, ví dụ bài đã bị claim trong `music.claim_check`; được báo lại mỗi khi có thêm kết quả).",
            "enum": [
              "text",
              "first",
              "partial"
            ]
          },
          "model": {
            "type": "string",
            "description": "Model thực tế; rỗng khi là `auto` và job chưa kết thúc."
          },
          "requested_model": {
            "type": "string"
          },
          "quantity": {
            "type": "integer"
          },
          "delivered": {
            "type": "integer"
          },
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/JobItem"
            }
          },
          "error": {
            "$ref": "#/components/schemas/JobError"
          },
          "request_id": {
            "type": "string"
          },
          "callback_url": {
            "type": "string",
            "format": "uri"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "completed_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "JobItem": {
        "type": "object",
        "description": "Kết quả đã lưu (`url`, `bytes`, `expires_at`) hoặc, khi đang tạo, preview (`stream_url`).",
        "required": [
          "index",
          "content_type"
        ],
        "properties": {
          "index": {
            "type": "integer"
          },
          "url": {
            "type": "string",
            "format": "uri",
            "description": "URL tải kết quả (`/files/{id}`)."
          },
          "stream_url": {
            "type": "string",
            "format": "uri",
            "description": "URL phát khi đang tạo (`/api/v1/media/{id}`)."
          },
          "content_type": {
            "type": "string"
          },
          "bytes": {
            "type": "integer"
          },
          "expires_at": {
            "type": "string",
            "format": "date-time"
          },
          "meta": {
            "description": "Metadata do provider trả (JSON tùy ý)."
          }
        }
      },
      "JobError": {
        "type": "object",
        "required": [
          "code",
          "message",
          "retryable"
        ],
        "properties": {
          "code": {
            "$ref": "#/components/schemas/ErrorCode"
          },
          "message": {
            "type": "string"
          },
          "retryable": {
            "type": "boolean"
          }
        }
      },
      "AlignedLyrics": {
        "type": "object",
        "required": [
          "words"
        ],
        "properties": {
          "words": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "word",
                "start_s",
                "end_s",
                "success",
                "p_align"
              ],
              "properties": {
                "word": {
                  "type": "string"
                },
                "start_s": {
                  "type": "number"
                },
                "end_s": {
                  "type": "number"
                },
                "success": {
                  "type": "boolean"
                },
                "p_align": {
                  "type": "number"
                }
              }
            }
          },
          "waveform": {
            "type": "array",
            "items": {
              "type": "number"
            }
          },
          "cer": {
            "type": "number",
            "description": "Tỉ lệ lỗi ký tự của việc căn lời."
          },
          "streamed": {
            "type": "boolean"
          }
        }
      },
      "CallbackURL": {
        "type": "string",
        "format": "uri",
        "description": "URL nhận callback khi job đổi giai đoạn; body là `Job`. Phải là http(s) công khai."
      },
      "MusicModel": {
        "type": "string",
        "description": "Bỏ trống/`auto` để Wave chọn. Bí danh (không phân biệt hoa thường): v2, v3, v35, v4, v45, v45plus (v4.5+), v45all, v5, v55, v6, v6wild, v6mini; hoặc khóa wire `chirp-*`. Tên khác → 400 `MODEL_UNAVAILABLE`.",
        "default": "auto"
      },
      "MusicGenerateFields": {
        "type": "object",
        "description": "Các trường chung của generate/extend/cover/infill/add_vocals/add_instrumental/upload_cover/upload_extend/mashup (Suno). Chế độ custom bật khi có `style` hoặc `title` (cần cả hai; `prompt` là lời, bắt buộc trừ khi `instrumental`). Chế độ mô tả khi không có: `prompt` bắt buộc (riêng music.generate instrumental có thể bỏ trống).",
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "MusicGenerateRequest": {
        "description": "Tạo bài hát mới (kind mặc định của /api/v1/music/jobs). Không nhận clip_id, continue_at, start_s, end_s, full_lyrics, audio_url hay part audio.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.generate",
                "default": "music.generate"
              }
            }
          }
        ]
      },
      "MusicExtendRequest": {
        "description": "Kéo dài một clip do Wave tạo.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicExtendBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.extend"
              }
            }
          }
        ]
      },
      "MusicCoverRequest": {
        "description": "Cover một clip do Wave tạo.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicCoverBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.cover"
              }
            }
          }
        ]
      },
      "MusicInfillRequest": {
        "description": "Thay một đoạn (tối thiểu 10 giây) của clip hoặc của audio tải lên. Luôn ở chế độ custom (cần style, title, prompt). Nguồn: `clip_id` hoặc đúng một audio (`audio_url` / part `audio`).",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicInfillBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.infill"
              }
            }
          }
        ]
      },
      "MusicAddVocalsRequest": {
        "description": "Thêm giọng hát lên audio tải lên (đúng một: `audio_url` hoặc part `audio`). Luôn custom: cần `style`, `title`, `prompt` (lời); `instrumental` bị từ chối.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicAddVocalsBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.add_vocals"
              }
            }
          }
        ]
      },
      "MusicAddInstrumentalRequest": {
        "description": "Tạo nhạc nền cho giọng hát tải lên (đúng một audio). Luôn custom và instrumental: cần `style`, `title`; không nhận `prompt`.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicAddInstrumentalBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.add_instrumental"
              }
            }
          }
        ]
      },
      "MusicUploadCoverRequest": {
        "description": "Cover audio tải lên (đúng một: `audio_url` hoặc part `audio`).",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicUploadCoverBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.upload_cover"
              }
            }
          }
        ]
      },
      "MusicUploadExtendRequest": {
        "description": "Kéo dài audio tải lên (đúng một audio). Không nhận clip_id.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicUploadExtendBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.upload_extend"
              }
            }
          }
        ]
      },
      "MusicMashupRequest": {
        "description": "Trộn đúng hai audio: `audio_urls` (2 phần tử) hoặc hai part `audio` (có thể kết hợp `audio_url` + `audio_urls`).",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicMashupBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.mashup"
              }
            }
          }
        ]
      },
      "MusicSoundsRequest": {
        "description": "Tạo hiệu ứng âm thanh (model v5 trở lên hoặc auto).",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicSoundsBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.sounds"
              }
            }
          }
        ]
      },
      "MusicLyricsRequest": {
        "description": "Viết lời từ mô tả ngắn.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicLyricsBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.lyrics"
              }
            }
          }
        ]
      },
      "MusicClipRequest": {
        "description": "Thao tác trên một clip do Wave tạo: `music.wav` (WAV), `music.mp4` (video), `music.midi` (MIDI), `music.cover_art` (ảnh bìa).",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicClipBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "music.wav",
                  "music.mp4",
                  "music.midi",
                  "music.cover_art"
                ]
              }
            }
          }
        ]
      },
      "MusicVocalRemovalRequest": {
        "description": "Tách giọng/stem. Nguồn: đúng một trong `clip_id` hoặc audio (`audio_url` / part `audio`).",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicVocalRemovalBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.vocal_removal"
              }
            }
          }
        ]
      },
      "MusicPersonaRequest": {
        "description": "Tạo persona giọng hát từ một clip.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicPersonaBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.persona"
              }
            }
          }
        ]
      },
      "MusicJobRequest": {
        "description": "Body JSON của POST /api/v1/music/jobs; `kind` chọn schema, mặc định `music.generate`.",
        "oneOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateRequest"
          },
          {
            "$ref": "#/components/schemas/MusicExtendRequest"
          },
          {
            "$ref": "#/components/schemas/MusicCoverRequest"
          },
          {
            "$ref": "#/components/schemas/MusicInfillRequest"
          },
          {
            "$ref": "#/components/schemas/MusicAddVocalsRequest"
          },
          {
            "$ref": "#/components/schemas/MusicAddInstrumentalRequest"
          },
          {
            "$ref": "#/components/schemas/MusicUploadCoverRequest"
          },
          {
            "$ref": "#/components/schemas/MusicAdvancedCoverRequest"
          },
          {
            "$ref": "#/components/schemas/MusicUploadExtendRequest"
          },
          {
            "$ref": "#/components/schemas/MusicMashupRequest"
          },
          {
            "$ref": "#/components/schemas/MusicSoundsRequest"
          },
          {
            "$ref": "#/components/schemas/MusicLyricsRequest"
          },
          {
            "$ref": "#/components/schemas/MusicClipRequest"
          },
          {
            "$ref": "#/components/schemas/MusicVocalRemovalRequest"
          },
          {
            "$ref": "#/components/schemas/MusicPersonaRequest"
          },
          {
            "$ref": "#/components/schemas/MusicClaimCheckRequest"
          }
        ],
        "discriminator": {
          "propertyName": "kind",
          "mapping": {
            "music.generate": "#/components/schemas/MusicGenerateRequest",
            "music.extend": "#/components/schemas/MusicExtendRequest",
            "music.cover": "#/components/schemas/MusicCoverRequest",
            "music.infill": "#/components/schemas/MusicInfillRequest",
            "music.add_vocals": "#/components/schemas/MusicAddVocalsRequest",
            "music.add_instrumental": "#/components/schemas/MusicAddInstrumentalRequest",
            "music.upload_cover": "#/components/schemas/MusicUploadCoverRequest",
            "music.upload_extend": "#/components/schemas/MusicUploadExtendRequest",
            "music.mashup": "#/components/schemas/MusicMashupRequest",
            "music.sounds": "#/components/schemas/MusicSoundsRequest",
            "music.lyrics": "#/components/schemas/MusicLyricsRequest",
            "music.wav": "#/components/schemas/MusicClipRequest",
            "music.mp4": "#/components/schemas/MusicClipRequest",
            "music.midi": "#/components/schemas/MusicClipRequest",
            "music.cover_art": "#/components/schemas/MusicClipRequest",
            "music.vocal_removal": "#/components/schemas/MusicVocalRemovalRequest",
            "music.persona": "#/components/schemas/MusicPersonaRequest",
            "music.advanced_cover": "#/components/schemas/MusicAdvancedCoverRequest",
            "music.claim_check": "#/components/schemas/MusicClaimCheckRequest"
          }
        }
      },
      "MusicMultipartRequest": {
        "type": "object",
        "description": "Dạng multipart của MusicJobRequest: mỗi part text là một field JSON cùng tên (hoặc part `request` chứa cả object JSON); part file `audio` là nguồn âm thanh (tối đa 20 MiB mỗi file). Tổng body ≤ 41 MiB; riêng `music.claim_check` (part `kind` phải đứng trước các part `audio`) tối đa 15 file và ≤ 301 MiB.",
        "properties": {
          "request": {
            "type": "string",
            "description": "Cả body JSON (MusicJobRequest) trong một part."
          },
          "kind": {
            "$ref": "#/components/schemas/JobKind"
          },
          "audio": {
            "type": "array",
            "description": "1 file cho add_vocals/add_instrumental/upload_cover/advanced_cover/upload_extend/vocal_removal/infill (không clip_id); 2 file cho mashup; 1..15 file cho claim_check (cộng với `audio_urls`).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 15
          }
        },
        "additionalProperties": true
      },
      "MediaRef": {
        "description": "Ảnh nguồn: chuỗi URL http(s), hoặc object `{url}` / `{b64}` (chỉ một) kèm `crop` tùy chọn (flow). Grok không nhận `crop`.",
        "oneOf": [
          {
            "type": "string",
            "format": "uri"
          },
          {
            "type": "object",
            "properties": {
              "url": {
                "type": "string",
                "format": "uri"
              },
              "b64": {
                "type": "string",
                "description": "Ảnh mã hoá base64."
              },
              "crop": {
                "type": "object",
                "description": "Khung cắt chuẩn hoá 0..1 mỗi cạnh (flow).",
                "properties": {
                  "top": {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 1
                  },
                  "left": {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 1
                  },
                  "bottom": {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 1
                  },
                  "right": {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 1
                  }
                }
              }
            }
          }
        ]
      },
      "ImageFields": {
        "type": "object",
        "description": "Body ảnh thống nhất. Provider do `model` quyết định; field provider không hỗ trợ bị từ chối (400) trừ khi `drop_unsupported: true` (khi đó ghi vào `dropped`). chatgpt (`gpt-image-1`): aspect_ratio 1:1|16:9|9:16, không nhận seed/references/negative_prompt/provider_options/resolution/start_image/end_image/duration_s. flow (`nano-banana-*`): aspect_ratio 1:1|16:9|9:16|3:4|4:3 (hoặc landscape|portrait|square), seed ≥ 0, references tối đa 10 (tính cả ảnh nguồn). grok (`grok-imagine`, `grok-imagine-pro`): chỉ image.generate, aspect_ratio 1:1|2:3|3:2|4:3|3:4|16:9|9:16, provider_options.grok.",
        "required": [
          "prompt"
        ],
        "properties": {
          "model": {
            "type": "string",
            "default": "auto",
            "description": "`auto`, `gpt-image-1`, `nano-banana-2-lite`, `nano-banana-2`, `nano-banana-pro`, `grok-imagine`, `grok-imagine-pro` (tiền tố `chatgpt/`, `flow/`, `grok/` được chấp nhận)."
          },
          "prompt": {
            "type": "string",
            "maxLength": 32000,
            "description": "Nội dung cần vẽ."
          },
          "aspect_ratio": {
            "type": "string",
            "description": "Tỉ lệ khung; tập giá trị theo provider (xem mô tả)."
          },
          "count": {
            "type": "integer",
            "minimum": 1,
            "maximum": 4,
            "default": 1,
            "description": "Số ảnh, 1..4."
          },
          "drop_unsupported": {
            "type": "boolean",
            "default": false,
            "description": "Bỏ các trường provider không hỗ trợ thay vì trả 400; trường bị bỏ được ghi trong `dropped`."
          },
          "seed": {
            "type": "integer",
            "minimum": 0,
            "description": "flow."
          },
          "references": {
            "type": "array",
            "description": "Ảnh tham chiếu (flow, tối đa 10 kể cả nguồn edit).",
            "items": {
              "$ref": "#/components/schemas/MediaRef"
            },
            "maxItems": 10
          },
          "negative_prompt": {
            "type": "string",
            "description": "Không provider ảnh nào hỗ trợ; cần drop_unsupported."
          },
          "resolution": {
            "type": "string",
            "description": "Chỉ cho video; bị từ chối trên ảnh trừ khi drop_unsupported."
          },
          "duration_s": {
            "type": "integer",
            "description": "Chỉ cho video."
          },
          "start_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`."
          },
          "end_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`."
          },
          "provider_options": {
            "type": "object",
            "description": "Theo provider; chỉ grok dùng: `{\"grok\":{\"nsfw\",\"watermark\",\"skip_upsampler\"}}`.",
            "properties": {
              "grok": {
                "$ref": "#/components/schemas/GrokOptions"
              }
            }
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "GrokOptions": {
        "type": "object",
        "description": "Bật/tắt của Grok; mặc định đều false.",
        "properties": {
          "nsfw": {
            "type": "boolean",
            "default": false,
            "description": "Cho phép nội dung NSFW (cờ `enable_nsfw` của Grok)."
          },
          "watermark": {
            "type": "boolean",
            "default": false,
            "description": "Thêm watermark của Grok (cờ `enable_watermark`)."
          },
          "skip_upsampler": {
            "type": "boolean",
            "default": false,
            "description": "Cờ `skip_upsampler` của Grok, gửi nguyên như vậy."
          }
        },
        "additionalProperties": false
      },
      "ImageGenerateRequest": {
        "description": "Tạo ảnh (kind mặc định của /api/v1/images/jobs). Không nhận `image_url` hay part `image`.",
        "allOf": [
          {
            "$ref": "#/components/schemas/ImageGenerateBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "image.generate",
                "default": "image.generate"
              }
            }
          }
        ]
      },
      "ImageEditRequest": {
        "description": "Sửa ảnh (chatgpt hoặc flow; grok không có). Đúng một nguồn: `image_url` hoặc part `image`. Với chatgpt, `aspect_ratio` bị bỏ (ghi vào dropped) vì upstream lấy theo ảnh nguồn.",
        "allOf": [
          {
            "$ref": "#/components/schemas/ImageEditBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "image.edit"
              }
            }
          }
        ]
      },
      "ImageJobRequest": {
        "description": "Body JSON của POST /api/v1/images/jobs; `kind` mặc định `image.generate`.",
        "oneOf": [
          {
            "$ref": "#/components/schemas/ImageGenerateRequest"
          },
          {
            "$ref": "#/components/schemas/ImageEditRequest"
          }
        ],
        "discriminator": {
          "propertyName": "kind",
          "mapping": {
            "image.generate": "#/components/schemas/ImageGenerateRequest",
            "image.edit": "#/components/schemas/ImageEditRequest"
          }
        }
      },
      "ImageMultipartRequest": {
        "type": "object",
        "description": "Dạng multipart của ImageJobRequest: part text = field JSON (hoặc part `request`); part file `image` là nguồn của image.edit (đúng một), part file `reference` là ảnh tham chiếu (flow).",
        "properties": {
          "request": {
            "type": "string",
            "description": "Cả body JSON (ImageJobRequest) trong một part."
          },
          "kind": {
            "type": "string",
            "enum": [
              "image.generate",
              "image.edit"
            ]
          },
          "image": {
            "type": "string",
            "format": "binary",
            "description": "File ảnh nguồn của `image.edit` (đúng một file, tối đa 20 MiB)."
          },
          "reference": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "description": "Ảnh tham chiếu (flow), mỗi part một file, tối đa 20 MiB mỗi file."
          }
        },
        "additionalProperties": true
      },
      "VideoGenerateRequest": {
        "type": "object",
        "description": "Body video thống nhất (kind `video.generate`). flow (`veo-3.1-lite`, `veo-3.1-fast` (mặc định auto), `veo-3.1-quality`, `omni-flash`): aspect_ratio 16:9|9:16 (landscape|portrait), duration_s 4|6|8 (lite/fast), 8 (quality), 4|6|8|10 (omni-flash), mặc định 8; resolution 360p|720p chỉ omni-flash; ảnh vào tối đa 3 (lite/fast), 0 (quality), 7 (omni-flash); references tối đa 7; seed/negative_prompt/provider_options không hỗ trợ. grok (`grok-imagine-video`): count phải 1, aspect_ratio 1:1|2:3|3:2|16:9|9:16, duration_s 6|10|15 (mặc định 6), resolution 480p|720p (mặc định 480p), chỉ start_image (không crop), không references/end_image/seed/negative_prompt. `prompt` bắt buộc khi không có ảnh nào (text-to-video).",
        "properties": {
          "kind": {
            "type": "string",
            "const": "video.generate",
            "default": "video.generate"
          },
          "model": {
            "type": "string",
            "default": "auto",
            "description": "`auto`, `veo-3.1-lite`, `veo-3.1-fast`, `veo-3.1-quality`, `omni-flash` (flow) hoặc `grok-imagine-video` (grok)."
          },
          "prompt": {
            "type": "string",
            "maxLength": 32000,
            "description": "Nội dung video; bắt buộc khi không có ảnh."
          },
          "aspect_ratio": {
            "type": "string",
            "description": "Tỉ lệ khung; tập giá trị tuỳ model (xem mô tả)."
          },
          "count": {
            "type": "integer",
            "minimum": 1,
            "maximum": 4,
            "default": 1,
            "description": "Số video, 1..4 (grok: 1)."
          },
          "drop_unsupported": {
            "type": "boolean",
            "default": false,
            "description": "Bỏ các trường model không hỗ trợ thay vì trả 400; trường bị bỏ được ghi trong `dropped`."
          },
          "duration_s": {
            "type": "integer",
            "description": "Giây; tập giá trị theo model."
          },
          "resolution": {
            "type": "string",
            "description": "`360p`|`720p` (flow omni-flash), `480p`|`720p` (grok)."
          },
          "start_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Ảnh khung đầu. Trong `multipart/form-data` có thể gửi một part file cùng tên thay cho object này."
          },
          "end_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Ảnh khung cuối. Trong `multipart/form-data` có thể gửi một part file cùng tên thay cho object này."
          },
          "image_url": {
            "type": "string",
            "format": "uri",
            "description": "Bí danh cũ của `start_image` (URL); không gửi cùng start_image."
          },
          "references": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MediaRef"
            },
            "maxItems": 7,
            "description": "Ingredients (flow); không dùng cùng start_image/end_image. Trong `multipart/form-data` có thể gửi các part file `reference` thay cho object này."
          },
          "seed": {
            "type": "integer",
            "description": "Không model video nào hỗ trợ; cần `drop_unsupported`."
          },
          "negative_prompt": {
            "type": "string",
            "description": "Không model video nào hỗ trợ; cần `drop_unsupported`."
          },
          "provider_options": {
            "type": "object",
            "properties": {
              "grok": {
                "$ref": "#/components/schemas/GrokOptions"
              }
            },
            "description": "Chỉ grok: `{\"grok\":{\"nsfw\",\"watermark\",\"skip_upsampler\"}}`."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "VideoMultipartRequest": {
        "type": "object",
        "description": "Dạng multipart của VideoGenerateRequest: part text = field JSON (hoặc part `request`); part file `start_image`, `end_image` (tối đa một mỗi loại, không gửi trùng với body) và `reference` (nhiều).",
        "properties": {
          "request": {
            "type": "string",
            "description": "Cả body JSON (VideoGenerateRequest) trong một part."
          },
          "start_image": {
            "type": "string",
            "format": "binary",
            "description": "File ảnh khung đầu (tối đa 20 MiB); không gửi kèm `start_image` trong JSON."
          },
          "end_image": {
            "type": "string",
            "format": "binary",
            "description": "File ảnh khung cuối (tối đa 20 MiB); không gửi kèm `end_image` trong JSON."
          },
          "reference": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "description": "Ảnh tham chiếu (flow), mỗi part một file, tối đa 20 MiB mỗi file."
          }
        },
        "additionalProperties": true
      },
      "OpenAIImageGenerationRequest": {
        "type": "object",
        "description": "Body theo OpenAI Images. Field lạ → 400. `size`, `quality`, `background`, `output_format`, `output_compression`, `moderation`, `partial_images`, `style`, `user` được nhận và bỏ qua.",
        "required": [
          "prompt"
        ],
        "additionalProperties": false,
        "properties": {
          "prompt": {
            "type": "string",
            "maxLength": 32000,
            "description": "Nội dung cần vẽ."
          },
          "model": {
            "type": "string",
            "description": "Chỉ truyền tiếp khi là model Wave phục vụ cho image.generate; tên OpenAI (dall-e-3...) rơi về auto."
          },
          "n": {
            "type": "integer",
            "minimum": 1,
            "maximum": 4,
            "default": 1,
            "description": "Số ảnh, 1..4."
          },
          "response_format": {
            "type": "string",
            "enum": [
              "b64_json",
              "url"
            ],
            "default": "b64_json",
            "description": "`b64_json` (mặc định) hoặc `url` (URL file của Wave)."
          },
          "stream": {
            "type": "boolean",
            "description": "Phải là false."
          },
          "ratio": {
            "type": "string",
            "description": "Mở rộng của gateway cũ, thành `aspect_ratio` (vd 1:1, 16:9, 9:16)."
          },
          "size": {
            "type": "string",
            "description": "Nhận để tương thích với OpenAI và bị bỏ qua."
          },
          "quality": {
            "type": "string",
            "description": "Nhận để tương thích với OpenAI và bị bỏ qua."
          },
          "background": {
            "type": "string",
            "description": "Nhận để tương thích với OpenAI và bị bỏ qua."
          },
          "output_format": {
            "type": "string",
            "description": "Nhận để tương thích với OpenAI và bị bỏ qua."
          },
          "output_compression": {
            "type": "integer",
            "description": "Nhận để tương thích với OpenAI và bị bỏ qua."
          },
          "moderation": {
            "type": "string",
            "description": "Nhận để tương thích với OpenAI và bị bỏ qua."
          },
          "partial_images": {
            "type": "integer",
            "description": "Nhận để tương thích với OpenAI và bị bỏ qua."
          },
          "style": {
            "type": "string",
            "description": "Nhận để tương thích với OpenAI và bị bỏ qua."
          },
          "user": {
            "type": "string",
            "description": "Nhận để tương thích với OpenAI và bị bỏ qua."
          }
        }
      },
      "OpenAIImageEditRequest": {
        "type": "object",
        "required": [
          "image",
          "prompt"
        ],
        "properties": {
          "image": {
            "type": "string",
            "format": "binary",
            "description": "Đúng một file ảnh nguồn (tối đa 20 MiB)."
          },
          "prompt": {
            "type": "string",
            "maxLength": 32000,
            "description": "Cách sửa ảnh."
          },
          "model": {
            "type": "string",
            "description": "Chỉ truyền tiếp khi là model Wave phục vụ cho image.edit."
          },
          "n": {
            "type": "integer",
            "const": 1,
            "default": 1,
            "description": "Phải là 1."
          },
          "response_format": {
            "type": "string",
            "enum": [
              "b64_json",
              "url"
            ],
            "default": "b64_json",
            "description": "`b64_json` (mặc định) hoặc `url` (URL file của Wave)."
          },
          "stream": {
            "type": "boolean",
            "description": "Phải là false."
          }
        },
        "additionalProperties": true
      },
      "OpenAIImagesResponse": {
        "type": "object",
        "required": [
          "created",
          "data",
          "output_format"
        ],
        "properties": {
          "created": {
            "type": "integer",
            "description": "Unix seconds."
          },
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "b64_json": {
                  "type": "string"
                },
                "url": {
                  "type": "string",
                  "format": "uri"
                }
              }
            }
          },
          "output_format": {
            "type": "string",
            "enum": [
              "png",
              "jpeg",
              "webp"
            ]
          }
        }
      },
      "MusicAdvancedCoverRequest": {
        "description": "Cover cho audio mà Suno từ chối khi tải lên: wave tự biến đổi audio và render qua Studio, rồi cover. Body giống hệt `music.upload_cover` (đúng một: `audio_url` hoặc part `audio`); đổi giữa hai loại chỉ bằng `kind`. Một job duy nhất: poll đúng id đã gửi, kết quả là các clip cover; tính giá `music.advanced_cover`.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicAdvancedCoverBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.advanced_cover"
              }
            }
          }
        ]
      },
      "MusicClaimCheckRequest": {
        "description": "Cách gửi: muốn tải file lên thì gửi `multipart/form-data`, mỗi bài một part `audio`; chỉ dùng `audio_urls` thì gửi JSON cũng được. Kiểm tra 1..15 bài hát xem YouTube Content ID có claim không. wave dựng các bài thành một video thử riêng tư (cách nhau 5 giây im lặng, tổng tối đa 60 phút), tải lên một kênh YouTube của wave và đọc claim từ YouTube Studio. Các bài là các part `audio` multipart rồi đến `audio_urls`, theo đúng thứ tự đó; `titles` cũng theo thứ tự này. Một job duy nhất: poll đúng id đã gửi. Tính giá và trừ tiền theo từng bài; kết quả có một item cho mỗi bài (`application/json`, xem ClaimCheckTrackResult; cùng object này nằm trong `meta` của item). Video từ 15 phút trở lên chỉ được tải lên kênh đã xác minh tải video dài. Job chạy trong thời gian theo dõi (`watch_minutes`) cộng 10 phút ân hạn: xong ngay khi mọi bài đều bị claim `audio`, nếu không thì khi hết thời gian theo dõi; bài không có claim chỉ được báo là `clear` vào lúc đó. Video thử không bao giờ bị xoá khỏi kênh. Không phải chờ hết: ngay khi một bài bị claim, job có `progress: partial` và `items` có sẵn một item cho mỗi bài; bài chưa có claim mang `result: pending`. Mỗi lần có thêm bài bị claim, `items` được cập nhật và có callback `partial`.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicClaimCheckBody"
          },
          {
            "type": "object",
            "required": [
              "kind"
            ],
            "properties": {
              "kind": {
                "type": "string",
                "const": "music.claim_check"
              }
            }
          }
        ]
      },
      "ClaimCheckTrackResult": {
        "type": "object",
        "description": "Kết luận cho một bài của job `music.claim_check`: nội dung của item kết quả `index` (và `meta` của nó).",
        "required": [
          "index",
          "title",
          "result",
          "video_start",
          "video_end"
        ],
        "properties": {
          "index": {
            "type": "integer",
            "description": "Vị trí của bài trong request."
          },
          "title": {
            "type": "string"
          },
          "result": {
            "type": "string",
            "description": "`audio`: bản thu bị claim; `lyrics`: chỉ phần sáng tác/lời (gồm cả claim giai điệu) bị claim; `copyright`: loại claim khác; `clear`: không có claim khi hết thời gian theo dõi; `pending`: chỉ có khi job chưa xong, bài chưa có claim nào. Một bài đã bị claim khi job chưa xong vẫn có thể lên mức cao hơn (vd `lyrics` thành `audio`).",
            "enum": [
              "audio",
              "lyrics",
              "copyright",
              "clear",
              "pending"
            ]
          },
          "type": {
            "type": "string",
            "description": "Loại claim mà kết quả lấy từ đó (cao nhất trong audio, melody, lyrics, copyright).",
            "enum": [
              "audio",
              "melody",
              "lyrics",
              "copyright"
            ]
          },
          "claimant": {
            "type": "string",
            "description": "Chủ sở hữu đầu tiên, đã chuẩn hoá (vd `UMG`); vắng khi có tên không rõ."
          },
          "claimant_full": {
            "type": "string",
            "description": "Mọi chủ sở hữu, theo thứ tự của Studio."
          },
          "range": {
            "type": "object",
            "description": "Đoạn bị claim, tính bằng giây trên chính file audio của bài (0 là đầu file đã gửi). Vắng khi claim không có mốc thời gian.",
            "required": [
              "start",
              "end"
            ],
            "properties": {
              "start": {
                "type": "number"
              },
              "end": {
                "type": "number"
              }
            }
          },
          "video_start": {
            "type": "number",
            "description": "Giây tính từ đầu video thử, nơi bài bắt đầu. `claims` dùng mốc thời gian của video thử."
          },
          "video_end": {
            "type": "number",
            "description": "Giây tính từ đầu video thử, nơi bài kết thúc."
          },
          "claims": {
            "type": "array",
            "description": "Mọi claim được gán cho bài.",
            "items": {
              "$ref": "#/components/schemas/ClaimCheckClaim"
            }
          }
        }
      },
      "ClaimCheckClaim": {
        "type": "object",
        "description": "Một claim như YouTube Studio liệt kê.",
        "properties": {
          "claim_id": {
            "type": "string"
          },
          "video_id": {
            "type": "string",
            "description": "Video thử riêng tư."
          },
          "start": {
            "type": "number",
            "description": "Giây trên video thử."
          },
          "end": {
            "type": "number",
            "description": "Giây trên video thử."
          },
          "title": {
            "type": "string",
            "description": "Tiêu đề của tài sản (asset) claim."
          },
          "artist": {
            "type": "string"
          },
          "owner_ids": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "claimant": {
            "type": "string"
          },
          "claimant_full": {
            "type": "string"
          },
          "record_label": {
            "type": "string",
            "description": "Hãng của bản thu được lấy mẫu; không bao giờ dùng làm claimant."
          },
          "raw_type": {
            "type": "string",
            "description": "Loại claim của Studio, vd `CLAIM_TYPE_AUDIO`."
          },
          "type": {
            "type": "string",
            "enum": [
              "audio",
              "melody",
              "lyrics",
              "copyright"
            ]
          }
        }
      },
      "MusicGenerateBody": {
        "description": "Tạo bài hát mới (kind mặc định của /api/v1/music/jobs). Không nhận clip_id, continue_at, start_s, end_s, full_lyrics, audio_url hay part audio.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateFields"
          },
          {
            "type": "object",
            "properties": {}
          }
        ]
      },
      "MusicExtendBody": {
        "description": "Kéo dài một clip do Wave tạo.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateFields"
          },
          {
            "type": "object",
            "required": [
              "clip_id"
            ],
            "properties": {
              "clip_id": {
                "type": "string",
                "description": "Clip nguồn; phải do Wave tạo (400 `UNKNOWN_SOURCE_CLIP` nếu không)."
              },
              "continue_at": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "Giây bắt đầu phần nối tiếp."
              }
            }
          }
        ]
      },
      "MusicCoverBody": {
        "description": "Cover một clip do Wave tạo.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateFields"
          },
          {
            "type": "object",
            "required": [
              "clip_id"
            ],
            "properties": {
              "clip_id": {
                "type": "string",
                "description": "Clip nguồn; phải do Wave tạo (400 `UNKNOWN_SOURCE_CLIP` nếu không). Id clip nằm trong `meta` của item kết quả."
              },
              "start_s": {
                "type": "number",
                "minimum": 0,
                "description": "Đi cùng end_s; cửa sổ cover."
              },
              "end_s": {
                "type": "number",
                "description": "Phải lớn hơn start_s."
              }
            }
          }
        ]
      },
      "MusicInfillBody": {
        "description": "Thay một đoạn (tối thiểu 10 giây) của clip hoặc của audio tải lên. Luôn ở chế độ custom (cần style, title, prompt). Nguồn: `clip_id` hoặc đúng một audio (`audio_url` / part `audio`).",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateFields"
          },
          {
            "type": "object",
            "required": [
              "start_s",
              "end_s",
              "full_lyrics"
            ],
            "properties": {
              "clip_id": {
                "type": "string",
                "description": "Clip nguồn; phải do Wave tạo (400 `UNKNOWN_SOURCE_CLIP` nếu không). Id clip nằm trong `meta` của item kết quả."
              },
              "audio_url": {
                "type": "string",
                "format": "uri",
                "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
              },
              "audio": {
                "type": "array",
                "description": "Chỉ có trong `multipart/form-data`: file audio nguồn (tối đa 20 MiB), thay cho `audio_url`.",
                "items": {
                  "type": "string",
                  "format": "binary"
                },
                "maxItems": 1
              },
              "start_s": {
                "type": "number",
                "minimum": 0,
                "description": "Giây bắt đầu đoạn được thay."
              },
              "end_s": {
                "type": "number",
                "description": "end_s - start_s ≥ 10."
              },
              "full_lyrics": {
                "type": "string",
                "description": "Toàn bộ lời sau khi sửa."
              }
            }
          }
        ]
      },
      "MusicAddVocalsBody": {
        "description": "Thêm giọng hát lên audio tải lên (đúng một: `audio_url` hoặc part `audio`). Luôn custom: cần `style`, `title`, `prompt` (lời); `instrumental` bị từ chối.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateFields"
          },
          {
            "type": "object",
            "required": [
              "style",
              "title",
              "prompt"
            ],
            "properties": {
              "audio_url": {
                "type": "string",
                "format": "uri",
                "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
              },
              "audio": {
                "type": "array",
                "description": "Chỉ có trong `multipart/form-data`: file audio nguồn (tối đa 20 MiB), thay cho `audio_url`.",
                "items": {
                  "type": "string",
                  "format": "binary"
                },
                "maxItems": 1
              }
            }
          }
        ]
      },
      "MusicAddInstrumentalBody": {
        "description": "Tạo nhạc nền cho giọng hát tải lên (đúng một audio). Luôn custom và instrumental: cần `style`, `title`; không nhận `prompt`.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateFields"
          },
          {
            "type": "object",
            "required": [
              "style",
              "title"
            ],
            "properties": {
              "audio_url": {
                "type": "string",
                "format": "uri",
                "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
              },
              "audio": {
                "type": "array",
                "description": "Chỉ có trong `multipart/form-data`: file audio nguồn (tối đa 20 MiB), thay cho `audio_url`.",
                "items": {
                  "type": "string",
                  "format": "binary"
                },
                "maxItems": 1
              }
            }
          }
        ]
      },
      "MusicUploadCoverBody": {
        "description": "Cover audio tải lên (đúng một: `audio_url` hoặc part `audio`).",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateFields"
          },
          {
            "type": "object",
            "properties": {
              "audio_url": {
                "type": "string",
                "format": "uri",
                "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
              },
              "audio": {
                "type": "array",
                "description": "Chỉ có trong `multipart/form-data`: file audio nguồn (tối đa 20 MiB), thay cho `audio_url`.",
                "items": {
                  "type": "string",
                  "format": "binary"
                },
                "maxItems": 1
              },
              "advanced_fallback": {
                "type": "boolean",
                "default": false,
                "description": "Khi Suno từ chối audio tải lên, cùng job này tiếp tục bằng luồng `music.advanced_cover` (wave tự chọn cách biến đổi audio) và bị tính giá của `music.advanced_cover`. Chỉ khi luồng đó thực sự chạy mới tính giá này; tải lên thành công trực tiếp tính giá `music.upload_cover`. Giữ tạm giá `music.advanced_cover` khi tạo job."
              }
            }
          }
        ]
      },
      "MusicAdvancedCoverBody": {
        "description": "Cover cho audio mà Suno từ chối khi tải lên: wave tự biến đổi audio và render qua Studio, rồi cover. Body giống hệt `music.upload_cover` (đúng một: `audio_url` hoặc part `audio`); đổi giữa hai loại chỉ bằng `kind`. Một job duy nhất: poll đúng id đã gửi, kết quả là các clip cover; tính giá `music.advanced_cover`.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateFields"
          },
          {
            "type": "object",
            "properties": {
              "audio_url": {
                "type": "string",
                "format": "uri",
                "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
              },
              "audio": {
                "type": "array",
                "description": "Chỉ có trong `multipart/form-data`: file audio nguồn (tối đa 20 MiB), thay cho `audio_url`.",
                "items": {
                  "type": "string",
                  "format": "binary"
                },
                "maxItems": 1
              }
            }
          }
        ]
      },
      "MusicUploadExtendBody": {
        "description": "Kéo dài audio tải lên (đúng một audio). Không nhận clip_id.",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateFields"
          },
          {
            "type": "object",
            "properties": {
              "audio_url": {
                "type": "string",
                "format": "uri",
                "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
              },
              "audio": {
                "type": "array",
                "description": "Chỉ có trong `multipart/form-data`: file audio nguồn (tối đa 20 MiB), thay cho `audio_url`.",
                "items": {
                  "type": "string",
                  "format": "binary"
                },
                "maxItems": 1
              },
              "continue_at": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "Giây trong audio đã tải lên, nơi phần nối bắt đầu."
              }
            }
          }
        ]
      },
      "MusicMashupBody": {
        "description": "Trộn đúng hai audio: `audio_urls` (2 phần tử) hoặc hai part `audio` (có thể kết hợp `audio_url` + `audio_urls`).",
        "allOf": [
          {
            "$ref": "#/components/schemas/MusicGenerateFields"
          },
          {
            "type": "object",
            "properties": {
              "audio_url": {
                "type": "string",
                "format": "uri",
                "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
              },
              "audio_urls": {
                "type": "array",
                "items": {
                  "type": "string",
                  "format": "uri"
                },
                "maxItems": 2,
                "description": "URL http(s) của audio nguồn: hai URL, hoặc một URL cộng `audio_url` hay một part `audio`."
              },
              "audio": {
                "type": "array",
                "description": "Chỉ có trong `multipart/form-data`: hai file audio (tối đa 20 MiB mỗi file), hoặc một file cộng một URL.",
                "items": {
                  "type": "string",
                  "format": "binary"
                },
                "maxItems": 2
              }
            }
          }
        ]
      },
      "MusicSoundsBody": {
        "type": "object",
        "description": "Tạo hiệu ứng âm thanh (model v5 trở lên hoặc auto).",
        "required": [
          "prompt"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 500,
            "description": "Mô tả âm thanh cần tạo."
          },
          "loop": {
            "type": "boolean",
            "default": false,
            "description": "Tạo âm thanh lặp liền mạch."
          },
          "tempo": {
            "type": "integer",
            "minimum": 1,
            "maximum": 300,
            "description": "Nhịp, BPM."
          },
          "key": {
            "type": "string",
            "default": "Any",
            "enum": [
              "Any",
              "C",
              "C#",
              "D",
              "D#",
              "E",
              "F",
              "F#",
              "G",
              "G#",
              "A",
              "A#",
              "B",
              "Cm",
              "C#m",
              "Dm",
              "D#m",
              "Em",
              "Fm",
              "F#m",
              "Gm",
              "G#m",
              "Am",
              "A#m",
              "Bm"
            ],
            "description": "Giọng (tông) nhạc."
          },
          "grab_lyrics": {
            "type": "boolean",
            "default": false,
            "description": "Trả thêm mốc thời gian từng từ trong `meta` của item."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "MusicLyricsBody": {
        "type": "object",
        "description": "Viết lời từ mô tả ngắn.",
        "required": [
          "prompt"
        ],
        "properties": {
          "prompt": {
            "type": "string",
            "maxLength": 200,
            "description": "Mô tả ngắn bài hát cần viết lời (tối đa 200 ký tự)."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "MusicClipBody": {
        "type": "object",
        "description": "Thao tác trên một clip do Wave tạo: `music.wav` (WAV), `music.mp4` (video), `music.midi` (MIDI), `music.cover_art` (ảnh bìa).",
        "required": [
          "clip_id"
        ],
        "properties": {
          "clip_id": {
            "type": "string",
            "description": "Clip nguồn; phải do Wave tạo (400 `UNKNOWN_SOURCE_CLIP` nếu không). Id clip nằm trong `meta` của item kết quả."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "MusicVocalRemovalBody": {
        "type": "object",
        "description": "Tách giọng/stem. Nguồn: đúng một trong `clip_id` hoặc audio (`audio_url` / part `audio`).",
        "properties": {
          "clip_id": {
            "type": "string",
            "description": "Clip nguồn; phải do Wave tạo (400 `UNKNOWN_SOURCE_CLIP` nếu không). Id clip nằm trong `meta` của item kết quả."
          },
          "audio_url": {
            "type": "string",
            "format": "uri",
            "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
          },
          "audio": {
            "type": "array",
            "description": "Chỉ có trong `multipart/form-data`: file audio nguồn (tối đa 20 MiB), thay cho `audio_url`.",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 1
          },
          "type": {
            "type": "string",
            "default": "separate_vocal",
            "enum": [
              "separate_vocal",
              "split_stem",
              "split_stem_advanced"
            ],
            "description": "`separate_vocal`: tách lời và nhạc nền; `split_stem`: tách thành nhiều stem; `split_stem_advanced`: lấy một stem chọn bằng `stem_name`."
          },
          "stem_name": {
            "type": "string",
            "description": "Bắt buộc với `split_stem_advanced`, không dùng với type khác.",
            "enum": [
              "Vocals",
              "Backing Vocals",
              "Drums",
              "Bass",
              "Guitar",
              "Keyboard",
              "Percussion",
              "Strings",
              "Synth",
              "FX",
              "Brass",
              "Woodwinds"
            ]
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "MusicPersonaBody": {
        "type": "object",
        "description": "Tạo persona giọng hát từ một clip.",
        "required": [
          "clip_id",
          "name",
          "description"
        ],
        "properties": {
          "clip_id": {
            "type": "string",
            "description": "Clip nguồn; phải do Wave tạo (400 `UNKNOWN_SOURCE_CLIP` nếu không). Id clip nằm trong `meta` của item kết quả."
          },
          "name": {
            "type": "string",
            "description": "Tên persona."
          },
          "description": {
            "type": "string",
            "description": "Mô tả persona."
          },
          "vocal_start_s": {
            "type": "number",
            "minimum": 0,
            "default": 0,
            "description": "Giây bắt đầu đoạn giọng hát dùng để tạo persona."
          },
          "vocal_end_s": {
            "type": "number",
            "default": 30,
            "description": "Phải lớn hơn vocal_start_s."
          },
          "style": {
            "type": "string",
            "description": "Thẻ phong cách của persona."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "MusicClaimCheckBody": {
        "type": "object",
        "description": "Cách gửi: muốn tải file lên thì gửi `multipart/form-data`, mỗi bài một part `audio`; chỉ dùng `audio_urls` thì gửi JSON cũng được. Kiểm tra 1..15 bài hát xem YouTube Content ID có claim không. wave dựng các bài thành một video thử riêng tư (cách nhau 5 giây im lặng, tổng tối đa 60 phút), tải lên một kênh YouTube của wave và đọc claim từ YouTube Studio. Các bài là các part `audio` multipart rồi đến `audio_urls`, theo đúng thứ tự đó; `titles` cũng theo thứ tự này. Một job duy nhất: poll đúng id đã gửi. Tính giá và trừ tiền theo từng bài; kết quả có một item cho mỗi bài (`application/json`, xem ClaimCheckTrackResult; cùng object này nằm trong `meta` của item). Video từ 15 phút trở lên chỉ được tải lên kênh đã xác minh tải video dài. Job chạy trong thời gian theo dõi (`watch_minutes`) cộng 10 phút ân hạn: xong ngay khi mọi bài đều bị claim `audio`, nếu không thì khi hết thời gian theo dõi; bài không có claim chỉ được báo là `clear` vào lúc đó. Video thử không bao giờ bị xoá khỏi kênh. Không phải chờ hết: ngay khi một bài bị claim, job có `progress: partial` và `items` có sẵn một item cho mỗi bài; bài chưa có claim mang `result: pending`. Mỗi lần có thêm bài bị claim, `items` được cập nhật và có callback `partial`.",
        "properties": {
          "audio": {
            "type": "array",
            "description": "Chỉ có trong `multipart/form-data`: mỗi part `audio` là một file bài hát (tối đa 20 MiB). Gửi part `kind` trước các part `audio`. Tính chung với `audio_urls`: tổng 1..15 bài; các part `audio` đứng trước `audio_urls`. Với curl: `-F audio=@bai-1.mp3 -F audio=@bai-2.mp3` (cần dấu `@` để gửi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 15
          },
          "audio_urls": {
            "type": "array",
            "description": "URL http(s) mà wave tải về (tối đa 20 MiB mỗi file). Tính chung với các part `audio`: tổng cộng 1..15 bài.",
            "items": {
              "type": "string",
              "format": "uri"
            },
            "maxItems": 15
          },
          "titles": {
            "type": "array",
            "description": "Tên bài theo thứ tự bài (các part `audio` multipart trước, rồi `audio_urls`); số phần tử bằng số bài. Chuỗi rỗng, hoặc không gửi danh sách, nghĩa là tên file bỏ phần mở rộng. Tên được trả lại trong kết quả và dùng để khớp claim theo tên khi khoảng thời gian bị claim không rơi vào bài nào.",
            "items": {
              "type": "string",
              "maxLength": 200
            },
            "maxItems": 15
          },
          "watch_minutes": {
            "type": "integer",
            "minimum": 10,
            "maximum": 120,
            "default": 60,
            "description": "Theo dõi claim bao lâu sau khi tải lên. Gộp nhiều bài theo dõi từ một giờ trở lên sẽ được cộng thêm tới 75 phút (20 ms mỗi giây video) nếu như vậy dài hơn."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "ImageGenerateBody": {
        "description": "Tạo ảnh (kind mặc định của /api/v1/images/jobs). Không nhận `image_url` hay part `image`.",
        "allOf": [
          {
            "$ref": "#/components/schemas/ImageFields"
          },
          {
            "type": "object",
            "properties": {
              "reference": {
                "type": "array",
                "description": "Chỉ có trong `multipart/form-data`: ảnh tham chiếu (flow), mỗi part một file, tối đa 20 MiB mỗi file; tính chung với `references`.",
                "items": {
                  "type": "string",
                  "format": "binary"
                },
                "maxItems": 10
              }
            }
          }
        ]
      },
      "ImageEditBody": {
        "description": "Sửa ảnh (chatgpt hoặc flow; grok không có). Đúng một nguồn: `image_url` hoặc part `image`. Với chatgpt, `aspect_ratio` bị bỏ (ghi vào dropped) vì upstream lấy theo ảnh nguồn.",
        "allOf": [
          {
            "$ref": "#/components/schemas/ImageFields"
          },
          {
            "type": "object",
            "properties": {
              "image_url": {
                "type": "string",
                "format": "uri",
                "description": "URL http(s) của ảnh nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Không tải được thì job FAILED `SOURCE_FETCH_FAILED`."
              },
              "image": {
                "type": "string",
                "format": "binary",
                "description": "Chỉ có trong `multipart/form-data`: file ảnh nguồn cần sửa (đúng một file, tối đa 20 MiB), thay cho `image_url`."
              },
              "reference": {
                "type": "array",
                "description": "Chỉ có trong `multipart/form-data`: ảnh tham chiếu (flow), mỗi part một file, tối đa 20 MiB mỗi file; tính chung với `references`.",
                "items": {
                  "type": "string",
                  "format": "binary"
                },
                "maxItems": 10
              }
            }
          }
        ]
      },
      "MusicInfillJson": {
        "type": "object",
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "clip_id": {
            "type": "string",
            "description": "Clip nguồn; phải do Wave tạo (400 `UNKNOWN_SOURCE_CLIP` nếu không). Id clip nằm trong `meta` của item kết quả."
          },
          "audio_url": {
            "type": "string",
            "format": "uri",
            "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
          },
          "start_s": {
            "type": "number",
            "minimum": 0,
            "description": "Giây bắt đầu đoạn được thay."
          },
          "end_s": {
            "type": "number",
            "description": "end_s - start_s ≥ 10."
          },
          "full_lyrics": {
            "type": "string",
            "description": "Toàn bộ lời sau khi sửa."
          }
        }
      },
      "MusicInfillMultipart": {
        "type": "object",
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "clip_id": {
            "type": "string",
            "description": "Clip nguồn; phải do Wave tạo (400 `UNKNOWN_SOURCE_CLIP` nếu không). Id clip nằm trong `meta` của item kết quả."
          },
          "audio": {
            "type": "array",
            "description": "File audio (tối đa 20 MiB mỗi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 1
          },
          "start_s": {
            "type": "number",
            "minimum": 0,
            "description": "Giây bắt đầu đoạn được thay."
          },
          "end_s": {
            "type": "number",
            "description": "end_s - start_s ≥ 10."
          },
          "full_lyrics": {
            "type": "string",
            "description": "Toàn bộ lời sau khi sửa."
          }
        }
      },
      "MusicAddVocalsJson": {
        "type": "object",
        "required": [
          "audio_url"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio_url": {
            "type": "string",
            "format": "uri",
            "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
          }
        }
      },
      "MusicAddVocalsMultipart": {
        "type": "object",
        "required": [
          "audio"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio": {
            "type": "array",
            "description": "File audio (tối đa 20 MiB mỗi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 1
          }
        }
      },
      "MusicAddInstrumentalJson": {
        "type": "object",
        "required": [
          "audio_url"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio_url": {
            "type": "string",
            "format": "uri",
            "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
          }
        }
      },
      "MusicAddInstrumentalMultipart": {
        "type": "object",
        "required": [
          "audio"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio": {
            "type": "array",
            "description": "File audio (tối đa 20 MiB mỗi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 1
          }
        }
      },
      "MusicUploadCoverJson": {
        "type": "object",
        "required": [
          "audio_url"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio_url": {
            "type": "string",
            "format": "uri",
            "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
          },
          "advanced_fallback": {
            "type": "boolean",
            "default": false,
            "description": "Khi Suno từ chối audio tải lên, cùng job này tiếp tục bằng luồng `music.advanced_cover` (wave tự chọn cách biến đổi audio) và bị tính giá của `music.advanced_cover`. Chỉ khi luồng đó thực sự chạy mới tính giá này; tải lên thành công trực tiếp tính giá `music.upload_cover`. Giữ tạm giá `music.advanced_cover` khi tạo job."
          }
        }
      },
      "MusicUploadCoverMultipart": {
        "type": "object",
        "required": [
          "audio"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio": {
            "type": "array",
            "description": "File audio (tối đa 20 MiB mỗi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 1
          },
          "advanced_fallback": {
            "type": "boolean",
            "default": false,
            "description": "Khi Suno từ chối audio tải lên, cùng job này tiếp tục bằng luồng `music.advanced_cover` (wave tự chọn cách biến đổi audio) và bị tính giá của `music.advanced_cover`. Chỉ khi luồng đó thực sự chạy mới tính giá này; tải lên thành công trực tiếp tính giá `music.upload_cover`. Giữ tạm giá `music.advanced_cover` khi tạo job."
          }
        }
      },
      "MusicAdvancedCoverJson": {
        "type": "object",
        "required": [
          "audio_url"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio_url": {
            "type": "string",
            "format": "uri",
            "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
          }
        }
      },
      "MusicAdvancedCoverMultipart": {
        "type": "object",
        "required": [
          "audio"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio": {
            "type": "array",
            "description": "File audio (tối đa 20 MiB mỗi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 1
          }
        }
      },
      "MusicUploadExtendJson": {
        "type": "object",
        "required": [
          "audio_url"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio_url": {
            "type": "string",
            "format": "uri",
            "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
          },
          "continue_at": {
            "type": "number",
            "exclusiveMinimum": 0,
            "description": "Giây trong audio đã tải lên, nơi phần nối bắt đầu."
          }
        }
      },
      "MusicUploadExtendMultipart": {
        "type": "object",
        "required": [
          "audio"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio": {
            "type": "array",
            "description": "File audio (tối đa 20 MiB mỗi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 1
          },
          "continue_at": {
            "type": "number",
            "exclusiveMinimum": 0,
            "description": "Giây trong audio đã tải lên, nơi phần nối bắt đầu."
          }
        }
      },
      "MusicMashupJson": {
        "type": "object",
        "required": [
          "audio_urls"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio_url": {
            "type": "string",
            "format": "uri",
            "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
          },
          "audio_urls": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "uri"
            },
            "maxItems": 2,
            "description": "URL http(s) của audio nguồn: hai URL, hoặc một URL cộng `audio_url` hay một part `audio`."
          }
        }
      },
      "MusicMashupMultipart": {
        "type": "object",
        "required": [
          "audio"
        ],
        "properties": {
          "model": {
            "$ref": "#/components/schemas/MusicModel"
          },
          "prompt": {
            "type": "string",
            "maxLength": 5000,
            "description": "Mô tả bài hát, hoặc lời bài hát khi ở chế độ custom."
          },
          "instrumental": {
            "type": "boolean",
            "default": false,
            "description": "Không có lời hát. Ở custom mode, `prompt` (lời) khi đó không bắt buộc."
          },
          "style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Thẻ phong cách nhạc (custom mode), vd `pop, female vocal`."
          },
          "title": {
            "type": "string",
            "maxLength": 100,
            "description": "Tên bài (custom mode)."
          },
          "negative_style": {
            "type": "string",
            "maxLength": 1000,
            "description": "Phong cách cần tránh."
          },
          "duration_s": {
            "type": "integer",
            "minimum": 10,
            "maximum": 360,
            "description": "Cần chế độ custom và model v5.5/v6 (hoặc auto)."
          },
          "persona_id": {
            "type": "string",
            "description": "Persona tạo bằng `music.persona` (lấy `persona_id` trong kết quả) để dùng giọng/phong cách của nó."
          },
          "vocal_gender": {
            "type": "string",
            "enum": [
              "m",
              "f"
            ],
            "description": "Giọng mong muốn: `m` (nam) hoặc `f` (nữ)."
          },
          "style_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo `style`, 0..1."
          },
          "weirdness": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức thử nghiệm, lạ của kết quả, 0..1."
          },
          "audio_weight": {
            "type": "number",
            "minimum": 0,
            "maximum": 1,
            "description": "Mức bám theo audio nguồn (cover và các kind tải audio lên), 0..1."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "audio": {
            "type": "array",
            "description": "File audio (tối đa 20 MiB mỗi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 2
          }
        }
      },
      "MusicVocalRemovalJson": {
        "type": "object",
        "properties": {
          "clip_id": {
            "type": "string",
            "description": "Clip nguồn; phải do Wave tạo (400 `UNKNOWN_SOURCE_CLIP` nếu không). Id clip nằm trong `meta` của item kết quả."
          },
          "audio_url": {
            "type": "string",
            "format": "uri",
            "description": "URL http(s) của audio nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Hoặc gửi một part file `audio` thay cho trường này."
          },
          "type": {
            "type": "string",
            "default": "separate_vocal",
            "enum": [
              "separate_vocal",
              "split_stem",
              "split_stem_advanced"
            ],
            "description": "`separate_vocal`: tách lời và nhạc nền; `split_stem`: tách thành nhiều stem; `split_stem_advanced`: lấy một stem chọn bằng `stem_name`."
          },
          "stem_name": {
            "type": "string",
            "description": "Bắt buộc với `split_stem_advanced`, không dùng với type khác.",
            "enum": [
              "Vocals",
              "Backing Vocals",
              "Drums",
              "Bass",
              "Guitar",
              "Keyboard",
              "Percussion",
              "Strings",
              "Synth",
              "FX",
              "Brass",
              "Woodwinds"
            ]
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "MusicVocalRemovalMultipart": {
        "type": "object",
        "properties": {
          "clip_id": {
            "type": "string",
            "description": "Clip nguồn; phải do Wave tạo (400 `UNKNOWN_SOURCE_CLIP` nếu không). Id clip nằm trong `meta` của item kết quả."
          },
          "audio": {
            "type": "array",
            "description": "File audio (tối đa 20 MiB mỗi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 1
          },
          "type": {
            "type": "string",
            "default": "separate_vocal",
            "enum": [
              "separate_vocal",
              "split_stem",
              "split_stem_advanced"
            ],
            "description": "`separate_vocal`: tách lời và nhạc nền; `split_stem`: tách thành nhiều stem; `split_stem_advanced`: lấy một stem chọn bằng `stem_name`."
          },
          "stem_name": {
            "type": "string",
            "description": "Bắt buộc với `split_stem_advanced`, không dùng với type khác.",
            "enum": [
              "Vocals",
              "Backing Vocals",
              "Drums",
              "Bass",
              "Guitar",
              "Keyboard",
              "Percussion",
              "Strings",
              "Synth",
              "FX",
              "Brass",
              "Woodwinds"
            ]
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "MusicClaimCheckJson": {
        "type": "object",
        "required": [
          "audio_urls"
        ],
        "properties": {
          "audio_urls": {
            "type": "array",
            "description": "URL http(s) mà wave tải về (tối đa 20 MiB mỗi file). Tính chung với các part `audio`: tổng cộng 1..15 bài.",
            "items": {
              "type": "string",
              "format": "uri"
            },
            "maxItems": 15
          },
          "titles": {
            "type": "array",
            "description": "Tên bài theo thứ tự bài (các part `audio` multipart trước, rồi `audio_urls`); số phần tử bằng số bài. Chuỗi rỗng, hoặc không gửi danh sách, nghĩa là tên file bỏ phần mở rộng. Tên được trả lại trong kết quả và dùng để khớp claim theo tên khi khoảng thời gian bị claim không rơi vào bài nào.",
            "items": {
              "type": "string",
              "maxLength": 200
            },
            "maxItems": 15
          },
          "watch_minutes": {
            "type": "integer",
            "minimum": 10,
            "maximum": 120,
            "default": 60,
            "description": "Theo dõi claim bao lâu sau khi tải lên. Gộp nhiều bài theo dõi từ một giờ trở lên sẽ được cộng thêm tới 75 phút (20 ms mỗi giây video) nếu như vậy dài hơn."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "MusicClaimCheckMultipart": {
        "type": "object",
        "required": [
          "audio"
        ],
        "properties": {
          "audio": {
            "type": "array",
            "description": "File audio (tối đa 20 MiB mỗi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 15
          },
          "titles": {
            "type": "array",
            "description": "Tên bài theo thứ tự bài (các part `audio` multipart trước, rồi `audio_urls`); số phần tử bằng số bài. Chuỗi rỗng, hoặc không gửi danh sách, nghĩa là tên file bỏ phần mở rộng. Tên được trả lại trong kết quả và dùng để khớp claim theo tên khi khoảng thời gian bị claim không rơi vào bài nào.",
            "items": {
              "type": "string",
              "maxLength": 200
            },
            "maxItems": 15
          },
          "watch_minutes": {
            "type": "integer",
            "minimum": 10,
            "maximum": 120,
            "default": 60,
            "description": "Theo dõi claim bao lâu sau khi tải lên. Gộp nhiều bài theo dõi từ một giờ trở lên sẽ được cộng thêm tới 75 phút (20 ms mỗi giây video) nếu như vậy dài hơn."
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "ImageGenerateJson": {
        "type": "object",
        "properties": {
          "model": {
            "type": "string",
            "default": "auto",
            "description": "`auto`, `gpt-image-1`, `nano-banana-2-lite`, `nano-banana-2`, `nano-banana-pro`, `grok-imagine`, `grok-imagine-pro` (tiền tố `chatgpt/`, `flow/`, `grok/` được chấp nhận)."
          },
          "prompt": {
            "type": "string",
            "maxLength": 32000,
            "description": "Nội dung cần vẽ."
          },
          "aspect_ratio": {
            "type": "string",
            "description": "Tỉ lệ khung; tập giá trị theo provider (xem mô tả)."
          },
          "count": {
            "type": "integer",
            "minimum": 1,
            "maximum": 4,
            "default": 1,
            "description": "Số ảnh, 1..4."
          },
          "drop_unsupported": {
            "type": "boolean",
            "default": false,
            "description": "Bỏ các trường provider không hỗ trợ thay vì trả 400; trường bị bỏ được ghi trong `dropped`."
          },
          "seed": {
            "type": "integer",
            "minimum": 0,
            "description": "flow."
          },
          "references": {
            "type": "array",
            "description": "Ảnh tham chiếu (flow, tối đa 10 kể cả nguồn edit).",
            "items": {
              "$ref": "#/components/schemas/MediaRef"
            },
            "maxItems": 10
          },
          "negative_prompt": {
            "type": "string",
            "description": "Không provider ảnh nào hỗ trợ; cần drop_unsupported."
          },
          "resolution": {
            "type": "string",
            "description": "Chỉ cho video; bị từ chối trên ảnh trừ khi drop_unsupported."
          },
          "duration_s": {
            "type": "integer",
            "description": "Chỉ cho video."
          },
          "start_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`."
          },
          "end_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`."
          },
          "provider_options": {
            "type": "object",
            "description": "Theo provider; chỉ grok dùng: `{\"grok\":{\"nsfw\",\"watermark\",\"skip_upsampler\"}}`.",
            "properties": {
              "grok": {
                "$ref": "#/components/schemas/GrokOptions"
              }
            }
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          }
        }
      },
      "ImageGenerateMultipart": {
        "type": "object",
        "properties": {
          "model": {
            "type": "string",
            "default": "auto",
            "description": "`auto`, `gpt-image-1`, `nano-banana-2-lite`, `nano-banana-2`, `nano-banana-pro`, `grok-imagine`, `grok-imagine-pro` (tiền tố `chatgpt/`, `flow/`, `grok/` được chấp nhận)."
          },
          "prompt": {
            "type": "string",
            "maxLength": 32000,
            "description": "Nội dung cần vẽ."
          },
          "aspect_ratio": {
            "type": "string",
            "description": "Tỉ lệ khung; tập giá trị theo provider (xem mô tả)."
          },
          "count": {
            "type": "integer",
            "minimum": 1,
            "maximum": 4,
            "default": 1,
            "description": "Số ảnh, 1..4."
          },
          "drop_unsupported": {
            "type": "boolean",
            "default": false,
            "description": "Bỏ các trường provider không hỗ trợ thay vì trả 400; trường bị bỏ được ghi trong `dropped`."
          },
          "seed": {
            "type": "integer",
            "minimum": 0,
            "description": "flow."
          },
          "references": {
            "type": "array",
            "description": "Ảnh tham chiếu (flow, tối đa 10 kể cả nguồn edit).",
            "items": {
              "$ref": "#/components/schemas/MediaRef"
            },
            "maxItems": 10
          },
          "negative_prompt": {
            "type": "string",
            "description": "Không provider ảnh nào hỗ trợ; cần drop_unsupported."
          },
          "resolution": {
            "type": "string",
            "description": "Chỉ cho video; bị từ chối trên ảnh trừ khi drop_unsupported."
          },
          "duration_s": {
            "type": "integer",
            "description": "Chỉ cho video."
          },
          "start_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`."
          },
          "end_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`."
          },
          "provider_options": {
            "type": "object",
            "description": "Theo provider; chỉ grok dùng: `{\"grok\":{\"nsfw\",\"watermark\",\"skip_upsampler\"}}`.",
            "properties": {
              "grok": {
                "$ref": "#/components/schemas/GrokOptions"
              }
            }
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "reference": {
            "type": "array",
            "description": "Ảnh tham chiếu, mỗi part một file (tối đa 20 MiB mỗi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 10
          }
        }
      },
      "ImageEditJson": {
        "type": "object",
        "required": [
          "image_url"
        ],
        "properties": {
          "model": {
            "type": "string",
            "default": "auto",
            "description": "`auto`, `gpt-image-1`, `nano-banana-2-lite`, `nano-banana-2`, `nano-banana-pro`, `grok-imagine`, `grok-imagine-pro` (tiền tố `chatgpt/`, `flow/`, `grok/` được chấp nhận)."
          },
          "prompt": {
            "type": "string",
            "maxLength": 32000,
            "description": "Nội dung cần vẽ."
          },
          "aspect_ratio": {
            "type": "string",
            "description": "Tỉ lệ khung; tập giá trị theo provider (xem mô tả)."
          },
          "count": {
            "type": "integer",
            "minimum": 1,
            "maximum": 4,
            "default": 1,
            "description": "Số ảnh, 1..4."
          },
          "drop_unsupported": {
            "type": "boolean",
            "default": false,
            "description": "Bỏ các trường provider không hỗ trợ thay vì trả 400; trường bị bỏ được ghi trong `dropped`."
          },
          "seed": {
            "type": "integer",
            "minimum": 0,
            "description": "flow."
          },
          "references": {
            "type": "array",
            "description": "Ảnh tham chiếu (flow, tối đa 10 kể cả nguồn edit).",
            "items": {
              "$ref": "#/components/schemas/MediaRef"
            },
            "maxItems": 10
          },
          "negative_prompt": {
            "type": "string",
            "description": "Không provider ảnh nào hỗ trợ; cần drop_unsupported."
          },
          "resolution": {
            "type": "string",
            "description": "Chỉ cho video; bị từ chối trên ảnh trừ khi drop_unsupported."
          },
          "duration_s": {
            "type": "integer",
            "description": "Chỉ cho video."
          },
          "start_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`."
          },
          "end_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`."
          },
          "provider_options": {
            "type": "object",
            "description": "Theo provider; chỉ grok dùng: `{\"grok\":{\"nsfw\",\"watermark\",\"skip_upsampler\"}}`.",
            "properties": {
              "grok": {
                "$ref": "#/components/schemas/GrokOptions"
              }
            }
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "image_url": {
            "type": "string",
            "format": "uri",
            "description": "URL http(s) của ảnh nguồn; Wave tải về sau khi nhận job (tối đa 20 MiB). Không tải được thì job FAILED `SOURCE_FETCH_FAILED`."
          }
        }
      },
      "ImageEditMultipart": {
        "type": "object",
        "required": [
          "image"
        ],
        "properties": {
          "model": {
            "type": "string",
            "default": "auto",
            "description": "`auto`, `gpt-image-1`, `nano-banana-2-lite`, `nano-banana-2`, `nano-banana-pro`, `grok-imagine`, `grok-imagine-pro` (tiền tố `chatgpt/`, `flow/`, `grok/` được chấp nhận)."
          },
          "prompt": {
            "type": "string",
            "maxLength": 32000,
            "description": "Nội dung cần vẽ."
          },
          "aspect_ratio": {
            "type": "string",
            "description": "Tỉ lệ khung; tập giá trị theo provider (xem mô tả)."
          },
          "count": {
            "type": "integer",
            "minimum": 1,
            "maximum": 4,
            "default": 1,
            "description": "Số ảnh, 1..4."
          },
          "drop_unsupported": {
            "type": "boolean",
            "default": false,
            "description": "Bỏ các trường provider không hỗ trợ thay vì trả 400; trường bị bỏ được ghi trong `dropped`."
          },
          "seed": {
            "type": "integer",
            "minimum": 0,
            "description": "flow."
          },
          "references": {
            "type": "array",
            "description": "Ảnh tham chiếu (flow, tối đa 10 kể cả nguồn edit).",
            "items": {
              "$ref": "#/components/schemas/MediaRef"
            },
            "maxItems": 10
          },
          "negative_prompt": {
            "type": "string",
            "description": "Không provider ảnh nào hỗ trợ; cần drop_unsupported."
          },
          "resolution": {
            "type": "string",
            "description": "Chỉ cho video; bị từ chối trên ảnh trừ khi drop_unsupported."
          },
          "duration_s": {
            "type": "integer",
            "description": "Chỉ cho video."
          },
          "start_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`."
          },
          "end_image": {
            "$ref": "#/components/schemas/MediaRef",
            "description": "Chỉ dành cho video; ảnh bị từ chối trừ khi `drop_unsupported`."
          },
          "provider_options": {
            "type": "object",
            "description": "Theo provider; chỉ grok dùng: `{\"grok\":{\"nsfw\",\"watermark\",\"skip_upsampler\"}}`.",
            "properties": {
              "grok": {
                "$ref": "#/components/schemas/GrokOptions"
              }
            }
          },
          "callback_url": {
            "$ref": "#/components/schemas/CallbackURL"
          },
          "image": {
            "type": "string",
            "format": "binary",
            "description": "File ảnh cần sửa (tối đa 20 MiB)."
          },
          "reference": {
            "type": "array",
            "description": "Ảnh tham chiếu, mỗi part một file (tối đa 20 MiB mỗi file).",
            "items": {
              "type": "string",
              "format": "binary"
            },
            "maxItems": 10
          }
        }
      }
    }
  }
}
