Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
9383 lines (8239 sloc) 349 KB
// Copyright 2019 Google LLC.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// Code generated file. DO NOT EDIT.
// Package content provides access to the Content API for Shopping.
//
// For product documentation, see: https://developers.google.com/shopping-content
//
// Creating a client
//
// Usage example:
//
// import "google.golang.org/api/content/v2sandbox"
// ...
// ctx := context.Background()
// contentService, err := content.NewService(ctx)
//
// In this example, Google Application Default Credentials are used for authentication.
//
// For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
//
// Other authentication options
//
// To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:
//
// contentService, err := content.NewService(ctx, option.WithAPIKey("AIza..."))
//
// To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:
//
// config := &oauth2.Config{...}
// // ...
// token, err := config.Exchange(ctx, ...)
// contentService, err := content.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
//
// See https://godoc.org/google.golang.org/api/option/ for details on options.
package content // import "google.golang.org/api/content/v2sandbox"
import (
"bytes"
"context"
"encoding/json"
"errors"
"fmt"
"io"
"net/http"
"net/url"
"strconv"
"strings"
googleapi "google.golang.org/api/googleapi"
gensupport "google.golang.org/api/internal/gensupport"
option "google.golang.org/api/option"
htransport "google.golang.org/api/transport/http"
)
// Always reference these packages, just in case the auto-generated code
// below doesn't.
var _ = bytes.NewBuffer
var _ = strconv.Itoa
var _ = fmt.Sprintf
var _ = json.NewDecoder
var _ = io.Copy
var _ = url.Parse
var _ = gensupport.MarshalJSON
var _ = googleapi.Version
var _ = errors.New
var _ = strings.Replace
var _ = context.Canceled
const apiId = "content:v2sandbox"
const apiName = "content"
const apiVersion = "v2sandbox"
const basePath = "https://www.googleapis.com/content/v2sandbox/"
// OAuth2 scopes used by this API.
const (
// Manage your product listings and accounts for Google Shopping
ContentScope = "https://www.googleapis.com/auth/content"
)
// NewService creates a new APIService.
func NewService(ctx context.Context, opts ...option.ClientOption) (*APIService, error) {
scopesOption := option.WithScopes(
"https://www.googleapis.com/auth/content",
)
// NOTE: prepend, so we don't override user-specified scopes.
opts = append([]option.ClientOption{scopesOption}, opts...)
client, endpoint, err := htransport.NewClient(ctx, opts...)
if err != nil {
return nil, err
}
s, err := New(client)
if err != nil {
return nil, err
}
if endpoint != "" {
s.BasePath = endpoint
}
return s, nil
}
// New creates a new APIService. It uses the provided http.Client for requests.
//
// Deprecated: please use NewService instead.
// To provide a custom HTTP client, use option.WithHTTPClient.
// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
func New(client *http.Client) (*APIService, error) {
if client == nil {
return nil, errors.New("client is nil")
}
s := &APIService{client: client, BasePath: basePath}
s.Orderinvoices = NewOrderinvoicesService(s)
s.Orderpayments = NewOrderpaymentsService(s)
s.Orderreturns = NewOrderreturnsService(s)
s.Orders = NewOrdersService(s)
return s, nil
}
type APIService struct {
client *http.Client
BasePath string // API endpoint base URL
UserAgent string // optional additional User-Agent fragment
Orderinvoices *OrderinvoicesService
Orderpayments *OrderpaymentsService
Orderreturns *OrderreturnsService
Orders *OrdersService
}
func (s *APIService) userAgent() string {
if s.UserAgent == "" {
return googleapi.UserAgent
}
return googleapi.UserAgent + " " + s.UserAgent
}
func NewOrderinvoicesService(s *APIService) *OrderinvoicesService {
rs := &OrderinvoicesService{s: s}
return rs
}
type OrderinvoicesService struct {
s *APIService
}
func NewOrderpaymentsService(s *APIService) *OrderpaymentsService {
rs := &OrderpaymentsService{s: s}
return rs
}
type OrderpaymentsService struct {
s *APIService
}
func NewOrderreturnsService(s *APIService) *OrderreturnsService {
rs := &OrderreturnsService{s: s}
return rs
}
type OrderreturnsService struct {
s *APIService
}
func NewOrdersService(s *APIService) *OrdersService {
rs := &OrdersService{s: s}
return rs
}
type OrdersService struct {
s *APIService
}
type Amount struct {
// Pretax: [required] Value before taxes.
Pretax *Price `json:"pretax,omitempty"`
// Tax: [required] Tax value.
Tax *Price `json:"tax,omitempty"`
// ForceSendFields is a list of field names (e.g. "Pretax") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Pretax") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *Amount) MarshalJSON() ([]byte, error) {
type NoMethod Amount
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type CustomerReturnReason struct {
Description string `json:"description,omitempty"`
ReasonCode string `json:"reasonCode,omitempty"`
// ForceSendFields is a list of field names (e.g. "Description") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Description") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *CustomerReturnReason) MarshalJSON() ([]byte, error) {
type NoMethod CustomerReturnReason
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// Error: An error returned by the API.
type Error struct {
// Domain: The domain of the error.
Domain string `json:"domain,omitempty"`
// Message: A description of the error.
Message string `json:"message,omitempty"`
// Reason: The error code.
Reason string `json:"reason,omitempty"`
// ForceSendFields is a list of field names (e.g. "Domain") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Domain") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *Error) MarshalJSON() ([]byte, error) {
type NoMethod Error
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// Errors: A list of errors returned by a failed batch entry.
type Errors struct {
// Code: The HTTP status of the first error in errors.
Code int64 `json:"code,omitempty"`
// Errors: A list of errors.
Errors []*Error `json:"errors,omitempty"`
// Message: The message of the first error in errors.
Message string `json:"message,omitempty"`
// ForceSendFields is a list of field names (e.g. "Code") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Code") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *Errors) MarshalJSON() ([]byte, error) {
type NoMethod Errors
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type InvoiceSummary struct {
// AdditionalChargeSummaries: Summary of the total amounts of the
// additional charges.
AdditionalChargeSummaries []*InvoiceSummaryAdditionalChargeSummary `json:"additionalChargeSummaries,omitempty"`
// CustomerBalance: [required] Customer balance on this invoice. A
// negative amount means the customer is paying, a positive one means
// the customer is receiving money. Note: the sum of merchant_balance,
// customer_balance and google_balance must always be zero.
//
// Furthermore the absolute value of this amount is expected to be equal
// to the sum of product amount and additional charges, minus
// promotions.
CustomerBalance *Amount `json:"customerBalance,omitempty"`
// GoogleBalance: [required] Google balance on this invoice. A negative
// amount means Google is paying, a positive one means Google is
// receiving money. Note: the sum of merchant_balance, customer_balance
// and google_balance must always be zero.
GoogleBalance *Amount `json:"googleBalance,omitempty"`
// MerchantBalance: [required] Merchant balance on this invoice. A
// negative amount means the merchant is paying, a positive one means
// the merchant is receiving money. Note: the sum of merchant_balance,
// customer_balance and google_balance must always be zero.
MerchantBalance *Amount `json:"merchantBalance,omitempty"`
// ProductTotal: [required] Total price for the product.
ProductTotal *Amount `json:"productTotal,omitempty"`
// PromotionSummaries: Summary for each promotion.
PromotionSummaries []*Promotion `json:"promotionSummaries,omitempty"`
// ForceSendFields is a list of field names (e.g.
// "AdditionalChargeSummaries") to unconditionally include in API
// requests. By default, fields with empty values are omitted from API
// requests. However, any non-pointer, non-interface field appearing in
// ForceSendFields will be sent to the server regardless of whether the
// field is empty or not. This may be used to include empty fields in
// Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g.
// "AdditionalChargeSummaries") to include in API requests with the JSON
// null value. By default, fields with empty values are omitted from API
// requests. However, any field with an empty value appearing in
// NullFields will be sent to the server as null. It is an error if a
// field in this list has a non-empty value. This may be used to include
// null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *InvoiceSummary) MarshalJSON() ([]byte, error) {
type NoMethod InvoiceSummary
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type InvoiceSummaryAdditionalChargeSummary struct {
// TotalAmount: [required] Total additional charge for this type.
TotalAmount *Amount `json:"totalAmount,omitempty"`
// Type: [required] Type of the additional charge.
Type string `json:"type,omitempty"`
// ForceSendFields is a list of field names (e.g. "TotalAmount") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "TotalAmount") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *InvoiceSummaryAdditionalChargeSummary) MarshalJSON() ([]byte, error) {
type NoMethod InvoiceSummaryAdditionalChargeSummary
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type MerchantOrderReturn struct {
CreationDate string `json:"creationDate,omitempty"`
MerchantOrderId string `json:"merchantOrderId,omitempty"`
OrderId string `json:"orderId,omitempty"`
OrderReturnId string `json:"orderReturnId,omitempty"`
ReturnItems []*MerchantOrderReturnItem `json:"returnItems,omitempty"`
ReturnShipments []*ReturnShipment `json:"returnShipments,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "CreationDate") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "CreationDate") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *MerchantOrderReturn) MarshalJSON() ([]byte, error) {
type NoMethod MerchantOrderReturn
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type MerchantOrderReturnItem struct {
CustomerReturnReason *CustomerReturnReason `json:"customerReturnReason,omitempty"`
ItemId string `json:"itemId,omitempty"`
MerchantReturnReason *RefundReason `json:"merchantReturnReason,omitempty"`
Product *OrderLineItemProduct `json:"product,omitempty"`
ReturnShipmentIds []string `json:"returnShipmentIds,omitempty"`
State string `json:"state,omitempty"`
// ForceSendFields is a list of field names (e.g.
// "CustomerReturnReason") to unconditionally include in API requests.
// By default, fields with empty values are omitted from API requests.
// However, any non-pointer, non-interface field appearing in
// ForceSendFields will be sent to the server regardless of whether the
// field is empty or not. This may be used to include empty fields in
// Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "CustomerReturnReason") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *MerchantOrderReturnItem) MarshalJSON() ([]byte, error) {
type NoMethod MerchantOrderReturnItem
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type Order struct {
// Acknowledged: Whether the order was acknowledged.
Acknowledged bool `json:"acknowledged,omitempty"`
// ChannelType: The channel type of the order: "purchaseOnGoogle" or
// "googleExpress".
ChannelType string `json:"channelType,omitempty"`
// Customer: The details of the customer who placed the order.
Customer *OrderCustomer `json:"customer,omitempty"`
// DeliveryDetails: The details for the delivery.
DeliveryDetails *OrderDeliveryDetails `json:"deliveryDetails,omitempty"`
// Id: The REST id of the order. Globally unique.
Id string `json:"id,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#order".
Kind string `json:"kind,omitempty"`
// LineItems: Line items that are ordered.
LineItems []*OrderLineItem `json:"lineItems,omitempty"`
MerchantId uint64 `json:"merchantId,omitempty,string"`
// MerchantOrderId: Merchant-provided id of the order.
MerchantOrderId string `json:"merchantOrderId,omitempty"`
// NetAmount: The net amount for the order. For example, if an order was
// originally for a grand total of $100 and a refund was issued for $20,
// the net amount will be $80.
NetAmount *Price `json:"netAmount,omitempty"`
// PaymentMethod: The details of the payment method.
PaymentMethod *OrderPaymentMethod `json:"paymentMethod,omitempty"`
// PaymentStatus: The status of the payment.
PaymentStatus string `json:"paymentStatus,omitempty"`
// PlacedDate: The date when the order was placed, in ISO 8601 format.
PlacedDate string `json:"placedDate,omitempty"`
// Promotions: Deprecated. The details of the merchant provided
// promotions applied to the order. More details about the program are
// here.
Promotions []*OrderLegacyPromotion `json:"promotions,omitempty"`
// Refunds: Refunds for the order.
Refunds []*OrderRefund `json:"refunds,omitempty"`
// Shipments: Shipments of the order.
Shipments []*OrderShipment `json:"shipments,omitempty"`
// ShippingCost: The total cost of shipping for all items.
ShippingCost *Price `json:"shippingCost,omitempty"`
// ShippingCostTax: The tax for the total shipping cost.
ShippingCostTax *Price `json:"shippingCostTax,omitempty"`
// ShippingOption: The requested shipping option.
ShippingOption string `json:"shippingOption,omitempty"`
// Status: The status of the order.
Status string `json:"status,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Acknowledged") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Acknowledged") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *Order) MarshalJSON() ([]byte, error) {
type NoMethod Order
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderAddress struct {
// Country: CLDR country code (e.g. "US").
Country string `json:"country,omitempty"`
// FullAddress: Strings representing the lines of the printed label for
// mailing the order, for example:
// John Smith
// 1600 Amphitheatre Parkway
// Mountain View, CA, 94043
// United States
FullAddress []string `json:"fullAddress,omitempty"`
// IsPostOfficeBox: Whether the address is a post office box.
IsPostOfficeBox bool `json:"isPostOfficeBox,omitempty"`
// Locality: City, town or commune. May also include dependent
// localities or sublocalities (e.g. neighborhoods or suburbs).
Locality string `json:"locality,omitempty"`
// PostalCode: Postal Code or ZIP (e.g. "94043").
PostalCode string `json:"postalCode,omitempty"`
// RecipientName: Name of the recipient.
RecipientName string `json:"recipientName,omitempty"`
// Region: Top-level administrative subdivision of the country. For
// example, a state like California ("CA") or a province like Quebec
// ("QC").
Region string `json:"region,omitempty"`
// StreetAddress: Street-level part of the address.
StreetAddress []string `json:"streetAddress,omitempty"`
// ForceSendFields is a list of field names (e.g. "Country") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Country") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderAddress) MarshalJSON() ([]byte, error) {
type NoMethod OrderAddress
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderCancellation struct {
// Actor: The actor that created the cancellation.
Actor string `json:"actor,omitempty"`
// CreationDate: Date on which the cancellation has been created, in ISO
// 8601 format.
CreationDate string `json:"creationDate,omitempty"`
// Quantity: The quantity that was canceled.
Quantity int64 `json:"quantity,omitempty"`
// Reason: The reason for the cancellation. Orders that are cancelled
// with a noInventory reason will lead to the removal of the product
// from Shopping Actions until you make an update to that product. This
// will not affect your Shopping ads.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "Actor") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Actor") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderCancellation) MarshalJSON() ([]byte, error) {
type NoMethod OrderCancellation
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderCustomer struct {
// Email: Deprecated.
Email string `json:"email,omitempty"`
// ExplicitMarketingPreference: Deprecated. Please use
// marketingRightsInfo instead.
ExplicitMarketingPreference bool `json:"explicitMarketingPreference,omitempty"`
// FullName: Full name of the customer.
FullName string `json:"fullName,omitempty"`
// MarketingRightsInfo: Customer's marketing preferences.
MarketingRightsInfo *OrderCustomerMarketingRightsInfo `json:"marketingRightsInfo,omitempty"`
// ForceSendFields is a list of field names (e.g. "Email") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Email") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderCustomer) MarshalJSON() ([]byte, error) {
type NoMethod OrderCustomer
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderCustomerMarketingRightsInfo struct {
// ExplicitMarketingPreference: Last known user selection regarding
// marketing preferences. In certain cases this selection might not be
// known, so this field would be empty.
ExplicitMarketingPreference string `json:"explicitMarketingPreference,omitempty"`
// LastUpdatedTimestamp: Timestamp when last time marketing preference
// was updated. Could be empty, if user wasn't offered a selection yet.
LastUpdatedTimestamp string `json:"lastUpdatedTimestamp,omitempty"`
// MarketingEmailAddress: Email address that can be used for marketing
// purposes. This field is only filled when explicitMarketingPreference
// is equal to 'granted'.
MarketingEmailAddress string `json:"marketingEmailAddress,omitempty"`
// ForceSendFields is a list of field names (e.g.
// "ExplicitMarketingPreference") to unconditionally include in API
// requests. By default, fields with empty values are omitted from API
// requests. However, any non-pointer, non-interface field appearing in
// ForceSendFields will be sent to the server regardless of whether the
// field is empty or not. This may be used to include empty fields in
// Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g.
// "ExplicitMarketingPreference") to include in API requests with the
// JSON null value. By default, fields with empty values are omitted
// from API requests. However, any field with an empty value appearing
// in NullFields will be sent to the server as null. It is an error if a
// field in this list has a non-empty value. This may be used to include
// null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderCustomerMarketingRightsInfo) MarshalJSON() ([]byte, error) {
type NoMethod OrderCustomerMarketingRightsInfo
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderDeliveryDetails struct {
// Address: The delivery address
Address *OrderAddress `json:"address,omitempty"`
// PhoneNumber: The phone number of the person receiving the delivery.
PhoneNumber string `json:"phoneNumber,omitempty"`
// ForceSendFields is a list of field names (e.g. "Address") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Address") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderDeliveryDetails) MarshalJSON() ([]byte, error) {
type NoMethod OrderDeliveryDetails
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderLegacyPromotion struct {
Benefits []*OrderLegacyPromotionBenefit `json:"benefits,omitempty"`
// EffectiveDates: 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.
EffectiveDates string `json:"effectiveDates,omitempty"`
// GenericRedemptionCode: Optional. The text code that corresponds to
// the promotion when applied on the retailer?s website.
GenericRedemptionCode string `json:"genericRedemptionCode,omitempty"`
// Id: The unique ID of the promotion.
Id string `json:"id,omitempty"`
// LongTitle: The full title of the promotion.
LongTitle string `json:"longTitle,omitempty"`
// ProductApplicability: Whether the promotion is applicable to all
// products or only specific products.
ProductApplicability string `json:"productApplicability,omitempty"`
// RedemptionChannel: Indicates that the promotion is valid online.
RedemptionChannel string `json:"redemptionChannel,omitempty"`
// ForceSendFields is a list of field names (e.g. "Benefits") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Benefits") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderLegacyPromotion) MarshalJSON() ([]byte, error) {
type NoMethod OrderLegacyPromotion
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderLegacyPromotionBenefit struct {
// Discount: The discount in the order price when the promotion is
// applied.
Discount *Price `json:"discount,omitempty"`
// OfferIds: The OfferId(s) that were purchased in this order and map to
// this specific benefit of the promotion.
OfferIds []string `json:"offerIds,omitempty"`
// SubType: Further describes the benefit of the promotion. Note that we
// will expand on this enumeration as we support new promotion
// sub-types.
SubType string `json:"subType,omitempty"`
// TaxImpact: The impact on tax when the promotion is applied.
TaxImpact *Price `json:"taxImpact,omitempty"`
// Type: Describes whether the promotion applies to products (e.g. 20%
// off) or to shipping (e.g. Free Shipping).
Type string `json:"type,omitempty"`
// ForceSendFields is a list of field names (e.g. "Discount") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Discount") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderLegacyPromotionBenefit) MarshalJSON() ([]byte, error) {
type NoMethod OrderLegacyPromotionBenefit
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderLineItem struct {
// Annotations: Annotations that are attached to the line item.
Annotations []*OrderMerchantProvidedAnnotation `json:"annotations,omitempty"`
// Cancellations: Cancellations of the line item.
Cancellations []*OrderCancellation `json:"cancellations,omitempty"`
// Id: The id of the line item.
Id string `json:"id,omitempty"`
// Price: Total price for the line item. For example, if two items for
// $10 are purchased, the total price will be $20.
Price *Price `json:"price,omitempty"`
// Product: Product data from the time of the order placement.
Product *OrderLineItemProduct `json:"product,omitempty"`
// QuantityCanceled: Number of items canceled.
QuantityCanceled int64 `json:"quantityCanceled,omitempty"`
// QuantityDelivered: Number of items delivered.
QuantityDelivered int64 `json:"quantityDelivered,omitempty"`
// QuantityOrdered: Number of items ordered.
QuantityOrdered int64 `json:"quantityOrdered,omitempty"`
// QuantityPending: Number of items pending.
QuantityPending int64 `json:"quantityPending,omitempty"`
// QuantityReturned: Number of items returned.
QuantityReturned int64 `json:"quantityReturned,omitempty"`
// QuantityShipped: Number of items shipped.
QuantityShipped int64 `json:"quantityShipped,omitempty"`
// ReturnInfo: Details of the return policy for the line item.
ReturnInfo *OrderLineItemReturnInfo `json:"returnInfo,omitempty"`
// Returns: Returns of the line item.
Returns []*OrderReturn `json:"returns,omitempty"`
// ShippingDetails: Details of the requested shipping for the line item.
ShippingDetails *OrderLineItemShippingDetails `json:"shippingDetails,omitempty"`
// Tax: Total tax amount for the line item. For example, if two items
// are purchased, and each have a cost tax of $2, the total tax amount
// will be $4.
Tax *Price `json:"tax,omitempty"`
// ForceSendFields is a list of field names (e.g. "Annotations") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Annotations") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderLineItem) MarshalJSON() ([]byte, error) {
type NoMethod OrderLineItem
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderLineItemProduct struct {
// Brand: Brand of the item.
Brand string `json:"brand,omitempty"`
// Channel: The item's channel (online or local).
Channel string `json:"channel,omitempty"`
// Condition: Condition or state of the item.
Condition string `json:"condition,omitempty"`
// ContentLanguage: The two-letter ISO 639-1 language code for the item.
ContentLanguage string `json:"contentLanguage,omitempty"`
// Gtin: Global Trade Item Number (GTIN) of the item.
Gtin string `json:"gtin,omitempty"`
// Id: The REST id of the product.
Id string `json:"id,omitempty"`
// ImageLink: URL of an image of the item.
ImageLink string `json:"imageLink,omitempty"`
// ItemGroupId: Shared identifier for all variants of the same product.
ItemGroupId string `json:"itemGroupId,omitempty"`
// Mpn: Manufacturer Part Number (MPN) of the item.
Mpn string `json:"mpn,omitempty"`
// OfferId: An identifier of the item.
OfferId string `json:"offerId,omitempty"`
// Price: Price of the item.
Price *Price `json:"price,omitempty"`
// ShownImage: URL to the cached image shown to the user when order was
// placed.
ShownImage string `json:"shownImage,omitempty"`
// TargetCountry: The CLDR territory code of the target country of the
// product.
TargetCountry string `json:"targetCountry,omitempty"`
// Title: The title of the product.
Title string `json:"title,omitempty"`
// VariantAttributes: Variant attributes for the item. These are
// dimensions of the product, such as color, gender, material, pattern,
// and size. You can find a comprehensive list of variant attributes
// here.
VariantAttributes []*OrderLineItemProductVariantAttribute `json:"variantAttributes,omitempty"`
// ForceSendFields is a list of field names (e.g. "Brand") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Brand") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderLineItemProduct) MarshalJSON() ([]byte, error) {
type NoMethod OrderLineItemProduct
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderLineItemProductVariantAttribute struct {
// Dimension: The dimension of the variant.
Dimension string `json:"dimension,omitempty"`
// Value: The value for the dimension.
Value string `json:"value,omitempty"`
// ForceSendFields is a list of field names (e.g. "Dimension") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Dimension") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderLineItemProductVariantAttribute) MarshalJSON() ([]byte, error) {
type NoMethod OrderLineItemProductVariantAttribute
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderLineItemReturnInfo struct {
// DaysToReturn: How many days later the item can be returned.
DaysToReturn int64 `json:"daysToReturn,omitempty"`
// IsReturnable: Whether the item is returnable.
IsReturnable bool `json:"isReturnable,omitempty"`
// PolicyUrl: URL of the item return policy.
PolicyUrl string `json:"policyUrl,omitempty"`
// ForceSendFields is a list of field names (e.g. "DaysToReturn") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "DaysToReturn") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderLineItemReturnInfo) MarshalJSON() ([]byte, error) {
type NoMethod OrderLineItemReturnInfo
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderLineItemShippingDetails struct {
// DeliverByDate: The delivery by date, in ISO 8601 format.
DeliverByDate string `json:"deliverByDate,omitempty"`
// Method: Details of the shipping method.
Method *OrderLineItemShippingDetailsMethod `json:"method,omitempty"`
// ShipByDate: The ship by date, in ISO 8601 format.
ShipByDate string `json:"shipByDate,omitempty"`
// ForceSendFields is a list of field names (e.g. "DeliverByDate") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "DeliverByDate") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderLineItemShippingDetails) MarshalJSON() ([]byte, error) {
type NoMethod OrderLineItemShippingDetails
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderLineItemShippingDetailsMethod struct {
// Carrier: The carrier for the shipping. Optional. See
// shipments[].carrier for a list of acceptable values.
Carrier string `json:"carrier,omitempty"`
// MaxDaysInTransit: Maximum transit time.
MaxDaysInTransit int64 `json:"maxDaysInTransit,omitempty"`
// MethodName: The name of the shipping method.
MethodName string `json:"methodName,omitempty"`
// MinDaysInTransit: Minimum transit time.
MinDaysInTransit int64 `json:"minDaysInTransit,omitempty"`
// ForceSendFields is a list of field names (e.g. "Carrier") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Carrier") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderLineItemShippingDetailsMethod) MarshalJSON() ([]byte, error) {
type NoMethod OrderLineItemShippingDetailsMethod
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderMerchantProvidedAnnotation struct {
// Key: Key for additional merchant provided (as key-value pairs)
// annotation about the line item.
Key string `json:"key,omitempty"`
// Value: Value for additional merchant provided (as key-value pairs)
// annotation about the line item.
Value string `json:"value,omitempty"`
// ForceSendFields is a list of field names (e.g. "Key") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Key") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderMerchantProvidedAnnotation) MarshalJSON() ([]byte, error) {
type NoMethod OrderMerchantProvidedAnnotation
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderPaymentMethod struct {
// BillingAddress: The billing address.
BillingAddress *OrderAddress `json:"billingAddress,omitempty"`
// ExpirationMonth: The card expiration month (January = 1, February = 2
// etc.).
ExpirationMonth int64 `json:"expirationMonth,omitempty"`
// ExpirationYear: The card expiration year (4-digit, e.g. 2015).
ExpirationYear int64 `json:"expirationYear,omitempty"`
// LastFourDigits: The last four digits of the card number.
LastFourDigits string `json:"lastFourDigits,omitempty"`
// PhoneNumber: The billing phone number.
PhoneNumber string `json:"phoneNumber,omitempty"`
// Type: The type of instrument.
//
// Acceptable values are:
// - "AMEX"
// - "DISCOVER"
// - "JCB"
// - "MASTERCARD"
// - "UNIONPAY"
// - "VISA"
// - ""
Type string `json:"type,omitempty"`
// ForceSendFields is a list of field names (e.g. "BillingAddress") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "BillingAddress") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrderPaymentMethod) MarshalJSON() ([]byte, error) {
type NoMethod OrderPaymentMethod
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderRefund struct {
// Actor: The actor that created the refund.
Actor string `json:"actor,omitempty"`
// Amount: The amount that is refunded.
Amount *Price `json:"amount,omitempty"`
// CreationDate: Date on which the item has been created, in ISO 8601
// format.
CreationDate string `json:"creationDate,omitempty"`
// Reason: The reason for the refund.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "Actor") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Actor") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderRefund) MarshalJSON() ([]byte, error) {
type NoMethod OrderRefund
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderReturn struct {
// Actor: The actor that created the refund.
Actor string `json:"actor,omitempty"`
// CreationDate: Date on which the item has been created, in ISO 8601
// format.
CreationDate string `json:"creationDate,omitempty"`
// Quantity: Quantity that is returned.
Quantity int64 `json:"quantity,omitempty"`
// Reason: The reason for the return.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "Actor") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Actor") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderReturn) MarshalJSON() ([]byte, error) {
type NoMethod OrderReturn
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderShipment struct {
// Carrier: The carrier handling the shipment.
//
// Acceptable values are:
// - "gsx"
// - "ups"
// - "usps"
// - "fedex"
// - "dhl"
// - "ecourier"
// - "cxt"
// - "google"
// - "ontrac"
// - "emsy"
// - "ont"
// - "deliv"
// - "dynamex"
// - "lasership"
// - "mpx"
// - "uds"
Carrier string `json:"carrier,omitempty"`
// CreationDate: Date on which the shipment has been created, in ISO
// 8601 format.
CreationDate string `json:"creationDate,omitempty"`
// DeliveryDate: Date on which the shipment has been delivered, in ISO
// 8601 format. Present only if status is delivered
DeliveryDate string `json:"deliveryDate,omitempty"`
// Id: The id of the shipment.
Id string `json:"id,omitempty"`
// LineItems: The line items that are shipped.
LineItems []*OrderShipmentLineItemShipment `json:"lineItems,omitempty"`
// Status: The status of the shipment.
Status string `json:"status,omitempty"`
// TrackingId: The tracking id for the shipment.
TrackingId string `json:"trackingId,omitempty"`
// ForceSendFields is a list of field names (e.g. "Carrier") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Carrier") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderShipment) MarshalJSON() ([]byte, error) {
type NoMethod OrderShipment
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderShipmentLineItemShipment struct {
// LineItemId: The id of the line item that is shipped. Either
// lineItemId or productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// ProductId: The ID of the product to ship. This is the REST ID used in
// the products service. Either lineItemId or productId is required.
ProductId string `json:"productId,omitempty"`
// Quantity: The quantity that is shipped.
Quantity int64 `json:"quantity,omitempty"`
// ForceSendFields is a list of field names (e.g. "LineItemId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "LineItemId") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderShipmentLineItemShipment) MarshalJSON() ([]byte, error) {
type NoMethod OrderShipmentLineItemShipment
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderinvoicesCreateChargeInvoiceRequest struct {
// InvoiceId: [required] The ID of the invoice.
InvoiceId string `json:"invoiceId,omitempty"`
// InvoiceSummary: [required] Invoice summary.
InvoiceSummary *InvoiceSummary `json:"invoiceSummary,omitempty"`
// LineItemInvoices: [required] Invoice details per line item.
LineItemInvoices []*ShipmentInvoiceLineItemInvoice `json:"lineItemInvoices,omitempty"`
// OperationId: [required] The ID of the operation, unique across all
// operations for a given order.
OperationId string `json:"operationId,omitempty"`
// ShipmentGroupId: [required] ID of the shipment group.
ShipmentGroupId string `json:"shipmentGroupId,omitempty"`
// ForceSendFields is a list of field names (e.g. "InvoiceId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "InvoiceId") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderinvoicesCreateChargeInvoiceRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrderinvoicesCreateChargeInvoiceRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderinvoicesCreateChargeInvoiceResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#orderinvoicesCreateChargeInvoiceResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrderinvoicesCreateChargeInvoiceResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrderinvoicesCreateChargeInvoiceResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderinvoicesCreateRefundInvoiceRequest struct {
// InvoiceId: [required] The ID of the invoice.
InvoiceId string `json:"invoiceId,omitempty"`
// OperationId: [required] The ID of the operation, unique across all
// operations for a given order.
OperationId string `json:"operationId,omitempty"`
// RefundOnlyOption: Option to create a refund-only invoice. Exactly one
// of refundOnlyOption or returnOption must be provided.
RefundOnlyOption *OrderinvoicesCustomBatchRequestEntryCreateRefundInvoiceRefundOption `json:"refundOnlyOption,omitempty"`
// ReturnOption: Option to create an invoice for a refund and mark all
// items within the invoice as returned. Exactly one of refundOnlyOption
// or returnOption must be provided.
ReturnOption *OrderinvoicesCustomBatchRequestEntryCreateRefundInvoiceReturnOption `json:"returnOption,omitempty"`
// ShipmentInvoices: Invoice details for different shipment groups.
ShipmentInvoices []*ShipmentInvoice `json:"shipmentInvoices,omitempty"`
// ForceSendFields is a list of field names (e.g. "InvoiceId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "InvoiceId") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderinvoicesCreateRefundInvoiceRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrderinvoicesCreateRefundInvoiceRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderinvoicesCreateRefundInvoiceResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#orderinvoicesCreateRefundInvoiceResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrderinvoicesCreateRefundInvoiceResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrderinvoicesCreateRefundInvoiceResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderinvoicesCustomBatchRequestEntryCreateRefundInvoiceRefundOption struct {
// Description: Optional description of the refund reason.
Description string `json:"description,omitempty"`
// Reason: [required] Reason for the refund.
Reason string `json:"reason,omitempty"`
// ForceSendFields is a list of field names (e.g. "Description") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Description") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderinvoicesCustomBatchRequestEntryCreateRefundInvoiceRefundOption) MarshalJSON() ([]byte, error) {
type NoMethod OrderinvoicesCustomBatchRequestEntryCreateRefundInvoiceRefundOption
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderinvoicesCustomBatchRequestEntryCreateRefundInvoiceReturnOption struct {
// Description: Optional description of the return reason.
Description string `json:"description,omitempty"`
// Reason: [required] Reason for the return.
Reason string `json:"reason,omitempty"`
// ForceSendFields is a list of field names (e.g. "Description") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Description") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderinvoicesCustomBatchRequestEntryCreateRefundInvoiceReturnOption) MarshalJSON() ([]byte, error) {
type NoMethod OrderinvoicesCustomBatchRequestEntryCreateRefundInvoiceReturnOption
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderpaymentsNotifyAuthApprovedRequest struct {
AuthAmountPretax *Price `json:"authAmountPretax,omitempty"`
AuthAmountTax *Price `json:"authAmountTax,omitempty"`
// ForceSendFields is a list of field names (e.g. "AuthAmountPretax") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "AuthAmountPretax") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrderpaymentsNotifyAuthApprovedRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrderpaymentsNotifyAuthApprovedRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderpaymentsNotifyAuthApprovedResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#orderpaymentsNotifyAuthApprovedResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrderpaymentsNotifyAuthApprovedResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrderpaymentsNotifyAuthApprovedResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderpaymentsNotifyAuthDeclinedRequest struct {
// DeclineReason: Reason why payment authorization was declined.
DeclineReason string `json:"declineReason,omitempty"`
// ForceSendFields is a list of field names (e.g. "DeclineReason") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "DeclineReason") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderpaymentsNotifyAuthDeclinedRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrderpaymentsNotifyAuthDeclinedRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderpaymentsNotifyAuthDeclinedResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#orderpaymentsNotifyAuthDeclinedResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrderpaymentsNotifyAuthDeclinedResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrderpaymentsNotifyAuthDeclinedResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderpaymentsNotifyChargeRequest struct {
// ChargeState: Whether charge was successful.
ChargeState string `json:"chargeState,omitempty"`
// InvoiceId: Deprecated. Please use invoiceIds instead.
InvoiceId string `json:"invoiceId,omitempty"`
// InvoiceIds: Invoice IDs from the orderinvoices service that
// correspond to the charge.
InvoiceIds []string `json:"invoiceIds,omitempty"`
// ForceSendFields is a list of field names (e.g. "ChargeState") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ChargeState") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderpaymentsNotifyChargeRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrderpaymentsNotifyChargeRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderpaymentsNotifyChargeResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#orderpaymentsNotifyChargeResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrderpaymentsNotifyChargeResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrderpaymentsNotifyChargeResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderpaymentsNotifyRefundRequest struct {
// InvoiceId: Deprecated. Please use invoiceIds instead.
InvoiceId string `json:"invoiceId,omitempty"`
// InvoiceIds: Invoice IDs from the orderinvoices service that
// correspond to the refund.
InvoiceIds []string `json:"invoiceIds,omitempty"`
// RefundState: Whether refund was successful.
RefundState string `json:"refundState,omitempty"`
// ForceSendFields is a list of field names (e.g. "InvoiceId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "InvoiceId") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderpaymentsNotifyRefundRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrderpaymentsNotifyRefundRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderpaymentsNotifyRefundResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#orderpaymentsNotifyRefundResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrderpaymentsNotifyRefundResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrderpaymentsNotifyRefundResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrderreturnsListResponse struct {
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#orderreturnsListResponse".
Kind string `json:"kind,omitempty"`
// NextPageToken: The token for the retrieval of the next page of
// returns.
NextPageToken string `json:"nextPageToken,omitempty"`
Resources []*MerchantOrderReturn `json:"resources,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Kind") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Kind") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrderreturnsListResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrderreturnsListResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersAcknowledgeRequest struct {
// OperationId: The ID of the operation. Unique across all operations
// for a given order.
OperationId string `json:"operationId,omitempty"`
// ForceSendFields is a list of field names (e.g. "OperationId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "OperationId") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersAcknowledgeRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrdersAcknowledgeRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersAcknowledgeResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersAcknowledgeResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrdersAcknowledgeResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersAcknowledgeResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersAdvanceTestOrderResponse struct {
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersAdvanceTestOrderResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Kind") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Kind") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersAdvanceTestOrderResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersAdvanceTestOrderResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCancelLineItemRequest struct {
// Amount: Deprecated. Please use amountPretax and amountTax instead.
Amount *Price `json:"amount,omitempty"`
// AmountPretax: Amount to refund for the cancelation. Optional. If not
// set, Google will calculate the default based on the price and tax of
// the items involved. The amount must not be larger than the net amount
// left on the order.
AmountPretax *Price `json:"amountPretax,omitempty"`
// AmountTax: Tax amount that correspond to cancellation amount in
// amountPretax.
AmountTax *Price `json:"amountTax,omitempty"`
// LineItemId: The ID of the line item to cancel. Either lineItemId or
// productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// OperationId: The ID of the operation. Unique across all operations
// for a given order.
OperationId string `json:"operationId,omitempty"`
// ProductId: The ID of the product to cancel. This is the REST ID used
// in the products service. Either lineItemId or productId is required.
ProductId string `json:"productId,omitempty"`
// Quantity: The quantity to cancel.
Quantity int64 `json:"quantity,omitempty"`
// Reason: The reason for the cancellation.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "Amount") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Amount") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCancelLineItemRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCancelLineItemRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCancelLineItemResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersCancelLineItemResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrdersCancelLineItemResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCancelLineItemResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCancelRequest struct {
// OperationId: The ID of the operation. Unique across all operations
// for a given order.
OperationId string `json:"operationId,omitempty"`
// Reason: The reason for the cancellation.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "OperationId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "OperationId") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCancelRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCancelRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCancelResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersCancelResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrdersCancelResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCancelResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCancelTestOrderByCustomerRequest struct {
// Reason: The reason for the cancellation.
Reason string `json:"reason,omitempty"`
// ForceSendFields is a list of field names (e.g. "Reason") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Reason") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCancelTestOrderByCustomerRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCancelTestOrderByCustomerRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCancelTestOrderByCustomerResponse struct {
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersCancelTestOrderByCustomerResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Kind") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Kind") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCancelTestOrderByCustomerResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCancelTestOrderByCustomerResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCreateTestOrderRequest struct {
// Country: The CLDR territory code of the country of the test order to
// create. Affects the currency and addresses of orders created via
// template_name, or the addresses of orders created via
// test_order.
//
// Acceptable values are:
// - "US"
// - "FR" Defaults to US.
Country string `json:"country,omitempty"`
// TemplateName: The test order template to use. Specify as an
// alternative to testOrder as a shortcut for retrieving a template and
// then creating an order using that template.
TemplateName string `json:"templateName,omitempty"`
// TestOrder: The test order to create.
TestOrder *TestOrder `json:"testOrder,omitempty"`
// ForceSendFields is a list of field names (e.g. "Country") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Country") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCreateTestOrderRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCreateTestOrderRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCreateTestOrderResponse struct {
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersCreateTestOrderResponse".
Kind string `json:"kind,omitempty"`
// OrderId: The ID of the newly created test order.
OrderId string `json:"orderId,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Kind") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Kind") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCreateTestOrderResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCreateTestOrderResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCreateTestReturnRequest struct {
// Items: Returned items.
Items []*OrdersCustomBatchRequestEntryCreateTestReturnReturnItem `json:"items,omitempty"`
// ForceSendFields is a list of field names (e.g. "Items") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Items") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCreateTestReturnRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCreateTestReturnRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCreateTestReturnResponse struct {
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersCreateTestReturnResponse".
Kind string `json:"kind,omitempty"`
// ReturnId: The ID of the newly created test order return.
ReturnId string `json:"returnId,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Kind") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Kind") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCreateTestReturnResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCreateTestReturnResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequest struct {
// Entries: The request entries to be processed in the batch.
Entries []*OrdersCustomBatchRequestEntry `json:"entries,omitempty"`
// ForceSendFields is a list of field names (e.g. "Entries") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Entries") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntry struct {
// BatchId: An entry ID, unique within the batch request.
BatchId int64 `json:"batchId,omitempty"`
// Cancel: Required for cancel method.
Cancel *OrdersCustomBatchRequestEntryCancel `json:"cancel,omitempty"`
// CancelLineItem: Required for cancelLineItem method.
CancelLineItem *OrdersCustomBatchRequestEntryCancelLineItem `json:"cancelLineItem,omitempty"`
// InStoreRefundLineItem: Required for inStoreReturnLineItem method.
InStoreRefundLineItem *OrdersCustomBatchRequestEntryInStoreRefundLineItem `json:"inStoreRefundLineItem,omitempty"`
// MerchantId: The ID of the managing account.
MerchantId uint64 `json:"merchantId,omitempty,string"`
// MerchantOrderId: The merchant order id. Required for
// updateMerchantOrderId and getByMerchantOrderId methods.
MerchantOrderId string `json:"merchantOrderId,omitempty"`
// Method: The method to apply.
Method string `json:"method,omitempty"`
// OperationId: The ID of the operation. Unique across all operations
// for a given order. Required for all methods beside get and
// getByMerchantOrderId.
OperationId string `json:"operationId,omitempty"`
// OrderId: The ID of the order. Required for all methods beside
// getByMerchantOrderId.
OrderId string `json:"orderId,omitempty"`
// Refund: Required for refund method.
Refund *OrdersCustomBatchRequestEntryRefund `json:"refund,omitempty"`
// RejectReturnLineItem: Required for rejectReturnLineItem method.
RejectReturnLineItem *OrdersCustomBatchRequestEntryRejectReturnLineItem `json:"rejectReturnLineItem,omitempty"`
// ReturnLineItem: Required for returnLineItem method.
ReturnLineItem *OrdersCustomBatchRequestEntryReturnLineItem `json:"returnLineItem,omitempty"`
// ReturnRefundLineItem: Required for returnRefundLineItem method.
ReturnRefundLineItem *OrdersCustomBatchRequestEntryReturnRefundLineItem `json:"returnRefundLineItem,omitempty"`
// SetLineItemMetadata: Required for setLineItemMetadata method.
SetLineItemMetadata *OrdersCustomBatchRequestEntrySetLineItemMetadata `json:"setLineItemMetadata,omitempty"`
// ShipLineItems: Required for shipLineItems method.
ShipLineItems *OrdersCustomBatchRequestEntryShipLineItems `json:"shipLineItems,omitempty"`
// UpdateLineItemShippingDetails: Required for
// updateLineItemShippingDate method.
UpdateLineItemShippingDetails *OrdersCustomBatchRequestEntryUpdateLineItemShippingDetails `json:"updateLineItemShippingDetails,omitempty"`
// UpdateShipment: Required for updateShipment method.
UpdateShipment *OrdersCustomBatchRequestEntryUpdateShipment `json:"updateShipment,omitempty"`
// ForceSendFields is a list of field names (e.g. "BatchId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "BatchId") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntry) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntry
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryCancel struct {
// Reason: The reason for the cancellation.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "Reason") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Reason") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryCancel) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryCancel
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryCancelLineItem struct {
// Amount: Deprecated. Please use amountPretax and amountTax instead.
Amount *Price `json:"amount,omitempty"`
// AmountPretax: Amount to refund for the cancelation. Optional. If not
// set, Google will calculate the default based on the price and tax of
// the items involved. The amount must not be larger than the net amount
// left on the order.
AmountPretax *Price `json:"amountPretax,omitempty"`
// AmountTax: Tax amount that correspond to cancellation amount in
// amountPretax.
AmountTax *Price `json:"amountTax,omitempty"`
// LineItemId: The ID of the line item to cancel. Either lineItemId or
// productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// ProductId: The ID of the product to cancel. This is the REST ID used
// in the products service. Either lineItemId or productId is required.
ProductId string `json:"productId,omitempty"`
// Quantity: The quantity to cancel.
Quantity int64 `json:"quantity,omitempty"`
// Reason: The reason for the cancellation.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "Amount") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Amount") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryCancelLineItem) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryCancelLineItem
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryCreateTestReturnReturnItem struct {
// LineItemId: The ID of the line item to return.
LineItemId string `json:"lineItemId,omitempty"`
// Quantity: Quantity that is returned.
Quantity int64 `json:"quantity,omitempty"`
// ForceSendFields is a list of field names (e.g. "LineItemId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "LineItemId") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryCreateTestReturnReturnItem) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryCreateTestReturnReturnItem
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryInStoreRefundLineItem struct {
// AmountPretax: The amount that is refunded. Required.
AmountPretax *Price `json:"amountPretax,omitempty"`
// AmountTax: Tax amount that correspond to refund amount in
// amountPretax. Required.
AmountTax *Price `json:"amountTax,omitempty"`
// LineItemId: The ID of the line item to return. Either lineItemId or
// productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// ProductId: The ID of the product to return. This is the REST ID used
// in the products service. Either lineItemId or productId is required.
ProductId string `json:"productId,omitempty"`
// Quantity: The quantity to return and refund.
Quantity int64 `json:"quantity,omitempty"`
// Reason: The reason for the return.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "AmountPretax") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "AmountPretax") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryInStoreRefundLineItem) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryInStoreRefundLineItem
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryRefund struct {
// Amount: Deprecated. Please use amountPretax and amountTax instead.
Amount *Price `json:"amount,omitempty"`
// AmountPretax: The amount that is refunded. Either amount or
// amountPretax and amountTax should be filled.
AmountPretax *Price `json:"amountPretax,omitempty"`
// AmountTax: Tax amount that correspond to refund amount in
// amountPretax.
AmountTax *Price `json:"amountTax,omitempty"`
// Reason: The reason for the refund.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "Amount") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Amount") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryRefund) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryRefund
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryRejectReturnLineItem struct {
// LineItemId: The ID of the line item to return. Either lineItemId or
// productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// ProductId: The ID of the product to return. This is the REST ID used
// in the products service. Either lineItemId or productId is required.
ProductId string `json:"productId,omitempty"`
// Quantity: The quantity to return and refund.
Quantity int64 `json:"quantity,omitempty"`
// Reason: The reason for the return.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "LineItemId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "LineItemId") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryRejectReturnLineItem) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryRejectReturnLineItem
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryReturnLineItem struct {
// LineItemId: The ID of the line item to return. Either lineItemId or
// productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// ProductId: The ID of the product to return. This is the REST ID used
// in the products service. Either lineItemId or productId is required.
ProductId string `json:"productId,omitempty"`
// Quantity: The quantity to return.
Quantity int64 `json:"quantity,omitempty"`
// Reason: The reason for the return.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "LineItemId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "LineItemId") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryReturnLineItem) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryReturnLineItem
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryReturnRefundLineItem struct {
// AmountPretax: The amount that is refunded. If omitted, refundless
// return is assumed (same as calling returnLineItem method). Optional,
// but if filled then both amountPretax and amountTax must be set.
AmountPretax *Price `json:"amountPretax,omitempty"`
// AmountTax: Tax amount that correspond to refund amount in
// amountPretax.
AmountTax *Price `json:"amountTax,omitempty"`
// LineItemId: The ID of the line item to return. Either lineItemId or
// productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// ProductId: The ID of the product to return. This is the REST ID used
// in the products service. Either lineItemId or productId is required.
ProductId string `json:"productId,omitempty"`
// Quantity: The quantity to return and refund.
Quantity int64 `json:"quantity,omitempty"`
// Reason: The reason for the return.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "AmountPretax") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "AmountPretax") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryReturnRefundLineItem) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryReturnRefundLineItem
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntrySetLineItemMetadata struct {
Annotations []*OrderMerchantProvidedAnnotation `json:"annotations,omitempty"`
// LineItemId: The ID of the line item to set metadata. Either
// lineItemId or productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// ProductId: The ID of the product to set metadata. This is the REST ID
// used in the products service. Either lineItemId or productId is
// required.
ProductId string `json:"productId,omitempty"`
// ForceSendFields is a list of field names (e.g. "Annotations") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Annotations") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntrySetLineItemMetadata) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntrySetLineItemMetadata
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryShipLineItems struct {
// Carrier: Deprecated. Please use shipmentInfo instead. The carrier
// handling the shipment. See shipments[].carrier in the Orders
// resource representation for a list of acceptable values.
Carrier string `json:"carrier,omitempty"`
// LineItems: Line items to ship.
LineItems []*OrderShipmentLineItemShipment `json:"lineItems,omitempty"`
// ShipmentGroupId: ID of the shipment group. Required for orders that
// use the orderinvoices service.
ShipmentGroupId string `json:"shipmentGroupId,omitempty"`
// ShipmentId: Deprecated. Please use shipmentInfo instead. The ID of
// the shipment.
ShipmentId string `json:"shipmentId,omitempty"`
// ShipmentInfos: Shipment information. This field is repeated because a
// single line item can be shipped in several packages (and have several
// tracking IDs).
ShipmentInfos []*OrdersCustomBatchRequestEntryShipLineItemsShipmentInfo `json:"shipmentInfos,omitempty"`
// TrackingId: Deprecated. Please use shipmentInfo instead. The tracking
// id for the shipment.
TrackingId string `json:"trackingId,omitempty"`
// ForceSendFields is a list of field names (e.g. "Carrier") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Carrier") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryShipLineItems) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryShipLineItems
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryShipLineItemsShipmentInfo struct {
// Carrier: The carrier handling the shipment. See shipments[].carrier
// in the Orders resource representation for a list of acceptable
// values.
Carrier string `json:"carrier,omitempty"`
// ShipmentId: The ID of the shipment.
ShipmentId string `json:"shipmentId,omitempty"`
// TrackingId: The tracking id for the shipment.
TrackingId string `json:"trackingId,omitempty"`
// ForceSendFields is a list of field names (e.g. "Carrier") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Carrier") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryShipLineItemsShipmentInfo) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryShipLineItemsShipmentInfo
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryUpdateLineItemShippingDetails struct {
// DeliverByDate: Updated delivery by date, in ISO 8601 format. If not
// specified only ship by date is updated.
DeliverByDate string `json:"deliverByDate,omitempty"`
// LineItemId: The ID of the line item to set metadata. Either
// lineItemId or productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// ProductId: The ID of the product to set metadata. This is the REST ID
// used in the products service. Either lineItemId or productId is
// required.
ProductId string `json:"productId,omitempty"`
// ShipByDate: Updated ship by date, in ISO 8601 format. If not
// specified only deliver by date is updated.
ShipByDate string `json:"shipByDate,omitempty"`
// ForceSendFields is a list of field names (e.g. "DeliverByDate") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "DeliverByDate") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryUpdateLineItemShippingDetails) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryUpdateLineItemShippingDetails
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchRequestEntryUpdateShipment struct {
// Carrier: The carrier handling the shipment. Not updated if missing.
// See shipments[].carrier in the Orders resource representation for a
// list of acceptable values.
Carrier string `json:"carrier,omitempty"`
// DeliveryDate: Date on which the shipment has been delivered, in ISO
// 8601 format. Optional and can be provided only if status is
// delivered.
DeliveryDate string `json:"deliveryDate,omitempty"`
// ShipmentId: The ID of the shipment.
ShipmentId string `json:"shipmentId,omitempty"`
// Status: New status for the shipment. Not updated if missing.
Status string `json:"status,omitempty"`
// TrackingId: The tracking id for the shipment. Not updated if missing.
TrackingId string `json:"trackingId,omitempty"`
// ForceSendFields is a list of field names (e.g. "Carrier") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Carrier") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchRequestEntryUpdateShipment) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchRequestEntryUpdateShipment
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchResponse struct {
// Entries: The result of the execution of the batch requests.
Entries []*OrdersCustomBatchResponseEntry `json:"entries,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersCustomBatchResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Entries") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Entries") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersCustomBatchResponseEntry struct {
// BatchId: The ID of the request entry this entry responds to.
BatchId int64 `json:"batchId,omitempty"`
// Errors: A list of errors defined if and only if the request failed.
Errors *Errors `json:"errors,omitempty"`
// ExecutionStatus: The status of the execution. Only defined if
// - the request was successful; and
// - the method is not get, getByMerchantOrderId, or one of the test
// methods.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersCustomBatchResponseEntry".
Kind string `json:"kind,omitempty"`
// Order: The retrieved order. Only defined if the method is get and if
// the request was successful.
Order *Order `json:"order,omitempty"`
// ForceSendFields is a list of field names (e.g. "BatchId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "BatchId") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersCustomBatchResponseEntry) MarshalJSON() ([]byte, error) {
type NoMethod OrdersCustomBatchResponseEntry
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersGetByMerchantOrderIdResponse struct {
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersGetByMerchantOrderIdResponse".
Kind string `json:"kind,omitempty"`
// Order: The requested order.
Order *Order `json:"order,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Kind") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Kind") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersGetByMerchantOrderIdResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersGetByMerchantOrderIdResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersGetTestOrderTemplateResponse struct {
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersGetTestOrderTemplateResponse".
Kind string `json:"kind,omitempty"`
// Template: The requested test order template.
Template *TestOrder `json:"template,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Kind") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Kind") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersGetTestOrderTemplateResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersGetTestOrderTemplateResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersInStoreRefundLineItemRequest struct {
// AmountPretax: The amount that is refunded. Required.
AmountPretax *Price `json:"amountPretax,omitempty"`
// AmountTax: Tax amount that correspond to refund amount in
// amountPretax. Required.
AmountTax *Price `json:"amountTax,omitempty"`
// LineItemId: The ID of the line item to return. Either lineItemId or
// productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// OperationId: The ID of the operation. Unique across all operations
// for a given order.
OperationId string `json:"operationId,omitempty"`
// ProductId: The ID of the product to return. This is the REST ID used
// in the products service. Either lineItemId or productId is required.
ProductId string `json:"productId,omitempty"`
// Quantity: The quantity to return and refund.
Quantity int64 `json:"quantity,omitempty"`
// Reason: The reason for the return.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "AmountPretax") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "AmountPretax") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersInStoreRefundLineItemRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrdersInStoreRefundLineItemRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersInStoreRefundLineItemResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersInStoreRefundLineItemResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrdersInStoreRefundLineItemResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersInStoreRefundLineItemResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersListResponse struct {
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersListResponse".
Kind string `json:"kind,omitempty"`
// NextPageToken: The token for the retrieval of the next page of
// orders.
NextPageToken string `json:"nextPageToken,omitempty"`
Resources []*Order `json:"resources,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Kind") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Kind") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersListResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersListResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersRefundRequest struct {
// Amount: Deprecated. Please use amountPretax and amountTax instead.
Amount *Price `json:"amount,omitempty"`
// AmountPretax: The amount that is refunded. Either amount or
// amountPretax and amountTax should be filled.
AmountPretax *Price `json:"amountPretax,omitempty"`
// AmountTax: Tax amount that correspond to refund amount in
// amountPretax.
AmountTax *Price `json:"amountTax,omitempty"`
// OperationId: The ID of the operation. Unique across all operations
// for a given order.
OperationId string `json:"operationId,omitempty"`
// Reason: The reason for the refund.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "Amount") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Amount") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersRefundRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrdersRefundRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersRefundResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersRefundResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrdersRefundResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersRefundResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersRejectReturnLineItemRequest struct {
// LineItemId: The ID of the line item to return. Either lineItemId or
// productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// OperationId: The ID of the operation. Unique across all operations
// for a given order.
OperationId string `json:"operationId,omitempty"`
// ProductId: The ID of the product to return. This is the REST ID used
// in the products service. Either lineItemId or productId is required.
ProductId string `json:"productId,omitempty"`
// Quantity: The quantity to return and refund.
Quantity int64 `json:"quantity,omitempty"`
// Reason: The reason for the return.
Reason string `json:"reason,omitempty"`
// ReasonText: The explanation of the reason.
ReasonText string `json:"reasonText,omitempty"`
// ForceSendFields is a list of field names (e.g. "LineItemId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "LineItemId") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *OrdersRejectReturnLineItemRequest) MarshalJSON() ([]byte, error) {
type NoMethod OrdersRejectReturnLineItemRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersRejectReturnLineItemResponse struct {
// ExecutionStatus: The status of the execution.
ExecutionStatus string `json:"executionStatus,omitempty"`
// Kind: Identifies what kind of resource this is. Value: the fixed
// string "content#ordersRejectReturnLineItemResponse".
Kind string `json:"kind,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ExecutionStatus") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExecutionStatus") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *OrdersRejectReturnLineItemResponse) MarshalJSON() ([]byte, error) {
type NoMethod OrdersRejectReturnLineItemResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
type OrdersReturnLineItemRequest struct {
// LineItemId: The ID of the line item to return. Either lineItemId or
// productId is required.
LineItemId string `json:"lineItemId,omitempty"`
// OperationId: The ID of the operation. Unique across all operations
// for a given order.
OperationId string `json:"operationId,omitempty"`
// ProductId: The ID of the product to return. This is the REST ID used
</