Retrieve bookings

Retrieve bookings

#b2b

https://api.worldota.net/api/b2b/v3/hotel/order/info/

The call gets the order data of the successfully finished booking.

ℹ️

It is recommended that there should be a time gap between:

  • Receiving the booking confirmation.
  • Requesting the order information.

Request example

curl --user '<KEY_ID>:<API_KEY>' 'https://api.worldota.net/api/b2b/v3/hotel/order/info/' \
--header 'Content-Type: application/json' \
--data '{
  "ordering": {
    "ordering_type": "desc",
    "ordering_by": "created_at"
  },
  "pagination": {
    "page_size": "10",
    "page_number": "1"
  }, 
  "search": {
    "created_at": {
      "from_date": "2018-12-05T00:00"
    }
  },
  "language": "en"
}'

Request body

Response

Response example

{
  "data": {
    "current_page_number": 1,
    "found_orders": 6,
    "found_pages": 6,
    "orders": [
      {
        "agreement_number": null,
        "amount_payable": {
          "amount": "92.73",
          "currency_code": "EUR"
        },
        "amount_payable_vat": {
          "amount": "0",
          "currency_code": "EUR"
        },
        "amount_payable_with_upsells": {
          "amount": "92.73",
          "currency_code": "EUR"
        },
        "amount_refunded": {
          "amount": "0",
          "currency_code": "EUR"
        },
        "amount_sell": {
          "amount": "92.73",
          "currency_code": "EUR"
        },
        "amount_sell_b2b2c": {
          "amount": "200.00",
          "currency_code": "EUR"
        },
        "amount_sell_b2b2c_commission": {
          "amount": "16.80",
          "currency_code": "EUR"
        },
        "api_auth_key_id": 1304,
        "cancellation_info": {
          "free_cancellation_before": "2025-02-13T22:00:00",
          "policies": [
            {
              "end_at": "2025-02-13T22:00:00",
              "penalty": {
                "amount": "0",
                "amount_info": {
                  "amount_commission": "0",
                  "amount_gross": "0",
                  "amount_net": "0"
                },
                "currency_code": "EUR"
              },
              "start_at": null
            },
            {
              "end_at": null,
              "penalty": {
                "amount": "10",
                "amount_info": {
                  "amount_commission": "0.2",
                  "amount_gross": "2",
                  "amount_net": "1.8"
                },
                "currency_code": "EUR"
              },
              "start_at": "2025-02-13T22:00:00"
            }
          ]
        },
        "cancelled_at": null,
        "checkin_at": "2025-02-14",
        "checkout_at": "2025-02-15",
        "contract_slug": "only.look.no.book",
        "created_at": "2024-12-04T16:40:37",
        "has_tickets": false,
        "hotel_data": {
          "hid": 8473727,
          "id": "test_hotel_do_not_book",
          "order_id": null
        },
        "invoice_id": null,
        "is_cancellable": true,
        "is_checked": false,
        "meta_data": {
          "voucher_order_comment": null
        },
        "modified_at": "2024-12-04T16:44:35",
        "nights": 1,
        "order_id": 708366118,
        "order_type": "hotel",
        "partner_data": {
          "order_comment": null,
          "order_id": "test_hotel_do_not_booking"
        },
        "payment_data": {
          "invoice_id": null,
          "invoice_id_v2": null,
          "paid_at": null,
          "payment_by": null,
          "payment_due": "2025-02-13",
          "payment_pending": "2025-02-10",
          "payment_type": "deposit"
        },
        "roomnights": 1,
        "rooms_data": [
          {
            "bedding_name": [
              "nobedding"
            ],
            "guest_data": {
              "adults_number": 1,
              "children_number": 0,
              "guests": [
                {
                  "age": null,
                  "first_name": "Marty",
                  "first_name_original": "Marty",
                  "is_child": false,
                  "last_name": "Quatro",
                  "last_name_original": "Quatro"
                }
              ]
            },
            "meal_name": "nomeal",
            "has_breakfast": false,
            "no_child_meal": true,
            "room_idx": 0,
            "room_name": "Suite"
          }
        ],
        "source": "b2b-api",
        "status": "completed",
        "supplier_data": {
          "confirmation_id": "612573702",
          "name": "Extranet",
          "order_id": "612573702"
        },
        "taxes": [
          {
            "amount_tax": {
              "amount": "15.14",
              "currency_code": "USD"
            },
            "is_included": true,
            "name": "vat"
          }
        ],
        "total_vat": {
          "amount": "0",
          "currency_code": "EUR",
          "included": false
        },
        "upsells": [],
        "user_data": {
          "arrival_datetime": null,
          "email": "[email protected]",
          "user_comment": "comment"
        }
      }
    ],
    "total_orders": 1239,
    "total_pages": 1239
  },
  "debug": null,
  "error": null,
  "status": "ok"
}

Errors

The error field has the value specified in the headers below.

page_out_of_range

The page_number field value is greater than the total_pages field value.