diff --git a/proto/cmp/services/accommodation/v1alpha/search_parameters_types.proto b/proto/cmp/services/accommodation/v1alpha/search_parameters_types.proto index c929bd7..57290e3 100644 --- a/proto/cmp/services/accommodation/v1alpha/search_parameters_types.proto +++ b/proto/cmp/services/accommodation/v1alpha/search_parameters_types.proto @@ -24,7 +24,7 @@ message AccommodationSearchParameters { // Single geographic point represented by two double fields. cmp.types.v1alpha.Coordinate location_coordinate = 2; - // Geo tree type, representted by Country, Region, and City_or_Resort. + // Geo tree type, represented by Country, Region, and City_or_Resort. cmp.types.v1alpha.GeoTree location_geo_tree = 3; // Geo circle. Represented by a coordinate and a distance for radius diff --git a/proto/cmp/services/activity/v1alpha/activity_types.proto b/proto/cmp/services/activity/v1alpha/activity_types.proto index aa25bcd..6f6b4ea 100644 --- a/proto/cmp/services/activity/v1alpha/activity_types.proto +++ b/proto/cmp/services/activity/v1alpha/activity_types.proto @@ -1,9 +1,5 @@ syntax = "proto3"; -// ### Activity Services -// -// The Activity services are used for both tickets and excursions - package cmp.services.activity.v1alpha; import "cmp/types/v1alpha/description.proto"; @@ -16,123 +12,179 @@ import "cmp/types/v1alpha/contact_info.proto"; import "cmp/types/v1alpha/product_code.proto"; import "cmp/types/v1alpha/delivery.proto"; import "cmp/types/v1alpha/redemption.proto"; -import "cmp/services/activity/v1alpha/search_result_types.proto"; +import "cmp/types/v1alpha/bookable.proto"; +import "cmp/types/v1alpha/address.proto"; +import "google/protobuf/timestamp.proto"; -message ActivityExtendedInfo { - // Activity Product Details - ActivityDetails activity_product_detail_response = 1; - // Units - repeated ActivityUnit units = 2; +// This represents Activity types which is needed for different activity services (search, info, ... etc) +// +// ![Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/services/activity/v1alpha/activity_types.proto.dot.xs.svg) +// [Open Message Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/services/activity/v1alpha/activity_types.proto.dot.svg) +message Activity { + // Context for Inventory system concepts that need to be included in an info response, + // like an OwnerCode, PTC_OfferParameters, Tax codes, Disclosure RefID, etc. or a + // serialized combination of these codes. + string context = 1; - // Service Info - ActivityService service = 3; + // Ex: "2023-08-28T12:03:50", specifying when the static data of a product was last updated + google.protobuf.Timestamp last_modified = 2; - // Zones - repeated ActivityZone zones = 4; + // An identifier for external sessions, aiding in tracking and continuity across + // sessions. + string external_session_id = 3; + + // External Product codes for the result. These can be of different types + cmp.types.v1alpha.ProductCode product_code = 4; + + // Unit IDfor the result + // 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 + // ProductInfo message. These are in general also supplier specific. + string unit_code = 5; + + // Service codes for the result + // 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 + string service_code = 6; + + // Status of the result, whether it is immediately bookable or not + cmp.types.v1alpha.Bookability bookable = 7; +} - // Descriptions with different languages - repeated cmp.types.v1alpha.LocalizedDescriptionSet descriptions = 5; +message ActivityLocation { + // Ex: Ctra. de la Porrassa, s/n, Magaluf, ES 07181 in structured fields + cmp.types.v1alpha.Address address = 1; - // Coordinates - cmp.types.v1alpha.Coordinate position =6; + // Geo Tree. Country, region, city_or_resort + cmp.types.v1alpha.GeoTree geo_tree = 2; - // Activity Features - repeated ActivityFeature features = 7; + // Coordinate + cmp.types.v1alpha.Coordinate coordinate = 3; +} - // Tags - repeated ActivityTag tags = 8; +message PickupDropoffEvent { + // Ex: "AESPMI43NU", + string location_code = 1; + // Ex: "Sunny Beach Hotel", + string location_name = 2; - // Languages - repeated cmp.types.v1alpha.Language languages = 9; + // True if this pickup location is selected for the activity + // + // Ex: "true" + // + // FIXME: How is this relevant for the search result message? + bool pickup_indicator = 3; - // Contact Info; Address, Email, Phone, Urls - cmp.types.v1alpha.ContactInfo contact_info = 10; + // Ex: "OTHERS / Parking Varadero(bus stop css nº50)", + string other_info = 4; - // Images - repeated cmp.types.v1alpha.Image images = 11; + // Datetime of the pickup dropoff event as Unix timestamp + google.protobuf.Timestamp date_time = 5; - // Videos - repeated cmp.types.v1alpha.Video videos = 12; + // Longitude and Latitude of the location + cmp.types.v1alpha.Coordinate coordinates = 6; +} +enum PricingType { + PRICING_TYPE_UNSPECIFIED = 0; + PRICING_TYPE_PERPERSON = 1; + PRICING_TYPE_PERGROUP = 2; } -message ActivityDetails { - // Context for Inventory system concepts that need to be included in an info response, - // like an OwnerCode, PTC_OfferParameters, Tax codes, Disclosure RefID, etc. or a - // serialized combination of these codes. - string context = 1; +message ActivityExtendedInfo { + // Activity dynamic info + Activity activity = 1; - // Errors encountered in the generation of the response. Standardized error list - // to be created. - repeated string errors = 2; + // Units + repeated ActivityUnit units = 2; - // Warnings encountered in the generation of the response. This section might include - // information about fields not processed due to incompatibilities with the - // inventory system - repeated string warnings = 3; + // Service Info + ActivityService service = 3; - // Supplier code from the Inventory System for this activity response. - string supplier_unit_code = 4; + // Zones + repeated ActivityZone zones = 4; - // An identifier for external sessions, aiding in tracking and continuity across - // sessions. - string external_session_id = 5; + // Descriptions with different languages + repeated cmp.types.v1alpha.LocalizedDescriptionSet descriptions = 5; + + // Coordinates + cmp.types.v1alpha.Coordinate position =6; + + // Activity Features + repeated ActivityFeature features = 7; + + // Tags + repeated ActivityTag tags = 8; + + // Languages + repeated cmp.types.v1alpha.Language languages = 9; + + // Contact Info; Address, Email, Phone, Urls + cmp.types.v1alpha.ContactInfo contact_info = 10; + + // Images + repeated cmp.types.v1alpha.Image images = 11; + + // Videos + repeated cmp.types.v1alpha.Video videos = 12; + + // Supplier code from the Inventory System for this activity response. + string supplier_unit_code = 13; // Activity Category Code - string category_code = 6; + string category_code = 14; // Category name which describes the category_code - string category_name = 7; + string category_name = 15; // Type Code - string type_code = 8; + string type_code = 16; // Type name which describes type_code - string type_name = 9; - - // Supplier specific code, matching the supplier code in ProductList and ProductInfo - // messages - cmp.types.v1alpha.SupplierProductCode supplier_code = 10; + string type_name = 17; + + // Supplier Product codes for the result + // These must match the supplier codes provided in the ProductList and + // ProductInfo messages + cmp.types.v1alpha.SupplierProductCode supplier_code = 18; // Supplier Name - string supplier_code_name = 11; - - // product_code - cmp.types.v1alpha.ProductCode product_code = 12; + string supplier_code_name = 19; // Duration range (min, max) of the activity in minutes - cmp.types.v1alpha.DurationRange duration_range = 13; + cmp.types.v1alpha.DurationRange duration_range = 20; // Time given for confirmation before the offer expires - cmp.types.v1alpha.Duration max_confirmation_duration = 14; + cmp.types.v1alpha.Duration max_confirmation_duration = 21; // Allow Free Sale - bool allow_free_sale = 15; + bool allow_free_sale = 22; // The ability to confirm instantly - bool instant_confirmation = 16; + bool instant_confirmation = 23; // Can be delivered instantly - bool instant_delivery = 17; + bool instant_delivery = 24; // Check availability - bool availability_required = 18; + bool availability_required = 25; // Availability Type - string availability_type = 19; + string availability_type = 26; // Delivery Formats; such as QR Code, NFT, Ticket, ... etc - repeated cmp.types.v1alpha.DeliveryFormat delivery_formats = 20; + repeated cmp.types.v1alpha.DeliveryFormat delivery_formats = 27; // Delivery Methods; such as Email, SMS, Post, ... etc - repeated cmp.types.v1alpha.DeliveryMethod delivery_methods = 21; + repeated cmp.types.v1alpha.DeliveryMethod delivery_methods = 28; // Redemption method - repeated cmp.types.v1alpha.RedemptionMethod redemption_method = 22; + repeated cmp.types.v1alpha.RedemptionMethod redemption_methods = 29; } - message ActivityUnit { // Schedule cmp.types.v1alpha.DateTimeRange schedule = 1; @@ -147,7 +199,6 @@ message ActivityUnit { string description = 4; } - message ActivityService { // Service Code string code = 1; @@ -169,7 +220,7 @@ message ActivityZone { // Unit Code string code = 1; - // Geo tree type, representted by Country, Region, and City_or_Resort. + // Geo tree type, represented by Country, Region, and City_or_Resort. cmp.types.v1alpha.GeoTree geo_tree = 2; // pick-up and drop-off information about location and time diff --git a/proto/cmp/services/activity/v1alpha/info.proto b/proto/cmp/services/activity/v1alpha/info.proto index 0cafa21..a3232ca 100644 --- a/proto/cmp/services/activity/v1alpha/info.proto +++ b/proto/cmp/services/activity/v1alpha/info.proto @@ -1,9 +1,5 @@ syntax = "proto3"; -// ### Activity Services -// -// The Activity services are used for both tickets and excursions - package cmp.services.activity.v1alpha; import "cmp/types/v1alpha/common.proto"; diff --git a/proto/cmp/services/activity/v1alpha/list.proto b/proto/cmp/services/activity/v1alpha/list.proto index aa139a6..8d92f47 100644 --- a/proto/cmp/services/activity/v1alpha/list.proto +++ b/proto/cmp/services/activity/v1alpha/list.proto @@ -2,7 +2,7 @@ syntax = "proto3"; package cmp.services.activity.v1alpha; -import "cmp/services/activity/v1alpha/search_result_types.proto"; +import "cmp/services/activity/v1alpha/activity_types.proto"; import "cmp/types/v1alpha/common.proto"; import "google/protobuf/timestamp.proto"; diff --git a/proto/cmp/services/activity/v1alpha/search.proto b/proto/cmp/services/activity/v1alpha/search.proto index c2103d1..ea35952 100644 --- a/proto/cmp/services/activity/v1alpha/search.proto +++ b/proto/cmp/services/activity/v1alpha/search.proto @@ -59,7 +59,7 @@ message ActivitySearchRequest { // Single geographic point represented by two double fields. cmp.types.v1alpha.Coordinate source_location_coordinate = 8; - // Geo tree type, representted by Country, Region, and City_or_Resort. + // Geo tree type, represented by Country, Region, and City_or_Resort. cmp.types.v1alpha.GeoTree source_location_geo_tree = 9; // Geo circle. Represented by a coordinate and a distance for radius @@ -83,7 +83,7 @@ message ActivitySearchRequest { // Single geographic point represented by two double fields. cmp.types.v1alpha.Coordinate service_location_coordinate = 13; - // Geo tree type, representted by Country, Region, and City_or_Resort. + // Geo tree type, represented by Country, Region, and City_or_Resort. cmp.types.v1alpha.GeoTree service_location_geo_tree = 14; // Geo circle. Represented by a coordinate and a distance for radius diff --git a/proto/cmp/services/activity/v1alpha/search_result_types.proto b/proto/cmp/services/activity/v1alpha/search_result_types.proto index e98bea6..58b6798 100644 --- a/proto/cmp/services/activity/v1alpha/search_result_types.proto +++ b/proto/cmp/services/activity/v1alpha/search_result_types.proto @@ -2,13 +2,9 @@ syntax = "proto3"; package cmp.services.activity.v1alpha; -import "cmp/types/v1alpha/address.proto"; -import "cmp/types/v1alpha/bookable.proto"; import "cmp/types/v1alpha/datetime_range.proto"; -import "cmp/types/v1alpha/location.proto"; import "cmp/types/v1alpha/price.proto"; -import "cmp/types/v1alpha/product_code.proto"; -import "google/protobuf/timestamp.proto"; +import "cmp/services/activity/v1alpha/activity_types.proto"; // This type represents a search result and is used in the `ActivitySearchResponse` // message. @@ -44,75 +40,4 @@ message ActivitySearchResult { // Pricing type // Ex: "PerPerson", "PerGroup" PricingType pricing_type = 9; -} - -// Represents an Activity product. -// -// See extensive explanations in search_parameters_types -message Activity { - // Ex: "2023-08-28T12:03:50", specifying when the static data of a product was last updated - google.protobuf.Timestamp last_modified = 1; - // Supplier Product codes for the result - // These must match the supplier codes provided in the ProductList and - // ProductInfo messages - cmp.types.v1alpha.SupplierProductCode supplier_code = 2; - - // External Product codes for the result. These can be of different types - cmp.types.v1alpha.ProductCode product_code = 3; - - // Unit IDfor the result - // 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 - // ProductInfo message. These are in general also supplier specific. - string unit_code = 4; - - // Service codes for the result - // 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 - string service_code = 5; - - // Status of the result, whether it is immediately bookable or not - cmp.types.v1alpha.Bookability bookable = 6; -} - -message ActivityLocation { - // Ex: Ctra. de la Porrassa, s/n, Magaluf, ES 07181 in structured fields - cmp.types.v1alpha.Address address = 1; - - // Geo Tree. Country, region, city_or_resort - cmp.types.v1alpha.GeoTree geo_tree = 2; - - // Coordinate - cmp.types.v1alpha.Coordinate coordinate = 3; -} - -message PickupDropoffEvent { - // Ex: "AESPMI43NU", - string location_code = 1; - // Ex: "Sunny Beach Hotel", - string location_name = 2; - - // True if this pickup location is selected for the activity - // - // Ex: "true" - // - // FIXME: How is this relevant for the search result message? - bool pickup_indicator = 3; - - // Ex: "OTHERS / Parking Varadero(bus stop css nº50)", - string other_info = 4; - - // Datetime of the pickup dropoff event as Unix timestamp - google.protobuf.Timestamp date_time = 5; - - // Longitude and Latitude of the location - cmp.types.v1alpha.Coordinate coordinates = 6; -} - -enum PricingType { - PRICING_TYPE_UNSPECIFIED = 0; - PRICING_TYPE_PERPERSON = 1; - PRICING_TYPE_PERGROUP = 2; -} +} \ No newline at end of file diff --git a/proto/cmp/types/v1alpha/contact_info.proto b/proto/cmp/types/v1alpha/contact_info.proto index bdecb4f..a6d3099 100644 --- a/proto/cmp/types/v1alpha/contact_info.proto +++ b/proto/cmp/types/v1alpha/contact_info.proto @@ -11,10 +11,7 @@ import "cmp/types/v1alpha/link.proto"; // // ![Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/types/v1alpha/contact_info.proto.dot.xs.svg) // [Open Message Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/types/v1alpha/contact_info.proto.dot.svg) - - message ContactInfo { - // Address repeated cmp.types.v1alpha.Address address = 1; @@ -26,5 +23,4 @@ message ContactInfo { // Websites repeated cmp.types.v1alpha.Link links = 4; - } \ No newline at end of file diff --git a/proto/cmp/types/v1alpha/delivery.proto b/proto/cmp/types/v1alpha/delivery.proto index 386a105..86ca05a 100644 --- a/proto/cmp/types/v1alpha/delivery.proto +++ b/proto/cmp/types/v1alpha/delivery.proto @@ -6,7 +6,6 @@ package cmp.types.v1alpha; // // ![Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/types/v1alpha/delivery.proto.dot.xs.svg) // [Open Message Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/types/v1alpha/delivery.proto.dot.svg) - enum DeliveryFormat { DELIVERY_FORMAT_UNSPECIFIED = 0; DELIVERY_FORMAT_OTHER = 1; diff --git a/proto/cmp/types/v1alpha/link.proto b/proto/cmp/types/v1alpha/link.proto index b87c1ec..dc2c2f5 100644 --- a/proto/cmp/types/v1alpha/link.proto +++ b/proto/cmp/types/v1alpha/link.proto @@ -6,22 +6,21 @@ package cmp.types.v1alpha; // // ![Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/types/v1alpha/link.proto.dot.xs.svg) // [Open Message Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/types/v1alpha/link.proto.dot.svg) - message Link { // Link type // // Ex: "LG" or "TC" - LinkType link_type = 1; + LinkType type = 1; // Link description // // Ex: "Baggage conditions" - string link_description = 2; + string description = 2; // Link reference // // Ex: "https://api.lyko.tech/v2.1/transfers/ebaa9aed-dbc4-4d51-a41a-336a3c3e9bfc/pdf-terms-and-conditions" - string link_ref = 3; + string ref = 3; } enum LinkType { @@ -32,7 +31,7 @@ enum LinkType { LINK_TYPE_BOOKING = 4; LINK_TYPE_SUPPORT = 5; LINK_TYPE_FEEDBACK = 6; - LINK_TYPE_COMPLAIN = 7; + LINK_TYPE_COMPLAINT = 7; LINK_TYPE_FACEBOOK = 8; LINK_TYPE_INSTAGRAM = 9; LINK_TYPE_X = 10; diff --git a/proto/cmp/types/v1alpha/redemption.proto b/proto/cmp/types/v1alpha/redemption.proto index 4511dfe..6552b18 100644 --- a/proto/cmp/types/v1alpha/redemption.proto +++ b/proto/cmp/types/v1alpha/redemption.proto @@ -6,7 +6,6 @@ package cmp.types.v1alpha; // // ![Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/types/v1alpha/redemption.proto.dot.xs.svg) // [Open Message Diagram](https://storage.googleapis.com/docs-cmp-files/diagrams/proto/cmp/types/v1alpha/redemption.proto.dot.svg) - enum RedemptionMethod { REDEMPTION_METHOD_UNSPECIFIED = 0; REDEMPTION_METHOD_OTHER = 1;