Update booking statuses

patch

/rest/ofscCapacity/v1/bookingStatuses

This operation updates the booking statuses (that is, open or closed) based on the specified request parameters.

Request

Body ()
The schema of the request body parameters.
Root Schema : Booking Status Request List
Type: object
Title: Booking Status Request List
The array of booking statuses.
Show Source
Nested Schema : items
Type: array
Show Source
Nested Schema : bookingStatusCollection
Type: object
Show Source
Nested Schema : Statuses
Type: array
Title: Statuses
The array of booking statuses.
Show Source
Nested Schema : bookingStatusNode
Type: object
Show Source
Back to Top

Response

Supported Media Types

200 Response

This section describes the 200 status response for this operation.
Body ()
Root Schema : ResultBookingStatusObject
Type: object
Show Source
Nested Schema : Results
Type: object
Title: Results
An array containing the results of the operation.
Show Source
Nested Schema : Errors
Type: array
Title: Errors
The array of failed operations.
Show Source
Nested Schema : items
Type: object
Show Source
Nested Schema : Error Detail
Type: object
Title: Error Detail
The details of the error.
Show Source
Nested Schema : Operation
Type: object
Title: Operation
The operation that caused the error.
Show Source

Default Response

This section describes the default error response for this operation.
Body ()
Root Schema : Error
Type: object
Error response
Show Source
Back to Top

Examples

The following example shows how to update a booking status by submitting a PATCH request on the REST resource.

Example of Request Header

The following shows an example of the request header.

PATCH /rest/ofscCapacity/v1/bookingStatuses
Connection: close
Accept-Encoding: gzip,deflate
Authorization: Basic bXlyb290QHFhNTUwMzox
Host: <instance_name>.etadirect.com
User-Agent: Apache-HttpClient/4.1.1 (java 1.5)

Example of Request Body

The following example shows the contents of the request body in JSON format.

{"items": [{
   "date": "2017-08-23",
   "area": "CapacityArea",
   "statuses": [
    {
         "category": "IN",
         "state": "closed"
      
    }
    ]
}]}

Example of Response Header

The following shows an example of the response header.

HTTP/1.1 200 OK
Server: nginx
Date: Wed, 23 Aug 2017 13:09:35 GMT
Content-Type: application/json; charset=utf-8
Transfer-Encoding: chunked
Connection: keep-alive
Access-Control-Allow-Credentials: true
Strict-Transport-Security: max-age=31536000; includeSubDomains;

Example of Response Body

The following example shows the contents of the response body in JSON format.

{
    "results": {
        "updatedFieldCount": 2,
        "notChangedFieldCount": 0,
        "errors": []
    }
}
Back to Top