Skip to content

Commit

Permalink
add AssignResourceRole method
Browse files Browse the repository at this point in the history
  • Loading branch information
RazcoDev committed Apr 3, 2024
1 parent a7c7af4 commit 270a29b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/api/users.go
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ func (u *Users) AssignRole(ctx context.Context, userKey string, roleKey string,
return roleAssignmentRead, nil
}

// AssignResourceRole assigns a role to a user in your context's environment, by user key, role key and tenant key.
// AssignResourceRole assigns a *resource* role to a user in your context's environment, by user key, role key, tenant key and a resource instance string (e.g. "document:mydoc").
// Usage Example:
// `roleAssignment, err := PermitClient.Api.Users.AssignRole(ctx, "user-key", "role-key", "default", "document:mydoc")`
func (u *Users) AssignResourceRole(ctx context.Context, userKey string, roleKey string, tenantKey string, resourceInstance string) (*models.RoleAssignmentRead, error) {
Expand Down

0 comments on commit 270a29b

Please sign in to comment.