curl --request PATCH \
--url https://api.xenia.team/api/v1/mgt/workspaces/{workspaceId}/locations/{locationId} \
--header 'Content-Type: application/json' \
--header 'x-client-key: <api-key>' \
--header 'x-client-secret: <api-key>' \
--data '
{
"name": "test location add",
"description": "location description",
"avatar": {
"color": "#C5CAE9"
},
"attachments": [
"https://cdn.xenia.team/.../image1.png",
"https://cdn.xenia.team/.../image2.png"
],
"isQREnable": true,
"LevelId": "98329f39-e263-484d-8fa7-e951fcddb9c1",
"ParentId": "6c826259-28ea-4e16-8869-b16cbc147633",
"latitude": null,
"longitude": null,
"address": null,
"memberIds": [
"dfea8b8a-5b22-4668-b68d-dc641eb3a101",
"e25dd448-7ae7-4588-8767-7e1a316547e5"
]
}
'{
"data": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"HotelId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"avatar": {
"color": "<string>"
},
"attachments": [
"<string>"
],
"LevelId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"ParentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"slugCode": "<string>",
"isQREnable": true,
"locationNumber": 123,
"timezone": "<string>",
"coordinates": {
"type": "Point",
"coordinates": [
123
]
},
"address": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"deletedAt": "2023-11-07T05:31:56Z",
"Members": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fullName": "<string>",
"emailId": "<string>",
"phoneNo": "<string>",
"RoleId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"timezone": "<string>"
}
],
"Level": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"title": "<string>",
"isSite": true
},
"assetCount": 123,
"Sublocations": "<array>",
"ParentLocation": "<unknown>"
},
"meta": {}
}Updates details of an existing location including name, description, coordinates, and membership. Applies validation and business rules such as uniqueness of name within a parent location.
curl --request PATCH \
--url https://api.xenia.team/api/v1/mgt/workspaces/{workspaceId}/locations/{locationId} \
--header 'Content-Type: application/json' \
--header 'x-client-key: <api-key>' \
--header 'x-client-secret: <api-key>' \
--data '
{
"name": "test location add",
"description": "location description",
"avatar": {
"color": "#C5CAE9"
},
"attachments": [
"https://cdn.xenia.team/.../image1.png",
"https://cdn.xenia.team/.../image2.png"
],
"isQREnable": true,
"LevelId": "98329f39-e263-484d-8fa7-e951fcddb9c1",
"ParentId": "6c826259-28ea-4e16-8869-b16cbc147633",
"latitude": null,
"longitude": null,
"address": null,
"memberIds": [
"dfea8b8a-5b22-4668-b68d-dc641eb3a101",
"e25dd448-7ae7-4588-8767-7e1a316547e5"
]
}
'{
"data": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"HotelId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"avatar": {
"color": "<string>"
},
"attachments": [
"<string>"
],
"LevelId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"ParentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"slugCode": "<string>",
"isQREnable": true,
"locationNumber": 123,
"timezone": "<string>",
"coordinates": {
"type": "Point",
"coordinates": [
123
]
},
"address": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"deletedAt": "2023-11-07T05:31:56Z",
"Members": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fullName": "<string>",
"emailId": "<string>",
"phoneNo": "<string>",
"RoleId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"timezone": "<string>"
}
],
"Level": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"title": "<string>",
"isSite": true
},
"assetCount": 123,
"Sublocations": "<array>",
"ParentLocation": "<unknown>"
},
"meta": {}
}UUID of the workspace.
The ID of the location to be updated.