Class PolarisPrincipalsApi

java.lang.Object
org.apache.polaris.service.admin.api.PolarisPrincipalsApi

@Path("/api/management/v1/principals") @Generated(value="org.openapitools.codegen.languages.JavaResteasyServerCodegen", date="2025-12-29T15:11:10.836467545Z[UTC]", comments="Generator version: 7.12.0") public class PolarisPrincipalsApi extends Object
The principals API interface This file is automatically generated by the OpenAPI Code Generator based on configuration in the build.gradle file.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    jakarta.ws.rs.core.Response
    assignPrincipalRole(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, @Valid org.apache.polaris.core.admin.model.GrantPrincipalRoleRequest grantPrincipalRoleRequest, org.apache.polaris.core.context.RealmContext realmContext, jakarta.ws.rs.core.SecurityContext securityContext)
    Add a role to the principal Response type: Void.
    jakarta.ws.rs.core.Response
    createPrincipal(@Valid org.apache.polaris.core.admin.model.CreatePrincipalRequest createPrincipalRequest, org.apache.polaris.core.context.RealmContext realmContext, jakarta.ws.rs.core.SecurityContext securityContext)
    Create a principal Response type: PrincipalWithCredentials.
    jakarta.ws.rs.core.Response
    deletePrincipal(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, org.apache.polaris.core.context.RealmContext realmContext, jakarta.ws.rs.core.SecurityContext securityContext)
    Remove a principal from polaris Response type: Void.
    jakarta.ws.rs.core.Response
    getPrincipal(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, org.apache.polaris.core.context.RealmContext realmContext, jakarta.ws.rs.core.SecurityContext securityContext)
    Get the principal details Response type: Principal.
    jakarta.ws.rs.core.Response
    listPrincipalRolesAssigned(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, org.apache.polaris.core.context.RealmContext realmContext, jakarta.ws.rs.core.SecurityContext securityContext)
    List the roles assigned to the principal Response type: PrincipalRoles.
    jakarta.ws.rs.core.Response
    listPrincipals(org.apache.polaris.core.context.RealmContext realmContext, jakarta.ws.rs.core.SecurityContext securityContext)
    List the principals for the current catalog Response type: Principals.
    jakarta.ws.rs.core.Response
    revokePrincipalRole(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, @Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalRoleName, org.apache.polaris.core.context.RealmContext realmContext, jakarta.ws.rs.core.SecurityContext securityContext)
    Remove a role from a catalog principal Response type: Void.
    jakarta.ws.rs.core.Response
    rotateCredentials(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, org.apache.polaris.core.context.RealmContext realmContext, jakarta.ws.rs.core.SecurityContext securityContext)
    Rotate a principal's credentials.
    jakarta.ws.rs.core.Response
    updatePrincipal(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, @Valid org.apache.polaris.core.admin.model.UpdatePrincipalRequest updatePrincipalRequest, org.apache.polaris.core.context.RealmContext realmContext, jakarta.ws.rs.core.SecurityContext securityContext)
    Update an existing principal Response type: Principal.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • assignPrincipalRole

      @PUT @Path("/{principalName}/principal-roles") @Consumes("application/json") @RolesAllowed("**") @Timeout public jakarta.ws.rs.core.Response assignPrincipalRole(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) @PathParam("principalName") @Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, @Nonnull @Valid @Valid org.apache.polaris.core.admin.model.GrantPrincipalRoleRequest grantPrincipalRoleRequest, @Context org.apache.polaris.core.context.RealmContext realmContext, @Context jakarta.ws.rs.core.SecurityContext securityContext)
      Add a role to the principal Response type: Void.
      Parameters:
      principalName - Required - The name of the target principal
      grantPrincipalRoleRequest - Required - The principal role to assign
      Returns:
      201 - Successful response
    • createPrincipal

      @POST @Consumes("application/json") @Produces("application/json") @RolesAllowed("**") @Timeout public jakarta.ws.rs.core.Response createPrincipal(@Nonnull @Valid @Valid org.apache.polaris.core.admin.model.CreatePrincipalRequest createPrincipalRequest, @Context org.apache.polaris.core.context.RealmContext realmContext, @Context jakarta.ws.rs.core.SecurityContext securityContext)
      Create a principal Response type: PrincipalWithCredentials.
      Parameters:
      createPrincipalRequest - Required - The principal to create
      Returns:
      201 - Successful response
    • deletePrincipal

      @DELETE @Path("/{principalName}") @RolesAllowed("**") @Timeout public jakarta.ws.rs.core.Response deletePrincipal(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) @PathParam("principalName") @Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, @Context org.apache.polaris.core.context.RealmContext realmContext, @Context jakarta.ws.rs.core.SecurityContext securityContext)
      Remove a principal from polaris Response type: Void.
      Parameters:
      principalName - Required - The principal name
      Returns:
      204 - Success, no content
    • getPrincipal

      @GET @Path("/{principalName}") @Produces("application/json") @RolesAllowed("**") @Timeout public jakarta.ws.rs.core.Response getPrincipal(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) @PathParam("principalName") @Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, @Context org.apache.polaris.core.context.RealmContext realmContext, @Context jakarta.ws.rs.core.SecurityContext securityContext)
      Get the principal details Response type: Principal.
      Parameters:
      principalName - Required - The principal name
      Returns:
      200 - The requested principal
    • listPrincipalRolesAssigned

      @GET @Path("/{principalName}/principal-roles") @Produces("application/json") @RolesAllowed("**") @Timeout public jakarta.ws.rs.core.Response listPrincipalRolesAssigned(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) @PathParam("principalName") @Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, @Context org.apache.polaris.core.context.RealmContext realmContext, @Context jakarta.ws.rs.core.SecurityContext securityContext)
      List the roles assigned to the principal Response type: PrincipalRoles.
      Parameters:
      principalName - Required - The name of the target principal
      Returns:
      200 - List of roles assigned to this principal
    • listPrincipals

      @GET @Produces("application/json") @RolesAllowed("**") @Timeout public jakarta.ws.rs.core.Response listPrincipals(@Context org.apache.polaris.core.context.RealmContext realmContext, @Context jakarta.ws.rs.core.SecurityContext securityContext)
      List the principals for the current catalog Response type: Principals.
      Returns:
      200 - List of principals for this catalog
    • revokePrincipalRole

      @DELETE @Path("/{principalName}/principal-roles/{principalRoleName}") @RolesAllowed("**") @Timeout public jakarta.ws.rs.core.Response revokePrincipalRole(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) @PathParam("principalName") @Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, @Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) @PathParam("principalRoleName") @Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalRoleName, @Context org.apache.polaris.core.context.RealmContext realmContext, @Context jakarta.ws.rs.core.SecurityContext securityContext)
      Remove a role from a catalog principal Response type: Void.
      Parameters:
      principalName - Required - The name of the target principal
      principalRoleName - Required - The name of the role
      Returns:
      204 - Success, no content
    • rotateCredentials

      @POST @Path("/{principalName}/rotate") @Produces("application/json") @RolesAllowed("**") @Timeout public jakarta.ws.rs.core.Response rotateCredentials(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) @PathParam("principalName") @Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, @Context org.apache.polaris.core.context.RealmContext realmContext, @Context jakarta.ws.rs.core.SecurityContext securityContext)
      Rotate a principal's credentials. The new credentials will be returned in the response. This is the only API, aside from createPrincipal, that returns the user's credentials. This API is *not* idempotent. Response type: PrincipalWithCredentials.
      Parameters:
      principalName - Required - The user name
      Returns:
      200 - The principal details along with the newly rotated credentials
    • updatePrincipal

      @PUT @Path("/{principalName}") @Consumes("application/json") @Produces("application/json") @RolesAllowed("**") @Timeout public jakarta.ws.rs.core.Response updatePrincipal(@Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) @PathParam("principalName") @Pattern(regexp="^(?!\\s*[s|S][y|Y][s|S][t|T][e|E][m|M]\\$).*$") @Size(min=1,max=256) String principalName, @Nonnull @Valid @Valid org.apache.polaris.core.admin.model.UpdatePrincipalRequest updatePrincipalRequest, @Context org.apache.polaris.core.context.RealmContext realmContext, @Context jakarta.ws.rs.core.SecurityContext securityContext)
      Update an existing principal Response type: Principal.
      Parameters:
      principalName - Required - The principal name
      updatePrincipalRequest - Required - The principal details to use in the update
      Returns:
      200 - The updated principal