---
title: "Songs that sound like this song"
method: GET
path: "/songs/{song_id}/sonic-match"
tags: ["Song"]
---

# Songs that sound like this song

`GET /songs/{song_id}/sonic-match`

Similarity is derived from analysing the audio, which Ampache does not do itself, so this needs a sonic-analysis plugin (see the AudioMuse plugin). With none enabled the request is refused with 403 rather than answered with an empty list. `similarity` runs 0.0-1.0 where 1.0 is the same recording, matching the OpenSubsonic `sonicMatch` scale, and is -1 when the backend gives no comparable score.

## Path parameters

- `song_id` string, required

## Query parameters

- `limit` integer
- `offset` integer

## Response `200`

Songs that sound like this one, most similar first, each with its similarity score

- SonicMatchResponse
  - `sonic_match` SonicMatchObject[], required
    - `id` string, required
    - `title` string, nullable, required
    - `name` string, nullable, required
    - `artist` NamedReference, required
      - `id` string, required
      - `name` string, nullable, required
      - `prefix` string, nullable, required
      - `basename` string, nullable, required
    - `artists` NamedReference[], required
      - `id` string, required
      - `name` string, nullable, required
      - `prefix` string, nullable, required
      - `basename` string, nullable, required
    - `album` NamedReference, required
      - `id` string, required
      - `name` string, nullable, required
      - `prefix` string, nullable, required
      - `basename` string, nullable, required
    - `albumartist` NamedReference
      - `id` string, required
      - `name` string, nullable, required
      - `prefix` string, nullable, required
      - `basename` string, nullable, required
    - `disk` integer, required
    - `disksubtitle` string, nullable, required
    - `bpm` number, nullable, required
    - `track` integer, required
    - `filename` string, nullable, required
    - `genre` GenreReference[], required
      - `id` string, required
      - `name` string, required
    - `mood` object[], required
      - `id` string, required
      - `name` string, required
    - `playlisttrack` integer, required
    - `time` integer, required
    - `year` integer, required
    - `format` string, nullable, required
    - `stream_format` string, nullable, required
    - `bitrate` integer, nullable, required
    - `stream_bitrate` integer, nullable, required
    - `rate` integer, required
    - `mode` string, nullable, required
    - `mime` string, nullable, required
    - `stream_mime` string, nullable, required
    - `url` string, required
    - `size` integer, required
    - `mbid` string, nullable, required
    - `art` string, nullable, required
    - `has_art` boolean, required
    - `flag` boolean, required
    - `rating` integer, nullable, required
    - `averagerating` number, nullable, required
    - `playcount` integer, required
    - `last_played` string, nullable, required
    - `catalog` string, required
    - `composer` string, nullable, required
    - `channels` integer, nullable, required
    - `comment` string, nullable, required
    - `license` string, nullable, required
    - `publisher` string, nullable, required
    - `language` string, nullable, required
    - `lyrics` string, nullable, required
    - `replaygain_album_gain` number, nullable, required
    - `replaygain_album_peak` number, nullable, required
    - `replaygain_track_gain` number, nullable, required
    - `replaygain_track_peak` number, nullable, required
    - `r128_album_gain` number, nullable, required
    - `r128_track_gain` number, nullable, required
    - `metadata` object
    - `similarity` number, required — 0.0-1.0 where 1.0 is the same recording, matching the OpenSubsonic `sonicMatch` scale. -1 when the analysis backend gives no comparable score.

## Other responses

- `400` — HTTP 400 Bad Request (errors 4705, 4710).
- `401` — HTTP 401 Unauthorized (error 4701).
- `403` — HTTP 403 Forbidden (errors 4700, 4703, 4742).
- `404` — HTTP 404 Not Found (error 4704).
- `500` — HTTP 500 Internal Server Error (error 4702).

---

[API](https://skmtc.net/ampache/apis/ampache-rest-api.md) · [All operations](https://skmtc.net/ampache/apis/ampache-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/ampache/ampache-rest-api/revisions/535feee32afb/schema)
