Class Offer1

java.lang.Object
com.duffel.sdk.model.Offer1

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", date="2022-08-28T15:18:14.926970+07:00[Asia/Bangkok]") public class Offer1 extends Object
Offer1
  • Field Details

  • Constructor Details

    • Offer1

      public Offer1()
  • Method Details

    • allowedPassengerIdentityDocumentTypes

      public Offer1 allowedPassengerIdentityDocumentTypes(List<Offer1.AllowedPassengerIdentityDocumentTypesEnum> allowedPassengerIdentityDocumentTypes)
    • addAllowedPassengerIdentityDocumentTypesItem

      public Offer1 addAllowedPassengerIdentityDocumentTypesItem(Offer1.AllowedPassengerIdentityDocumentTypesEnum allowedPassengerIdentityDocumentTypesItem)
    • getAllowedPassengerIdentityDocumentTypes

      @Nullable public List<Offer1.AllowedPassengerIdentityDocumentTypesEnum> getAllowedPassengerIdentityDocumentTypes()
      The types of identity documents that may be provided for the passengers when creating an order based on this offer. Currently, the only supported type is `passport`. If this is `[]`, then you must not provide identity documents.
      Returns:
      allowedPassengerIdentityDocumentTypes
    • setAllowedPassengerIdentityDocumentTypes

      public void setAllowedPassengerIdentityDocumentTypes(List<Offer1.AllowedPassengerIdentityDocumentTypesEnum> allowedPassengerIdentityDocumentTypes)
    • availableServices

      public Offer1 availableServices(List<OfferService> availableServices)
    • addAvailableServicesItem

      public Offer1 addAvailableServicesItem(OfferService availableServicesItem)
    • getAvailableServices

      @Nullable @Valid public @Valid List<OfferService> getAvailableServices()
      The services that can be booked along with the offer but are not included by default, for example an additional checked bag. This field is only returned in the [Get single offer](/docs/api/offers/get-offer-by-id) endpoint. When there are no services available, or we don't support services for the airline, this list will be empty. If you want to know which airlines we support services for, please get in touch with the Duffel support team at <help@duffel.com>.
      Returns:
      availableServices
    • setAvailableServices

      public void setAvailableServices(List<OfferService> availableServices)
    • baseAmount

      public Offer1 baseAmount(String baseAmount)
    • getBaseAmount

      @Nullable public String getBaseAmount()
      The base price of the offer for all passengers, excluding taxes. It does not include the base amount of any service(s) that might be booked with the offer.
      Returns:
      baseAmount
    • setBaseAmount

      public void setBaseAmount(String baseAmount)
    • baseCurrency

      public Offer1 baseCurrency(String baseCurrency)
    • getBaseCurrency

      @Nullable public String getBaseCurrency()
      The currency of the `base_amount`, as an [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code. It will match your organisation's billing currency unless you’re using Duffel as an accredited IATA agent, in which case it will be in the currency provided by the airline (which will usually be based on the country where your IATA agency is registered).
      Returns:
      baseCurrency
    • setBaseCurrency

      public void setBaseCurrency(String baseCurrency)
    • conditions

      public Offer1 conditions(OfferConditions1 conditions)
    • getConditions

      @Nullable @Valid public @Valid OfferConditions1 getConditions()
      Get conditions
      Returns:
      conditions
    • setConditions

      public void setConditions(OfferConditions1 conditions)
    • createdAt

      public Offer1 createdAt(OffsetDateTime createdAt)
    • getCreatedAt

      @Nullable @Valid public @Valid OffsetDateTime getCreatedAt()
      The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) datetime at which the offer was created
      Returns:
      createdAt
    • setCreatedAt

      public void setCreatedAt(OffsetDateTime createdAt)
    • expiresAt

      public Offer1 expiresAt(OffsetDateTime expiresAt)
    • getExpiresAt

      @Nullable @Valid public @Valid OffsetDateTime getExpiresAt()
      The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) datetime expiry of the offer before which the traveller should use this offer to create an order. After this time the offer can no longer be used to create an order.
      Returns:
      expiresAt
    • setExpiresAt

      public void setExpiresAt(OffsetDateTime expiresAt)
    • id

      public Offer1 id(String id)
    • getId

      @Nullable public String getId()
      Duffel's unique identifier for the offer
      Returns:
      id
    • setId

      public void setId(String id)
    • liveMode

      public Offer1 liveMode(Boolean liveMode)
    • getLiveMode

      @Nullable public Boolean getLiveMode()
      Whether the offer request was created in live mode. This field will be set to `true` if the offer request was created in live mode, or `false` if it was created in test mode.
      Returns:
      liveMode
    • setLiveMode

      public void setLiveMode(Boolean liveMode)
    • owner

      public Offer1 owner(OfferIndexOwner owner)
    • getOwner

      @Nullable @Valid public @Valid OfferIndexOwner getOwner()
      Get owner
      Returns:
      owner
    • setOwner

      public void setOwner(OfferIndexOwner owner)
    • partial

      public Offer1 partial(Boolean partial)
    • getPartial

      @Nullable public Boolean getPartial()
      Partial offers are a new concept we're introducing as a part of a new multi-step search flow that we're currently experimenting with. A partial offer can't be booked directly, but it can be combined with other partial offers to form a full offer. Partial offers are only ever returned through the multi-step search flow. So there's no need to add any handling to deal with partial offers if you're using the traditional `OfferRequest` search flow to create offers.
      Returns:
      partial
    • setPartial

      public void setPartial(Boolean partial)
    • passengerIdentityDocumentsRequired

      public Offer1 passengerIdentityDocumentsRequired(Boolean passengerIdentityDocumentsRequired)
    • getPassengerIdentityDocumentsRequired

      @Nullable public Boolean getPassengerIdentityDocumentsRequired()
      Whether identity documents must be provided for each of the passengers when creating an order based on this offer. If this is `true`, you must provide an identity document for every passenger.
      Returns:
      passengerIdentityDocumentsRequired
    • setPassengerIdentityDocumentsRequired

      public void setPassengerIdentityDocumentsRequired(Boolean passengerIdentityDocumentsRequired)
    • passengers

      public Offer1 passengers(List<OfferPassenger> passengers)
    • addPassengersItem

      public Offer1 addPassengersItem(OfferPassenger passengersItem)
    • getPassengers

      @Nullable @Valid public @Valid List<OfferPassenger> getPassengers()
      The passengers included in the offer
      Returns:
      passengers
    • setPassengers

      public void setPassengers(List<OfferPassenger> passengers)
    • paymentRequirements

      public Offer1 paymentRequirements(OfferIndexPaymentRequirements paymentRequirements)
    • getPaymentRequirements

      @Nullable @Valid public @Valid OfferIndexPaymentRequirements getPaymentRequirements()
      Get paymentRequirements
      Returns:
      paymentRequirements
    • setPaymentRequirements

      public void setPaymentRequirements(OfferIndexPaymentRequirements paymentRequirements)
    • slices

      public Offer1 slices(List<OfferSlice> slices)
    • addSlicesItem

      public Offer1 addSlicesItem(OfferSlice slicesItem)
    • getSlices

      @Nullable @Valid public @Valid List<OfferSlice> getSlices()
      The [slices](/docs/api/overview/key-principles) that make up this offer. Each slice will include one or more [segments](/docs/api/overview/key-principles), the specific flights that the airline is offering to take the passengers from the slice's `origin` to its `destination`. [Partial](#offers-schema-partial) offers contain a single slice as each partial offer is for a particular slice of the journey.
      Returns:
      slices
    • setSlices

      public void setSlices(List<OfferSlice> slices)
    • taxAmount

      public Offer1 taxAmount(String taxAmount)
    • getTaxAmount

      @Nullable public String getTaxAmount()
      The amount of tax payable on the offer for all passengers
      Returns:
      taxAmount
    • getTaxAmount_JsonNullable

      public org.openapitools.jackson.nullable.JsonNullable<String> getTaxAmount_JsonNullable()
    • setTaxAmount_JsonNullable

      public void setTaxAmount_JsonNullable(org.openapitools.jackson.nullable.JsonNullable<String> taxAmount)
    • setTaxAmount

      public void setTaxAmount(String taxAmount)
    • taxCurrency

      public Offer1 taxCurrency(String taxCurrency)
    • getTaxCurrency

      @Nullable public String getTaxCurrency()
      The currency of the `tax_amount`, as an [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code. It will match your organisation's billing currency unless you’re using Duffel as an accredited IATA agent, in which case it will be in the currency provided by the airline (which will usually be based on the country where your IATA agency is registered).
      Returns:
      taxCurrency
    • getTaxCurrency_JsonNullable

      public org.openapitools.jackson.nullable.JsonNullable<String> getTaxCurrency_JsonNullable()
    • setTaxCurrency_JsonNullable

      public void setTaxCurrency_JsonNullable(org.openapitools.jackson.nullable.JsonNullable<String> taxCurrency)
    • setTaxCurrency

      public void setTaxCurrency(String taxCurrency)
    • totalAmount

      public Offer1 totalAmount(String totalAmount)
    • getTotalAmount

      @Nullable public String getTotalAmount()
      The total price of the offer for all passengers, including taxes. It does not include the total price of any service(s) that might be booked with the offer.
      Returns:
      totalAmount
    • setTotalAmount

      public void setTotalAmount(String totalAmount)
    • totalCurrency

      public Offer1 totalCurrency(String totalCurrency)
    • getTotalCurrency

      @Nullable public String getTotalCurrency()
      The currency of the `total_amount`, as an [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code. It will match your organisation's billing currency unless you’re using Duffel as an accredited IATA agent, in which case it will be in the currency provided by the airline (which will usually be based on the country where your IATA agency is registered).
      Returns:
      totalCurrency
    • setTotalCurrency

      public void setTotalCurrency(String totalCurrency)
    • totalEmissionsKg

      public Offer1 totalEmissionsKg(String totalEmissionsKg)
    • getTotalEmissionsKg

      @Nullable public String getTotalEmissionsKg()
      An estimate of the total carbon dioxide (CO₂) emissions when all of the passengers fly this offer's itinerary, measured in kilograms
      Returns:
      totalEmissionsKg
    • setTotalEmissionsKg

      public void setTotalEmissionsKg(String totalEmissionsKg)
    • updatedAt

      public Offer1 updatedAt(OffsetDateTime updatedAt)
    • getUpdatedAt

      @Nullable @Valid public @Valid OffsetDateTime getUpdatedAt()
      The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) datetime at which the offer was last updated
      Returns:
      updatedAt
    • setUpdatedAt

      public void setUpdatedAt(OffsetDateTime updatedAt)
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object