> ## Documentation Index
> Fetch the complete documentation index at: https://docs.goenhance.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Suno MIDI

> Transcribe separated stems into MIDI. Run `suno-stem-split` first, then pass its `img_uuid` as `task_id`; add `audio_id` to transcribe a single stem.

**Pricing** (per request):

| Option | Tokens | USD |
|---|---|---|
| Per request | 0.1 | $0.002 |

**Result**: `json` holds two items:

- `{ "type": "midi", "value": "https://...mid" }` — a Standard MIDI File (one track per instrument, 120 BPM so note times match the audio, drums on channel 10)
- `{ "type": "json", "value": { "instruments": [{ "name": "Electric Bass (finger)", "notes": [{ "pitch": 44, "start": 7.69, "end": 7.91, "velocity": 1 }] }] } }` — the raw note data (times in seconds, velocity 0 to 1)

Works best on clean stems such as AI-generated songs; not every instrument may be detected. Result links expire (see `link_expired_at`).



## OpenAPI

````yaml api-reference/audio-generations/openapi-suno-midi.json POST /api/v1/audio/generations
openapi: 3.1.0
info:
  title: GoEnhance API - Suno MIDI
  description: Transcribe the stems of a Suno stem split into MIDI.
  version: 1.0.0
servers:
  - url: https://api.goenhance.ai
security: []
paths:
  /api/v1/audio/generations:
    post:
      tags:
        - AudioGenerations
      summary: Suno MIDI
      description: >-
        Transcribe separated stems into MIDI. Run `suno-stem-split` first, then
        pass its `img_uuid` as `task_id`; add `audio_id` to transcribe a single
        stem.


        **Pricing** (per request):


        | Option | Tokens | USD |

        |---|---|---|

        | Per request | 0.1 | $0.002 |


        **Result**: `json` holds two items:


        - `{ "type": "midi", "value": "https://...mid" }` — a Standard MIDI File
        (one track per instrument, 120 BPM so note times match the audio, drums
        on channel 10)

        - `{ "type": "json", "value": { "instruments": [{ "name": "Electric Bass
        (finger)", "notes": [{ "pitch": 44, "start": 7.69, "end": 7.91,
        "velocity": 1 }] }] } }` — the raw note data (times in seconds, velocity
        0 to 1)


        Works best on clean stems such as AI-generated songs; not every
        instrument may be detected. Result links expire (see `link_expired_at`).
      parameters:
        - name: Authorization
          in: header
          description: ''
          required: false
          example: '{{Authorization}}'
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                model:
                  type: string
                  enum:
                    - suno-midi
                  description: Model name. Must be `suno-midi`.
                task_id:
                  type: string
                  description: >-
                    Required. The `img_uuid` of one of your successful
                    `suno-stem-split` tasks. MIDI is transcribed from its
                    separated stems.
                audio_id:
                  type: string
                  description: >-
                    Optional. The `audio_id` of one stem from that task's result
                    (`json[].audio_id`) to transcribe only that stem. Omit to
                    transcribe all stems.
                custom_callback_url:
                  type: string
                  format: uri
                  description: >-
                    Optional. A publicly accessible HTTPS URL. When the task
                    status changes (processing / success / failed), GoEnhance
                    sends a POST request to this URL. The request body is
                    identical to the response of GET /api/v1/jobs/detail. If
                    your server does not respond with HTTP 200, the notification
                    is retried up to 3 times, with a 3-second timeout per
                    attempt.
                  example: https://your-server.com/goenhance/callback
              required:
                - model
                - task_id
            example:
              model: suno-midi
              task_id: 0d1502a5-53d9-4124-9026-a65de426cf98
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                  msg:
                    type: string
                  data:
                    type: object
                    properties:
                      img_uuid:
                        type: string
                      cost:
                        type: number
                        description: >-
                          Tokens deducted for this request. This is the amount
                          actually charged, so it already reflects any discount
                          active on your account and can be lower than the
                          listed price. Tokens are deducted when the task is
                          accepted, and refunded automatically if the generation
                          ends in failure.
                        example: 0.1
                    required:
                      - img_uuid
                      - cost
                required:
                  - code
                  - msg
                  - data
              examples:
                '1':
                  summary: Success
                  value:
                    code: 0
                    msg: Success
                    data:
                      img_uuid: c12b656c-747a-44fd-9c80-add79b0c52d5
                      cost: 0.1
                '2':
                  summary: Insufficient tokens
                  value:
                    code: 100
                    msg: tokens is not enough
                quota:
                  summary: API key quota exceeded
                  value:
                    code: 101
                    msg: 'API key quota exceeded: 4990 of 5000 tokens used (monthly)'
                bad:
                  summary: Invalid parameters
                  value:
                    code: -1
                    msg: >-
                      Source task 0d1502a5-... must be a suno-stem-split task
                      (model: suno-v6)
          headers: {}
        '401':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                  msg:
                    type: string
          headers: {}
      deprecated: false

````