@@ -30,61 +30,71 @@ public override void Map(IEndpointRouteBuilder app)
3030
3131 // User Permission Management
3232 group . MapPost ( "/users/{userId}/grant" , this . GrantUserPermission )
33+ . WithName ( "System.GrantUserPermission" )
3334 . WithDescription ( "Grants a specific permission to a user for a specific entity." )
3435 . Produces ( ( int ) HttpStatusCode . NoContent )
3536 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . BadRequest )
3637 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . InternalServerError ) ;
3738
3839 group . MapPost ( "/users/{userId}/revoke" , this . RevokeUserPermission )
40+ . WithName ( "System.RevokeUserPermission" )
3941 . WithDescription ( "Revokes a specific permission from a user for a specific entity." )
4042 . Produces ( ( int ) HttpStatusCode . NoContent )
4143 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . BadRequest )
4244 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . InternalServerError ) ;
4345
4446 group . MapPost ( "/users/{userId}/revoke/all" , this . RevokeAllUserPermissions )
47+ . WithName ( "System.RevokeAllUserPermissions" )
4548 . WithDescription ( "Revokes all permissions from a user." )
4649 . Produces ( ( int ) HttpStatusCode . NoContent )
4750 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . BadRequest )
4851 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . InternalServerError ) ;
4952
5053 group . MapGet ( "/users/{userId}" , this . GetUserGrantedPermissions )
54+ . WithName ( "System.GetUserGrantedPermissions" )
5155 . WithDescription ( "Retrieves all granted permissions for a user for a specific entity." ) // does not take the defaults into account
5256 . Produces < IReadOnlyCollection < string > > ( )
5357 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . BadRequest )
5458 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . InternalServerError ) ;
5559
5660 group . MapGet ( "/users" , this . GetUsersGrantedPermissions )
61+ . WithName ( "System.GetUsersGrantedPermissions" )
5762 . WithDescription ( "Retrieves all granted permissions for all users for a specific entity." ) // does not take the defaults into account
5863 . Produces < IReadOnlyCollection < EntityPermissionInfo > > ( )
5964 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . BadRequest )
6065 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . InternalServerError ) ;
6166
6267 // Role Permission Management
6368 group . MapPost ( "/roles/{role}/grant" , this . GrantRolePermission )
69+ . WithName ( "System.GrantRolePermission" )
6470 . WithDescription ( "Grants a specific permission to a role for a specific entity." )
6571 . Produces ( ( int ) HttpStatusCode . NoContent )
6672 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . BadRequest )
6773 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . InternalServerError ) ;
6874
6975 group . MapPost ( "/roles/{role}/revoke" , this . RevokeRolePermission )
76+ . WithName ( "System.RevokeRolePermission" )
7077 . WithDescription ( "Revokes a specific permission from a role for a specific entity." )
7178 . Produces ( ( int ) HttpStatusCode . NoContent )
7279 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . BadRequest )
7380 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . InternalServerError ) ;
7481
7582 group . MapPost ( "/roles/{role}/revoke/all" , this . RevokeAllRolePermissions )
83+ . WithName ( "System.RevokeAllRolePermissions" )
7684 . WithDescription ( "Revokes all permissions from a role." )
7785 . Produces ( ( int ) HttpStatusCode . NoContent )
7886 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . BadRequest )
7987 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . InternalServerError ) ;
8088
8189 group . MapGet ( "/roles/{role}" , this . GetRoleGrantedPermissions )
90+ . WithName ( "System.GetRoleGrantedPermissions" )
8291 . WithDescription ( "Retrieves all granted permissions for a role for a specific entity." ) // does not take the defaults into account
8392 . Produces < IReadOnlyCollection < string > > ( )
8493 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . BadRequest )
8594 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . InternalServerError ) ;
8695
8796 group . MapGet ( "/roles" , this . GetRolesGrantedPermissions )
97+ . WithName ( "System.GetRolesGrantedPermissions" )
8898 . WithDescription ( "Retrieves all granted permissions for all roles for a specific entity." ) // does not take the defaults into account
8999 . Produces < IReadOnlyCollection < EntityPermissionInfo > > ( )
90100 . Produces < ProblemDetails > ( ( int ) HttpStatusCode . BadRequest )
0 commit comments