From 9ecfa9ed40dc526327245fb69e7bb33a269195f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=A5=D0=BE=D0=BC=D1=8F=D1=87=D0=BE=D0=BA?= Date: Thu, 5 Mar 2026 22:01:15 +0000 Subject: [PATCH] =?UTF-8?q?=D0=9E=D0=B1=D0=BD=D0=BE=D0=B2=D0=B8=D1=82?= =?UTF-8?q?=D1=8C=20Home?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Home.md | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) diff --git a/Home.md b/Home.md index 683cf99..bb98399 100644 --- a/Home.md +++ b/Home.md @@ -1 +1,87 @@ # Добро пожаловать в вики Muza API. + +## Быстрый старт + +```bash +deno run --allow-net --allow-env --allow-read mod.ts +``` + +сервер будет запущен по адресу `http://localhost:8000` + +## API эндпоинты + +### Поиск + +| Эндпоинт | Описание | +|----------|-------------| +| `/api/search?q=&filter=` | Search YouTube Music (songs/albums/artists) | +| `/api/yt_search?q=&filter=` | Search YouTube (videos/channels/playlists) | +| `/api/search/suggestions?q=` | Autocomplete suggestions | + +### Контент + +| Эндпоинт | Описание | +|----------|-------------| +| `/api/songs/:videoId` | Song details with artist/album links | +| `/api/albums/:browseId` | Album with tracks and artist | +| `/api/artists/:browseId` | Artist with discography | +| `/api/playlists/:playlistId` | Playlist tracks | +| `/api/chain/:videoId` | Full chain: Song → Artist → Albums | + +### Обзор + +| Эндпоинт | Описание | +|----------|-------------| +| `/api/related/:videoId` | Related songs | +| `/api/radio?videoId=` | Generate radio mix | +| `/api/similar?title=&artist=` | Similar tracks | +| `/api/charts?country=` | Music charts | +| `/api/trending?country=` | Trending music | +| `/api/moods` | Mood categories | +| `/api/top/artists?country=` | Top artists | +| `/api/top/tracks?country=` | Top tracks | + +### Стриминг & Лирика + +| Endpoint | Description | +|----------|-------------| +| `/api/stream?id=` | Audio stream URLs | +| `/api/proxy?url=` | Audio proxy (CORS bypass) | +| `/api/lyrics?title=&artist=` | Synced lyrics (LRC) | + +### Инфо + +| Endpoint | Description | +|----------|-------------| +| `/api/artist/info?artist=` | Artist bio (Last.fm) | +| `/api/track/info?title=&artist=` | Track info (Last.fm) | + +## Примеры + +```bash +# Поиск песен +curl "https://verome-api.deno.dev/api/search?q=Blinding%20Lights&filter=songs" + +# Получение текста песен +curl "https://verome-api.deno.dev/api/lyrics?title=Blinding%20Lights&artist=The%20Weeknd" + +# URL стрима +curl "https://verome-api.deno.dev/api/stream?id=4NRXx6U8ABQ" + +# Radio mix +curl "https://verome-api.deno.dev/api/radio?videoId=4NRXx6U8ABQ" +``` + +## Структура проекта + +``` +mod.ts - Server and routes +lib.ts - API clients (YT Music, YouTube, Last.fm, LRCLib) +ui.ts - Web UI +assets/ - Logo +``` + +## Деплой +```bash +deployctl deploy --project=verome-api --prod mod.ts +``` \ No newline at end of file