Hotelumo Reservations API

The Reservations API from Hotelumo — 3 operation(s) for reservations.

GitHub OpenAPI

Operations 6

GET /api/reservations List reservations #
POST /api/reservations Create a reservation #
GET /api/reservations/{reservationId} Get a reservation #
PUT /api/reservations/{reservationId} Update a reservation #
DELETE /api/reservations/{reservationId} Delete a reservation #
POST /api/reservations/{reservationId}/approve Approve a requested reservation #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/hotelumo-com:hotelumo-com-reservations-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

hotelumo-com-reservations-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Hotelumo Reservations API
  version: 1.0.0
  description: 'Public REST API for Hotelumo. Authenticate with an API key created in the Hotelumo dashboard: send the base64-encoded key secret with HTTP Basic auth. Each key carries per-resource scopes like `reservations:read` or `rates:write`.'
servers:
- url: https://api.hotelumo.com
tags:
- name: Reservations
paths:
  /api/reservations:
    get:
      tags:
      - Reservations
      summary: List reservations
      description: Lists the reservations of your organization. Optionally filter by `hotelId`, `guestId`, a legacy `startTime`/`endTime` window, or an overlapping stay window with `stayDateFrom`/`stayDateTo`. Requires the `reservations:read` scope.
      security:
      - apiKey: []
      - accessToken: []
      parameters:
      - in: query
        name: hotelId
        schema:
          type: string
      - in: query
        name: guestId
        schema:
          type: string
      - in: query
        name: startTime
        schema:
          type: string
      - in: query
        name: endTime
        schema:
          type: string
      - in: query
        name: stayDateFrom
        description: Include stays checking out after this date
        schema:
          type: string
          format: date
      - in: query
        name: stayDateTo
        description: Include stays checking in on or before this date
        schema:
          type: string
          format: date
      - in: query
        name: limit
        schema:
          type: integer
          default: 0
      - in: query
        name: skip
        schema:
          type: integer
          default: 0
      - in: query
        name: sortField
        schema:
          type: string
          example: startTime
      - in: query
        name: sortDirection
        schema:
          type: string
          enum:
          - ASC
          - DESC
      - in: query
        name: fields
        description: Comma-separated projection of fields to return
        schema:
          type: string
      responses:
        '200':
          description: Array of reservations
        '401':
          description: Missing or invalid credentials
        '403':
          description: API key is missing the `reservations:read` scope
        '429':
          description: API key rate limit exceeded
      operationId: getApiReservations
      x-codeSamples:
      - lang: Node + Request
        source: "const request = require('request');\n\nconst options = {\n  method: 'GET',\n  url: 'https://api.hotelumo.com/api/reservations',\n  qs: {\n    hotelId: 'SOME_STRING_VALUE',\n    guestId: 'SOME_STRING_VALUE',\n    startTime: 'SOME_STRING_VALUE',\n    endTime: 'SOME_STRING_VALUE',\n    stayDateFrom: 'SOME_STRING_VALUE',\n    stayDateTo: 'SOME_STRING_VALUE',\n    limit: 'SOME_INTEGER_VALUE',\n    skip: 'SOME_INTEGER_VALUE',\n    sortField: 'startTime',\n    sortDirection: 'SOME_STRING_VALUE',\n    fields: 'SOME_STRING_VALUE'\n  },\n  headers: {Authorization: 'Basic REPLACE_BASIC_AUTH'}\n};\n\nrequest(options, function (error, response, body) {\n  if (error) throw new Error(error);\n\n  console.log(body);\n});\n"
      - lang: Shell + Curl
        source: "curl --request GET \\\n  --url 'https://api.hotelumo.com/api/reservations?hotelId=SOME_STRING_VALUE&guestId=SOME_STRING_VALUE&startTime=SOME_STRING_VALUE&endTime=SOME_STRING_VALUE&stayDateFrom=SOME_STRING_VALUE&stayDateTo=SOME_STRING_VALUE&limit=SOME_INTEGER_VALUE&skip=SOME_INTEGER_VALUE&sortField=startTime&sortDirection=SOME_STRING_VALUE&fields=SOME_STRING_VALUE' \\\n  --header 'Authorization: Basic REPLACE_BASIC_AUTH'"
      - lang: Shell + Httpie
        source: "http GET 'https://api.hotelumo.com/api/reservations?hotelId=SOME_STRING_VALUE&guestId=SOME_STRING_VALUE&startTime=SOME_STRING_VALUE&endTime=SOME_STRING_VALUE&stayDateFrom=SOME_STRING_VALUE&stayDateTo=SOME_STRING_VALUE&limit=SOME_INTEGER_VALUE&skip=SOME_INTEGER_VALUE&sortField=startTime&sortDirection=SOME_STRING_VALUE&fields=SOME_STRING_VALUE' \\\n  Authorization:'Basic REPLACE_BASIC_AUTH'"
      - lang: Python + Python3
        source: 'import http.client


          conn = http.client.HTTPSConnection("api.hotelumo.com")


          headers = { ''Authorization'': "Basic REPLACE_BASIC_AUTH" }


          conn.request("GET", "/api/reservations?hotelId=SOME_STRING_VALUE&guestId=SOME_STRING_VALUE&startTime=SOME_STRING_VALUE&endTime=SOME_STRING_VALUE&stayDateFrom=SOME_STRING_VALUE&stayDateTo=SOME_STRING_VALUE&limit=SOME_INTEGER_VALUE&skip=SOME_INTEGER_VALUE&sortField=startTime&sortDirection=SOME_STRING_VALUE&fields=SOME_STRING_VALUE", headers=headers)


          res = conn.getresponse()

          data = res.read()


          print(data.decode("utf-8"))'
      - lang: Php + Curl
        source: "<?php\n\n$curl = curl_init();\n\ncurl_setopt_array($curl, [\n  CURLOPT_URL => \"https://api.hotelumo.com/api/reservations?hotelId=SOME_STRING_VALUE&guestId=SOME_STRING_VALUE&startTime=SOME_STRING_VALUE&endTime=SOME_STRING_VALUE&stayDateFrom=SOME_STRING_VALUE&stayDateTo=SOME_STRING_VALUE&limit=SOME_INTEGER_VALUE&skip=SOME_INTEGER_VALUE&sortField=startTime&sortDirection=SOME_STRING_VALUE&fields=SOME_STRING_VALUE\",\n  CURLOPT_RETURNTRANSFER => true,\n  CURLOPT_ENCODING => \"\",\n  CURLOPT_MAXREDIRS => 10,\n  CURLOPT_TIMEOUT => 30,\n  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,\n  CURLOPT_CUSTOMREQUEST => \"GET\",\n  CURLOPT_HTTPHEADER => [\n    \"Authorization: Basic REPLACE_BASIC_AUTH\"\n  ],\n]);\n\n$response = curl_exec($curl);\n$err = curl_error($curl);\n\ncurl_close($curl);\n\nif ($err) {\n  echo \"cURL Error #:\" . $err;\n} else {\n  echo $response;\n}"
      - lang: Php + Http1
        source: "<?php\n\n$request = new HttpRequest();\n$request->setUrl('https://api.hotelumo.com/api/reservations');\n$request->setMethod(HTTP_METH_GET);\n\n$request->setQueryData([\n  'hotelId' => 'SOME_STRING_VALUE',\n  'guestId' => 'SOME_STRING_VALUE',\n  'startTime' => 'SOME_STRING_VALUE',\n  'endTime' => 'SOME_STRING_VALUE',\n  'stayDateFrom' => 'SOME_STRING_VALUE',\n  'stayDateTo' => 'SOME_STRING_VALUE',\n  'limit' => 'SOME_INTEGER_VALUE',\n  'skip' => 'SOME_INTEGER_VALUE',\n  'sortField' => 'startTime',\n  'sortDirection' => 'SOME_STRING_VALUE',\n  'fields' => 'SOME_STRING_VALUE'\n]);\n\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\ntry {\n  $response = $request->send();\n\n  echo $response->getBody();\n} catch (HttpException $ex) {\n  echo $ex;\n}"
      - lang: Php + Http2
        source: "<?php\n\n$client = new http\\Client;\n$request = new http\\Client\\Request;\n\n$request->setRequestUrl('https://api.hotelumo.com/api/reservations');\n$request->setRequestMethod('GET');\n$request->setQuery(new http\\QueryString([\n  'hotelId' => 'SOME_STRING_VALUE',\n  'guestId' => 'SOME_STRING_VALUE',\n  'startTime' => 'SOME_STRING_VALUE',\n  'endTime' => 'SOME_STRING_VALUE',\n  'stayDateFrom' => 'SOME_STRING_VALUE',\n  'stayDateTo' => 'SOME_STRING_VALUE',\n  'limit' => 'SOME_INTEGER_VALUE',\n  'skip' => 'SOME_INTEGER_VALUE',\n  'sortField' => 'startTime',\n  'sortDirection' => 'SOME_STRING_VALUE',\n  'fields' => 'SOME_STRING_VALUE'\n]));\n\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\n$client->enqueue($request)->send();\n$response = $client->getResponse();\n\necho $response->getBody();"
    post:
      tags:
      - Reservations
      summary: Create a reservation
      description: Creates a reservation (and its ReservationRooms from the `rooms` array). Requires the `reservations:write` scope.
      security:
      - apiKey: []
      - accessToken: []
      responses:
        '200':
          description: The created reservation
        '403':
          description: API key is missing the `reservations:write` scope
      operationId: postApiReservations
      x-codeSamples:
      - lang: Node + Request
        source: "const request = require('request');\n\nconst options = {\n  method: 'POST',\n  url: 'https://api.hotelumo.com/api/reservations',\n  headers: {Authorization: 'Basic REPLACE_BASIC_AUTH'}\n};\n\nrequest(options, function (error, response, body) {\n  if (error) throw new Error(error);\n\n  console.log(body);\n});\n"
      - lang: Shell + Curl
        source: "curl --request POST \\\n  --url https://api.hotelumo.com/api/reservations \\\n  --header 'Authorization: Basic REPLACE_BASIC_AUTH'"
      - lang: Shell + Httpie
        source: "http POST https://api.hotelumo.com/api/reservations \\\n  Authorization:'Basic REPLACE_BASIC_AUTH'"
      - lang: Python + Python3
        source: 'import http.client


          conn = http.client.HTTPSConnection("api.hotelumo.com")


          headers = { ''Authorization'': "Basic REPLACE_BASIC_AUTH" }


          conn.request("POST", "/api/reservations", headers=headers)


          res = conn.getresponse()

          data = res.read()


          print(data.decode("utf-8"))'
      - lang: Php + Curl
        source: "<?php\n\n$curl = curl_init();\n\ncurl_setopt_array($curl, [\n  CURLOPT_URL => \"https://api.hotelumo.com/api/reservations\",\n  CURLOPT_RETURNTRANSFER => true,\n  CURLOPT_ENCODING => \"\",\n  CURLOPT_MAXREDIRS => 10,\n  CURLOPT_TIMEOUT => 30,\n  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,\n  CURLOPT_CUSTOMREQUEST => \"POST\",\n  CURLOPT_HTTPHEADER => [\n    \"Authorization: Basic REPLACE_BASIC_AUTH\"\n  ],\n]);\n\n$response = curl_exec($curl);\n$err = curl_error($curl);\n\ncurl_close($curl);\n\nif ($err) {\n  echo \"cURL Error #:\" . $err;\n} else {\n  echo $response;\n}"
      - lang: Php + Http1
        source: "<?php\n\n$request = new HttpRequest();\n$request->setUrl('https://api.hotelumo.com/api/reservations');\n$request->setMethod(HTTP_METH_POST);\n\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\ntry {\n  $response = $request->send();\n\n  echo $response->getBody();\n} catch (HttpException $ex) {\n  echo $ex;\n}"
      - lang: Php + Http2
        source: "<?php\n\n$client = new http\\Client;\n$request = new http\\Client\\Request;\n\n$request->setRequestUrl('https://api.hotelumo.com/api/reservations');\n$request->setRequestMethod('POST');\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\n$client->enqueue($request)->send();\n$response = $client->getResponse();\n\necho $response->getBody();"
  /api/reservations/{reservationId}:
    get:
      tags:
      - Reservations
      summary: Get a reservation
      description: Returns a single reservation by id, with its `rooms`. Reservations belonging to another organization respond 404. Requires the `reservations:read` scope.
      security:
      - apiKey: []
      - accessToken: []
      parameters:
      - in: path
        name: reservationId
        required: true
        schema:
          type: string
      responses:
        '200':
          description: The reservation
        '404':
          description: Not found (or owned by another organization)
      operationId: getApiReservationsReservationId
      x-codeSamples:
      - lang: Node + Request
        source: "const request = require('request');\n\nconst options = {\n  method: 'GET',\n  url: 'https://api.hotelumo.com/api/reservations/%7BreservationId%7D',\n  headers: {Authorization: 'Basic REPLACE_BASIC_AUTH'}\n};\n\nrequest(options, function (error, response, body) {\n  if (error) throw new Error(error);\n\n  console.log(body);\n});\n"
      - lang: Shell + Curl
        source: "curl --request GET \\\n  --url https://api.hotelumo.com/api/reservations/%7BreservationId%7D \\\n  --header 'Authorization: Basic REPLACE_BASIC_AUTH'"
      - lang: Shell + Httpie
        source: "http GET https://api.hotelumo.com/api/reservations/%7BreservationId%7D \\\n  Authorization:'Basic REPLACE_BASIC_AUTH'"
      - lang: Python + Python3
        source: 'import http.client


          conn = http.client.HTTPSConnection("api.hotelumo.com")


          headers = { ''Authorization'': "Basic REPLACE_BASIC_AUTH" }


          conn.request("GET", "/api/reservations/%7BreservationId%7D", headers=headers)


          res = conn.getresponse()

          data = res.read()


          print(data.decode("utf-8"))'
      - lang: Php + Curl
        source: "<?php\n\n$curl = curl_init();\n\ncurl_setopt_array($curl, [\n  CURLOPT_URL => \"https://api.hotelumo.com/api/reservations/%7BreservationId%7D\",\n  CURLOPT_RETURNTRANSFER => true,\n  CURLOPT_ENCODING => \"\",\n  CURLOPT_MAXREDIRS => 10,\n  CURLOPT_TIMEOUT => 30,\n  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,\n  CURLOPT_CUSTOMREQUEST => \"GET\",\n  CURLOPT_HTTPHEADER => [\n    \"Authorization: Basic REPLACE_BASIC_AUTH\"\n  ],\n]);\n\n$response = curl_exec($curl);\n$err = curl_error($curl);\n\ncurl_close($curl);\n\nif ($err) {\n  echo \"cURL Error #:\" . $err;\n} else {\n  echo $response;\n}"
      - lang: Php + Http1
        source: "<?php\n\n$request = new HttpRequest();\n$request->setUrl('https://api.hotelumo.com/api/reservations/%7BreservationId%7D');\n$request->setMethod(HTTP_METH_GET);\n\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\ntry {\n  $response = $request->send();\n\n  echo $response->getBody();\n} catch (HttpException $ex) {\n  echo $ex;\n}"
      - lang: Php + Http2
        source: "<?php\n\n$client = new http\\Client;\n$request = new http\\Client\\Request;\n\n$request->setRequestUrl('https://api.hotelumo.com/api/reservations/%7BreservationId%7D');\n$request->setRequestMethod('GET');\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\n$client->enqueue($request)->send();\n$response = $client->getResponse();\n\necho $response->getBody();"
    put:
      tags:
      - Reservations
      summary: Update a reservation
      description: Updates a reservation by id. Reservations belonging to another organization respond 404. Requires the `reservations:write` scope.
      security:
      - apiKey: []
      - accessToken: []
      parameters:
      - in: path
        name: reservationId
        required: true
        schema:
          type: string
      responses:
        '200':
          description: The updated reservation
        '403':
          description: API key is missing the `reservations:write` scope
        '404':
          description: Not found (or owned by another organization)
      operationId: putApiReservationsReservationId
      x-codeSamples:
      - lang: Node + Request
        source: "const request = require('request');\n\nconst options = {\n  method: 'PUT',\n  url: 'https://api.hotelumo.com/api/reservations/%7BreservationId%7D',\n  headers: {Authorization: 'Basic REPLACE_BASIC_AUTH'}\n};\n\nrequest(options, function (error, response, body) {\n  if (error) throw new Error(error);\n\n  console.log(body);\n});\n"
      - lang: Shell + Curl
        source: "curl --request PUT \\\n  --url https://api.hotelumo.com/api/reservations/%7BreservationId%7D \\\n  --header 'Authorization: Basic REPLACE_BASIC_AUTH'"
      - lang: Shell + Httpie
        source: "http PUT https://api.hotelumo.com/api/reservations/%7BreservationId%7D \\\n  Authorization:'Basic REPLACE_BASIC_AUTH'"
      - lang: Python + Python3
        source: 'import http.client


          conn = http.client.HTTPSConnection("api.hotelumo.com")


          headers = { ''Authorization'': "Basic REPLACE_BASIC_AUTH" }


          conn.request("PUT", "/api/reservations/%7BreservationId%7D", headers=headers)


          res = conn.getresponse()

          data = res.read()


          print(data.decode("utf-8"))'
      - lang: Php + Curl
        source: "<?php\n\n$curl = curl_init();\n\ncurl_setopt_array($curl, [\n  CURLOPT_URL => \"https://api.hotelumo.com/api/reservations/%7BreservationId%7D\",\n  CURLOPT_RETURNTRANSFER => true,\n  CURLOPT_ENCODING => \"\",\n  CURLOPT_MAXREDIRS => 10,\n  CURLOPT_TIMEOUT => 30,\n  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,\n  CURLOPT_CUSTOMREQUEST => \"PUT\",\n  CURLOPT_HTTPHEADER => [\n    \"Authorization: Basic REPLACE_BASIC_AUTH\"\n  ],\n]);\n\n$response = curl_exec($curl);\n$err = curl_error($curl);\n\ncurl_close($curl);\n\nif ($err) {\n  echo \"cURL Error #:\" . $err;\n} else {\n  echo $response;\n}"
      - lang: Php + Http1
        source: "<?php\n\n$request = new HttpRequest();\n$request->setUrl('https://api.hotelumo.com/api/reservations/%7BreservationId%7D');\n$request->setMethod(HTTP_METH_PUT);\n\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\ntry {\n  $response = $request->send();\n\n  echo $response->getBody();\n} catch (HttpException $ex) {\n  echo $ex;\n}"
      - lang: Php + Http2
        source: "<?php\n\n$client = new http\\Client;\n$request = new http\\Client\\Request;\n\n$request->setRequestUrl('https://api.hotelumo.com/api/reservations/%7BreservationId%7D');\n$request->setRequestMethod('PUT');\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\n$client->enqueue($request)->send();\n$response = $client->getResponse();\n\necho $response->getBody();"
    delete:
      tags:
      - Reservations
      summary: Delete a reservation
      description: Deletes a reservation by id (cascading its rooms, folio and charges). Reservations belonging to another organization respond 404. Requires the `reservations:write` scope.
      security:
      - apiKey: []
      - accessToken: []
      parameters:
      - in: path
        name: reservationId
        required: true
        schema:
          type: string
      responses:
        '200':
          description: The deleted reservation
        '404':
          description: Not found (or owned by another organization)
      operationId: deleteApiReservationsReservationId
      x-codeSamples:
      - lang: Node + Request
        source: "const request = require('request');\n\nconst options = {\n  method: 'DELETE',\n  url: 'https://api.hotelumo.com/api/reservations/%7BreservationId%7D',\n  headers: {Authorization: 'Basic REPLACE_BASIC_AUTH'}\n};\n\nrequest(options, function (error, response, body) {\n  if (error) throw new Error(error);\n\n  console.log(body);\n});\n"
      - lang: Shell + Curl
        source: "curl --request DELETE \\\n  --url https://api.hotelumo.com/api/reservations/%7BreservationId%7D \\\n  --header 'Authorization: Basic REPLACE_BASIC_AUTH'"
      - lang: Shell + Httpie
        source: "http DELETE https://api.hotelumo.com/api/reservations/%7BreservationId%7D \\\n  Authorization:'Basic REPLACE_BASIC_AUTH'"
      - lang: Python + Python3
        source: 'import http.client


          conn = http.client.HTTPSConnection("api.hotelumo.com")


          headers = { ''Authorization'': "Basic REPLACE_BASIC_AUTH" }


          conn.request("DELETE", "/api/reservations/%7BreservationId%7D", headers=headers)


          res = conn.getresponse()

          data = res.read()


          print(data.decode("utf-8"))'
      - lang: Php + Curl
        source: "<?php\n\n$curl = curl_init();\n\ncurl_setopt_array($curl, [\n  CURLOPT_URL => \"https://api.hotelumo.com/api/reservations/%7BreservationId%7D\",\n  CURLOPT_RETURNTRANSFER => true,\n  CURLOPT_ENCODING => \"\",\n  CURLOPT_MAXREDIRS => 10,\n  CURLOPT_TIMEOUT => 30,\n  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,\n  CURLOPT_CUSTOMREQUEST => \"DELETE\",\n  CURLOPT_HTTPHEADER => [\n    \"Authorization: Basic REPLACE_BASIC_AUTH\"\n  ],\n]);\n\n$response = curl_exec($curl);\n$err = curl_error($curl);\n\ncurl_close($curl);\n\nif ($err) {\n  echo \"cURL Error #:\" . $err;\n} else {\n  echo $response;\n}"
      - lang: Php + Http1
        source: "<?php\n\n$request = new HttpRequest();\n$request->setUrl('https://api.hotelumo.com/api/reservations/%7BreservationId%7D');\n$request->setMethod(HTTP_METH_DELETE);\n\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\ntry {\n  $response = $request->send();\n\n  echo $response->getBody();\n} catch (HttpException $ex) {\n  echo $ex;\n}"
      - lang: Php + Http2
        source: "<?php\n\n$client = new http\\Client;\n$request = new http\\Client\\Request;\n\n$request->setRequestUrl('https://api.hotelumo.com/api/reservations/%7BreservationId%7D');\n$request->setRequestMethod('DELETE');\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\n$client->enqueue($request)->send();\n$response = $client->getResponse();\n\necho $response->getBody();"
  /api/reservations/{reservationId}/approve:
    post:
      tags:
      - Reservations
      summary: Approve a requested reservation
      description: Rechecks inventory, promotes the parent to CONFIRMED and each PENDING room to CONFIRMED, then starts the normal folio/reminder workflow. Requires the `reservations:write` scope.
      security:
      - apiKey: []
      - accessToken: []
      responses:
        '200':
          description: Approved reservation
        '409':
          description: The request cannot be approved or inventory changed
      operationId: postApiReservationsReservationIdApprove
      x-codeSamples:
      - lang: Node + Request
        source: "const request = require('request');\n\nconst options = {\n  method: 'POST',\n  url: 'https://api.hotelumo.com/api/reservations/%7BreservationId%7D/approve',\n  headers: {Authorization: 'Basic REPLACE_BASIC_AUTH'}\n};\n\nrequest(options, function (error, response, body) {\n  if (error) throw new Error(error);\n\n  console.log(body);\n});\n"
      - lang: Shell + Curl
        source: "curl --request POST \\\n  --url https://api.hotelumo.com/api/reservations/%7BreservationId%7D/approve \\\n  --header 'Authorization: Basic REPLACE_BASIC_AUTH'"
      - lang: Shell + Httpie
        source: "http POST https://api.hotelumo.com/api/reservations/%7BreservationId%7D/approve \\\n  Authorization:'Basic REPLACE_BASIC_AUTH'"
      - lang: Python + Python3
        source: 'import http.client


          conn = http.client.HTTPSConnection("api.hotelumo.com")


          headers = { ''Authorization'': "Basic REPLACE_BASIC_AUTH" }


          conn.request("POST", "/api/reservations/%7BreservationId%7D/approve", headers=headers)


          res = conn.getresponse()

          data = res.read()


          print(data.decode("utf-8"))'
      - lang: Php + Curl
        source: "<?php\n\n$curl = curl_init();\n\ncurl_setopt_array($curl, [\n  CURLOPT_URL => \"https://api.hotelumo.com/api/reservations/%7BreservationId%7D/approve\",\n  CURLOPT_RETURNTRANSFER => true,\n  CURLOPT_ENCODING => \"\",\n  CURLOPT_MAXREDIRS => 10,\n  CURLOPT_TIMEOUT => 30,\n  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,\n  CURLOPT_CUSTOMREQUEST => \"POST\",\n  CURLOPT_HTTPHEADER => [\n    \"Authorization: Basic REPLACE_BASIC_AUTH\"\n  ],\n]);\n\n$response = curl_exec($curl);\n$err = curl_error($curl);\n\ncurl_close($curl);\n\nif ($err) {\n  echo \"cURL Error #:\" . $err;\n} else {\n  echo $response;\n}"
      - lang: Php + Http1
        source: "<?php\n\n$request = new HttpRequest();\n$request->setUrl('https://api.hotelumo.com/api/reservations/%7BreservationId%7D/approve');\n$request->setMethod(HTTP_METH_POST);\n\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\ntry {\n  $response = $request->send();\n\n  echo $response->getBody();\n} catch (HttpException $ex) {\n  echo $ex;\n}"
      - lang: Php + Http2
        source: "<?php\n\n$client = new http\\Client;\n$request = new http\\Client\\Request;\n\n$request->setRequestUrl('https://api.hotelumo.com/api/reservations/%7BreservationId%7D/approve');\n$request->setRequestMethod('POST');\n$request->setHeaders([\n  'Authorization' => 'Basic REPLACE_BASIC_AUTH'\n]);\n\n$client->enqueue($request)->send();\n$response = $client->getResponse();\n\necho $response->getBody();"
components:
  securitySchemes:
    apiKey:
      type: http
      scheme: basic
      description: 'HTTP Basic auth carrying only the API key secret: `Authorization: Basic base64(<key secret>)`.'
    accessToken:
      type: apiKey
      in: header
      name: Authorization
      description: 'Operator session token issued by the Hotelumo dashboard: `Authorization: Token <access token>`.'