Initial commit: YouTube Studio Flow (backend, frontend, infrastructure, docs)
This commit is contained in:
@@ -0,0 +1,57 @@
|
||||
# Playlists API
|
||||
|
||||
Base path: `/api/v1/playlists`
|
||||
|
||||
All endpoints require `Authorization: Bearer <jwt>`.
|
||||
|
||||
Related: [[02 - Videos API]], [[04 - Database Schema]], [[10 - Quota API]]
|
||||
|
||||
---
|
||||
|
||||
## GET /playlists/channel/:channelId
|
||||
|
||||
List all playlists for a given channel.
|
||||
|
||||
**Response:** `Playlist[]`
|
||||
|
||||
---
|
||||
|
||||
## GET /playlists/video/:videoId
|
||||
|
||||
List all playlists that a specific video belongs to.
|
||||
|
||||
**Response:** `Playlist[]`
|
||||
|
||||
---
|
||||
|
||||
## POST /playlists/channel/:channelId/sync
|
||||
|
||||
Sync playlists from YouTube for the given channel, creating or updating local records to match the YouTube source.
|
||||
|
||||
**Response:**
|
||||
|
||||
```json
|
||||
{ "synced": number }
|
||||
```
|
||||
|
||||
**Cost:** Consumes YouTube API quota. See [[10 - Quota API]].
|
||||
|
||||
---
|
||||
|
||||
## POST /playlists/video/:videoId/:playlistId
|
||||
|
||||
Add a video to a playlist. Creates a `VideoPlaylist` join record.
|
||||
|
||||
**Response:** `VideoPlaylist`
|
||||
|
||||
---
|
||||
|
||||
## DELETE /playlists/video/:videoId/:playlistId
|
||||
|
||||
Remove a video from a playlist. Deletes the `VideoPlaylist` join record.
|
||||
|
||||
**Response:**
|
||||
|
||||
```json
|
||||
{ "removed": true }
|
||||
```
|
||||
Reference in New Issue
Block a user