Back to Journal
November 26, 2026
Developers & API

Sheet Music OCR API: Convert Images to MusicXML (Hosted and Open-Source Options)

Sheet Music OCR API: Convert Images to MusicXML (Hosted and Open-Source Options)

Optical music recognition (OMR) reads a picture of printed notation and produces notes a program can use, usually MusicXML. If you are building an app that has to understand scores, you have two broad choices: call a hosted API, or run an open-source engine yourself. This guide compares the real options as of late 2026 and shows how to use ScoreFlip's scanning endpoint.

We build ScoreFlip, so we say where the alternatives fit better. Always check each project's own documentation for current limits and terms.

The options

OptionTypeNotes
ScoreFlip scan APIHosted, pay per pageOne printed page per request, image in, MusicXML out. Also available as an MCP tool.
Flat OMR APIHostedDocumented in Flat's developer docs; accepts PDFs and photos and can return MusicXML or MIDI. Fits you best if you are already building on Flat's score editor.
AudiverisOpen source, desktop and JavaMature engine for printed scores to MusicXML. You host and operate it. Printed music only.
oemerOpen source, PythonImage to MusicXML from a command line. Its own docs describe multi-minute runs on a GPU, so plan for batch jobs.
homrOpen source, PythonAimed at camera photos of sheet music. Needs a Python environment and optionally a GPU.

Rule of thumb: self-host if you scan large volumes and have the engineering time; use a hosted API if you want a working result today without running GPUs or tuning models.

ScoreFlip scan API in one request

bash
curl -X POST https://api.scoreflipml.roovemusic.com/v1/scans \
  -H "Authorization: Bearer $SCOREFLIP_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://example.com/page-1.jpg", "max_credits": 20}'

Then poll and download exactly as with any job:

bash
curl https://api.scoreflipml.roovemusic.com/v1/jobs/JOB_ID \
  -H "Authorization: Bearer $SCOREFLIP_API_KEY"

curl "https://api.scoreflipml.roovemusic.com/v1/jobs/JOB_ID/result?format=musicxml" \
  -H "Authorization: Bearer $SCOREFLIP_API_KEY" -o page-1.musicxml

Details that matter:

  • One page per request. Send PNG, JPEG, WebP or TIFF images. PDFs are not supported by the API yet, so split a PDF into page images first.
  • Charged per page, refunded automatically if the job fails. Live rates are at the public pricing endpoint.
  • Prepaid, no free tier. Credits never expire. Create keys under Settings → Developer API in the app.
  • Spending cap. Pass max_credits so a bug cannot overspend.

Getting good scans

Recognition quality depends mostly on the image:

  • Photograph straight on, under even light, with all five staff lines visible edge to edge.
  • Avoid shadows across the staves and curled page edges.
  • Keep resolution high enough that note heads are crisp.

We wrote a longer checklist in taking better photos of sheet music. If a result still has wrong notes, see how to fix wrong notes in a scanned score.

What to do with the MusicXML

MusicXML opens in MuseScore, Finale, Sibelius and Dorico, and libraries such as music21 (Python) and OpenSheetMusicDisplay (browser) can read or render it. Typical pipelines: scan, then transpose, extract chords, check ranges for a student, or render in the browser.

Calling it from an AI assistant

The same capability is exposed as the scan_sheet_music tool on ScoreFlip's MCP server, so Claude, Cursor and other agents can read a score image directly.

Next steps

Enjoyed this deep dive?

Explore more articles on notation scanning, electric keyboards, and gamified music practice in our journal.

Explore All Articles