# Locations

## Retrieving all locations

> Retrieves all locations assigned to the tenant. You can filter, sort and paginate the results with query parameters.

```json
{"openapi":"3.0.0","info":{"title":"Vendor Service","version":"0.0.1"},"tags":[{"name":"Locations"}],"servers":[{"url":"https://api.emporix.io"}],"security":[{"OAuth2":["vendor.vendor_read","vendor.vendor_manage"]}],"components":{"securitySchemes":{"OAuth2":{"type":"oauth2","flows":{"clientCredentials":{"tokenUrl":"https://api.emporix.io/oauth/token","scopes":{"vendor.vendor_read":"Needed to read vendors and locations","vendor.vendor_manage":"Needed to manage vendors and locations"}}}}},"parameters":{"trait_paged_pageNumber":{"name":"pageNumber","in":"query","description":"The page number to be retrieved where the size of the pages must be specified by the pageSize parameter.\nThe number of the first page is 1.\n","schema":{"default":1,"minimum":1,"type":"integer"}},"trait_paged_pageSize":{"name":"pageSize","in":"query","description":"The number of documents being retrieved on the page.\n","schema":{"default":16,"minimum":1,"type":"integer"}},"trait_XTotalCount_header":{"in":"header","name":"X-Total-Count","required":false,"description":"In order to get information how many entities meet a filter requirements, X-Total-Count header has been introduced. The header is optional and its default value is false. If the header is provided and it is true then total count is returned in the X-Total-Count response header.","schema":{"default":false,"type":"boolean"}},"trait_sort":{"in":"query","name":"sort","required":false,"description":"Fields to sort the response data by following order of the parameters from left to right. Can contain multiple fields in format: field name:sort direction separated by a comma. The colon with sort direction parameter is redundant and descending order is taken only if it is equal to desc or DESC. Ascending order is considered in any other case.","schema":{"type":"string"}},"trait_q_param":{"in":"query","name":"q","required":false,"description":"Query param for filtering entities by specified type. Examples of query params which are supported:\n\n| Q Param                                                                            | Description                                                                                                                          |\n|------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------|\n| `name:\"Exact match\"`                                                               | find an entity with `name` field with `Exact match` value                                                                            |\n| `name:~Supplier`                                                                   | find an entity with `name` field containing `Supplier` value                                                                        |\n| `type:COMPANY`                                                                     | find an entity with `type` field with `COMPANY` value                                                                               |\n| `metadata.createdAt:(>\"2019-01-06T10:29:30.602Z\" AND <\"2020-01-07T10:29:30.602Z\")` | find an entity with `metadata.createdAt` field with value between `2019-01-06T10:29:30.602Z` and `2020-01-07T10:29:30.602Z`      |\n| `name:exists`                                                                      | find an entity with existing `name` field                                                                                            |\n| `name:null`                                                                        | find an entity with non-existing `name` field                                                                                        |\n","schema":{"type":"string"}},"trait_fields":{"in":"query","name":"fields","required":false,"description":"Comma-separated list of fields to return in the response. If not specified, all fields are returned.","schema":{"type":"string"}},"trait_location_name_query_param":{"name":"name","in":"query","required":false,"schema":{"type":"string"},"description":"Location name. When specified, only locations containing the specified name will be returned.\n"},"trait_location_type_query_param":{"name":"type","in":"query","required":false,"schema":{"type":"string","enum":["HEADQUARTER","WAREHOUSE","OFFICE"]},"description":"The type of the location. When specified, only locations of the specified type will be returned.\n"},"trait_location_contactDetails_email_query_param":{"name":"contactDetails.email","in":"query","required":false,"schema":{"type":"string"},"description":"The email of the contact details of the location. When specified, only locations with contact details containing the specified email will be returned.\n"},"trait_location_contactDetails_phone_query_param":{"name":"contactDetails.phone","in":"query","required":false,"schema":{"type":"string"},"description":"The phone number of the contact details of the location.\n"},"trait_location_contactDetails_address_query_param":{"name":"contactDetails.address","in":"query","required":false,"schema":{"type":"string"},"description":"The address of the contact details of the location.\n"},"trait_location_contactDetails_city_query_param":{"name":"contactDetails.city","in":"query","required":false,"schema":{"type":"string"},"description":"The city of the contact details of the location.\n"},"trait_location_contactDetails_state_query_param":{"name":"contactDetails.state","in":"query","required":false,"schema":{"type":"string"},"description":"The state of the contact details of the location.\n"},"trait_location_contactDetails_postcode_query_param":{"name":"contactDetails.postcode","in":"query","required":false,"schema":{"type":"string"},"description":"The postcode of the contact details of the location.\n"},"trait_location_contactDetails_countryCode_query_param":{"name":"contactDetails.countryCode","in":"query","required":false,"schema":{"type":"string"},"description":"The country code of the contact details of the location.\n"}},"responses":{"GetLocations":{"description":"The request was successful. A list of locations is returned.","headers":{"X-Total-Count":{"description":"Total amount of locations.","schema":{"type":"integer","format":"int32"}}},"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/location"}}}}},"BadRequest_400":{"description":"Request was syntactically incorrect. Details will be provided in the response payload.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"Unauthorized_401":{"description":"Given request is unauthorized - the authorization token is invalid or has expired.","content":{"application/json":{"schema":{"type":"object","properties":{"fault":{"type":"object","properties":{"faultstring":{"type":"string"},"detail":{"type":"object","properties":{"errorcode":{"type":"string"}}}}}}}}}},"Forbidden_403":{"description":"Given authorization scopes are not sufficient and do not match scopes required by the endpoint.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"InternalServiceError_500":{"description":"Internal Service Error occurred.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}}},"schemas":{"location":{"title":"Location","type":"object","properties":{"id":{"type":"string","description":"The location unique identifier."},"name":{"type":"string","description":"The name of the location."},"type":{"type":"string","enum":["HEADQUARTER","WAREHOUSE","OFFICE"],"description":"The type of the location."},"contactDetails":{"$ref":"#/components/schemas/contactDetails"},"metadata":{"$ref":"#/components/schemas/metadata"},"mixins":{"type":"object","description":"Mixins request. A map where a key represent mixins set name and a value represent a map with key-value pairs.","additionalProperties":true}}},"contactDetails":{"title":"Contact Details","type":"object","properties":{"emails":{"type":"array","items":{"type":"string","format":"email"},"description":"The list of contact emails."},"phones":{"type":"array","items":{"type":"string"},"description":"The list of contact phone numbers."},"addressLine1":{"type":"string","description":"The first address line of the contact."},"city":{"type":"string","description":"The city of the contact."},"state":{"type":"string","description":"The state of the contact."},"postcode":{"type":"string","description":"The post code of the contact."},"countryCode":{"type":"string","description":"The country code of the contact."},"tags":{"type":"array","items":{"type":"string"},"description":"Allows to tag the location."}}},"metadata":{"type":"object","allOf":[{"$ref":"#/components/schemas/metadataUpdate"},{"type":"object","properties":{"createdAt":{"description":"Date and time when the document was created.","type":"string"},"modifiedAt":{"description":"Date and time when the document was last modified.","type":"string"}}}]},"metadataUpdate":{"type":"object","properties":{"version":{"minimum":1,"type":"integer","description":"Version of the document."},"mixins":{"type":"object","description":"Links to the mixin schemas. A map where the keys represent mixins set attributes and the values represent url to a schema for a particular set.","additionalProperties":true}}},"errorMessage":{"title":"Error","description":"Schema for API specified errors.","type":"object","properties":{"code":{"minimum":100,"maximum":599,"description":"Original HTTP error code, should be consistent with the response HTTP code.","type":"integer"},"status":{"description":"Original HTTP error name.","type":"string"},"message":{"description":"Descriptive error message for debugging.","type":"string"},"resourceId":{"type":"string","description":"Id of the resource."},"details":{"description":"List of problems causing this error.","type":"array","items":{"description":"Details for specific error cause.","type":"string"}}},"required":["status","code"]}}},"paths":{"/vendor/{tenant}/locations":{"get":{"summary":"Retrieving all locations","description":"Retrieves all locations assigned to the tenant. You can filter, sort and paginate the results with query parameters.","parameters":[{"$ref":"#/components/parameters/trait_paged_pageNumber"},{"$ref":"#/components/parameters/trait_paged_pageSize"},{"$ref":"#/components/parameters/trait_XTotalCount_header"},{"$ref":"#/components/parameters/trait_sort"},{"$ref":"#/components/parameters/trait_q_param"},{"$ref":"#/components/parameters/trait_fields"},{"$ref":"#/components/parameters/trait_location_name_query_param"},{"$ref":"#/components/parameters/trait_location_type_query_param"},{"$ref":"#/components/parameters/trait_location_contactDetails_email_query_param"},{"$ref":"#/components/parameters/trait_location_contactDetails_phone_query_param"},{"$ref":"#/components/parameters/trait_location_contactDetails_address_query_param"},{"$ref":"#/components/parameters/trait_location_contactDetails_city_query_param"},{"$ref":"#/components/parameters/trait_location_contactDetails_state_query_param"},{"$ref":"#/components/parameters/trait_location_contactDetails_postcode_query_param"},{"$ref":"#/components/parameters/trait_location_contactDetails_countryCode_query_param"}],"responses":{"200":{"$ref":"#/components/responses/GetLocations"},"400":{"$ref":"#/components/responses/BadRequest_400"},"401":{"$ref":"#/components/responses/Unauthorized_401"},"403":{"$ref":"#/components/responses/Forbidden_403"},"500":{"$ref":"#/components/responses/InternalServiceError_500"}},"operationId":"GET-vendor-mgmt-list-all-locations","tags":["Locations"]}}}}
```

## Creating a location

> Creates a new location for the tenant. A location represents address information for a vendor.

```json
{"openapi":"3.0.0","info":{"title":"Vendor Service","version":"0.0.1"},"tags":[{"name":"Locations"}],"servers":[{"url":"https://api.emporix.io"}],"security":[{"OAuth2":["vendor.vendor_manage"]}],"components":{"securitySchemes":{"OAuth2":{"type":"oauth2","flows":{"clientCredentials":{"tokenUrl":"https://api.emporix.io/oauth/token","scopes":{"vendor.vendor_read":"Needed to read vendors and locations","vendor.vendor_manage":"Needed to manage vendors and locations"}}}}},"schemas":{"locationCreate":{"title":"Location create payload","type":"object","properties":{"id":{"type":"string","description":"Custom location identifier. If not provided, it is automatically generated.","minLength":1,"maxLength":66,"pattern":"^[a-zA-Z0-9_-]+$"},"name":{"type":"string","description":"The name of the location"},"type":{"type":"string","enum":["HEADQUARTER","WAREHOUSE","OFFICE"],"description":"The type of the location."},"contactDetails":{"$ref":"#/components/schemas/contactDetails"},"mixins":{"type":"object","description":"Mixins request. A map where a key represent mixins set name and a value represent a map with key-value pairs.","additionalProperties":true}},"required":["type","contactDetails"]},"contactDetails":{"title":"Contact Details","type":"object","properties":{"emails":{"type":"array","items":{"type":"string","format":"email"},"description":"The list of contact emails."},"phones":{"type":"array","items":{"type":"string"},"description":"The list of contact phone numbers."},"addressLine1":{"type":"string","description":"The first address line of the contact."},"city":{"type":"string","description":"The city of the contact."},"state":{"type":"string","description":"The state of the contact."},"postcode":{"type":"string","description":"The post code of the contact."},"countryCode":{"type":"string","description":"The country code of the contact."},"tags":{"type":"array","items":{"type":"string"},"description":"Allows to tag the location."}}},"errorMessage":{"title":"Error","description":"Schema for API specified errors.","type":"object","properties":{"code":{"minimum":100,"maximum":599,"description":"Original HTTP error code, should be consistent with the response HTTP code.","type":"integer"},"status":{"description":"Original HTTP error name.","type":"string"},"message":{"description":"Descriptive error message for debugging.","type":"string"},"resourceId":{"type":"string","description":"Id of the resource."},"details":{"description":"List of problems causing this error.","type":"array","items":{"description":"Details for specific error cause.","type":"string"}}},"required":["status","code"]}},"responses":{"BadRequest_400":{"description":"Request was syntactically incorrect. Details will be provided in the response payload.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"Unauthorized_401":{"description":"Given request is unauthorized - the authorization token is invalid or has expired.","content":{"application/json":{"schema":{"type":"object","properties":{"fault":{"type":"object","properties":{"faultstring":{"type":"string"},"detail":{"type":"object","properties":{"errorcode":{"type":"string"}}}}}}}}}},"Forbidden_403":{"description":"Given authorization scopes are not sufficient and do not match scopes required by the endpoint.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"Conflict_409":{"description":"Given resource already exists","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"InternalServiceError_500":{"description":"Internal Service Error occurred.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}}}},"paths":{"/vendor/{tenant}/locations":{"post":{"summary":"Creating a location","description":"Creates a new location for the tenant. A location represents address information for a vendor.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/locationCreate"}}}},"responses":{"201":{"description":"The request was successful. The location has been created.","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest_400"},"401":{"$ref":"#/components/responses/Unauthorized_401"},"403":{"$ref":"#/components/responses/Forbidden_403"},"409":{"$ref":"#/components/responses/Conflict_409"},"500":{"$ref":"#/components/responses/InternalServiceError_500"}},"operationId":"POST-vendor-mgmt-create-location","tags":["Locations"]}}}}
```

## Retrieving a location

> Retrieves a location by the specified unique identifier.

```json
{"openapi":"3.0.0","info":{"title":"Vendor Service","version":"0.0.1"},"tags":[{"name":"Locations"}],"servers":[{"url":"https://api.emporix.io"}],"security":[{"OAuth2":["vendor.vendor_read","vendor.vendor_manage"]}],"components":{"securitySchemes":{"OAuth2":{"type":"oauth2","flows":{"clientCredentials":{"tokenUrl":"https://api.emporix.io/oauth/token","scopes":{"vendor.vendor_read":"Needed to read vendors and locations","vendor.vendor_manage":"Needed to manage vendors and locations"}}}}},"parameters":{"trait_fields":{"in":"query","name":"fields","required":false,"description":"Comma-separated list of fields to return in the response. If not specified, all fields are returned.","schema":{"type":"string"}}},"responses":{"GetLocation":{"description":"The request was successful. The requested location is returned.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/location"}}}},"BadRequest_400":{"description":"Request was syntactically incorrect. Details will be provided in the response payload.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"Unauthorized_401":{"description":"Given request is unauthorized - the authorization token is invalid or has expired.","content":{"application/json":{"schema":{"type":"object","properties":{"fault":{"type":"object","properties":{"faultstring":{"type":"string"},"detail":{"type":"object","properties":{"errorcode":{"type":"string"}}}}}}}}}},"Forbidden_403":{"description":"Given authorization scopes are not sufficient and do not match scopes required by the endpoint.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"NotFound_404":{"description":"The requested resource does not exist.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"InternalServiceError_500":{"description":"Internal Service Error occurred.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}}},"schemas":{"location":{"title":"Location","type":"object","properties":{"id":{"type":"string","description":"The location unique identifier."},"name":{"type":"string","description":"The name of the location."},"type":{"type":"string","enum":["HEADQUARTER","WAREHOUSE","OFFICE"],"description":"The type of the location."},"contactDetails":{"$ref":"#/components/schemas/contactDetails"},"metadata":{"$ref":"#/components/schemas/metadata"},"mixins":{"type":"object","description":"Mixins request. A map where a key represent mixins set name and a value represent a map with key-value pairs.","additionalProperties":true}}},"contactDetails":{"title":"Contact Details","type":"object","properties":{"emails":{"type":"array","items":{"type":"string","format":"email"},"description":"The list of contact emails."},"phones":{"type":"array","items":{"type":"string"},"description":"The list of contact phone numbers."},"addressLine1":{"type":"string","description":"The first address line of the contact."},"city":{"type":"string","description":"The city of the contact."},"state":{"type":"string","description":"The state of the contact."},"postcode":{"type":"string","description":"The post code of the contact."},"countryCode":{"type":"string","description":"The country code of the contact."},"tags":{"type":"array","items":{"type":"string"},"description":"Allows to tag the location."}}},"metadata":{"type":"object","allOf":[{"$ref":"#/components/schemas/metadataUpdate"},{"type":"object","properties":{"createdAt":{"description":"Date and time when the document was created.","type":"string"},"modifiedAt":{"description":"Date and time when the document was last modified.","type":"string"}}}]},"metadataUpdate":{"type":"object","properties":{"version":{"minimum":1,"type":"integer","description":"Version of the document."},"mixins":{"type":"object","description":"Links to the mixin schemas. A map where the keys represent mixins set attributes and the values represent url to a schema for a particular set.","additionalProperties":true}}},"errorMessage":{"title":"Error","description":"Schema for API specified errors.","type":"object","properties":{"code":{"minimum":100,"maximum":599,"description":"Original HTTP error code, should be consistent with the response HTTP code.","type":"integer"},"status":{"description":"Original HTTP error name.","type":"string"},"message":{"description":"Descriptive error message for debugging.","type":"string"},"resourceId":{"type":"string","description":"Id of the resource."},"details":{"description":"List of problems causing this error.","type":"array","items":{"description":"Details for specific error cause.","type":"string"}}},"required":["status","code"]}}},"paths":{"/vendor/{tenant}/locations/{locationId}":{"get":{"parameters":[{"$ref":"#/components/parameters/trait_fields"}],"summary":"Retrieving a location","description":"Retrieves a location by the specified unique identifier.","responses":{"200":{"$ref":"#/components/responses/GetLocation"},"400":{"$ref":"#/components/responses/BadRequest_400"},"401":{"$ref":"#/components/responses/Unauthorized_401"},"403":{"$ref":"#/components/responses/Forbidden_403"},"404":{"$ref":"#/components/responses/NotFound_404"},"500":{"$ref":"#/components/responses/InternalServiceError_500"}},"operationId":"GET-vendor-mgmt-retrieve-location","tags":["Locations"]}}}}
```

## Upserting a location

> Updates or creates a location with a given location ID. You can omit the \`metadata.version\`, but then optimistic locking is not enabled.

```json
{"openapi":"3.0.0","info":{"title":"Vendor Service","version":"0.0.1"},"tags":[{"name":"Locations"}],"servers":[{"url":"https://api.emporix.io"}],"security":[{"OAuth2":["vendor.vendor_manage"]}],"components":{"securitySchemes":{"OAuth2":{"type":"oauth2","flows":{"clientCredentials":{"tokenUrl":"https://api.emporix.io/oauth/token","scopes":{"vendor.vendor_read":"Needed to read vendors and locations","vendor.vendor_manage":"Needed to manage vendors and locations"}}}}},"schemas":{"locationUpdate":{"title":"Location update payload","type":"object","properties":{"name":{"type":"string","description":"The name of the location."},"type":{"type":"string","enum":["HEADQUARTER","WAREHOUSE","OFFICE"],"description":"The type of the location."},"contactDetails":{"$ref":"#/components/schemas/contactDetails"},"metadata":{"$ref":"#/components/schemas/metadataUpdate"},"mixins":{"type":"object","description":"Mixins request. A map where a key represent mixins set name and a value represent a map with key-value pairs.","additionalProperties":true}},"required":["type","contactDetails"]},"contactDetails":{"title":"Contact Details","type":"object","properties":{"emails":{"type":"array","items":{"type":"string","format":"email"},"description":"The list of contact emails."},"phones":{"type":"array","items":{"type":"string"},"description":"The list of contact phone numbers."},"addressLine1":{"type":"string","description":"The first address line of the contact."},"city":{"type":"string","description":"The city of the contact."},"state":{"type":"string","description":"The state of the contact."},"postcode":{"type":"string","description":"The post code of the contact."},"countryCode":{"type":"string","description":"The country code of the contact."},"tags":{"type":"array","items":{"type":"string"},"description":"Allows to tag the location."}}},"metadataUpdate":{"type":"object","properties":{"version":{"minimum":1,"type":"integer","description":"Version of the document."},"mixins":{"type":"object","description":"Links to the mixin schemas. A map where the keys represent mixins set attributes and the values represent url to a schema for a particular set.","additionalProperties":true}}},"errorMessage":{"title":"Error","description":"Schema for API specified errors.","type":"object","properties":{"code":{"minimum":100,"maximum":599,"description":"Original HTTP error code, should be consistent with the response HTTP code.","type":"integer"},"status":{"description":"Original HTTP error name.","type":"string"},"message":{"description":"Descriptive error message for debugging.","type":"string"},"resourceId":{"type":"string","description":"Id of the resource."},"details":{"description":"List of problems causing this error.","type":"array","items":{"description":"Details for specific error cause.","type":"string"}}},"required":["status","code"]}},"responses":{"BadRequest_400_Update":{"description":"Request was syntactically incorrect. Details will be provided in the response payload.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"Unauthorized_401":{"description":"Given request is unauthorized - the authorization token is invalid or has expired.","content":{"application/json":{"schema":{"type":"object","properties":{"fault":{"type":"object","properties":{"faultstring":{"type":"string"},"detail":{"type":"object","properties":{"errorcode":{"type":"string"}}}}}}}}}},"Forbidden_403":{"description":"Given authorization scopes are not sufficient and do not match scopes required by the endpoint.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"NotFound_404":{"description":"The requested resource does not exist.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"Conflict_409":{"description":"Given resource already exists","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"InternalServiceError_500":{"description":"Internal Service Error occurred.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}}}},"paths":{"/vendor/{tenant}/locations/{locationId}":{"put":{"summary":"Upserting a location","description":"Updates or creates a location with a given location ID. You can omit the `metadata.version`, but then optimistic locking is not enabled.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/locationUpdate"}}}},"responses":{"201":{"description":"The request was successful. The location has been created.","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"}}}}}},"204":{"description":"The location has been updated successfully."},"400":{"$ref":"#/components/responses/BadRequest_400_Update"},"401":{"$ref":"#/components/responses/Unauthorized_401"},"403":{"$ref":"#/components/responses/Forbidden_403"},"404":{"$ref":"#/components/responses/NotFound_404"},"409":{"$ref":"#/components/responses/Conflict_409"},"500":{"$ref":"#/components/responses/InternalServiceError_500"}},"operationId":"PUT-vendor-mgmt-update-location","tags":["Locations"]}}}}
```

## Delete a location

> Deletes a location.

```json
{"openapi":"3.0.0","info":{"title":"Vendor Service","version":"0.0.1"},"tags":[{"name":"Locations"}],"servers":[{"url":"https://api.emporix.io"}],"security":[{"OAuth2":["vendor.vendor_manage"]}],"components":{"securitySchemes":{"OAuth2":{"type":"oauth2","flows":{"clientCredentials":{"tokenUrl":"https://api.emporix.io/oauth/token","scopes":{"vendor.vendor_read":"Needed to read vendors and locations","vendor.vendor_manage":"Needed to manage vendors and locations"}}}}},"responses":{"BadRequest_400":{"description":"Request was syntactically incorrect. Details will be provided in the response payload.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"Unauthorized_401":{"description":"Given request is unauthorized - the authorization token is invalid or has expired.","content":{"application/json":{"schema":{"type":"object","properties":{"fault":{"type":"object","properties":{"faultstring":{"type":"string"},"detail":{"type":"object","properties":{"errorcode":{"type":"string"}}}}}}}}}},"Forbidden_403":{"description":"Given authorization scopes are not sufficient and do not match scopes required by the endpoint.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"NotFound_404":{"description":"The requested resource does not exist.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}},"InternalServiceError_500":{"description":"Internal Service Error occurred.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorMessage"}}}}},"schemas":{"errorMessage":{"title":"Error","description":"Schema for API specified errors.","type":"object","properties":{"code":{"minimum":100,"maximum":599,"description":"Original HTTP error code, should be consistent with the response HTTP code.","type":"integer"},"status":{"description":"Original HTTP error name.","type":"string"},"message":{"description":"Descriptive error message for debugging.","type":"string"},"resourceId":{"type":"string","description":"Id of the resource."},"details":{"description":"List of problems causing this error.","type":"array","items":{"description":"Details for specific error cause.","type":"string"}}},"required":["status","code"]}}},"paths":{"/vendor/{tenant}/locations/{locationId}":{"delete":{"summary":"Delete a location","description":"Deletes a location.","responses":{"204":{"description":"The location has been deleted successfully."},"400":{"$ref":"#/components/responses/BadRequest_400"},"401":{"$ref":"#/components/responses/Unauthorized_401"},"403":{"$ref":"#/components/responses/Forbidden_403"},"404":{"$ref":"#/components/responses/NotFound_404"},"500":{"$ref":"#/components/responses/InternalServiceError_500"}},"operationId":"DELETE-vendor-mgmt-remove-location","tags":["Locations"]}}}}
```
