use axum::Json; use axum::extract::{Path, Query, State}; use jwt::extractor::AuthUser; use uuid::Uuid; use crate::error::RepoResult; use crate::features::RepoService; use crate::features::collab::{CollaboratorPage, ListCollaboratorQuery}; #[utoipa::path( get, path = "/repo/{channel_id}/{repo_id}/collaborators", tag = "repo", params(ListCollaboratorQuery), responses((status = 200, description = "List collaborators", body = CollaboratorPage)), security(("bearer_auth" = [])) )] pub(crate) async fn handler( State(svc): State, AuthUser { claims }: AuthUser, Path((_, repo_id)): Path<(Uuid, Uuid)>, Query(q): Query, ) -> RepoResult> { let page = svc .list_collaborators(claims.sub, repo_id, q.page, q.limit) .await?; Ok(Json(page)) }