Connector API
  • Mews Connector API
  • Getting started
  • Usage guidelines
    • Authentication
    • Requests
    • Responses
    • Environments
    • Serialization
    • Pagination
    • Best practices
  • Concepts
    • Multi-property
    • Restrictions
    • Taxation
    • Time units
  • Use cases
    • 'How to' use cases
    • Accounting
    • Customer loyalty
    • Customer management
    • Customer messaging
    • Data export
    • Device integration
    • Events
    • Guest technology
    • Housekeeping
    • Kiosk
    • Mews Payment Terminals
    • Payment automation
    • Point of sale
    • Reputation management
    • Revenue management
    • Upsell
  • API Operations
    • Common objects
    • Accounting categories
    • Accounting items
    • Accounts
    • Account notes
    • Addresses
    • Age categories
    • Availability adjustments
    • Availability blocks
    • Billing automations
    • Bills
    • Business segments
    • Cancellation policies
    • Cashiers
    • Cashier transactions
    • Commands
    • Companies
    • Companionships
    • Company contracts
    • Configuration
    • Counters
    • Countries
    • Credit cards
    • Currencies
    • Customers
    • Departments
    • Devices
    • Enterprises
    • Exchange rates
    • Exports
    • Identity documents
    • Images
    • Languages
    • Loyalty memberships
    • Loyalty programs
    • Loyalty tiers
    • Messages
    • Message threads
    • Order items
    • Orders
    • Outlet bills
    • Outlet items
    • Outlets
    • Payments
    • Payment requests
    • Preauthorizations
    • Product categories
    • Product service orders
    • Products
    • Rates
    • Rate groups
    • Reservations
    • Reservation groups
    • Resource access tokens
    • Resource blocks
    • Resources
    • Resource categories
    • Resource features
    • Restrictions
    • Routing rules
    • Rules
    • Service order notes
    • Service overbooking limits
    • Services
    • Source assignments
    • Sources
    • Tasks
    • Tax environments
    • Taxations
    • Vouchers
    • Voucher codes
  • API Events
    • Ways to communicate
    • General Webhooks
    • Integration Webhooks
    • Webhooks FAQ
    • WebSockets
  • Your integration journey
    • Certification
  • Deprecations
    • Migration guide: Get all reservations
  • Changelog
    • Changelog 2024
    • Changelog 2023
    • Changelog 2022
    • Changelog 2021
    • Changelog 2020
    • Changelog 2019
    • Changelog 2018
    • Changelog 2017
    • Changelog 2016
Powered by GitBook
On this page
  • Get all resource blocks
  • Request
  • Response
  • Add resource block
  • Request
  • Response
  • Delete resource blocks
  • Request
  • Response

Was this helpful?

  1. API Operations

Resource blocks

PreviousResource access tokensNextResources

Last updated 4 months ago

Was this helpful?

Get all resource blocks

Returns all resource blocks (out of order blocks or internal use blocks). Note this operation uses and supports .

Request

[PlatformAddress]/api/connector/v1/resourceBlocks/getAll

{
    "ClientToken": "E0D439EE522F44368DC78E1BFB03710C-D24FB11DBE31D4621C4817E028D9E1D",
    "AccessToken": "C66EF7B239D24632943D115EDE9CB810-EA00F8FD8294692C940F6B5A8F9453D",
    "Client": "Sample Client 1.0.0",
    "EnterpriseIds": [
        "3fa85f64-5717-4562-b3fc-2c963f66afa6",
        "4d0201db-36f5-428b-8d11-4f0a65e960cc"
    ],
    "ResourceBlockIds": [
        "c478f1b3-7edb-4ccc-8f07-dd32fae1ca70"
    ],
    "AssignedResourceIds": [
        "b64f088d-49b5-4d5f-9766-2e27c4b75e27"
    ],
    "CollidingUtc": {
        "StartUtc": "2020-01-25T00:00:00Z",
        "EndUtc": "2020-01-30T00:00:00Z"
    },
    "CreatedUtc": {
        "StartUtc": "2020-01-05T00:00:00Z",
        "EndUtc": "2020-01-10T00:00:00Z"
    },
    "UpdatedUtc": {
        "StartUtc": "2020-01-15T00:00:00Z",
        "EndUtc": "2020-01-20T00:00:00Z"
    },
    "Extent": {
        "Inactive": true
    },
    "Limitation": { "Count": 10 }
}
Property
Type
Contract
Description

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.

EnterpriseIds

array of string

optional, max 1000 items

ResourceBlockIds

array of string

optional, max 1000 items

AssignedResourceIds

array of string

optional, max 1000 items

CollidingUtc

optional, max length 3 months

CreatedUtc

optional, max length 3 months

UpdatedUtc

optional, max length 3 months

Extent

required

Extent of data to be returned.

Limitation

required

Limitation on the quantity of data returned.

Resource block extent

Property
Type
Contract
Description

Inactive

bool

required

Whether the response should contain inactive entities.

Response

{
    "ResourceBlocks": [
        {
            "AssignedResourceId": "5ee074b1-6c86-48e8-915f-c7aa4702086f",
            "CreatedUtc": "2016-03-29T22:02:34Z",
            "EndUtc": "2016-01-01T16:00:00Z",
            "Id": "5ab9d519-2485-4d77-85c4-2a619cbdc4e7",
            "IsActive": true,
            "StartUtc": "2016-01-01T10:00:00Z",
            "Type": "InternalUse",
            "UpdatedUtc": "2016-03-29T22:02:34Z",
            "Name": "Resource block 1",
            "Notes": "Note"
        },
        {
            "AssignedResourceId": "f7c4b4f5-ac83-4977-a41a-63d27cc6e3e9",
            "CreatedUtc": "2016-03-29T15:14:06Z",
            "EndUtc": "2016-01-01T16:00:00Z",
            "Id": "4d98ad40-a726-409e-8bf3-2c12ff3c0331",
            "IsActive": true,
            "StartUtc": "2016-01-01T10:00:00Z",
            "Type": "OutOfOrder",
            "UpdatedUtc": "2016-03-29T15:14:06Z",
            "Name": "Resource block 2",
            "Notes": null
        }
    ]
}
Property
Type
Contract
Description

