add sns endpoint

This commit is contained in:
Dohyun Lim committed 2026-02-02 10:36:42 +09:00
1 parent 18b18e9ff2
commit 19bd12d581
22 files changed
+106 -1

No files matched your search

+14 -1
View File
@@ -16,6 +16,7 @@ from app.home.api.routers.v1.home import router as home_router
from app.user.api.routers.v1.auth import router as auth_router, test_router as auth_test_router
from app.lyric.api.routers.v1.lyric import router as lyric_router
from app.song.api.routers.v1.song import router as song_router
from app.sns.api.routers.v1.sns import router as sns_router
from app.video.api.routers.v1.video import router as video_router
from app.utils.cors import CustomCORSMiddleware
from config import prj_settings
@@ -151,6 +152,17 @@ tags_metadata = [
- created_at 기준 내림차순 정렬됩니다.
- 삭제는 소프트 삭제(is_deleted=True) 방식으로 처리되며, 데이터 복구가 가능합니다.
- 삭제 대상: Video, SongTimestamp, Song, Lyric, Image, Project
""",
},
{
"name": "SNS",
"description": """SNS 업로드 API - Instagram Graph API
**인증: 필요** - `Authorization: Bearer {access_token}` 헤더 필수
## 주요 기능
- `GET /sns/instagram/upload/{task_id}` - Instagram 업로드 상태 조회
""",
},
]
@@ -226,7 +238,7 @@ def custom_openapi():
if method in ["get", "post", "put", "patch", "delete"]:
# 공개 엔드포인트가 아닌 경우 인증 필요
is_public = any(public_path in path for public_path in public_endpoints)
if not is_public and path.startswith("/api/"):
if not is_public:
operation["security"] = [{"BearerAuth": []}]
app.openapi_schema = openapi_schema
@@ -267,6 +279,7 @@ app.include_router(lyric_router)
app.include_router(song_router)
app.include_router(video_router)
app.include_router(archive_router) # Archive API 라우터 추가
app.include_router(sns_router) # SNS API 라우터 추가
# DEBUG 모드에서만 테스트 라우터 등록
if prj_settings.DEBUG: