Orders

List a buyer's orders

Get a list of trip orders for a buyer

get/trips/{trip_uuid}/bookings/{buyer_id}

Request

  • Base URL
    https://api.wetravel.com/v2/bookings
  • URL
    https://api.wetravel.com/v2/bookings/trips/{trip_uuid}/bookings/{buyer_id}
  • Auth
    HTTP bearer

Path parameters

trip_uuidstring required

Trip Uuid

buyer_idstring required

Id of the buyer

Query parameters

departure_datestring date

Departure date

Response

Get a list of trip orders for a buyer

buyer_idinteger

Unique ID of the buyer

Example response

{
  "buyer_id": 1,
  "buyer": {
    "id": 1,
    "email": "maksym+local@wetravel.com",
    "full_name": "Maks Local"
  },
  "orders": [
    {
      "paid_amount": 200000,
      "refunded_amount": 100000,
      "total_amount": 100000,
      "buyer_id": 1,
      "trip_length": 8,
      "departure_date": "2021-08-14T00:00:00.000Z",
      "currency": "EUR",
      "overpaid_amount": 100000,
      "already_paid": 200000,
      "has_payment_plan": true,
      "allow_partial_payment": true,
      "active_participants_count": 1,
      "created_at": "2021-07-30T09:55:46.000Z",
      "esign_document": {
        "document_id": 3126680263958200300,
        "signed_at": "2021-07-30T09:55:46.000Z"
      },
      "options": [
        {
          "trip_option_id": "2354579505229986943",
          "price": 100000,
          "name": "Gold package",
          "type": "package",
          "active_count": 1,
          "deposit_amount": 5000,
          "has_deposit": true,
          "participants": [
            {
              "email": "maksym+local@wetravel.com",
              "first_name": "Maks",
              "last_name": "Local",
              "survey": [
                {
                  "question_id": "1157591197",
                  "question": "T-Shirt size",
                  "type": "checkbox",
                  "answers": [
                    "L"
                  ],
                  "files": [
                    {
                      "handle": "4d9uMXxpRpqcDVA8mUMk",
                      "filename": "Id.png",
                      "url": "https://cdn.filestackcontent.com/1d9uMtxpapqcDVA8mlMk"
                    }
                  ]
                }
              ]
            }
          ]
        }
      ],
      "donations": [
        {
          "price": 100000,
          "name": "Carbon Offset",
          "type": "Carbon Offset",
          "active_count": 1,
          "amount": 5000
        }
      ],
      "installments": [
        {
          "type": "installment",
          "total": 5000,
          "previous_payment": 5000,
          "paid": true,
          "date": "2021-06-25T00:00:00.000Z"
        }
      ]
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.