=== useapi.net — universal note === Generated: 2026-05-20 04:11 UTC Authentication (applies to every useapi.net API). Header: Authorization: Bearer user:- Use the COMPLETE token, including the `user:` prefix and the alphanumeric suffix. Do not truncate. Do not URL-encode. A single token authorizes every API under the user's subscription. Service-specific patterns. Identifier names (jobid / taskId / musicId / etc.), job lifecycle, response shapes, webhook semantics, and synchronous-vs-async behavior vary PER API. Use ONLY the service-specific documentation below to determine the correct request body, response shape, polling endpoint, and status values for THIS API. Do not assume conventions from another useapi.net API carry over. For cross-service context (e.g. which APIs expose the same underlying model, billing tiers, model availability matrix), see https://useapi.net/llms.txt === END universal note === === URL: https://useapi.net/docs/start-here/setup-mureka === Document URL: https://useapi.net/docs/start-here/setup-mureka # Setup Mureka December 2, 2024 (April 13, 2026) > Looking for the [legacy setup method](/docs/start-here/setup-mureka-legacy)? ## Table of contents Approximately 10 minutes to complete setup steps. --- > This is the setup guide for [Mureka API](/docs/api-mureka-v1). A [Mureka AI](https://www.mureka.ai) account and a [useapi.net subscription](/docs/subscription) are required for the API to work. ### Automated setup (recommended) Use our guided browser setup to configure your account automatically — no DevTools or cookie copying needed. Enter your API token, log in with Google in the remote browser, and your account is ready. [Open automated setup](/assets/setup-browser/mureka.html){: .btn .btn-primary .fs-4 } Prefer manual setup? Continue with the steps below. --- [Mureka AI](https://www.mureka.ai), a **music generation** service from Chinese tech giant Kunlun Tech featuring proprietary SkyMusic 2.0 model and positioned to compete with [Suno](https://www.suno.com) and [Udio](https://www.udio.com). Mureka AI creates unique songs based on user-provided lyrics or description (AI-generated lyrics), selected musical styles, and references to specific vocals and songs, including those uploaded by the user. ### Create Gmail account We *strongly recommend* creating a separate new Gmail account designated to be used with the API. When creating the account make sure to turn on [2-Step Verification](https://support.google.com/accounts/answer/185839) authorization using [Google Authenticator](https://support.google.com/accounts/answer/1066447). ### Clear all browser cookies Launch Chromium-based web-browser of your choice (eg [Opera](https://www.opera.com/), [Brave](https://brave.com/), [Chromium](https://www.chromium.org/) or [Chrome](https://www.google.com/chrome/)) and clear **all** cookies. It is very important that you start absolutely fresh and obtain fresh Google cookies. We suggest using [Opera](https://www.opera.com/) with `VPN` option turned on and VPN region set to Americas. 1. Open a new browser tab 2. Click on the address bar and type `opera://settings/clearBrowserData` (or `chrome://settings/clearBrowserData` for Chrome) `1` 3. Press `Enter` to navigate to the settings page 4. Set `Time range` to `All time` 5. Check `Cookies and other site data` `2` 6. Click `Delete data` `3` ![](/assets/images/mureka_setup_1.jpg) ### Navigate to Mureka and login with Google * Navigate to [https://www.mureka.ai](https://www.mureka.ai) `1` * Click on `Try free now` button `2` ![](/assets/images/mureka_setup_2.jpg) * Click `Continue with Google` button ![](/assets/images/mureka_setup_3.jpg) * Enter your Google email created earlier ![](/assets/images/mureka_setup_4.jpg) * Enter 2-Step Verification code `1` * Make sure to check `Don't ask again on this device` `2` - this is **very important** * Click `Next` `3` ![](/assets/images/mureka_setup_5.jpg) Once successfully logged in you should see your user profile in the sidebar ![](/assets/images/mureka_setup_6.jpg) ### Navigate to Google Account * Click on the address bar * Type or paste `myaccount.google.com` `1` * Press `Enter` to navigate ![](/assets/images/mureka_setup_7.jpg) ### Copy `__Secure-3PSID` cookie Now we need to open Developer Tools to copy the cookie: 1. Press `F12` key on your keyboard (or `Control+Shift+I` on Windows, `Command+Option+I` on Mac) 2. A panel will open on the right side or bottom of your browser - this is Developer Tools 3. Look at the top of this panel and find the word `Application` - click on it `1` 4. On the left side of the panel, find `Cookies` - click the small arrow next to it to expand 5. Click on `https://accounts.google.com/` `2` 6. A list of cookies will appear on the right side 7. Scroll through the list and find the cookie named `__Secure-3PSID` 8. Click once on that row to select it (the row will become highlighted) `3` 9. Right-click on the highlighted row 10. A menu will appear - click on `Copy` `4` ![](/assets/images/mureka_setup_8.jpg) Your copied cookie will look similar to this (tab-separated values): ``` __Secure-3PSID g.a0...secured...076 .google.com / 2027-02-23T04:38:16.033Z 167 ✓ ✓ None High ``` We redacted values in the screenshot for security, your actual cookie value will be a long string (~170 characters). ### Verify and add account Use the form below to verify your cookie and add your Mureka account. Paste the copied cookie into the `sessionCookie` field. **Option 1: Paste the full tab-separated cookie line** (as copied from DevTools): ``` __Secure-3PSID g.a0...secured...076 .google.com / 2027-02-23T04:38:16.033Z 167 ✓ ✓ None High ``` **Option 2: Paste minimal JSON format** (if you prefer): ```json {"value": "g.a0...secured...076", "expires": "2027-02-23T04:38:16.033Z"} ``` Select **Add Account** to complete setup, or **Verify** to test your cookie first. You should receive response `200` if successful. You can also use [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts) directly. ⚠️ Once your account is added, make sure to [clear all browser cookies](#clear-all-browser-cookies) to ensure that this session will no longer be active in the browser and fully managed by API.
=== URL: https://useapi.net/docs/api-mureka-v1 === Document URL: https://useapi.net/docs/api-mureka-v1 # Mureka API v1 December 2, 2024 (April 4, 2026) This is [experimental](/docs/legal) API for for the [Mureka AI](https://www.mureka.ai), a music generation service from Chinese tech giant Kunlun Tech featuring proprietary SkyMusic 2.0 model and positioned to compete with [Suno](https://www.suno.com) and [Udio](https://www.udio.com). Mureka AI creates unique songs based on user-provided lyrics or description (AI-generated lyrics), selected musical styles, and references to specific vocals and songs, including those uploaded by the user. Our API also provides comprehensive **TTS/speech generation** capabilities with custom voice cloning from audio samples and multi-turn conversations using multiple voices. Our API supports **all** functionality of [Mureka AI](https://www.mureka.ai), including Pro subscription features such as the ability to upload and use custom soundtracks for reference, and to upload and use melodies (motifs). Mureka supports up to **10 concurrent generations** per account in **near real-time** fashion, with an average generation time of 45 seconds (each generation produces two songs). Generated songs can be up to 5 minutes long depending on your lyrics. Currently, two [web subscription](https://www.mureka.ai/subscribe) plans are supported: | Plan | Price | Songs | Speech | |------|-------|-------|--------| | **Pro** | $9/month | 500 songs | 250 min | | **Premier** | $27/month | 2,000 songs | 1,000 min | Cost breakdown: | Plan | Cost/Song | Cost/Speech Min | |------|-----------|-----------------| | **Pro** | 1.8¢ | 3.6¢ | | **Premier** | 1.35¢ | 2.7¢ | Supported models: `V9` (default), `V8`, `O2`, `V7.6`, `V7.5` * Song/speech allowances are **shared** (songs OR speech minutes) * Downloading instrumentals and stems is **free** * Lyrics generation is **free** Credit top-ups available at $48 for 1600 credits. Compare the above with the official API, which starts at [$1000/m with 5 concurrent generations](https://platform.mureka.ai/pricing) at a rate of `3¢/song`. The official API also charges for lyrics generation and stems download. [Setup Mureka](/docs/start-here/setup-mureka) [Postman collection](https://www.postman.com/useapinet/useapi-net/collection) (April 4, 2026) [LLM-friendly API spec](https://useapi.net/assets/aibot/api-mureka-v1.txt) Feed this to your LLM to build integrations Examples: * [Mureka V9](/blog/260404) * [Mureka V8](/blog/260127m) * [Mureka O2 & V7.6](/blog/251128) * [Mureka TTS/Speech](/blog/250818) Articles: * [Mureka API Music Samples](/docs/articles/mureka-music-samples) Developer Community: * Discord Server * Telegram Channel * r/murekaai_api === URL: https://useapi.net/docs/api-mureka-v1/del-mureka-accounts-account === Document URL: https://useapi.net/docs/api-mureka-v1/del-mureka-accounts-account ## Delete Mureka API account December 2, 2024 --- > **https://api.useapi.net/v1/mureka/accounts/`account`** The `account` value should correspond to an account configured previously via a [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts) request. ##### Request Headers ``` yaml Authorization: Bearer {API token} ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Responses **204** **204 No Content** **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **404** **404 Not Found** ##### Model ```typescript { // TypeScript, all fields are optional error: string, errorDetails: string, code: number } ``` ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X DELETE https://api.useapi.net/v1/mureka/accounts/ ``` **JavaScript** ``` javascript const account = "Previously configured account"; const apiUrl = `https://api.useapi.net/v1/mureka/accounts/${channnel}`; const token = "API token"; const data = { method: 'DELETE', headers: { 'Authorization': `Bearer ${token}`, 'Content-Type': 'application/json' } }; const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests account = "Previously configured account" apiUrl = f"https://api.useapi.net/v1/mureka/accounts/{account}" token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.delete(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/del-mureka-files-vocal === Document URL: https://useapi.net/docs/api-mureka-v1/del-mureka-files-vocal ## Delete vocal January 15, 2025 --- Delete vocal which was uploaded using [POST files/vocal](/docs/api-mureka-v1/post-mureka-files-vocal). > **https://api.useapi.net/v1/mureka/files/vocal/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `id` is **required**, to see full list of uploaded vocals use [GET music/vocals/?mine=true](/docs/api-mureka-v1/get-mureka-music-vocals). ##### Responses **200** **200 OK** **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X DELETE https://api.useapi.net/v1/mureka/files/vocal/?account=&id= ``` **JavaScript** ``` javascript const account = 123456789; const id = 98765432; const apiUrl = `https://api.useapi.net/v1/mureka/files/vocal/?account=${account}&id=${id}`; const token = "API token"; const data = { method: 'DELETE', headers: { 'Authorization': `Bearer ${token}`, 'Content-Type': 'application/json' } }; const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests account = 123456789 id = 98765432 apiUrl = f"https://api.useapi.net/v1/mureka/files/vocal/?account={account}&id={id}" token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.delete(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/del-mureka-files === Document URL: https://useapi.net/docs/api-mureka-v1/del-mureka-files ## Delete track December 13, 2024 --- Delete track which was uploaded using [POST /files](/docs/api-mureka-v1/post-mureka-files). > **https://api.useapi.net/v1/mureka/files/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `id` is **required**, to see full list of uploaded tracks use [GET /files](/docs/api-mureka-v1/get-mureka-files). ##### Responses **200** **200 OK** **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X DELETE https://api.useapi.net/v1/mureka/files/?account=&id= ``` **JavaScript** ``` javascript const account = 123456789; const id = 98765432; const apiUrl = `https://api.useapi.net/v1/mureka/files/?account=${account}&id=${id}`; const token = "API token"; const data = { method: 'DELETE', headers: { 'Authorization': `Bearer ${token}`, 'Content-Type': 'application/json' } }; const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests account = 123456789 id = 98765432 apiUrl = f"https://api.useapi.net/v1/mureka/files/?account={account}&id={id}" token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.delete(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/del-mureka-music-song_id === Document URL: https://useapi.net/docs/api-mureka-v1/del-mureka-music-song_id ## Delete song December 2, 2024 --- > **https://api.useapi.net/v1/mureka/music/`song_id`** The `song_id` value returned by one of the following endpoints: * [GET /music](/docs/api-mureka-v1/get-mureka-music) * [POST /music/create](/docs/api-mureka-v1/post-mureka-music-create) * [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced) * [POST /music/create-instrumental](/docs/api-mureka-v1/post-mureka-music-create-instrumental) ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Responses **200** **200 OK** ```json {} ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript {} ``` ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X DELETE https://api.useapi.net/v1/mureka/accounts/ ``` **JavaScript** ``` javascript const song_id = 123456789; const apiUrl = `https://api.useapi.net/v1/mureka/accounts/${song_id}`; const token = "API token"; const data = { method: 'DELETE', headers: { 'Authorization': `Bearer ${token}`, 'Content-Type': 'application/json' } }; const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests song_id = 123456789 apiUrl = f"https://api.useapi.net/v1/mureka/accounts/{song_id}" token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.delete(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/del-mureka-speech-voice === Document URL: https://useapi.net/docs/api-mureka-v1/del-mureka-speech-voice ## Delete speech voice August 18, 2025 --- This endpoint permanently deletes a custom cloned voice from your Mureka account. Once deleted, the voice cannot be recovered and can no longer be used for speech generation. Use this to clean up unwanted voice clones or manage your voice library. > **https://api.useapi.net/v1/mureka/speech/voice?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `voice_id` is **required**. The ID of the voice to delete. Get voice IDs from [GET /speech/voices](/docs/api-mureka-v1/get-mureka-speech-voices). ##### Responses **200** **200 OK** ```json {} ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Examples **Curl** ``` bash curl -X DELETE "https://api.useapi.net/v1/mureka/speech/voice?voice_id=12345678901234" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const voiceId = "Voice ID to delete"; const apiUrl = `https://api.useapi.net/v1/mureka/speech/voice?voice_id=${voiceId}`; const response = await fetch(apiUrl, { method: "DELETE", headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" voice_id = "Voice ID to delete" apiUrl = f"https://api.useapi.net/v1/mureka/speech/voice?voice_id={voice_id}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.delete(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/del-mureka-speech === Document URL: https://useapi.net/docs/api-mureka-v1/del-mureka-speech ## Delete speech August 18, 2025 --- This endpoint permanently deletes a specific speech recording from your Mureka account. Once deleted, the speech audio file and metadata cannot be recovered. Use this to clean up unwanted recordings or manage storage in your account. > **https://api.useapi.net/v1/mureka/speech/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `id` is **required**. The ID of the speech to delete. Get speech IDs from [GET /speech](/docs/api-mureka-v1/get-mureka-speech). ##### Responses **200** **200 OK** ```json {} ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Examples **Curl** ``` bash curl -X DELETE "https://api.useapi.net/v1/mureka/speech/?id=23456789012345" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const speechId = "Speech ID to delete"; const apiUrl = `https://api.useapi.net/v1/mureka/speech/?id=${speechId}`; const response = await fetch(apiUrl, { method: "DELETE", headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" speech_id = "Speech ID to delete" apiUrl = f"https://api.useapi.net/v1/mureka/speech/?id={speech_id}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.delete(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-accounts-account === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-accounts-account ## Retrieve Mureka API account configuration for `account` December 2, 2024 (January 20, 2026) --- [Setup Mureka](/docs/start-here/setup-mureka) > **https://api.useapi.net/v1/mureka/accounts/`account`** The `account` value should correspond to an account configured previously via a [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts) request. ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Responses **200** **200 OK** ```json { "account": "123456789", "token": "abc…secured…xyz", "updated": 1724514995, "updatedUTC": "2024-10-24T15:56:35.000Z", "tokenIssuedDaysAgo": 30, "hasAutoRefresh": true, "email": "user@gmail.com", "sessionCookie": { "name": "__Secure-3PSID", "value": "g.a000abc…secured…12345", "domain": ".google.com", "path": "/", "expires": "2026-02-15T12:00:00.000Z", "httpOnly": true, "secure": true, "sameSite": "None", "added": "2026-01-15T10:30:00.000Z" } } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **404** **404 Not Found** Configuration not found. To create configuration use [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional account: string token: string updated: number updatedUTC: string tokenIssuedDaysAgo: number hasAutoRefresh: boolean email?: string sessionCookie?: { name: string value: string domain: string path: string expires: string httpOnly: boolean secure: boolean sameSite: string added?: string } error?: string } ``` ##### Examples **Curl** ``` bash curl https://api.useapi.net/v1/mureka/accounts/ \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const account = "Previously configured account"; const apiUrl = `https://api.useapi.net/v1/mureka/accounts/${account}`; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" account = "Previously configured account" apiUrl = f"https://api.useapi.net/v1/mureka/accounts/{account}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-accounts === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-accounts ## Retrieve Mureka API accounts configuration December 2, 2024 (January 20, 2026) --- This endpoint retrieves the complete list of configured API accounts for Mureka. [Setup Mureka](/docs/start-here/setup-mureka) > **https://api.useapi.net/v1/mureka/accounts** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Responses **200** **200 OK** ```json { "123456789": { "account": "123456789", "token": "abc…secured…xyz", "updated": 1724514995, "updatedUTC": "2024-10-24T15:56:35.000Z", "tokenIssuedDaysAgo": 29, "hasAutoRefresh": true, "email": "user@gmail.com", "sessionCookie": { "name": "__Secure-3PSID", "value": "g.a000abc…secured…12345", "domain": ".google.com", "path": "/", "expires": "2026-02-15T12:00:00.000Z", "httpOnly": true, "secure": true, "sameSite": "None", "added": "2026-01-15T10:30:00.000Z" } }, "987654321": { "account": "987654321", "token": "def…secured…uvw", "updated": 1724514995, "updatedUTC": "2024-10-24T15:56:35.000Z", "tokenIssuedDaysAgo": 1, "hasAutoRefresh": false, "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required" } } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **404** **404 Not Found** Configuration not found. To create configuration use [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional [account: string]: { account: string token: string updated: number updatedUTC: string tokenIssuedDaysAgo: number hasAutoRefresh: boolean email?: string sessionCookie?: { name: string value: string domain: string path: string expires: string httpOnly: boolean secure: boolean sameSite: string added?: string } error?: string } } ``` ##### Examples **Curl** ``` bash curl https://api.useapi.net/v1/mureka/accounts \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const apiUrl = "https://api.useapi.net/v1/mureka/accounts"; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" apiUrl = "https://api.useapi.net/v1/mureka/accounts" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-files-youtube === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-files-youtube ## Retrieve soundtrack from YouTube url December 13, 2024 --- This endpoint will return a link to the YouTube video soundtrack. You can download it, adjust if needed, and upload it to your track collection using [POST /files](/docs/api-mureka-v1/post-mureka-files). > **https://api.useapi.net/v1/mureka/files/youtube/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `url` is **required**. Provide the YouTube url link for which you want to retrieve the soundtrack. ##### Responses **200** **200 OK** ```json { "name": "", "cos_url": "https://...mp3", "duration": 21000 } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional name: string cos_url: string duration: number } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/files/youtube/?account=account&url=" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const account = "Previously configured account"; const url = "YouTube video url"; const apiUrl = `https://api.useapi.net/v1/mureka/files/youtube/?account=${account}&url=${url}`; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" account = "Previously configured account" url = "YouTube video url" apiUrl = f"https://api.useapi.net/v1/mureka/files/youtube/?account={account}&url={url}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-files === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-files ## Retrieve your reference tracks December 13, 2024 --- Retrieve full list of track uploaded using [POST /files](/docs/api-mureka-v1/post-mureka-files). Keep in mind that all uploaded files will be visible to all users of Mureka.ai website. Use `id` value to reference a track when using the parameter `ref_id` of [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced). > **https://api.useapi.net/v1/mureka/files/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `last_id` is optional. Use it to retrieve the next page of data. To do so, set its value to the `last_id` returned in the previous response when the `more` field in that response is `true`. ##### Responses **200** **200 OK** ```json { "list": [ { "id": 1122334455, "url": "https://.mp3", "duration_milliseconds": 30000, "mood": "relaxed", "title": "", "genre": "afrobeat", "username": "" }, { "id": 66778899, "url": "https://.mp3", "duration_milliseconds": 30000, "mood": "restless", "title": "", "genre": "rock", "username": "" } ], "last_id": 77665544332211, "more": true } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional list: { id: number url: string duration_milliseconds: number mood: string title: string genre: string username: string }[] last_id: number more: boolean } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/files/?account=account" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const account = "Previously configured account"; const apiUrl = `https://api.useapi.net/v1/mureka/files/?account=${account}`; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" account = "Previously configured account" apiUrl = f"https://api.useapi.net/v1/mureka/files/?account={account}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-jobs-jobid === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-jobs-jobid ## Retrieve Job Status January 21, 2026 --- Retrieve the status and details of a specific music or speech generation job by its job ID. This endpoint is particularly useful when using `async` mode for music or speech generation, or when tracking job progress via webhooks using the `replyUrl` parameter. Job IDs are returned from: * [POST /music/create](/docs/api-mureka-v1/post-mureka-music-create) * [POST /music/create-instrumental](/docs/api-mureka-v1/post-mureka-music-create-instrumental) * [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced) * [POST /music/extend](/docs/api-mureka-v1/post-mureka-music-extend) * [POST /music/regenerate](/docs/api-mureka-v1/post-mureka-music-regenerate) * [POST /speech](/docs/api-mureka-v1/post-mureka-speech) Jobs are retained for 7 days after creation. Jobs older than 7 days will return a 404 error. To get a summary of all running jobs, use [GET /jobs](/docs/api-mureka-v1/get-mureka-jobs). > **https://api.useapi.net/v1/mureka/jobs/`jobid`** ##### Request Headers ``` yaml Authorization: Bearer {API token} ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Path Parameters - `jobid` is **required**, the unique job identifier. ##### Responses **200** **200 OK** Returns the job record with current status and details. **Music job (completed):** ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "verb": "music/create", "jobType": "music", "status": "completed", "created": "2026-01-20T12:34:56.789Z", "updated": "2026-01-20T12:35:42.123Z", "request": { "account": "12345678901234", "prompt": "Upbeat electronic dance track", "model": "V7.6", "async": true, "replyUrl": "https://your-domain.com/webhook", "replyRef": "my-custom-ref-123" }, "response": { "feed_id": 11223344, "state": 3, "songs": [ { "song_id": "user:777-mureka:123456789-song:33445566", "title": "Upbeat Dance", "version": "1", "duration_milliseconds": 234567, "mp3_url": "https://...mp3", "cover": "https://...png" }, { "song_id": "user:777-mureka:123456789-song:33445567", "title": "Upbeat Dance", "version": "2", "duration_milliseconds": 234890, "mp3_url": "https://...mp3", "cover": "https://...png" } ] } } ``` **Speech job (completed):** ```json { "jobid": "j0121061456745673364t-u777-a12345678901234-bot:mureka", "verb": "speech", "jobType": "tts", "status": "completed", "created": "2026-01-20T12:40:00.000Z", "updated": "2026-01-20T12:40:25.000Z", "request": { "account": "12345678901234", "text": "Hello, this is a test speech.", "voice_id": 12345, "async": true }, "response": { "title": "Hello, this is a test speech.", "mp3_url": "https://...mp3", "duration_milliseconds": 5000, "state": 3 } } ``` **Job still processing:** ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "verb": "music/create", "jobType": "music", "status": "created", "created": "2026-01-20T12:34:56.789Z", "request": { "account": "12345678901234", "prompt": "Upbeat electronic dance track", "async": true } } ``` **Job failed:** ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "verb": "music/create", "jobType": "music", "status": "failed", "created": "2026-01-20T12:34:56.789Z", "updated": "2026-01-20T12:35:10.000Z", "request": { "account": "12345678901234", "prompt": "Test prompt", "async": true }, "error": "Content policy violation", "code": 400 } ``` **400** **400 Bad Request** Invalid job ID format. ```json { "error": "Invalid job ID: Missing required component" } ``` **401** **401 Unauthorized** Invalid API token. ```json { "error": "Unauthorized", "code": 401 } ``` **403** **403 Forbidden** Job belongs to a different user. ```json { "error": "Unauthorized access to job" } ``` **404** **404 Not Found** Job not found or has expired (jobs are retained for 7 days). ```json { "error": "Job not found" } ``` ##### Model **Music Job** Music generation job structure. ```typescript { jobid: string // Unique job identifier verb: 'music/create' | 'music/create-instrumental' | 'music/create-advanced' | 'music/regenerate' | 'music/extend' jobType: 'music' // Job type status: 'created' | 'completed' | 'failed' created: string // ISO 8601 creation timestamp updated?: string // ISO 8601 last update timestamp request: { account?: string // Mureka account ID prompt?: string // Text prompt (for create endpoints) title?: string // Song title lyrics?: string // Lyrics (for create-advanced, extend) song_id?: string // Source song ID (for extend, regenerate) start_milliseconds?: number // Start position (for regenerate) model?: string // AI model used instrumental_model?: string // Instrumental model (for create-instrumental) ref_id?: string // Reference track ID vocal_id?: string // Vocal library ID motif_id?: string // Motif ID mood?: string // Mood tag genre?: string // Genre tag vocal_gender?: string // Vocal gender (male, female) async?: boolean // Fire-and-forget mode replyUrl?: string // Webhook URL for callbacks replyRef?: string // Custom reference for callbacks } response?: { // Present when completed feed_id: number state: number songs: Array<{ song_id: string title: string version: string duration_milliseconds: number generate_at: number genres: string[] moods: string[] mp3_url: string share_key: string cover: string share_link: string }> } error?: string // Error message (if failed) errorDetails?: string // Additional error details code?: number // HTTP status code (if failed) } ``` **Speech Job** Speech generation job structure. ```typescript { jobid: string // Unique job identifier verb: 'speech' // Job verb jobType: 'tts' // Job type status: 'created' | 'completed' | 'failed' created: string // ISO 8601 creation timestamp updated?: string // ISO 8601 last update timestamp request: { account?: string // Mureka account ID title?: string // Speech title text?: string // Text to convert to speech voice_id?: number // Voice ID conversation?: Array<{voice_id: number, text: string}> // Multi-speaker conversation async?: boolean // Fire-and-forget mode replyUrl?: string // Webhook URL for callbacks replyRef?: string // Custom reference for callbacks } response?: { // Present when completed title: string preview: string cover: string mp3_url: string id: number duration_milliseconds: number audio_quality: number state: number } error?: string // Error message (if failed) errorDetails?: string // Additional error details code?: number // HTTP status code (if failed) } ``` ##### Examples **Curl** ```bash # Get job status curl "https://api.useapi.net/v1/mureka/jobs/j0121061432017475905m-u777-a12345678901234-bot:mureka" \ -H "Authorization: Bearer {API token}" # Poll for completion (check every 5 seconds) while true; do STATUS=$(curl -s "https://api.useapi.net/v1/mureka/jobs/j0121061432017475905m-u777-a12345678901234-bot:mureka" \ -H "Authorization: Bearer {API token}" | jq -r '.status') echo "Status: $STATUS" if [[ "$STATUS" == "completed" || "$STATUS" == "failed" ]]; then break fi sleep 5 done ``` **JavaScript** ```javascript const token = "API token"; const jobid = "j0121061432017475905m-u777-a12345678901234-bot:mureka"; // Get job status async function getJobStatus(jobid) { const response = await fetch(`https://api.useapi.net/v1/mureka/jobs/${jobid}`, { headers: { "Authorization": `Bearer ${token}` } }); if (!response.ok) { throw new Error(`HTTP ${response.status}: ${await response.text()}`); } return await response.json(); } // Poll until completion async function waitForCompletion(jobid, intervalMs = 5000) { while (true) { const job = await getJobStatus(jobid); console.log(`Status: ${job.status}`); if (job.status === "completed") { console.log("Job completed!", job.response); return job; } if (job.status === "failed") { console.error("Job failed:", job.error); throw new Error(job.error); } await new Promise(resolve => setTimeout(resolve, intervalMs)); } } // Usage const job = await waitForCompletion(jobid); // Access song URLs (for music jobs) if (job.jobType === "music" && job.response?.songs) { job.response.songs.forEach((song, i) => { console.log(`Song ${i + 1}: ${song.mp3_url}`); }); } // Access audio URL (for speech jobs) if (job.jobType === "tts" && job.response?.mp3_url) { console.log(`Speech audio: ${job.response.mp3_url}`); } ``` **Python** ```python import requests import time token = "API token" jobid = "j0121061432017475905m-u777-a12345678901234-bot:mureka" # Get job status def get_job_status(jobid: str) -> dict: response = requests.get( f"https://api.useapi.net/v1/mureka/jobs/{jobid}", headers={"Authorization": f"Bearer {token}"} ) response.raise_for_status() return response.json() # Poll until completion def wait_for_completion(jobid: str, interval_sec: int = 5) -> dict: while True: job = get_job_status(jobid) print(f"Status: {job['status']}") if job["status"] == "completed": print("Job completed!", job["response"]) return job if job["status"] == "failed": raise Exception(f"Job failed: {job.get('error')}") time.sleep(interval_sec) # Usage job = wait_for_completion(jobid) # Access song URLs (for music jobs) if job["jobType"] == "music" and job.get("response", {}).get("songs"): for i, song in enumerate(job["response"]["songs"]): print(f"Song {i + 1}: {song['mp3_url']}") # Access audio URL (for speech jobs) if job["jobType"] == "tts" and job.get("response", {}).get("mp3_url"): print(f"Speech audio: {job['response']['mp3_url']}") ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-jobs === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-jobs ## List Running Jobs January 21, 2026 --- Retrieve a summary of all currently running jobs for your user account. This endpoint is useful for monitoring active music and speech generation jobs across all your configured Mureka accounts. Jobs are retained for 7 days after creation. Running jobs are tracked separately and show real-time elapsed time. > **https://api.useapi.net/v1/mureka/jobs** ##### Request Headers ``` yaml Authorization: Bearer {API token} ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Responses **200** **200 OK** Returns summary of running jobs grouped by account. ```json { "total": 3, "music": 2, "tts": 1, "accounts": { "12345678901234": { "total": 3, "music": 2, "tts": 1, "jobs": [ { "jobid": "j0121061456745673364t-u777-a12345678901234-bot:mureka", "verb": "speech", "elapsed": "00:00" }, { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "verb": "music/create", "elapsed": "00:24" }, { "jobid": "j0121061447693272611m-u777-a12345678901234-bot:mureka", "verb": "music/create-advanced", "elapsed": "00:09" } ] } }, "availableAccounts": [ "98765432109876", "12345678901234" ] } ``` **401** **401 Unauthorized** Invalid API token. ```json { "error": "Unauthorized", "code": 401 } ``` ##### Model ```typescript { total: number // Total number of running jobs music: number // Number of music generation jobs tts: number // Number of speech (TTS) jobs accounts: { [accountId: string]: { total: number // Jobs for this account music: number // Music jobs for this account tts: number // TTS jobs for this account jobs: Array<{ jobid: string // Unique job identifier verb: 'music/create' | 'music/create-instrumental' | 'music/create-advanced' | 'music/regenerate' | 'music/extend' | 'speech' elapsed: string // Human-readable elapsed time (e.g., "45s", "1m 23s") }> } } availableAccounts: string[] // List of configured account IDs } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/jobs" \ -H "Authorization: Bearer {API token}" ``` **JavaScript** ``` javascript const token = "API token"; const apiUrl = "https://api.useapi.net/v1/mureka/jobs"; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}` } }); const result = await response.json(); console.log("Running jobs:", result.total); console.log("Music jobs:", result.music); console.log("TTS jobs:", result.tts); // Check jobs per account for (const [accountId, data] of Object.entries(result.accounts)) { console.log(`Account ${accountId}: ${data.total} jobs`); data.jobs.forEach(job => { console.log(` - ${job.jobid} (${job.verb}) running for ${job.elapsed}`); }); } ``` **Python** ``` python import requests token = "API token" api_url = "https://api.useapi.net/v1/mureka/jobs" headers = { "Authorization": f"Bearer {token}" } response = requests.get(api_url, headers=headers) result = response.json() print(f"Running jobs: {result['total']}") print(f"Music jobs: {result['music']}") print(f"TTS jobs: {result['tts']}") # Check jobs per account for account_id, data in result['accounts'].items(): print(f"Account {account_id}: {data['total']} jobs") for job in data['jobs']: print(f" - {job['jobid']} ({job['verb']}) running for {job['elapsed']}") ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-music-moods-and-genres === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-music-moods-and-genres ## Retrieve a list of supported Genres, Moods and Vocals December 2, 2024 --- > **https://api.useapi.net/v1/mureka/music/moods-and-genres/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. ##### Responses **200** **200 OK** ```json { "genres": [ { "tag": "pop", "cover": "cos-prod/res/image/Pop@4x.png" }, { "tag": "", "cover": "" }, { "tag": "", "cover": "" } ], "moods": [ { "tag": "relaxed" }, { "tag": "" }, { "tag": "" } ], "vocals": [ { "tag": "female vocal" }, { "tag": "male vocal" } ] } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional genres: { tag: string, cover?: string }[] moods: { tag: string }[] vocals: { tag: string }[] } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/music/moods-and-genres/?account=account" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const account = "Previously configured account"; const apiUrl = `https://api.useapi.net/v1/mureka/music/moods-and-genres/?account=${account}`; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" account = "Previously configured account" apiUrl = f"https://api.useapi.net/v1/mureka/music/moods-and-genres/?account={account}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-music-refs === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-music-refs ## Retrieve a list of reference songs December 2, 2024 --- > **https://api.useapi.net/v1/mureka/music/refs/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `mood` is optional. Filter songs by mood, to retrieve list supported moods use [GET music/moods-and-genres](/docs/api-mureka-v1/get-mureka-music-moods-and-genres). - `genre` is optional. Filter songs by genre, to retrieve list supported genres use [GET music/moods-and-genres](/docs/api-mureka-v1/get-mureka-music-moods-and-genres). - `last_id` is optional. Use it to retrieve the next page of data. To do so, set its value to the `last_id` returned in the previous response when the `more` field in that response is `true`. ##### Responses **200** **200 OK** ```json { "list": [ { "id": 1122334455, "url": "https://.mp3", "duration_milliseconds": 30000, "mood": "relaxed", "title": "", "genre": "afrobeat", "username": "" }, { "id": 66778899, "url": "https://.mp3", "duration_milliseconds": 30000, "mood": "restless", "title": "", "genre": "rock", "username": "" } ], "last_id": 77665544332211, "more": true } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional list: { id: number url: string duration_milliseconds: number mood: string title: string genre: string username: string }[] last_id: number more: boolean } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/music/refs/?account=account" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const account = "Previously configured account"; const apiUrl = `https://api.useapi.net/v1/mureka/music/refs/?account=${account}`; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" account = "Previously configured account" apiUrl = f"https://api.useapi.net/v1/mureka/music/refs/?account={account}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-music-song_id === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-music-song_id ## Retrieve generated song lyrics and other details December 2, 2024 (March 31, 2025) --- > **https://api.useapi.net/v1/mureka/music/`song_id`** The `song_id` value returned by one of the following endpoints: * [GET /music](/docs/api-mureka-v1/get-mureka-music) * [POST /music/create](/docs/api-mureka-v1/post-mureka-music-create) * [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced) * [POST /music/create-instrumental](/docs/api-mureka-v1/post-mureka-music-create-instrumental) ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Responses **200** **200 OK** ```json { "song": { "song_id": "user:777-mureka:987654321-song:123456789", "title": "", "version": "1", "duration_milliseconds": 1234567, "generate_at": 123456789, "genres": [ "rock", "metal" ], "moods": [ "majestic", "romantic", "mysterious" ], "mp3_url": "https://.mp3", "share_key": "", "machine_audit_state": 1, "credit_type": 1, "cover": "https://.png", "lyrics": [ { "rows": [ { "start": 1, "end": 100, "text": "lyrics here" }, { "start": 200, "end": 300, "text": "lyrics continues" } ] } ], "video": {}, "share_link": "https://" }, "user": { "id": "987654321", "user_id": 987654321, "stage_name": "", "profile_image": "https://.png" }, "feed_id": 998877665544332211, "conn_id": "…", "state": 3, "generation_method": 1, "model": "O1" } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **404** **404 Not Found** ```json { "error": "The song has been deleted" } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional song: { song_id: number title: string version: string duration_milliseconds: number generate_at: number genres: string[] moods: string[] mp3_url: string share_key: string share_link: string machine_audit_state: number credit_type: number cover: string lyrics: { seg_type: number user_input_tag: string start?: number end?: number rows?: { start?: number end?: number text: string }[] }[] video?: { video_url: string video_cover_url: string video_id: number } } user: { id: string user_id: number stage_name: string profile_image: string } feed_id: number conn_id: string state: number generation_method: number model: string } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/music/song_id" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const song_id = "song_id"; const apiUrl = `https://api.useapi.net/v1/mureka/music/${song_id}`; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" song_id = "song_id" apiUrl = f"https://api.useapi.net/v1/mureka/music/{song_id}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-music-vocals === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-music-vocals ## Retrieve a list of vocal samples including the ones you uploaded December 2, 2024 (January 15, 2025) --- > **https://api.useapi.net/v1/mureka/music/vocals/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `last_id` is optional. Use it to retrieve the next page of data. To do so, set its value to the `last_id` returned in the previous response when the `more` field in that response is `true`. - `mine` is optional. Set to `true` to retrieve list of vocals uploaded via [POST files/vocal](/docs/api-mureka-v1/post-mureka-files-vocal). Supported values: `true`, `false` (default). ##### Responses **200** **200 OK** ```json { "list": [ { "id": 47235584950273, "url": "https://...mp3", "duration_milliseconds": 40731, "gender": 2, "title": "James", "created_at": 1735202082, "username": "Star_Boy", "background_url": "https://...jpg" }, { "id": 48696156946433, "url": "https://...mp3", "duration_milliseconds": 49059, "gender": 2, "title": "Bella", "created_at": 1735898537, "username": "ZenZephyr", "background_url": "https://...jpeg" } ], "last_id": 1726311196088, "more": true } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional list: { id: number url: string duration_milliseconds: number gender: number title: string created_at: number username: string background_url: string }[] last_id: number more: boolean } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/music/vocals/?account=account" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const account = "Previously configured account"; const apiUrl = `https://api.useapi.net/v1/mureka/music/vocals/?account=${account}`; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" account = "Previously configured account" apiUrl = f"https://api.useapi.net/v1/mureka/music/vocals/?account={account}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-music === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-music ## Retrieve generated music December 2, 2024 (March 31, 2025) --- > **https://api.useapi.net/v1/mureka/music/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `last_id` is optional. Use it to retrieve the next page of data. To do so, set its value to the `last_id` returned in the previous response when the `more` field in that response is `true`. - `expand` is optiona. Set it to `true` if you want to retrieve complete song details. Supported values: `true`, `false` (default). ##### Responses **200** **200 OK** ```json { "list": [ { "feed_id": 111222333, "state": 3, "songs": [ { "song_id": "user:777-mureka:123456789-song:111122222", "title": "", "version": "1", "duration_milliseconds": 123456, "generate_at": 123456789, "genres": [ "rock", "metal" ], "moods": [ "majestic", "romantic", "mysterious" ], "mp3_url": "https://.mp3", "share_key": "", "machine_audit_state": 1, "credit_type": 1, "cover": "https://.png", "share_link": "https://" }, { "song_id": "user:777-mureka:123456789-song:33334444", "title": "", "version": "1", "duration_milliseconds": 223456, "generate_at": 223456789, "genres": [ "rock", "metal" ], "moods": [ "quirky", "relaxed", "mysterious" ], "mp3_url": "https://.mp3", "share_key": "", "machine_audit_state": 1, "credit_type": 1, "cover": "https://.png", "share_link": "https://" } ], "conn_id": "…", "is_accelerated": true, "generation_method": 1, "model": "V6" }, { "feed_id": 444555666, "state": 3, "songs": [ { "song_id": "user:777-mureka:123456789-song:55556666", "title": "", "version": "1", "duration_milliseconds": 123456, "generate_at": 123456789, "genres": [ "latin", "world-music" ], "moods": [ "calm", "romantic", "happy" ], "mp3_url": "https://.mp3", "share_key": "", "machine_audit_state": 1, "credit_type": 1, "cover": "https://.png", "share_link": "https://" }, { "song_id": "user:777-mureka:123456789-song:77778888", "title": "", "version": "1", "duration_milliseconds": 223456, "generate_at": 223456789, "genres": [ "pop", "indie" ], "moods": [ "majestic", "inspired", "quirky" ], "mp3_url": "https://.mp3", "share_key": "", "machine_audit_state": 1, "credit_type": 1, "cover": "https://.png", "share_link": "https://" } ], "conn_id": "…", "is_accelerated": true, "generation_method": 1, "model": "O1" } ], "last_id": 123456789, "more": true, "total": 9623 } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional list: { feed_id: number state: number songs: { song_id: number title: string version: string duration_milliseconds: number generate_at: number genres: string[] moods: string[] mp3_url: string share_key: string share_link: string machine_audit_state: number wave_list: number[] credit_type: number cover: string is_played?: boolean is_liked?: boolean video?: { video_url: string video_cover_url: string video_id: number } }[] is_accelerated: boolean conn_id: string generation_method: number model: string }[] last_id: number total: number } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/music/?account=account" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const account = "Previously configured account"; const apiUrl = `https://api.useapi.net/v1/mureka/music/?account=${account}`; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" account = "Previously configured account" apiUrl = f"https://api.useapi.net/v1/mureka/music/?account={account}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-profile === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-profile ## Retrieve your [mureka.ai](https://www.mureka.ai) account information and remaining credits December 2, 2024 (April 4, 2026) --- > **https://api.useapi.net/v1/mureka/profile/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. ##### Responses **200** **200 OK** ```json { "user": { "id": "987654321", "user_id": 987654321, "stage_name": "useapi.net", "profile_image": "https://static-cos.mureka.ai/cos-prod/image/default.png", "is_vip": true, "vip_level": 2, "created_on": 1756353867, "sid": 123456789, "last_active_time": 1771038894, "country_code": "US", "register_ip": "192.168.0.1", "vip_end": 1771632412, "vip_name": "Monthly Pro", "vip_level_name": "basic", "vip_period_name": "month", "created_on_UTC": "2025-08-28T04:04:27.000Z", "vip_end_UTC": "2026-02-21T00:06:52.000Z" }, "country_code": "US", "credits": 500, "feed_list_count": 574, "credits_silver": 4, "free_download_mp3_models": [ "V8" ], "models": { "official_models": [ { "display_name": "V9", "model": "mureka-9", "description": "Advanced prompt control, studio-grade sound", "generation_amount": 1, "required_credits": 12, "supported_control_types": [ "refer", "prompt", "soundtrack", "motif", "vocal", "instrumental", "remix" ], "show_free_to_use": true, "app_display_name": "V9", "min_tier": "basic" }, { "display_name": "V8", "model": "mureka-8.0.1", "description": "Publish-ready music, emotional vocals, memorable melodies.", "generation_amount": 1, "required_credits": 12, "supported_control_types": [ "refer", "prompt", "soundtrack", "motif", "vocal", "instrumental", "remix" ], "show_free_to_use": true, "app_display_name": "V8", "min_tier": "basic" }, { "display_name": "O2", "model": "mureka-o2", "description": "All-in-one smart music model, professional results.", "generation_amount": 1, "required_credits": 20, "supported_control_types": [ "refer", "prompt", "soundtrack", "instrumental", "vocal" ], "show_free_to_use": true, "app_display_name": "O2", "min_tier": "basic" }, { "display_name": "V7.6", "model": "mureka-7.6", "description": "Pro music creation, finer prompt control.", "generation_amount": 1, "required_credits": 10, "supported_control_types": [ "refer", "prompt", "soundtrack", "motif", "vocal", "instrumental" ], "show_free_to_use": true, "app_display_name": "V7.6", "min_tier": "basic" }, { "display_name": "V7.5-all", "model": "mureka-7.5all", "description": "Easy music creation, clear vocal, quick mixing, entry-level.", "generation_amount": 1, "required_credits": 10, "supported_control_types": [ "refer", "prompt", "soundtrack", "motif", "vocal", "instrumental" ], "show_free_to_use": true, "app_display_name": "V7.5-all" } ], "default_model": { "display_name": "V9", "model": "mureka-9", "description": "Advanced prompt control, studio-grade sound", "generation_amount": 1, "required_credits": 12, "supported_control_types": [ "refer", "prompt", "soundtrack", "motif", "vocal", "instrumental", "remix" ], "show_free_to_use": true, "app_display_name": "V9", "min_tier": "basic" } } } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional user: { id: string user_id: number stage_name: string profile_image: string is_vip: boolean vip_level: number created_on: number sid: number register_ip: string vip_start: number vip_end: number vip_name: string vip_level_name: string vip_period_name: string } credits: number credits_silver?: number feed_list_count: number free_download_mp3_models?: string[] models?: { official_models: { display_name: string model: string description?: string generation_amount?: number required_credits: number supported_control_types: string[] show_free_to_use?: boolean app_display_name?: string min_tier?: string }[] default_model: { display_name: string model: string description?: string generation_amount?: number required_credits: number supported_control_types: string[] show_free_to_use?: boolean app_display_name?: string min_tier?: string } } } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/profile/?account=account" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const account = "Previously configured account"; const apiUrl = `https://api.useapi.net/v1/mureka/profile/?account=${account}`; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" account = "Previously configured account" apiUrl = f"https://api.useapi.net/v1/mureka/profile/?account={account}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-speech-voices === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-speech-voices ## Retrieve speech voices August 18, 2025 --- This endpoint retrieves available voices for speech generation, including both built-in voices and your custom cloned voices. Use the `cloned` parameter to filter for only cloned voices created via [POST /speech/voice](/docs/api-mureka-v1/post-mureka-speech-voice). Use pagination with the `last_id` parameter and `more` field to browse through all available voices. Voices include preview audio for testing before use. > **https://api.useapi.net/v1/mureka/speech/voices/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `last_id` is optional. Use it to retrieve the next page of data. Set its value to the `last_id` returned in the previous response. - `cloned` is optional. Filter voices by type. Set to `true` for only cloned voices, `false` for built-in voices, or omit for all voices. Supported values: `true`, `false`. ##### Responses **200** **200 OK** ```json { "list": [ { "id": 12345678901234, "user_id": 23456789012345, "title": "Sarah", "cover": "https://static-cos.mureka.ai/cos-prod/res/cover/….png", "mp3_url": "https://static-cos.mureka.ai/cos-prod/tts-v2/….mp3", "language": "en", "created_at": 1755483687, "description": "Professional female voice", "duration_milliseconds": 12520, "source_type": 2, "machine_audit_state": 1 }, { "id": 34567890123456, "user_id": 23456789012345, "title": "Michael", "cover": "https://static-cos.mureka.ai/cos-prod/res/cover/….png", "mp3_url": "https://static-cos.mureka.ai/cos-prod/tts-v2/….mp3", "language": "en", "created_at": 1755483619, "description": "Deep male narrator", "duration_milliseconds": 13680, "source_type": 2, "machine_audit_state": 1 } ], "last_id": 1755483619964 } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional list: { id: number user_id: number title: string cover: string mp3_url: string language: string created_at: number description: string duration_milliseconds: number source_type?: number machine_audit_state: number }[] last_id: number more?: boolean } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/speech/voices/?cloned=true" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const apiUrl = "https://api.useapi.net/v1/mureka/speech/voices/?cloned=true"; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" apiUrl = "https://api.useapi.net/v1/mureka/speech/voices/?cloned=true" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/get-mureka-speech === Document URL: https://useapi.net/docs/api-mureka-v1/get-mureka-speech ## Retrieve generated speech August 18, 2025 --- This endpoint retrieves a list of previously generated speech recordings from your Mureka account. Use pagination with the `last_id` parameter to browse through all your speech history. The `more` field indicates whether additional pages are available. Each response includes the generated audio URLs, titles, and metadata for easy playback and management. > **https://api.useapi.net/v1/mureka/speech/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `last_id` is optional. Use it to retrieve the next page of data. Set its value to the `last_id` returned in the previous response. ##### Responses **200** **200 OK** ```json { "list": [ { "title": "Morning Conversation", "preview": "Good morning! How are you doing today? I hope you're having a wonderful start to your day.", "cover": "https://static-cos.mureka.ai/cos-prod/res/cover/….png", "mp3_url": "https://static-cos.mureka.ai/cos-prod/tts-v2/….mp3", "id": 23456789012345, "duration_milliseconds": 8500, "audio_quality": 2, "state": 3 }, { "title": "Evening Reflection", "preview": "As the day comes to an end, let's take a moment to reflect on all the good things that happened.", "cover": "https://static-cos.mureka.ai/cos-prod/res/cover/….png", "mp3_url": "https://static-cos.mureka.ai/cos-prod/tts-v2/….mp3", "id": 34567890123456, "duration_milliseconds": 12300, "audio_quality": 2, "state": 3 } ], "last_id": 1755483687, "more": true } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional list: { title: string preview: string cover: string mp3_url: string id: number duration_milliseconds: number audio_quality: number state: number }[] last_id: number more?: boolean } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/speech/" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" ``` **JavaScript** ``` javascript const token = "API token"; const apiUrl = "https://api.useapi.net/v1/mureka/speech/"; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" apiUrl = "https://api.useapi.net/v1/mureka/speech/" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-accounts-account === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-accounts-account ## Create or update Mureka API account configuration (Legacy) December 2, 2024 (January 20, 2026) --- > This is the legacy method that requires manual token renewal every 30 days. We recommend using [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts) with Google cookies for **automatic token refresh**. See [Setup Mureka (Legacy)](/docs/start-here/setup-mureka-legacy) for details. > **https://api.useapi.net/v1/mureka/accounts/`account`** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Request Body ```json { "account": "Mureka account", "token": "Mureka token", } ``` - `account` and `token` are **required**. Please see [Setup Mureka](/docs/start-here/setup-mureka) for details. - `account` value specified in the request body **must match** the account value specified in the URL path https://api.useapi.net/v1/mureka/accounts/`account`. ##### Responses **201** **201 Created** ```json { "updated": 1724514995, "account": "123456789", "token": "", "updatedUTC": "2024-10-24T15:56:35.000Z", "email": "user@gmail.com" } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Wrong username/password combination.", "code": 401 } ``` ##### Model ```typescript { // TypeScript, all fields are optional account: string token: string updated: number updatedUTC: string email?: string error: string code: number } ``` ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X POST https://api.useapi.net/v1/mureka/accounts/ \ -d '{"account": "…", "token": "…"}' ``` **JavaScript** ``` javascript const account = "Mureka account"; const token = "Mureka token"; const apiUrl = `https://api.useapi.net/v1/mureka/accounts/${account}`; const api_token = "API token"; const data = { method: 'POST', headers: { 'Authorization': `Bearer ${api_token}`, 'Content-Type': 'application/json' } }; data.body = JSON.stringify({ account, token }); const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests account = "Mureka account" token = "Mureka token" apiUrl = f"https://api.useapi.net/v1/mureka/accounts/{account}" api_token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {api_token}" } body = { "account": f"{account}", "token": f"{token}" } response = requests.post(apiUrl, headers=headers, json=body) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-accounts === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-accounts ## Configure Mureka API account with auto-refresh January 19, 2026 (January 20, 2026) --- Configure your Mureka account for API access using Google OAuth cookies. This method enables **automatic token refresh** - when your Mureka session expires, the API will automatically refresh it using Google One Tap authentication. See [Setup Mureka](/docs/start-here/setup-mureka) for detailed instructions. > Looking for the [legacy method](/docs/api-mureka-v1/post-mureka-accounts-account) with manual token setup? > **https://api.useapi.net/v1/mureka/accounts** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json # Alternatively you can use multipart/form-data # Content-Type: multipart/form-data ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Request Body **Option 1: Tab-separated format** (paste cookie as copied from DevTools) ``` { "sessionCookie": "__Secure-3PSIDg.a0...secured...076.google.com/2027-02-23T04:38:16.033Z167NoneHigh" } ``` Where `` represents actual tab characters as copied from Chrome DevTools. **Option 2: Minimal JSON format** ```json { "sessionCookie": {"value": "g.a0...secured...076", "expires": "2027-02-23T04:38:16.033Z"} } ``` - `sessionCookie` is **required**. The `__Secure-3PSID` cookie from `accounts.google.com`. Accepts: - Tab-separated format (copied directly from Chrome DevTools) - Minimal JSON: `{"value": "g.a0...secured...076", "expires": "2027-02-23T04:38:16.033Z"}` - Full JSON cookie object ##### Responses **200** **200 OK** Account configured successfully with auto-refresh enabled. ```json { "64532357578753": { "account": "64532357578753", "token": "JfE...secured...2sWc", "hasAutoRefresh": true, "tokenIssuedDaysAgo": 0, "updatedUTC": "2026-01-19T04:38:16.000Z", "email": "user@gmail.com", "sessionCookie": { "name": "__Secure-3PSID", "value": "g.a0005wi...secured...90076", "domain": ".google.com", "path": "/", "expires": "2027-02-23T04:38:16.033Z", "httpOnly": true, "secure": true, "sameSite": "None", "added": "2026-01-19T04:38:16.000Z" }, "user": { "id": "64532357578753", "name": "User", "avatar": "https://...", "gold": 40, "vip_type": 2 } } } ``` **400** **400 Bad Request** Cookie validation failed or expired. ```json { "error": "Google cookie expired on 2025-01-19T04:38:16.033Z. Please provide a fresh cookie.", "code": 597 } ``` Or if the cookie is not found: ```json { "error": "Required cookie __Secure-3PSID not found in sessionCookie", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` ##### Model ```typescript { // TypeScript, all fields are optional [account: string]: { account: string token: string hasAutoRefresh: boolean tokenIssuedDaysAgo: number updatedUTC: string email?: string sessionCookie: { name: string value: string domain: string path: string expires: string httpOnly: boolean secure: boolean sameSite: string added: string } user: { id: string name: string avatar: string gold: number vip_type: number } } error: string code: number } ``` ##### Automatic Token Refresh When configured with this endpoint, your Mureka account benefits from **automatic token refresh**: - The `__Secure-3PSID` Google cookie is valid for approximately **13 months** - When your Mureka session token expires (typically after 30 days), the API **automatically** refreshes it using Google One Tap - You will receive email notifications when: - A token refresh is initiated - The refresh succeeds - The refresh fails (manual re-setup required) If automatic refresh fails (e.g., Google invalidated the cookie), you will need to repeat the [setup process](/docs/start-here/setup-mureka) with fresh cookies. ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X POST https://api.useapi.net/v1/mureka/accounts \ -d '{"sessionCookie": {"value": "g.a0...YOUR_COOKIE_VALUE...076", "expires": "2027-02-23T04:38:16.033Z"}}' ``` **JavaScript** ``` javascript const apiUrl = 'https://api.useapi.net/v1/mureka/accounts'; const api_token = "API token"; // Option 1: Tab-separated format (paste directly from DevTools) // const sessionCookie = "paste tab-separated cookie row from DevTools here"; // Option 2: Minimal JSON format const sessionCookie = {value: "g.a0...secured...076", expires: "2027-02-23T04:38:16.033Z"}; const response = await fetch(apiUrl, { method: 'POST', headers: { 'Authorization': `Bearer ${api_token}`, 'Content-Type': 'application/json' }, body: JSON.stringify({ sessionCookie }) }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests apiUrl = "https://api.useapi.net/v1/mureka/accounts" api_token = "API token" # Option 1: Tab-separated format (paste directly from DevTools) # sessionCookie = "paste tab-separated cookie row from DevTools here" # Option 2: Minimal JSON format sessionCookie = {"value": "g.a0...secured...076", "expires": "2027-02-23T04:38:16.033Z"} headers = { "Content-Type": "application/json", "Authorization": f"Bearer {api_token}" } body = { "sessionCookie": sessionCookie } response = requests.post(apiUrl, headers=headers, json=body) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-files-motif === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-files-motif ## Upload mp3 melody (motif) track December 13, 2024 --- Upload mp3 audio file up to 5GB in size. Use `id` value to reference uploaded melody when using the parameter `motif_id` of [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced). Uploaded file will not be visible for other users of the Mureka.ai [POST raw content using Make.com and similar nocode tools.](/docs/questions-and-answers#how-post-raw-content-to-runwaymlassets-and-minimaxfiles-using-makecom-and-similar-nocode-tools) > **https://api.useapi.net/v1/mureka/files/motif/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: audio/mpeg ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. - `Content-Type` is **required**, only `audio/mpeg ` supported. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. ##### Responses **200** **200 OK** The response contains an `id` that you can use to reference the uploaded melody when using the parameter `motif_id` of [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced). ```json { "id": "user:777-mureka:987654321-file:123456789", "url": "https://.mp3", "duration_milliseconds": 50000 } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional id: string url: string duration_milliseconds: number } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/files/motif/?account=" \ -H "Authorization: Bearer …" \ -H "Content-Type: audio/mpeg" \ --data-binary /path/to/your/audio.mp3 ``` **JavaScript** ``` javascript const token = "API token"; const account = "Previously configured account account"; const apiUrl = `https://api.useapi.net/v1/mureka/files/motif/?account=${account}`; let blob; /* // Example 1: Fetch audio from URL const url = "https://upload.wikimedia.org/wikipedia/commons/7/7d/sound.mp3"; const response = await fetch(url); blob = await responseImage.blob(); */ /* // Example 2: Load audio from local file (Blob) const fsp = require('fs').promises; const fileName = "./music.mp3"; blob = new Blob([await fsp.readFile(fileName)]); */ /* // Example 3: Load from input file html element // const musicFile = document.getElementById(`music-file`); if (musicFile.files[0]) blob = musicFile.files[0]); */ const response = await fetch(apiUrl, { method: "POST" headers: { "Authorization": `Bearer ${token}`, }, body: blob }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" account = "Previously configured account account" apiUrl = f"https://api.useapi.net/v1/mureka/files/motif/?account={account}" headers = { 'Authorization': f'Bearer {token}', 'Content-Type': 'audio/mpeg' } # # Example 1: Fetch audio from URL # url = "https://upload.wikimedia.org/wikipedia/commons/7/7d/audio.mp3" # response_audio = requests.get(url) # file_content = response_audio.content # # Example 2: Load audio from local file # audio_file_path = "./audio.mp3" # with open(audio_file_path, 'rb') as audio_file: # file_content = audio_file.read() response = requests.post(api_url, headers=headers, data=file_content) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-files-vocal === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-files-vocal ## Upload mp3 vocal January 15, 2025 --- Upload mp3 audio file up to 5GB in size. Use `id` value to reference uploaded vocal when using the parameter `vocal_id` of [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced). Uploaded file will not be visible for other users of the Mureka.ai [POST raw content using Make.com and similar nocode tools.](/docs/questions-and-answers#how-post-raw-content-to-runwaymlassets-and-minimaxfiles-using-makecom-and-similar-nocode-tools) > **https://api.useapi.net/v1/mureka/files/vocal/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: audio/mpeg ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. - `Content-Type` is **required**, only `audio/mpeg ` supported. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `title` is **required**. Provide name for your vocal. ##### Responses **200** **200 OK** The response contains an `id` that you can use to reference the uploaded melody when using the parameter `vocal_id` of [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced). ```json { "id": 1234567890, "title": "vocal name", "url": "https://.mp3", "duration_milliseconds": 50000 } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional id: number title: string url: string duration_milliseconds: number } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/files/vocal/?account=" \ -H "Authorization: Bearer …" \ -H "Content-Type: audio/mpeg" \ --data-binary /path/to/your/audio.mp3 ``` **JavaScript** ``` javascript const token = "API token"; const account = "Previously configured account account"; const apiUrl = `https://api.useapi.net/v1/mureka/files/vocal/?account=${account}`; let blob; /* // Example 1: Fetch audio from URL const url = "https://upload.wikimedia.org/wikipedia/commons/7/7d/sound.mp3"; const response = await fetch(url); blob = await responseImage.blob(); */ /* // Example 2: Load audio from local file (Blob) const fsp = require('fs').promises; const fileName = "./music.mp3"; blob = new Blob([await fsp.readFile(fileName)]); */ /* // Example 3: Load from input file html element // const musicFile = document.getElementById(`music-file`); if (musicFile.files[0]) blob = musicFile.files[0]); */ const response = await fetch(apiUrl, { method: "POST" headers: { "Authorization": `Bearer ${token}`, }, body: blob }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" account = "Previously configured account account" apiUrl = f"https://api.useapi.net/v1/mureka/files/vocal/?account={account}" headers = { 'Authorization': f'Bearer {token}', 'Content-Type': 'audio/mpeg' } # # Example 1: Fetch audio from URL # url = "https://upload.wikimedia.org/wikipedia/commons/7/7d/audio.mp3" # response_audio = requests.get(url) # file_content = response_audio.content # # Example 2: Load audio from local file # audio_file_path = "./audio.mp3" # with open(audio_file_path, 'rb') as audio_file: # file_content = audio_file.read() response = requests.post(api_url, headers=headers, data=file_content) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-files === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-files ## Upload mp3 audio track to your music collection December 13, 2024 --- Upload mp3 audio file up to 5GB in size. Files uploaded using this endpoint will be visible to all users of Mureka.ai website. To retrieve a full list of all your uploaded tracks use [GET /files](/docs/api-mureka-v1/get-mureka-files). [POST raw content using Make.com and similar nocode tools.](/docs/questions-and-answers#how-post-raw-content-to-runwaymlassets-and-minimaxfiles-using-makecom-and-similar-nocode-tools) > **https://api.useapi.net/v1/mureka/files/?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: audio/mpeg ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. - `Content-Type` is **required**, only `audio/mpeg ` supported. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `title` is **required**. - `genre` is **required**. Provide the genre of your track. See supported values using [GET /music/moods-and-genres](/docs/api-mureka-v1/get-mureka-music-moods-and-genres). - `mood` is **required**. Provide the mood of your track. See supported values using [GET /music/moods-and-genres](/docs/api-mureka-v1/get-mureka-music-moods-and-genres). - `url` is optional. Provide the original YouTube url if applicable. ##### Responses **200** **200 OK** The response contains an `id` that you can use to reference the uploaded audio file when using the parameter `ref_id` of [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced). ```json { "id": 1122334455, "url": "https://.mp3", "duration_milliseconds": 30000, "mood": "relaxed", "title": "", "genre": "afrobeat" } ``` **400** **400 Bad Request** ```json { "error": "", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional id: number url: string duration_milliseconds: number mood: string title: string genre: string } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/files/?account=&title=&genre=<genre>&mood=<mood>" \ -H "Authorization: Bearer …" \ -H "Content-Type: audio/mpeg" \ --data-binary /path/to/your/audio.mp3 ``` **JavaScript** ``` javascript const token = "API token"; const account = "Previously configured account account"; const title = "song title"; const mood = "song mood"; const genre = "song genre"; const apiUrl = `https://api.useapi.net/v1/mureka/files/?account=${account}&title=${title}&genre=${genre}&mood=${mood}`; let blob; /* // Example 1: Fetch audio from URL const url = "https://upload.wikimedia.org/wikipedia/commons/7/7d/sound.mp3"; const response = await fetch(url); blob = await responseImage.blob(); */ /* // Example 2: Load audio from local file (Blob) const fsp = require('fs').promises; const fileName = "./music.mp3"; blob = new Blob([await fsp.readFile(fileName)]); */ /* // Example 3: Load from input file html element // <input id="music-file" type="file"> const musicFile = document.getElementById(`music-file`); if (musicFile.files[0]) blob = musicFile.files[0]); */ const response = await fetch(apiUrl, { method: "POST" headers: { "Authorization": `Bearer ${token}`, }, body: blob }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" account = "Previously configured account account" title = "song title" mood = "song mood" genre = "song genre" apiUrl = f"https://api.useapi.net/v1/mureka/files/?account={account}&title={title}&genre={genre}&mood={mood}" headers = { 'Authorization': f'Bearer {token}', 'Content-Type': 'audio/mpeg' } # # Example 1: Fetch audio from URL # url = "https://upload.wikimedia.org/wikipedia/commons/7/7d/audio.mp3" # response_audio = requests.get(url) # file_content = response_audio.content # # Example 2: Load audio from local file # audio_file_path = "./audio.mp3" # with open(audio_file_path, 'rb') as audio_file: # file_content = audio_file.read() response = requests.post(api_url, headers=headers, data=file_content) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-create-advanced === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-create-advanced ## Create a song using custom lyrics, styles, vocals and reference song <small>December 2, 2024 (April 4, 2026)</small> --- Mureka supports up to **10 parallel generations** per account in **near real-time** fashion, with an average generation time of 45 seconds (each generation produces two songs). Generated songs can be up to 5 minutes long depending on your lyrics. > **https://api.useapi.net/v1/mureka/music/create-advanced** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json # Alternatively you can use multipart/form-data # Content-Type: multipart/form-data ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Request Body ```json { "account": "Optional Mureka API account", "lyrics": "Required song lyrics", "title": "Optional song title", } ``` - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) is configured or if the `motif_id` parameter is provided. However, if you have multiple accounts configured and the `motif_id` parameter is not provided, this parameter becomes **required**. - `lyrics` is **required**. Lyrics for the song. Maximum length: 5000 characters. - `title` is optional. Song title. Maximum length: 50 characters. - `desc` is optional. To guide song generation, provide a comma-separated list of genres, moods, and desired vocals. See supported values using [GET /music/moods-and-genres](/docs/api-mureka-v1/get-mureka-music-moods-and-genres). This parameter is not compatible with parameters `ref_id`, `vocal_id` or `motif_id`. Example: `pop, electronic, happy, female vocal`" Maximum length: 1000 characters. - `vocal_id` is optional. Specify the desired vocal. See supported vocals using [GET /music/vocals](/docs/api-mureka-v1/get-mureka-music-vocals). - `ref_id` is optional. Create songs inspired by a reference track. See available tracks using [GET /music/refs](/docs/api-mureka-v1/get-mureka-music-refs). You can upload your own track using [POST /files](/docs/api-mureka-v1/post-mureka-files). To see a list of tracks you have already uploaded, use [GET /files](/docs/api-mureka-v1/get-mureka-files). - `motif_id` is optional. Create songs inspired by a melody idea to kickstart your song. Upload the melody using [POST /files/motif](/docs/api-mureka-v1/post-mureka-files-motif) and use the returned `id` value. This parameter is not compatible with parameters `ref_id`, `vocal_id` or `desc`. - `model` is optional. Supported values: `V9` (default), `V8`, `O2`, `V7.6`, `V7.5`. - `vocal_gender` is optional. Specify desired vocal gender. Supported values: `female`, `male`. Note: `V7`, `O1`, `V6`, and `V5.5` are retired models that now redirect to `V7.6`. - `async` is optional, enables fire-and-forget mode (default: `false`). When `true`, returns immediately with `201 Created` and job metadata. Poll [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) for completion status. Useful for avoiding long request timeouts since music generation takes 30-90 seconds. - `replyUrl` is optional, webhook URL for job status callbacks. Receives POST requests with job status updates (`created`, `completed`, `failed`). The JSON payload shape matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. - `replyRef` is optional, custom reference string passed back in webhook callbacks. Useful for tracking jobs on your end. ##### Responses **200** **200 OK** ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "feed_id": 11223344, "state": 3, "songs": [ { "song_id": "user:777-mureka:123456789-song:33445566", "title": "<title>", "version": "1", "duration_milliseconds": 234567, "generate_at": 12345677, "genres": [ "electronic", "indie" ], "moods": [ "quirky", "angry", "restless" ], "mp3_url": "https://<download link>.mp3", "share_key": "<share key>", "recall": true, "machine_audit_state": 4, "credit_type": 1, "cover": "https://<cover image>.png", "share_link": "https://<share link>" }, { "song_id": "user:777-mureka:123456789-song:33445566", "title": "<title>", "version": "2", "duration_milliseconds": 1234567, "generate_at": 12345667, "genres": [ "electronic", "world-music" ], "moods": [ "dark", "quirky", "energetic" ], "mp3_url": "https://<download link>.mp3", "share_key": "<share key>", "machine_audit_state": 1, "credit_type": 1, "cover": "https://<cover image>.png", "share_link": "https://<share link>" } ] } ``` **201** **201 Created** Job created in async mode (`async: true`). Music generation is processing in the background. Use [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) to poll for completion status. ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "verb": "music/create-advanced", "jobType": "music", "status": "created", "created": "2026-01-20T12:34:56.789Z", "request": { "account": "12345678901234", "lyrics": "Your song lyrics here", "title": "My Song", "model": "V7.6", "async": true, "replyUrl": "https://your-domain.com/webhook", "replyRef": "my-custom-ref-123" } } ``` **400** **400 Bad Request** ```json { "error": "<Error message>", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Wrong username/password combination.", "code": 401 } ``` **429** **429 Too Many Requests** * Rate limit exceeded. Endpoint called too frequently. Wait at least 3 seconds before making another call. ```json { "code": 9008, "msg": "Too frequently, please try again later." } ``` * Concurrent job limit exceeded. All job slots are taken (typically 10 concurrent generations per account). Wait at least 5 seconds before retrying. ```json { "error": "Generate multiple task exceed limit. (6323)" } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model **200 OK (Sync)** Music generation completed. Returns full song data with MP3 URLs. ```typescript { jobid: string // Job identifier (for later lookup) feed_id: number state: number songs?: { song_id: string title: string version: string duration_milliseconds: number generate_at: number genres: string[] moods: string[] mp3_url: string share_key: string machine_audit_state: number credit_type: number cover: string share_link: string }[] error?: string code?: number msg?: string } ``` **201 Created (Async)** Job created and processing in background. Structure matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. ```typescript { jobid: string // Job identifier verb: 'music/create-advanced' // Job verb jobType: 'music' // Job type status: 'created' // Job status created: string // ISO 8601 timestamp request: { account?: string lyrics: string title?: string desc?: string vocal_id?: string ref_id?: string motif_id?: string model?: string vocal_gender?: string async: true replyUrl?: string replyRef?: string } } ``` **Error** Error response structure (applies to both sync and async modes). ```typescript { jobid?: string // Present for job-related errors error: string // Error summary message code?: number // HTTP status code or error code msg?: string // Additional error message } ``` ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X POST https://api.useapi.net/v1/mureka/music/create-advanced \ -d '{"account": "…", "lyrics": "…"}' ``` **JavaScript** ``` javascript const account = "Mureka account"; const lyrics = "<Your song lyrics here>"; const apiUrl = `https://api.useapi.net/v1/mureka/music/create-advanced`; const api_token = "API token"; const data = { method: 'POST', headers: { 'Authorization': `Bearer ${api_token}`, 'Content-Type': 'application/json' } }; data.body = JSON.stringify({ account, lyrics }); const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests account = "Mureka account" lyrics = "<Your song lyrics here>" apiUrl = f"https://api.useapi.net/v1/mureka/music/create-advanced" api_token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {api_token}" } body = { "account": f"{account}", "lyrics": f"{lyrics}" } response = requests.post(apiUrl, headers=headers, json=body) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-create-instrumental === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-create-instrumental ## Create instrumental music <small>March 31, 2025 (April 4, 2026)</small> --- Mureka supports up to **10 parallel generations** per account in **near real-time** fashion, with an average generation time of 45 seconds (each generation produces two songs). Generated songs can be up to 5 minutes long depending on your prompt. > **https://api.useapi.net/v1/mureka/music/create-instrumental** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json # Alternatively you can use multipart/form-data # Content-Type: multipart/form-data ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Request Body ```json { "account": "Optional Mureka API account", "prompt": "Ambient electronic with soft pads, great for nature walks and peaceful moments." } ``` - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) is configured or if the `motif_id` parameter is provided. However, if you have multiple accounts configured and the `motif_id` parameter is not provided, this parameter becomes **required**. - `prompt` is optional. Describe your instrumental music. Maximum length: 1000 characters. - `title` is optional. Song title. Maximum length: 50 characters. - `ref_id` is optional. Create music inspired by a reference track. See available tracks using [GET /music/refs](/docs/api-mureka-v1/get-mureka-music-refs). You can upload your own track using [POST /files](/docs/api-mureka-v1/post-mureka-files). To see a list of tracks you have already uploaded, use [GET /files](/docs/api-mureka-v1/get-mureka-files). - `model` is optional. Supported values: `V9` (default), `V8`, `O2`, `V7.6`, `V7.5`. Note: `V7`, `O1`, `V6`, and `V5.5` are retired models that now redirect to `V7.6`. - `async` is optional, enables fire-and-forget mode (default: `false`). When `true`, returns immediately with `201 Created` and job metadata. Poll [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) for completion status. Useful for avoiding long request timeouts since music generation takes 30-90 seconds. - `replyUrl` is optional, webhook URL for job status callbacks. Receives POST requests with job status updates (`created`, `completed`, `failed`). The JSON payload shape matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. - `replyRef` is optional, custom reference string passed back in webhook callbacks. Useful for tracking jobs on your end. ##### Responses **200** **200 OK** ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "feed_id": 11223344, "state": 3, "songs": [ { "song_id": "user:777-mureka:123456789-song:33445566", "title": "<title>", "version": "1", "duration_milliseconds": 234567, "generate_at": 12345677, "genres": [ "electronic", "indie" ], "moods": [ "quirky", "angry", "restless" ], "mp3_url": "https://<download link>.mp3", "share_key": "<share key>", "recall": true, "machine_audit_state": 4, "credit_type": 1, "cover": "https://<cover image>.png", "share_link": "https://<share link>" }, { "song_id": "user:777-mureka:123456789-song:33445566", "title": "<title>", "version": "2", "duration_milliseconds": 1234567, "generate_at": 12345667, "genres": [ "electronic", "world-music" ], "moods": [ "dark", "quirky", "energetic" ], "mp3_url": "https://<download link>.mp3", "share_key": "<share key>", "machine_audit_state": 1, "credit_type": 1, "cover": "https://<cover image>.png", "share_link": "https://<share link>" } ] } ``` **201** **201 Created** Job created in async mode (`async: true`). Music generation is processing in the background. Use [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) to poll for completion status. ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "verb": "music/create-instrumental", "jobType": "music", "status": "created", "created": "2026-01-20T12:34:56.789Z", "request": { "account": "12345678901234", "prompt": "Ambient electronic with soft pads", "model": "V7.6", "async": true, "replyUrl": "https://your-domain.com/webhook", "replyRef": "my-custom-ref-123" } } ``` **400** **400 Bad Request** ```json { "error": "<Error message>", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Wrong username/password combination.", "code": 401 } ``` **429** **429 Too Many Requests** * Rate limit exceeded. Endpoint called too frequently. Wait at least 3 seconds before making another call. ```json { "code": 9008, "msg": "Too frequently, please try again later." } ``` * Concurrent job limit exceeded. All job slots are taken (typically 10 concurrent generations per account). Wait at least 5 seconds before retrying. ```json { "error": "Generate multiple task exceed limit. (6323)" } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model **200 OK (Sync)** Music generation completed. Returns full song data with MP3 URLs. ```typescript { jobid: string // Job identifier (for later lookup) feed_id: number state: number songs?: { song_id: string title: string version: string duration_milliseconds: number generate_at: number genres: string[] moods: string[] mp3_url: string share_key: string machine_audit_state: number credit_type: number cover: string share_link: string }[] error?: string code?: number msg?: string } ``` **201 Created (Async)** Job created and processing in background. Structure matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. ```typescript { jobid: string // Job identifier verb: 'music/create-instrumental' // Job verb jobType: 'music' // Job type status: 'created' // Job status created: string // ISO 8601 timestamp request: { account?: string prompt?: string title?: string ref_id?: string model?: string async: true replyUrl?: string replyRef?: string } } ``` **Error** Error response structure (applies to both sync and async modes). ```typescript { jobid?: string // Present for job-related errors error: string // Error summary message code?: number // HTTP status code or error code msg?: string // Additional error message rawData?: string // Raw error data (if available) } ``` ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X POST https://api.useapi.net/v1/mureka/music/create-instrumental \ -d '{"account": "…", "prompt": "…"}' ``` **JavaScript** ``` javascript const account = "Mureka account"; const prompt = "<Your music prompt here>"; const apiUrl = `https://api.useapi.net/v1/mureka/music/create-instrumental`; const api_token = "API token"; const data = { method: 'POST', headers: { 'Authorization': `Bearer ${api_token}`, 'Content-Type': 'application/json' } }; data.body = JSON.stringify({ account, prompt }); const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests account = "Mureka account" prompt = "<Your music prompt here>" apiUrl = f"https://api.useapi.net/v1/mureka/music/create-instrumental" api_token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {api_token}" } body = { "account": f"{account}", "prompt": f"{prompt}" } response = requests.post(apiUrl, headers=headers, json=body) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-create === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-create ## Create a song using AI-generated lyrics based on your prompt <small>December 2, 2024 (April 4, 2026)</small> --- Mureka supports up to **10 parallel generations** per account in **near real-time** fashion, with an average generation time of 45 seconds (each generation produces two songs). Generated songs can be up to 5 minutes long depending on your lyrics. > **https://api.useapi.net/v1/mureka/music/create** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json # Alternatively you can use multipart/form-data # Content-Type: multipart/form-data ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Request Body ```json { "account": "Optional Mureka API account", "prompt": "Optional text prompt" } ``` - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple music configured, this parameter becomes **required**. - `prompt` is optional. Use it to guide AI to generate desired lyrics. If omitted AI will generate some random lyrics. Maximum length: 3000 characters. - `model` is optional. Supported values: `V9` (default), `V8`, `O2`, `V7.6`, `V7.5`. Note: `V7`, `O1`, `V6`, and `V5.5` are retired models that now redirect to `V7.6`. - `async` is optional, enables fire-and-forget mode (default: `false`). When `true`, returns immediately with `201 Created` and job metadata. Poll [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) for completion status. Useful for avoiding long request timeouts since music generation takes 30-90 seconds. - `replyUrl` is optional, webhook URL for job status callbacks. Receives POST requests with job status updates (`created`, `completed`, `failed`). The JSON payload shape matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. - `replyRef` is optional, custom reference string passed back in webhook callbacks. Useful for tracking jobs on your end. ##### Responses **200** **200 OK** ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "feed_id": 11223344, "state": 3, "songs": [ { "song_id": "user:777-mureka:123456789-song:33445566", "title": "<title>", "version": "1", "duration_milliseconds": 234567, "generate_at": 12345677, "genres": [ "electronic", "indie" ], "moods": [ "quirky", "angry", "restless" ], "mp3_url": "https://<download link>.mp3", "share_key": "<share key>", "recall": true, "machine_audit_state": 4, "credit_type": 1, "cover": "https://<cover image>.png", "share_link": "https://<share link>" }, { "song_id": "user:777-mureka:123456789-song:33445566", "title": "<title>", "version": "2", "duration_milliseconds": 1234567, "generate_at": 12345667, "genres": [ "electronic", "world-music" ], "moods": [ "dark", "quirky", "energetic" ], "mp3_url": "https://<download link>.mp3", "share_key": "<share key>", "machine_audit_state": 1, "credit_type": 1, "cover": "https://<cover image>.png", "share_link": "https://<share link>" } ] } ``` **201** **201 Created** Job created in async mode (`async: true`). Music generation is processing in the background. Use [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) to poll for completion status. ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "verb": "music/create", "jobType": "music", "status": "created", "created": "2026-01-20T12:34:56.789Z", "request": { "account": "12345678901234", "prompt": "Silly song about Santa", "model": "V7.6", "async": true, "replyUrl": "https://your-domain.com/webhook", "replyRef": "my-custom-ref-123" } } ``` **400** **400 Bad Request** ```json { "error": "<Error message>", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Wrong username/password combination.", "code": 401 } ``` **429** **429 Too Many Requests** * Rate limit exceeded. Endpoint called too frequently. Wait at least 3 seconds before making another call. ```json { "code": 9008, "msg": "Too frequently, please try again later." } ``` * Concurrent job limit exceeded. All job slots are taken (typically 10 concurrent generations per account). Wait at least 5 seconds before retrying. ```json { "error": "Generate multiple task exceed limit. (6323)" } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model **200 OK (Sync)** Music generation completed. Returns full song data with MP3 URLs. ```typescript { jobid: string // Job identifier (for later lookup) feed_id: number state: number songs?: { song_id: string title: string version: string duration_milliseconds: number generate_at: number genres: string[] moods: string[] mp3_url: string share_key: string machine_audit_state: number credit_type: number cover: string share_link: string }[] error?: string code?: number msg?: string } ``` **201 Created (Async)** Job created and processing in background. Structure matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. ```typescript { jobid: string // Job identifier verb: 'music/create' // Job verb jobType: 'music' // Job type status: 'created' // Job status created: string // ISO 8601 timestamp request: { account?: string prompt?: string model?: string async: true replyUrl?: string replyRef?: string } } ``` **Error** Error response structure (applies to both sync and async modes). ```typescript { jobid?: string // Present for job-related errors error: string // Error summary message code?: number // HTTP status code or error code msg?: string // Additional error message rawData?: string // Raw error data (if available) } ``` ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X POST https://api.useapi.net/v1/mureka/music/create \ -d '{"account": "…", "prompt": "…"}' ``` **JavaScript** ``` javascript const account = "Mureka account"; const prompt = "Silly song about Santa"; const apiUrl = `https://api.useapi.net/v1/mureka/music/create`; const api_token = "API token"; const data = { method: 'POST', headers: { 'Authorization': `Bearer ${api_token}`, 'Content-Type': 'application/json' } }; data.body = JSON.stringify({ account, prompt }); const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests account = "Mureka account" prompt = "Silly song about Santa" apiUrl = f"https://api.useapi.net/v1/mureka/music/create" api_token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {api_token}" } body = { "account": f"{account}", "prompt": f"{prompt}" } response = requests.post(apiUrl, headers=headers, json=body) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-download === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-download ## Download the song license and stems <small>March 31, 2025</small> --- > **https://api.useapi.net/v1/mureka/music/download** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json # Alternatively you can use multipart/form-data # Content-Type: multipart/form-data ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Request Body ```json { "song_id": 123456789, "type": "stem" } ``` - `song_id` is **required**. The `song_id` value returned by one of the following endpoints: * [GET /music](/docs/api-mureka-v1/get-mureka-music) * [POST /music/create](/docs/api-mureka-v1/post-mureka-music-create) * [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced) * [POST /music/create-instrumental](/docs/api-mureka-v1/post-mureka-music-create-instrumental) * [POST /music/download](/docs/api-mureka-v1/post-mureka-music-download) * [POST /music/regenerate](/docs/api-mureka-v1/post-mureka-music-regenerate) - `type` is **required**. Supported values: `stem`, `license` ##### Responses **200** **200 OK** ```json { "oss_key": "https://static-cos.mureka.ai/…zip", "paid_state": 1 } ``` **400** **400 Bad Request** ```json { "error": "<Error message>", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Wrong username/password combination.", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional oss_key: string paid_state: number } ``` ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X POST https://api.useapi.net/v1/mureka/music/download \ -d '{"song_id": …, "type": "stem"}' ``` **JavaScript** ``` javascript const song_id = 123456789; const type = "stem"; const apiUrl = `https://api.useapi.net/v1/mureka/music/download`; const api_token = "API token"; const data = { method: 'POST', headers: { 'Authorization': `Bearer ${api_token}`, 'Content-Type': 'application/json' } }; data.body = JSON.stringify({ song_id, type }); const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests song_id = 123456789 type = "stem" apiUrl = f"https://api.useapi.net/v1/mureka/music/download" api_token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {api_token}" } body = { "song_id": song_id, "type": f"{type}" } response = requests.post(apiUrl, headers=headers, json=body) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-extend === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-extend ## Extend song <small>December 13, 2024 (January 21, 2026)</small> --- > **https://api.useapi.net/v1/mureka/music/extend** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json # Alternatively you can use multipart/form-data # Content-Type: multipart/form-data ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Request Body ```json { "song_id": 123456789, "lyrics": "required lyrics to extend your original song" } ``` - `song_id` is **required**. The `song_id` value returned by one of the following endpoints: * [GET /music](/docs/api-mureka-v1/get-mureka-music) * [POST /music/create](/docs/api-mureka-v1/post-mureka-music-create) * [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced) * [POST /music/create-instrumental](/docs/api-mureka-v1/post-mureka-music-create-instrumental) * [POST /music/extend](/docs/api-mureka-v1/post-mureka-music-extend) * [POST /music/regenerate](/docs/api-mureka-v1/post-mureka-music-regenerate) - `lyrics` is **required**. Lyrics for the song extension. Maximum length: 3000 characters. - `async` is optional, enables fire-and-forget mode (default: `false`). When `true`, returns immediately with `201 Created` and job metadata. Poll [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) for completion status. Useful for avoiding long request timeouts since music generation takes 30-90 seconds. - `replyUrl` is optional, webhook URL for job status callbacks. Receives POST requests with job status updates (`created`, `completed`, `failed`). The JSON payload shape matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. - `replyRef` is optional, custom reference string passed back in webhook callbacks. Useful for tracking jobs on your end. ##### Responses **200** **200 OK** ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "feed_id": 11223344, "state": 3, "songs": [ { "song_id": "user:777-mureka:123456789-song:33445566", "title": "<title>", "version": "1...1", "is_regenerate": true, "regenerate_from": 123456, "duration_milliseconds": 234567, "generate_at": 12345677, "genres": [ "electronic", "indie" ], "moods": [ "quirky", "angry", "restless" ], "mp3_url": "https://<download link>.mp3", "share_key": "<share key>", "recall": true, "machine_audit_state": 1, "credit_type": 1, "cover": "https://<cover image>.png", "share_link": "https://<share link>" }, { "song_id": "user:777-mureka:123456789-song:33445566", "title": "<title>", "version": "1...2", "is_regenerate": true, "regenerate_from": 123456, "duration_milliseconds": 1234567, "generate_at": 12345667, "genres": [ "electronic", "world-music" ], "moods": [ "dark", "quirky", "energetic" ], "mp3_url": "https://<download link>.mp3", "share_key": "<share key>", "machine_audit_state": 1, "credit_type": 1, "cover": "https://<cover image>.png", "share_link": "https://<share link>" } ] } ``` **201** **201 Created** Job created in async mode (`async: true`). Music extension is processing in the background. Use [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) to poll for completion status. ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "verb": "music/extend", "jobType": "music", "status": "created", "created": "2026-01-20T12:34:56.789Z", "request": { "account": "12345678901234", "song_id": "user:777-mureka:123456789-song:33445566", "lyrics": "New verse lyrics here", "async": true, "replyUrl": "https://your-domain.com/webhook", "replyRef": "my-custom-ref-123" } } ``` **400** **400 Bad Request** ```json { "error": "<Error message>", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Wrong username/password combination.", "code": 401 } ``` **429** **429 Too Many Requests** * Rate limit exceeded. Endpoint called too frequently. Wait at least 3 seconds before making another call. ```json { "code": 9008, "msg": "Too frequently, please try again later." } ``` * Concurrent job limit exceeded. All job slots are taken (typically 10 concurrent generations per account). Wait at least 5 seconds before retrying. ```json { "error": "Generate multiple task exceed limit. (6323)" } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model **200 OK (Sync)** Music extension completed. Returns full song data with MP3 URLs. ```typescript { jobid: string // Job identifier (for later lookup) feed_id: number state: number songs?: { song_id: string title: string version: string is_regenerate: boolean regenerate_from: number duration_milliseconds: number generate_at: number genres: string[] moods: string[] mp3_url: string share_key: string machine_audit_state: number credit_type: number cover: string share_link: string }[] error?: string code?: number msg?: string } ``` **201 Created (Async)** Job created and processing in background. Structure matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. ```typescript { jobid: string // Job identifier verb: 'music/extend' // Job verb jobType: 'music' // Job type status: 'created' // Job status created: string // ISO 8601 timestamp request: { account?: string song_id: string lyrics: string async: true replyUrl?: string replyRef?: string } } ``` **Error** Error response structure (applies to both sync and async modes). ```typescript { jobid?: string // Present for job-related errors error: string // Error summary message code?: number // HTTP status code or error code msg?: string // Additional error message rawData?: string // Raw error data (if available) } ``` ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X POST https://api.useapi.net/v1/mureka/music/extend \ -d '{"song_id": …, "lyrics": "…"}' ``` **JavaScript** ``` javascript const song_id = 123456789; const lyrics = "place your lyrics here"; const apiUrl = `https://api.useapi.net/v1/mureka/music/extend`; const api_token = "API token"; const data = { method: 'POST', headers: { 'Authorization': `Bearer ${api_token}`, 'Content-Type': 'application/json' } }; data.body = JSON.stringify({ song_id, lyrics }); const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests song_id = 123456789 lyrics = "place your lyrics here" apiUrl = f"https://api.useapi.net/v1/mureka/music/extend" api_token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {api_token}" } body = { "song_id": song_id, "lyrics": f"{lyrics}" } response = requests.post(apiUrl, headers=headers, json=body) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-lyrics-generate === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-lyrics-generate ## Create an AI-generated lyrics based on your prompt <small>December 2, 2024 (October 3, 2025)</small> --- > **https://api.useapi.net/v1/mureka/music/lyrics-generate** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json # Alternatively you can use multipart/form-data # Content-Type: multipart/form-data ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Request Body ```json { "account": "Optional Mureka API account", "prompt": "Optional text prompt" } ``` - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple music configured, this parameter becomes **required**. - `prompt` is optional. Use it to guide AI to generate desired lyrics. If omitted AI will generate some random lyrics. ##### Responses **200** **200 OK** ```json { "lyrics": "<lyrics generated by AI based on your optional prompt>" } ``` **400** **400 Bad Request** ```json { "error": "<Error message>", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Wrong username/password combination.", "code": 401 } ``` **429** **429 Too Many Requests** Rate limit exceeded. Endpoint called too frequently. Wait at least 1 second before making another call. ```json { "code": 9008, "msg": "Too frequently, please try again later." } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional lyrics: string error?: string code?: number msg?: string } ``` ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X POST https://api.useapi.net/v1/mureka/music/lyrics-generate \ -d '{"account": "…", "prompt": "…"}' ``` **JavaScript** ``` javascript const account = "Mureka account"; const prompt = "Silly song about Santa"; const apiUrl = `https://api.useapi.net/v1/mureka/music/lyrics-generate`; const api_token = "API token"; const data = { method: 'POST', headers: { 'Authorization': `Bearer ${api_token}`, 'Content-Type': 'application/json' } }; data.body = JSON.stringify({ account, prompt }); const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests account = "Mureka account" prompt = "Silly song about Santa" apiUrl = f"https://api.useapi.net/v1/mureka/music/lyrics-generate" api_token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {api_token}" } body = { "account": f"{account}", "prompt": f"{prompt}" } response = requests.post(apiUrl, headers=headers, json=body) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-regenerate === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-regenerate ## Regenerate song <small>December 13, 2024 (January 21, 2026)</small> --- > **https://api.useapi.net/v1/mureka/music/regenerate** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json # Alternatively you can use multipart/form-data # Content-Type: multipart/form-data ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Request Body ```json { "song_id": 123456789, "start_milliseconds": 123456 } ``` - `song_id` is **required**. The `song_id` value returned by one of the following endpoints: * [GET /music](/docs/api-mureka-v1/get-mureka-music) * [POST /music/create](/docs/api-mureka-v1/post-mureka-music-create) * [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced) * [POST /music/create-instrumental](/docs/api-mureka-v1/post-mureka-music-create-instrumental) * [POST /music/extend](/docs/api-mureka-v1/post-mureka-music-extend) * [POST /music/regenerate](/docs/api-mureka-v1/post-mureka-music-regenerate) - `start_milliseconds` is **required**. Define a starting point for the extension. - `async` is optional, enables fire-and-forget mode (default: `false`). When `true`, returns immediately with `201 Created` and job metadata. Poll [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) for completion status. Useful for avoiding long request timeouts since music generation takes 30-90 seconds. - `replyUrl` is optional, webhook URL for job status callbacks. Receives POST requests with job status updates (`created`, `completed`, `failed`). The JSON payload shape matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. - `replyRef` is optional, custom reference string passed back in webhook callbacks. Useful for tracking jobs on your end. ##### Responses **200** **200 OK** ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "feed_id": 11223344, "state": 3, "songs": [ { "song_id": "user:777-mureka:123456789-song:33445566", "title": "<title>", "version": "1.1.1", "is_regenerate": true, "regenerate_from": 123456, "duration_milliseconds": 234567, "generate_at": 12345677, "genres": [ "electronic", "indie" ], "moods": [ "quirky", "angry", "restless" ], "mp3_url": "https://<download link>.mp3", "share_key": "<share key>", "recall": true, "machine_audit_state": 1, "credit_type": 1, "cover": "https://<cover image>.png", "share_link": "https://<share link>" }, { "song_id": "user:777-mureka:123456789-song:33445566", "title": "<title>", "version": "1.1.2", "is_regenerate": true, "regenerate_from": 123456, "duration_milliseconds": 1234567, "generate_at": 12345667, "genres": [ "electronic", "world-music" ], "moods": [ "dark", "quirky", "energetic" ], "mp3_url": "https://<download link>.mp3", "share_key": "<share key>", "machine_audit_state": 1, "credit_type": 1, "cover": "https://<cover image>.png", "share_link": "https://<share link>" } ] } ``` **201** **201 Created** Job created in async mode (`async: true`). Music regeneration is processing in the background. Use [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) to poll for completion status. ```json { "jobid": "j0121061432017475905m-u777-a12345678901234-bot:mureka", "verb": "music/regenerate", "jobType": "music", "status": "created", "created": "2026-01-20T12:34:56.789Z", "request": { "account": "12345678901234", "song_id": "user:777-mureka:123456789-song:33445566", "start_milliseconds": 123456, "async": true, "replyUrl": "https://your-domain.com/webhook", "replyRef": "my-custom-ref-123" } } ``` **400** **400 Bad Request** ```json { "error": "<Error message>", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Wrong username/password combination.", "code": 401 } ``` **429** **429 Too Many Requests** * Rate limit exceeded. Endpoint called too frequently. Wait at least 3 seconds before making another call. ```json { "code": 9008, "msg": "Too frequently, please try again later." } ``` * Concurrent job limit exceeded. All job slots are taken (typically 10 concurrent generations per account). Wait at least 5 seconds before retrying. ```json { "error": "Generate multiple task exceed limit. (6323)" } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model **200 OK (Sync)** Music regeneration completed. Returns full song data with MP3 URLs. ```typescript { jobid: string // Job identifier (for later lookup) feed_id: number state: number songs?: { song_id: string title: string version: string is_regenerate: boolean regenerate_from: number duration_milliseconds: number generate_at: number genres: string[] moods: string[] mp3_url: string share_key: string machine_audit_state: number credit_type: number cover: string share_link: string }[] error?: string code?: number msg?: string } ``` **201 Created (Async)** Job created and processing in background. Structure matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. ```typescript { jobid: string // Job identifier verb: 'music/regenerate' // Job verb jobType: 'music' // Job type status: 'created' // Job status created: string // ISO 8601 timestamp request: { account?: string song_id: string start_milliseconds: number async: true replyUrl?: string replyRef?: string } } ``` **Error** Error response structure (applies to both sync and async modes). ```typescript { jobid?: string // Present for job-related errors error: string // Error summary message code?: number // HTTP status code or error code msg?: string // Additional error message rawData?: string // Raw error data (if available) } ``` ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X POST https://api.useapi.net/v1/mureka/music/regenerate \ -d '{"song_id": …, "start_milliseconds": …}' ``` **JavaScript** ``` javascript const song_id = 123456789; const start_milliseconds = 123456; const apiUrl = `https://api.useapi.net/v1/mureka/music/regenerate`; const api_token = "API token"; const data = { method: 'POST', headers: { 'Authorization': `Bearer ${api_token}`, 'Content-Type': 'application/json' } }; data.body = JSON.stringify({ song_id, start_milliseconds }); const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests song_id = 123456789 start_milliseconds = 123456 apiUrl = f"https://api.useapi.net/v1/mureka/music/regenerate" api_token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {api_token}" } body = { "song_id": song_id, "lyrics": start_milliseconds } response = requests.post(apiUrl, headers=headers, json=body) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-vidoe-generate === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-music-vidoe-generate ## Create an AI-generated video for your song <small>December 2, 2024 (October 3, 2025)</small> --- > **https://api.useapi.net/v1/mureka/music/video-generate** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json # Alternatively you can use multipart/form-data # Content-Type: multipart/form-data ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Request Body ```json { "song_id": 123456789 } ``` - `song_id` is **required**. The `song_id` value returned by one of the following endpoints: * [GET /music](/docs/api-mureka-v1/get-mureka-music) * [POST /music/create](/docs/api-mureka-v1/post-mureka-music-create) * [POST /music/create-advanced](/docs/api-mureka-v1/post-mureka-music-create-advanced) ##### Responses **200** **200 OK** ```json { "video_url": "https://<download link>.mp4", "video_cover_url": "https://<cover image>.png", "video_id": 112233445566 } ``` **400** **400 Bad Request** ```json { "error": "<Error message>", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Wrong username/password combination.", "code": 401 } ``` **429** **429 Too Many Requests** * Rate limit exceeded. Endpoint called too frequently. Wait at least 3 seconds before making another call. ```json { "code": 9008, "msg": "Too frequently, please try again later." } ``` * Concurrent job limit exceeded. All job slots are taken (typically 10 concurrent generations per account). Wait at least 5 seconds before retrying. ```json { "error": "Generate multiple task exceed limit. (6323)" } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional video_url: string video_cover_url: string video_id: number error?: string code?: number msg?: string } ``` ##### Examples **Curl** ``` bash curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X POST https://api.useapi.net/v1/mureka/music/video-generate \ -d '{"song_id": …}' ``` **JavaScript** ``` javascript const song_id = 123456789; const apiUrl = `https://api.useapi.net/v1/mureka/music/video-generate`; const api_token = "API token"; const data = { method: 'POST', headers: { 'Authorization': `Bearer ${api_token}`, 'Content-Type': 'application/json' } }; data.body = JSON.stringify({ song_id }); const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests song_id = 123456789 apiUrl = f"https://api.useapi.net/v1/mureka/music/video-generate" api_token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {api_token}" } body = { "song_id": song_id } response = requests.post(apiUrl, headers=headers, json=body) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-speech-voice === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-speech-voice ## Clone voice for speech <small>August 18, 2025</small> --- This endpoint creates a custom voice clone by uploading an audio sample. The cloned voice can then be used for speech generation via [POST /speech](/docs/api-mureka-v1/post-mureka-speech). Upload clear, high-quality audio MP3 samples (10-60 seconds) for best results. Voice cloning typically takes 60-90 seconds to process. > **https://api.useapi.net/v1/mureka/speech/voice?…** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: audio/mpeg ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Query Parameters - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `title` is **required**. Voice title. Length: 1-50 characters. - `desc` is **required**. Voice description. Length: 1-500 characters. - `lang` is **required**. Language code for the voice. Supported values: `en` (English), `zh-Hans` (Simplified Chinese), `zh-Hant` (Traditional Chinese), `ja` (Japanese), `ko` (Korean), `es` (Spanish), `pt` (Portuguese), `de` (German), `fr` (French), `it` (Italian), `ru` (Russian). ##### Request Body Binary audio file content. Supported format: MP3 only (`audio/mpeg` content type). Recommended: 10-60 seconds of clear speech for optimal cloning quality. ##### Responses **200** **200 OK** ```json { "id": 12345678901234, "user_id": 23456789012345, "title": "Custom Voice", "cover": "https://static-cos.mureka.ai/cos-prod/res/cover/….png", "mp3_url": "https://static-cos.mureka.ai/cos-prod/tts-v2/….mp3", "language": "en", "created_at": 1755483687, "description": "Custom cloned voice description", "duration_milliseconds": 12520, "machine_audit_state": 1 } ``` **400** **400 Bad Request** ```json { "error": "<Error message>", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model ```typescript { // TypeScript, all fields are optional id: number user_id: number title: string cover: string mp3_url: string language: string created_at: number description: string duration_milliseconds: number machine_audit_state: number } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/speech/voice?title=CustomVoice&desc=MyVoiceDescription&lang=en" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" \ -H "Content-Type: audio/mpeg" \ --data-binary @voice_sample.mp3 ``` **JavaScript** ``` javascript const token = "API token"; const title = "Custom Voice"; const desc = "My voice description"; const lang = "en"; const fileInput = document.querySelector('input[type="file"]'); const file = fileInput.files[0]; const apiUrl = `https://api.useapi.net/v1/mureka/speech/voice?title=${title}&desc=${desc}&lang=${lang}`; const response = await fetch(apiUrl, { method: "POST", headers: { "Authorization": `Bearer ${token}`, "Content-Type": file.type, }, body: file, }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" title = "Custom Voice" desc = "My voice description" lang = "en" apiUrl = f"https://api.useapi.net/v1/mureka/speech/voice?title={title}&desc={desc}&lang={lang}" headers = { "Authorization" : f"Bearer {token}", "Content-Type": "audio/mpeg" } with open('voice_sample.mp3', 'rb') as audio_file: response = requests.post(apiUrl, headers=headers, data=audio_file.read()) print(response, response.json()) ``` === URL: https://useapi.net/docs/api-mureka-v1/post-mureka-speech === Document URL: https://useapi.net/docs/api-mureka-v1/post-mureka-speech ## Generate speech <small>August 18, 2025 (January 21, 2026)</small> --- This endpoint generates high-quality speech from text using Mureka's advanced text-to-speech technology. You can use either predefined voices or custom cloned voices created via [POST /speech/voice](/docs/api-mureka-v1/post-mureka-speech-voice). For multi-speaker conversations, use the `conversation` parameter with different voice IDs. Speech generation typically takes 20-90 seconds depending on text length. Unlike music generation endpoints, this endpoint has no rate limits or concurrent generation restrictions, allowing unlimited parallel speech generations per account. > **https://api.useapi.net/v1/mureka/speech** ##### Request Headers ``` yaml Authorization: Bearer {API token} Content-Type: application/json # Content-Type: multipart/form-data ``` - `API token` is **required**, see [Setup useapi.net](/docs/start-here/setup-useapi) for details. ##### Request Body - `account` is optional when only one [account](/docs/api-mureka-v1/get-mureka-accounts) configured. However, if you have multiple accounts configured, this parameter becomes **required**. - `title` is optional string. Maximum length is 500 characters. - `text` is required string when not using `conversation`. Must be used together with `voice_id`. Maximum text length is 5000 characters. - `voice_id` is required number when not using `conversation`. Must be used together with `text`. Get available voice IDs from [GET /speech/voices](/docs/api-mureka-v1/get-mureka-speech-voices). To create a cloned voice, first use [POST /speech/voice](/docs/api-mureka-v1/post-mureka-speech-voice) to upload an audio sample and clone the voice. - `conversation` is optional JSON string. Alternative to `text` and `voice_id`. Must be a JSON string array of objects with `voice_id` (number) and `text` (string) fields. Cannot be used together with `text` and `voice_id`. Total text length across all conversation items cannot exceed 5000 characters. Example `conversation` JSON: ```json [ {"voice_id": 12345, "text": "Hello, welcome to our service!"}, {"voice_id": 67890, "text": "Thank you for choosing us today."}, {"voice_id": 12345, "text": "Is there anything I can help you with?"} ] ``` - `async` is optional, enables fire-and-forget mode (default: `false`). When `true`, returns immediately with `201 Created` and job metadata. Poll [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) for completion status. Useful for avoiding long request timeouts since speech generation takes 20-90 seconds. - `replyUrl` is optional, webhook URL for job status callbacks. Receives POST requests with job status updates (`created`, `completed`, `failed`). The JSON payload shape matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. - `replyRef` is optional, custom reference string passed back in webhook callbacks. Useful for tracking jobs on your end. ##### Responses **200** **200 OK** ```json { "jobid": "j0121061456745673364t-u777-a12345678901234-bot:mureka", "title": "Sample Speech Title", "preview": "This is a preview of the generated speech content that demonstrates the text-to-speech capabilities.", "cover": "https://static-cos.mureka.ai/cos-prod/res/cover/….png", "mp3_url": "https://static-cos.mureka.ai/cos-prod/tts-v2/….mp3", "id": 12345678901234, "duration_milliseconds": 15000, "audio_quality": 2, "state": 3 } ``` **201** **201 Created** Job created in async mode (`async: true`). Speech generation is processing in the background. Use [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) to poll for completion status. ```json { "jobid": "j0121061456745673364t-u777-a12345678901234-bot:mureka", "verb": "speech", "jobType": "tts", "status": "created", "created": "2026-01-20T12:34:56.789Z", "request": { "account": "12345678901234", "text": "Hello, this is a sample text for speech generation.", "voice_id": 67890, "async": true, "replyUrl": "https://your-domain.com/webhook", "replyRef": "my-custom-ref-123" } } ``` **400** **400 Bad Request** ```json { "error": "<Error message>", "code": 400 } ``` **401** **401 Unauthorized** ```json { "error": "Unauthorized", "code": 401 } ``` **596** **596 Account Error** Returned when the account has an error state preventing API calls. ```json { "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" } ``` Possible error codes: - `ACCOUNT_ERROR` - Account has a blocking error - `REFRESH_FAILED` - Automatic token refresh failed - `REFRESH_IN_PROGRESS` - Token refresh already in progress, retry shortly - `SESSION_EXPIRED` - Session expired and no auto-refresh available - `COOKIE_EXPIRED` - Google cookie has expired To resolve, update your account configuration via [POST /accounts](/docs/api-mureka-v1/post-mureka-accounts). ##### Model **200 OK (Sync)** Speech generation completed. Returns full audio data with MP3 URL. ```typescript { jobid: string // Job identifier (for later lookup) title: string preview: string cover: string mp3_url: string id: number duration_milliseconds: number audio_quality: number state: number } ``` **201 Created (Async)** Job created and processing in background. Structure matches [GET /jobs/`jobid`](/docs/api-mureka-v1/get-mureka-jobs-jobid) response. ```typescript { jobid: string // Job identifier verb: 'speech' // Job verb jobType: 'tts' // Job type status: 'created' // Job status created: string // ISO 8601 timestamp request: { account?: string title?: string text?: string voice_id?: number conversation?: string async: true replyUrl?: string replyRef?: string } } ``` **Error** Error response structure (applies to both sync and async modes). ```typescript { jobid?: string // Present for job-related errors error: string // Error summary message code?: number // HTTP status code or error code rawData?: string // Raw error data (if available) } ``` ##### Examples **Curl** ``` bash curl "https://api.useapi.net/v1/mureka/speech" \ -H "Accept: application/json" \ -H "Authorization: Bearer …" \ -H "Content-Type: application/json" \ -d '{ "text": "Hello, this is a sample text for speech generation.", "voice_id": 67890 }' ``` **JavaScript** ``` javascript const token = "API token"; const apiUrl = "https://api.useapi.net/v1/mureka/speech"; const response = await fetch(apiUrl, { method: "POST", headers: { "Authorization": `Bearer ${token}`, "Content-Type": "application/json", }, body: JSON.stringify({ text: "Hello, this is a sample text for speech generation.", voice_id: 67890 }), }); const result = await response.json(); console.log("response", {response, result}); ``` **Python** ``` python import requests token = "API token" apiUrl = "https://api.useapi.net/v1/mureka/speech" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } data = { "text": "Hello, this is a sample text for speech generation.", "voice_id": 67890 } response = requests.post(apiUrl, headers=headers, json=data) print(response, response.json()) ``` === Cross-reference: General Q&A === For cross-cutting tips (rate limiting, prompt moderation, common patterns) see https://useapi.net/assets/aibot/qa.txt WARNING: Q&A items are general-purpose and may reference deprecated APIs, sunsetted services, or scenarios not applicable to the API documented above. Cross-check against this service's endpoint documentation before applying any Q&A guidance.