feat: stabilize social backend contracts

This commit is contained in:
boutmoun123
2026-05-31 16:13:23 +03:00
parent ad6da6754d
commit 49e132909e
40 changed files with 12037 additions and 9562 deletions
@@ -4,7 +4,8 @@
"notes": [
"This dashboard must authenticate with /auth/superadmin/* routes only.",
"User-only routes are not a valid contract for this dashboard unless they have a dedicated /admin or /superadmin variant.",
"The dashboard proxy should target the Nest backend API base URL defined in .env.local."
"The dashboard proxy should target the Nest backend API base URL defined in .env.local.",
"Mobile-facing routes are mirrored here for frontend contract visibility, but normal user routes require a normal user access token when called from Flutter."
],
"modules": {
"auth": [
@@ -15,6 +16,22 @@
"POST /auth/superadmin/sessions/:sessionId/revoke"
],
"users": [
"PATCH /users/me/profile-setup",
"PATCH /users/me/music-setup",
"PATCH /users/me",
"GET /users",
"GET /users/discover",
"GET /users/:userId",
"GET /users/:userId/presence",
"GET /users/:userId/profile-overview",
"GET /users/:userId/posts",
"POST /users/:userId/follow",
"DELETE /users/:userId/follow",
"GET /users/:userId/follow-status",
"GET /users/:userId/followers",
"GET /users/:userId/following",
"GET /users/me/followers",
"GET /users/me/following",
"GET /users/admin",
"GET /users/admin/admins",
"GET /users/admin/:userId",
@@ -31,6 +48,23 @@
"PATCH /superadmin/users/:userId/status"
],
"posts": [
"POST /posts",
"POST /posts/reels",
"GET /posts/reels",
"GET /posts/:postId",
"GET /posts/user/:userId",
"PATCH /posts/:postId",
"POST /posts/:postId/repost",
"PATCH /posts/:postId/comment-settings",
"PATCH /posts/:postId/pin-profile",
"PATCH /posts/:postId/unpin-profile",
"PATCH /posts/:postId/archive",
"PATCH /posts/:postId/restore-archive",
"DELETE /posts/:postId",
"POST /posts/:postId/view",
"POST /posts/:postId/play",
"POST /posts/:postId/share",
"POST /posts/:postId/collaboration-requests",
"GET /posts/admin/moderation",
"DELETE /posts/admin/:postId",
"PATCH /superadmin/posts/:postId/status"
@@ -41,8 +75,32 @@
"PATCH /superadmin/comments/:commentId/status"
],
"notifications": [
"GET /notifications",
"GET /notifications/unread-count",
"PATCH /notifications/:notificationId/read",
"PATCH /notifications/read-all",
"GET /notifications/superadmin"
],
"follows": [
"POST /follows/toggle",
"GET /follows/followers/:userId",
"GET /follows/following/:userId",
"GET /follows/status/:targetUserId",
"GET /follows/suggestions",
"GET /follows/requests",
"PATCH /follows/requests/:requestId/approve",
"PATCH /follows/requests/:requestId/reject"
],
"devices": [
"POST /devices/register",
"POST /devices/unregister"
],
"collaborationRequests": [
"POST /posts/:postId/collaboration-requests",
"GET /collaboration-requests",
"PATCH /collaboration-requests/:requestId/approve",
"PATCH /collaboration-requests/:requestId/reject"
],
"marketplace": [
"GET /marketplace/home",
"GET /marketplace/listings",