Core • API Reference

Getting Started & Health

Connect to Unbound Music's local engine on port 45731, check status, listen to live events, and manage app preferences.

Base URL

http://127.0.0.1:45731

Response Format

Standard JSON (UTF-8)

Authentication

Local only • No API key needed

Quick Reference

MethodEndpoint
GET/api/v1/ping
GET/api/v1/health
GET/api/v1/status
SSE/api/v1/events
GET/api/v1/settings
POST/api/v1/sleeptimer/start
GET/api/v1/updater/check
GET/api/v1/ping

Quick connection check

Returns a lightweight pong response to confirm the local music service is running.

Example Request
curl "http://127.0.0.1:45731/api/v1/ping"
Example Response
{"status": "pong"}
GET/api/v1/health

Readiness check

Confirms both the local API server and storage are ready to accept requests.

Example Request
curl "http://127.0.0.1:45731/api/v1/health"
Example Response
{"healthy": true, "port": 45731}
GET/api/v1/status

App & library status

Returns version, uptime, and how many songs are currently indexed in your library.

Example Request
curl "http://127.0.0.1:45731/api/v1/status"
Example Response
{
  "status": "online",
  "version": "2.0.0",
  "uptime_seconds": 3482,
  "database": {
    "track_count": 1420
  }
}
SSE/api/v1/events

Live progress & discovery stream

Streams real-time updates such as download progress and nearby peer discovery.

Parameters

Accept(header, string)required— text/event-stream
Example Request
curl -N -H "Accept: text/event-stream" "http://127.0.0.1:45731/api/v1/events"
Example Response
event: download_progress
data: {"track_id": "5NV6RFTu24j", "percent": 64.5}
GET/api/v1/settings

Read or save app settings

GET reads saved playback quality and audio toggles; POST updates them.

Example Request
curl "http://127.0.0.1:45731/api/v1/settings"
Example Response
{
  "streaming_quality": "HIGH",
  "sponsorblock_enabled": true,
  "normalize_volume": false
}
POST/api/v1/sleeptimer/start

Start bedtime sleep timer

Fades music down gently after the chosen minutes or at the end of the current song.

Example Request
curl -X POST -H "Content-Type: application/json" -d '{"minutes": 30, "end_of_song": false}' "http://127.0.0.1:45731/api/v1/sleeptimer/start"
Example Response
{"active": true, "remaining_ms": 1800000}
GET/api/v1/updater/check

Check for app updates

Checks whether a newer release of Unbound Music is available.

Example Request
curl "http://127.0.0.1:45731/api/v1/updater/check"
Example Response
{"has_update": false, "current_version": "2.0.0", "latest_version": "2.0.0"}