generated/google/apis/content_v2sandbox/classes.rb in google-api-client-0.24.2 vs generated/google/apis/content_v2sandbox/classes.rb in google-api-client-0.24.3

- old
+ new

@@ -45,10 +45,35 @@ @pretax = args[:pretax] if args.key?(:pretax) @tax = args[:tax] if args.key?(:tax) end end + # + class CustomerReturnReason + include Google::Apis::Core::Hashable + + # + # Corresponds to the JSON property `description` + # @return [String] + attr_accessor :description + + # + # Corresponds to the JSON property `reasonCode` + # @return [String] + attr_accessor :reason_code + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @description = args[:description] if args.key?(:description) + @reason_code = args[:reason_code] if args.key?(:reason_code) + end + end + # An error returned by the API. class Error include Google::Apis::Core::Hashable # The domain of the error. @@ -192,10 +217,108 @@ @type = args[:type] if args.key?(:type) end end # + class MerchantOrderReturn + include Google::Apis::Core::Hashable + + # + # Corresponds to the JSON property `creationDate` + # @return [String] + attr_accessor :creation_date + + # + # Corresponds to the JSON property `merchantOrderId` + # @return [String] + attr_accessor :merchant_order_id + + # + # Corresponds to the JSON property `orderId` + # @return [String] + attr_accessor :order_id + + # + # Corresponds to the JSON property `orderReturnId` + # @return [String] + attr_accessor :order_return_id + + # + # Corresponds to the JSON property `returnItems` + # @return [Array<Google::Apis::ContentV2sandbox::MerchantOrderReturnItem>] + attr_accessor :return_items + + # + # Corresponds to the JSON property `returnShipments` + # @return [Array<Google::Apis::ContentV2sandbox::ReturnShipment>] + attr_accessor :return_shipments + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @creation_date = args[:creation_date] if args.key?(:creation_date) + @merchant_order_id = args[:merchant_order_id] if args.key?(:merchant_order_id) + @order_id = args[:order_id] if args.key?(:order_id) + @order_return_id = args[:order_return_id] if args.key?(:order_return_id) + @return_items = args[:return_items] if args.key?(:return_items) + @return_shipments = args[:return_shipments] if args.key?(:return_shipments) + end + end + + # + class MerchantOrderReturnItem + include Google::Apis::Core::Hashable + + # + # Corresponds to the JSON property `customerReturnReason` + # @return [Google::Apis::ContentV2sandbox::CustomerReturnReason] + attr_accessor :customer_return_reason + + # + # Corresponds to the JSON property `itemId` + # @return [String] + attr_accessor :item_id + + # + # Corresponds to the JSON property `merchantReturnReason` + # @return [Google::Apis::ContentV2sandbox::RefundReason] + attr_accessor :merchant_return_reason + + # + # Corresponds to the JSON property `product` + # @return [Google::Apis::ContentV2sandbox::OrderLineItemProduct] + attr_accessor :product + + # + # Corresponds to the JSON property `returnShipmentIds` + # @return [Array<String>] + attr_accessor :return_shipment_ids + + # + # Corresponds to the JSON property `state` + # @return [String] + attr_accessor :state + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @customer_return_reason = args[:customer_return_reason] if args.key?(:customer_return_reason) + @item_id = args[:item_id] if args.key?(:item_id) + @merchant_return_reason = args[:merchant_return_reason] if args.key?(:merchant_return_reason) + @product = args[:product] if args.key?(:product) + @return_shipment_ids = args[:return_shipment_ids] if args.key?(:return_shipment_ids) + @state = args[:state] if args.key?(:state) + end + end + + # class Order include Google::Apis::Core::Hashable # Whether the order was acknowledged. # Corresponds to the JSON property `acknowledged` @@ -264,14 +387,14 @@ # The date when the order was placed, in ISO 8601 format. # Corresponds to the JSON property `placedDate` # @return [String] attr_accessor :placed_date - # The details of the merchant provided promotions applied to the order. More - # details about the program are here. + # Deprecated. The details of the merchant provided promotions applied to the + # order. More details about the program are here. # Corresponds to the JSON property `promotions` - # @return [Array<Google::Apis::ContentV2sandbox::OrderPromotion>] + # @return [Array<Google::Apis::ContentV2sandbox::OrderLegacyPromotion>] attr_accessor :promotions # Refunds for the order. # Corresponds to the JSON property `refunds` # @return [Array<Google::Apis::ContentV2sandbox::OrderRefund>] @@ -447,12 +570,11 @@ # class OrderCustomer include Google::Apis::Core::Hashable - # Email address that should be used for order related communications. In certain - # cases this might not be a real users email, but a proxy email. + # Deprecated. # Corresponds to the JSON property `email` # @return [String] attr_accessor :email # Deprecated. Please use marketingRightsInfo instead. @@ -542,10 +664,118 @@ @phone_number = args[:phone_number] if args.key?(:phone_number) end end # + class OrderLegacyPromotion + include Google::Apis::Core::Hashable + + # + # Corresponds to the JSON property `benefits` + # @return [Array<Google::Apis::ContentV2sandbox::OrderLegacyPromotionBenefit>] + attr_accessor :benefits + + # The date and time frame when the promotion is active and ready for validation + # review. Note that the promotion live time may be delayed for a few hours due + # to the validation review. + # Start date and end date are separated by a forward slash (/). The start date + # is specified by the format (YYYY-MM-DD), followed by the letter ?T?, the time + # of the day when the sale starts (in Greenwich Mean Time, GMT), followed by an + # expression of the time zone for the sale. The end date is in the same format. + # Corresponds to the JSON property `effectiveDates` + # @return [String] + attr_accessor :effective_dates + + # Optional. The text code that corresponds to the promotion when applied on the + # retailer?s website. + # Corresponds to the JSON property `genericRedemptionCode` + # @return [String] + attr_accessor :generic_redemption_code + + # The unique ID of the promotion. + # Corresponds to the JSON property `id` + # @return [String] + attr_accessor :id + + # The full title of the promotion. + # Corresponds to the JSON property `longTitle` + # @return [String] + attr_accessor :long_title + + # Whether the promotion is applicable to all products or only specific products. + # Corresponds to the JSON property `productApplicability` + # @return [String] + attr_accessor :product_applicability + + # Indicates that the promotion is valid online. + # Corresponds to the JSON property `redemptionChannel` + # @return [String] + attr_accessor :redemption_channel + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @benefits = args[:benefits] if args.key?(:benefits) + @effective_dates = args[:effective_dates] if args.key?(:effective_dates) + @generic_redemption_code = args[:generic_redemption_code] if args.key?(:generic_redemption_code) + @id = args[:id] if args.key?(:id) + @long_title = args[:long_title] if args.key?(:long_title) + @product_applicability = args[:product_applicability] if args.key?(:product_applicability) + @redemption_channel = args[:redemption_channel] if args.key?(:redemption_channel) + end + end + + # + class OrderLegacyPromotionBenefit + include Google::Apis::Core::Hashable + + # The discount in the order price when the promotion is applied. + # Corresponds to the JSON property `discount` + # @return [Google::Apis::ContentV2sandbox::Price] + attr_accessor :discount + + # The OfferId(s) that were purchased in this order and map to this specific + # benefit of the promotion. + # Corresponds to the JSON property `offerIds` + # @return [Array<String>] + attr_accessor :offer_ids + + # Further describes the benefit of the promotion. Note that we will expand on + # this enumeration as we support new promotion sub-types. + # Corresponds to the JSON property `subType` + # @return [String] + attr_accessor :sub_type + + # The impact on tax when the promotion is applied. + # Corresponds to the JSON property `taxImpact` + # @return [Google::Apis::ContentV2sandbox::Price] + attr_accessor :tax_impact + + # Describes whether the promotion applies to products (e.g. 20% off) or to + # shipping (e.g. Free Shipping). + # Corresponds to the JSON property `type` + # @return [String] + attr_accessor :type + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @discount = args[:discount] if args.key?(:discount) + @offer_ids = args[:offer_ids] if args.key?(:offer_ids) + @sub_type = args[:sub_type] if args.key?(:sub_type) + @tax_impact = args[:tax_impact] if args.key?(:tax_impact) + @type = args[:type] if args.key?(:type) + end + end + + # class OrderLineItem include Google::Apis::Core::Hashable # Annotations that are attached to the line item. # Corresponds to the JSON property `annotations` @@ -962,118 +1192,10 @@ @type = args[:type] if args.key?(:type) end end # - class OrderPromotion - include Google::Apis::Core::Hashable - - # - # Corresponds to the JSON property `benefits` - # @return [Array<Google::Apis::ContentV2sandbox::OrderPromotionBenefit>] - attr_accessor :benefits - - # The date and time frame when the promotion is active and ready for validation - # review. Note that the promotion live time may be delayed for a few hours due - # to the validation review. - # Start date and end date are separated by a forward slash (/). The start date - # is specified by the format (YYYY-MM-DD), followed by the letter ?T?, the time - # of the day when the sale starts (in Greenwich Mean Time, GMT), followed by an - # expression of the time zone for the sale. The end date is in the same format. - # Corresponds to the JSON property `effectiveDates` - # @return [String] - attr_accessor :effective_dates - - # Optional. The text code that corresponds to the promotion when applied on the - # retailer?s website. - # Corresponds to the JSON property `genericRedemptionCode` - # @return [String] - attr_accessor :generic_redemption_code - - # The unique ID of the promotion. - # Corresponds to the JSON property `id` - # @return [String] - attr_accessor :id - - # The full title of the promotion. - # Corresponds to the JSON property `longTitle` - # @return [String] - attr_accessor :long_title - - # Whether the promotion is applicable to all products or only specific products. - # Corresponds to the JSON property `productApplicability` - # @return [String] - attr_accessor :product_applicability - - # Indicates that the promotion is valid online. - # Corresponds to the JSON property `redemptionChannel` - # @return [String] - attr_accessor :redemption_channel - - def initialize(**args) - update!(**args) - end - - # Update properties of this object - def update!(**args) - @benefits = args[:benefits] if args.key?(:benefits) - @effective_dates = args[:effective_dates] if args.key?(:effective_dates) - @generic_redemption_code = args[:generic_redemption_code] if args.key?(:generic_redemption_code) - @id = args[:id] if args.key?(:id) - @long_title = args[:long_title] if args.key?(:long_title) - @product_applicability = args[:product_applicability] if args.key?(:product_applicability) - @redemption_channel = args[:redemption_channel] if args.key?(:redemption_channel) - end - end - - # - class OrderPromotionBenefit - include Google::Apis::Core::Hashable - - # The discount in the order price when the promotion is applied. - # Corresponds to the JSON property `discount` - # @return [Google::Apis::ContentV2sandbox::Price] - attr_accessor :discount - - # The OfferId(s) that were purchased in this order and map to this specific - # benefit of the promotion. - # Corresponds to the JSON property `offerIds` - # @return [Array<String>] - attr_accessor :offer_ids - - # Further describes the benefit of the promotion. Note that we will expand on - # this enumeration as we support new promotion sub-types. - # Corresponds to the JSON property `subType` - # @return [String] - attr_accessor :sub_type - - # The impact on tax when the promotion is applied. - # Corresponds to the JSON property `taxImpact` - # @return [Google::Apis::ContentV2sandbox::Price] - attr_accessor :tax_impact - - # Describes whether the promotion applies to products (e.g. 20% off) or to - # shipping (e.g. Free Shipping). - # Corresponds to the JSON property `type` - # @return [String] - attr_accessor :type - - def initialize(**args) - update!(**args) - end - - # Update properties of this object - def update!(**args) - @discount = args[:discount] if args.key?(:discount) - @offer_ids = args[:offer_ids] if args.key?(:offer_ids) - @sub_type = args[:sub_type] if args.key?(:sub_type) - @tax_impact = args[:tax_impact] if args.key?(:tax_impact) - @type = args[:type] if args.key?(:type) - end - end - - # class OrderRefund include Google::Apis::Core::Hashable # The actor that created the refund. # Corresponds to the JSON property `actor` @@ -1558,23 +1680,29 @@ # Whether charge was successful. # Corresponds to the JSON property `chargeState` # @return [String] attr_accessor :charge_state - # Invoice ID from orderInvoice service that corresponds to the charge. + # Deprecated. Please use invoiceIds instead. # Corresponds to the JSON property `invoiceId` # @return [String] attr_accessor :invoice_id + # Invoice IDs from the orderinvoices service that correspond to the charge. + # Corresponds to the JSON property `invoiceIds` + # @return [Array<String>] + attr_accessor :invoice_ids + def initialize(**args) update!(**args) end # Update properties of this object def update!(**args) @charge_state = args[:charge_state] if args.key?(:charge_state) @invoice_id = args[:invoice_id] if args.key?(:invoice_id) + @invoice_ids = args[:invoice_ids] if args.key?(:invoice_ids) end end # class OrderpaymentsNotifyChargeResponse @@ -1604,15 +1732,20 @@ # class OrderpaymentsNotifyRefundRequest include Google::Apis::Core::Hashable - # Invoice ID from orderInvoice service that corresponds to the charge. + # Deprecated. Please use invoiceIds instead. # Corresponds to the JSON property `invoiceId` # @return [String] attr_accessor :invoice_id + # Invoice IDs from the orderinvoices service that correspond to the refund. + # Corresponds to the JSON property `invoiceIds` + # @return [Array<String>] + attr_accessor :invoice_ids + # Whether refund was successful. # Corresponds to the JSON property `refundState` # @return [String] attr_accessor :refund_state @@ -1621,10 +1754,11 @@ end # Update properties of this object def update!(**args) @invoice_id = args[:invoice_id] if args.key?(:invoice_id) + @invoice_ids = args[:invoice_ids] if args.key?(:invoice_ids) @refund_state = args[:refund_state] if args.key?(:refund_state) end end # @@ -1652,10 +1786,42 @@ @kind = args[:kind] if args.key?(:kind) end end # + class OrderreturnsListResponse + include Google::Apis::Core::Hashable + + # Identifies what kind of resource this is. Value: the fixed string "content# + # orderreturnsListResponse". + # Corresponds to the JSON property `kind` + # @return [String] + attr_accessor :kind + + # The token for the retrieval of the next page of returns. + # Corresponds to the JSON property `nextPageToken` + # @return [String] + attr_accessor :next_page_token + + # + # Corresponds to the JSON property `resources` + # @return [Array<Google::Apis::ContentV2sandbox::MerchantOrderReturn>] + attr_accessor :resources + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @kind = args[:kind] if args.key?(:kind) + @next_page_token = args[:next_page_token] if args.key?(:next_page_token) + @resources = args[:resources] if args.key?(:resources) + end + end + + # class OrdersAcknowledgeRequest include Google::Apis::Core::Hashable # The ID of the operation. Unique across all operations for a given order. # Corresponds to the JSON property `operationId` @@ -3683,10 +3849,72 @@ @promotion_id = args[:promotion_id] if args.key?(:promotion_id) end end # + class RefundReason + include Google::Apis::Core::Hashable + + # + # Corresponds to the JSON property `description` + # @return [String] + attr_accessor :description + + # + # Corresponds to the JSON property `reasonCode` + # @return [String] + attr_accessor :reason_code + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @description = args[:description] if args.key?(:description) + @reason_code = args[:reason_code] if args.key?(:reason_code) + end + end + + # + class ReturnShipment + include Google::Apis::Core::Hashable + + # + # Corresponds to the JSON property `creationDate` + # @return [String] + attr_accessor :creation_date + + # + # Corresponds to the JSON property `returnMethodType` + # @return [String] + attr_accessor :return_method_type + + # + # Corresponds to the JSON property `shipmentId` + # @return [String] + attr_accessor :shipment_id + + # + # Corresponds to the JSON property `shipmentTrackingInfos` + # @return [Array<Google::Apis::ContentV2sandbox::ShipmentTrackingInfo>] + attr_accessor :shipment_tracking_infos + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @creation_date = args[:creation_date] if args.key?(:creation_date) + @return_method_type = args[:return_method_type] if args.key?(:return_method_type) + @shipment_id = args[:shipment_id] if args.key?(:shipment_id) + @shipment_tracking_infos = args[:shipment_tracking_infos] if args.key?(:shipment_tracking_infos) + end + end + + # class ShipmentInvoice include Google::Apis::Core::Hashable # [required] Invoice summary. # Corresponds to the JSON property `invoiceSummary` @@ -3752,10 +3980,35 @@ @unit_invoice = args[:unit_invoice] if args.key?(:unit_invoice) end end # + class ShipmentTrackingInfo + include Google::Apis::Core::Hashable + + # + # Corresponds to the JSON property `carrier` + # @return [String] + attr_accessor :carrier + + # + # Corresponds to the JSON property `trackingNumber` + # @return [String] + attr_accessor :tracking_number + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @carrier = args[:carrier] if args.key?(:carrier) + @tracking_number = args[:tracking_number] if args.key?(:tracking_number) + end + end + + # class TestOrder include Google::Apis::Core::Hashable # The details of the customer who placed the order. # Corresponds to the JSON property `customer` @@ -3793,14 +4046,14 @@ # Identifier of one of the predefined delivery addresses for the delivery. # Corresponds to the JSON property `predefinedDeliveryAddress` # @return [String] attr_accessor :predefined_delivery_address - # The details of the merchant provided promotions applied to the order. More - # details about the program are here. + # Deprecated. The details of the merchant provided promotions applied to the + # order. More details about the program are here. # Corresponds to the JSON property `promotions` - # @return [Array<Google::Apis::ContentV2sandbox::OrderPromotion>] + # @return [Array<Google::Apis::ContentV2sandbox::OrderLegacyPromotion>] attr_accessor :promotions # The total cost of shipping for all items. # Corresponds to the JSON property `shippingCost` # @return [Google::Apis::ContentV2sandbox::Price] @@ -3838,10 +4091,10 @@ # class TestOrderCustomer include Google::Apis::Core::Hashable - # Email address of the customer. + # Deprecated. # Corresponds to the JSON property `email` # @return [String] attr_accessor :email # Deprecated. Please use marketingRightsInfo instead.