Skip to main content

UpdateAuthorizedUserInput

Input for updateAuthorizedUser.

input UpdateAuthorizedUserInput {
userEmail: String!
accessLevel: AuthorizedUserAccessLevel
roles: [String!]
permissions: [String!]
storeId: ID
pointOfSaleId: ID
}

Fields​

UpdateAuthorizedUserInput.userEmail ● String! non-null scalar​

Email of the user to update. Identifies the existing record.

UpdateAuthorizedUserInput.accessLevel ● AuthorizedUserAccessLevel enum​

New permission level. ADMIN_ACCESS is rejected when storeId or pointOfSaleId is set. Sending only the level the current roles already contain keeps the roles; another level replaces them with the role of that level. A user with permissions accepts only its current level, READ_ACCESS, which keeps the list. When sent with roles, it must equal the level the roles contain. When sent with permissions, it must be READ_ACCESS, or the level of the role when the list equals the permissions of that role. Send roles to change the roles.

UpdateAuthorizedUserInput.roles ● [String!] list scalar​

New roles, ids as in AuthorizedUser.roles. Must not be empty; unknown ids are rejected. Replaces the current roles or permission list. With storeId or pointOfSaleId, only read_access, write_access and cashier_access are allowed.

UpdateAuthorizedUserInput.permissions ● [String!] list scalar​

New custom permission list, instead of roles. Replaces the current roles or permission list, as resource:action ids. Send roles or permissions, not both. Must not be empty; unknown ids are rejected. Some permissions are given only through a role (for example credentials:read), and some need others in the same list (for example exports:create needs payments:read). A list equal to the permissions of one role is stored as that role. With storeId or pointOfSaleId, only the permissions of read_access, write_access and cashier_access are allowed.

UpdateAuthorizedUserInput.storeId ● ID scalar​

ID of a store of the current account. Restricts the user to that store. Pass null to clear. Omit to keep.

UpdateAuthorizedUserInput.pointOfSaleId ● ID scalar​

ID of a point of sale of the current account. Restricts the user to that point of sale. Pass null to clear. Omit to keep.

Member Of​

updateAuthorizedUser mutation