---
title: "Update availability blocks"
method: POST
path: "/api/connector/v1/availabilityBlocks/update"
tags: ["Availability blocks"]
---

# Update availability blocks

`POST /api/connector/v1/availabilityBlocks/update`

Updates information about the specified `Availability block`. Note this operation supports [Portfolio Access Tokens](https://mews-systems.gitbook.io/connector-api/concepts/multi-property/).

## Request body

- MultipleAvailabilityBlockUpdateParameters
  - `ClientToken` string, required — Token identifying the client application.
  - `AccessToken` string, required — Access token of the client application.
  - `Client` string, required — Name and version of the client application.
  - `EnterpriseId` string, uuid, nullable — Unique identifier of the enterprise. Required when using [Portfolio Access Tokens](https://mews-systems.gitbook.io/connector-api/concepts/multi-property), ignored otherwise.
  - `AvailabilityBlocks` AvailabilityBlockUpdateParameters[], required — Availability blocks to be updated.
    - `AvailabilityBlockId` string, uuid — Unique identifier of the [Availability block](https://mews-systems.gitbook.io/connector-api/operations/availabilityblocks#availability-block).
    - `Name` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `FirstTimeUnitStartUtc` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `LastTimeUnitStartUtc` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `ExternalIdentifier` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `State` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `ReservationPurpose` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `CompanyId` GuidNullableUpdateValue
      - `Value` string, uuid, nullable — Value which is to be updated.
    - `TravelAgencyId` GuidNullableUpdateValue
      - `Value` string, uuid, nullable — Value which is to be updated.
    - `BookerId` GuidNullableUpdateValue
      - `Value` string, uuid, nullable — Value which is to be updated.
    - `Notes` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `Budget` UpdateValueCurrencyValueOld
      - `Value` CurrencyValueOld — Total price of the reservation.
        - `Currency` string, currency, required
        - `Value` number, double, nullable
        - `Net` number, double, nullable
        - `Tax` number, double, nullable
        - `TaxRate` number, double, nullable
    - `CancellationReason` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `CancellationReasonDetail` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `RollingReleaseOffset` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `ReleasedUtc` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `ReleaseStrategy` ReleaseStrategyUpdateValue
      - `Value` 'FixedRelease' | 'RollingRelease' | 'None' — The strategy for automatic release of the availability block. FixedRelease (The availability block is released at a fixed time.) RollingRelease (Each availability adjustment is released at a fixed offset from its start.) None (The availability block is not automatically released.)
    - `QuoteId` GuidNullableUpdateValue
      - `Value` string, uuid, nullable — Value which is to be updated.
    - `PurchaseOrderNumber` StringUpdateValue
      - `Value` string, nullable — Value which is to be updated.
    - `BusinessSegmentId` GuidNullableUpdateValue
      - `Value` string, uuid, nullable — Value which is to be updated.

## Response `200`

OK

- AvailabilityBlockAddResult
  - `AvailabilityBlocks` AvailabilityBlock[], required — Availability blocks.
    - `Id` string, uuid — Unique identifier of the availability block.
    - `EnterpriseId` string, uuid — Unique identifier of the [enterprise](https://mews-systems.gitbook.io/connector-api/operations/enterprises#enterprise).
    - `ServiceId` string, uuid — Unique identifier of the `Service` the block is assigned to.
    - `RateId` string, uuid — Unique identifier of the `Rate` assigned to the block. Availability block is always created with a new dedicated rate so this value differs from `TemplateRateId` or `RateId` provided in the request.
    - `VoucherId` string, uuid, nullable — Unique identifier of the `Voucher` used to access specified private `Rate`.
    - `BookerId` string, uuid, nullable — Unique identifier of the `Customer` on whose behalf the block was made.
    - `CompanyId` string, uuid, nullable — Unique identifier of the `Company` linked to the block.
    - `TravelAgencyId` string, uuid, nullable — Unique identifier of `Company`with `Travel agency contract` the Availability Block is related to.
    - `Budget` CurrencyValueOld — Total price of the reservation.
      - `Currency` string, currency, required
      - `Value` number, double, nullable
      - `Net` number, double, nullable
      - `Tax` number, double, nullable
      - `TaxRate` number, double, nullable
    - `State` 'Confirmed' | 'Optional' | 'Inquired' | 'Canceled', required — Confirmed (The block deducts availability and can have reservations assigned.) Optional (The block deducts availability and cannot have reservations assigned.) Inquired (The block does not deduct availability and cannot have reservations assigned (waitlist).) Canceled (The block does not deduct availability and cannot have reservations assigned (waitlist).)
    - `ReservationPurpose` 'Leisure' | 'Business' | 'Student' — Leisure Business Student
    - `CreatedUtc` string, required — Creation date and time of the block in UTC timezone in ISO 8601 format.
    - `UpdatedUtc` string, required — Last update date and time of the block in UTC timezone in ISO 8601 format.
    - `FirstTimeUnitStartUtc` string, required — Start of the time interval, expressed as the timestamp for the start of the first time unit, in UTC timezone ISO 8601 format. See [Time units](https://mews-systems.gitbook.io/connector-api/concepts/time-units).
    - `LastTimeUnitStartUtc` string, required — End of the time interval, expressed as the timestamp for the start of the last time unit, in UTC timezone ISO 8601 format. See [Time units](https://mews-systems.gitbook.io/connector-api/concepts/time-units).
    - `ReleasedUtc` string, nullable — The moment when the block and its availability is released in UTC timezone in ISO 8601 format. Mutually exclusive with `RollingReleaseOffset`; the block will not be automatically released if neither `ReleasedUtc` nor `RollingReleaseOffset` is specified.
    - `RollingReleaseOffset` string, nullable — Exact offset from the start of availability adjustments to the moment the individual days in the adjustment should be released, in ISO 8601 duration format. A positive offset means the release happens before the start of the availability adjustment, a negative offset means it happens after the start. Mutually exclusive with `ReleasedUtc`; the block will not be automatically released if neither `ReleasedUtc` nor `RollingReleaseOffset` is specified.
    - `ExternalIdentifier` string, nullable — Identifier of the block from external system.
    - `Name` string, nullable — The name of the block in Mews.
    - `Notes` string, nullable — Additional notes of the block.
    - `PickupDistribution` 'AllInOneGroup' | 'IndividualGroups', required — AllInOneGroup (All created reservations in the block are added to the same reservation group.) IndividualGroups (Reservations can be picked up in multiple groups, with up to 750 reservations per group.)
    - `IsActive` boolean, required — Whether the `Availability Block` is still active.
    - `QuoteId` string, uuid, nullable — Unique identifier of the Mews Events quote associated with the availability block.
    - `AvailabilityBlockNumber` string, required — Unique number for a specific availability block within the Mews system.
    - `ReleaseStrategy` 'FixedRelease' | 'RollingRelease' | 'None', required — The strategy for automatic release of the availability block. FixedRelease (The availability block is released at a fixed time.) RollingRelease (Each availability adjustment is released at a fixed offset from its start.) None (The availability block is not automatically released.)
    - `PurchaseOrderNumber` string, nullable — Unique number of the purchase order. This number is propagated to any newly picked up `Reservation` within the block.
    - `BusinessSegmentId` string, uuid, nullable, required — Unique identifier of the associated `Business segment`.
    - `CanceledUtc` string, date-time, nullable — Date and time of the block cancellation in UTC timezone in ISO 8601 format.
    - `CancellationReason` 'Other' | 'ConfirmationMissed' | 'BookedElsewhere' | 'ForceMajeure' | 'GuestComplaint' | 'NoShow' | 'PriceTooHigh' | 'ServiceNotAvailable' | 'InputError' | 'InvalidPayment' | 'TravelAgency' | 'RequestedByGuest' | 'Update' | 'BookingAbandoned' | 'RequestedByBooker' — Other ConfirmationMissed BookedElsewhere ForceMajeure GuestComplaint NoShow PriceTooHigh ServiceNotAvailable InputError InvalidPayment TravelAgency RequestedByGuest Update BookingAbandoned RequestedByBooker
    - `CancellationReasonDetail` string, nullable — Additional details of availability block cancellation.

## Other responses

- `204` — Server has successfully fulfilled the request and there is no additional information to send back.
- `400` — 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).
- `401` — Error caused by usage of invalid ClientToken, AccessToken, or you may not have the necessary permission to use the endpoint.
- `403` — 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.
- `408` — 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)
- `429` — 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).
- `500` — 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).

---

[API](https://skmtc.net/mews/apis/connector-api.md) · [All operations](https://skmtc.net/mews/apis/connector-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/mews/connector-api/revisions/81933a8ff730/schema)
