← Files GoodMemARCHIVED FILE

skills/goodmem-sdk/references/java/models/AssignRoleRequest.md

1.17 KB · Oct 2, 2026 · 00:24 UTC

↓ Download file

<!-- sdk-ref package=ai.pairsys:goodmem-java registry=maven version=0.2.2 -->

# AssignRoleRequest

Assigns one code-defined role at an INSTANCE or SPACE boundary.

Prefer `builder()` to the canonical record constructor.
 Builder-based call sites remain source-compatible when optional fields are added in later SDK versions.

- `roleAssignmentId` (`RoleAssignmentId`): Optional caller-provided role-assignment UUID. Typed wrapper `RoleAssignmentId`; build from a raw string with `RoleAssignmentId.from(String)`.
- `principalId` (`PrincipalId`): Active principal receiving the role. Typed wrapper `PrincipalId`; build from a raw string with `PrincipalId.from(String)`.
- `role` (`AssignRoleRequestRole`): Code-defined non-ROOT role to assign. Typed enum `AssignRoleRequestRole`; unknown server values fail Jackson deserialization loudly.
- `assignedResource` (`RoleAssignmentTarget`): INSTANCE or SPACE boundary receiving the assignment.

[Java](../../java.md)

Related types — open only those used by your request:

- [AssignRoleRequestRole](AssignRoleRequestRole.md)
- [PrincipalId](PrincipalId.md)
- [RoleAssignmentId](RoleAssignmentId.md)
- [RoleAssignmentTarget](RoleAssignmentTarget.md)

SHA-256: 5cb21aa3b1989c09d00a57739625bf0afe4b28f142c8470097f5cac24ccdbed5