async def add_user_to_collection(
            id: UUID = Path(
                ..., description="The unique identifier of the collection"
            ),
            user_id: UUID = Path(
                ..., description="The unique identifier of the user to add"
            ),
            auth_user=Depends(self.providers.auth.auth_wrapper()),
        ) -> WrappedBooleanResponse:
            """Add a user to a collection.

            This endpoint grants a user access to a specific collection. The
            authenticated user must have admin permissions for the collection
            to add new users.
            """
            await authorize_collection_action(
                auth_user, id, CollectionAction.MANAGE_USERS, self.services
            )

            result = await self.services.management.add_user_to_collection(
                user_id, id
            )
            return GenericBooleanResponse(success=result)  # type: ignore
Add a user to a collection.

            This endpoint grants a user access to a specific collection. The
            authenticated user must have admin permissions for the collection
            to add new users.
            
py/core/main/api/v3/collections_router.py