Skip to content
paul-wtfPublic

About

Self-hosted music-link converter across Spotify, Deezer, Tidal and YouTube Music — FastAPI backend, SvelteKit frontend, Helm chart included

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

linkhop

Music-link converter across streaming services. Paste a track, album or artist link from one service, get the equivalent on every other one.

Live at https://linkhop.paul.wtf

Similar in spirit to Odesli / song.link, but self-hosted, Kubernetes-native and without trackers — match quality is boosted by preferring industry identifiers (ISRC for tracks, UPC for albums) over fuzzy metadata search.

Supported services

Service Tracks Albums Artists Notes
Spotify ✓ ✓ ✓ OAuth client credentials
Deezer ✓ ✓ ✓ No credentials needed
Tidal ✓ ✓ ✓ OAuth client credentials
YouTube Music ✓ ✓ ✓ ytmusicapi, unofficial
Apple Music ✓ ✓ ✓ iTunes Search API, free

Playlists are out of scope for V1.

Note: conversions towards Apple Music match albums via UPC, but tracks always use metadata matching — the iTunes API's ISRC lookup returns no results in practice. Conversions from Apple Music always use metadata matching, since iTunes responses contain no ISRC/UPC.

Features

  • Bidirectional conversion between all supported services
  • ISRC / UPC matching for high-quality results; metadata fallback with a confidence score exposed via the API
  • Shareable short links (/c/<id>), persisted in Postgres — the link lands on a rendered result page, not a JSON endpoint
  • Search by text when there is no link at hand: type a title, pick a result, get it on every service
  • Link previews for short links: chat apps show title, artists, cover and the services the item was found on
  • Redis cache for resolved links (default 7 d TTL)
  • Rate-limiting per IP or per API key, each independently configurable
  • OpenAPI docs served at /api/v1/docs, Swagger UI
  • Your own service first: pick the service you listen on once, and its match moves to the top with a button that opens it; share pages can forward there on their own
  • 30 second preview on the cover where Apple Music has one, and a note which title an uncertain match found
  • QR code and system share sheet for short links, and a counter of how often a short link was opened
  • Installable, and on Android a share target: "Share" in a music app lists linkhop and converts the link right away (iOS has no share targets for web apps; a Shortcut that opens https://<host>/?url=<input> does the same)
  • Discord commands: /linkhop <link> and a message command, answered by the backend itself (see backend/README.md)
  • German and English interface, chosen from the browser language with a manual override
  • Catppuccin Mocha / Latte theme with prefers-color-scheme auto-detect and a manual toggle
  • Progressive enhancement: ?url= query parameter triggers an immediate conversion, and an OpenSearch description lets browsers add the site as a search engine

Stack

Layer Tech
Backend Python 3.12 (uv-managed), FastAPI, SQLAlchemy 2 (async), asyncpg, Alembic
Frontend SvelteKit (adapter-static), TypeScript, Vite
Cache Redis 7
Database Postgres 16 (CNPG in production)
Tests pytest, Playwright (E2E), Vitest (components)
Packaging Docker images, Helm chart (with Redis sub-chart)
Deployment FluxCD → RKE2 + Traefik + cert-manager + external-dns

Quick start (local dev)

Backend (needs uv; Python 3.12 is resolved via backend/.python-version):

cd backend
uv sync
docker-compose up -d               # Postgres + Redis only
uv run alembic upgrade head
uv run uvicorn linkhop.main:app --reload --port 8080

Frontend (needs Node 22.17+ + pnpm):

cd frontend
pnpm install
pnpm gen:api                       # generate typed client from backend OpenAPI
pnpm dev                           # http://localhost:5173, proxied /api → :8080

Then open http://localhost:5173 and paste a Deezer track URL (Deezer, YouTube Music and Apple Music work without credentials; Spotify/Tidal need client credentials via env vars — see backend/README.md).

See backend/README.md for the full env-var reference, admin CLI (linkhop-admin key create|list|revoke) and live-integration test setup.

API (quick reference)

All endpoints under /api/v1. Full schema at /api/v1/docs.

Method Path Purpose
GET /convert?url=... Resolve a link; optional ?share=true returns a short-id
GET /search?q=... Find tracks, albums and artists by text (Deezer, or Apple Music if Deezer is off)
GET /c/{short_id} JSON lookup for a short-id (frontend renders /c/{id})
GET /services Enabled services with display metadata
GET /health Liveness + readiness (Redis, Postgres)
GET /opensearch.xml OpenSearch description, so browsers offer linkhop as a search engine
GET /docs Swagger UI
GET /openapi.json OpenAPI schema

Deployment

A Helm chart is released on every linkhop-<version> git tag via helm/chart-releaser-action and served from GitHub Pages:

helm repo add linkhop https://paul-wtf.github.io/linkhop
helm install linkhop linkhop/linkhop --namespace linkhop --create-namespace

Container images are published to GHCR on every v<version> release:

  • ghcr.io/paul-wtf/linkhop-backend:<version>
  • ghcr.io/paul-wtf/linkhop-frontend:<version>

The chart expects credentials via an existingSecret so secrets can be managed by your tool of choice (External Secrets Operator, sealed-secrets, sops, plain kubectl). Required keys: LINKHOP_DATABASE_URL, LINKHOP_REDIS_URL, LINKHOP_SPOTIFY_CLIENT_ID/_SECRET, LINKHOP_TIDAL_CLIENT_ID/_SECRET.

See helm/linkhop/ for chart values and templates, and docs/superpowers/specs/2026-04-21-helm-chart-design.md for the design rationale.

Design docs

License

No license file yet — treat the code as "all rights reserved" until one lands. Open an issue if you need a permissive grant.

About

Self-hosted music-link converter across Spotify, Deezer, Tidal and YouTube Music — FastAPI backend, SvelteKit frontend, Helm chart included

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages