Mews Products API
The Products API from Mews — 4 operation(s) for products.
The Products API from Mews — 4 operation(s) for products.
openapi: 3.0.4
info:
title: Connector Account notes Products API
description: General-purpose API that enables partners of Mews to access data and services in Mews Operations
termsOfService: https://www.mews.com/en/terms-conditions/partners
contact:
name: Partner success
email: partnersuccess@mews.com
version: v1
servers:
- url: https://api.mews.com
tags:
- name: Products
paths:
/api/connector/v1/products/getPricing:
post:
tags:
- Products
summary: Get product pricing
description: 'Returns prices for a given product for a specified time interval. UTC timestamps must correspond to the start boundary of a time unit, e.g. 00:00 converted to UTC for a time unit of "Day". Other timestamps are not permitted. The __maximum size of time interval__ depends on the service''s time unit: 100 hours if hours, 100 days if days, or 24 months if months. For more information about time units, see [Time unit](https://mews-systems.gitbook.io/connector-api/concepts/time-units). This operation supports [Portfolio Access Tokens](https://mews-systems.gitbook.io/connector-api/concepts/multi-property/).'
operationId: products_getPricing
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/ProductPricingFilterParameters'
example:
ClientToken: E0D439EE522F44368DC78E1BFB03710C-D24FB11DBE31D4621C4817E028D9E1D
AccessToken: C66EF7B239D24632943D115EDE9CB810-EA00F8FD8294692C940F6B5A8F9453D
Client: Sample Client 1.0.0
ProductId: 6b97a38b-0043-41e0-afbd-3f083bdbc0d2
FirstTimeUnitStartUtc: '2024-03-01T23:00:00.000Z'
LastTimeUnitStartUtc: '2024-03-03T23:00:00.000Z'
EnterpriseIds:
- 3fa85f64-5717-4562-b3fc-2c963f66afa6
- 4d0201db-36f5-428b-8d11-4f0a65e960cc
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/ProductPricingResult'
example:
ProductId: 6b97a38b-0043-41e0-afbd-3f083bdbc0d2
TimeUnitStartsUtc:
- '2024-03-01T23:00:00Z'
- '2024-03-02T23:00:00Z'
- '2024-03-03T23:00:00Z'
BaseAmountPrices:
- Currency: EUR
NetValue: 93.46
GrossValue: 100.0
TaxValues:
- Code: DE-2020-1-L
Value: 6.54
Breakdown:
Items:
- TaxRateCode: DE-2020-1-L
NetValue: 93.46
TaxValue: 6.54
- Currency: EUR
NetValue: 93.46
GrossValue: 100.0
TaxValues:
- Code: DE-2020-1-L
Value: 6.54
Breakdown:
Items:
- TaxRateCode: DE-2020-1-L
NetValue: 93.46
TaxValue: 6.54
AgeCategoryPrices:
- AgeCategoryId: 7d9d9b11-2c96-4862-9ead-501c6a8ed114
Prices:
- Currency: EUR
NetValue: 93.46
GrossValue: 100.0
TaxValues:
- Code: DE-2020-1-L
Value: 6.54
Breakdown:
Items:
- TaxRateCode: DE-2020-1-L
NetValue: 93.46
TaxValue: 6.54
- Currency: EUR
NetValue: 93.46
GrossValue: 100.0
TaxValues:
- Code: DE-2020-1-L
Value: 6.54
Breakdown:
Items:
- TaxRateCode: DE-2020-1-L
NetValue: 93.46
TaxValue: 6.54
'400':
description: Error caused by the client app, e.g. in case of malformed request or invalid identifier of a resource. In most cases, such an error signifies a bug in the client app (consumer of the API).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'401':
description: Error caused by usage of invalid ClientToken, AccessToken, or you may not have the necessary permission to use the endpoint.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'403':
description: Server error that should be reported to the end user of the client app. Happens for example when the server-side validation fails or when a business-logic check is violated.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'408':
description: Error caused by heavy request that takes too long to process (typically tens of seconds). To get around this, request data in smaller batches. For more information, see [Request timeouts](https://mews-systems.gitbook.io/connector-api/guidelines/requests#request-timeouts)
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'204':
description: Server has successfully fulfilled the request and there is no additional information to send back.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'429':
description: Error caused by too many requests sent in a given amount of time. Response contains `Retry-After` header indicating how long the user agent should wait before making a follow-up request. For more information, see [Request limits](https://mews-systems.gitbook.io/connector-api/guidelines/requests#request-limits).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'500':
description: Unexpected error on the Mews side. This may be due to a software fault. If such a situation occurs, the error will be logged and the development team notified, however you can raise an issue through GitHub on our [documentation repository](https://github.com/MewsSystems/gitbook-connector-api).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
x-restricted: true
/api/connector/v1/products/updatePrice:
post:
tags:
- Products
summary: Update product pricing
description: Updates the prices for a given product. You can make multiple price updates with one API call, and for each one specify the price amount per [Time unit](https://mews-systems.gitbook.io/connector-api/concepts/time-units) and the time interval for which it applies. The price will be updated for all service time units that the specified time interval intersects. It is not permitted to update historical prices older than specified by `EditableHistoryInterval`. This operation supports [Portfolio Access Tokens](https://mews-systems.gitbook.io/connector-api/concepts/multi-property/).
operationId: products_updatePrice
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/ProductPriceUpdateParameters'
example:
ClientToken: E0D439EE522F44368DC78E1BFB03710C-D24FB11DBE31D4621C4817E028D9E1D
AccessToken: C66EF7B239D24632943D115EDE9CB810-EA00F8FD8294692C940F6B5A8F9453D
Client: Sample Client 1.0.0
ProductId: 6b97a38b-0043-41e0-afbd-3f083bdbc0d2
PriceUpdates:
- Value: 100.0
FirstTimeUnitStartUtc: '2024-03-01T23:00:00.000Z'
LastTimeUnitStartUtc: '2024-03-03T23:00:00.000Z'
- Value: 200.0
FirstTimeUnitStartUtc: '2024-03-06T23:00:00.000Z'
LastTimeUnitStartUtc: '2024-03-08T23:00:00.000Z'
EnterpriseId: 3fa85f64-5717-4562-b3fc-2c963f66afa6
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/Unit'
'400':
description: Error caused by the client app, e.g. in case of malformed request or invalid identifier of a resource. In most cases, such an error signifies a bug in the client app (consumer of the API).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'401':
description: Error caused by usage of invalid ClientToken, AccessToken, or you may not have the necessary permission to use the endpoint.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'403':
description: Server error that should be reported to the end user of the client app. Happens for example when the server-side validation fails or when a business-logic check is violated.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'408':
description: Error caused by heavy request that takes too long to process (typically tens of seconds). To get around this, request data in smaller batches. For more information, see [Request timeouts](https://mews-systems.gitbook.io/connector-api/guidelines/requests#request-timeouts)
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'204':
description: Server has successfully fulfilled the request and there is no additional information to send back.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'429':
description: Error caused by too many requests sent in a given amount of time. Response contains `Retry-After` header indicating how long the user agent should wait before making a follow-up request. For more information, see [Request limits](https://mews-systems.gitbook.io/connector-api/guidelines/requests#request-limits).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'500':
description: Unexpected error on the Mews side. This may be due to a software fault. If such a situation occurs, the error will be logged and the development team notified, however you can raise an issue through GitHub on our [documentation repository](https://github.com/MewsSystems/gitbook-connector-api).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
/api/connector/v1/products/getAll:
post:
tags:
- Products
summary: Get all products
description: Returns all products offered together with the specified services. Note this operation uses [Pagination](https://mews-systems.gitbook.io/connector-api/guidelines/pagination/) and supports [Portfolio Access Tokens](https://mews-systems.gitbook.io/connector-api/concepts/multi-property/).
operationId: products_getAll
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/ProductFilterParameters'
example:
ClientToken: E0D439EE522F44368DC78E1BFB03710C-D24FB11DBE31D4621C4817E028D9E1D
AccessToken: C66EF7B239D24632943D115EDE9CB810-EA00F8FD8294692C940F6B5A8F9453D
Client: Sample Client 1.0.0
ServiceIds:
- bd26d8db-86da-4f96-9efc-e5a4654a4a94
UpdatedUtc:
StartUtc: '2023-10-01T00:00:00Z'
EndUtc: '2023-10-31T00:00:00Z'
Limitation:
Count: 10
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/ProductResult'
example:
Products:
- Id: 198bc308-c1f2-4a1c-a827-c41d99d52f3d
ServiceId: bd26d8db-86da-4f96-9efc-e5a4654a4a94
CreatedUtc: '2023-10-01T11:48:57Z'
UpdatedUtc: '2023-10-28T11:48:57Z'
CategoryId: null
AccountingCategoryId: 6535e19e-1077-49d9-a338-67bf4ffecb14
IsActive: true
Names:
en-US: Breakfast
ExternalNames:
en-US: Breakfast
ShortNames:
en-US: BFST
Descriptions:
en-US: Nice continental breakfast.
ChargingMode: PerPersonPerTimeUnit
PostingMode: Once
Options:
BillAsPackage: false
Promotions:
BeforeCheckIn: false
AfterCheckIn: false
DuringStay: false
BeforeCheckOut: false
AfterCheckOut: false
DuringCheckOut: false
Classifications:
Food: false
Beverage: false
Wellness: false
CityTax: false
Price:
GrossValue: 25
Currency: EUR
TaxValues:
- Code: FR-T
ExternalIdentifier: PROD-BFST-009
CustomerProducts:
- Id: 198bc308-c1f2-4a1c-a827-c41d99d52f3d
ServiceId: bd26d8db-86da-4f96-9efc-e5a4654a4a94
CreatedUtc: '2023-10-01T11:48:57Z'
UpdatedUtc: '2023-10-28T11:48:57Z'
CategoryId: null
AccountingCategoryId: 6535e19e-1077-49d9-a338-67bf4ffecb14
IsActive: true
Names:
en-US: Breakfast
ExternalNames:
en-US: Breakfast
ShortNames:
en-US: BFST
Descriptions:
en-US: Nice continental breakfast.
ChargingMode: PerPersonPerTimeUnit
PostingMode: Once
Options:
BillAsPackage: false
Promotions:
BeforeCheckIn: false
AfterCheckIn: false
DuringStay: false
BeforeCheckOut: false
AfterCheckOut: false
DuringCheckOut: false
Classifications:
Food: false
Beverage: false
Wellness: false
CityTax: false
Price:
GrossValue: 25
Currency: EUR
TaxValues:
- Code: FR-T
ExternalIdentifier: PROD-BFST-009
Cursor: 198bc308-c1f2-4a1c-a827-c41d99d52f3d
'400':
description: Error caused by the client app, e.g. in case of malformed request or invalid identifier of a resource. In most cases, such an error signifies a bug in the client app (consumer of the API).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'401':
description: Error caused by usage of invalid ClientToken, AccessToken, or you may not have the necessary permission to use the endpoint.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'403':
description: Server error that should be reported to the end user of the client app. Happens for example when the server-side validation fails or when a business-logic check is violated.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'408':
description: Error caused by heavy request that takes too long to process (typically tens of seconds). To get around this, request data in smaller batches. For more information, see [Request timeouts](https://mews-systems.gitbook.io/connector-api/guidelines/requests#request-timeouts)
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'204':
description: Server has successfully fulfilled the request and there is no additional information to send back.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'429':
description: Error caused by too many requests sent in a given amount of time. Response contains `Retry-After` header indicating how long the user agent should wait before making a follow-up request. For more information, see [Request limits](https://mews-systems.gitbook.io/connector-api/guidelines/requests#request-limits).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'500':
description: Unexpected error on the Mews side. This may be due to a software fault. If such a situation occurs, the error will be logged and the development team notified, however you can raise an issue through GitHub on our [documentation repository](https://github.com/MewsSystems/gitbook-connector-api).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
/api/connector/v1/products/delete:
post:
tags:
- Products
summary: Delete products
description: Deletes specified products. This operation supports [Portfolio Access Tokens](https://mews-systems.gitbook.io/connector-api/concepts/multi-property/).
operationId: products_delete
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/ProductDeleteParameters'
example:
ClientToken: E0D439EE522F44368DC78E1BFB03710C-D24FB11DBE31D4621C4817E028D9E1D
AccessToken: C66EF7B239D24632943D115EDE9CB810-EA00F8FD8294692C940F6B5A8F9453D
Client: Sample Client 1.0.0
EnterpriseId: aff75fbb-5cce-4fae-8039-b07000d16650
ProductIds:
- 1f60b9de-c042-4841-bcab-b07000d2201f
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/Unit'
'400':
description: Error caused by the client app, e.g. in case of malformed request or invalid identifier of a resource. In most cases, such an error signifies a bug in the client app (consumer of the API).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'401':
description: Error caused by usage of invalid ClientToken, AccessToken, or you may not have the necessary permission to use the endpoint.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'403':
description: Server error that should be reported to the end user of the client app. Happens for example when the server-side validation fails or when a business-logic check is violated.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'408':
description: Error caused by heavy request that takes too long to process (typically tens of seconds). To get around this, request data in smaller batches. For more information, see [Request timeouts](https://mews-systems.gitbook.io/connector-api/guidelines/requests#request-timeouts)
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'204':
description: Server has successfully fulfilled the request and there is no additional information to send back.
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'429':
description: Error caused by too many requests sent in a given amount of time. Response contains `Retry-After` header indicating how long the user agent should wait before making a follow-up request. For more information, see [Request limits](https://mews-systems.gitbook.io/connector-api/guidelines/requests#request-limits).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
'500':
description: Unexpected error on the Mews side. This may be due to a software fault. If such a situation occurs, the error will be logged and the development team notified, however you can raise an issue through GitHub on our [documentation repository](https://github.com/MewsSystems/gitbook-connector-api).
content:
application/json:
schema:
$ref: '#/components/schemas/ConnectorApiExceptionResult'
components:
schemas:
TaxBreakdown:
title: Tax breakdown
required:
- Items
type: object
properties:
Items:
type: array
items:
$ref: '#/components/schemas/TaxBreakdownItem'
description: Tax breakdown items per each tax rate applied.
additionalProperties: false
x-schema-id: TaxBreakdown
RelativeProductPrice:
title: Relative product price
type: object
properties:
Multiplier:
type: number
format: double
deprecated: true
Target:
type: string
nullable: true
deprecated: true
TaxRateCodes:
type: array
items:
type: string
nullable: true
deprecated: true
ProductIds:
type: array
items:
type: string
format: uuid
nullable: true
deprecated: true
additionalProperties: false
description: ''
x-schema-id: RelativeProductPrice
ProductConsumptionMomentEnum:
title: Product consumption moment
enum:
- ServiceOrderEnd
- ServiceOrderStart
- PostingTimeUnit
- NextTimeUnit
type: string
description: '
ServiceOrderEnd
ServiceOrderStart
PostingTimeUnit
NextTimeUnit'
x-enumNames:
- ServiceOrderEnd
- ServiceOrderStart
- PostingTimeUnit
- NextTimeUnit
x-enumDescriptions:
- ''
- ''
- ''
- ''
Unit:
type: object
additionalProperties: false
ExtendedAmount:
title: Extended amount
required:
- Breakdown
- Currency
- GrossValue
- NetValue
- TaxValues
type: object
properties:
Currency:
minLength: 1
type: string
description: ISO-4217 code of the [Currency](https://mews-systems.gitbook.io/connector-api/operations/currencies/#currency).
format: currency
NetValue:
type: number
description: Net value without taxes.
format: double
GrossValue:
type: number
description: Gross value including all taxes.
format: double
TaxValues:
type: array
items:
$ref: '#/components/schemas/TaxValue'
description: The tax values applied.
Breakdown:
title: Tax breakdown
allOf:
- $ref: '#/components/schemas/TaxBreakdown'
description: Information about individual tax amounts.
Value:
type: number
format: double
nullable: true
Net:
type: number
format: double
nullable: true
Tax:
type: number
format: double
nullable: true
TaxRate:
type: number
format: double
nullable: true
additionalProperties: false
description: ''
x-schema-id: ExtendedAmount
Limitation:
title: Limitation
required:
- Count
type: object
properties:
Count:
type: integer
format: int32
Cursor:
type: string
format: uuid
nullable: true
additionalProperties: false
description: Limitation on the quantity of data returned.
x-schema-id: Limitation
ProductChargingModeEnum:
title: Product charging mode
enum:
- Once
- PerTimeUnit
- PerPersonPerTimeUnit
- PerPerson
type: string
description: '
Once
PerTimeUnit
PerPersonPerTimeUnit
PerPerson'
x-enumNames:
- Once
- PerTimeUnit
- PerPersonPerTimeUnit
- PerPerson
x-enumDescriptions:
- ''
- ''
- ''
- ''
TaxValue:
title: Tax value
required:
- Value
type: object
properties:
Code:
type: string
description: Code corresponding to tax type.
nullable: true
Value:
type: number
description: Amount of tax applied.
format: double
additionalProperties: false
x-schema-id: TaxValue
ProductOptions:
title: Product options
required:
- BillAsPackage
type: object
properties:
BillAsPackage:
type: boolean
description: Product should be displayed as part of a package.
additionalProperties: false
description: ''
x-schema-id: ProductOptions
TimeFilterInterval:
title: Time interval
type: object
properties:
StartUtc:
type: string
format: date-time
nullable: true
EndUtc:
type: string
format: date-time
nullable: true
additionalProperties: false
description: "When a time interval is used for **filtering** (for example in parameters such as `CreatedUtc.StartUtc` / `CreatedUtc.EndUtc`), the following rules apply:\r\n\r\n- **Start equals End (equality mode)** \r\n If `StartUtc` and `EndUtc` are exactly the same timestamp, the filter is treated as an equality check for that precise moment in time:\r\n \r\n ```\r\n CreatedUtc == StartUtc\r\n ```\r\n \r\n This does not represent an interval; only records with `CreatedUtc` equal to that exact instant are returned.\r\n\r\n- **Start differs from End (interval mode)** \r\n If `StartUtc` and `EndUtc` are different, the filter is evaluated as a half-open interval:\r\n \r\n ```\r\n StartUtc <= CreatedUtc < EndUtc\r\n ```\r\n \r\n In other words, the start is inclusive and the end is exclusive.\r\n\r\nMake sure your integration takes inclusive Start / exclusive End behavior of time intervals into account so that no records at the boundaries are omitted."
x-schema-id: TimeFilterInterval
Amount:
title: Amount
required:
- Breakdown
- Currency
- GrossValue
- NetValue
- TaxValues
type: object
properties:
Currency:
minLength: 1
type: string
description: ISO-4217 code of the [Currency](https://mews-systems.gitbook.io/connector-api/operations/currencies/#currency).
format: currency
NetValue:
type: number
description: Net value without taxes.
format: double
GrossValue:
type: number
description: Gross value including all taxes.
format: double
TaxValues:
type: array
items:
$ref: '#/components/schemas/TaxValue'
description: The tax values applied.
Breakdown:
title: Tax breakdown
allOf:
- $ref: '#/components/schemas/TaxBreakdown'
description: Information about individual tax amounts.
additionalProperties: false
description: ''
x-schema-id: Amount
Product:
title: Product
required:
- ChargingMode
- Classifications
- ConsumptionMoment
- CreatedUtc
- ExternalNames
- Id
- IsActive
- Names
- Options
- Ordering
- PostingMode
- Price
- Pricing
- Promotions
- ServiceId
- ShortNames
- UpdatedUtc
type: object
properties:
Id:
type: string
description: Unique identifier of the product.
format: uuid
ServiceId:
type: string
description: Unique identifier of the [Service](https://mews-systems.gitbook.io/connector-api/operations/services/#service).
format: uuid
CategoryId:
type: string
description: Unique identifier of the Product category.
format: uuid
nullable: true
AccountingCategoryId:
type: string
description: Unique identifier of [Accounting Category](https://mews-systems.gitbook.io/connector-api/operations/accountingcategories/#accounting-category).
format: uuid
nullable: true
IsActive:
type: boolean
description: Whether the product is still active.
IsDefault:
type: boolean
deprecated: true
Name:
type: string
description: Name of the product. **Deprecated!** Please use Names
nullable: true
deprecated: true
x-deprecatedMessage: Use `Names` instead.
Names:
title: Localized text
type: object
additionalProperties:
type: string
description: All translations of the name.
x-schema-id: LocalizedStrings
ExternalName:
type: string
description: Name of the product meant to be displayed to customer. **Deprecated!** Please use ExternalNames
nullable: true
deprecated: true
x-deprecatedMessage: Use `ExternalNames` instead.
ExternalNames:
title: Localized text
type: object
additionalProperties:
type: string
description: All translations of external name.
x-schema-id: LocalizedStrings
ShortName:
type: string
description: Short name of the product. **Deprecated!** Please use ShortNames
nullable: true
deprecated: true
x-deprecatedMessage: Use `ShortNames` instead.
ShortNames:
title: Localized text
type: object
additionalProperties:
type: string
description: All translations of short name.
x-schema-id: LocalizedStrings
Description:
type: string
description: Description of the product. **Deprecated!** Please use Descriptions
nullable: true
deprecated: true
x-deprecatedMessage: Use `Descriptions` instead.
Descriptions:
title: Localized text
type: object
additionalProperties:
type: string
description: All translations of descriptions.
nullable: true
x-schema-id: LocalizedStrings
Charging:
title: Product charging mode
allOf:
- $ref: '#/components/schemas/ProductChargingModeEnum'
description: '
Once
PerTimeUnit
# --- truncated at 32 KB (52 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/mews/refs/heads/main/openapi/mews-products-api-openapi.yml