Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version 4 update #15

Merged
merged 33 commits into from
Apr 12, 2024
Merged
Show file tree
Hide file tree
Changes from 31 commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
ac6ca61
ProductStatus, Disclaimer Licenses, Unspecified, lists ordering comme…
SamJaarsma Mar 26, 2024
bd82047
splitting of basic and extensive traveller info
SamJaarsma Mar 26, 2024
340d5cb
added on-request using the types/bookability message
SamJaarsma Mar 26, 2024
0b750ac
moving traveler details from each result to the search result with a …
SamJaarsma Mar 26, 2024
58d000c
forgot import
SamJaarsma Mar 26, 2024
e62492b
simplify enum for product status
SamJaarsma Mar 26, 2024
9759971
added timestamp to the activity list and info
SamJaarsma Mar 27, 2024
1f09b8d
field order correction
SamJaarsma Mar 27, 2024
beb15f7
improve explanation of cancellation boolean and moved servicefact to …
SamJaarsma Mar 27, 2024
3af70fe
implementation of change policy in transport
SamJaarsma Mar 27, 2024
b33da1e
amended explanation for warnings
SamJaarsma Mar 27, 2024
f558a6d
fix multi room explanation
SamJaarsma Mar 28, 2024
ae12780
first attempt to currency
SamJaarsma Apr 2, 2024
b1891d4
Price and currency revision final. Added locally payable or included …
SamJaarsma Apr 3, 2024
1c09e46
added a comment
SamJaarsma Apr 3, 2024
d96ffac
fix small typos and comments
havan Apr 4, 2024
11991f1
Merge branch 'version-4-update' of https://github.com/chain4travel/ca…
SamJaarsma Apr 4, 2024
0a0ab18
review comments
SamJaarsma Apr 4, 2024
6557fa4
further review comments
SamJaarsma Apr 4, 2024
ad3adeb
Update proto/cmp/services/accommodation/v1alpha/search.proto
SamJaarsma Apr 11, 2024
26297d2
Update proto/cmp/services/transport/v1alpha/search.proto
SamJaarsma Apr 11, 2024
6314e38
Update proto/cmp/services/transport/v1alpha/search_query_types.proto
SamJaarsma Apr 11, 2024
8cc2d52
Update proto/cmp/types/v1alpha/service_fact.proto
SamJaarsma Apr 11, 2024
2a333ce
review comments Alex
SamJaarsma Apr 11, 2024
ff61da1
Merge branch 'version-4-update' of https://github.com/chain4travel/ca…
SamJaarsma Apr 11, 2024
db632c6
further comments from Alex
SamJaarsma Apr 11, 2024
cb079bd
specification of on-chain payment improvement and typos
SamJaarsma Apr 11, 2024
e1ab928
buf format
havan Apr 11, 2024
df683c3
rename supported_currencies to on_chain_currencies
SamJaarsma Apr 12, 2024
5add7d6
made made names of all repeated fields plural
SamJaarsma Apr 12, 2024
64b401d
Added enum RatepPlanType
SamJaarsma Apr 12, 2024
6903b65
improved RatePlan documentation
SamJaarsma Apr 12, 2024
92995fe
fix typo
havan Apr 12, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion proto/cmp/services/accommodation/v1alpha/info.proto
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ package cmp.services.accommodation.v1alpha;
import "cmp/services/accommodation/v1alpha/property_types.proto";
import "cmp/types/v1alpha/common.proto";
import "cmp/types/v1alpha/language.proto";
import "google/protobuf/timestamp.proto";
import "cmp/types/v1alpha/product_code.proto";
import "google/protobuf/timestamp.proto";

