> ## Documentation Index > Fetch the complete documentation index at: https://docs.restaurant365.com/llms.txt > Use this file to discover all available pages before exploring further. # /public/user-management/v1/users > Updates multiple user accounts in a single request ## OpenAPI ````json PATCH /public/user-management/v1/users { "openapi": "3.0.1", "info": { "title": "R365.PublicApi", "contact": { "name": "R365 Services Team", "email": "r365@restaurant365.com" }, "version": "1.0" }, "security": [ { "Bearer": [] } ], "paths": { "/public/user-management/v1/users": { "patch": { "tags": [ "netcore" ], "description": "Updates multiple user accounts in a single request", "requestBody": { "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.Models.PatchUserRequest" } } } } }, "responses": { "200": { "description": "Users updated successfully.", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.UserUpdated" } }, "userErrors": { "type": "array", "example": "[]" } } } } } }, "207": { "description": "207 Multi-Status – Partial success: the response contains arrays of created users and of errors for those that could not be created.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.Models.UserUpdatedSuccessErrorsResponse" } } } }, "400": { "description": "Bad request, more than one validation errors occurred.", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "array", "example": "[]" }, "userErrors": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.UserErrors" } } } } } } }, "404": { "description": "Not Found – one or more requested resources could not be located.", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "array", "example": "[]" }, "userErrors": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.UserErrors" }, "example": [ { "message": "The following role IDs do not exist: [172cb15b-131e-43d3-83af-c5016c1b858f]", "errorCode": "urn:r365:user:roles-not-found" }, { "message": "The following location IDs do not exist: [172cb15b-131e-43d3-83af-c5016c1b858f]", "errorCode": "urn:r365:user:locations-not-found" }, { "message": "The following externalLocation IDs do not exist: [172cb15b-131e-43d3-83af-c5016c1b858f]", "errorCode": "urn:r365:user:external-locations-not-found" }, { "message": "The following reportRole IDs do not exist: [172cb15b-131e-43d3-83af-c5016c1b858f]", "errorCode": "urn:r365:user:report-roles-not-found" }, { "message": "The specified value for field 'defaultLocation' is unknown", "errorCode": "urn:r365:user:default-location-not-found" }, { "message": "The following Options IDs do not exist: [45, 32]", "errorCode": "urn:r365:user:options-not-found" } ] } } } } } }, "409": { "description": "Conflict – the request could not be completed due to a conflict with the current state of the resource.", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "array", "example": "[]" }, "userErrors": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.UserErrors" }, "example": [ { "message": "The specified value 'jack' for field 'username' already in use", "errorCode": "urn:r365:user:username-conflict" }, { "message": "The specified value 'user@email.net' for field 'email' already in use", "errorCode": "urn:r365:user:email-conflict" }, { "message": "No access to add/delete default location id 'fb3c7802-c668-4c52-98ea-477e294363bb'", "errorCode": "urn:r365:user:user-has-no-access" }, { "message": "No access to delete locations granted from option", "errorCode": "urn:r365:user:no-access-to-delete-locations-by-options" }, { "message": "Users with Full Access, All Locations and All Reports must have the grant access beyond personal level set to True", "errorCode": "urn:r365::grant-beyond-personal-level-must-be-true" }, { "message": "Cannot set grant access beyond personal level to true when user does not have permission to edit users or roles", "errorCode": "urn:r365::insufficient-permissions" } ] } } } } } }, "422": { "description": "Unprocessable Entity: The request was well-formed but contains semantic errors and could not be processed.", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "array", "example": "[]" }, "userErrors": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.UserErrors" }, "example": [ { "message": "Field 'fullName' is required", "errorCode": "urn:r365:user:fullname-required" }, { "message": "Field 'username' is required", "errorCode": "urn:r365:user:fullname-required" }, { "message": "Field 'email' is required", "errorCode": "urn:r365:user:email-required" }, { "message": "Field 'defaultLocation' is required", "errorCode": "urn:r365:user:default-location-required" }, { "message": "The specified value for field 'canGrantAccessBeyondPersonalLevel' is invalid", "errorCode": "urn:r365:user:can-grant-access-beyond-personal-level-invalid-value" } ] } } } } } } } } } }, "components": { "schemas": { "R365.Netcore.Public.Contracts.Users.Models.PatchUserRequest": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid", "description": "Unique identifier of the patch user." }, "fullName": { "type": "string" }, "username": { "type": "string" }, "defaultLocation": { "type": "string", "format": "uuid" }, "email": { "type": "string" }, "managedByBrand": { "type": "string", "nullable": true }, "mobileNumber": { "type": "string", "nullable": true }, "allLocationsAccess": { "type": "boolean", "nullable": true }, "allBrandFranchiseeLocationAccess": { "type": "boolean", "nullable": true }, "canGrantAccessBeyondPersonalLevel": { "type": "boolean" }, "inActive": { "type": "boolean", "nullable": true }, "userRoles": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Public.Models.GuidId" } }, "locations": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Public.Models.GuidId" }, "nullable": true }, "externalLocations": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.Models.ExternalLocationReference" }, "nullable": true }, "reportRoles": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Public.Models.GuidId" }, "nullable": true }, "optionIds": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.Models.EntityReferenceLongPatch" }, "nullable": true } }, "additionalProperties": false }, "R365.Netcore.Public.Contracts.Users.UserUpdated": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid", "description": "Unique identifier of the user updated." }, "username": { "type": "string" } }, "additionalProperties": false }, "R365.Netcore.Public.Contracts.Users.Models.UserUpdatedSuccessErrorsResponse": { "type": "object", "properties": { "success": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.UserUpdated" } }, "errors": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.UserErrors" } } }, "additionalProperties": false }, "R365.Netcore.Public.Contracts.Users.UserErrors": { "type": "object", "properties": { "username": { "type": "string" }, "errors": { "type": "array", "items": { "$ref": "#/components/schemas/R365.Netcore.Public.Contracts.Users.ErrorMessage" } } }, "additionalProperties": false }, "R365.Public.Models.GuidId": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid", "description": "Unique identifier of the guid id." } }, "additionalProperties": false }, "R365.Netcore.Public.Contracts.Users.Models.ExternalLocationReference": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid", "description": "Unique identifier of the external location." }, "tenant": { "type": "string" } }, "additionalProperties": false }, "R365.Netcore.Public.Contracts.Users.Models.EntityReferenceLongPatch": { "type": "object", "properties": { "id": { "type": "integer", "format": "int64", "description": "Unique identifier of the entity reference long patch." } }, "additionalProperties": false }, "R365.Netcore.Public.Contracts.Users.ErrorMessage": { "type": "object", "properties": { "error": { "type": "string", "nullable": true }, "errorCode": { "type": "string", "nullable": true } }, "additionalProperties": false } }, "securitySchemes": { "Bearer": { "type": "http", "description": "Put **_ONLY_** your JWT Bearer token on textbox below!", "scheme": "Bearer", "bearerFormat": "JWT" } } } } ````