{
  "openapi": "3.0.1",
  "info": {
    "title": "Sheet Music Renderer: ABC, MusicXML, LilyPond & MIDI to PDF",
    "description": "Turn ABC notation, MusicXML, LilyPond, MEI, Humdrum or MIDI into sheet music (PDF, PNG or SVG pages), MIDI and MP3 audio. Transpose, change the page size or playback instrument, render whole tunebooks, and get errors with line numbers that people and AI agents can fix.",
    "version": "0.1",
    "x-build-id": "CzjXxJ8RHbZN7VVic"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/jumblemog~sheet-music-renderer/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-jumblemog-sheet-music-renderer",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/jumblemog~sheet-music-renderer/runs": {
      "post": {
        "operationId": "runs-sync-jumblemog-sheet-music-renderer",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/jumblemog~sheet-music-renderer/run-sync": {
      "post": {
        "operationId": "run-sync-jumblemog-sheet-music-renderer",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "notation": {
            "title": "Score",
            "type": "string",
            "description": "One score as text: ABC notation (X:, T:, K: lines, any number of voices and tunes), MusicXML, LilyPond, MEI or Humdrum **kern. The notation is recognized automatically, or set it in Input format."
          },
          "scoreUrls": {
            "title": "Links to scores",
            "type": "array",
            "description": "Links to score files: .abc, .musicxml, .xml, .mxl (compressed MusicXML, as exported by MuseScore, Finale, Sibelius or Dorico), .ly, .mei, .krn and .mid or .midi. GitHub file pages, Google Drive and Dropbox share links work, and ZIP archives of LilyPond projects too.",
            "items": {
              "type": "string"
            }
          },
          "uploads": {
            "title": "Upload scores",
            "type": "array",
            "description": "Upload score files or ZIP archives from your computer, or pick files you already stored in an Apify key-value store."
          },
          "outputs": {
            "title": "What to make",
            "type": "array",
            "description": "Any mix of sheet music (PDF, PNG and SVG pages), MIDI and audio. The price per score is the same whatever you pick.",
            "items": {
              "type": "string",
              "enum": [
                "pdf",
                "png",
                "svg",
                "midi",
                "mp3",
                "wav"
              ],
              "enumTitles": [
                "PDF sheet music",
                "PNG images (one per page)",
                "SVG images (one per page)",
                "MIDI file",
                "MP3 audio",
                "WAV audio"
              ]
            },
            "default": [
              "pdf",
              "png",
              "midi",
              "mp3"
            ]
          },
          "transpose": {
            "title": "Transpose",
            "type": "string",
            "description": "Move the music up or down: semitones such as 2 or -3, or an interval such as M2 (a whole step up), -m3 or P5. For MusicXML, MEI, Humdrum and MIDI a target key also works, such as Bb or F#. Notation and audio both change. Empty: as written."
          },
          "instrument": {
            "title": "Playback instrument",
            "enum": [
              "",
              "piano",
              "electric-piano",
              "harpsichord",
              "organ",
              "accordion",
              "harmonica",
              "nylon-guitar",
              "guitar",
              "electric-guitar",
              "acoustic-bass",
              "violin",
              "viola",
              "cello",
              "contrabass",
              "harp",
              "strings",
              "choir",
              "trumpet",
              "trombone",
              "tuba",
              "french-horn",
              "brass",
              "soprano-sax",
              "alto-sax",
              "tenor-sax",
              "oboe",
              "bassoon",
              "clarinet",
              "piccolo",
              "flute",
              "recorder",
              "pan-flute",
              "ocarina",
              "marimba",
              "vibraphone",
              "xylophone",
              "glockenspiel",
              "music-box",
              "celesta",
              "kalimba",
              "banjo",
              "sitar",
              "bagpipe",
              "fiddle",
              "steel-drums",
              "synth-pad"
            ],
            "type": "string",
            "description": "The General MIDI instrument for the MIDI file and the audio. Drum parts keep their drums.",
            "default": ""
          },
          "tempo": {
            "title": "Playback tempo (beats per minute)",
            "minimum": 0,
            "maximum": 400,
            "type": "integer",
            "description": "Play the MIDI and audio at this tempo, for example 60 to practise slowly. Empty or 0: the tempo in the score."
          },
          "pageSize": {
            "title": "Page size",
            "enum": [
              "a4",
              "letter",
              "a4-landscape",
              "letter-landscape"
            ],
            "type": "string",
            "description": "The paper size of PDF pages.",
            "default": "a4"
          },
          "layout": {
            "title": "Layout",
            "enum": [
              "pages",
              "cropped",
              "single-line"
            ],
            "type": "string",
            "description": "Whole pages, or pages trimmed to the height of the music, which suits images. One long line puts all the music on a single line.",
            "default": "pages"
          },
          "staffSize": {
            "title": "Staff size (%)",
            "minimum": 30,
            "maximum": 300,
            "type": "integer",
            "description": "Make the music bigger or smaller on the page. 100 is a usual printed size; try 130 for beginners or large print, 75 to fit more on a page.",
            "default": 100
          },
          "ppi": {
            "title": "PNG resolution (pixels per inch)",
            "minimum": 36,
            "maximum": 600,
            "type": "integer",
            "description": "Resolution of PNG images. 150 is sharp on screens; use 300 for print.",
            "default": 150
          },
          "inputFormat": {
            "title": "Input format",
            "enum": [
              "auto",
              "abc",
              "musicxml",
              "lilypond",
              "mei",
              "humdrum",
              "midi"
            ],
            "type": "string",
            "description": "The notation of the scores, when automatic recognition gets it wrong.",
            "default": "auto"
          },
          "scores": {
            "title": "More scores (batch)",
            "type": "array",
            "description": "A list of scores to render in the same run. Each entry is notation text, or an object with \"notation\" or \"url\" and optional \"name\", \"inputFormat\", \"transpose\", \"instrument\", \"tempo\" and \"mainFile\", for example [{\"url\": \"https://example.com/tune.abc\", \"transpose\": \"-2\", \"name\": \"tune-in-bb\"}]."
          },
          "mainFile": {
            "title": "Main file in ZIP archives",
            "type": "string",
            "description": "The main score inside a ZIP archive, such as score.ly or src/main.ly. Empty: found automatically (main.ly or score.ly first, then the score file nearest the top)."
          },
          "renderTimeoutSecs": {
            "title": "Time limit per score (seconds)",
            "minimum": 5,
            "maximum": 600,
            "type": "integer",
            "description": "Stop engraving a score after this many seconds. Most scores take a second or two.",
            "default": 60
          },
          "maxScores": {
            "title": "Maximum scores",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Stop after this many scores, so the cost of a run stays predictable.",
            "default": 100
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}