diff --git a/docs/api.md b/docs/api.md index 2c431eb..f515af6 100644 --- a/docs/api.md +++ b/docs/api.md @@ -117,10 +117,61 @@ Meilisearch 전체 동기화 (인증 필요) --- -## 봇 상태 +## 관리자 - 봇 관리 (인증 필요) -### GET /bots -봇 상태 조회 +### GET /admin/bots +봇 목록 조회 + +**응답:** +```json +[ + { + "id": "youtube-fromis9", + "name": "fromis_9", + "type": "youtube", + "status": "running", + "last_check_at": "2026-01-18T10:30:00Z", + "last_added_count": 2, + "schedules_added": 150, + "check_interval": 2, + "error_message": null, + "enabled": true + } +] +``` + +### POST /admin/bots/:id/start +봇 시작 + +### POST /admin/bots/:id/stop +봇 정지 + +### POST /admin/bots/:id/sync-all +전체 동기화 (모든 영상/트윗 수집) + +**응답:** +```json +{ + "success": true, + "addedCount": 25, + "total": 100 +} +``` + +### GET /admin/bots/quota-warning +YouTube API 할당량 경고 조회 + +**응답:** +```json +{ + "active": true, + "message": "YouTube API 할당량 초과", + "timestamp": "2026-01-18T10:00:00Z" +} +``` + +### DELETE /admin/bots/quota-warning +할당량 경고 해제 ---