Skip to main content
Glama

musictomidi-mcp

An MCP server (stdio transport) that lets an AI agent use the MusicToMIDI API with your API key. It starts a MIDI conversion or a stem separation from a local audio or video file, follows the job, downloads its results, lists your jobs and reads your credits, quotas and prices.

API documentation: https://musictomidi.com/developers

Glama listing: https://glama.ai/mcp/servers/julienhalgand/musictomidi-mcp

Tools

Tool

Inputs

What it does

musictomidi_convert_to_midi

file_path, model, startSeconds, endSeconds, options, stems, Idempotency-Key

Sends the local audio or video file (POST /v1/files, then PUT to the returned upload URL) and starts a MIDI conversion (POST /v1/jobs, operation: midi). Returns jobId and status at once. A file larger than 4 GB is refused before it is sent.

musictomidi_separate_stems

file_path, model (separation), startSeconds, endSeconds, stems, formats, mp3, Idempotency-Key

The same for a stem separation (operation: separation).

musictomidi_get_job

job_id, wait_seconds (0 to 50, default 0)

GET /v1/jobs/{jobId}. With wait_seconds, asks again every 3 seconds until the job is done, failed or expired, or until wait_seconds. Returns the status, progress, stage, cost and results.

musictomidi_download_result

job_id, output_dir

Downloads the result files of a done job into output_dir and returns the paths written. Never overwrites a file: a number is added to the name.

musictomidi_list_jobs

offset, limit

GET /v1/jobs: the jobs of the account, newest first.

musictomidi_get_account

none

GET /v1/account: credits and quotas.

musictomidi_get_prices

none

GET /v1/account: the price list, as the API sends it.

Models, parameters and options are those of the OpenAPI description, except tempoKey and options.timingGrid, which the tools do not expose.

With an Idempotency-Key, calling a start tool again with the same value, the same unchanged file and the same parameters does not send the file again and returns the job already started. The server remembers the files it sent for as long as it runs and the API keeps them (24 hours).

Related MCP server: strudel-ai

Configuration

Variable

MUSICTOMIDI_API_KEY

required

Your API key, created on https://musictomidi.com/developers. mtm_prod_… keys run real conversions. mtm_test_… keys use the same API, run no conversion, debit no credits and always return the same sample result.

MUSICTOMIDI_API_URL

optional

Base URL of the API. Default: https://api.musictomidi.com/v1.

Without MUSICTOMIDI_API_KEY, every tool answers with an error that tells you to create a key.

Example of an mcpServers block with npx:

{
  "mcpServers": {
    "musictomidi": {
      "command": "npx",
      "args": ["-y", "@rhiea/musictomidi-mcp"],
      "env": {
        "MUSICTOMIDI_API_KEY": "mtm_prod_…"
      }
    }
  }
}

Requires Node.js 18 or later.

Errors

Each error.code of the API comes back as a clear message, with the original code. A network error or an unexpected HTTP response comes back with the HTTP code and the first 500 characters of the body. The API key never appears in an answer or a log.

License

MIT License — see LICENSE.

Available Tools

7 tools
musictomidi_convert_to_midiA

Uploads a local audio or video file to MusicToMIDI and starts a MIDI conversion job. Returns at once, without waiting for the end of the job: jobId (give it to musictomidi_get_job to get the status, then to musictomidi_download_result to get the files) and status.

Inputs: model (required), file_path (required), stems, options, +3 more.

musictomidi_download_resultA

Saves the result files of a done MusicToMIDI job in a local folder, where musictomidi_get_job only gives their links, and returns the paths written: .mid (MIDI), .raw.mid (MIDI before filtering and quantization), .stem. (isolated voice or drums), .original. (the audio sent; with a test key, a sample and not the file sent), and each stem as .flac and/or .mp3. Never overwrites an existing file: a number is added to the name, as in song (1).mid.

Inputs: job_id (required), output_dir (required).

musictomidi_get_accountB

Returns the credits and the quotas of the MusicToMIDI account. The prices are in musictomidi_get_prices.

Inputs: no named parameters.

musictomidi_get_jobA

Returns the state of a MusicToMIDI job, without downloading anything: status (validating, starting, running, then done, failed or expired), progress, stage, cost, the results once done (links to the result files, bpm, key, duration…), the error of a failed or expired job, and testMode true for the sample job of a test key (no conversion: always the same sample files, never the file sent). While the status is validating, starting or running, call again (wait_seconds waits inside the call); once it is done, use the links of the results, or call musictomidi_download_result to save the files in a folder.

Inputs: job_id (required), wait_seconds.

musictomidi_get_pricesA

Returns the prices of the MusicToMIDI account as GET /v1/account sends them: one entry per model, with creditsPerSegment and segmentSeconds. A job costs (floor(seconds / segmentSeconds) + 1) × creditsPerSegment credits, seconds being the duration of the audio, or of the part chosen with startSeconds and endSeconds.

Inputs: no named parameters.

musictomidi_list_jobsA

Lists the jobs of the MusicToMIDI account, newest first, one page at a time: for each job its jobId, createdAt, model, cost, audioName and status (running, done, or refunded for a failed or expired job, which is not charged). A test key lists only its test jobs; open a listed job with musictomidi_get_job.

Inputs: limit, offset.

musictomidi_separate_stemsA

Uploads a local audio or video file to MusicToMIDI and starts a stem separation job, whose result is one audio file per stem. Returns at once, without waiting for the end of the job: jobId (give it to musictomidi_get_job to get the status, then to musictomidi_download_result to get the files) and status.

Inputs: model (required), file_path (required), mp3, stems, +4 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.1/5.0

    Scored across 7 tools

    Disambiguation5/5

    Each tool maps to a distinct step of the workflow: two job-creation tools with clearly different outputs (MIDI vs. stems), plus status polling, file download, listing, credits/quotas, and pricing. The only near-overlap is get_account vs. get_prices, but the descriptions make the boundary explicit (remaining credits/quotas vs. per-model cost formula).

    Naming Consistency5/5

    All seven tools use the same musictomidi_ prefix followed by a snake_case verb_noun pattern (convert_to_midi, separate_stems, get_job, download_result, list_jobs, get_account, get_prices). No convention mixing.

    Tool Count5/5

    Seven tools is well-scoped for an async conversion service: two job submitters, three job-lifecycle tools, and two account/billing tools. Nothing feels redundant or missing at the count level.

    Completeness4/5

    The full async lifecycle is covered: submit, poll, download, list history, check credits, and check pricing. Minor gaps exist, e.g. no cancel/delete job operation and no explicit pagination/cursor parameter for list_jobs, but agents can work around these.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables AI agents to create and edit Strudel music code, render offline WAV audio, and obtain structured hearing reports with waveform, spectrogram, BPM, and onset analysis.
      AGPL 3.0
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables AI agents to perform comprehensive audio processing—stem separation, analysis, transcription, restoration, speech processing, and generation—through a unified self-hosted API with asynchronous jobs and webhooks.
      6
      Do What The F*ck You Want To Public