message AccommodationProductInfoRequest {
// Message header
Expand Down
37 changes: 16 additions & 21 deletions proto/cmp/services/accommodation/v1alpha/property_types.proto
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,11 @@ import "cmp/types/v1alpha/file.proto";
import "cmp/types/v1alpha/location.proto";
import "cmp/types/v1alpha/meal_plan.proto";
import "cmp/types/v1alpha/phone.proto";
import "cmp/types/v1alpha/product_code.proto";
import "cmp/types/v1alpha/product_status.proto";
import "cmp/types/v1alpha/service_fact.proto";
import "cmp/types/v1alpha/traveller.proto";
import "google/protobuf/timestamp.proto";
import "cmp/types/v1alpha/product_code.proto";

// ### Property message type
//
Expand All @@ -23,14 +24,15 @@ import "cmp/types/v1alpha/product_code.proto";
// ![Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/services/accommodation/v1alpha/property_types.proto.dot.xs.svg)
// [Open Message Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/services/accommodation/v1alpha/property_types.proto.dot.svg)
message Property {
// Ex: "2023-08-28T12:03:50",
// Ex: "2023-08-28T12:03:50", specifying when the static data of a product was
// last updated
google.protobuf.Timestamp last_modified = 1;

// Ex: "AESPMI1234"
// Supplier product Code
cmp.types.v1alpha.SupplierProductCode supplier_code = 2;

// Product code which can be of different types
repeated cmp.types.v1alpha.ProductCode product_code = 3;
repeated cmp.types.v1alpha.ProductCode product_codes = 3;

// Ex: "Beach Hotel Alanya"
string name = 4;
Expand Down Expand Up @@ -60,7 +62,7 @@ message Property {
string website = 12;

// Status of the property
PropertyStatus status = 13;
cmp.types.v1alpha.ProductStatus status = 13;

// Airports
// Ex: ["PMI", "ZRH", "AYT"]
Expand Down Expand Up @@ -97,13 +99,6 @@ enum CategoryUnit {
CATEGORY_UNIT_PALMS = 2;
}

enum PropertyStatus {
PROPERTY_STATUS_UNSPECIFIED = 0;
PROPERTY_STATUS_DRAFT = 1;
PROPERTY_STATUS_CONFIRMED = 2;
PROPERTY_STATUS_EXPIRED = 3;
}

// This message type contains extended info about a property
message PropertyExtendedInfo {
// Property
Expand All @@ -116,7 +111,7 @@ message PropertyExtendedInfo {
repeated cmp.types.v1alpha.Video videos = 3;

// Segmentation classification
repeated string classification = 4;
repeated string classifications = 4;

// Property descriptions
repeated cmp.types.v1alpha.LocalizedDescriptionSet localized_descriptions = 5;
Expand All @@ -137,19 +132,19 @@ message Room {
// in the ProductList and the ProductInfo messages, so that the static data like room
// amenities, descriptions, images etc. can be married to the dynamic price and
// availability data for display to the end user.
string supplier_room_code = 1;
string supplier_code = 1;

// Room name. In case of hotel a standardized room name is often derrived from
// room code structures. Exmple: "superior seaview room".
// For holiday homes we expect names like "Master Bedroom", "Second Bedroom" or
// "Bathroom" when specific descriptions for each room are available.
string supplier_room_name = 2;
// Room name. In case of hotel a standardized room name is often derrived from
// room code structures. Exmple: "superior seaview room".
// For holiday homes we expect names like "Master Bedroom", "Second Bedroom" or
// "Bathroom" when specific descriptions for each room are available.
string supplier_name = 2;

// Original room name as assigned by the hotel. In case of spefifically designated room
// names by chains and both the chain and the customer wants to adhere to them.
// Ex: "CEIBA CLUB", "CEIBA GOVERNORS SUITE", "GOVERNORS SUITE" or "ENCLAVE NATURE VIEW"
// For holiday homes specific room names if availbale can be given.
string original_room_name =3;
string original_name = 3;

repeated cmp.types.v1alpha.Image images = 4;
SamJaarsma marked this conversation as resolved.
Show resolved Hide resolved
repeated cmp.types.v1alpha.Video videos = 5;
Expand All @@ -158,7 +153,7 @@ message Room {
repeated cmp.types.v1alpha.LocalizedDescriptionSet descriptions = 6;

// Meal plan (Board code)
repeated cmp.types.v1alpha.MealPlan meal_plan = 7;
repeated cmp.types.v1alpha.MealPlan meal_plans = 7;

// Beds
repeated cmp.types.v1alpha.Bed beds = 8;
Expand Down
12 changes: 7 additions & 5 deletions proto/cmp/services/accommodation/v1alpha/search.proto
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,15 @@ import "cmp/services/accommodation/v1alpha/search_query_types.proto";
import "cmp/services/accommodation/v1alpha/search_result_types.proto";
import "cmp/types/v1alpha/common.proto";
import "cmp/types/v1alpha/search.proto";
import "cmp/types/v1alpha/traveller.proto";

// The `Accommodation Search Request` message type facilitates the request for
// accommodations like hotel and holiday home searches within the platform. In the
// request the market, language and currency are specified at the top-level.
//
// In "queries" we specify the details of the trip like dates, properties or
// locations or filters. The purpose of such a structure is to allow for multi-room
// and multi-property search requests.
// and multi-property search requests.
//
// For the response this means that there is no grouping of different
// room, mealplan or rateplan options in single room or single property searches.
Expand All @@ -33,7 +34,7 @@ import "cmp/types/v1alpha/search.proto";
// a search for 1 room for 2 adults would be just 1 query, with one travel period and
// one set of search parameters. The response has one query_id with many result_ids
// for various rooms, mealplans and rateplans in one hotel and depending on the search
// parameters, again for other hotels. Each property+room+rateplan+mealplan is one
// parameters, again for other hotels. Each property+room+rateplan+mealplan is one
// result_id with just one unit.
//
// The simple example is also applicable for holiday homes where one or multiple
Expand Down Expand Up @@ -62,15 +63,13 @@ import "cmp/types/v1alpha/search.proto";
// In this case the number of rooms is specified and the total amount of travellers,
// but no distribution of travellers per room is detailed in the request. The reponse
// then hold multiple units for one search_id and result_id, so that if 5 rooms are
// requested, but only 2 standard rooms are available, the requested amount can be
// requested, but only 2 standard rooms are available, the requested amount can be
// completed with a different room type (superior, seaview,..)
//
// In general, the number of available rooms should be considered to ensure that for
// requests with multiple rooms or homes, the same room or home is not offered twice
// to different travellers.
//
//

message AccommodationSearchRequest {
// Message header. Contains API version, message info string and end-user wallet
// address
Expand Down Expand Up @@ -108,6 +107,9 @@ message AccommodationSearchResponse {

// Unique combinations of bookable search results, like property,
repeated AccommodationSearchResult results = 3;

// Global definition of the travellers for all results to be used via the traveller_id each unit.
repeated cmp.types.v1alpha.BasicTraveller travellers = 4;
}

// Service definition for Accommodation search
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ message AccommodationSearchParameters {
// This "one of" field enforces only one of the fields below. They all share
// memory, setting one will remove the others.
oneof geo_location {
// FIXME: Do we need a list of location code here? Other fields are not lists.
// A list of location codes or just one code.
cmp.types.v1alpha.LocationCodes location_codes = 1;

// Single geographic point represented by two double fields.
Expand All @@ -38,7 +38,7 @@ message AccommodationSearchParameters {
repeated cmp.types.v1alpha.MealPlan meal_plan_codes = 6;

// Rate plans
repeated cmp.types.v1alpha.RatePlan rate_plan = 7;
repeated cmp.types.v1alpha.RatePlan rate_plans = 7;

// Rate Rules
// To be used when searching for specific rates like refundable or resellable offers
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ message AccommodationSearchQuery {
cmp.types.v1alpha.TravelPeriod travel_period = 3;

// Travellers
repeated cmp.types.v1alpha.Traveller travellers = 4;
repeated cmp.types.v1alpha.BasicTraveller travellers = 4;

// Total number of rooms / holiday homes
int32 unit_count = 5;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ syntax = "proto3";
package cmp.services.accommodation.v1alpha;

import "cmp/services/accommodation/v1alpha/unit_types.proto";
import "cmp/types/v1alpha/bookable.proto";
import "cmp/types/v1alpha/cancel_policy.proto";
import "cmp/types/v1alpha/price.proto";
import "cmp/types/v1alpha/rate.proto";
Expand Down Expand Up @@ -34,4 +35,7 @@ message AccommodationSearchResult {

// Freetext remarks without any functionality
string remarks = 7;

// Status of the result, whether it is immediately bookable or not
cmp.types.v1alpha.Bookability bookable = 8;
}
8 changes: 4 additions & 4 deletions proto/cmp/services/accommodation/v1alpha/unit_types.proto
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import "cmp/types/v1alpha/product_code.proto";
import "cmp/types/v1alpha/rate.proto";
import "cmp/types/v1alpha/service_fact.proto";
import "cmp/types/v1alpha/travel_period.proto";
import "cmp/types/v1alpha/traveller.proto";

// A Unit can represent a room in a hotel. One search option can have multiple units
// for multi-room requests Ex: one request for 2 rooms for 4 adults, 2 in each room.
Expand Down Expand Up @@ -45,8 +44,9 @@ message Unit {
// Travel period
cmp.types.v1alpha.TravelPeriod travel_period = 5;

// Travellers
repeated cmp.types.v1alpha.Traveller travellers = 6;
// Traveller_id is a list of travellers related to this unit. The details can be found in
// the search response repeated travellers field
repeated int32 traveller_ids = 6;

// Beds
repeated cmp.types.v1alpha.Bed beds = 7;
Expand Down Expand Up @@ -77,7 +77,7 @@ message Unit {

// Property code which can be of different types
cmp.types.v1alpha.ProductCode property_code = 15;

// Supplier Property code, consistent in ProductList, ProductInfo and Search
cmp.types.v1alpha.SupplierProductCode supplier_code = 16;

Expand Down
7 changes: 6 additions & 1 deletion proto/cmp/services/activity/v1alpha/search.proto
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ message ActivitySearchRequest {
cmp.types.v1alpha.TravelPeriod travel_period = 5;

// Travellers
repeated cmp.types.v1alpha.Traveller travellers = 6;
repeated cmp.types.v1alpha.BasicTraveller travellers = 6;

// ### Source Location
//
Expand Down Expand Up @@ -110,6 +110,11 @@ message ActivitySearchResponse {

// Unique combinations of bookable search results
repeated ActivitySearchResult results = 3;

// The traveller_id is specified in each result and the ids are detailed with
// basic traveller data only once in the top-level search response to avoid
// repetition.
repeated cmp.types.v1alpha.BasicTraveller travellers = 4;
}

// ### Activity Search Service
Expand Down
48 changes: 16 additions & 32 deletions proto/cmp/services/activity/v1alpha/search_parameters_types.proto
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ syntax = "proto3";

package cmp.services.activity.v1alpha;

import "cmp/types/v1alpha/language.proto";
import "cmp/types/v1alpha/duration.proto";
import "cmp/types/v1alpha/language.proto";
import "cmp/types/v1alpha/price.proto";
import "cmp/types/v1alpha/product_code.proto";

Expand All @@ -17,57 +17,41 @@ message ActivitySearchParameters {
// Specify the language(s) a potential guide should speak for example a tour in
// the Anne Frank house in Amsterdam in French or the tour at the pyramids in
// Egypt should be in Russian
repeated cmp.types.v1alpha.Language spoken_language = 1;

// Specify one or more product codes to be included in the search response
// These can be of different types
// Ex: "TC000000"
repeated cmp.types.v1alpha.ProductCode product_codes = 2;
repeated cmp.types.v1alpha.Language spoken_languages = 1;

// Specify one or more supplier codes to be included in the search response
// These must match the supplier codes provided in the ProductList and
// ProductInfo messages
repeated cmp.types.v1alpha.SupplierProductCode supplier_codes = 3;
repeated cmp.types.v1alpha.SupplierProductCode supplier_codes = 2;

// Specify one or more product codes to be included in the search response
// These can be of different types
repeated cmp.types.v1alpha.ProductCode product_codes = 3;

// Specify one or more activity IDs to be included in the search response
// Specify one or more unit IDs to be included in the search response
// The purpose of this concept is to allow for different activities for one product
// like "Windsurfing" and "Kitesurfing" under "Salou Playa Llarga".
// Code and description match the information provided in the ProductList and
// Code and description match the information provided in the ProductList and
// ProductInfo message. These are in general also supplier specific.
// Ex: "EESPMI46VY"
repeated string activity_id = 4;
repeated string unit_codes = 4;

// Specify one or more service codes to be included in the search response
// Several different packages could be included like "Windsurfing" with or without
// "Wetsuit". Code and description match the information provided in the ProductInfo message
// These are in general also supplier specific
// Ex: "XO"
repeated string service_code = 5;

// Specify one or more category codes to be included in the search response
// This concept is covering classification and segmentation aspects like for example
// Museum tours, Outdoor activities, Theme parks etc...
// Code and description match the information provided in the ProductInfo message
// These are in general also supplier specific
repeated string category_code = 6;

// Specify one or more type codes to be included in the search response
// A code to identify a specific type of excursion like Leisure, Activity, Learning, etc
// Code and description match the information provided in the ProductInfo message
// These are in general also supplier specific
repeated string type_code = 7;
repeated string service_codes = 5;

// Duration
//
// Specify the minimal and maximum duration of an activity to be included in the
// search response
cmp.types.v1alpha.Duration min_duration = 8;
cmp.types.v1alpha.Duration max_duration = 9;
cmp.types.v1alpha.Duration min_duration = 6;
cmp.types.v1alpha.Duration max_duration = 7;

// Pricerange
//
// Specify the minimum and maximum price of an activity to be included in the
// search response
cmp.types.v1alpha.Price min_price = 10;
cmp.types.v1alpha.Price max_price = 11;
}
cmp.types.v1alpha.Price min_price = 8;
cmp.types.v1alpha.Price max_price = 9;
}
Loading