Skip to content

Commit

Permalink
Merge pull request #869 from duffelhq/jo-prepare-rates-source
Browse files Browse the repository at this point in the history
Add StaysRate.source
  • Loading branch information
jekku authored Jan 9, 2024
2 parents 6a6374f + 8dc89be commit 554e19c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/Stays/StaysTypes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,12 @@ export interface StaysRate {
* The duffel_hotel_group_rewards value is an example programme for testing and integration purposes, and will only appear on Duffel Hotel Group test hotel rates.
*/
supported_loyalty_programme: StaysLoyaltyProgramme | null

/**
* The source of the rate.
* Useful in scenarios where a rate requires explicitly showing the source.
*/
source: 'bookingcom' | 'priceline' | 'travelport' | 'duffel_hotel_group'
}

export interface StaysRoomRate extends StaysRate {
Expand Down
2 changes: 2 additions & 0 deletions src/Stays/mocks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ export const MOCK_ACCOMMODATION: StaysAccommodation = {
payment_method: 'balance',
quantity_available: 1,
supported_loyalty_programme: null,
source: 'duffel_hotel_group',
},
{
total_currency: 'GBP',
Expand Down Expand Up @@ -82,6 +83,7 @@ export const MOCK_ACCOMMODATION: StaysAccommodation = {
payment_method: 'card',
quantity_available: 1,
supported_loyalty_programme: 'duffel_hotel_group_rewards',
source: 'duffel_hotel_group',
},
],
photos: [
Expand Down

0 comments on commit 554e19c

Please sign in to comment.