ResourceBlocks

required

The resource blocks colliding with the interval or matching the Id parameters.

Resource block

Property
Type
Contract
Description

Id

string

required

Unique identifier of the block.

AssignedResourceId

string

required

IsActive

bool

required

Whether the block is still active.

Type

required

Type of the resource block.

StartUtc

string

required

Start of the block in UTC timezone in ISO 8601 format.

EndUtc

string

required

End of the block in UTC timezone in ISO 8601 format.

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.

Name

string

required

Name of the resource block.

Notes

string

optional

Note describing the resource block.

Resource block type

  • OutOfOrder

  • InternalUse

Add resource block

Adds a new resource block to the specified resource for a defined period of time.

Request

[PlatformAddress]/api/connector/v1/resourceBlocks/add

{
    "ClientToken": "E0D439EE522F44368DC78E1BFB03710C-D24FB11DBE31D4621C4817E028D9E1D",
    "AccessToken": "C66EF7B239D24632943D115EDE9CB810-EA00F8FD8294692C940F6B5A8F9453D",
    "Client": "Sample Client 1.0.0",
    "ResourceBlocks": [
        {
            "ResourceId": "0d71d44e-3d85-4506-9b6f-aab500b69c52",
            "Name": "Resource block 1",
            "StartUtc": "2019-10-15T10:00:00Z",
            "EndUtc": "2019-10-20T10:00:00Z",
            "Type": "OutOfOrder",
            "Notes": "Note"
        },
        {
            "ResourceId": "f7c4b4f5-ac83-4977-a41a-63d27cc6e3e9",
            "Name": "Resource block 2",
            "StartUtc": "2019-10-15T10:00:00Z",
            "EndUtc": "2019-10-20T10:00:00Z",
            "Type": "InternalUse",
            "Notes": "Note"
        }
    ]   
}
Property
Type
Contract
Description

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.

ResourceBlocks

required

Resource block parameters.

Resource block parameters

Property
Type
Contract
Description

ResourceId

string

required

Name

string

required

Name of the resource block.

StartUtc

string

required

Start of the interval in UTC timezone in ISO 8601 format.

EndUtc

string

required

End of the interval in UTC timezone in ISO 8601 format.

Type

required

Type of the resource block.

Notes

string

optional

Note describing the resource block.

Response

{
    "ResourceBlocks": [
        {
            "Id": "0913bd1d-69fc-4bcb-82d3-5a40520c8fb0",
            "AssignedResourceId": "0d71d44e-3d85-4506-9b6f-aab500b69c52",
            "Name": "Resource block 1",
            "StartUtc": "2019-10-15T10:00:00Z",
            "EndUtc": "2019-10-20T10:00:00Z",
            "Type": "OutOfOrder",
            "CreatedUtc": "2016-06-01T15:14:06Z",
            "UpdatedUtc": "2016-06-01T15:14:06Z"
        },
        {
            "Id": "4d98ad40-a726-409e-8bf3-2c12ff3c0331",
            "AssignedResourceId": "f7c4b4f5-ac83-4977-a41a-63d27cc6e3e9",
            "Name": "Resource block 2",
            "StartUtc": "2019-10-15T10:00:00Z",
            "EndUtc": "2019-10-20T10:00:00Z",
            "Type": "InternalUse",
            "CreatedUtc": "2016-06-01T15:14:06Z",
            "UpdatedUtc": "2016-06-01T15:14:06Z"
        }
    ]
}
Property
Type
Contract
Description

ResourceBlocks

required

Resource blocks added.

Delete resource blocks

Removes specified resource blocks from the resources.

Request

[PlatformAddress]/api/connector/v1/resourceBlocks/delete

{
    "ClientToken": "E0D439EE522F44368DC78E1BFB03710C-D24FB11DBE31D4621C4817E028D9E1D",
    "AccessToken": "C66EF7B239D24632943D115EDE9CB810-EA00F8FD8294692C940F6B5A8F9453D",
    "Client": "Sample Client 1.0.0",
    "ResourceBlockIds": [
        "bf1e10b7-8a03-4675-9e27-05fc84312a58",
        "e8fb6bfb-d64a-4e7c-acfe-ab0400d01183"
    ]
}
Property
Type
Contract
Description

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.

ResourceBlockIds

array of string

required

Response

{}

Unique identifiers of the . If not specified, the operation returns data for all enterprises within scope of the Access Token.

Unique identifiers of the requested .

Unique identifiers of the requested Assigned .

Interval in which the is active.

Interval in which the was created.

Interval in which the was updated.

array of

Unique identifier of the assigned .

string

array of

Unique identifier of .

string

array of

Unique identifier of to be removed.

Pagination
Portfolio Access Tokens
Resource blocks
Resource block
Resource block
Resource block
Resource block extent
Resource block
Resource block type
Resource block parameters
Resource block type
Resource blocks
Resource blocks
Limitation
Resources
Resource
Resource
Enterprises
Time interval
Time interval
Time interval