-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Search restructure with SearchQuery concept (#8)
- Loading branch information
Showing
24 changed files
with
554 additions
and
241 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
syntax = "proto3"; | ||
|
||
package cmp.services.accommodation.v1alpha1; | ||
|
||
import "cmp/services/accommodation/v1alpha1/property_types.proto"; | ||
import "cmp/types/v1alpha1/common.proto"; | ||
import "cmp/types/v1alpha1/language.proto"; | ||
import "google/protobuf/timestamp.proto"; | ||
|
||
message AccommodationProductInfoRequest { | ||
// Message header | ||
cmp.types.v1alpha1.Header header = 1; | ||
|
||
// Only respond with the products that are modified after this timestamp | ||
google.protobuf.Timestamp modified_after = 2; | ||
|
||
// Languages | ||
repeated cmp.types.v1alpha1.Language languages = 3; | ||
|
||
// Property codes | ||
repeated string property_codes = 4; | ||
} | ||
|
||
message AccommodationProductInfoResponse { | ||
// Message header | ||
cmp.types.v1alpha1.Header header = 1; | ||
|
||
// Product list: Properties | ||
repeated PropertyExtendedInfo properties = 2; | ||
} | ||
|
||
// Accommodation product info service definition | ||
// | ||
// ![Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/services/accommodation/v1alpha1/info.proto.dot.xs.svg) | ||
// [Open Message Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/services/accommodation/v1alpha1/info.proto.dot.svg) | ||
service AccommodationProductInfoService { | ||
// Returns product list for accommodation (properties) | ||
rpc AccommodationProductInfo(AccommodationProductInfoRequest) returns (AccommodationProductInfoResponse); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
proto/cmp/services/accommodation/v1alpha1/search_query_types.proto
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
syntax = "proto3"; | ||
|
||
package cmp.services.accommodation.v1alpha1; | ||
|
||
import "cmp/services/accommodation/v1alpha1/search_parameters_types.proto"; | ||
import "cmp/services/accommodation/v1alpha1/unit_types.proto"; | ||
import "cmp/types/v1alpha1/travel_period.proto"; | ||
import "cmp/types/v1alpha1/traveller.proto"; | ||
|
||
message AccommodationSearchQuery { | ||
// Integer query ID, unique per search request | ||
int32 query_id = 1; | ||
|
||
// Accommodation specific search parameters Ex: Specific search parameters like | ||
// geo location, meal plan, rate plan and rate rules. | ||
AccommodationSearchParameters search_parameters_accommodation = 2; | ||
|
||
// Travel period | ||
cmp.types.v1alpha1.TravelPeriod travel_period = 3; | ||
|
||
// Travellers | ||
repeated cmp.types.v1alpha1.Traveller travellers = 4; | ||
|
||
// Total number of rooms / holiday homes | ||
int32 unit_count = 5; | ||
|
||
// Type of the unit, like room or holiday home | ||
UnitType unit_type = 6; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.