Every route of the music app backend. The Jamendo catalogue is mirrored into
SQLite and audio is cached on disk, so the app talks to one host with one response shape.
Base URL
https://music.cloudrx.cyou
All app routes live under /v1. /health, /stats and
/openapi.json sit at the root.
meta carries limit, offset, total,
cached and sometimes stale.
Auth
authorization: Bearer <token>
Get a token from /v1/auth/guest, /v1/auth/register or
/v1/auth/login. Tokens last 90 days; /v1/auth/logout revokes all of them.
Paging
?limit=20&offset=0
limit is capped at 100. meta.total is the upstream count when Jamendo
reports one.
Caching
x-cache: HIT | MISS
Lists 30 min, details 6 h, genres 7 d, audio 30 d on disk, artwork 60 d on disk.
A stale entry is served if Jamendo fails.
Errors
400 bad_request bad parameter
401 unauthorized missing or stale token
404 not_found unknown id or licence blocks download
429 rate_limited client is too fast
502 upstream_error Jamendo refused or track has no audio
503 unavailable upstream cooling down after a 429
Every error body has the same error.code machine name.
Quick start
# browse
curl -s 'https://music.cloudrx.cyou/v1/home' | head -c 400
# guest session, then save a favourite
TOKEN=$(curl -s -X POST 'https://music.cloudrx.cyou/v1/auth/guest' \
-H 'content-type: application/json' \
-d '{"deviceId":"android-7f3c9a12b4"}' | node -pe 'JSON.parse(require("fs").readFileSync(0)).data.token')
curl -s -X POST 'https://music.cloudrx.cyou/v1/me/favorites' \
-H "authorization: Bearer $TOKEN" -H 'content-type: application/json' \
-d '{"trackId":"168"}'
# stream with seeking
curl -s -H 'range: bytes=0-1023' 'https://music.cloudrx.cyou/v1/stream/168' -o chunk.mp3
Catalog
Read-only browsing and search over the Jamendo catalogue, normalised to a single track shape.
GET/v1/homerunnable here
Everything the home screen needs, in one call
Trending this week, newest releases, a chillout shelf, the genre list and the radios, fetched in parallel. When one of the four upstream calls fails the answer is still 200 with partial: true, and that variant is cached for 2 minutes instead of 30.
Every filter maps to a Jamendo parameter. Up to 4 tags combine with + or a comma. Tracks carry musicinfo tags, so genre chips render without a second call.
Jamendo ignores limit and offset here and returns an empty page for any non-zero offset, so the whole collection is fetched once, cached, and paged locally.
Audio, artwork and radio. Streaming supports Range, so the player can seek without downloading the whole file.
GET/v1/stream/:id
Audio stream with Range support
Proxied on the first play, then served from disk. Send a Range header to seek: the answer is 206 with Content-Range. X-Cache is MISS on the first hit and HIT once the file is stored, X-Audio-Format names the format actually served. Jamendo signed URLs expire and some tracks lack the requested format, so the server walks mp32 to mp31 to ogg before giving up; a track with no playable file answers 502 upstream_error.
HTTP/1.1 200 OK
content-type: audio/mpeg
icy-name: Best Of Jamendo Radio
<endless audio stream>
GET/v1/img
Cached artwork proxy
Only the Jamendo artwork hosts are allowed (usercontent.jamendo.com, images.jamendo.com, img.jamendo.com), https only, no credentials in the URL. Files live on disk for 60 days and are answered with a strong ETag, so repeat requests get 304.
Call it on first launch with a stable device id: the same id always returns the same guest account, so the library survives app restarts. Letters, digits, dot, underscore, colon and dash are allowed, 8 to 128 characters.
Builds a tag profile from favourites and recent plays, pulls matching tracks, tops up from the same artists, then from the weekly chart. Cached 20 minutes per user.