platform

package
v0.0.0-...-e2bdc13 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 12, 2023 License: MIT Imports: 16 Imported by: 0

Documentation ¶

Index ¶

Constants ¶

View Source
const Version = "1.3.0"

Version identifies the current library version. Should match the git tag

Variables ¶

View Source
var ErrNotFound = errors.New("resource not found")

Functions ¶

func GetUserAgent ¶

func GetUserAgent() string

Types ¶

type AWSLambdaDestination ¶

type AWSLambdaDestination struct {
	// Amazon Resource Name (ARN) of the Lambda function in the format `arn:aws:lambda:<region>:<accountid>:function:<functionName>`. Use the format `arn:aws:lambda:<region>:<accountid>:function:<functionName>:<functionAlias/version>` to point to a specific version of the function.
	Arn string `json:"arn"`
	// Partially hidden on retrieval for security reasons.
	AccessKey string `json:"accessKey"`
	// Partially hidden on retrieval for security reasons.
	AccessSecret string `json:"accessSecret"`
}

* * We recommend creating an Identify and Access Management (IAM) user with an `accessKey` and `accessSecret` pair, specifically for each Extension that only has the `lambda:InvokeFunction` permission on this function. *

func (AWSLambdaDestination) MarshalJSON ¶

func (obj AWSLambdaDestination) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type Address ¶

type Address struct {
	// Unique identifier of the Address.
	//
	// It is not recommended to set it manually since the API overwrites this ID when creating an Address for a [Customer](ctp:api:type:Customer).
	// Use `key` instead and omit this field from the request to let the API generate the ID for the Address.
	ID *string `json:"id,omitempty"`
	// User-defined identifier of the Address that must be unique when multiple addresses are referenced in [BusinessUnits](ctp:api:type:BusinessUnit), [Customers](ctp:api:type:Customer), and `itemShippingAddresses` (LineItem-specific addresses) of a [Cart](ctp:api:type:Cart), [Order](ctp:api:type:Order), [QuoteRequest](ctp:api:type:QuoteRequest), or [Quote](ctp:api:type:Quote).
	Key *string `json:"key,omitempty"`
	// Name of the country.
	Country string `json:"country"`
	// Title of the contact, for example 'Dr.'
	Title *string `json:"title,omitempty"`
	// Salutation of the contact, for example 'Mr.' or 'Ms.'
	Salutation *string `json:"salutation,omitempty"`
	// Given name (first name) of the contact.
	FirstName *string `json:"firstName,omitempty"`
	// Family name (last name) of the contact.
	LastName *string `json:"lastName,omitempty"`
	// Name of the street.
	StreetName *string `json:"streetName,omitempty"`
	// Street number.
	StreetNumber *string `json:"streetNumber,omitempty"`
	// Further information on the street address.
	AdditionalStreetInfo *string `json:"additionalStreetInfo,omitempty"`
	// Postal code.
	PostalCode *string `json:"postalCode,omitempty"`
	// Name of the city.
	City *string `json:"city,omitempty"`
	// Name of the region.
	Region *string `json:"region,omitempty"`
	// Name of the state, for example, Colorado.
	State *string `json:"state,omitempty"`
	// Name of the company.
	Company *string `json:"company,omitempty"`
	// Name of the department.
	Department *string `json:"department,omitempty"`
	// Number or name of the building.
	Building *string `json:"building,omitempty"`
	// Number or name of the apartment.
	Apartment *string `json:"apartment,omitempty"`
	// Post office box number.
	POBox *string `json:"pOBox,omitempty"`
	// Phone number of the contact.
	Phone *string `json:"phone,omitempty"`
	// Mobile phone number of the contact.
	Mobile *string `json:"mobile,omitempty"`
	// Email address of the contact.
	Email *string `json:"email,omitempty"`
	// Fax number of the contact.
	Fax *string `json:"fax,omitempty"`
	// Further information on the Address.
	AdditionalAddressInfo *string `json:"additionalAddressInfo,omitempty"`
	// ID for the contact used in an external system.
	ExternalId *string `json:"externalId,omitempty"`
	// Custom Fields defined for the Address.
	Custom *CustomFields `json:"custom,omitempty"`
}

* * Address type returned by read methods. * Optionally, the `custom` field can be present in addition to the fields of a BaseAddress(ctp:api:type:BaseAddress). *

type AddressDraft ¶

type AddressDraft struct {
	// Unique identifier of the Address.
	//
	// It is not recommended to set it manually since the API overwrites this ID when creating an Address for a [Customer](ctp:api:type:Customer).
	// Use `key` instead and omit this field from the request to let the API generate the ID for the Address.
	ID *string `json:"id,omitempty"`
	// User-defined identifier of the Address that must be unique when multiple addresses are referenced in [BusinessUnits](ctp:api:type:BusinessUnit), [Customers](ctp:api:type:Customer), and `itemShippingAddresses` (LineItem-specific addresses) of a [Cart](ctp:api:type:Cart), [Order](ctp:api:type:Order), [QuoteRequest](ctp:api:type:QuoteRequest), or [Quote](ctp:api:type:Quote).
	Key *string `json:"key,omitempty"`
	// Name of the country.
	Country string `json:"country"`
	// Title of the contact, for example 'Dr.'
	Title *string `json:"title,omitempty"`
	// Salutation of the contact, for example 'Mr.' or 'Ms.'
	Salutation *string `json:"salutation,omitempty"`
	// Given name (first name) of the contact.
	FirstName *string `json:"firstName,omitempty"`
	// Family name (last name) of the contact.
	LastName *string `json:"lastName,omitempty"`
	// Name of the street.
	StreetName *string `json:"streetName,omitempty"`
	// Street number.
	StreetNumber *string `json:"streetNumber,omitempty"`
	// Further information on the street address.
	AdditionalStreetInfo *string `json:"additionalStreetInfo,omitempty"`
	// Postal code.
	PostalCode *string `json:"postalCode,omitempty"`
	// Name of the city.
	City *string `json:"city,omitempty"`
	// Name of the region.
	Region *string `json:"region,omitempty"`
	// Name of the state, for example, Colorado.
	State *string `json:"state,omitempty"`
	// Name of the company.
	Company *string `json:"company,omitempty"`
	// Name of the department.
	Department *string `json:"department,omitempty"`
	// Number or name of the building.
	Building *string `json:"building,omitempty"`
	// Number or name of the apartment.
	Apartment *string `json:"apartment,omitempty"`
	// Post office box number.
	POBox *string `json:"pOBox,omitempty"`
	// Phone number of the contact.
	Phone *string `json:"phone,omitempty"`
	// Mobile phone number of the contact.
	Mobile *string `json:"mobile,omitempty"`
	// Email address of the contact.
	Email *string `json:"email,omitempty"`
	// Fax number of the contact.
	Fax *string `json:"fax,omitempty"`
	// Further information on the Address.
	AdditionalAddressInfo *string `json:"additionalAddressInfo,omitempty"`
	// ID for the contact used in an external system.
	ExternalId *string `json:"externalId,omitempty"`
	// Custom Fields defined for the Address.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * Address type to be used on write methods. * Optionally, use the `custom` field in addition to the fields of a BaseAddress(ctp:api:type:BaseAddress). *

type AnonymousCartSignInMode ¶

type AnonymousCartSignInMode string
const (
	AnonymousCartSignInModeMergeWithExistingCustomerCart AnonymousCartSignInMode = "MergeWithExistingCustomerCart"
	AnonymousCartSignInModeUseAsNewActiveCustomerCart    AnonymousCartSignInMode = "UseAsNewActiveCustomerCart"
)

type AnonymousIdAlreadyInUseError ¶

type AnonymousIdAlreadyInUseError struct {
	// `"The given anonymous ID is already in use."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the anonymous ID is being used by another resource. * * The client application should choose another anonymous ID or retrieve an automatically generated one. *

func (*AnonymousIdAlreadyInUseError) DecodeStruct ¶

func (obj *AnonymousIdAlreadyInUseError) DecodeStruct(src map[string]interface{}) error

func (AnonymousIdAlreadyInUseError) Error ¶

func (AnonymousIdAlreadyInUseError) MarshalJSON ¶

func (obj AnonymousIdAlreadyInUseError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AnonymousIdAlreadyInUseError) UnmarshalJSON ¶

func (obj *AnonymousIdAlreadyInUseError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ApiClient ¶

type ApiClient struct {
	// The OAuth2 `client_id` that can be used to [obtain an access token](/../api/authorization#requesting-an-access-token-using-the-composable-commerce-oauth-20-service).
	ID string `json:"id"`
	// Name of the APIClient.
	Name string `json:"name"`
	// Whitespace-separated list of [OAuth scopes](/../api/scopes) that can be used when [obtaining an access token](/../api/authorization#requesting-an-access-token-using-the-composable-commerce-oauth-20-service).
	Scope string `json:"scope"`
	// Only shown once in the response of creating the APIClient.
	// This is the OAuth2 `client_secret` that can be used to [obtain an access token](/../api/authorization#requesting-an-access-token-using-the-composable-commerce-oauth-20-service).
	Secret *string `json:"secret,omitempty"`
	// Date of the last day this APIClient was used to [obtain an access token](/../api/authorization#requesting-an-access-token-using-the-composable-commerce-oauth-20-service).
	LastUsedAt *Date `json:"lastUsedAt,omitempty"`
	// If set, the Client will be deleted on (or shortly after) this point in time.
	DeleteAt *time.Time `json:"deleteAt,omitempty"`
	// Date and time (UTC) the APIClient was initially created at.
	CreatedAt *time.Time `json:"createdAt,omitempty"`
	// Expiration time in seconds for each access token obtained by the APIClient. Only present when set with the [APIClientDraft](ctp:api:type:ApiClientDraft). If not present the default value applies.
	AccessTokenValiditySeconds *int `json:"accessTokenValiditySeconds,omitempty"`
	// Inactivity expiration time in seconds for each refresh token obtained by the APIClient. Only present when set with the [APIClientDraft](ctp:api:type:ApiClientDraft). If not present the default value applies.
	RefreshTokenValiditySeconds *int `json:"refreshTokenValiditySeconds,omitempty"`
}

type ApiClientDraft ¶

type ApiClientDraft struct {
	// Name of the APIClient.
	Name string `json:"name"`
	// Whitespace-separated list of [OAuth scopes](/../api/scopes) that can be used when [obtaining an access token](/../api/authorization#requesting-an-access-token-using-the-composable-commerce-oauth-20-service).
	Scope string `json:"scope"`
	// If set, the Client will be deleted after the specified amount of days.
	DeleteDaysAfterCreation *int `json:"deleteDaysAfterCreation,omitempty"`
	// Expiration time in seconds for each access token obtained by the APIClient. If not set the default value applies.
	AccessTokenValiditySeconds *int `json:"accessTokenValiditySeconds,omitempty"`
	// Inactivity expiration time in seconds for each refresh token obtained by the APIClient. The expiration time for refresh tokens is restarted each time the token is used. If not set the default value applies.
	RefreshTokenValiditySeconds *int `json:"refreshTokenValiditySeconds,omitempty"`
}

type ApiClientPagedQueryResponse ¶

type ApiClientPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// APIClients matching the query.
	Results []ApiClient `json:"results"`
}

* * [PagedQueryResult](/general-concepts#pagedqueryresult) with `results` containing an array of [APIClient](ctp:api:type:ApiClient). *

type Asset ¶

type Asset struct {
	// Unique identifier of the Asset.
	ID      string        `json:"id"`
	Sources []AssetSource `json:"sources"`
	// Name of the Asset.
	Name LocalizedString `json:"name"`
	// Description of the Asset.
	Description *LocalizedString `json:"description,omitempty"`
	// Keywords for categorizing and organizing Assets.
	Tags []string `json:"tags"`
	// Custom Fields defined for the Asset.
	Custom *CustomFields `json:"custom,omitempty"`
	// User-defined unique identifier of the Asset.
	Key *string `json:"key,omitempty"`
}

func (Asset) MarshalJSON ¶

func (obj Asset) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssetDimensions ¶

type AssetDimensions struct {
	// Width of the Asset source.
	W int `json:"w"`
	// Height of the Asset source.
	H int `json:"h"`
}

* * Dimensions of the Asset source specified by the number of pixels. *

type AssetDraft ¶

type AssetDraft struct {
	Sources []AssetSource `json:"sources"`
	// Name of the Asset.
	Name LocalizedString `json:"name"`
	// Description of the Asset.
	Description *LocalizedString `json:"description,omitempty"`
	// Keywords for categorizing and organizing Assets.
	Tags []string `json:"tags"`
	// Custom Fields defined for the Asset.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// User-defined unique identifier for the Asset.
	Key *string `json:"key,omitempty"`
}

func (AssetDraft) MarshalJSON ¶

func (obj AssetDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssetSource ¶

type AssetSource struct {
	// URI of the AssetSource.
	Uri string `json:"uri"`
	// User-defined unique identifier of the AssetSource.
	Key *string `json:"key,omitempty"`
	// Width and height of the AssetSource.
	Dimensions *AssetDimensions `json:"dimensions,omitempty"`
	// Indicates the type of content, for example `application/pdf`.
	ContentType *string `json:"contentType,omitempty"`
}

* * Representation of an Asset(#asset) in a specific format, for example a video in a certain encoding, or an image in a certain resolution. *

type AssignedProductReference ¶

type AssignedProductReference struct {
	// Reference to a Product that is assigned to the Product Selection.
	Product ProductReference `json:"product"`
	// The Variants of the Product that are included from the Product Selection.
	//
	// This field may exist only in Product Selections with `Individual` [ProductSelectionMode](ctp:api:type:ProductSelectionMode).
	// In absence of this field, all Variants are deemed to be included.
	VariantSelection ProductVariantSelection `json:"variantSelection,omitempty"`
	// The Variants of the Product that are excluded from the Product Selection.
	//
	// This field may exist only in Product Selections with `IndividualExclusion` [ProductSelectionMode](ctp:api:type:ProductSelectionMode).
	// In absence of this field, all Variants are deemed to be excluded.
	VariantExclusion *ProductVariantExclusion `json:"variantExclusion,omitempty"`
}

func (*AssignedProductReference) UnmarshalJSON ¶

func (obj *AssignedProductReference) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AssignedProductSelection ¶

type AssignedProductSelection struct {
	// Reference to the Product Selection that this assignment is part of.
	ProductSelection ProductSelectionReference `json:"productSelection"`
	// Defines which Variants of the Product will be included in the Product Selection.
	//
	// This field is only available for assignments to a Product Selection with `Individual` [ProductSelectionMode](ctp:api:type:ProductSelectionMode).
	VariantSelection ProductVariantSelection `json:"variantSelection,omitempty"`
	// Defines which Variants of the Product will be excluded from the Product Selection.
	//
	// This field is only available for assignments to a Product Selection with `IndividualExclusion` [ProductSelectionMode](ctp:api:type:ProductSelectionMode).
	VariantExclusion *ProductVariantExclusion `json:"variantExclusion,omitempty"`
	// Date and time (UTC) this assignment was initially created.
	CreatedAt time.Time `json:"createdAt"`
}

func (*AssignedProductSelection) UnmarshalJSON ¶

func (obj *AssignedProductSelection) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AssignedProductSelectionPagedQueryResponse ¶

type AssignedProductSelectionPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/general-concepts#strong-consistency).
	// Unlike other endpoints, the Product Selection endpoint does not return this field by default.
	// To get `total`, pass the query parameter `withTotal` set to `true`.
	// When the results are filtered with a [Query Predicate](/predicates/query), `total` is subject to a [limit](/limits#queries).
	Total *int `json:"total,omitempty"`
	// References to ProductSelection that are assigned to the Product.
	Results []AssignedProductSelection `json:"results"`
}

* * [PagedQueryResult](/general-concepts#pagedqueryresult) containing an array of AssignedProductSelection(ctp:api:type:AssignedProductSelection). *

type Associate ¶

type Associate struct {
	// Roles assigned to the Associate within a Business Unit.
	AssociateRoleAssignments []AssociateRoleAssignment `json:"associateRoleAssignments"`
	// Deprecated type. Use `associateRoleAssignment` instead.
	Roles []AssociateRoleDeprecated `json:"roles"`
	// The [Customer](ctp:api:type:Customer) that acts as an Associate in the Business Unit.
	Customer CustomerReference `json:"customer"`
}

type AssociateDraft ¶

type AssociateDraft struct {
	// Roles assigned to the Associate within a Business Unit.
	AssociateRoleAssignments []AssociateRoleAssignmentDraft `json:"associateRoleAssignments"`
	// Deprecated type. Use `associateRoleAssignment` instead.
	Roles []AssociateRoleDeprecated `json:"roles"`
	// The [Customer](ctp:api:type:Customer) to be part of the Business Unit.
	Customer CustomerResourceIdentifier `json:"customer"`
}

func (AssociateDraft) MarshalJSON ¶

func (obj AssociateDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateMissingPermissionError ¶

type AssociateMissingPermissionError struct {
	// - When an action is performed by an Associate: `"Associate '$idOfAssociate' has no rights to $action in business-unit '$idOrKeyOfBusinessUnit'. Needs '$requiredPermission'."`
	// - When an action is performed for another Associate, like [viewing their Cart](/projects/associate-carts#get-cart-in-businessunit): `"Associate '$idOfAssociate' has no rights to $action for customer '$idOfCustomer' in business-unit '$idOrKeyOfBusinessUnit'. Needs '$requiredPermission'."`
	// - When viewing an entity: `"Associate '$idOfAssociate' has no rights to $action in business-unit '$idOrKeyOfBusinessUnit'. Needs '$requiredViewMyPermission' or '$requiredViewOthersPermission'."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// [ResourceIdentifier](ctp:api:type:CustomerResourceIdentifier) to the [Associate](ctp:api:type:Associate) that tried to perform the action.
	Associate CustomerResourceIdentifier `json:"associate"`
	// [ResourceIdentifier](ctp:api:type:BusinessUnitResourceIdentifier) to the [BusinessUnit](ctp:api:type:BusinessUnit).
	BusinessUnit BusinessUnitResourceIdentifier `json:"businessUnit"`
	// [ResourceIdentifier](ctp:api:type:CustomerResourceIdentifier) of the [Associate](ctp:api:type:Associate) on whose behalf the action is performed.
	AssociateOnBehalf *CustomerResourceIdentifier `json:"associateOnBehalf,omitempty"`
	// The Permissions that the [Associate](ctp:api:type:Associate) performing the action lacks. At least one of these Permissions is needed.
	Permissions []Permission `json:"permissions"`
}

* * Returned when an Associate(/projects/business-units#associate) is missing a Permission(/projects/associate-roles#ctp:api:type:Permission) on a [B2B resource](/associates-overview#b2b-resources). *

func (*AssociateMissingPermissionError) DecodeStruct ¶

func (obj *AssociateMissingPermissionError) DecodeStruct(src map[string]interface{}) error

func (AssociateMissingPermissionError) Error ¶

func (AssociateMissingPermissionError) MarshalJSON ¶

func (obj AssociateMissingPermissionError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AssociateMissingPermissionError) UnmarshalJSON ¶

func (obj *AssociateMissingPermissionError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AssociateRole ¶

type AssociateRole struct {
	// Unique identifier of the AssociateRole.
	ID string `json:"id"`
	// Current version of the AssociateRole.
	Version int `json:"version"`
	// Date and time (UTC) the AssociateRole was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the AssociateRole was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources updated after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the AssociateRole.
	Key string `json:"key"`
	// Whether the AssociateRole can be assigned to an Associate by a [buyer](/../api/associates-overview#buyer). If false, the AssociateRole can only be assigned using the [general endpoint](/../api/associates-overview#through-the-general-endpoints).
	BuyerAssignable bool `json:"buyerAssignable"`
	// Name of the AssociateRole.
	Name *string `json:"name,omitempty"`
	// List of Permissions for the AssociateRole.
	Permissions []Permission `json:"permissions"`
	// Custom Fields for the AssociateRole.
	Custom *CustomFields `json:"custom,omitempty"`
}

type AssociateRoleAddPermissionAction ¶

type AssociateRoleAddPermissionAction struct {
	// Permission to be added to the AssociateRole.
	Permission Permission `json:"permission"`
}

* * Adding a Permission to an AssociateRole(ctp:api:type:AssociateRole) generates an [AssociateRolePermissionAdded](ctp:api:type:AssociateRolePermissionAddedMessage) Message. *

func (AssociateRoleAddPermissionAction) MarshalJSON ¶

func (obj AssociateRoleAddPermissionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleAssignment ¶

type AssociateRoleAssignment struct {
	// Role the Associate holds within a Business Unit.
	AssociateRole AssociateRoleKeyReference `json:"associateRole"`
	// Determines whether the AssociateRoleAssignment can be inherited by child Business Units.
	Inheritance AssociateRoleInheritanceMode `json:"inheritance"`
}

type AssociateRoleAssignmentDraft ¶

type AssociateRoleAssignmentDraft struct {
	// Role the Associate holds within a Business Unit.
	AssociateRole AssociateRoleResourceIdentifier `json:"associateRole"`
	// Determines whether the AssociateRoleAssignment can be inherited by child Business Units.
	Inheritance *AssociateRoleInheritanceMode `json:"inheritance,omitempty"`
}

type AssociateRoleBuyerAssignableChangedMessage ¶

type AssociateRoleBuyerAssignableChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The new value of the `buyerAssignable` field of the AssociateRole.
	BuyerAssignable bool `json:"buyerAssignable"`
}

* * Generated after a successful [Change BuyerAssignable](ctp:api:type:AssociateRoleChangeBuyerAssignableAction) update action. *

func (AssociateRoleBuyerAssignableChangedMessage) MarshalJSON ¶

func (obj AssociateRoleBuyerAssignableChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AssociateRoleBuyerAssignableChangedMessage) UnmarshalJSON ¶

func (obj *AssociateRoleBuyerAssignableChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AssociateRoleBuyerAssignableChangedMessagePayload ¶

type AssociateRoleBuyerAssignableChangedMessagePayload struct {
	// The new value of the `buyerAssignable` field of the AssociateRole.
	BuyerAssignable bool `json:"buyerAssignable"`
}

* * Generated after a successful [Change BuyerAssignable](ctp:api:type:AssociateRoleChangeBuyerAssignableAction) update action. *

func (AssociateRoleBuyerAssignableChangedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleChangeBuyerAssignableAction ¶

type AssociateRoleChangeBuyerAssignableAction struct {
	// The new value of the `buyerAssignable` field of the AssociateRole.
	BuyerAssignable bool `json:"buyerAssignable"`
}

* * Changing the `buyerAssignable` value of an AssociateRole generates an [AssociateRoleBuyerAssignableChanged](ctp:api:type:AssociateRoleBuyerAssignableChangedMessage) Message. *

func (AssociateRoleChangeBuyerAssignableAction) MarshalJSON ¶

func (obj AssociateRoleChangeBuyerAssignableAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleCreatedMessage ¶

type AssociateRoleCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [AssociateRole](ctp:api:type:AssociateRole) that was created.
	AssociateRole AssociateRole `json:"associateRole"`
}

* * Generated after a successful [Create AssociateRole](/projects/associate-roles#create-associaterole) request. *

func (AssociateRoleCreatedMessage) MarshalJSON ¶

func (obj AssociateRoleCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AssociateRoleCreatedMessage) UnmarshalJSON ¶

func (obj *AssociateRoleCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AssociateRoleCreatedMessagePayload ¶

type AssociateRoleCreatedMessagePayload struct {
	// The [AssociateRole](ctp:api:type:AssociateRole) that was created.
	AssociateRole AssociateRole `json:"associateRole"`
}

* * Generated after a successful [Create AssociateRole](/projects/associate-roles#create-associaterole) request. *

func (AssociateRoleCreatedMessagePayload) MarshalJSON ¶

func (obj AssociateRoleCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleDeletedMessage ¶

type AssociateRoleDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
}

* * Generated after a successful [Delete AssociateRole](/projects/associate-roles#delete-associaterole) request. *

func (AssociateRoleDeletedMessage) MarshalJSON ¶

func (obj AssociateRoleDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AssociateRoleDeletedMessage) UnmarshalJSON ¶

func (obj *AssociateRoleDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AssociateRoleDeletedMessagePayload ¶

type AssociateRoleDeletedMessagePayload struct {
}

* * Generated after a successful [Delete AssociateRole](/projects/associate-roles#delete-associaterole) request. *

func (AssociateRoleDeletedMessagePayload) MarshalJSON ¶

func (obj AssociateRoleDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleDeprecated ¶

type AssociateRoleDeprecated string

* * Roles defining how an Associate(ctp:api:type:Associate) can interact with a Business Unit. *

const (
	AssociateRoleDeprecatedAdmin AssociateRoleDeprecated = "Admin"
	AssociateRoleDeprecatedBuyer AssociateRoleDeprecated = "Buyer"
)

type AssociateRoleDraft ¶

type AssociateRoleDraft struct {
	// User-defined unique identifier for the AssociateRole.
	Key string `json:"key"`
	// Name of the AssociateRole.
	Name *string `json:"name,omitempty"`
	// Whether the AssociateRole can be assigned to an Associate by a [buyer](/../api/associates-overview#buyer).
	BuyerAssignable *bool `json:"buyerAssignable,omitempty"`
	// List of Permissions for the AssociateRole.
	Permissions []Permission `json:"permissions"`
	// Custom Fields for the AssociateRole.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (AssociateRoleDraft) MarshalJSON ¶

func (obj AssociateRoleDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleInheritanceMode ¶

type AssociateRoleInheritanceMode string

* * Determines whether an AssociateRoleAssignment(ctp:api:type:AssociateRoleAssignment) can be inherited by child Business Units. *

const (
	AssociateRoleInheritanceModeEnabled  AssociateRoleInheritanceMode = "Enabled"
	AssociateRoleInheritanceModeDisabled AssociateRoleInheritanceMode = "Disabled"
)

type AssociateRoleKeyReference ¶

type AssociateRoleKeyReference struct {
	// Unique and immutable key of the referenced [AssociateRole](ctp:api:type:AssociateRole).
	Key string `json:"key"`
}

* * Reference(ctp:api:type:TypeReference) to an AssociateRole(ctp:api:type:AssociateRole) by its key. *

func (AssociateRoleKeyReference) MarshalJSON ¶

func (obj AssociateRoleKeyReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleNameChangedMessage ¶

type AssociateRoleNameChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Updated name of the [AssociateRole](ctp:api:type:AssociateRole).
	Name string `json:"name"`
}

* * Generated after a successful [Set Name](ctp:api:type:AssociateRoleSetNameAction) update action. *

func (AssociateRoleNameChangedMessage) MarshalJSON ¶

func (obj AssociateRoleNameChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AssociateRoleNameChangedMessage) UnmarshalJSON ¶

func (obj *AssociateRoleNameChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AssociateRoleNameChangedMessagePayload ¶

type AssociateRoleNameChangedMessagePayload struct {
	// Updated name of the [AssociateRole](ctp:api:type:AssociateRole).
	Name string `json:"name"`
}

* * Generated after a successful [Set Name](ctp:api:type:AssociateRoleSetNameAction) update action. *

func (AssociateRoleNameChangedMessagePayload) MarshalJSON ¶

func (obj AssociateRoleNameChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRolePagedQueryResponse ¶

type AssociateRolePagedQueryResponse struct {
	// Number of requested [results](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of elements [skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [AssociateRoles](ctp:api:type:AssociateRole) matching the query.
	Results []AssociateRole `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of AssociateRole(ctp:api:type:AssociateRole). *

type AssociateRolePermissionAddedMessage ¶

type AssociateRolePermissionAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The Permission that was added to the AssociateRole.
	Permission Permission `json:"permission"`
}

* * Generated after a successful [Add Permissions](ctp:api:type:AssociateRoleAddPermissionAction) update action. *

func (AssociateRolePermissionAddedMessage) MarshalJSON ¶

func (obj AssociateRolePermissionAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AssociateRolePermissionAddedMessage) UnmarshalJSON ¶

func (obj *AssociateRolePermissionAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AssociateRolePermissionAddedMessagePayload ¶

type AssociateRolePermissionAddedMessagePayload struct {
	// The Permission that was added to the AssociateRole.
	Permission Permission `json:"permission"`
}

* * Generated after a successful [Add Permissions](ctp:api:type:AssociateRoleAddPermissionAction) update action. *

func (AssociateRolePermissionAddedMessagePayload) MarshalJSON ¶

func (obj AssociateRolePermissionAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRolePermissionRemovedMessage ¶

type AssociateRolePermissionRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The Permission that was removed from the AssociateRole.
	Permission Permission `json:"permission"`
}

* * Generated after a successful [Remove Permissions](ctp:api:type:AssociateRoleRemovePermissionAction) update action. *

func (AssociateRolePermissionRemovedMessage) MarshalJSON ¶

func (obj AssociateRolePermissionRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AssociateRolePermissionRemovedMessage) UnmarshalJSON ¶

func (obj *AssociateRolePermissionRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AssociateRolePermissionRemovedMessagePayload ¶

type AssociateRolePermissionRemovedMessagePayload struct {
	// The Permission that was removed from the AssociateRole.
	Permission Permission `json:"permission"`
}

* * Generated after a successful [Remove Permissions](ctp:api:type:AssociateRoleRemovePermissionAction) update action. *

func (AssociateRolePermissionRemovedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRolePermissionsSetMessage ¶

type AssociateRolePermissionsSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Permission assigned to the AssociateRole.
	Permissions []Permission `json:"permissions"`
}

* * Generated after a successful [Set Permissions](ctp:api:type:AssociateRoleSetPermissionsAction) update action. *

func (AssociateRolePermissionsSetMessage) MarshalJSON ¶

func (obj AssociateRolePermissionsSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AssociateRolePermissionsSetMessage) UnmarshalJSON ¶

func (obj *AssociateRolePermissionsSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AssociateRolePermissionsSetMessagePayload ¶

type AssociateRolePermissionsSetMessagePayload struct {
	// Permission assigned to the AssociateRole.
	Permissions []Permission `json:"permissions"`
}

* * Generated after a successful [Set Permissions](ctp:api:type:AssociateRoleSetPermissionsAction) update action. *

func (AssociateRolePermissionsSetMessagePayload) MarshalJSON ¶

func (obj AssociateRolePermissionsSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleReference ¶

type AssociateRoleReference struct {
	// Unique identifier of the referenced [AssociateRole](ctp:api:type:AssociateRole).
	ID string `json:"id"`
	// Contains the representation of the expanded AssociateRole. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for AssociateRole.
	Obj *AssociateRole `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:TypeReference) to an AssociateRole(ctp:api:type:AssociateRole). *

func (AssociateRoleReference) MarshalJSON ¶

func (obj AssociateRoleReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleRemovePermissionAction ¶

type AssociateRoleRemovePermissionAction struct {
	// Permission to be removed from the AssociateRole.
	Permission Permission `json:"permission"`
}

* * Removing a Permission from an AssociateRole(ctp:api:type:AssociateRole) generates an [AssociateRolePermissionRemoved](ctp:api:type:AssociateRolePermissionRemovedMessage) Message. *

func (AssociateRoleRemovePermissionAction) MarshalJSON ¶

func (obj AssociateRoleRemovePermissionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleResourceIdentifier ¶

type AssociateRoleResourceIdentifier struct {
	// Unique identifier of the referenced [AssociateRole](ctp:api:type:AssociateRole). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// Unique key of the referenced [AssociateRole](ctp:api:type:AssociateRole). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:TypeResourceIdentifier) of an AssociateRole(ctp:api:type:AssociateRole). *

func (AssociateRoleResourceIdentifier) MarshalJSON ¶

func (obj AssociateRoleResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleSetCustomFieldAction ¶

type AssociateRoleSetCustomFieldAction struct {
	// Name of the [Custom Field](ctp:api:type:CustomFields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Trying to remove a field that does not exist will fail with an [InvalidOperationError](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (AssociateRoleSetCustomFieldAction) MarshalJSON ¶

func (obj AssociateRoleSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleSetCustomTypeAction ¶

type AssociateRoleSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the AssociateRole with [Custom Fields](ctp:api:type:CustomFields).
	// If absent, any existing Type and Custom Fields are removed from the AssociateRole.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](ctp:api:type:CustomFields) for the AssociateRole.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (AssociateRoleSetCustomTypeAction) MarshalJSON ¶

func (obj AssociateRoleSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleSetNameAction ¶

type AssociateRoleSetNameAction struct {
	// New name to set.
	// If `name` is absent or `null`, the existing name, if any, will be removed.
	Name *string `json:"name,omitempty"`
}

* * Updating the name of an AssociateRole(ctp:api:type:AssociateRole) generates an [AssociateRoleNameSet](ctp:api:type:AssociateRoleNameSetMessage) Message. *

func (AssociateRoleSetNameAction) MarshalJSON ¶

func (obj AssociateRoleSetNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleSetPermissionsAction ¶

type AssociateRoleSetPermissionsAction struct {
	// Overrides the current list of Permissions for the AssociateRole.
	Permissions []Permission `json:"permissions"`
}

* * Updating the Permissions on an AssociateRole(ctp:api:type:AssociateRole) generates an [AssociateRolePermissionsSet](ctp:api:type:AssociateRolePermissionsSetMessage) Message. *

func (AssociateRoleSetPermissionsAction) MarshalJSON ¶

func (obj AssociateRoleSetPermissionsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AssociateRoleUpdate ¶

type AssociateRoleUpdate struct {
	// Expected version of the AssociateRole on which the changes should be applied.
	// If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the AssociateRole.
	Actions []AssociateRoleUpdateAction `json:"actions"`
}

func (*AssociateRoleUpdate) UnmarshalJSON ¶

func (obj *AssociateRoleUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AssociateRoleUpdateAction ¶

type AssociateRoleUpdateAction interface{}

type Attribute ¶

type Attribute struct {
	// Name of the Attribute.
	Name string `json:"name"`
	// The [AttributeType](ctp:api:type:AttributeType) determines the format of the Attribute `value` to be provided:
	//
	// - For [Enum Type](ctp:api:type:AttributeEnumType) and [Localized Enum Type](ctp:api:type:AttributeLocalizedEnumType),
	//   use the `key` of the [Plain Enum Value](ctp:api:type:AttributePlainEnumValue) or [Localized Enum Value](ctp:api:type:AttributeLocalizedEnumValue) objects,
	//   or the complete objects as `value`.
	// - For [Localizable Text Type](ctp:api:type:AttributeLocalizableTextType), use the [LocalizedString](ctp:api:type:LocalizedString) object as `value`.
	// - For [Money Type](ctp:api:type:AttributeMoneyType) Attributes, use the [Money](ctp:api:type:Money) object as `value`.
	// - For [Set Type](ctp:api:type:AttributeSetType) Attributes, use the entire `set` object  as `value`.
	// - For [Nested Type](ctp:api:type:AttributeNestedType) Attributes, use the list of values of all Attributes of the nested Product as `value`.
	// - For [Reference Type](ctp:api:type:AttributeReferenceType) Attributes, use the [Reference](ctp:api:type:Reference) object as `value`.
	Value interface{} `json:"value"`
}

type AttributeBooleanType ¶

type AttributeBooleanType struct {
}

* * Attribute type for Boolean values. Valid values for the Attribute are `true` and `false` (JSON Boolean). *

func (AttributeBooleanType) MarshalJSON ¶

func (obj AttributeBooleanType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeConstraintEnum ¶

type AttributeConstraintEnum string

* * Specifies how an Attribute (or a set of Attributes) should be validated across all variants of a Product: *

const (
	AttributeConstraintEnumNone              AttributeConstraintEnum = "None"
	AttributeConstraintEnumUnique            AttributeConstraintEnum = "Unique"
	AttributeConstraintEnumCombinationUnique AttributeConstraintEnum = "CombinationUnique"
	AttributeConstraintEnumSameForAll        AttributeConstraintEnum = "SameForAll"
)

type AttributeConstraintEnumDraft ¶

type AttributeConstraintEnumDraft string
const (
	AttributeConstraintEnumDraftNone AttributeConstraintEnumDraft = "None"
)

type AttributeDateTimeType ¶

type AttributeDateTimeType struct {
}

func (AttributeDateTimeType) MarshalJSON ¶

func (obj AttributeDateTimeType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeDateType ¶

type AttributeDateType struct {
}

func (AttributeDateType) MarshalJSON ¶

func (obj AttributeDateType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeDefinition ¶

type AttributeDefinition struct {
	// Describes the Type of the Attribute.
	Type AttributeType `json:"type"`
	// User-defined name of the Attribute that is unique within the [Project](ctp:api:type:Project).
	Name string `json:"name"`
	// Human-readable label for the Attribute.
	Label LocalizedString `json:"label"`
	// If `true`, the Attribute must have a value on a [ProductVariant](ctp:api:type:ProductVariant).
	IsRequired bool `json:"isRequired"`
	// Specifies how Attributes are validated across all variants of a Product.
	AttributeConstraint AttributeConstraintEnum `json:"attributeConstraint"`
	// Provides additional Attribute information to aid content managers configure Product details.
	InputTip *LocalizedString `json:"inputTip,omitempty"`
	// Provides a visual representation directive for values of this Attribute (only relevant for [AttributeTextType](ctp:api:type:AttributeTextType) and [AttributeLocalizableTextType](ctp:api:type:AttributeLocalizableTextType)).
	InputHint TextInputHint `json:"inputHint"`
	// If `true`, the Attribute's values are available for the [Product Projections Search API](/../api/projects/products-search) for use in full-text search queries, filters, and facets.
	//
	// Which exact features are available with this flag depends on the specific [AttributeType](ctp:api:type:AttributeType).
	// The maximum size of a searchable field is **restricted** by the [Field content size limit](/../api/limits#field-content-size).
	// This constraint is enforced at both [Product creation](/../api/projects/products#create-product) and [Product update](/../api/projects/products#update-product).
	// If the length of the input exceeds the maximum size, an [InvalidField](ctp:api:type:InvalidFieldError) error is returned.
	IsSearchable bool `json:"isSearchable"`
}

* * Describes a Product Attribute and allows you to define meta-information associated with the Attribute (like whether it should be searchable, or its constraints). *

func (*AttributeDefinition) UnmarshalJSON ¶

func (obj *AttributeDefinition) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AttributeDefinitionAlreadyExistsError ¶

type AttributeDefinitionAlreadyExistsError struct {
	// `"An attribute definition with name $attributeName already exists on product type $productTypeName."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifier of the Product Type containing the conflicting name.
	ConflictingProductTypeId string `json:"conflictingProductTypeId"`
	// Name of the Product Type containing the conflicting name.
	ConflictingProductTypeName string `json:"conflictingProductTypeName"`
	// Name of the conflicting Attribute.
	ConflictingAttributeName string `json:"conflictingAttributeName"`
}

* * Returned when the `name` of the AttributeDefinition(ctp:api:type:AttributeDefinition) conflicts with an existing Attribute. * * The error is returned as a failed response to the [Create ProductType](/../api/projects/productTypes#create-producttype) request or [Change AttributeDefinition Name](ctp:api:type:ProductTypeChangeAttributeNameAction) update action. *

func (*AttributeDefinitionAlreadyExistsError) DecodeStruct ¶

func (obj *AttributeDefinitionAlreadyExistsError) DecodeStruct(src map[string]interface{}) error

func (AttributeDefinitionAlreadyExistsError) Error ¶

func (AttributeDefinitionAlreadyExistsError) MarshalJSON ¶

func (obj AttributeDefinitionAlreadyExistsError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AttributeDefinitionAlreadyExistsError) UnmarshalJSON ¶

func (obj *AttributeDefinitionAlreadyExistsError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AttributeDefinitionDraft ¶

type AttributeDefinitionDraft struct {
	// Describes the Type of the Attribute.
	//
	// When the `type` is different for an AttributeDefinition using the same name in multiple ProductTypes, an [AttributeDefinitionTypeConflict](ctp:api:type:AttributeDefinitionTypeConflictError) error is returned.
	Type AttributeType `json:"type"`
	// User-defined name of the Attribute that is unique with the [Project](ctp:api:type:Project).
	//
	// When using the same `name` for an Attribute in multiple ProductTypes, all fields of the AttributeDefinition of this Attribute must be the same across the ProductTypes, else an [AttributeDefinitionAlreadyExists](ctp:api:type:AttributeDefinitionAlreadyExistsError) error is returned.
	// An exception to this are the values of an `enum` or `lenum` Type and sets thereof.
	Name string `json:"name"`
	// Human-readable label for the Attribute.
	Label LocalizedString `json:"label"`
	// Set to `true` if the Attribute is required to have a value on a [ProductVariant](ctp:api:type:ProductVariant).
	IsRequired bool `json:"isRequired"`
	// Specifies how an Attribute or a combination of Attributes should be validated across all variants of a Product.
	AttributeConstraint *AttributeConstraintEnum `json:"attributeConstraint,omitempty"`
	// Provides additional information about the Attribute that aids content managers when setting Product details.
	InputTip *LocalizedString `json:"inputTip,omitempty"`
	// Provides a visual representation directive for values of this Attribute (only relevant for [AttributeTextType](ctp:api:type:AttributeTextType) and [AttributeLocalizableTextType](ctp:api:type:AttributeLocalizableTextType)).
	InputHint *TextInputHint `json:"inputHint,omitempty"`
	// Set to `true` if the Attribute's values should be available in the [Product Projections Search API](/../api/projects/products-search) and can be used in full-text search queries, filters, and facets.
	// Which exact features are available with this flag depends on the specific [AttributeType](ctp:api:type:AttributeType).
	// The maximum size of a searchable field is **restricted** by the [Field content size limit](/../api/limits#field-content-size).
	// This constraint is enforced at both Product creation and Product update.
	// If the length of the input exceeds the maximum size, an InvalidField error is returned.
	IsSearchable *bool `json:"isSearchable,omitempty"`
}

* * Specify the Attribute to be created with the ProductTypeDraft(ctp:api:type:ProductTypeDraft). *

func (*AttributeDefinitionDraft) UnmarshalJSON ¶

func (obj *AttributeDefinitionDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AttributeDefinitionTypeConflictError ¶

type AttributeDefinitionTypeConflictError struct {
	// `"The attribute with name $attributeName has a different type on product type $productTypeName."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifier of the Product Type containing the conflicting name.
	ConflictingProductTypeId string `json:"conflictingProductTypeId"`
	// Name of the Product Type containing the conflicting name.
	ConflictingProductTypeName string `json:"conflictingProductTypeName"`
	// Name of the conflicting Attribute.
	ConflictingAttributeName string `json:"conflictingAttributeName"`
}

* * Returned when the `type` is different for an AttributeDefinition using the same `name` in multiple Product Types. * * The error is returned as a failed response to the [Create ProductType](/../api/projects/productTypes#create-producttype) request. *

func (*AttributeDefinitionTypeConflictError) DecodeStruct ¶

func (obj *AttributeDefinitionTypeConflictError) DecodeStruct(src map[string]interface{}) error

func (AttributeDefinitionTypeConflictError) Error ¶

func (AttributeDefinitionTypeConflictError) MarshalJSON ¶

func (obj AttributeDefinitionTypeConflictError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AttributeDefinitionTypeConflictError) UnmarshalJSON ¶

func (obj *AttributeDefinitionTypeConflictError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AttributeEnumType ¶

type AttributeEnumType struct {
	// Available values that can be assigned to Products.
	Values []AttributePlainEnumValue `json:"values"`
}

* * Attribute type for plain enum values. Useful for predefined language-agnostic values selectable in drop downs when only one value should be selected. Use AttributeSetType(ctp:api:type:AttributeSetType) of AttributeEnumType instead if multiple values can be selected from the list. *

func (AttributeEnumType) MarshalJSON ¶

func (obj AttributeEnumType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeGroup ¶

type AttributeGroup struct {
	// Platform-generated unique identifier of the AttributeGroup.
	ID string `json:"id"`
	// Current version of the AttributeGroup.
	Version int `json:"version"`
	// Date and time (UTC) the AttributeGroup was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the AttributeGroup was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Name of the AttributeGroup.
	Name LocalizedString `json:"name"`
	// Description of the AttributeGroup.
	Description *LocalizedString `json:"description,omitempty"`
	// [Attributes](ctp:api:type:AttributeDefinition) with unique values.
	Attributes []AttributeReference `json:"attributes"`
	// User-defined unique identifier of the AttributeGroup.
	Key *string `json:"key,omitempty"`
}

type AttributeGroupAddAttributeAction ¶

type AttributeGroupAddAttributeAction struct {
	// Value to add.
	Attribute AttributeReference `json:"attribute"`
}

func (AttributeGroupAddAttributeAction) MarshalJSON ¶

func (obj AttributeGroupAddAttributeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeGroupChangeNameAction ¶

type AttributeGroupChangeNameAction struct {
	// New value to set.
	// Must not be empty.
	Name LocalizedString `json:"name"`
}

func (AttributeGroupChangeNameAction) MarshalJSON ¶

func (obj AttributeGroupChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeGroupDraft ¶

type AttributeGroupDraft struct {
	// Name of the AttributeGroup.
	Name LocalizedString `json:"name"`
	// Description of the AttributeGroup.
	Description *LocalizedString `json:"description,omitempty"`
	// [Attributes](ctp:api:type:AttributeDefinition) with unique values.
	Attributes []AttributeReference `json:"attributes"`
	// User-defined unique identifier for the AttributeGroup.
	Key *string `json:"key,omitempty"`
}

type AttributeGroupPagedQueryResponse ¶

type AttributeGroupPagedQueryResponse struct {
	// Number of results requested in the query request.
	Limit int `json:"limit"`
	// Offset supplied by the client or the server default.
	// It is the number of elements skipped, not a page number.
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [AttributeGroups](ctp:api:type:AttributeGroup) matching the query.
	Results []AttributeGroup `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of AttributeGroup(ctp:api:type:AttributeGroup). *

type AttributeGroupReference ¶

type AttributeGroupReference struct {
	// Platform-generated unique identifier of the referenced [AttributeGroup](ctp:api:type:AttributeGroup).
	ID string `json:"id"`
	// Contains the representation of the expanded AttributeGroup. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for AttributeGroup.
	Obj *AttributeGroup `json:"obj,omitempty"`
}

* * Reference(/../api/types#reference) to an AttributeGroup(ctp:api:type:AttributeGroup). *

func (AttributeGroupReference) MarshalJSON ¶

func (obj AttributeGroupReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeGroupRemoveAttributeAction ¶

type AttributeGroupRemoveAttributeAction struct {
	// Value to remove.
	Attribute AttributeReference `json:"attribute"`
}

func (AttributeGroupRemoveAttributeAction) MarshalJSON ¶

func (obj AttributeGroupRemoveAttributeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeGroupResourceIdentifier ¶

type AttributeGroupResourceIdentifier struct {
	// Platform-generated unique identifier of the referenced [AttributeGroup](ctp:api:type:AttributeGroup). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-generated unique identifier of the referenced [AttributeGroup](ctp:api:type:AttributeGroup). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(/../api/types#resourceidentifier) to an AttributeGroup(ctp:api:type:AttributeGroup). *

func (AttributeGroupResourceIdentifier) MarshalJSON ¶

func (obj AttributeGroupResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeGroupSetAttributesAction ¶

type AttributeGroupSetAttributesAction struct {
	// New unique values to set.
	Attributes []AttributeReference `json:"attributes"`
}

func (AttributeGroupSetAttributesAction) MarshalJSON ¶

func (obj AttributeGroupSetAttributesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeGroupSetDescriptionAction ¶

type AttributeGroupSetDescriptionAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

func (AttributeGroupSetDescriptionAction) MarshalJSON ¶

func (obj AttributeGroupSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeGroupSetKeyAction ¶

type AttributeGroupSetKeyAction struct {
	// If `key` is absent or `null`, the existing key, if any, will be removed.
	Key *string `json:"key,omitempty"`
}

func (AttributeGroupSetKeyAction) MarshalJSON ¶

func (obj AttributeGroupSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeGroupUpdate ¶

type AttributeGroupUpdate struct {
	// Expected version of the AttributeGroup on which the changes should be applied. If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the AttributeGroup.
	Actions []AttributeGroupUpdateAction `json:"actions"`
}

func (*AttributeGroupUpdate) UnmarshalJSON ¶

func (obj *AttributeGroupUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AttributeGroupUpdateAction ¶

type AttributeGroupUpdateAction interface{}

type AttributeLocalizableTextType ¶

type AttributeLocalizableTextType struct {
}

* * Attribute type for LocalizedString(ctp:api:type:LocalizedString) values. *

func (AttributeLocalizableTextType) MarshalJSON ¶

func (obj AttributeLocalizableTextType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeLocalizedEnumType ¶

type AttributeLocalizedEnumType struct {
	// Available values that can be assigned to Products.
	Values []AttributeLocalizedEnumValue `json:"values"`
}

* * Attribute type for localized enum values. Useful for predefined language-specific values selectable in drop-down menus if only one value can be selected. Use AttributeSetType(ctp:api:type:AttributeSetType) of AttributeLocalizedEnumValue instead if multiple values can be selected. *

func (AttributeLocalizedEnumType) MarshalJSON ¶

func (obj AttributeLocalizedEnumType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeLocalizedEnumValue ¶

type AttributeLocalizedEnumValue struct {
	// Key of the value used as a programmatic identifier, for example in facets & filters.
	Key string `json:"key"`
	// Descriptive, localized label of the value.
	Label LocalizedString `json:"label"`
}

* * A localized enum value must be unique within the enum, else a [DuplicateEnumValues](ctp:api:type:DuplicateEnumValuesError) error is returned. *

type AttributeMoneyType ¶

type AttributeMoneyType struct {
}

func (AttributeMoneyType) MarshalJSON ¶

func (obj AttributeMoneyType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeNameDoesNotExistError ¶

type AttributeNameDoesNotExistError struct {
	// `"Attribute definition for $attributeName does not exist on type $typeName."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Non-existent Attribute name.
	InvalidAttributeName string `json:"invalidAttributeName"`
}

* * Returned when an AttributeDefinition(ctp:api:type:AttributeDefinition) does not exist for an Attribute `name`. * * The error is returned as a failed response to the [Change AttributeDefinition Name](ctp:api:type:ProductTypeChangeAttributeNameAction) update action. *

func (*AttributeNameDoesNotExistError) DecodeStruct ¶

func (obj *AttributeNameDoesNotExistError) DecodeStruct(src map[string]interface{}) error

func (AttributeNameDoesNotExistError) Error ¶

func (AttributeNameDoesNotExistError) MarshalJSON ¶

func (obj AttributeNameDoesNotExistError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AttributeNameDoesNotExistError) UnmarshalJSON ¶

func (obj *AttributeNameDoesNotExistError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AttributeNestedType ¶

type AttributeNestedType struct {
	// Attributes that can be stored as nested Attributes of the current Attribute.
	TypeReference ProductTypeReference `json:"typeReference"`
}

* * Attribute type for nesting Attributes based on some existing ProductType. It does not support `isSearchable` and is not supported in queries. The only supported AttributeConstraint is `None`. *

func (AttributeNestedType) MarshalJSON ¶

func (obj AttributeNestedType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeNumberType ¶

type AttributeNumberType struct {
}

func (AttributeNumberType) MarshalJSON ¶

func (obj AttributeNumberType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributePlainEnumValue ¶

type AttributePlainEnumValue struct {
	// Key of the value used as a programmatic identifier, for example in facets & filters.
	Key string `json:"key"`
	// Descriptive label of the value.
	Label string `json:"label"`
}

* * A plain enum value must be unique within the enum, else a [DuplicateEnumValues](ctp:api:types:DuplicateEnumValuesError) error is returned. *

type AttributeReference ¶

type AttributeReference struct {
	// The Attribute's `name` as given in its [AttributeDefinition](ctp:api:type:AttributeDefinition).
	Key string `json:"key"`
}

type AttributeReferenceType ¶

type AttributeReferenceType struct {
	// Name of the resource type that the value should reference.
	ReferenceTypeId AttributeReferenceTypeId `json:"referenceTypeId"`
}

func (AttributeReferenceType) MarshalJSON ¶

func (obj AttributeReferenceType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeReferenceTypeId ¶

type AttributeReferenceTypeId string

* * Name of the resource type that the value should reference. Supported resource type identifiers: *

const (
	AttributeReferenceTypeIdCart             AttributeReferenceTypeId = "cart"
	AttributeReferenceTypeIdCategory         AttributeReferenceTypeId = "category"
	AttributeReferenceTypeIdChannel          AttributeReferenceTypeId = "channel"
	AttributeReferenceTypeIdCustomer         AttributeReferenceTypeId = "customer"
	AttributeReferenceTypeIdKeyValueDocument AttributeReferenceTypeId = "key-value-document"
	AttributeReferenceTypeIdOrder            AttributeReferenceTypeId = "order"
	AttributeReferenceTypeIdProduct          AttributeReferenceTypeId = "product"
	AttributeReferenceTypeIdProductType      AttributeReferenceTypeId = "product-type"
	AttributeReferenceTypeIdReview           AttributeReferenceTypeId = "review"
	AttributeReferenceTypeIdShippingMethod   AttributeReferenceTypeId = "shipping-method"
	AttributeReferenceTypeIdState            AttributeReferenceTypeId = "state"
	AttributeReferenceTypeIdZone             AttributeReferenceTypeId = "zone"
)

type AttributeSetType ¶

type AttributeSetType struct {
	// Attribute type of the elements in the set.
	ElementType AttributeType `json:"elementType"`
}

* * AttributeType that defines a set (without duplicate elements) with values of the given `elementType`. It does not support `isRequired`. Since this type itself is an AttributeType, it is possible to construct an AttributeSetType of an AttributeSetType of any AttributeType, and to continue with this iteration until terminating with any non-AttributeSetType. In case the AttributeSetType iteration terminates with an AttributeNestedType(ctp:api:type:AttributeNestedType), the iteration can have 5 steps at maximum. *

func (AttributeSetType) MarshalJSON ¶

func (obj AttributeSetType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AttributeSetType) UnmarshalJSON ¶

func (obj *AttributeSetType) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AttributeTextType ¶

type AttributeTextType struct {
}

* * Attribute type for plain text values. *

func (AttributeTextType) MarshalJSON ¶

func (obj AttributeTextType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeTimeType ¶

type AttributeTimeType struct {
}

func (AttributeTimeType) MarshalJSON ¶

func (obj AttributeTimeType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AttributeType ¶

type AttributeType interface{}

* * Umbrella type for specific attribute types discriminated by property `name`.

type AuthErrorResponse ¶

type AuthErrorResponse struct {
	// HTTP status code corresponding to the error.
	StatusCode int `json:"statusCode"`
	// First error message in the `errors` array.
	Message string `json:"message"`
	// Authentication and authorization-related errors returned for a request.
	Errors []ErrorObject `json:"errors"`
	// Error code as per the [OAuth 2.0 specification](https://datatracker.ietf.org/doc/html/rfc6749#section-5.2). For example: `"access_denied"`.
	ErrorMessage string `json:"error"`
	// Plain text description of the first error.
	ErrorDescription *string `json:"error_description,omitempty"`
}

* * Represents errors related to authentication and authorization in a format conforming to the [OAuth 2.0 specification](https://datatracker.ietf.org/doc/html/rfc6749#section-5.2). *

func (AuthErrorResponse) Error ¶

func (obj AuthErrorResponse) Error() string

func (*AuthErrorResponse) UnmarshalJSON ¶

func (obj *AuthErrorResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AuthenticationMode ¶

type AuthenticationMode string
const (
	AuthenticationModePassword     AuthenticationMode = "Password"
	AuthenticationModeExternalAuth AuthenticationMode = "ExternalAuth"
)

type AuthorizationHeaderAuthentication ¶

type AuthorizationHeaderAuthentication struct {
	// Partially hidden on retrieval for security reasons.
	HeaderValue string `json:"headerValue"`
}

* * The `Authorization` header will be set to the content of `headerValue`. The authentication scheme (such as `Basic` or `Bearer`) should be included in the `headerValue`. * * For example, the `headerValue` for [Basic Authentication](https://datatracker.ietf.org/doc/html/rfc7617) should be set to `Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==`. *

func (AuthorizationHeaderAuthentication) MarshalJSON ¶

func (obj AuthorizationHeaderAuthentication) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AwsAuthenticationMode ¶

type AwsAuthenticationMode string

* * Defines the method of authentication for AWS SQS and SNS Destinations.

const (
	AwsAuthenticationModeCredentials AwsAuthenticationMode = "Credentials"
	AwsAuthenticationModeIAM         AwsAuthenticationMode = "IAM"
)

type AzureEventGridDestination ¶

type AzureEventGridDestination struct {
	// URI of the topic.
	Uri string `json:"uri"`
	// Partially hidden on retrieval for security reasons.
	AccessKey string `json:"accessKey"`
}

* * [Azure Event Grid](https://azure.microsoft.com/en-us/products/event-grid/) can be used to push messages to Azure Functions, HTTP endpoints (webhooks), and several other Azure tools. Event Grid can only be used with the CloudEventsFormat(ctp:api:type:CloudEventsFormat). * To set up a Subscription with Azure Event Grid, first create a topic in the [Azure Portal](https://azure.microsoft.com/en-us/get-started/azure-portal/). To allow Composable Commerce to push messages to your topic, provide an [access key](https://docs.microsoft.com/en-us/azure/event-grid/get-access-keys). *

func (AzureEventGridDestination) MarshalJSON ¶

func (obj AzureEventGridDestination) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AzureFunctionsAuthentication ¶

type AzureFunctionsAuthentication struct {
	// Partially hidden on retrieval for security reasons.
	Key string `json:"key"`
}

* * To protect your Azure Function, set its `authLevel` to `function` and provide the function's key to be used inside the `x-functions-key` header. For more information, see the [Azure Functions documentation](https://docs.microsoft.com/en-us/azure/azure-functions/functions-bindings-http-webhook#keys). * * To protect the secret key from being exposed, remove the code parameter and secret key from the URL. For example, use `https://foo.azurewebsites.net/api/bar` instead of * `https://foo.azurewebsites.net/api/bar?code=secret`. *

func (AzureFunctionsAuthentication) MarshalJSON ¶

func (obj AzureFunctionsAuthentication) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type AzureServiceBusDestination ¶

type AzureServiceBusDestination struct {
	// SharedAccessKey is partially hidden on retrieval for security reasons.
	ConnectionString string `json:"connectionString"`
}

* * [Azure Service Bus](https://azure.microsoft.com/en-us/products/service-bus/) can be used as a pull-queue with [Queues](https://learn.microsoft.com/en-us/azure/service-bus-messaging/service-bus-queues-topics-subscriptions#queues), or to fan-out messages with [Topics and Subscriptions](https://learn.microsoft.com/en-us/azure/service-bus-messaging/service-bus-queues-topics-subscriptions). * To set up a Subscription with Azure Service Bus, first create a queue/topic in the [Azure Portal](https://azure.microsoft.com/en-us/get-started/azure-portal/) with a Shared Access Policy including the `Send` permission. *

func (AzureServiceBusDestination) MarshalJSON ¶

func (obj AzureServiceBusDestination) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BadGatewayError ¶

type BadGatewayError struct {
	// Plain text description of the error.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a server-side problem is caused by scaling infrastructure resources. * * The client application should retry the request with exponential backoff up to a point where further delay is unacceptable. *

func (*BadGatewayError) DecodeStruct ¶

func (obj *BadGatewayError) DecodeStruct(src map[string]interface{}) error

func (BadGatewayError) Error ¶

func (obj BadGatewayError) Error() string

func (BadGatewayError) MarshalJSON ¶

func (obj BadGatewayError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BadGatewayError) UnmarshalJSON ¶

func (obj *BadGatewayError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BaseAddress ¶

type BaseAddress struct {
	// Unique identifier of the Address.
	//
	// It is not recommended to set it manually since the API overwrites this ID when creating an Address for a [Customer](ctp:api:type:Customer).
	// Use `key` instead and omit this field from the request to let the API generate the ID for the Address.
	ID *string `json:"id,omitempty"`
	// User-defined identifier of the Address that must be unique when multiple addresses are referenced in [BusinessUnits](ctp:api:type:BusinessUnit), [Customers](ctp:api:type:Customer), and `itemShippingAddresses` (LineItem-specific addresses) of a [Cart](ctp:api:type:Cart), [Order](ctp:api:type:Order), [QuoteRequest](ctp:api:type:QuoteRequest), or [Quote](ctp:api:type:Quote).
	Key *string `json:"key,omitempty"`
	// Name of the country.
	Country string `json:"country"`
	// Title of the contact, for example 'Dr.'
	Title *string `json:"title,omitempty"`
	// Salutation of the contact, for example 'Mr.' or 'Ms.'
	Salutation *string `json:"salutation,omitempty"`
	// Given name (first name) of the contact.
	FirstName *string `json:"firstName,omitempty"`
	// Family name (last name) of the contact.
	LastName *string `json:"lastName,omitempty"`
	// Name of the street.
	StreetName *string `json:"streetName,omitempty"`
	// Street number.
	StreetNumber *string `json:"streetNumber,omitempty"`
	// Further information on the street address.
	AdditionalStreetInfo *string `json:"additionalStreetInfo,omitempty"`
	// Postal code.
	PostalCode *string `json:"postalCode,omitempty"`
	// Name of the city.
	City *string `json:"city,omitempty"`
	// Name of the region.
	Region *string `json:"region,omitempty"`
	// Name of the state, for example, Colorado.
	State *string `json:"state,omitempty"`
	// Name of the company.
	Company *string `json:"company,omitempty"`
	// Name of the department.
	Department *string `json:"department,omitempty"`
	// Number or name of the building.
	Building *string `json:"building,omitempty"`
	// Number or name of the apartment.
	Apartment *string `json:"apartment,omitempty"`
	// Post office box number.
	POBox *string `json:"pOBox,omitempty"`
	// Phone number of the contact.
	Phone *string `json:"phone,omitempty"`
	// Mobile phone number of the contact.
	Mobile *string `json:"mobile,omitempty"`
	// Email address of the contact.
	Email *string `json:"email,omitempty"`
	// Fax number of the contact.
	Fax *string `json:"fax,omitempty"`
	// Further information on the Address.
	AdditionalAddressInfo *string `json:"additionalAddressInfo,omitempty"`
	// ID for the contact used in an external system.
	ExternalId *string `json:"externalId,omitempty"`
}

* * Polymorphic base type that represents a postal address and contact details. * Depending on the read or write action, it can be either Address(ctp:api:type:Address) or AddressDraft(ctp:api:type:AddressDraft) that * only differ in the data type for the optional `custom` field. *

type BaseResource ¶

type BaseResource struct {
	ID             string    `json:"id"`
	Version        int       `json:"version"`
	CreatedAt      time.Time `json:"createdAt"`
	LastModifiedAt time.Time `json:"lastModifiedAt"`
}

type BusinessUnit ¶

type BusinessUnit interface{}

* * Generic type to model the fields that all types of Business Units have in common. *

type BusinessUnitAddAddressAction ¶

type BusinessUnitAddAddressAction struct {
	// Address to add to the addresses of the [Business Unit](ctp:api:type:BusinessUnit).
	Address BaseAddress `json:"address"`
}

* * Adding an address to a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitAddressAdded](ctp:api:type:BusinessUnitAddressAddedMessage) Message. *

func (BusinessUnitAddAddressAction) MarshalJSON ¶

func (obj BusinessUnitAddAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAddAssociateAction ¶

type BusinessUnitAddAssociateAction struct {
	// The Associate to add.
	Associate AssociateDraft `json:"associate"`
}

* * Adding an Associate to a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitAssociateAdded](ctp:api:type:BusinessUnitAssociateAddedMessage) Message. *

func (BusinessUnitAddAssociateAction) MarshalJSON ¶

func (obj BusinessUnitAddAssociateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAddBillingAddressIdAction ¶

type BusinessUnitAddBillingAddressIdAction struct {
	// ID of the address to add as a billing address. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to add as a billing address. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Adding a billing address to a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitBillingAddressAdded](ctp:api:type:BusinessUnitBillingAddressAddedMessage) Message. *

func (BusinessUnitAddBillingAddressIdAction) MarshalJSON ¶

func (obj BusinessUnitAddBillingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAddShippingAddressIdAction ¶

type BusinessUnitAddShippingAddressIdAction struct {
	// ID of the address to add as a shipping address. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to add as a shipping address. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Adding a shipping address to a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitShippingAddressAdded](ctp:api:type:BusinessUnitShippingAddressAddedMessage) Message. *

func (BusinessUnitAddShippingAddressIdAction) MarshalJSON ¶

func (obj BusinessUnitAddShippingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAddStoreAction ¶

type BusinessUnitAddStoreAction struct {
	// [Store](ctp:api:type:Store) to add.
	Store StoreResourceIdentifier `json:"store"`
}

* * Adding a Store(ctp:api:type:Store) to a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitStoreAdded](ctp:api:type:BusinessUnitStoreAddedMessage) Message. * Only applicable when `storeMode` is `Explicit`. *

func (BusinessUnitAddStoreAction) MarshalJSON ¶

func (obj BusinessUnitAddStoreAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAddressAddedMessage ¶

type BusinessUnitAddressAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The address that was added to the [Business Unit](ctp:api:type:BusinessUnit).
	Address Address `json:"address"`
}

* * Generated after a successful [Add Address](ctp:api:type:BusinessUnitAddAddressAction) update action. *

func (BusinessUnitAddressAddedMessage) MarshalJSON ¶

func (obj BusinessUnitAddressAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitAddressAddedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitAddressAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitAddressAddedMessagePayload ¶

type BusinessUnitAddressAddedMessagePayload struct {
	// The address that was added to the [Business Unit](ctp:api:type:BusinessUnit).
	Address Address `json:"address"`
}

* * Generated after a successful [Add Address](ctp:api:type:BusinessUnitAddAddressAction) update action. *

func (BusinessUnitAddressAddedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitAddressAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAddressChangedMessage ¶

type BusinessUnitAddressChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Updated address of the Business Unit.
	Address Address `json:"address"`
}

* * Generated after a successful [Change Address](ctp:api:type:BusinessUnitChangeAddressAction) update action. *

func (BusinessUnitAddressChangedMessage) MarshalJSON ¶

func (obj BusinessUnitAddressChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitAddressChangedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitAddressChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitAddressChangedMessagePayload ¶

type BusinessUnitAddressChangedMessagePayload struct {
	// Updated address of the Business Unit.
	Address Address `json:"address"`
}

* * Generated after a successful [Change Address](ctp:api:type:BusinessUnitChangeAddressAction) update action. *

func (BusinessUnitAddressChangedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitAddressChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAddressRemovedMessage ¶

type BusinessUnitAddressRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The address that was removed from the [Business Unit](ctp:api:type:BusinessUnit).
	Address Address `json:"address"`
}

* * Generated after a successful [Remove Address](ctp:api:type:BusinessUnitRemoveAddressAction) update action. *

func (BusinessUnitAddressRemovedMessage) MarshalJSON ¶

func (obj BusinessUnitAddressRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitAddressRemovedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitAddressRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitAddressRemovedMessagePayload ¶

type BusinessUnitAddressRemovedMessagePayload struct {
	// The address that was removed from the [Business Unit](ctp:api:type:BusinessUnit).
	Address Address `json:"address"`
}

* * Generated after a successful [Remove Address](ctp:api:type:BusinessUnitRemoveAddressAction) update action. *

func (BusinessUnitAddressRemovedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitAddressRemovedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAssociateAddedMessage ¶

type BusinessUnitAssociateAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [Associate](ctp:api:type:Associate) that was added to the [Business Unit](ctp:api:type:BusinessUnit).
	Associate Associate `json:"associate"`
}

* * Generated after a successful [Add Associate](ctp:api:type:BusinessUnitAddAssociateAction) update action. *

func (BusinessUnitAssociateAddedMessage) MarshalJSON ¶

func (obj BusinessUnitAssociateAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitAssociateAddedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitAssociateAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitAssociateAddedMessagePayload ¶

type BusinessUnitAssociateAddedMessagePayload struct {
	// The [Associate](ctp:api:type:Associate) that was added to the [Business Unit](ctp:api:type:BusinessUnit).
	Associate Associate `json:"associate"`
}

* * Generated after a successful [Add Associate](ctp:api:type:BusinessUnitAddAssociateAction) update action. *

func (BusinessUnitAssociateAddedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitAssociateAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAssociateChangedMessage ¶

type BusinessUnitAssociateChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [Associate](ctp:api:type:Associate) that was updated.
	Associate Associate `json:"associate"`
}

* * Generated after a successful [Change Associate](ctp:api:type:BusinessUnitChangeAssociateAction) update action. *

func (BusinessUnitAssociateChangedMessage) MarshalJSON ¶

func (obj BusinessUnitAssociateChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitAssociateChangedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitAssociateChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitAssociateChangedMessagePayload ¶

type BusinessUnitAssociateChangedMessagePayload struct {
	// The [Associate](ctp:api:type:Associate) that was updated.
	Associate Associate `json:"associate"`
}

* * Generated after a successful [Change Associate](ctp:api:type:BusinessUnitChangeAssociateAction) update action. *

func (BusinessUnitAssociateChangedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitAssociateChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAssociateMode ¶

type BusinessUnitAssociateMode string

* * Determines whether a Business Unit can inherit Associates from a parent. *

const (
	BusinessUnitAssociateModeExplicit              BusinessUnitAssociateMode = "Explicit"
	BusinessUnitAssociateModeExplicitAndFromParent BusinessUnitAssociateMode = "ExplicitAndFromParent"
)

type BusinessUnitAssociateModeChangedMessage ¶

type BusinessUnitAssociateModeChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [BusinessUnitAssociateMode](ctp:api:type:BusinessUnitAssociateMode) of the Business Unit after the [Change Associate Mode](ctp:api:type:BusinessUnitChangeAssociateModeAction) update action.
	AssociateMode BusinessUnitAssociateMode `json:"associateMode"`
	// [BusinessUnitAssociateMode](ctp:api:type:BusinessUnitAssociateMode) of the Business Unit before the [Change Associate Mode](ctp:api:type:BusinessUnitChangeAssociateModeAction) update action.
	OldAssociateMode BusinessUnitAssociateMode `json:"oldAssociateMode"`
}

* * Generated after a successful [Change Associate Mode](ctp:api:type:BusinessUnitChangeAssociateModeAction) update action. *

func (BusinessUnitAssociateModeChangedMessage) MarshalJSON ¶

func (obj BusinessUnitAssociateModeChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitAssociateModeChangedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitAssociateModeChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitAssociateModeChangedMessagePayload ¶

type BusinessUnitAssociateModeChangedMessagePayload struct {
	// [BusinessUnitAssociateMode](ctp:api:type:BusinessUnitAssociateMode) of the Business Unit after the [Change Associate Mode](ctp:api:type:BusinessUnitChangeAssociateModeAction) update action.
	AssociateMode BusinessUnitAssociateMode `json:"associateMode"`
	// [BusinessUnitAssociateMode](ctp:api:type:BusinessUnitAssociateMode) of the Business Unit before the [Change Associate Mode](ctp:api:type:BusinessUnitChangeAssociateModeAction) update action.
	OldAssociateMode BusinessUnitAssociateMode `json:"oldAssociateMode"`
}

* * Generated after a successful [Change Associate Mode](ctp:api:type:BusinessUnitChangeAssociateModeAction) update action. *

func (BusinessUnitAssociateModeChangedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAssociateRemovedMessage ¶

type BusinessUnitAssociateRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [Associate](ctp:api:type:Associate) that was removed from the [Business Unit](ctp:api:type:BusinessUnit).
	Associate Associate `json:"associate"`
}

* * Generated after a successful [Remove Associate](ctp:api:type:BusinessUnitRemoveAssociateAction) update action. *

func (BusinessUnitAssociateRemovedMessage) MarshalJSON ¶

func (obj BusinessUnitAssociateRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitAssociateRemovedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitAssociateRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitAssociateRemovedMessagePayload ¶

type BusinessUnitAssociateRemovedMessagePayload struct {
	// The [Associate](ctp:api:type:Associate) that was removed from the [Business Unit](ctp:api:type:BusinessUnit).
	Associate Associate `json:"associate"`
}

* * Generated after a successful [Remove Associate](ctp:api:type:BusinessUnitRemoveAssociateAction) update action. *

func (BusinessUnitAssociateRemovedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitAssociateRemovedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitAssociatesSetMessage ¶

type BusinessUnitAssociatesSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The list of [Associates](ctp:api:type:Associate) that was updated on the [Business Unit](ctp:api:type:BusinessUnit).
	Associates []Associate `json:"associates"`
}

* * Generated after a successful [Set Associates](ctp:api:type:BusinessUnitSetAssociatesAction) update action. *

func (BusinessUnitAssociatesSetMessage) MarshalJSON ¶

func (obj BusinessUnitAssociatesSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitAssociatesSetMessage) UnmarshalJSON ¶

func (obj *BusinessUnitAssociatesSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitAssociatesSetMessagePayload ¶

type BusinessUnitAssociatesSetMessagePayload struct {
	// The list of [Associates](ctp:api:type:Associate) that was updated on the [Business Unit](ctp:api:type:BusinessUnit).
	Associates []Associate `json:"associates"`
}

* * Generated after a successful [Set Associates](ctp:api:type:BusinessUnitSetAssociatesAction) update action. *

func (BusinessUnitAssociatesSetMessagePayload) MarshalJSON ¶

func (obj BusinessUnitAssociatesSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitBillingAddressAddedMessage ¶

type BusinessUnitBillingAddressAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The address that was added to the [Business Unit](ctp:api:type:BusinessUnit) as billing address.
	Address Address `json:"address"`
}

* * Generated after a successful [Add Billing Address Identifier](ctp:api:type:BusinessUnitAddBillingAddressIdAction) update action. *

func (BusinessUnitBillingAddressAddedMessage) MarshalJSON ¶

func (obj BusinessUnitBillingAddressAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitBillingAddressAddedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitBillingAddressAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitBillingAddressAddedMessagePayload ¶

type BusinessUnitBillingAddressAddedMessagePayload struct {
	// The address that was added to the [Business Unit](ctp:api:type:BusinessUnit) as billing address.
	Address Address `json:"address"`
}

* * Generated after a successful [Add Billing Address Identifier](ctp:api:type:BusinessUnitAddBillingAddressIdAction) update action. *

func (BusinessUnitBillingAddressAddedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitBillingAddressRemovedMessage ¶

type BusinessUnitBillingAddressRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The address that was removed from the billing addresses of the [Business Unit](ctp:api:type:BusinessUnit).
	Address Address `json:"address"`
}

* * Generated after a successful [Remove Billing Address Identifier](ctp:api:type:BusinessUnitRemoveBillingAddressIdAction) update action. *

func (BusinessUnitBillingAddressRemovedMessage) MarshalJSON ¶

func (obj BusinessUnitBillingAddressRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitBillingAddressRemovedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitBillingAddressRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitBillingAddressRemovedMessagePayload ¶

type BusinessUnitBillingAddressRemovedMessagePayload struct {
	// The address that was removed from the billing addresses of the [Business Unit](ctp:api:type:BusinessUnit).
	Address Address `json:"address"`
}

* * Generated after a successful [Remove Billing Address Identifier](ctp:api:type:BusinessUnitRemoveBillingAddressIdAction) update action. *

func (BusinessUnitBillingAddressRemovedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitChangeAddressAction ¶

type BusinessUnitChangeAddressAction struct {
	// ID of the address to change. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to change. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
	// New address to set.
	Address BaseAddress `json:"address"`
}

* * Changing the address on a Business Unit generates the [BusinessUnitAddressChanged](ctp:api:type:BusinessUnitAddressChangedMessage) Message. *

func (BusinessUnitChangeAddressAction) MarshalJSON ¶

func (obj BusinessUnitChangeAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitChangeAssociateAction ¶

type BusinessUnitChangeAssociateAction struct {
	// New version of an existing Associate.
	Associate AssociateDraft `json:"associate"`
}

* * Updating the Associate(ctp:api:type:Associate) on a [Business Unit](ctp:api:type:BusinessUnit) generates the [BusinessUnitAssociateChanged](ctp:api:type:BusinessUnitAssociateChangedMessage) Message. *

func (BusinessUnitChangeAssociateAction) MarshalJSON ¶

func (obj BusinessUnitChangeAssociateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitChangeAssociateModeAction ¶

type BusinessUnitChangeAssociateModeAction struct {
	// The new value for `associateMode`.
	AssociateMode BusinessUnitAssociateMode `json:"associateMode"`
}

* * Only Business Units of type `Division` can be changed to `ExplicitAndFromParent`. * This update action generates a [BusinessUnitAssociateModeChanged](ctp:api:type:BusinessUnitAssociateModeChangedMessage) Message. *

func (BusinessUnitChangeAssociateModeAction) MarshalJSON ¶

func (obj BusinessUnitChangeAssociateModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitChangeNameAction ¶

type BusinessUnitChangeNameAction struct {
	// New name to set.
	Name string `json:"name"`
}

* * Updating the name on a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitNameChanged](ctp:api:type:BusinessUnitNameChangedMessage) Message. *

func (BusinessUnitChangeNameAction) MarshalJSON ¶

func (obj BusinessUnitChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitChangeParentUnitAction ¶

type BusinessUnitChangeParentUnitAction struct {
	// New parent unit of the [Business Unit](ctp:api:type:BusinessUnit).
	ParentUnit BusinessUnitResourceIdentifier `json:"parentUnit"`
}

* * Changing the parent of a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitParentUnitChanged](ctp:api:type:BusinessUnitParentUnitChangedMessage) Message. *

func (BusinessUnitChangeParentUnitAction) MarshalJSON ¶

func (obj BusinessUnitChangeParentUnitAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitChangeStatusAction ¶

type BusinessUnitChangeStatusAction struct {
	// New status to set.
	Status string `json:"status"`
}

* * Changing the status of a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitStatusChanged](ctp:api:type:BusinessUnitStatusChangedMessage) Message. *

func (BusinessUnitChangeStatusAction) MarshalJSON ¶

func (obj BusinessUnitChangeStatusAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitConfiguration ¶

type BusinessUnitConfiguration struct {
	// Status of Business Units created using the [My Business Unit endpoint](ctp:api:endpoint:/{projectKey}/me/business-units:POST).
	MyBusinessUnitStatusOnCreation BusinessUnitConfigurationStatus `json:"myBusinessUnitStatusOnCreation"`
	// Default [Associate Role](ctp:api:type:AssociateRole) assigned to the Associate creating a Business Unit using the [My Business Unit endpoint](ctp:api:endpoint:/{projectKey}/me/business-units:POST).
	MyBusinessUnitAssociateRoleOnCreation *AssociateRoleKeyReference `json:"myBusinessUnitAssociateRoleOnCreation,omitempty"`
}

type BusinessUnitConfigurationStatus ¶

type BusinessUnitConfigurationStatus string

* * Default value for [Business Unit Status](ctp:api:type:BusinessUnitStatus) configured though [Project settings](/../api/projects/project#change-my-business-unit-status-on-creation).

const (
	BusinessUnitConfigurationStatusActive   BusinessUnitConfigurationStatus = "Active"
	BusinessUnitConfigurationStatusInactive BusinessUnitConfigurationStatus = "Inactive"
)

type BusinessUnitContactEmailSetMessage ¶

type BusinessUnitContactEmailSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The contact email that was updated on the [Business Unit](ctp:api:type:BusinessUnit).
	ContactEmail *string `json:"contactEmail,omitempty"`
}

* * Generated after a successful [Set Contact Email](ctp:api:type:BusinessUnitSetContactEmailAction) update action. *

func (BusinessUnitContactEmailSetMessage) MarshalJSON ¶

func (obj BusinessUnitContactEmailSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitContactEmailSetMessage) UnmarshalJSON ¶

func (obj *BusinessUnitContactEmailSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitContactEmailSetMessagePayload ¶

type BusinessUnitContactEmailSetMessagePayload struct {
	// The contact email that was updated on the [Business Unit](ctp:api:type:BusinessUnit).
	ContactEmail *string `json:"contactEmail,omitempty"`
}

* * Generated after a successful [Set Contact Email](ctp:api:type:BusinessUnitSetContactEmailAction) update action. *

func (BusinessUnitContactEmailSetMessagePayload) MarshalJSON ¶

func (obj BusinessUnitContactEmailSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitCreatedMessage ¶

type BusinessUnitCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [Business Unit](ctp:api:type:BusinessUnit) that was created.
	BusinessUnit BusinessUnit `json:"businessUnit"`
}

* * Generated after a successful [Create Business Unit](/projects/business-units#create-businessunit) request. *

func (BusinessUnitCreatedMessage) MarshalJSON ¶

func (obj BusinessUnitCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitCreatedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitCreatedMessagePayload ¶

type BusinessUnitCreatedMessagePayload struct {
	// The [Business Unit](ctp:api:type:BusinessUnit) that was created.
	BusinessUnit BusinessUnit `json:"businessUnit"`
}

* * Generated after a successful [Create Business Unit](/projects/business-units#create-businessunit) request. *

func (BusinessUnitCreatedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitCreatedMessagePayload) UnmarshalJSON ¶

func (obj *BusinessUnitCreatedMessagePayload) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitDefaultBillingAddressSetMessage ¶

type BusinessUnitDefaultBillingAddressSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The address that was set as the default billing address.
	Address *Address `json:"address,omitempty"`
}

* * Generated after a successful [Set Default Billing Address](ctp:api:type:BusinessUnitSetDefaultBillingAddressAction) update action. *

func (BusinessUnitDefaultBillingAddressSetMessage) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitDefaultBillingAddressSetMessage) UnmarshalJSON ¶

func (obj *BusinessUnitDefaultBillingAddressSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitDefaultBillingAddressSetMessagePayload ¶

type BusinessUnitDefaultBillingAddressSetMessagePayload struct {
	// The address that was set as the default billing address.
	Address *Address `json:"address,omitempty"`
}

* * Generated after a successful [Set Default Billing Address](ctp:api:type:BusinessUnitSetDefaultBillingAddressAction) update action. *

func (BusinessUnitDefaultBillingAddressSetMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitDefaultShippingAddressSetMessage ¶

type BusinessUnitDefaultShippingAddressSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The address that was set as the default shipping address.
	Address *Address `json:"address,omitempty"`
}

* * Generated after a successful [Set Default Shipping Address](ctp:api:type:BusinessUnitSetDefaultShippingAddressAction) update action. *

func (BusinessUnitDefaultShippingAddressSetMessage) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitDefaultShippingAddressSetMessage) UnmarshalJSON ¶

func (obj *BusinessUnitDefaultShippingAddressSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitDefaultShippingAddressSetMessagePayload ¶

type BusinessUnitDefaultShippingAddressSetMessagePayload struct {
	// The address that was set as the default shipping address.
	Address *Address `json:"address,omitempty"`
}

* * Generated after a successful [Set Default Shipping Address](ctp:api:type:BusinessUnitSetDefaultShippingAddressAction) update action. *

func (BusinessUnitDefaultShippingAddressSetMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitDeletedMessage ¶

type BusinessUnitDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
}

* * Generated after a successful [Delete Business Unit](/projects/business-units#delete-businessunit) request. *

func (BusinessUnitDeletedMessage) MarshalJSON ¶

func (obj BusinessUnitDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitDeletedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitDeletedMessagePayload ¶

type BusinessUnitDeletedMessagePayload struct {
}

* * Generated after a successful [Delete Business Unit](/projects/business-units#delete-businessunit) request. *

func (BusinessUnitDeletedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitDraft ¶

type BusinessUnitDraft interface{}

* * Generic draft type to model those fields all Business Units have in common. The additional fields required for creating a Company(ctp:api:type:Company) or Division(ctp:api:type:Division) are represented on CompanyDraft(ctp:api:type:CompanyDraft) and DivisionDraft(ctp:api:type:DivisionDraft). *

type BusinessUnitKeyReference ¶

type BusinessUnitKeyReference struct {
	// Unique and immutable key of the referenced [BusinessUnit](ctp:api:type:BusinessUnit).
	Key string `json:"key"`
}

* * Reference(/../api/types#reference) to a BusinessUnit(ctp:api:type:BusinessUnit) by its key. *

func (BusinessUnitKeyReference) MarshalJSON ¶

func (obj BusinessUnitKeyReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitNameChangedMessage ¶

type BusinessUnitNameChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Updated name of the [Business Unit](ctp:api:type:BusinessUnit).
	Name string `json:"name"`
}

* * Generated after a successful [Change Name](ctp:api:type:BusinessUnitChangeNameAction) update action. *

func (BusinessUnitNameChangedMessage) MarshalJSON ¶

func (obj BusinessUnitNameChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitNameChangedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitNameChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitNameChangedMessagePayload ¶

type BusinessUnitNameChangedMessagePayload struct {
	// Updated name of the [Business Unit](ctp:api:type:BusinessUnit).
	Name string `json:"name"`
}

* * Generated after a successful [Change Name](ctp:api:type:BusinessUnitChangeNameAction) update action. *

func (BusinessUnitNameChangedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitNameChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitPagedQueryResponse ¶

type BusinessUnitPagedQueryResponse struct {
	// Number of requested [results](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of elements [skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [BusinessUnits](ctp:api:type:BusinessUnit) matching the query.
	Results []BusinessUnit `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of BusinessUnit(ctp:api:type:BusinessUnit). *

func (*BusinessUnitPagedQueryResponse) UnmarshalJSON ¶

func (obj *BusinessUnitPagedQueryResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitParentUnitChangedMessage ¶

type BusinessUnitParentUnitChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Parent unit of the [Business Unit](ctp:api:type:BusinessUnit) before the [Change Parent Unit](ctp:api:type:BusinessUnitChangeParentUnitAction) update action.
	OldParentUnit *BusinessUnitKeyReference `json:"oldParentUnit,omitempty"`
	// Parent unit of the [Business Unit](ctp:api:type:BusinessUnit) after the [Change Parent Unit](ctp:api:type:BusinessUnitChangeParentUnitAction) update action.
	NewParentUnit *BusinessUnitKeyReference `json:"newParentUnit,omitempty"`
}

* * Generated after a successful [Change Parent Unit](ctp:api:type:BusinessUnitChangeParentUnitAction) update action. *

func (BusinessUnitParentUnitChangedMessage) MarshalJSON ¶

func (obj BusinessUnitParentUnitChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitParentUnitChangedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitParentUnitChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitParentUnitChangedMessagePayload ¶

type BusinessUnitParentUnitChangedMessagePayload struct {
	// Parent unit of the [Business Unit](ctp:api:type:BusinessUnit) before the [Change Parent Unit](ctp:api:type:BusinessUnitChangeParentUnitAction) update action.
	OldParentUnit *BusinessUnitKeyReference `json:"oldParentUnit,omitempty"`
	// Parent unit of the [Business Unit](ctp:api:type:BusinessUnit) after the [Change Parent Unit](ctp:api:type:BusinessUnitChangeParentUnitAction) update action.
	NewParentUnit *BusinessUnitKeyReference `json:"newParentUnit,omitempty"`
}

* * Generated after a successful [Change Parent Unit](ctp:api:type:BusinessUnitChangeParentUnitAction) update action. *

func (BusinessUnitParentUnitChangedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitReference ¶

type BusinessUnitReference struct {
	// Unique identifier of the referenced [BusinessUnit](ctp:api:type:BusinessUnit).
	ID string `json:"id"`
	// Contains the representation of the expanded BusinessUnit. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for BusinessUnit.
	Obj BusinessUnit `json:"obj,omitempty"`
}

* * Reference(/../api/types#reference) to a BusinessUnit(ctp:api:type:BusinessUnit). *

func (BusinessUnitReference) MarshalJSON ¶

func (obj BusinessUnitReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitReference) UnmarshalJSON ¶

func (obj *BusinessUnitReference) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitRemoveAddressAction ¶

type BusinessUnitRemoveAddressAction struct {
	// ID of the address to be removed. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to be removed. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removing the address from a [Business Unit](ctp:api:type:BusinessUnit) generates the [BusinessUnitAddressRemoved](ctp:api:type:BusinessUnitAddressRemovedMessage) Message. *

func (BusinessUnitRemoveAddressAction) MarshalJSON ¶

func (obj BusinessUnitRemoveAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitRemoveAssociateAction ¶

type BusinessUnitRemoveAssociateAction struct {
	// [Associate](ctp:api:type:Associate) to remove.
	Customer CustomerResourceIdentifier `json:"customer"`
}

* * Removing an Associate(ctp:api:type:Associate) from a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitAssociateRemoved](ctp:api:type:BusinessUnitAssociateRemovedMessage) Message. *

func (BusinessUnitRemoveAssociateAction) MarshalJSON ¶

func (obj BusinessUnitRemoveAssociateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitRemoveBillingAddressIdAction ¶

type BusinessUnitRemoveBillingAddressIdAction struct {
	// ID of the address to be removed from `billingAddressIds`. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to be removed from `billingAddressIds`. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removing a billing address from a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitBillingAddressRemoved](ctp:api:type:BusinessUnitBillingAddressRemovedMessage) Message. *

func (BusinessUnitRemoveBillingAddressIdAction) MarshalJSON ¶

func (obj BusinessUnitRemoveBillingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitRemoveShippingAddressIdAction ¶

type BusinessUnitRemoveShippingAddressIdAction struct {
	// ID of the address to be removed from `shippingAddressIds`. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to be removed from `shippingAddressIds`. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removing a shipping address from a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitShippingAddressRemoved](ctp:api:type:BusinessUnitShippingAddressRemovedMessage) Message. *

func (BusinessUnitRemoveShippingAddressIdAction) MarshalJSON ¶

func (obj BusinessUnitRemoveShippingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitRemoveStoreAction ¶

type BusinessUnitRemoveStoreAction struct {
	// [Store](ctp:api:type:Store) to remove.
	Store StoreResourceIdentifier `json:"store"`
}

* * Removes a Store from the Business Unit. * Newly created [Carts](ctp:api:type:Cart) and [Orders](ctp:api:type:Order) can no longer reference the removed Store for the Business Unit. * We recommend cleaning up unordered Carts that still have the Store assigned after calling this update action since those cannot be converted to Orders. * Orders created before the Store was removed remain unchanged. * Generates a [BusinessUnitStoreRemoved](ctp:api:type:BusinessUnitStoreRemovedMessage) Message. * Only applicable when `storeMode` is `Explicit`. *

func (BusinessUnitRemoveStoreAction) MarshalJSON ¶

func (obj BusinessUnitRemoveStoreAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitResourceIdentifier ¶

type BusinessUnitResourceIdentifier struct {
	// Unique identifier of the referenced [BusinessUnit](ctp:api:type:BusinessUnit). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// Unique key of the referenced [BusinessUnit](ctp:api:type:BusinessUnit). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(/../api/types#resourceidentifier) to a BusinessUnit(ctp:api:type:BusinessUnit). *

func (BusinessUnitResourceIdentifier) MarshalJSON ¶

func (obj BusinessUnitResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitSetAddressCustomFieldAction ¶

type BusinessUnitSetAddressCustomFieldAction struct {
	// ID of the address to be extended.
	AddressId string `json:"addressId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Trying to remove a field that does not exist will fail with an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (BusinessUnitSetAddressCustomFieldAction) MarshalJSON ¶

func (obj BusinessUnitSetAddressCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitSetAddressCustomTypeAction ¶

type BusinessUnitSetAddressCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the `address` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `address`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) for the `address`.
	Fields *FieldContainer `json:"fields,omitempty"`
	// ID of the address to be extended.
	AddressId string `json:"addressId"`
}

func (BusinessUnitSetAddressCustomTypeAction) MarshalJSON ¶

func (obj BusinessUnitSetAddressCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitSetAssociatesAction ¶

type BusinessUnitSetAssociatesAction struct {
	// The new list of Associates. If not provided, any existing list is removed.
	Associates []AssociateDraft `json:"associates"`
}

* * Changes the Associates of a [Business Unit](ctp:api:type:BusinessUnit), generates a [BusinessUnitAssociatesSet](ctp:api:type:BusinessUnitAssociatesSetMessage) Message. *

func (BusinessUnitSetAssociatesAction) MarshalJSON ¶

func (obj BusinessUnitSetAssociatesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitSetContactEmailAction ¶

type BusinessUnitSetContactEmailAction struct {
	// Email to set.
	// If `contactEmail` is absent or `null`, the existing contact email, if any, will be removed.
	ContactEmail *string `json:"contactEmail,omitempty"`
}

* * Setting the contact email on a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitContactEmailSet](ctp:api:type:BusinessUnitContactEmailSetMessage) Message. *

func (BusinessUnitSetContactEmailAction) MarshalJSON ¶

func (obj BusinessUnitSetContactEmailAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitSetCustomFieldAction ¶

type BusinessUnitSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Trying to remove a field that does not exist will fail with an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (BusinessUnitSetCustomFieldAction) MarshalJSON ¶

func (obj BusinessUnitSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitSetCustomTypeAction ¶

type BusinessUnitSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the BusinessUnit with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the BusinessUnit.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) for the BusinessUnit.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (BusinessUnitSetCustomTypeAction) MarshalJSON ¶

func (obj BusinessUnitSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitSetDefaultBillingAddressAction ¶

type BusinessUnitSetDefaultBillingAddressAction struct {
	// ID of the address to add as a billing address. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to add as a billing address. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Setting the default billing address on a [Business Unit](ctp:api:type:BusinessUnit) generates the [BusinessUnitDefaultBillingAddressSet](ctp:api:type:BusinessUnitDefaultBillingAddressSetMessage) Message. *

func (BusinessUnitSetDefaultBillingAddressAction) MarshalJSON ¶

func (obj BusinessUnitSetDefaultBillingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitSetDefaultShippingAddressAction ¶

type BusinessUnitSetDefaultShippingAddressAction struct {
	// ID of the address to add as a shipping address. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to add as a shipping address. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Setting the default shipping address on a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitDefaultShippingAddressSet](ctp:api:type:BusinessUnitDefaultShippingAddressSetMessage) Message. *

func (BusinessUnitSetDefaultShippingAddressAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitSetStoreModeAction ¶

type BusinessUnitSetStoreModeAction struct {
	// Set to `Explicit` to specify Stores for the Business Unit. Set to `FromParent` to inherit Stores from a parent.
	StoreMode BusinessUnitStoreMode `json:"storeMode"`
	// Set the [Stores](ctp:api:type:Store) the Business Unit is associated with. Can only be set if `storeMode` is `Explicit`.
	Stores []StoreResourceIdentifier `json:"stores"`
}

* * Only Business Units of type `Division` can be have a store mode of `FromParent`. Changing the `storeMode` to `FromParent` empties the `stores` array on the BusinessUnit. * This update action generates a [BusinessUnitStoreModeChanged](ctp:api:type:BusinessUnitStoreModeChangedMessage) Message. *

func (BusinessUnitSetStoreModeAction) MarshalJSON ¶

func (obj BusinessUnitSetStoreModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitSetStoresAction ¶

type BusinessUnitSetStoresAction struct {
	// [Stores](ctp:api:type:Store) to set. Overrides the current list of Stores.
	Stores []StoreResourceIdentifier `json:"stores"`
}

* * Sets the Stores of the Business Unit. Can only be set if the Business Unit `storeMode` is `Explicit`. * [Carts](ctp:api:type:Cart) and [Orders](ctp:api:type:Order) created after the Set Stores update must use the new Stores of * the Business Unit and, if set, their [Product Selections](ctp:api:type:ProductSelection), and [Channels](ctp:api:type:Channel). * Orders created before the Set Stores update action remain unchanged. * Setting the Stores on a Business Unit generates a [BusinessUnitStoresSet](ctp:api:type:BusinessUnitStoresSetMessage) Message. *

func (BusinessUnitSetStoresAction) MarshalJSON ¶

func (obj BusinessUnitSetStoresAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitShippingAddressAddedMessage ¶

type BusinessUnitShippingAddressAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The address that was added to the [Business Unit](ctp:api:type:BusinessUnit) as shipping address.
	Address Address `json:"address"`
}

* * Generated after a successful [Add Shipping Address Identifier](ctp:api:type:BusinessUnitAddShippingAddressIdAction) update action. *

func (BusinessUnitShippingAddressAddedMessage) MarshalJSON ¶

func (obj BusinessUnitShippingAddressAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitShippingAddressAddedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitShippingAddressAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitShippingAddressAddedMessagePayload ¶

type BusinessUnitShippingAddressAddedMessagePayload struct {
	// The address that was added to the [Business Unit](ctp:api:type:BusinessUnit) as shipping address.
	Address Address `json:"address"`
}

* * Generated after a successful [Add Shipping Address Identifier](ctp:api:type:BusinessUnitAddShippingAddressIdAction) update action. *

func (BusinessUnitShippingAddressAddedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitShippingAddressRemovedMessage ¶

type BusinessUnitShippingAddressRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The address that was removed from shipping addresses of the [Business Unit](ctp:api:type:BusinessUnit).
	Address Address `json:"address"`
}

* * Generated after a successful [Remove Shipping Address Identifier](ctp:api:type:BusinessUnitRemoveShippingAddressIdAction) update action. *

func (BusinessUnitShippingAddressRemovedMessage) MarshalJSON ¶

func (obj BusinessUnitShippingAddressRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitShippingAddressRemovedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitShippingAddressRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitShippingAddressRemovedMessagePayload ¶

type BusinessUnitShippingAddressRemovedMessagePayload struct {
	// The address that was removed from shipping addresses of the [Business Unit](ctp:api:type:BusinessUnit).
	Address Address `json:"address"`
}

* * Generated after a successful [Remove Shipping Address Identifier](ctp:api:type:BusinessUnitRemoveShippingAddressIdAction) update action. *

func (BusinessUnitShippingAddressRemovedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitStatus ¶

type BusinessUnitStatus string

* * Indicates whether the Business Unit can be edited and used in [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [Quote Requests](ctp:api:type:QuoteRequest), or [Quotes](ctp:api:type:Quote). *

const (
	BusinessUnitStatusActive   BusinessUnitStatus = "Active"
	BusinessUnitStatusInactive BusinessUnitStatus = "Inactive"
)

type BusinessUnitStatusChangedMessage ¶

type BusinessUnitStatusChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Updated status of the [Business Unit](ctp:api:type:BusinessUnit).
	Active BusinessUnitStatus `json:"active"`
}

* * Generated after a successful [Change Status](ctp:api:type:BusinessUnitChangeStatusAction) update action. *

func (BusinessUnitStatusChangedMessage) MarshalJSON ¶

func (obj BusinessUnitStatusChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitStatusChangedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitStatusChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitStatusChangedMessagePayload ¶

type BusinessUnitStatusChangedMessagePayload struct {
	// Updated status of the [Business Unit](ctp:api:type:BusinessUnit).
	Active BusinessUnitStatus `json:"active"`
}

* * Generated after a successful [Change Status](ctp:api:type:BusinessUnitChangeStatusAction) update action. *

func (BusinessUnitStatusChangedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitStatusChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitStoreAddedMessage ¶

type BusinessUnitStoreAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [Store](ctp:api:type:Store) that was added to the [Business Unit](ctp:api:type:BusinessUnit).
	Store StoreKeyReference `json:"store"`
}

* * Generated after a successful [Add Store](ctp:api:type:BusinessUnitAddStoreAction) update action. *

func (BusinessUnitStoreAddedMessage) MarshalJSON ¶

func (obj BusinessUnitStoreAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitStoreAddedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitStoreAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitStoreAddedMessagePayload ¶

type BusinessUnitStoreAddedMessagePayload struct {
	// The [Store](ctp:api:type:Store) that was added to the [Business Unit](ctp:api:type:BusinessUnit).
	Store StoreKeyReference `json:"store"`
}

* * Generated after a successful [Add Store](ctp:api:type:BusinessUnitAddStoreAction) update action. *

func (BusinessUnitStoreAddedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitStoreAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitStoreMode ¶

type BusinessUnitStoreMode string

* * Defines whether the Stores of the Business Unit are set directly on the Business Unit or are inherited from its parent unit. *

const (
	BusinessUnitStoreModeExplicit   BusinessUnitStoreMode = "Explicit"
	BusinessUnitStoreModeFromParent BusinessUnitStoreMode = "FromParent"
)

type BusinessUnitStoreModeChangedMessage ¶

type BusinessUnitStoreModeChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Stores](ctp:api:type:Store) of the [Business Unit](ctp:api:type:BusinessUnit) after the [Set Store Mode](ctp:api:type:BusinessUnitSetStoreModeAction) update action.
	Stores []StoreKeyReference `json:"stores"`
	// [BusinessUnitStoreMode](ctp:api:type:BusinessUnitStoreMode) of the Business Unit after the [Set Store Mode](ctp:api:type:BusinessUnitSetStoreModeAction) update action.
	StoreMode BusinessUnitStoreMode `json:"storeMode"`
	// [Stores](ctp:api:type:Store) of the [Business Unit](ctp:api:type:BusinessUnit) before the [Set Store Mode](ctp:api:type:BusinessUnitSetStoreModeAction) update action.
	OldStores []StoreKeyReference `json:"oldStores"`
	// [BusinessUnitStoreMode](ctp:api:type:BusinessUnitStoreMode) of the Business Unit before the [Set Store Mode](ctp:api:type:BusinessUnitSetStoreModeAction) update action.
	OldStoreMode BusinessUnitStoreMode `json:"oldStoreMode"`
}

* * Generated after a successful [Set Store Mode](ctp:api:type:BusinessUnitSetStoreModeAction) update action. *

func (BusinessUnitStoreModeChangedMessage) MarshalJSON ¶

func (obj BusinessUnitStoreModeChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitStoreModeChangedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitStoreModeChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitStoreModeChangedMessagePayload ¶

type BusinessUnitStoreModeChangedMessagePayload struct {
	// [Stores](ctp:api:type:Store) of the [Business Unit](ctp:api:type:BusinessUnit) after the [Set Store Mode](ctp:api:type:BusinessUnitSetStoreModeAction) update action.
	Stores []StoreKeyReference `json:"stores"`
	// [BusinessUnitStoreMode](ctp:api:type:BusinessUnitStoreMode) of the Business Unit after the [Set Store Mode](ctp:api:type:BusinessUnitSetStoreModeAction) update action.
	StoreMode BusinessUnitStoreMode `json:"storeMode"`
	// [Stores](ctp:api:type:Store) of the [Business Unit](ctp:api:type:BusinessUnit) before the [Set Store Mode](ctp:api:type:BusinessUnitSetStoreModeAction) update action.
	OldStores []StoreKeyReference `json:"oldStores"`
	// [BusinessUnitStoreMode](ctp:api:type:BusinessUnitStoreMode) of the Business Unit before the [Set Store Mode](ctp:api:type:BusinessUnitSetStoreModeAction) update action.
	OldStoreMode BusinessUnitStoreMode `json:"oldStoreMode"`
}

* * Generated after a successful [Set Store Mode](ctp:api:type:BusinessUnitSetStoreModeAction) update action. *

func (BusinessUnitStoreModeChangedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitStoreModeChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitStoreRemovedMessage ¶

type BusinessUnitStoreRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [Store](ctp:api:type:Store) that was removed from the [Business Unit](ctp:api:type:BusinessUnit).
	Store StoreKeyReference `json:"store"`
}

func (BusinessUnitStoreRemovedMessage) MarshalJSON ¶

func (obj BusinessUnitStoreRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitStoreRemovedMessage) UnmarshalJSON ¶

func (obj *BusinessUnitStoreRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitStoreRemovedMessagePayload ¶

type BusinessUnitStoreRemovedMessagePayload struct {
	// The [Store](ctp:api:type:Store) that was removed from the [Business Unit](ctp:api:type:BusinessUnit).
	Store StoreKeyReference `json:"store"`
}

func (BusinessUnitStoreRemovedMessagePayload) MarshalJSON ¶

func (obj BusinessUnitStoreRemovedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitStoresSetMessage ¶

type BusinessUnitStoresSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Stores](ctp:api:type:Store) of the [Business Unit](ctp:api:type:BusinessUnit) after the [Set Stores](ctp:api:type:BusinessUnitSetStoresAction) update action.
	Stores []StoreKeyReference `json:"stores"`
}

* * Generated after a successful [Set Stores](ctp:api:type:BusinessUnitSetStoresAction) update action. *

func (BusinessUnitStoresSetMessage) MarshalJSON ¶

func (obj BusinessUnitStoresSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BusinessUnitStoresSetMessage) UnmarshalJSON ¶

func (obj *BusinessUnitStoresSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitStoresSetMessagePayload ¶

type BusinessUnitStoresSetMessagePayload struct {
	// [Stores](ctp:api:type:Store) of the [Business Unit](ctp:api:type:BusinessUnit) after the [Set Stores](ctp:api:type:BusinessUnitSetStoresAction) update action.
	Stores []StoreKeyReference `json:"stores"`
}

* * Generated after a successful [Set Stores](ctp:api:type:BusinessUnitSetStoresAction) update action. *

func (BusinessUnitStoresSetMessagePayload) MarshalJSON ¶

func (obj BusinessUnitStoresSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type BusinessUnitType ¶

type BusinessUnitType string

* * The type of the Business Unit indicating its position in a hierarchy. *

const (
	BusinessUnitTypeCompany  BusinessUnitType = "Company"
	BusinessUnitTypeDivision BusinessUnitType = "Division"
)

type BusinessUnitUpdate ¶

type BusinessUnitUpdate struct {
	// Expected version of the BusinessUnit on which the changes should be applied.
	// If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the BusinessUnit.
	Actions []BusinessUnitUpdateAction `json:"actions"`
}

func (*BusinessUnitUpdate) UnmarshalJSON ¶

func (obj *BusinessUnitUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BusinessUnitUpdateAction ¶

type BusinessUnitUpdateAction interface{}

type ByProjectKeyApiClientsByIDRequestBuilder ¶

type ByProjectKeyApiClientsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyApiClientsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyApiClientsByIDRequestBuilder) Get ¶

type ByProjectKeyApiClientsByIDRequestMethodDelete ¶

type ByProjectKeyApiClientsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyApiClientsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyApiClientsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyApiClientsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyApiClientsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyApiClientsByIDRequestMethodGet ¶

type ByProjectKeyApiClientsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyApiClientsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyApiClientsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyApiClientsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyApiClientsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyApiClientsRequestBuilder ¶

type ByProjectKeyApiClientsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyApiClientsRequestBuilder) Get ¶

func (*ByProjectKeyApiClientsRequestBuilder) Post ¶

func (*ByProjectKeyApiClientsRequestBuilder) WithId ¶

type ByProjectKeyApiClientsRequestMethodGet ¶

type ByProjectKeyApiClientsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyApiClientsRequestMethodGet) Dump ¶

func (r *ByProjectKeyApiClientsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyApiClientsRequestMethodGet) Execute ¶

func (*ByProjectKeyApiClientsRequestMethodGet) Expand ¶

func (*ByProjectKeyApiClientsRequestMethodGet) Limit ¶

func (*ByProjectKeyApiClientsRequestMethodGet) Offset ¶

func (*ByProjectKeyApiClientsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyApiClientsRequestMethodGet) Sort ¶

func (*ByProjectKeyApiClientsRequestMethodGet) Where ¶

func (*ByProjectKeyApiClientsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyApiClientsRequestMethodGet) WithTotal ¶

type ByProjectKeyApiClientsRequestMethodGetInput ¶

type ByProjectKeyApiClientsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyApiClientsRequestMethodGetInput) Values ¶

type ByProjectKeyApiClientsRequestMethodPost ¶

type ByProjectKeyApiClientsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyApiClientsRequestMethodPost) Dump ¶

func (r *ByProjectKeyApiClientsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyApiClientsRequestMethodPost) Execute ¶

func (rb *ByProjectKeyApiClientsRequestMethodPost) Execute(ctx context.Context) (result *ApiClient, err error)

func (*ByProjectKeyApiClientsRequestMethodPost) Expand ¶

func (*ByProjectKeyApiClientsRequestMethodPost) WithHeaders ¶

type ByProjectKeyApiClientsRequestMethodPostInput ¶

type ByProjectKeyApiClientsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyApiClientsRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestBuilder) Get ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestBuilder) Get ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestBuilder) Get ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestBuilder) WithId ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestBuilder) WithKey ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet) Execute ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet) Expand ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet) Limit ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet) Offset ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet) Sort ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet) Where ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGet) WithTotal ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodPost) Execute ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodPost) Expand ¶

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodPost) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdBusinessUnitsRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestBuilder) Delete ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestBuilder) Get ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestBuilder) Post ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodDelete ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodDelete) Execute ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodDeleteInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodGet) Execute ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodPost) Execute ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestBuilder) Delete ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestBuilder) Get ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestBuilder) Post ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodDelete) Execute ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodGet) Execute ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodPost) Execute ¶

* * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsReplicateRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsReplicateRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsReplicateRequestBuilder) Post ¶

* * Creates a new Cart by replicating an existing Cart or Order. Can be useful in cases where a customer wants to cancel a recent order to make some changes or reorder a previous order. * * The replicated Cart preserves Customer information, Line Items and Custom Line Items, Custom Fields, Discount Codes, and other settings of the Cart or Order. If the Line Items become invalid, for example, due to removed Products or Prices, they are removed from the new Cart. If the Customer switches to another Customer Group, the new Cart is updated with the new value. It has up-to-date Tax Rates, Prices, and Line Item product data and is in `Active` CartState(ctp:api:type:CartState). * * The new Cart does not contain Payments or Deliveries. The State(ctp:api:type:ItemState) of Line Items and Custom Line Items is reset to `initial`. * * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsReplicateRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsReplicateRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsReplicateRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsReplicateRequestMethodPost) Execute ¶

* * Creates a new Cart by replicating an existing Cart or Order. Can be useful in cases where a customer wants to cancel a recent order to make some changes or reorder a previous order. * * The replicated Cart preserves Customer information, Line Items and Custom Line Items, Custom Fields, Discount Codes, and other settings of the Cart or Order. If the Line Items become invalid, for example, due to removed Products or Prices, they are removed from the new Cart. If the Customer switches to another Customer Group, the new Cart is updated with the new value. It has up-to-date Tax Rates, Prices, and Line Item product data and is in `Active` CartState(ctp:api:type:CartState). * * The new Cart does not contain Payments or Deliveries. The State(ctp:api:type:ItemState) of Line Items and Custom Line Items is reset to `initial`. * * If the Cart exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestBuilder) Post ¶

* * Creates a Cart(ctp:api:type:Cart) in the BusinessUnit(ctp:api:type:BusinessUnit) referenced by `businessUnitKey`. As such, the `businessUnit` field on CartDraft(ctp:api:type:CartDraft) is ignored for this request. * Creating a Cart can fail with an [InvalidOperation](ctp:api:type:InvalidOperationError) if the referenced ShippingMethod(ctp:api:type:ShippingMethod) in the CartDraft(ctp:api:type:CartDraft) has a predicate that does not match the Cart. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodGet) Execute ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodGet) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodPost) Execute ¶

* * Creates a Cart(ctp:api:type:Cart) in the BusinessUnit(ctp:api:type:BusinessUnit) referenced by `businessUnitKey`. As such, the `businessUnit` field on CartDraft(ctp:api:type:CartDraft) is ignored for this request. * Creating a Cart can fail with an [InvalidOperation](ctp:api:type:InvalidOperationError) if the referenced ShippingMethod(ctp:api:type:ShippingMethod) in the CartDraft(ctp:api:type:CartDraft) has a predicate that does not match the Cart. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodPost) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyCartsRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestBuilder) Get ¶

* * If the Order exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestBuilder) Post ¶

* * If the Order exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodGet) Execute ¶

* * If the Order exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodPost) Execute ¶

* * If the Order exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersByIDRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestBuilder) Get ¶

* * If the Order exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestBuilder) Post ¶

* * If the Order exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodGet) Execute ¶

* * If the Order exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodPost) Execute ¶

* * If the Order exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersOrderNumberByOrderNumberRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersQuotesRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersQuotesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersQuotesRequestBuilder) Post ¶

* * Creates an Order from a Quote(ctp:api:type:Cart) in a BusinessUnit(ctp:api:type:BusinessUnit). * Creating an Order fails with an [InvalidOperation](ctp:api:type:InvalidOperationError) if the Quote does not reference the same BusinessUnit as the `businessUnitKey` path parameter. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersQuotesRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersQuotesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersQuotesRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersQuotesRequestMethodPost) Execute ¶

* * Creates an Order from a Quote(ctp:api:type:Cart) in a BusinessUnit(ctp:api:type:BusinessUnit). * Creating an Order fails with an [InvalidOperation](ctp:api:type:InvalidOperationError) if the Quote does not reference the same BusinessUnit as the `businessUnitKey` path parameter. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestBuilder) Post ¶

* * Creates an Order from a Cart(ctp:api:type:Cart) in a BusinessUnit(ctp:api:type:BusinessUnit). * The Cart must have a shipping address set before creating an Order. * Creating an Order fails with an [InvalidOperation](ctp:api:type:InvalidOperationError) if the Cart does not reference the same BusinessUnit as the `businessUnitKey` path parameter. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodGet) Execute ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodGet) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodPost) Execute ¶

* * Creates an Order from a Cart(ctp:api:type:Cart) in a BusinessUnit(ctp:api:type:BusinessUnit). * The Cart must have a shipping address set before creating an Order. * Creating an Order fails with an [InvalidOperation](ctp:api:type:InvalidOperationError) if the Cart does not reference the same BusinessUnit as the `businessUnitKey` path parameter. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodPost) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyOrdersRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestBuilder) Get ¶

* * If the QuoteRequest exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestBuilder) Post ¶

* * If the QuoteRequest exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodGet) Execute ¶

* * If the QuoteRequest exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodPost) Execute ¶

* * If the QuoteRequest exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestBuilder) Get ¶

* * If the QuoteRequest exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestBuilder) Post ¶

* * If the QuoteRequest exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodGet) Execute ¶

* * If the QuoteRequest exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodPost) Execute ¶

* * If the QuoteRequest exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestBuilder) Post ¶

* * Creates a QuoteRequest in a BusinessUnit(ctp:api:type:BusinessUnit). Creating QuoteRequest fails with an [InvalidOperation](ctp:api:type:InvalidOperationError) if the Cart does not reference the same BusinessUnit as the `businessUnitKey` path parameter.

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodGet) Execute ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodPost) Execute ¶

* * Creates a QuoteRequest in a BusinessUnit(ctp:api:type:BusinessUnit). Creating QuoteRequest fails with an [InvalidOperation](ctp:api:type:InvalidOperationError) if the Cart does not reference the same BusinessUnit as the `businessUnitKey` path parameter.

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuoteRequestsRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestBuilder) Get ¶

* * If the Quote exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestBuilder) Post ¶

* * If the Quote exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodGet) Execute ¶

* * If the Quote exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodPost) Execute ¶

* * If the Quote exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestBuilder) Get ¶

* * If the Quote exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestBuilder) Post ¶

* * If the Quote exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodGet) Execute ¶

* * If the Quote exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodPost ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodPost) Execute ¶

* * If the Quote exists in the Project(ctp:api:type:Project) but does not reference the requested BusinessUnit(ctp:api:type:BusinessUnit), this method returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error. *

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesRequestBuilder struct {
	// contains filtered or unexported fields
}

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesRequestMethodGet ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesRequestMethodGet) Dump ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesRequestMethodGet) Execute ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesRequestMethodGet) WithHeaders ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesRequestMethodGetInput ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyQuotesRequestMethodGetInput) Values ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyRequestBuilder) Carts ¶

* * A shopping cart holds product variants and can be ordered.

func (*ByProjectKeyAsAssociateByAssociateIdInBusinessUnitKeyByBusinessUnitKeyRequestBuilder) Quotes ¶

* * A quote holds the negotiated offer.

type ByProjectKeyAsAssociateByAssociateIdRequestBuilder ¶

type ByProjectKeyAsAssociateByAssociateIdRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateByAssociateIdRequestBuilder) BusinessUnits ¶

* * A Business Unit can represent a Company or a Division.

func (*ByProjectKeyAsAssociateByAssociateIdRequestBuilder) InBusinessUnitKeyWithBusinessUnitKeyValue ¶

type ByProjectKeyAsAssociateRequestBuilder ¶

type ByProjectKeyAsAssociateRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAsAssociateRequestBuilder) WithAssociateIdValue ¶

type ByProjectKeyAssociateRolesByIDRequestBuilder ¶

type ByProjectKeyAssociateRolesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAssociateRolesByIDRequestBuilder) Delete ¶

func (*ByProjectKeyAssociateRolesByIDRequestBuilder) Get ¶

func (*ByProjectKeyAssociateRolesByIDRequestBuilder) Post ¶

type ByProjectKeyAssociateRolesByIDRequestMethodDelete ¶

type ByProjectKeyAssociateRolesByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAssociateRolesByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyAssociateRolesByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyAssociateRolesByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyAssociateRolesByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyAssociateRolesByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyAssociateRolesByIDRequestMethodDeleteInput ¶

type ByProjectKeyAssociateRolesByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyAssociateRolesByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyAssociateRolesByIDRequestMethodGet ¶

type ByProjectKeyAssociateRolesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAssociateRolesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyAssociateRolesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyAssociateRolesByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyAssociateRolesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyAssociateRolesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyAssociateRolesByIDRequestMethodGetInput ¶

type ByProjectKeyAssociateRolesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAssociateRolesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyAssociateRolesByIDRequestMethodPost ¶

type ByProjectKeyAssociateRolesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAssociateRolesByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyAssociateRolesByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyAssociateRolesByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyAssociateRolesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyAssociateRolesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyAssociateRolesByIDRequestMethodPostInput ¶

type ByProjectKeyAssociateRolesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAssociateRolesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestBuilder ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAssociateRolesKeyByKeyRequestBuilder) Delete ¶

* * Deleting an AssociateRole generates the [AssociateRoleDeleted](ctp:api:type:AssociateRoleDeletedMessage) Message. An AssociateRole can only be deleted if it is not assigned to any [Associates](ctp:api:type:Associate). *

func (*ByProjectKeyAssociateRolesKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyAssociateRolesKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodDelete ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodDelete) Execute ¶

* * Deleting an AssociateRole generates the [AssociateRoleDeleted](ctp:api:type:AssociateRoleDeletedMessage) Message. An AssociateRole can only be deleted if it is not assigned to any [Associates](ctp:api:type:Associate). *

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodGet ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodPost ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyAssociateRolesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAssociateRolesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyAssociateRolesRequestBuilder ¶

type ByProjectKeyAssociateRolesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAssociateRolesRequestBuilder) Get ¶

func (*ByProjectKeyAssociateRolesRequestBuilder) Post ¶

* * Creating a Associate Role generates the [AssociateRoleCreated](ctp:api:type:AssociateRoleCreatedMessage) Message. *

func (*ByProjectKeyAssociateRolesRequestBuilder) WithId ¶

func (*ByProjectKeyAssociateRolesRequestBuilder) WithKey ¶

type ByProjectKeyAssociateRolesRequestMethodGet ¶

type ByProjectKeyAssociateRolesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAssociateRolesRequestMethodGet) Dump ¶

func (r *ByProjectKeyAssociateRolesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyAssociateRolesRequestMethodGet) Execute ¶

func (*ByProjectKeyAssociateRolesRequestMethodGet) Expand ¶

func (*ByProjectKeyAssociateRolesRequestMethodGet) Limit ¶

func (*ByProjectKeyAssociateRolesRequestMethodGet) Offset ¶

func (*ByProjectKeyAssociateRolesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyAssociateRolesRequestMethodGet) Sort ¶

func (*ByProjectKeyAssociateRolesRequestMethodGet) Where ¶

func (*ByProjectKeyAssociateRolesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyAssociateRolesRequestMethodGet) WithTotal ¶

type ByProjectKeyAssociateRolesRequestMethodGetInput ¶

type ByProjectKeyAssociateRolesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyAssociateRolesRequestMethodGetInput) Values ¶

type ByProjectKeyAssociateRolesRequestMethodPost ¶

type ByProjectKeyAssociateRolesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAssociateRolesRequestMethodPost) Dump ¶

func (r *ByProjectKeyAssociateRolesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyAssociateRolesRequestMethodPost) Execute ¶

* * Creating a Associate Role generates the [AssociateRoleCreated](ctp:api:type:AssociateRoleCreatedMessage) Message. *

func (*ByProjectKeyAssociateRolesRequestMethodPost) Expand ¶

func (*ByProjectKeyAssociateRolesRequestMethodPost) WithHeaders ¶

type ByProjectKeyAssociateRolesRequestMethodPostInput ¶

type ByProjectKeyAssociateRolesRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAssociateRolesRequestMethodPostInput) Values ¶

type ByProjectKeyAttributeGroupsByIDRequestBuilder ¶

type ByProjectKeyAttributeGroupsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAttributeGroupsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyAttributeGroupsByIDRequestBuilder) Get ¶

func (*ByProjectKeyAttributeGroupsByIDRequestBuilder) Post ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodDelete ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAttributeGroupsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyAttributeGroupsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyAttributeGroupsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyAttributeGroupsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyAttributeGroupsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodDeleteInput ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyAttributeGroupsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodGet ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAttributeGroupsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyAttributeGroupsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyAttributeGroupsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyAttributeGroupsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyAttributeGroupsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodGetInput ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAttributeGroupsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodPost ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAttributeGroupsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyAttributeGroupsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyAttributeGroupsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyAttributeGroupsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyAttributeGroupsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodPostInput ¶

type ByProjectKeyAttributeGroupsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAttributeGroupsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestBuilder ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodGet ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodPost ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyAttributeGroupsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAttributeGroupsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyAttributeGroupsRequestBuilder ¶

type ByProjectKeyAttributeGroupsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAttributeGroupsRequestBuilder) Get ¶

func (*ByProjectKeyAttributeGroupsRequestBuilder) Post ¶

func (*ByProjectKeyAttributeGroupsRequestBuilder) WithId ¶

func (*ByProjectKeyAttributeGroupsRequestBuilder) WithKey ¶

type ByProjectKeyAttributeGroupsRequestMethodGet ¶

type ByProjectKeyAttributeGroupsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAttributeGroupsRequestMethodGet) Dump ¶

func (r *ByProjectKeyAttributeGroupsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyAttributeGroupsRequestMethodGet) Execute ¶

func (*ByProjectKeyAttributeGroupsRequestMethodGet) Expand ¶

func (*ByProjectKeyAttributeGroupsRequestMethodGet) Limit ¶

func (*ByProjectKeyAttributeGroupsRequestMethodGet) Offset ¶

func (*ByProjectKeyAttributeGroupsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyAttributeGroupsRequestMethodGet) Sort ¶

func (*ByProjectKeyAttributeGroupsRequestMethodGet) Where ¶

func (*ByProjectKeyAttributeGroupsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyAttributeGroupsRequestMethodGet) WithTotal ¶

type ByProjectKeyAttributeGroupsRequestMethodGetInput ¶

type ByProjectKeyAttributeGroupsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyAttributeGroupsRequestMethodGetInput) Values ¶

type ByProjectKeyAttributeGroupsRequestMethodPost ¶

type ByProjectKeyAttributeGroupsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyAttributeGroupsRequestMethodPost) Dump ¶

func (r *ByProjectKeyAttributeGroupsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyAttributeGroupsRequestMethodPost) Execute ¶

func (*ByProjectKeyAttributeGroupsRequestMethodPost) Expand ¶

func (*ByProjectKeyAttributeGroupsRequestMethodPost) WithHeaders ¶

type ByProjectKeyAttributeGroupsRequestMethodPostInput ¶

type ByProjectKeyAttributeGroupsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyAttributeGroupsRequestMethodPostInput) Values ¶

type ByProjectKeyBusinessUnitsByIDRequestBuilder ¶

type ByProjectKeyBusinessUnitsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyBusinessUnitsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyBusinessUnitsByIDRequestBuilder) Get ¶

func (*ByProjectKeyBusinessUnitsByIDRequestBuilder) Post ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodDelete ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyBusinessUnitsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyBusinessUnitsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyBusinessUnitsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyBusinessUnitsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyBusinessUnitsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyBusinessUnitsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodDeleteInput ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyBusinessUnitsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodGet ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyBusinessUnitsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyBusinessUnitsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyBusinessUnitsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyBusinessUnitsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyBusinessUnitsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodGetInput ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyBusinessUnitsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodPost ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyBusinessUnitsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyBusinessUnitsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyBusinessUnitsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyBusinessUnitsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyBusinessUnitsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodPostInput ¶

type ByProjectKeyBusinessUnitsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyBusinessUnitsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestBuilder ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodGet ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodPost ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyBusinessUnitsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyBusinessUnitsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyBusinessUnitsRequestBuilder ¶

type ByProjectKeyBusinessUnitsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyBusinessUnitsRequestBuilder) Get ¶

func (*ByProjectKeyBusinessUnitsRequestBuilder) Post ¶

func (*ByProjectKeyBusinessUnitsRequestBuilder) WithId ¶

func (*ByProjectKeyBusinessUnitsRequestBuilder) WithKey ¶

type ByProjectKeyBusinessUnitsRequestMethodGet ¶

type ByProjectKeyBusinessUnitsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyBusinessUnitsRequestMethodGet) Dump ¶

func (r *ByProjectKeyBusinessUnitsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyBusinessUnitsRequestMethodGet) Execute ¶

func (*ByProjectKeyBusinessUnitsRequestMethodGet) Expand ¶

func (*ByProjectKeyBusinessUnitsRequestMethodGet) Limit ¶

func (*ByProjectKeyBusinessUnitsRequestMethodGet) Offset ¶

func (*ByProjectKeyBusinessUnitsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyBusinessUnitsRequestMethodGet) Sort ¶

func (*ByProjectKeyBusinessUnitsRequestMethodGet) Where ¶

func (*ByProjectKeyBusinessUnitsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyBusinessUnitsRequestMethodGet) WithTotal ¶

type ByProjectKeyBusinessUnitsRequestMethodGetInput ¶

type ByProjectKeyBusinessUnitsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyBusinessUnitsRequestMethodGetInput) Values ¶

type ByProjectKeyBusinessUnitsRequestMethodPost ¶

type ByProjectKeyBusinessUnitsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyBusinessUnitsRequestMethodPost) Dump ¶

func (r *ByProjectKeyBusinessUnitsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyBusinessUnitsRequestMethodPost) Execute ¶

func (*ByProjectKeyBusinessUnitsRequestMethodPost) Expand ¶

func (*ByProjectKeyBusinessUnitsRequestMethodPost) WithHeaders ¶

type ByProjectKeyBusinessUnitsRequestMethodPostInput ¶

type ByProjectKeyBusinessUnitsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyBusinessUnitsRequestMethodPostInput) Values ¶

type ByProjectKeyCartDiscountsByIDRequestBuilder ¶

type ByProjectKeyCartDiscountsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartDiscountsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyCartDiscountsByIDRequestBuilder) Get ¶

func (*ByProjectKeyCartDiscountsByIDRequestBuilder) Post ¶

type ByProjectKeyCartDiscountsByIDRequestMethodDelete ¶

type ByProjectKeyCartDiscountsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartDiscountsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyCartDiscountsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyCartDiscountsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyCartDiscountsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyCartDiscountsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyCartDiscountsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyCartDiscountsByIDRequestMethodDeleteInput ¶

type ByProjectKeyCartDiscountsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyCartDiscountsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyCartDiscountsByIDRequestMethodGet ¶

type ByProjectKeyCartDiscountsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartDiscountsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyCartDiscountsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCartDiscountsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyCartDiscountsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyCartDiscountsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyCartDiscountsByIDRequestMethodGetInput ¶

type ByProjectKeyCartDiscountsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCartDiscountsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyCartDiscountsByIDRequestMethodPost ¶

type ByProjectKeyCartDiscountsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartDiscountsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyCartDiscountsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCartDiscountsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyCartDiscountsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyCartDiscountsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyCartDiscountsByIDRequestMethodPostInput ¶

type ByProjectKeyCartDiscountsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCartDiscountsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestBuilder ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartDiscountsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodGet ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodPost ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyCartDiscountsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCartDiscountsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyCartDiscountsRequestBuilder ¶

type ByProjectKeyCartDiscountsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartDiscountsRequestBuilder) Get ¶

func (*ByProjectKeyCartDiscountsRequestBuilder) Post ¶

func (*ByProjectKeyCartDiscountsRequestBuilder) WithId ¶

func (*ByProjectKeyCartDiscountsRequestBuilder) WithKey ¶

type ByProjectKeyCartDiscountsRequestMethodGet ¶

type ByProjectKeyCartDiscountsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartDiscountsRequestMethodGet) Dump ¶

func (r *ByProjectKeyCartDiscountsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCartDiscountsRequestMethodGet) Execute ¶

func (*ByProjectKeyCartDiscountsRequestMethodGet) Expand ¶

func (*ByProjectKeyCartDiscountsRequestMethodGet) Limit ¶

func (*ByProjectKeyCartDiscountsRequestMethodGet) Offset ¶

func (*ByProjectKeyCartDiscountsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyCartDiscountsRequestMethodGet) Sort ¶

func (*ByProjectKeyCartDiscountsRequestMethodGet) Where ¶

func (*ByProjectKeyCartDiscountsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyCartDiscountsRequestMethodGet) WithTotal ¶

type ByProjectKeyCartDiscountsRequestMethodGetInput ¶

type ByProjectKeyCartDiscountsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyCartDiscountsRequestMethodGetInput) Values ¶

type ByProjectKeyCartDiscountsRequestMethodPost ¶

type ByProjectKeyCartDiscountsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartDiscountsRequestMethodPost) Dump ¶

func (r *ByProjectKeyCartDiscountsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCartDiscountsRequestMethodPost) Execute ¶

func (*ByProjectKeyCartDiscountsRequestMethodPost) Expand ¶

func (*ByProjectKeyCartDiscountsRequestMethodPost) WithHeaders ¶

type ByProjectKeyCartDiscountsRequestMethodPostInput ¶

type ByProjectKeyCartDiscountsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCartDiscountsRequestMethodPostInput) Values ¶

type ByProjectKeyCartsByIDRequestBuilder ¶

type ByProjectKeyCartsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyCartsByIDRequestBuilder) Get ¶

* * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

func (*ByProjectKeyCartsByIDRequestBuilder) Post ¶

type ByProjectKeyCartsByIDRequestMethodDelete ¶

type ByProjectKeyCartsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyCartsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyCartsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyCartsByIDRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyCartsByIDRequestMethodDelete) Execute(ctx context.Context) (result *Cart, err error)

func (*ByProjectKeyCartsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyCartsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyCartsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyCartsByIDRequestMethodDeleteInput ¶

type ByProjectKeyCartsByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyCartsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyCartsByIDRequestMethodGet ¶

type ByProjectKeyCartsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyCartsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCartsByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyCartsByIDRequestMethodGet) Execute(ctx context.Context) (result *Cart, err error)

* * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

func (*ByProjectKeyCartsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyCartsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyCartsByIDRequestMethodGetInput ¶

type ByProjectKeyCartsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCartsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyCartsByIDRequestMethodPost ¶

type ByProjectKeyCartsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyCartsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCartsByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyCartsByIDRequestMethodPost) Execute(ctx context.Context) (result *Cart, err error)

func (*ByProjectKeyCartsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyCartsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyCartsByIDRequestMethodPostInput ¶

type ByProjectKeyCartsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCartsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyCartsCustomerIdByCustomerIdRequestBuilder ¶

type ByProjectKeyCartsCustomerIdByCustomerIdRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsCustomerIdByCustomerIdRequestBuilder) Get ¶

* * Retrieves the recently modified active Cart of a Customer with CartOrigin(ctp:api:type:CartOrigin) `Customer`. If no active Cart exists, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. * * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

type ByProjectKeyCartsCustomerIdByCustomerIdRequestMethodGet ¶

type ByProjectKeyCartsCustomerIdByCustomerIdRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsCustomerIdByCustomerIdRequestMethodGet) Dump ¶

func (*ByProjectKeyCartsCustomerIdByCustomerIdRequestMethodGet) Execute ¶

* * Retrieves the recently modified active Cart of a Customer with CartOrigin(ctp:api:type:CartOrigin) `Customer`. If no active Cart exists, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. * * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

func (*ByProjectKeyCartsCustomerIdByCustomerIdRequestMethodGet) Expand ¶

func (*ByProjectKeyCartsCustomerIdByCustomerIdRequestMethodGet) WithHeaders ¶

type ByProjectKeyCartsCustomerIdByCustomerIdRequestMethodGetInput ¶

type ByProjectKeyCartsCustomerIdByCustomerIdRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCartsCustomerIdByCustomerIdRequestMethodGetInput) Values ¶

type ByProjectKeyCartsKeyByKeyRequestBuilder ¶

type ByProjectKeyCartsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyCartsKeyByKeyRequestBuilder) Get ¶

* * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

func (*ByProjectKeyCartsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyCartsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyCartsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyCartsKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyCartsKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyCartsKeyByKeyRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyCartsKeyByKeyRequestMethodDelete) Execute(ctx context.Context) (result *Cart, err error)

func (*ByProjectKeyCartsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyCartsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyCartsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyCartsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyCartsKeyByKeyRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyCartsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyCartsKeyByKeyRequestMethodGet ¶

type ByProjectKeyCartsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyCartsKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCartsKeyByKeyRequestMethodGet) Execute ¶

func (rb *ByProjectKeyCartsKeyByKeyRequestMethodGet) Execute(ctx context.Context) (result *Cart, err error)

* * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

func (*ByProjectKeyCartsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyCartsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyCartsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyCartsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCartsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyCartsKeyByKeyRequestMethodPost ¶

type ByProjectKeyCartsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyCartsKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCartsKeyByKeyRequestMethodPost) Execute ¶

func (rb *ByProjectKeyCartsKeyByKeyRequestMethodPost) Execute(ctx context.Context) (result *Cart, err error)

func (*ByProjectKeyCartsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyCartsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyCartsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyCartsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCartsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyCartsReplicateRequestBuilder ¶

type ByProjectKeyCartsReplicateRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsReplicateRequestBuilder) Post ¶

* * Creates a new Cart by replicating an existing Cart or Order. Can be useful in cases where a customer wants to cancel a recent order to make some changes or reorder a previous order. * * The replicated Cart preserves Customer information, Line Items and Custom Line Items, Custom Fields, Discount Codes, and other settings of the Cart or Order. If the Line Items become invalid, for example, due to removed Products or Prices, they are removed from the new Cart. If the Customer switches to another Customer Group, the new Cart is updated with the new value. It has up-to-date Tax Rates, Prices, and Line Item product data and is in `Active` CartState(ctp:api:type:CartState). * * The new Cart does not contain Payments or Deliveries. The State(ctp:api:type:ItemState) of Line Items and Custom Line Items is reset to `initial`. *

type ByProjectKeyCartsReplicateRequestMethodPost ¶

type ByProjectKeyCartsReplicateRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsReplicateRequestMethodPost) Dump ¶

func (r *ByProjectKeyCartsReplicateRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCartsReplicateRequestMethodPost) Execute ¶

func (rb *ByProjectKeyCartsReplicateRequestMethodPost) Execute(ctx context.Context) (result *Cart, err error)

* * Creates a new Cart by replicating an existing Cart or Order. Can be useful in cases where a customer wants to cancel a recent order to make some changes or reorder a previous order. * * The replicated Cart preserves Customer information, Line Items and Custom Line Items, Custom Fields, Discount Codes, and other settings of the Cart or Order. If the Line Items become invalid, for example, due to removed Products or Prices, they are removed from the new Cart. If the Customer switches to another Customer Group, the new Cart is updated with the new value. It has up-to-date Tax Rates, Prices, and Line Item product data and is in `Active` CartState(ctp:api:type:CartState). * * The new Cart does not contain Payments or Deliveries. The State(ctp:api:type:ItemState) of Line Items and Custom Line Items is reset to `initial`. *

func (*ByProjectKeyCartsReplicateRequestMethodPost) WithHeaders ¶

type ByProjectKeyCartsRequestBuilder ¶

type ByProjectKeyCartsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsRequestBuilder) Get ¶

func (*ByProjectKeyCartsRequestBuilder) Post ¶

* * Creating a Cart fails with an [InvalidOperation](ctp:api:type:InvalidOperationError) error if the * ShippingMethod(ctp:api:type:ShippingMethod) referenced in the CartDraft * has a `predicate` that does not match the Cart. *

func (*ByProjectKeyCartsRequestBuilder) Replicate ¶

func (*ByProjectKeyCartsRequestBuilder) WithCustomerId ¶

func (*ByProjectKeyCartsRequestBuilder) WithId ¶

func (*ByProjectKeyCartsRequestBuilder) WithKey ¶

type ByProjectKeyCartsRequestMethodGet ¶

type ByProjectKeyCartsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsRequestMethodGet) Dump ¶

func (r *ByProjectKeyCartsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCartsRequestMethodGet) Execute ¶

func (*ByProjectKeyCartsRequestMethodGet) Expand ¶

func (*ByProjectKeyCartsRequestMethodGet) Limit ¶

func (*ByProjectKeyCartsRequestMethodGet) Offset ¶

func (*ByProjectKeyCartsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyCartsRequestMethodGet) Sort ¶

func (*ByProjectKeyCartsRequestMethodGet) Where ¶

func (*ByProjectKeyCartsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyCartsRequestMethodGet) WithQueryParams ¶

func (*ByProjectKeyCartsRequestMethodGet) WithTotal ¶

type ByProjectKeyCartsRequestMethodGetInput ¶

type ByProjectKeyCartsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyCartsRequestMethodGetInput) Values ¶

type ByProjectKeyCartsRequestMethodPost ¶

type ByProjectKeyCartsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCartsRequestMethodPost) Dump ¶

func (r *ByProjectKeyCartsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCartsRequestMethodPost) Execute ¶

func (rb *ByProjectKeyCartsRequestMethodPost) Execute(ctx context.Context) (result *Cart, err error)

* * Creating a Cart fails with an [InvalidOperation](ctp:api:type:InvalidOperationError) error if the * ShippingMethod(ctp:api:type:ShippingMethod) referenced in the CartDraft * has a `predicate` that does not match the Cart. *

func (*ByProjectKeyCartsRequestMethodPost) Expand ¶

func (*ByProjectKeyCartsRequestMethodPost) WithHeaders ¶

func (*ByProjectKeyCartsRequestMethodPost) WithQueryParams ¶

type ByProjectKeyCartsRequestMethodPostInput ¶

type ByProjectKeyCartsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCartsRequestMethodPostInput) Values ¶

type ByProjectKeyCategoriesByIDRequestBuilder ¶

type ByProjectKeyCategoriesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCategoriesByIDRequestBuilder) Delete ¶

* * Either the [scope](/../api/scopes) `manage_products:{projectKey}` or `manage_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesByIDRequestBuilder) Get ¶

* * Either the [scope](/../api/scopes) `view_products:{projectKey}` or `view_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesByIDRequestBuilder) Post ¶

* * Either the [scope](/../api/scopes) `manage_products:{projectKey}` or `manage_categories:{projectKey}` is required. *

type ByProjectKeyCategoriesByIDRequestMethodDelete ¶

type ByProjectKeyCategoriesByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCategoriesByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyCategoriesByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyCategoriesByIDRequestMethodDelete) Execute ¶

* * Either the [scope](/../api/scopes) `manage_products:{projectKey}` or `manage_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyCategoriesByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyCategoriesByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyCategoriesByIDRequestMethodDeleteInput ¶

type ByProjectKeyCategoriesByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyCategoriesByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyCategoriesByIDRequestMethodGet ¶

type ByProjectKeyCategoriesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCategoriesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyCategoriesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCategoriesByIDRequestMethodGet) Execute ¶

* * Either the [scope](/../api/scopes) `view_products:{projectKey}` or `view_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyCategoriesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyCategoriesByIDRequestMethodGetInput ¶

type ByProjectKeyCategoriesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCategoriesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyCategoriesByIDRequestMethodPost ¶

type ByProjectKeyCategoriesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCategoriesByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyCategoriesByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCategoriesByIDRequestMethodPost) Execute ¶

* * Either the [scope](/../api/scopes) `manage_products:{projectKey}` or `manage_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyCategoriesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyCategoriesByIDRequestMethodPostInput ¶

type ByProjectKeyCategoriesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCategoriesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyCategoriesKeyByKeyRequestBuilder ¶

type ByProjectKeyCategoriesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCategoriesKeyByKeyRequestBuilder) Delete ¶

* * Either the [scope](/../api/scopes) `manage_products:{projectKey}` or `manage_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesKeyByKeyRequestBuilder) Get ¶

* * Either the [scope](/../api/scopes) `view_products:{projectKey}` or `view_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesKeyByKeyRequestBuilder) Post ¶

* * Either the [scope](/../api/scopes) `manage_products:{projectKey}` or `manage_categories:{projectKey}` is required. *

type ByProjectKeyCategoriesKeyByKeyRequestMethodDelete ¶

type ByProjectKeyCategoriesKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodDelete) Execute ¶

* * Either the [scope](/../api/scopes) `manage_products:{projectKey}` or `manage_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyCategoriesKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyCategoriesKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyCategoriesKeyByKeyRequestMethodGet ¶

type ByProjectKeyCategoriesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyCategoriesKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodGet) Execute ¶

* * Either the [scope](/../api/scopes) `view_products:{projectKey}` or `view_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyCategoriesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyCategoriesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyCategoriesKeyByKeyRequestMethodPost ¶

type ByProjectKeyCategoriesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyCategoriesKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodPost) Execute ¶

* * Either the [scope](/../api/scopes) `manage_products:{projectKey}` or `manage_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyCategoriesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyCategoriesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCategoriesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyCategoriesRequestBuilder ¶

type ByProjectKeyCategoriesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCategoriesRequestBuilder) Get ¶

* * Either the [scope](/../api/scopes) `view_products:{projectKey}` or `view_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesRequestBuilder) Post ¶

* * Either the [scope](/../api/scopes) `manage_products:{projectKey}` or `manage_categories:{projectKey}` is required. * * Creating a Category produces the [CategoryCreated](ctp:api:type:CategoryCreatedMessage) Message. *

func (*ByProjectKeyCategoriesRequestBuilder) WithId ¶

func (*ByProjectKeyCategoriesRequestBuilder) WithKey ¶

type ByProjectKeyCategoriesRequestMethodGet ¶

type ByProjectKeyCategoriesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCategoriesRequestMethodGet) Dump ¶

func (r *ByProjectKeyCategoriesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCategoriesRequestMethodGet) Execute ¶

* * Either the [scope](/../api/scopes) `view_products:{projectKey}` or `view_categories:{projectKey}` is required. *

func (*ByProjectKeyCategoriesRequestMethodGet) Expand ¶

func (*ByProjectKeyCategoriesRequestMethodGet) Limit ¶

func (*ByProjectKeyCategoriesRequestMethodGet) Offset ¶

func (*ByProjectKeyCategoriesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyCategoriesRequestMethodGet) Sort ¶

func (*ByProjectKeyCategoriesRequestMethodGet) Where ¶

func (*ByProjectKeyCategoriesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyCategoriesRequestMethodGet) WithTotal ¶

type ByProjectKeyCategoriesRequestMethodGetInput ¶

type ByProjectKeyCategoriesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyCategoriesRequestMethodGetInput) Values ¶

type ByProjectKeyCategoriesRequestMethodPost ¶

type ByProjectKeyCategoriesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCategoriesRequestMethodPost) Dump ¶

func (r *ByProjectKeyCategoriesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCategoriesRequestMethodPost) Execute ¶

func (rb *ByProjectKeyCategoriesRequestMethodPost) Execute(ctx context.Context) (result *Category, err error)

* * Either the [scope](/../api/scopes) `manage_products:{projectKey}` or `manage_categories:{projectKey}` is required. * * Creating a Category produces the [CategoryCreated](ctp:api:type:CategoryCreatedMessage) Message. *

func (*ByProjectKeyCategoriesRequestMethodPost) Expand ¶

func (*ByProjectKeyCategoriesRequestMethodPost) WithHeaders ¶

type ByProjectKeyCategoriesRequestMethodPostInput ¶

type ByProjectKeyCategoriesRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCategoriesRequestMethodPostInput) Values ¶

type ByProjectKeyChannelsByIDRequestBuilder ¶

type ByProjectKeyChannelsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyChannelsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyChannelsByIDRequestBuilder) Get ¶

func (*ByProjectKeyChannelsByIDRequestBuilder) Post ¶

type ByProjectKeyChannelsByIDRequestMethodDelete ¶

type ByProjectKeyChannelsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyChannelsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyChannelsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyChannelsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyChannelsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyChannelsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyChannelsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyChannelsByIDRequestMethodDeleteInput ¶

type ByProjectKeyChannelsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyChannelsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyChannelsByIDRequestMethodGet ¶

type ByProjectKeyChannelsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyChannelsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyChannelsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyChannelsByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyChannelsByIDRequestMethodGet) Execute(ctx context.Context) (result *Channel, err error)

func (*ByProjectKeyChannelsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyChannelsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyChannelsByIDRequestMethodGetInput ¶

type ByProjectKeyChannelsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyChannelsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyChannelsByIDRequestMethodPost ¶

type ByProjectKeyChannelsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyChannelsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyChannelsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyChannelsByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyChannelsByIDRequestMethodPost) Execute(ctx context.Context) (result *Channel, err error)

func (*ByProjectKeyChannelsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyChannelsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyChannelsByIDRequestMethodPostInput ¶

type ByProjectKeyChannelsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyChannelsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyChannelsRequestBuilder ¶

type ByProjectKeyChannelsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyChannelsRequestBuilder) Get ¶

func (*ByProjectKeyChannelsRequestBuilder) Post ¶

func (*ByProjectKeyChannelsRequestBuilder) WithId ¶

type ByProjectKeyChannelsRequestMethodGet ¶

type ByProjectKeyChannelsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyChannelsRequestMethodGet) Dump ¶

func (r *ByProjectKeyChannelsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyChannelsRequestMethodGet) Execute ¶

func (*ByProjectKeyChannelsRequestMethodGet) Expand ¶

func (*ByProjectKeyChannelsRequestMethodGet) Limit ¶

func (*ByProjectKeyChannelsRequestMethodGet) Offset ¶

func (*ByProjectKeyChannelsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyChannelsRequestMethodGet) Sort ¶

func (*ByProjectKeyChannelsRequestMethodGet) Where ¶

func (*ByProjectKeyChannelsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyChannelsRequestMethodGet) WithTotal ¶

type ByProjectKeyChannelsRequestMethodGetInput ¶

type ByProjectKeyChannelsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyChannelsRequestMethodGetInput) Values ¶

type ByProjectKeyChannelsRequestMethodPost ¶

type ByProjectKeyChannelsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyChannelsRequestMethodPost) Dump ¶

func (r *ByProjectKeyChannelsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyChannelsRequestMethodPost) Execute ¶

func (rb *ByProjectKeyChannelsRequestMethodPost) Execute(ctx context.Context) (result *Channel, err error)

func (*ByProjectKeyChannelsRequestMethodPost) Expand ¶

func (*ByProjectKeyChannelsRequestMethodPost) WithHeaders ¶

type ByProjectKeyChannelsRequestMethodPostInput ¶

type ByProjectKeyChannelsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyChannelsRequestMethodPostInput) Values ¶

type ByProjectKeyCustomObjectsByContainerByKeyRequestBuilder ¶

type ByProjectKeyCustomObjectsByContainerByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestBuilder) Get ¶

type ByProjectKeyCustomObjectsByContainerByKeyRequestMethodDelete ¶

type ByProjectKeyCustomObjectsByContainerByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyCustomObjectsByContainerByKeyRequestMethodDeleteInput ¶

type ByProjectKeyCustomObjectsByContainerByKeyRequestMethodDeleteInput struct {
	Version     *int
	Expand      []string
	DataErasure *bool
}

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyCustomObjectsByContainerByKeyRequestMethodGet ¶

type ByProjectKeyCustomObjectsByContainerByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyCustomObjectsByContainerByKeyRequestMethodGetInput ¶

type ByProjectKeyCustomObjectsByContainerByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCustomObjectsByContainerByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyCustomObjectsByContainerRequestBuilder ¶

type ByProjectKeyCustomObjectsByContainerRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomObjectsByContainerRequestBuilder) Get ¶

type ByProjectKeyCustomObjectsByContainerRequestMethodGet ¶

type ByProjectKeyCustomObjectsByContainerRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomObjectsByContainerRequestMethodGet) Dump ¶

func (*ByProjectKeyCustomObjectsByContainerRequestMethodGet) Execute ¶

func (*ByProjectKeyCustomObjectsByContainerRequestMethodGet) Expand ¶

func (*ByProjectKeyCustomObjectsByContainerRequestMethodGet) Limit ¶

func (*ByProjectKeyCustomObjectsByContainerRequestMethodGet) Offset ¶

func (*ByProjectKeyCustomObjectsByContainerRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyCustomObjectsByContainerRequestMethodGet) Sort ¶

func (*ByProjectKeyCustomObjectsByContainerRequestMethodGet) Where ¶

func (*ByProjectKeyCustomObjectsByContainerRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyCustomObjectsByContainerRequestMethodGet) WithTotal ¶

type ByProjectKeyCustomObjectsByContainerRequestMethodGetInput ¶

type ByProjectKeyCustomObjectsByContainerRequestMethodGetInput struct {
	Sort         []string
	Where        []string
	Expand       []string
	PredicateVar map[string][]string
	Limit        *int
	Offset       *int
	WithTotal    *bool
}

func (*ByProjectKeyCustomObjectsByContainerRequestMethodGetInput) Values ¶

type ByProjectKeyCustomObjectsRequestBuilder ¶

type ByProjectKeyCustomObjectsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomObjectsRequestBuilder) Get ¶

* * For performance reasons, it is highly advisable to query for Custom Objects in a container by using the `container` field in the `where` predicate. *

func (*ByProjectKeyCustomObjectsRequestBuilder) Post ¶

* * If an object with the given container/key exists, the object will be replaced with the new value and the version is incremented. * If the request contains a version and an object with the given container/key, then the version must match the version of the existing object. Concurrent updates to the same Custom Object returns a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error even if the version is not provided. * * Fields with `null` values will **not be saved**. *

func (*ByProjectKeyCustomObjectsRequestBuilder) WithContainer ¶

func (*ByProjectKeyCustomObjectsRequestBuilder) WithContainerAndKey ¶

type ByProjectKeyCustomObjectsRequestMethodGet ¶

type ByProjectKeyCustomObjectsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomObjectsRequestMethodGet) Dump ¶

func (r *ByProjectKeyCustomObjectsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCustomObjectsRequestMethodGet) Execute ¶

* * For performance reasons, it is highly advisable to query for Custom Objects in a container by using the `container` field in the `where` predicate. *

func (*ByProjectKeyCustomObjectsRequestMethodGet) Expand ¶

func (*ByProjectKeyCustomObjectsRequestMethodGet) Limit ¶

func (*ByProjectKeyCustomObjectsRequestMethodGet) Offset ¶

func (*ByProjectKeyCustomObjectsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyCustomObjectsRequestMethodGet) Sort ¶

func (*ByProjectKeyCustomObjectsRequestMethodGet) Where ¶

func (*ByProjectKeyCustomObjectsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyCustomObjectsRequestMethodGet) WithTotal ¶

type ByProjectKeyCustomObjectsRequestMethodGetInput ¶

type ByProjectKeyCustomObjectsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyCustomObjectsRequestMethodGetInput) Values ¶

type ByProjectKeyCustomObjectsRequestMethodPost ¶

type ByProjectKeyCustomObjectsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomObjectsRequestMethodPost) Dump ¶

func (r *ByProjectKeyCustomObjectsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCustomObjectsRequestMethodPost) Execute ¶

* * If an object with the given container/key exists, the object will be replaced with the new value and the version is incremented. * If the request contains a version and an object with the given container/key, then the version must match the version of the existing object. Concurrent updates to the same Custom Object returns a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error even if the version is not provided. * * Fields with `null` values will **not be saved**. *

func (*ByProjectKeyCustomObjectsRequestMethodPost) Expand ¶

func (*ByProjectKeyCustomObjectsRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomObjectsRequestMethodPostInput ¶

type ByProjectKeyCustomObjectsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCustomObjectsRequestMethodPostInput) Values ¶

type ByProjectKeyCustomerGroupsByIDRequestBuilder ¶

type ByProjectKeyCustomerGroupsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomerGroupsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyCustomerGroupsByIDRequestBuilder) Get ¶

func (*ByProjectKeyCustomerGroupsByIDRequestBuilder) Post ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodDelete ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomerGroupsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyCustomerGroupsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyCustomerGroupsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyCustomerGroupsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyCustomerGroupsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodDeleteInput ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyCustomerGroupsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodGet ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomerGroupsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyCustomerGroupsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCustomerGroupsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyCustomerGroupsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyCustomerGroupsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodGetInput ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCustomerGroupsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodPost ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomerGroupsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyCustomerGroupsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCustomerGroupsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyCustomerGroupsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyCustomerGroupsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodPostInput ¶

type ByProjectKeyCustomerGroupsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCustomerGroupsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestBuilder ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodGet ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodPost ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyCustomerGroupsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCustomerGroupsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyCustomerGroupsRequestBuilder ¶

type ByProjectKeyCustomerGroupsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomerGroupsRequestBuilder) Get ¶

func (*ByProjectKeyCustomerGroupsRequestBuilder) Post ¶

func (*ByProjectKeyCustomerGroupsRequestBuilder) WithId ¶

func (*ByProjectKeyCustomerGroupsRequestBuilder) WithKey ¶

type ByProjectKeyCustomerGroupsRequestMethodGet ¶

type ByProjectKeyCustomerGroupsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomerGroupsRequestMethodGet) Dump ¶

func (r *ByProjectKeyCustomerGroupsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCustomerGroupsRequestMethodGet) Execute ¶

func (*ByProjectKeyCustomerGroupsRequestMethodGet) Expand ¶

func (*ByProjectKeyCustomerGroupsRequestMethodGet) Limit ¶

func (*ByProjectKeyCustomerGroupsRequestMethodGet) Offset ¶

func (*ByProjectKeyCustomerGroupsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyCustomerGroupsRequestMethodGet) Sort ¶

func (*ByProjectKeyCustomerGroupsRequestMethodGet) Where ¶

func (*ByProjectKeyCustomerGroupsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyCustomerGroupsRequestMethodGet) WithTotal ¶

type ByProjectKeyCustomerGroupsRequestMethodGetInput ¶

type ByProjectKeyCustomerGroupsRequestMethodGetInput struct {
	Where        []string
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	PredicateVar map[string][]string
}

func (*ByProjectKeyCustomerGroupsRequestMethodGetInput) Values ¶

type ByProjectKeyCustomerGroupsRequestMethodPost ¶

type ByProjectKeyCustomerGroupsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomerGroupsRequestMethodPost) Dump ¶

func (r *ByProjectKeyCustomerGroupsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCustomerGroupsRequestMethodPost) Execute ¶

func (*ByProjectKeyCustomerGroupsRequestMethodPost) Expand ¶

func (*ByProjectKeyCustomerGroupsRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomerGroupsRequestMethodPostInput ¶

type ByProjectKeyCustomerGroupsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCustomerGroupsRequestMethodPostInput) Values ¶

type ByProjectKeyCustomersByIDRequestBuilder ¶

type ByProjectKeyCustomersByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersByIDRequestBuilder) Delete ¶

* * Deleting a Customer produces the [CustomerDeleted](ctp:api:type:CustomerDeletedMessage) Message. *

func (*ByProjectKeyCustomersByIDRequestBuilder) Get ¶

func (*ByProjectKeyCustomersByIDRequestBuilder) Post ¶

type ByProjectKeyCustomersByIDRequestMethodDelete ¶

type ByProjectKeyCustomersByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyCustomersByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyCustomersByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyCustomersByIDRequestMethodDelete) Execute ¶

* * Deleting a Customer produces the [CustomerDeleted](ctp:api:type:CustomerDeletedMessage) Message. *

func (*ByProjectKeyCustomersByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyCustomersByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyCustomersByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyCustomersByIDRequestMethodDeleteInput ¶

type ByProjectKeyCustomersByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyCustomersByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyCustomersByIDRequestMethodGet ¶

type ByProjectKeyCustomersByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyCustomersByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCustomersByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyCustomersByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyCustomersByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyCustomersByIDRequestMethodGetInput ¶

type ByProjectKeyCustomersByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCustomersByIDRequestMethodGetInput) Values ¶

type ByProjectKeyCustomersByIDRequestMethodPost ¶

type ByProjectKeyCustomersByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyCustomersByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCustomersByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyCustomersByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyCustomersByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomersByIDRequestMethodPostInput ¶

type ByProjectKeyCustomersByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCustomersByIDRequestMethodPostInput) Values ¶

type ByProjectKeyCustomersEmailConfirmRequestBuilder ¶

type ByProjectKeyCustomersEmailConfirmRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersEmailConfirmRequestBuilder) Post ¶

* * Verifying the email of the Customer produces the [CustomerEmailVerified](ctp:api:type:CustomerEmailVerifiedMessage) Message. *

type ByProjectKeyCustomersEmailConfirmRequestMethodPost ¶

type ByProjectKeyCustomersEmailConfirmRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersEmailConfirmRequestMethodPost) Dump ¶

func (*ByProjectKeyCustomersEmailConfirmRequestMethodPost) Execute ¶

* * Verifying the email of the Customer produces the [CustomerEmailVerified](ctp:api:type:CustomerEmailVerifiedMessage) Message. *

func (*ByProjectKeyCustomersEmailConfirmRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomersEmailTokenByEmailTokenRequestBuilder ¶

type ByProjectKeyCustomersEmailTokenByEmailTokenRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersEmailTokenByEmailTokenRequestBuilder) Get ¶

type ByProjectKeyCustomersEmailTokenByEmailTokenRequestMethodGet ¶

type ByProjectKeyCustomersEmailTokenByEmailTokenRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersEmailTokenByEmailTokenRequestMethodGet) Dump ¶

func (*ByProjectKeyCustomersEmailTokenByEmailTokenRequestMethodGet) Execute ¶

func (*ByProjectKeyCustomersEmailTokenByEmailTokenRequestMethodGet) Expand ¶

func (*ByProjectKeyCustomersEmailTokenByEmailTokenRequestMethodGet) WithHeaders ¶

type ByProjectKeyCustomersEmailTokenByEmailTokenRequestMethodGetInput ¶

type ByProjectKeyCustomersEmailTokenByEmailTokenRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCustomersEmailTokenByEmailTokenRequestMethodGetInput) Values ¶

type ByProjectKeyCustomersEmailTokenRequestBuilder ¶

type ByProjectKeyCustomersEmailTokenRequestBuilder struct {
	// contains filtered or unexported fields
}

type ByProjectKeyCustomersEmailTokenRequestMethodPost ¶

type ByProjectKeyCustomersEmailTokenRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersEmailTokenRequestMethodPost) Dump ¶

func (r *ByProjectKeyCustomersEmailTokenRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCustomersEmailTokenRequestMethodPost) Execute ¶

func (*ByProjectKeyCustomersEmailTokenRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomersKeyByKeyRequestBuilder ¶

type ByProjectKeyCustomersKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersKeyByKeyRequestBuilder) Delete ¶

* * Deleting a Customer produces the [CustomerDeleted](ctp:api:type:CustomerDeletedMessage) Message. *

func (*ByProjectKeyCustomersKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyCustomersKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodDelete ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyCustomersKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyCustomersKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyCustomersKeyByKeyRequestMethodDelete) Execute ¶

* * Deleting a Customer produces the [CustomerDeleted](ctp:api:type:CustomerDeletedMessage) Message. *

func (*ByProjectKeyCustomersKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyCustomersKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyCustomersKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyCustomersKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodGet ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyCustomersKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCustomersKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyCustomersKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyCustomersKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCustomersKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodPost ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyCustomersKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCustomersKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyCustomersKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyCustomersKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyCustomersKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCustomersKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyCustomersPasswordRequestBuilder ¶

type ByProjectKeyCustomersPasswordRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersPasswordRequestBuilder) Post ¶

* * Changing the password produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=false`. *

type ByProjectKeyCustomersPasswordRequestMethodPost ¶

type ByProjectKeyCustomersPasswordRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersPasswordRequestMethodPost) Dump ¶

func (r *ByProjectKeyCustomersPasswordRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCustomersPasswordRequestMethodPost) Execute ¶

* * Changing the password produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=false`. *

func (*ByProjectKeyCustomersPasswordRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomersPasswordResetRequestBuilder ¶

type ByProjectKeyCustomersPasswordResetRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersPasswordResetRequestBuilder) Post ¶

* * Resetting the password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=true`. *

type ByProjectKeyCustomersPasswordResetRequestMethodPost ¶

type ByProjectKeyCustomersPasswordResetRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersPasswordResetRequestMethodPost) Dump ¶

func (*ByProjectKeyCustomersPasswordResetRequestMethodPost) Execute ¶

* * Resetting the password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=true`. *

func (*ByProjectKeyCustomersPasswordResetRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestBuilder ¶

type ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestBuilder) Get ¶

type ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet ¶

type ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet) Dump ¶

func (*ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet) Execute ¶

func (*ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet) Expand ¶

func (*ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet) WithHeaders ¶

type ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestMethodGetInput ¶

type ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyCustomersPasswordTokenByPasswordTokenRequestMethodGetInput) Values ¶

type ByProjectKeyCustomersPasswordTokenRequestBuilder ¶

type ByProjectKeyCustomersPasswordTokenRequestBuilder struct {
	// contains filtered or unexported fields
}

type ByProjectKeyCustomersPasswordTokenRequestMethodPost ¶

type ByProjectKeyCustomersPasswordTokenRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersPasswordTokenRequestMethodPost) Dump ¶

func (*ByProjectKeyCustomersPasswordTokenRequestMethodPost) Execute ¶

func (*ByProjectKeyCustomersPasswordTokenRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomersRequestBuilder ¶

type ByProjectKeyCustomersRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersRequestBuilder) EmailConfirm ¶

func (*ByProjectKeyCustomersRequestBuilder) EmailToken ¶

func (*ByProjectKeyCustomersRequestBuilder) Get ¶

func (*ByProjectKeyCustomersRequestBuilder) Password ¶

func (*ByProjectKeyCustomersRequestBuilder) PasswordReset ¶

func (*ByProjectKeyCustomersRequestBuilder) PasswordToken ¶

func (*ByProjectKeyCustomersRequestBuilder) Post ¶

* * If the `anonymousCart` field is set on the CustomerDraft(ctp:api:type:CustomerDraft), then the newly created Customer will be assigned to that Cart(ctp:api:type:Cart). * Similarly, if the `anonymousId` field is set, the Customer will be set on all [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [ShoppingLists](ctp:api:type:ShoppingList) and [Payments](ctp:api:type:Payment) with the same `anonymousId`. * Creating a Customer produces the [CustomerCreated](ctp:api:type:CustomerCreatedMessage) Message. *

func (*ByProjectKeyCustomersRequestBuilder) WithEmailToken ¶

func (*ByProjectKeyCustomersRequestBuilder) WithId ¶

func (*ByProjectKeyCustomersRequestBuilder) WithKey ¶

func (*ByProjectKeyCustomersRequestBuilder) WithPasswordToken ¶

type ByProjectKeyCustomersRequestMethodGet ¶

type ByProjectKeyCustomersRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersRequestMethodGet) Dump ¶

func (r *ByProjectKeyCustomersRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyCustomersRequestMethodGet) Execute ¶

func (*ByProjectKeyCustomersRequestMethodGet) Expand ¶

func (*ByProjectKeyCustomersRequestMethodGet) Limit ¶

func (*ByProjectKeyCustomersRequestMethodGet) Offset ¶

func (*ByProjectKeyCustomersRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyCustomersRequestMethodGet) Sort ¶

func (*ByProjectKeyCustomersRequestMethodGet) Where ¶

func (*ByProjectKeyCustomersRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyCustomersRequestMethodGet) WithTotal ¶

type ByProjectKeyCustomersRequestMethodGetInput ¶

type ByProjectKeyCustomersRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyCustomersRequestMethodGetInput) Values ¶

type ByProjectKeyCustomersRequestMethodPost ¶

type ByProjectKeyCustomersRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyCustomersRequestMethodPost) Dump ¶

func (r *ByProjectKeyCustomersRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyCustomersRequestMethodPost) Execute ¶

* * If the `anonymousCart` field is set on the CustomerDraft(ctp:api:type:CustomerDraft), then the newly created Customer will be assigned to that Cart(ctp:api:type:Cart). * Similarly, if the `anonymousId` field is set, the Customer will be set on all [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [ShoppingLists](ctp:api:type:ShoppingList) and [Payments](ctp:api:type:Payment) with the same `anonymousId`. * Creating a Customer produces the [CustomerCreated](ctp:api:type:CustomerCreatedMessage) Message. *

func (*ByProjectKeyCustomersRequestMethodPost) Expand ¶

func (*ByProjectKeyCustomersRequestMethodPost) WithHeaders ¶

type ByProjectKeyCustomersRequestMethodPostInput ¶

type ByProjectKeyCustomersRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyCustomersRequestMethodPostInput) Values ¶

type ByProjectKeyDiscountCodesByIDRequestBuilder ¶

type ByProjectKeyDiscountCodesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDiscountCodesByIDRequestBuilder) Delete ¶

* * Deprecated scope: `manage_orders:{projectKey}`

func (*ByProjectKeyDiscountCodesByIDRequestBuilder) Get ¶

* * Deprecated scope: `view_orders:{projectKey}`

func (*ByProjectKeyDiscountCodesByIDRequestBuilder) Post ¶

* * Deprecated scope: `manage_orders:{projectKey}`

type ByProjectKeyDiscountCodesByIDRequestMethodDelete ¶

type ByProjectKeyDiscountCodesByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDiscountCodesByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyDiscountCodesByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyDiscountCodesByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyDiscountCodesByIDRequestMethodDelete) Execute ¶

* * Deprecated scope: `manage_orders:{projectKey}`

func (*ByProjectKeyDiscountCodesByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyDiscountCodesByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyDiscountCodesByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyDiscountCodesByIDRequestMethodDeleteInput ¶

type ByProjectKeyDiscountCodesByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyDiscountCodesByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyDiscountCodesByIDRequestMethodGet ¶

type ByProjectKeyDiscountCodesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDiscountCodesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyDiscountCodesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyDiscountCodesByIDRequestMethodGet) Execute ¶

* * Deprecated scope: `view_orders:{projectKey}`

func (*ByProjectKeyDiscountCodesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyDiscountCodesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyDiscountCodesByIDRequestMethodGetInput ¶

type ByProjectKeyDiscountCodesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyDiscountCodesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyDiscountCodesByIDRequestMethodPost ¶

type ByProjectKeyDiscountCodesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDiscountCodesByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyDiscountCodesByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyDiscountCodesByIDRequestMethodPost) Execute ¶

* * Deprecated scope: `manage_orders:{projectKey}`

func (*ByProjectKeyDiscountCodesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyDiscountCodesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyDiscountCodesByIDRequestMethodPostInput ¶

type ByProjectKeyDiscountCodesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyDiscountCodesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyDiscountCodesRequestBuilder ¶

type ByProjectKeyDiscountCodesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDiscountCodesRequestBuilder) Get ¶

* * Deprecated scope: `view_orders:{projectKey}`

func (*ByProjectKeyDiscountCodesRequestBuilder) Post ¶

* * Deprecated scope: `manage_orders:{projectKey}`

func (*ByProjectKeyDiscountCodesRequestBuilder) WithId ¶

type ByProjectKeyDiscountCodesRequestMethodGet ¶

type ByProjectKeyDiscountCodesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDiscountCodesRequestMethodGet) Dump ¶

func (r *ByProjectKeyDiscountCodesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyDiscountCodesRequestMethodGet) Execute ¶

* * Deprecated scope: `view_orders:{projectKey}`

func (*ByProjectKeyDiscountCodesRequestMethodGet) Expand ¶

func (*ByProjectKeyDiscountCodesRequestMethodGet) Limit ¶

func (*ByProjectKeyDiscountCodesRequestMethodGet) Offset ¶

func (*ByProjectKeyDiscountCodesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyDiscountCodesRequestMethodGet) Sort ¶

func (*ByProjectKeyDiscountCodesRequestMethodGet) Where ¶

func (*ByProjectKeyDiscountCodesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyDiscountCodesRequestMethodGet) WithTotal ¶

type ByProjectKeyDiscountCodesRequestMethodGetInput ¶

type ByProjectKeyDiscountCodesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyDiscountCodesRequestMethodGetInput) Values ¶

type ByProjectKeyDiscountCodesRequestMethodPost ¶

type ByProjectKeyDiscountCodesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDiscountCodesRequestMethodPost) Dump ¶

func (r *ByProjectKeyDiscountCodesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyDiscountCodesRequestMethodPost) Execute ¶

* * Deprecated scope: `manage_orders:{projectKey}`

func (*ByProjectKeyDiscountCodesRequestMethodPost) Expand ¶

func (*ByProjectKeyDiscountCodesRequestMethodPost) WithHeaders ¶

type ByProjectKeyDiscountCodesRequestMethodPostInput ¶

type ByProjectKeyDiscountCodesRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyDiscountCodesRequestMethodPostInput) Values ¶

type ByProjectKeyExtensionsByIDRequestBuilder ¶

type ByProjectKeyExtensionsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyExtensionsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyExtensionsByIDRequestBuilder) Get ¶

func (*ByProjectKeyExtensionsByIDRequestBuilder) Post ¶

type ByProjectKeyExtensionsByIDRequestMethodDelete ¶

type ByProjectKeyExtensionsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyExtensionsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyExtensionsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyExtensionsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyExtensionsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyExtensionsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyExtensionsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyExtensionsByIDRequestMethodDeleteInput ¶

type ByProjectKeyExtensionsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyExtensionsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyExtensionsByIDRequestMethodGet ¶

type ByProjectKeyExtensionsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyExtensionsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyExtensionsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyExtensionsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyExtensionsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyExtensionsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyExtensionsByIDRequestMethodGetInput ¶

type ByProjectKeyExtensionsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyExtensionsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyExtensionsByIDRequestMethodPost ¶

type ByProjectKeyExtensionsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyExtensionsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyExtensionsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyExtensionsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyExtensionsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyExtensionsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyExtensionsByIDRequestMethodPostInput ¶

type ByProjectKeyExtensionsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyExtensionsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyExtensionsKeyByKeyRequestBuilder ¶

type ByProjectKeyExtensionsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyExtensionsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyExtensionsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyExtensionsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodGet ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyExtensionsKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodPost ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyExtensionsKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyExtensionsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyExtensionsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyExtensionsRequestBuilder ¶

type ByProjectKeyExtensionsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyExtensionsRequestBuilder) Get ¶

func (*ByProjectKeyExtensionsRequestBuilder) Post ¶

func (*ByProjectKeyExtensionsRequestBuilder) WithId ¶

func (*ByProjectKeyExtensionsRequestBuilder) WithKey ¶

type ByProjectKeyExtensionsRequestMethodGet ¶

type ByProjectKeyExtensionsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyExtensionsRequestMethodGet) Dump ¶

func (r *ByProjectKeyExtensionsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyExtensionsRequestMethodGet) Execute ¶

func (*ByProjectKeyExtensionsRequestMethodGet) Expand ¶

func (*ByProjectKeyExtensionsRequestMethodGet) Limit ¶

func (*ByProjectKeyExtensionsRequestMethodGet) Offset ¶

func (*ByProjectKeyExtensionsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyExtensionsRequestMethodGet) Sort ¶

func (*ByProjectKeyExtensionsRequestMethodGet) Where ¶

func (*ByProjectKeyExtensionsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyExtensionsRequestMethodGet) WithTotal ¶

type ByProjectKeyExtensionsRequestMethodGetInput ¶

type ByProjectKeyExtensionsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyExtensionsRequestMethodGetInput) Values ¶

type ByProjectKeyExtensionsRequestMethodPost ¶

type ByProjectKeyExtensionsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyExtensionsRequestMethodPost) Dump ¶

func (r *ByProjectKeyExtensionsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyExtensionsRequestMethodPost) Execute ¶

func (rb *ByProjectKeyExtensionsRequestMethodPost) Execute(ctx context.Context) (result *Extension, err error)

func (*ByProjectKeyExtensionsRequestMethodPost) Expand ¶

func (*ByProjectKeyExtensionsRequestMethodPost) WithHeaders ¶

type ByProjectKeyExtensionsRequestMethodPostInput ¶

type ByProjectKeyExtensionsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyExtensionsRequestMethodPostInput) Values ¶

type ByProjectKeyGraphqlRequestBuilder ¶

type ByProjectKeyGraphqlRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyGraphqlRequestBuilder) Post ¶

* * Execute a GraphQL query

type ByProjectKeyGraphqlRequestMethodPost ¶

type ByProjectKeyGraphqlRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyGraphqlRequestMethodPost) Dump ¶

func (r *ByProjectKeyGraphqlRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyGraphqlRequestMethodPost) Execute ¶

* * Execute a GraphQL query

func (*ByProjectKeyGraphqlRequestMethodPost) WithHeaders ¶

type ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyMeCustomersRequestBuilder ¶

type ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyMeCustomersRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyMeCustomersRequestBuilder) Post ¶

* * The My Business Unit endpoint does not support assigning existing Customers to a Business Unit. * Associates with the `UpdateAssociates` Permission(ctp:api:type:Permission) can use this endpoint to create a new Customer and associate it with the Business Unit. * If the required Permission(/projects/associate-roles#permission) is missing, an [AssociateMissingPermission](/errors#associatemissingpermission) error is returned. * The new Associate is created with an empty set of roles. *

type ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyMeCustomersRequestMethodPost ¶

type ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyMeCustomersRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyMeCustomersRequestMethodPost) Dump ¶

func (*ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyMeCustomersRequestMethodPost) Execute ¶

* * The My Business Unit endpoint does not support assigning existing Customers to a Business Unit. * Associates with the `UpdateAssociates` Permission(ctp:api:type:Permission) can use this endpoint to create a new Customer and associate it with the Business Unit. * If the required Permission(/projects/associate-roles#permission) is missing, an [AssociateMissingPermission](/errors#associatemissingpermission) error is returned. * The new Associate is created with an empty set of roles. *

func (*ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyMeCustomersRequestMethodPost) WithHeaders ¶

type ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyMeRequestBuilder ¶

type ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyMeRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyMeRequestBuilder) Customers ¶

type ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyRequestBuilder ¶

type ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyRequestBuilder) Me ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestBuilder) Delete ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestBuilder) Get ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. * * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestBuilder) Post ¶

* * Updates a Cart(ctp:api:type:Cart) in the Store specified by `storeKey`. * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. *

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodDelete) Execute ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodGet) Execute ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. * * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodPost) Execute ¶

* * Updates a Cart(ctp:api:type:Cart) in the Store specified by `storeKey`. * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestBuilder) Get ¶

* * Retrieves the recently modified active Cart of a Customer with CartOrigin(ctp:api:type:CartOrigin) `Customer`. If no active Cart exists, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. * * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. * * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

type ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestMethodGet) Execute ¶

* * Retrieves the recently modified active Cart of a Customer with CartOrigin(ctp:api:type:CartOrigin) `Customer`. If no active Cart exists, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. * * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. * * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestBuilder) Delete ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestBuilder) Get ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. * * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestBuilder) Post ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodDelete) Execute ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodGet) Execute ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. * * To ensure the Cart is up-to-date with current values (such as Prices and Discounts), use the [Recalculate](ctp:api:type:CartRecalculateAction) update action. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodPost) Execute ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsReplicateRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsReplicateRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsReplicateRequestBuilder) Post ¶

* * Creates a new Cart by replicating an existing Cart or Order. Can be useful in cases where a customer wants to cancel a recent order to make some changes or reorder a previous order. * * The replicated Cart preserves Customer information, Line Items and Custom Line Items, Custom Fields, Discount Codes, and other settings of the Cart or Order. If the Line Items become invalid, for example, due to removed Products or Prices, they are removed from the new Cart. If the Customer switches to another Customer Group, the new Cart is updated with the new value. It has up-to-date Tax Rates, Prices, and Line Item product data and is in `Active` CartState(ctp:api:type:CartState). * * The new Cart does not contain payments or deliveries. The State(ctp:api:type:ItemState) of Line Items and Custom Line Items is reset to `initial`. *

type ByProjectKeyInStoreKeyByStoreKeyCartsReplicateRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsReplicateRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsReplicateRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsReplicateRequestMethodPost) Execute ¶

* * Creates a new Cart by replicating an existing Cart or Order. Can be useful in cases where a customer wants to cancel a recent order to make some changes or reorder a previous order. * * The replicated Cart preserves Customer information, Line Items and Custom Line Items, Custom Fields, Discount Codes, and other settings of the Cart or Order. If the Line Items become invalid, for example, due to removed Products or Prices, they are removed from the new Cart. If the Customer switches to another Customer Group, the new Cart is updated with the new value. It has up-to-date Tax Rates, Prices, and Line Item product data and is in `Active` CartState(ctp:api:type:CartState). * * The new Cart does not contain payments or deliveries. The State(ctp:api:type:ItemState) of Line Items and Custom Line Items is reset to `initial`. *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsReplicateRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestBuilder) Get ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestBuilder) Post ¶

* * The `store` field in the created Cart(ctp:api:type:Cart) is set to the Store specified by the `storeKey` path parameter. * * Specific Error Codes: [CountryNotConfiguredInStore](ctp:api:type:CountryNotConfiguredInStoreError) *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestBuilder) Replicate ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestBuilder) WithCustomerId ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestBuilder) WithId ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestBuilder) WithKey ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet) Limit ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet) Offset ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet) Sort ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet) Where ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGet) WithTotal ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodPost) Execute ¶

* * The `store` field in the created Cart(ctp:api:type:Cart) is set to the Store specified by the `storeKey` path parameter. * * Specific Error Codes: [CountryNotConfiguredInStore](ctp:api:type:CountryNotConfiguredInStoreError) *

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCartsRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestBuilder) Delete ¶

* * Deleting a Customer produces the [CustomerDeleted](ctp:api:type:CustomerDeletedMessage) Message. * * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestBuilder) Get ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestBuilder) Post ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodDelete) Execute ¶

* * Deleting a Customer produces the [CustomerDeleted](ctp:api:type:CustomerDeletedMessage) Message. * * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodGet) Execute ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodPost) Execute ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersByIDRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailConfirmRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailConfirmRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailConfirmRequestBuilder) Post ¶

* * The customer verifies the email using the token value. * Verifying the email of the Customer produces the [CustomerEmailVerified](ctp:api:type:CustomerEmailVerifiedMessage) Message. * * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailConfirmRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailConfirmRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailConfirmRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailConfirmRequestMethodPost) Execute ¶

* * The customer verifies the email using the token value. * Verifying the email of the Customer produces the [CustomerEmailVerified](ctp:api:type:CustomerEmailVerifiedMessage) Message. * * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailConfirmRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestBuilder) Get ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestMethodGet) Execute ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenByEmailTokenRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenRequestBuilder) Post ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenRequestMethodPost) Execute ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersEmailTokenRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestBuilder) Delete ¶

* * Deleting a Customer produces the [CustomerDeleted](ctp:api:type:CustomerDeletedMessage) Message. * * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestBuilder) Get ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestBuilder) Post ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodDelete) Execute ¶

* * Deleting a Customer produces the [CustomerDeleted](ctp:api:type:CustomerDeletedMessage) Message. * * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodGet) Execute ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodPost) Execute ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordRequestBuilder) Post ¶

* * Changing the password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=false`. *

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordRequestMethodPost) Execute ¶

* * Changing the password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=false`. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordResetRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordResetRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordResetRequestBuilder) Post ¶

* * Resetting the password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=true`. * * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordResetRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordResetRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordResetRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordResetRequestMethodPost) Execute ¶

* * Resetting the password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=true`. * * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordResetRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestBuilder) Get ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet) Execute ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenByPasswordTokenRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenRequestBuilder) Post ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenRequestMethodPost) Execute ¶

* * If the Customer exists in the Project but the `stores` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersPasswordTokenRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder) EmailConfirm ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder) EmailToken ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder) Get ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder) Password ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder) PasswordReset ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder) PasswordToken ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder) Post ¶

* * When using this endpoint, if omitted, the Customer `stores` field is set to the Store specified in the path parameter. * * If the `anonymousCart` field is set on the CustomerDraft(ctp:api:type:CustomerDraft), then the newly created Customer will be assigned to that Cart(ctp:api:type:Cart). * Similarly, if the `anonymousId` field is set, the Customer will be set on all [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [ShoppingLists](ctp:api:type:ShoppingList) and [Payments](ctp:api:type:Payment) with the same `anonymousId`. * If a Cart with a `store` field specified, the `store` field must reference the same Store specified in the `{storeKey}` path parameter. * Creating a Customer produces the [CustomerCreated](ctp:api:type:CustomerCreatedMessage) Message. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder) WithEmailToken ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder) WithId ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder) WithKey ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder) WithPasswordToken ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet) Limit ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet) Offset ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet) Sort ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet) Where ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGet) WithTotal ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodPost) Execute ¶

* * When using this endpoint, if omitted, the Customer `stores` field is set to the Store specified in the path parameter. * * If the `anonymousCart` field is set on the CustomerDraft(ctp:api:type:CustomerDraft), then the newly created Customer will be assigned to that Cart(ctp:api:type:Cart). * Similarly, if the `anonymousId` field is set, the Customer will be set on all [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [ShoppingLists](ctp:api:type:ShoppingList) and [Payments](ctp:api:type:Payment) with the same `anonymousId`. * If a Cart with a `store` field specified, the `store` field must reference the same Store specified in the `{storeKey}` path parameter. * Creating a Customer produces the [CustomerCreated](ctp:api:type:CustomerCreatedMessage) Message. *

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyCustomersRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyLoginRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyLoginRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyLoginRequestBuilder) Post ¶

* * Authenticates a Customer associated with a Store. For more information, see [Global versus Store-specific Customers](/../api/customers-overview#global-versus-store-specific-customers). * * If the Customer exists in the Project but the `stores` field references a different Store, this method returns an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error. *

type ByProjectKeyInStoreKeyByStoreKeyLoginRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyLoginRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyLoginRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyLoginRequestMethodPost) Execute ¶

* * Authenticates a Customer associated with a Store. For more information, see [Global versus Store-specific Customers](/../api/customers-overview#global-versus-store-specific-customers). * * If the Customer exists in the Project but the `stores` field references a different Store, this method returns an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyLoginRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestBuilder) Get ¶

* * Retrieves the Customer's most recently modified active Cart in the Store specified by the `storeKey` path parameter. * * Carts with `Merchant` or `Quote` CartOrigin(ctp:api:type:CartOrigin) are ignored. * * If no active Cart exists, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. *

type ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestMethodGet) Execute ¶

* * Retrieves the Customer's most recently modified active Cart in the Store specified by the `storeKey` path parameter. * * Carts with `Merchant` or `Quote` CartOrigin(ctp:api:type:CartOrigin) are ignored. * * If no active Cart exists, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeActiveCartRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestBuilder) Get ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestBuilder) Post ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodPost) Execute ¶

* * If the Cart exists in the Project but does not have the `store` field, or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestBuilder) Get ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestBuilder) Post ¶

* * The `store` field in the created Cart(ctp:api:type:Cart) is set to the Store specified by the `storeKey` path parameter. * * Specific Error Codes: [CountryNotConfiguredInStore](ctp:api:type:CountryNotConfiguredInStoreError) *

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestBuilder) WithId ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet) Limit ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet) Offset ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet) Sort ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet) Where ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGet) WithTotal ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodPost) Execute ¶

* * The `store` field in the created Cart(ctp:api:type:Cart) is set to the Store specified by the `storeKey` path parameter. * * Specific Error Codes: [CountryNotConfiguredInStore](ctp:api:type:CountryNotConfiguredInStoreError) *

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeCartsRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeEmailConfirmRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeEmailConfirmRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeEmailConfirmRequestBuilder) Post ¶

* * This is the last step in the [email verification process of a Customer](/../api/projects/customers#email-verification-of-customer-in-store). *

type ByProjectKeyInStoreKeyByStoreKeyMeEmailConfirmRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMeEmailConfirmRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeEmailConfirmRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeEmailConfirmRequestMethodPost) Execute ¶

* * This is the last step in the [email verification process of a Customer](/../api/projects/customers#email-verification-of-customer-in-store). *

func (*ByProjectKeyInStoreKeyByStoreKeyMeEmailConfirmRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeLoginRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeLoginRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeLoginRequestBuilder) Post ¶

* * Retrieves the authenticated Customer (that matches the given email/password pair) if they are part of a specific Store(ctp:api:type:Store). * * - If the Customer does not have a Cart, the most recently modified anonymous cart becomes the Customer's Cart. * - If the Customer already has a Cart, the most recently modified anonymous cart is handled according to AnonymousCartSignInMode(ctp:api:type:AnonymousCartSignInMode). * * If a Cart is returned as part of CustomerSignInResult(ctp:api:type:CustomerSignInResult), it has been [recalculated](ctp:api:type:MyCartRecalculateAction) with up-to-date prices, taxes, discounts, and invalid line items removed. * * If an account with the given credentials is not found, an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error is returned. *

type ByProjectKeyInStoreKeyByStoreKeyMeLoginRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMeLoginRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeLoginRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeLoginRequestMethodPost) Execute ¶

* * Retrieves the authenticated Customer (that matches the given email/password pair) if they are part of a specific Store(ctp:api:type:Store). * * - If the Customer does not have a Cart, the most recently modified anonymous cart becomes the Customer's Cart. * - If the Customer already has a Cart, the most recently modified anonymous cart is handled according to AnonymousCartSignInMode(ctp:api:type:AnonymousCartSignInMode). * * If a Cart is returned as part of CustomerSignInResult(ctp:api:type:CustomerSignInResult), it has been [recalculated](ctp:api:type:MyCartRecalculateAction) with up-to-date prices, taxes, discounts, and invalid line items removed. * * If an account with the given credentials is not found, an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeLoginRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestBuilder) Get ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersByIDRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestBuilder) Get ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestBuilder) WithId ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet) Limit ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet) Offset ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet) Sort ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet) Where ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGet) WithTotal ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodPost) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeOrdersRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMePasswordRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMePasswordRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMePasswordRequestBuilder) Post ¶

* * Changing the password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=false`. *

func (*ByProjectKeyInStoreKeyByStoreKeyMePasswordRequestBuilder) Reset ¶

type ByProjectKeyInStoreKeyByStoreKeyMePasswordRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMePasswordRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMePasswordRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMePasswordRequestMethodPost) Execute ¶

* * Changing the password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=false`. *

func (*ByProjectKeyInStoreKeyByStoreKeyMePasswordRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMePasswordResetRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMePasswordResetRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMePasswordResetRequestBuilder) Post ¶

* * This is the last step in the [password reset process of the authenticated Customer](/../api/projects/customers#password-reset-of-customer-in-store). * * Resetting a password produces the of the Customer [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=true`. *

type ByProjectKeyInStoreKeyByStoreKeyMePasswordResetRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMePasswordResetRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMePasswordResetRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMePasswordResetRequestMethodPost) Execute ¶

* * This is the last step in the [password reset process of the authenticated Customer](/../api/projects/customers#password-reset-of-customer-in-store). * * Resetting a password produces the of the Customer [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=true`. *

func (*ByProjectKeyInStoreKeyByStoreKeyMePasswordResetRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder) ActiveCart ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder) Carts ¶

* * A shopping cart holds product variants and can be ordered.

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder) Delete ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder) EmailConfirm ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder) Get ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder) Login ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder) Orders ¶

* * An order can be created from a order, usually after a checkout process has been completed.

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder) Password ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder) Post ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder) ShoppingLists ¶

* * shopping-lists e.g. for wishlist support *

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestBuilder) Signup ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodDelete) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodDeleteInput struct {
	Version int
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet) Limit ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet) Offset ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet) Sort ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet) Where ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGet) WithTotal ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGetInput struct {
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Expand       []string
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodPost) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestBuilder) Delete ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestBuilder) Get ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestBuilder) Post ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodDelete) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodDeleteInput struct {
	Expand      []string
	DataErasure *bool
	Version     int
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodGet) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodPost) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestBuilder) Delete ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestBuilder) Get ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestBuilder) Post ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodDelete) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodDeleteInput struct {
	Expand      []string
	DataErasure *bool
	Version     int
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodGet) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodPost) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestBuilder) Get ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestBuilder) Post ¶

* * When using this endpoint, the `store` field of a ShoppingList is always set to the Store specified in the path parameter. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestBuilder) WithId ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestBuilder) WithKey ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet) Limit ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet) Offset ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet) Sort ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet) Where ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGet) WithTotal ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodPost) Execute ¶

* * When using this endpoint, the `store` field of a ShoppingList is always set to the Store specified in the path parameter. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeShoppingListsRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyMeSignupRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyMeSignupRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeSignupRequestBuilder) Post ¶

* * If omitted in the request body, the Customer(ctp:api:type:Customer) `stores` field is set to the Store specified in the path parameter. * * Creating a Customer produces the [CustomerCreated](ctp:api:type:CustomerCreatedMessage) Message. *

type ByProjectKeyInStoreKeyByStoreKeyMeSignupRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyMeSignupRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyMeSignupRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyMeSignupRequestMethodPost) Execute ¶

* * If omitted in the request body, the Customer(ctp:api:type:Customer) `stores` field is set to the Store specified in the path parameter. * * Creating a Customer produces the [CustomerCreated](ctp:api:type:CustomerCreatedMessage) Message. *

func (*ByProjectKeyInStoreKeyByStoreKeyMeSignupRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestBuilder) Delete ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestBuilder) Get ¶

* * Returns an order by its ID from a specific Store. * If the order exists in the project but does not have the store field, * or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestBuilder) Post ¶

* * Updates an order in the store specified by {storeKey}. * If the order exists in the project but does not have the store field, * or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodGet) Execute ¶

* * Returns an order by its ID from a specific Store. * If the order exists in the project but does not have the store field, * or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodPost) Execute ¶

* * Updates an order in the store specified by {storeKey}. * If the order exists in the project but does not have the store field, * or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. *

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersByIDRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestBuilder) Get ¶

* * Returns an order by its order number from a specific Store. * * If the order exists in the project but does not have the store field, * or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. * In case the orderNumber does not match the regular expression [a-zA-Z0-9_\-]+, * it should be provided in URL-encoded format. *

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestBuilder) Post ¶

* * Updates an order in the store specified by {storeKey}. * If the order exists in the project but does not have the store field, * or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. * In case the orderNumber does not match the regular expression [a-zA-Z0-9_\-]+, * it should be provided in URL-encoded format. *

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodGet) Execute ¶

* * Returns an order by its order number from a specific Store. * * If the order exists in the project but does not have the store field, * or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. * In case the orderNumber does not match the regular expression [a-zA-Z0-9_\-]+, * it should be provided in URL-encoded format. *

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodPost) Execute ¶

* * Updates an order in the store specified by {storeKey}. * If the order exists in the project but does not have the store field, * or the `store` field references a different Store, this method returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error. * In case the orderNumber does not match the regular expression [a-zA-Z0-9_\-]+, * it should be provided in URL-encoded format. *

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersOrderNumberByOrderNumberRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestBuilder) Get ¶

* * Queries orders in a specific Store.

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestBuilder) Post ¶

* * Creates an order from a Cart from a specific Store. * When using this endpoint the orders's store field is always set to the store specified in the path parameter. * The cart must have a shipping address set before creating an order. When using the Platform TaxMode, * the shipping address is used for tax calculation. *

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestBuilder) WithId ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestBuilder) WithOrderNumber ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet) Execute ¶

* * Queries orders in a specific Store.

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet) Limit ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet) Offset ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet) Sort ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet) Where ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGet) WithTotal ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodPost) Execute ¶

* * Creates an order from a Cart from a specific Store. * When using this endpoint the orders's store field is always set to the store specified in the path parameter. * The cart must have a shipping address set before creating an order. When using the Platform TaxMode, * the shipping address is used for tax calculation. *

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyOrdersRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestBuilder) Get ¶

* * Gets the current or staged representation of a Product(ctp:api:type:Product) by its ID from the specified Store(ctp:api:type:Store). * If the Store has defined some languages, countries, distribution or supply Channels, * they are used for projections based on [locale](ctp:api:type:ProductProjectionLocales), [price](ctp:api:type:ProductProjectionPrices) * and [inventory](ctp:api:type:ProductProjectionInventoryEntries). * * When used with an API Client that has the `view_published_products:{projectKey}` scope, this endpoint only returns published (current) Product Projections. *

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet) Execute ¶

* * Gets the current or staged representation of a Product(ctp:api:type:Product) by its ID from the specified Store(ctp:api:type:Store). * If the Store has defined some languages, countries, distribution or supply Channels, * they are used for projections based on [locale](ctp:api:type:ProductProjectionLocales), [price](ctp:api:type:ProductProjectionPrices) * and [inventory](ctp:api:type:ProductProjectionInventoryEntries). * * When used with an API Client that has the `view_published_products:{projectKey}` scope, this endpoint only returns published (current) Product Projections. *

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet) LocaleProjection ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet) PriceChannel ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet) PriceCountry ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet) PriceCurrency ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet) PriceCustomerGroup ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet) Staged ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGetInput struct {
	Staged             *bool
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	Expand             []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestBuilder) Get ¶

* * Gets the current or staged representation of a Product(ctp:api:type:Product) by its key from the specified Store(ctp:api:type:Store). * If the Store has defined some languages, countries, distribution or supply Channels, * they are used for projections based on [locale](ctp:api:type:ProductProjectionLocales), [price](ctp:api:type:ProductProjectionPrices) * and [inventory](ctp:api:type:ProductProjectionInventoryEntries). * * When used with an API Client that has the `view_published_products:{projectKey}` scope, this endpoint only returns published (current) Product Projections. *

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet) Execute ¶

* * Gets the current or staged representation of a Product(ctp:api:type:Product) by its key from the specified Store(ctp:api:type:Store). * If the Store has defined some languages, countries, distribution or supply Channels, * they are used for projections based on [locale](ctp:api:type:ProductProjectionLocales), [price](ctp:api:type:ProductProjectionPrices) * and [inventory](ctp:api:type:ProductProjectionInventoryEntries). * * When used with an API Client that has the `view_published_products:{projectKey}` scope, this endpoint only returns published (current) Product Projections. *

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet) LocaleProjection ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet) PriceChannel ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet) PriceCountry ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet) PriceCurrency ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet) PriceCustomerGroup ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet) Staged ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGetInput struct {
	Staged             *bool
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	Expand             []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyProductProjectionsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsRequestBuilder) WithId ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductProjectionsRequestBuilder) WithKey ¶

type ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestBuilder) Get ¶

* * Queries Product Selection assignments over all Product Selections that are active in a specific Store. * * The response will include duplicate Products whenever more than one active Product Selection of the Store * includes a Product. To make clear through which Product Selection a Product is available in the Store * the response contains assignments including both the Product and the Product Selection. * Only Products of Product Selections that are activated in the Store will be returned. *

type ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGet) Execute ¶

* * Queries Product Selection assignments over all Product Selections that are active in a specific Store. * * The response will include duplicate Products whenever more than one active Product Selection of the Store * includes a Product. To make clear through which Product Selection a Product is available in the Store * the response contains assignments including both the Product and the Product Selection. * Only Products of Product Selections that are activated in the Store will be returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGet) Limit ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGet) Offset ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGet) WithTotal ¶

type ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGetInput struct {
	Limit     *int
	Offset    *int
	WithTotal *bool
	Expand    []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyProductSelectionAssignmentsRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyRequestBuilder) Carts ¶

* * A shopping cart holds product variants and can be ordered.

func (*ByProjectKeyInStoreKeyByStoreKeyRequestBuilder) Customers ¶

* * A Customer is a person purchasing products. Carts, Orders, * Comments and Reviews can be associated to a Customer. *

func (*ByProjectKeyInStoreKeyByStoreKeyRequestBuilder) Login ¶

* * Retrieves the authenticated customer.

func (*ByProjectKeyInStoreKeyByStoreKeyRequestBuilder) Me ¶

func (*ByProjectKeyInStoreKeyByStoreKeyRequestBuilder) Orders ¶

* * An order can be created from a cart, usually after a checkout process has been completed.

func (*ByProjectKeyInStoreKeyByStoreKeyRequestBuilder) ProductProjections ¶

func (*ByProjectKeyInStoreKeyByStoreKeyRequestBuilder) ProductSelectionAssignments ¶

func (*ByProjectKeyInStoreKeyByStoreKeyRequestBuilder) ShippingMethods ¶

func (*ByProjectKeyInStoreKeyByStoreKeyRequestBuilder) ShoppingLists ¶

* * shopping-lists e.g. for wishlist support *

type ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestBuilder) Get ¶

* * Retrieves all the ShippingMethods that can ship to the shipping address of the given Cart in a given Store. * Each ShippingMethod contains exactly one ShippingRate with the flag `isMatching` set to `true`. * This ShippingRate is used when the ShippingMethod is [added to the Cart](ctp:api:type:CartSetShippingMethodAction). *

type ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestMethodGet) CartId ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestMethodGet) Execute ¶

* * Retrieves all the ShippingMethods that can ship to the shipping address of the given Cart in a given Store. * Each ShippingMethod contains exactly one ShippingRate with the flag `isMatching` set to `true`. * This ShippingRate is used when the ShippingMethod is [added to the Cart](ctp:api:type:CartSetShippingMethodAction). *

func (*ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestMethodGetInput struct {
	CartId string
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyShippingMethodsMatchingCartRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyShippingMethodsRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyShippingMethodsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShippingMethodsRequestBuilder) MatchingCart ¶

* * Get ShippingMethods for a cart in a store

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestBuilder) Delete ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestBuilder) Get ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestBuilder) Post ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodDelete) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodDeleteInput struct {
	Expand      []string
	DataErasure *bool
	Version     int
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodGet) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodPost) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestBuilder) Delete ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestBuilder) Get ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestBuilder) Post ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodDelete) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodDeleteInput struct {
	Expand      []string
	DataErasure *bool
	Version     int
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodGet) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodPost) Execute ¶

* * If a ShoppingList exists in a Project but does _not_ have the `store` field, or the `store` field references a different Store, * the [ResourceNotFound](/errors#404-not-found-1) error is returned. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestBuilder ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestBuilder) Get ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestBuilder) Post ¶

* * When using this endpoint, the `store` field of a ShoppingList is always set to the Store specified in the path parameter. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestBuilder) WithId ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestBuilder) WithKey ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet) Execute ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet) Limit ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet) Offset ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet) Sort ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet) Where ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGet) WithTotal ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGetInput ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodGetInput) Values ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodPost ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodPost) Dump ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodPost) Execute ¶

* * When using this endpoint, the `store` field of a ShoppingList is always set to the Store specified in the path parameter. *

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodPost) Expand ¶

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodPost) WithHeaders ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodPostInput ¶

type ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInStoreKeyByStoreKeyShoppingListsRequestMethodPostInput) Values ¶

type ByProjectKeyInventoryByIDRequestBuilder ¶

type ByProjectKeyInventoryByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInventoryByIDRequestBuilder) Delete ¶

* * Produces the [InventoryEntryDeleted](ctp:api:type:InventoryEntryDeletedMessage) Message.

func (*ByProjectKeyInventoryByIDRequestBuilder) Get ¶

func (*ByProjectKeyInventoryByIDRequestBuilder) Post ¶

type ByProjectKeyInventoryByIDRequestMethodDelete ¶

type ByProjectKeyInventoryByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInventoryByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyInventoryByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyInventoryByIDRequestMethodDelete) Execute ¶

* * Produces the [InventoryEntryDeleted](ctp:api:type:InventoryEntryDeletedMessage) Message.

func (*ByProjectKeyInventoryByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyInventoryByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyInventoryByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInventoryByIDRequestMethodDeleteInput ¶

type ByProjectKeyInventoryByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyInventoryByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyInventoryByIDRequestMethodGet ¶

type ByProjectKeyInventoryByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInventoryByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyInventoryByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyInventoryByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyInventoryByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyInventoryByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyInventoryByIDRequestMethodGetInput ¶

type ByProjectKeyInventoryByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInventoryByIDRequestMethodGetInput) Values ¶

type ByProjectKeyInventoryByIDRequestMethodPost ¶

type ByProjectKeyInventoryByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInventoryByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyInventoryByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyInventoryByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyInventoryByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyInventoryByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyInventoryByIDRequestMethodPostInput ¶

type ByProjectKeyInventoryByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInventoryByIDRequestMethodPostInput) Values ¶

type ByProjectKeyInventoryKeyByKeyRequestBuilder ¶

type ByProjectKeyInventoryKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInventoryKeyByKeyRequestBuilder) Delete ¶

* * Produces the [InventoryEntryDeleted](ctp:api:type:InventoryEntryDeletedMessage) Message.

func (*ByProjectKeyInventoryKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyInventoryKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodDelete ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInventoryKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyInventoryKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyInventoryKeyByKeyRequestMethodDelete) Execute ¶

* * Produces the [InventoryEntryDeleted](ctp:api:type:InventoryEntryDeletedMessage) Message.

func (*ByProjectKeyInventoryKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyInventoryKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyInventoryKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyInventoryKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodGet ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInventoryKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyInventoryKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyInventoryKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyInventoryKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyInventoryKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyInventoryKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodPost ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInventoryKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyInventoryKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyInventoryKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyInventoryKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyInventoryKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyInventoryKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInventoryKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyInventoryRequestBuilder ¶

type ByProjectKeyInventoryRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInventoryRequestBuilder) Get ¶

func (*ByProjectKeyInventoryRequestBuilder) Post ¶

* * Produces the [InventoryEntryCreated](ctp:api:type:InventoryEntryCreatedMessage) Message.

func (*ByProjectKeyInventoryRequestBuilder) WithId ¶

func (*ByProjectKeyInventoryRequestBuilder) WithKey ¶

type ByProjectKeyInventoryRequestMethodGet ¶

type ByProjectKeyInventoryRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInventoryRequestMethodGet) Dump ¶

func (r *ByProjectKeyInventoryRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyInventoryRequestMethodGet) Execute ¶

func (*ByProjectKeyInventoryRequestMethodGet) Expand ¶

func (*ByProjectKeyInventoryRequestMethodGet) Limit ¶

func (*ByProjectKeyInventoryRequestMethodGet) Offset ¶

func (*ByProjectKeyInventoryRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyInventoryRequestMethodGet) Sort ¶

func (*ByProjectKeyInventoryRequestMethodGet) Where ¶

func (*ByProjectKeyInventoryRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyInventoryRequestMethodGet) WithTotal ¶

type ByProjectKeyInventoryRequestMethodGetInput ¶

type ByProjectKeyInventoryRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyInventoryRequestMethodGetInput) Values ¶

type ByProjectKeyInventoryRequestMethodPost ¶

type ByProjectKeyInventoryRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyInventoryRequestMethodPost) Dump ¶

func (r *ByProjectKeyInventoryRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyInventoryRequestMethodPost) Execute ¶

* * Produces the [InventoryEntryCreated](ctp:api:type:InventoryEntryCreatedMessage) Message.

func (*ByProjectKeyInventoryRequestMethodPost) Expand ¶

func (*ByProjectKeyInventoryRequestMethodPost) WithHeaders ¶

type ByProjectKeyInventoryRequestMethodPostInput ¶

type ByProjectKeyInventoryRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyInventoryRequestMethodPostInput) Values ¶

type ByProjectKeyLoginRequestBuilder ¶

type ByProjectKeyLoginRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyLoginRequestBuilder) Post ¶

* * Authenticates a global Customer not associated with a Store. * For more information, see [Global versus Store-specific Customers](/../api/customers-overview#global-versus-store-specific-customers). * If the Customer is registered in a Store, use the [Authenticate (sign in) Customer in Store](/../api/projects/customers#authenticate-sign-in-customer-in-store) method. * * If an account with the given credentials is not found, an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error is returned. *

type ByProjectKeyLoginRequestMethodPost ¶

type ByProjectKeyLoginRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyLoginRequestMethodPost) Dump ¶

func (r *ByProjectKeyLoginRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyLoginRequestMethodPost) Execute ¶

* * Authenticates a global Customer not associated with a Store. * For more information, see [Global versus Store-specific Customers](/../api/customers-overview#global-versus-store-specific-customers). * If the Customer is registered in a Store, use the [Authenticate (sign in) Customer in Store](/../api/projects/customers#authenticate-sign-in-customer-in-store) method. * * If an account with the given credentials is not found, an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error is returned. *

func (*ByProjectKeyLoginRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeActiveCartRequestBuilder ¶

type ByProjectKeyMeActiveCartRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeActiveCartRequestBuilder) Get ¶

* * Retrieves the Customer's most recently modified active Cart. * Carts with `Merchant` or `Quote` CartOrigin(ctp:api:type:CartOrigin) are ignored. * * If no active Cart exists, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. *

type ByProjectKeyMeActiveCartRequestMethodGet ¶

type ByProjectKeyMeActiveCartRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeActiveCartRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeActiveCartRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeActiveCartRequestMethodGet) Execute ¶

func (rb *ByProjectKeyMeActiveCartRequestMethodGet) Execute(ctx context.Context) (result *Cart, err error)

* * Retrieves the Customer's most recently modified active Cart. * Carts with `Merchant` or `Quote` CartOrigin(ctp:api:type:CartOrigin) are ignored. * * If no active Cart exists, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned. *

func (*ByProjectKeyMeActiveCartRequestMethodGet) Expand ¶

func (*ByProjectKeyMeActiveCartRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeActiveCartRequestMethodGetInput ¶

type ByProjectKeyMeActiveCartRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeActiveCartRequestMethodGetInput) Values ¶

type ByProjectKeyMeBusinessUnitsByIDRequestBuilder ¶

type ByProjectKeyMeBusinessUnitsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeBusinessUnitsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyMeBusinessUnitsByIDRequestBuilder) Get ¶

func (*ByProjectKeyMeBusinessUnitsByIDRequestBuilder) Post ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodDelete ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodDeleteInput ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodGet ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeBusinessUnitsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodGetInput ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodPost ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeBusinessUnitsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodPostInput ¶

type ByProjectKeyMeBusinessUnitsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeBusinessUnitsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestBuilder ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodGet ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodPost ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeBusinessUnitsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyMeBusinessUnitsRequestBuilder ¶

type ByProjectKeyMeBusinessUnitsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeBusinessUnitsRequestBuilder) Get ¶

func (*ByProjectKeyMeBusinessUnitsRequestBuilder) Post ¶

* * Automatically assigns the Associate to the Business Unit in the default [Associate Role](ctp:api:type:AssociateRole) defined in BusinessUnitConfiguration(ctp:api:type:BusinessUnitConfiguration). If there is no default Associate Role configured, this request fails with an [InvalidOperation](ctp:api:type:InvalidOperationError) error. When creating a Division, the Associate must have the `AddChildUnits` Permission(ctp:api:type:Permission) in the parent unit. If the required Permission(/projects/associate-roles#permission) is missing, an [AssociateMissingPermission](/errors#associatemissingpermission) error is returned. *

func (*ByProjectKeyMeBusinessUnitsRequestBuilder) WithId ¶

func (*ByProjectKeyMeBusinessUnitsRequestBuilder) WithKey ¶

type ByProjectKeyMeBusinessUnitsRequestMethodGet ¶

type ByProjectKeyMeBusinessUnitsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeBusinessUnitsRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeBusinessUnitsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeBusinessUnitsRequestMethodGet) Execute ¶

func (*ByProjectKeyMeBusinessUnitsRequestMethodGet) Expand ¶

func (*ByProjectKeyMeBusinessUnitsRequestMethodGet) Limit ¶

func (*ByProjectKeyMeBusinessUnitsRequestMethodGet) Offset ¶

func (*ByProjectKeyMeBusinessUnitsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyMeBusinessUnitsRequestMethodGet) Sort ¶

func (*ByProjectKeyMeBusinessUnitsRequestMethodGet) Where ¶

func (*ByProjectKeyMeBusinessUnitsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyMeBusinessUnitsRequestMethodGet) WithTotal ¶

type ByProjectKeyMeBusinessUnitsRequestMethodGetInput ¶

type ByProjectKeyMeBusinessUnitsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyMeBusinessUnitsRequestMethodGetInput) Values ¶

type ByProjectKeyMeBusinessUnitsRequestMethodPost ¶

type ByProjectKeyMeBusinessUnitsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeBusinessUnitsRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeBusinessUnitsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeBusinessUnitsRequestMethodPost) Execute ¶

* * Automatically assigns the Associate to the Business Unit in the default [Associate Role](ctp:api:type:AssociateRole) defined in BusinessUnitConfiguration(ctp:api:type:BusinessUnitConfiguration). If there is no default Associate Role configured, this request fails with an [InvalidOperation](ctp:api:type:InvalidOperationError) error. When creating a Division, the Associate must have the `AddChildUnits` Permission(ctp:api:type:Permission) in the parent unit. If the required Permission(/projects/associate-roles#permission) is missing, an [AssociateMissingPermission](/errors#associatemissingpermission) error is returned. *

func (*ByProjectKeyMeBusinessUnitsRequestMethodPost) Expand ¶

func (*ByProjectKeyMeBusinessUnitsRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeBusinessUnitsRequestMethodPostInput ¶

type ByProjectKeyMeBusinessUnitsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeBusinessUnitsRequestMethodPostInput) Values ¶

type ByProjectKeyMeCartsByIDRequestBuilder ¶

type ByProjectKeyMeCartsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyMeCartsByIDRequestBuilder) Get ¶

func (*ByProjectKeyMeCartsByIDRequestBuilder) Post ¶

type ByProjectKeyMeCartsByIDRequestMethodDelete ¶

type ByProjectKeyMeCartsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyMeCartsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyMeCartsByIDRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyMeCartsByIDRequestMethodDelete) Execute(ctx context.Context) (result *Cart, err error)

func (*ByProjectKeyMeCartsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyMeCartsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyMeCartsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyMeCartsByIDRequestMethodDeleteInput ¶

type ByProjectKeyMeCartsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyMeCartsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyMeCartsByIDRequestMethodGet ¶

type ByProjectKeyMeCartsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeCartsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeCartsByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyMeCartsByIDRequestMethodGet) Execute(ctx context.Context) (result *Cart, err error)

func (*ByProjectKeyMeCartsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyMeCartsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeCartsByIDRequestMethodGetInput ¶

type ByProjectKeyMeCartsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeCartsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyMeCartsByIDRequestMethodPost ¶

type ByProjectKeyMeCartsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeCartsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeCartsByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyMeCartsByIDRequestMethodPost) Execute(ctx context.Context) (result *Cart, err error)

func (*ByProjectKeyMeCartsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyMeCartsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeCartsByIDRequestMethodPostInput ¶

type ByProjectKeyMeCartsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeCartsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyMeCartsKeyByKeyRequestBuilder ¶

type ByProjectKeyMeCartsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyMeCartsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyMeCartsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyMeCartsKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodGet ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeCartsKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodGet) Execute ¶

func (rb *ByProjectKeyMeCartsKeyByKeyRequestMethodGet) Execute(ctx context.Context) (result *Cart, err error)

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodPost ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeCartsKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodPost) Execute ¶

func (rb *ByProjectKeyMeCartsKeyByKeyRequestMethodPost) Execute(ctx context.Context) (result *Cart, err error)

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyMeCartsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeCartsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyMeCartsReplicateRequestBuilder ¶

type ByProjectKeyMeCartsReplicateRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsReplicateRequestBuilder) Post ¶

* * Creates a new Cart by replicating an existing Cart or Order of the authenticated Customer. * This can be useful in cases where a customer wants to cancel a recent order to make some changes or reorder a previous order. * * The replicated Cart preserves Customer information, Line Items and Custom Line Items, Custom Fields, Discount Codes, and other settings of the Cart or Order. * If the Line Items become invalid, for example, due to removed Products or Prices, they are removed from the new Cart. * If the Customer switches to another Customer Group, the new Cart is updated with the new value. * It has up-to-date Tax Rates, Prices, and Line Item product data and is in `Active` CartState(ctp:api:type:CartState). * * The new Cart does not contain Payments or Deliveries. The State(ctp:api:type:ItemState) of Line Items and Custom Line Items is reset to `initial`. * * In case the Cart or Order to be replicated does not belong to the authenticaed Customer, the API returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error *

type ByProjectKeyMeCartsReplicateRequestMethodPost ¶

type ByProjectKeyMeCartsReplicateRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsReplicateRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeCartsReplicateRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeCartsReplicateRequestMethodPost) Execute ¶

* * Creates a new Cart by replicating an existing Cart or Order of the authenticated Customer. * This can be useful in cases where a customer wants to cancel a recent order to make some changes or reorder a previous order. * * The replicated Cart preserves Customer information, Line Items and Custom Line Items, Custom Fields, Discount Codes, and other settings of the Cart or Order. * If the Line Items become invalid, for example, due to removed Products or Prices, they are removed from the new Cart. * If the Customer switches to another Customer Group, the new Cart is updated with the new value. * It has up-to-date Tax Rates, Prices, and Line Item product data and is in `Active` CartState(ctp:api:type:CartState). * * The new Cart does not contain Payments or Deliveries. The State(ctp:api:type:ItemState) of Line Items and Custom Line Items is reset to `initial`. * * In case the Cart or Order to be replicated does not belong to the authenticaed Customer, the API returns a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error *

func (*ByProjectKeyMeCartsReplicateRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeCartsRequestBuilder ¶

type ByProjectKeyMeCartsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsRequestBuilder) Get ¶

func (*ByProjectKeyMeCartsRequestBuilder) Post ¶

func (*ByProjectKeyMeCartsRequestBuilder) Replicate ¶

func (*ByProjectKeyMeCartsRequestBuilder) WithId ¶

func (*ByProjectKeyMeCartsRequestBuilder) WithKey ¶

type ByProjectKeyMeCartsRequestMethodGet ¶

type ByProjectKeyMeCartsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeCartsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeCartsRequestMethodGet) Execute ¶

func (*ByProjectKeyMeCartsRequestMethodGet) Expand ¶

func (*ByProjectKeyMeCartsRequestMethodGet) Limit ¶

func (*ByProjectKeyMeCartsRequestMethodGet) Offset ¶

func (*ByProjectKeyMeCartsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyMeCartsRequestMethodGet) Sort ¶

func (*ByProjectKeyMeCartsRequestMethodGet) Where ¶

func (*ByProjectKeyMeCartsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyMeCartsRequestMethodGet) WithTotal ¶

type ByProjectKeyMeCartsRequestMethodGetInput ¶

type ByProjectKeyMeCartsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyMeCartsRequestMethodGetInput) Values ¶

type ByProjectKeyMeCartsRequestMethodPost ¶

type ByProjectKeyMeCartsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeCartsRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeCartsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeCartsRequestMethodPost) Execute ¶

func (rb *ByProjectKeyMeCartsRequestMethodPost) Execute(ctx context.Context) (result *Cart, err error)

func (*ByProjectKeyMeCartsRequestMethodPost) Expand ¶

func (*ByProjectKeyMeCartsRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeCartsRequestMethodPostInput ¶

type ByProjectKeyMeCartsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeCartsRequestMethodPostInput) Values ¶

type ByProjectKeyMeEmailConfirmRequestBuilder ¶

type ByProjectKeyMeEmailConfirmRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeEmailConfirmRequestBuilder) Post ¶

* * This is the last step in the [email verification process of a Customer](/../api/projects/customers#email-verification-of-customer). *

type ByProjectKeyMeEmailConfirmRequestMethodPost ¶

type ByProjectKeyMeEmailConfirmRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeEmailConfirmRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeEmailConfirmRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeEmailConfirmRequestMethodPost) Execute ¶

* * This is the last step in the [email verification process of a Customer](/../api/projects/customers#email-verification-of-customer). *

func (*ByProjectKeyMeEmailConfirmRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeLoginRequestBuilder ¶

type ByProjectKeyMeLoginRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeLoginRequestBuilder) Post ¶

* * Retrieves the authenticated customer (that matches the given email/password pair). * * If used with [an access token for an anonymous session](ctp:api:type:AnonymousSession), all Orders and Carts that belong to the `anonymousId` are assigned to the newly logged-in Customer. * * - If the Customer does not have a Cart yet, the most recently modified anonymous cart becomes the Customer's Cart. * - If the Customer already has a Cart, the most recently modified anonymous cart is handled in accordance with AnonymousCartSignInMode(ctp:api:type:AnonymousCartSignInMode). * * A Cart returned as part of the CustomerSignInResult(ctp:api:type:CustomerSignInResult) is [recalculated](ctp:api:type:MyCartRecalculateAction) with up-to-date prices, taxes, discounts, and invalid line items removed. * * If an account with the given credentials is not found, an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error is returned. *

type ByProjectKeyMeLoginRequestMethodPost ¶

type ByProjectKeyMeLoginRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeLoginRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeLoginRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeLoginRequestMethodPost) Execute ¶

* * Retrieves the authenticated customer (that matches the given email/password pair). * * If used with [an access token for an anonymous session](ctp:api:type:AnonymousSession), all Orders and Carts that belong to the `anonymousId` are assigned to the newly logged-in Customer. * * - If the Customer does not have a Cart yet, the most recently modified anonymous cart becomes the Customer's Cart. * - If the Customer already has a Cart, the most recently modified anonymous cart is handled in accordance with AnonymousCartSignInMode(ctp:api:type:AnonymousCartSignInMode). * * A Cart returned as part of the CustomerSignInResult(ctp:api:type:CustomerSignInResult) is [recalculated](ctp:api:type:MyCartRecalculateAction) with up-to-date prices, taxes, discounts, and invalid line items removed. * * If an account with the given credentials is not found, an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error is returned. *

func (*ByProjectKeyMeLoginRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeOrdersByIDRequestBuilder ¶

type ByProjectKeyMeOrdersByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeOrdersByIDRequestBuilder) Get ¶

type ByProjectKeyMeOrdersByIDRequestMethodGet ¶

type ByProjectKeyMeOrdersByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeOrdersByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeOrdersByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeOrdersByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyMeOrdersByIDRequestMethodGet) Execute(ctx context.Context) (result *Order, err error)

func (*ByProjectKeyMeOrdersByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyMeOrdersByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeOrdersByIDRequestMethodGetInput ¶

type ByProjectKeyMeOrdersByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeOrdersByIDRequestMethodGetInput) Values ¶

type ByProjectKeyMeOrdersQuotesRequestBuilder ¶

type ByProjectKeyMeOrdersQuotesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeOrdersQuotesRequestBuilder) Post ¶

type ByProjectKeyMeOrdersQuotesRequestMethodPost ¶

type ByProjectKeyMeOrdersQuotesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeOrdersQuotesRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeOrdersQuotesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeOrdersQuotesRequestMethodPost) Execute ¶

func (rb *ByProjectKeyMeOrdersQuotesRequestMethodPost) Execute(ctx context.Context) (result *Order, err error)

func (*ByProjectKeyMeOrdersQuotesRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeOrdersRequestBuilder ¶

type ByProjectKeyMeOrdersRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeOrdersRequestBuilder) Get ¶

func (*ByProjectKeyMeOrdersRequestBuilder) Post ¶

func (*ByProjectKeyMeOrdersRequestBuilder) Quotes ¶

func (*ByProjectKeyMeOrdersRequestBuilder) WithId ¶

type ByProjectKeyMeOrdersRequestMethodGet ¶

type ByProjectKeyMeOrdersRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeOrdersRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeOrdersRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeOrdersRequestMethodGet) Execute ¶

func (*ByProjectKeyMeOrdersRequestMethodGet) Expand ¶

func (*ByProjectKeyMeOrdersRequestMethodGet) Limit ¶

func (*ByProjectKeyMeOrdersRequestMethodGet) Offset ¶

func (*ByProjectKeyMeOrdersRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyMeOrdersRequestMethodGet) Sort ¶

func (*ByProjectKeyMeOrdersRequestMethodGet) Where ¶

func (*ByProjectKeyMeOrdersRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyMeOrdersRequestMethodGet) WithTotal ¶

type ByProjectKeyMeOrdersRequestMethodGetInput ¶

type ByProjectKeyMeOrdersRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyMeOrdersRequestMethodGetInput) Values ¶

type ByProjectKeyMeOrdersRequestMethodPost ¶

type ByProjectKeyMeOrdersRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeOrdersRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeOrdersRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeOrdersRequestMethodPost) Execute ¶

func (rb *ByProjectKeyMeOrdersRequestMethodPost) Execute(ctx context.Context) (result *Order, err error)

func (*ByProjectKeyMeOrdersRequestMethodPost) Expand ¶

func (*ByProjectKeyMeOrdersRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeOrdersRequestMethodPostInput ¶

type ByProjectKeyMeOrdersRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeOrdersRequestMethodPostInput) Values ¶

type ByProjectKeyMePasswordRequestBuilder ¶

type ByProjectKeyMePasswordRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePasswordRequestBuilder) Post ¶

* * Changing the password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=false`. * * If the current password does not match, an [InvalidCurrentPassword](ctp:api:type:InvalidCurrentPasswordError) error is returned. *

func (*ByProjectKeyMePasswordRequestBuilder) Reset ¶

type ByProjectKeyMePasswordRequestMethodPost ¶

type ByProjectKeyMePasswordRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePasswordRequestMethodPost) Dump ¶

func (r *ByProjectKeyMePasswordRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMePasswordRequestMethodPost) Execute ¶

func (rb *ByProjectKeyMePasswordRequestMethodPost) Execute(ctx context.Context) (result *Customer, err error)

* * Changing the password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=false`. * * If the current password does not match, an [InvalidCurrentPassword](ctp:api:type:InvalidCurrentPasswordError) error is returned. *

func (*ByProjectKeyMePasswordRequestMethodPost) WithHeaders ¶

type ByProjectKeyMePasswordResetRequestBuilder ¶

type ByProjectKeyMePasswordResetRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePasswordResetRequestBuilder) Post ¶

* * This is the last step in the [password reset process of a Customer](/../api/projects/customers#password-reset-of-customer). * * Resetting a password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=true`. *

type ByProjectKeyMePasswordResetRequestMethodPost ¶

type ByProjectKeyMePasswordResetRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePasswordResetRequestMethodPost) Dump ¶

func (r *ByProjectKeyMePasswordResetRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMePasswordResetRequestMethodPost) Execute ¶

* * This is the last step in the [password reset process of a Customer](/../api/projects/customers#password-reset-of-customer). * * Resetting a password of the Customer produces the [CustomerPasswordUpdated](ctp:api:type:CustomerPasswordUpdatedMessage) Message with `reset=true`. *

func (*ByProjectKeyMePasswordResetRequestMethodPost) WithHeaders ¶

type ByProjectKeyMePaymentsByIDRequestBuilder ¶

type ByProjectKeyMePaymentsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePaymentsByIDRequestBuilder) Delete ¶

* * This endpoint can only delete a Payment when it has no [Transactions](ctp:api:type:Transaction). *

func (*ByProjectKeyMePaymentsByIDRequestBuilder) Get ¶

func (*ByProjectKeyMePaymentsByIDRequestBuilder) Post ¶

* * This endpoint can only update a Payment when it has no [Transactions](ctp:api:type:Transaction). *

type ByProjectKeyMePaymentsByIDRequestMethodDelete ¶

type ByProjectKeyMePaymentsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePaymentsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyMePaymentsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyMePaymentsByIDRequestMethodDelete) Execute ¶

* * This endpoint can only delete a Payment when it has no [Transactions](ctp:api:type:Transaction). *

func (*ByProjectKeyMePaymentsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyMePaymentsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyMePaymentsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyMePaymentsByIDRequestMethodDeleteInput ¶

type ByProjectKeyMePaymentsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyMePaymentsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyMePaymentsByIDRequestMethodGet ¶

type ByProjectKeyMePaymentsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePaymentsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyMePaymentsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMePaymentsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyMePaymentsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyMePaymentsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyMePaymentsByIDRequestMethodGetInput ¶

type ByProjectKeyMePaymentsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMePaymentsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyMePaymentsByIDRequestMethodPost ¶

type ByProjectKeyMePaymentsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePaymentsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyMePaymentsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMePaymentsByIDRequestMethodPost) Execute ¶

* * This endpoint can only update a Payment when it has no [Transactions](ctp:api:type:Transaction). *

func (*ByProjectKeyMePaymentsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyMePaymentsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyMePaymentsByIDRequestMethodPostInput ¶

type ByProjectKeyMePaymentsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMePaymentsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyMePaymentsKeyByKeyRequestBuilder ¶

type ByProjectKeyMePaymentsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePaymentsKeyByKeyRequestBuilder) Delete ¶

* * This endpoint can only delete a Payment when it has no [Transactions](ctp:api:type:Transaction). *

func (*ByProjectKeyMePaymentsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyMePaymentsKeyByKeyRequestBuilder) Post ¶

* * This endpoint can only update a Payment when it has no [Transactions](ctp:api:type:Transaction). *

type ByProjectKeyMePaymentsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyMePaymentsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodDelete) Execute ¶

* * This endpoint can only delete a Payment when it has no [Transactions](ctp:api:type:Transaction). *

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyMePaymentsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyMePaymentsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyMePaymentsKeyByKeyRequestMethodGet ¶

type ByProjectKeyMePaymentsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyMePaymentsKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyMePaymentsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyMePaymentsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyMePaymentsKeyByKeyRequestMethodPost ¶

type ByProjectKeyMePaymentsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyMePaymentsKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodPost) Execute ¶

* * This endpoint can only update a Payment when it has no [Transactions](ctp:api:type:Transaction). *

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyMePaymentsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyMePaymentsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMePaymentsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyMePaymentsRequestBuilder ¶

type ByProjectKeyMePaymentsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePaymentsRequestBuilder) Get ¶

func (*ByProjectKeyMePaymentsRequestBuilder) Post ¶

* * Creating a Payment produces the [PaymentCreated](ctp:api:type:PaymentCreatedMessage) Message. *

func (*ByProjectKeyMePaymentsRequestBuilder) WithId ¶

func (*ByProjectKeyMePaymentsRequestBuilder) WithKey ¶

type ByProjectKeyMePaymentsRequestMethodGet ¶

type ByProjectKeyMePaymentsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePaymentsRequestMethodGet) Dump ¶

func (r *ByProjectKeyMePaymentsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMePaymentsRequestMethodGet) Execute ¶

func (*ByProjectKeyMePaymentsRequestMethodGet) Expand ¶

func (*ByProjectKeyMePaymentsRequestMethodGet) Limit ¶

func (*ByProjectKeyMePaymentsRequestMethodGet) Offset ¶

func (*ByProjectKeyMePaymentsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyMePaymentsRequestMethodGet) Sort ¶

func (*ByProjectKeyMePaymentsRequestMethodGet) Where ¶

func (*ByProjectKeyMePaymentsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyMePaymentsRequestMethodGet) WithTotal ¶

type ByProjectKeyMePaymentsRequestMethodGetInput ¶

type ByProjectKeyMePaymentsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyMePaymentsRequestMethodGetInput) Values ¶

type ByProjectKeyMePaymentsRequestMethodPost ¶

type ByProjectKeyMePaymentsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMePaymentsRequestMethodPost) Dump ¶

func (r *ByProjectKeyMePaymentsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMePaymentsRequestMethodPost) Execute ¶

func (rb *ByProjectKeyMePaymentsRequestMethodPost) Execute(ctx context.Context) (result *MyPayment, err error)

* * Creating a Payment produces the [PaymentCreated](ctp:api:type:PaymentCreatedMessage) Message. *

func (*ByProjectKeyMePaymentsRequestMethodPost) Expand ¶

func (*ByProjectKeyMePaymentsRequestMethodPost) WithHeaders ¶

type ByProjectKeyMePaymentsRequestMethodPostInput ¶

type ByProjectKeyMePaymentsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMePaymentsRequestMethodPostInput) Values ¶

type ByProjectKeyMeQuoteRequestsByIDRequestBuilder ¶

type ByProjectKeyMeQuoteRequestsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuoteRequestsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyMeQuoteRequestsByIDRequestBuilder) Get ¶

func (*ByProjectKeyMeQuoteRequestsByIDRequestBuilder) Post ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodDelete ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodDeleteInput ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodGet ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeQuoteRequestsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodGetInput ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodPost ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeQuoteRequestsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodPostInput ¶

type ByProjectKeyMeQuoteRequestsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeQuoteRequestsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestBuilder ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodGet ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodPost ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeQuoteRequestsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyMeQuoteRequestsRequestBuilder ¶

type ByProjectKeyMeQuoteRequestsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuoteRequestsRequestBuilder) Get ¶

func (*ByProjectKeyMeQuoteRequestsRequestBuilder) Post ¶

func (*ByProjectKeyMeQuoteRequestsRequestBuilder) WithId ¶

func (*ByProjectKeyMeQuoteRequestsRequestBuilder) WithKey ¶

type ByProjectKeyMeQuoteRequestsRequestMethodGet ¶

type ByProjectKeyMeQuoteRequestsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuoteRequestsRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeQuoteRequestsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeQuoteRequestsRequestMethodGet) Execute ¶

func (*ByProjectKeyMeQuoteRequestsRequestMethodGet) Expand ¶

func (*ByProjectKeyMeQuoteRequestsRequestMethodGet) Limit ¶

func (*ByProjectKeyMeQuoteRequestsRequestMethodGet) Offset ¶

func (*ByProjectKeyMeQuoteRequestsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyMeQuoteRequestsRequestMethodGet) Sort ¶

func (*ByProjectKeyMeQuoteRequestsRequestMethodGet) Where ¶

func (*ByProjectKeyMeQuoteRequestsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyMeQuoteRequestsRequestMethodGet) WithTotal ¶

type ByProjectKeyMeQuoteRequestsRequestMethodGetInput ¶

type ByProjectKeyMeQuoteRequestsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyMeQuoteRequestsRequestMethodGetInput) Values ¶

type ByProjectKeyMeQuoteRequestsRequestMethodPost ¶

type ByProjectKeyMeQuoteRequestsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuoteRequestsRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeQuoteRequestsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeQuoteRequestsRequestMethodPost) Execute ¶

func (*ByProjectKeyMeQuoteRequestsRequestMethodPost) Expand ¶

func (*ByProjectKeyMeQuoteRequestsRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeQuoteRequestsRequestMethodPostInput ¶

type ByProjectKeyMeQuoteRequestsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeQuoteRequestsRequestMethodPostInput) Values ¶

type ByProjectKeyMeQuotesByIDRequestBuilder ¶

type ByProjectKeyMeQuotesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuotesByIDRequestBuilder) Get ¶

func (*ByProjectKeyMeQuotesByIDRequestBuilder) Post ¶

type ByProjectKeyMeQuotesByIDRequestMethodGet ¶

type ByProjectKeyMeQuotesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuotesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeQuotesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeQuotesByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyMeQuotesByIDRequestMethodGet) Execute(ctx context.Context) (result *Quote, err error)

func (*ByProjectKeyMeQuotesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyMeQuotesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeQuotesByIDRequestMethodGetInput ¶

type ByProjectKeyMeQuotesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeQuotesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyMeQuotesByIDRequestMethodPost ¶

type ByProjectKeyMeQuotesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuotesByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeQuotesByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeQuotesByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyMeQuotesByIDRequestMethodPost) Execute(ctx context.Context) (result *Quote, err error)

func (*ByProjectKeyMeQuotesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyMeQuotesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeQuotesByIDRequestMethodPostInput ¶

type ByProjectKeyMeQuotesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeQuotesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyMeQuotesKeyByKeyRequestBuilder ¶

type ByProjectKeyMeQuotesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuotesKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyMeQuotesKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyMeQuotesKeyByKeyRequestMethodGet ¶

type ByProjectKeyMeQuotesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuotesKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeQuotesKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeQuotesKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyMeQuotesKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyMeQuotesKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeQuotesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyMeQuotesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeQuotesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyMeQuotesKeyByKeyRequestMethodPost ¶

type ByProjectKeyMeQuotesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuotesKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeQuotesKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeQuotesKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyMeQuotesKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyMeQuotesKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeQuotesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyMeQuotesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeQuotesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyMeQuotesRequestBuilder ¶

type ByProjectKeyMeQuotesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuotesRequestBuilder) Get ¶

func (*ByProjectKeyMeQuotesRequestBuilder) WithId ¶

func (*ByProjectKeyMeQuotesRequestBuilder) WithKey ¶

type ByProjectKeyMeQuotesRequestMethodGet ¶

type ByProjectKeyMeQuotesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeQuotesRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeQuotesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeQuotesRequestMethodGet) Execute ¶

func (*ByProjectKeyMeQuotesRequestMethodGet) Expand ¶

func (*ByProjectKeyMeQuotesRequestMethodGet) Limit ¶

func (*ByProjectKeyMeQuotesRequestMethodGet) Offset ¶

func (*ByProjectKeyMeQuotesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyMeQuotesRequestMethodGet) Sort ¶

func (*ByProjectKeyMeQuotesRequestMethodGet) Where ¶

func (*ByProjectKeyMeQuotesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyMeQuotesRequestMethodGet) WithTotal ¶

type ByProjectKeyMeQuotesRequestMethodGetInput ¶

type ByProjectKeyMeQuotesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyMeQuotesRequestMethodGetInput) Values ¶

type ByProjectKeyMeRequestBuilder ¶

type ByProjectKeyMeRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeRequestBuilder) ActiveCart ¶

func (*ByProjectKeyMeRequestBuilder) BusinessUnits ¶

* * MyBusinessUnit creates and provides access to Business Units scoped to a specific user.

func (*ByProjectKeyMeRequestBuilder) Carts ¶

* * A shopping cart holds product variants and can be ordered.

func (*ByProjectKeyMeRequestBuilder) Delete ¶

func (*ByProjectKeyMeRequestBuilder) EmailConfirm ¶

func (*ByProjectKeyMeRequestBuilder) Get ¶

func (*ByProjectKeyMeRequestBuilder) Login ¶

func (*ByProjectKeyMeRequestBuilder) Orders ¶

* * An order can be created from a cart, usually after a checkout process has been completed.

func (*ByProjectKeyMeRequestBuilder) Password ¶

func (*ByProjectKeyMeRequestBuilder) Payments ¶

* * The My Payments endpoint creates and provides access to payments scoped to a specific user.

func (*ByProjectKeyMeRequestBuilder) Post ¶

func (*ByProjectKeyMeRequestBuilder) QuoteRequests ¶

* * The My Quote Requests endpoint creates and provides access to Quote Requests scoped to a specific user.

func (*ByProjectKeyMeRequestBuilder) Quotes ¶

* * The My Quote endpoint provides access to Quotes scoped to a specific user.

func (*ByProjectKeyMeRequestBuilder) ShoppingLists ¶

* * The My Shopping Lists endpoint creates and provides access to Shopping Lists scoped to a specific user.

func (*ByProjectKeyMeRequestBuilder) Signup ¶

type ByProjectKeyMeRequestMethodDelete ¶

type ByProjectKeyMeRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeRequestMethodDelete) Dump ¶

func (r *ByProjectKeyMeRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyMeRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyMeRequestMethodDelete) Execute(ctx context.Context) (result *Customer, err error)

func (*ByProjectKeyMeRequestMethodDelete) Version ¶

func (*ByProjectKeyMeRequestMethodDelete) WithHeaders ¶

func (*ByProjectKeyMeRequestMethodDelete) WithQueryParams ¶

type ByProjectKeyMeRequestMethodDeleteInput ¶

type ByProjectKeyMeRequestMethodDeleteInput struct {
	Version int
}

func (*ByProjectKeyMeRequestMethodDeleteInput) Values ¶

type ByProjectKeyMeRequestMethodGet ¶

type ByProjectKeyMeRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeRequestMethodGet) Execute ¶

func (rb *ByProjectKeyMeRequestMethodGet) Execute(ctx context.Context) (result *Customer, err error)

func (*ByProjectKeyMeRequestMethodGet) Expand ¶

func (*ByProjectKeyMeRequestMethodGet) Limit ¶

func (*ByProjectKeyMeRequestMethodGet) Offset ¶

func (*ByProjectKeyMeRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyMeRequestMethodGet) Sort ¶

func (*ByProjectKeyMeRequestMethodGet) Where ¶

func (*ByProjectKeyMeRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyMeRequestMethodGet) WithQueryParams ¶

func (*ByProjectKeyMeRequestMethodGet) WithTotal ¶

type ByProjectKeyMeRequestMethodGetInput ¶

type ByProjectKeyMeRequestMethodGetInput struct {
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Expand       []string
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyMeRequestMethodGetInput) Values ¶

type ByProjectKeyMeRequestMethodPost ¶

type ByProjectKeyMeRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeRequestMethodPost) Execute ¶

func (rb *ByProjectKeyMeRequestMethodPost) Execute(ctx context.Context) (result *Customer, err error)

func (*ByProjectKeyMeRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeShoppingListsByIDRequestBuilder ¶

type ByProjectKeyMeShoppingListsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeShoppingListsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyMeShoppingListsByIDRequestBuilder) Get ¶

func (*ByProjectKeyMeShoppingListsByIDRequestBuilder) Post ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodDelete ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeShoppingListsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyMeShoppingListsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyMeShoppingListsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyMeShoppingListsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyMeShoppingListsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodDeleteInput ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodDeleteInput struct {
	Expand  []string
	Version int
}

func (*ByProjectKeyMeShoppingListsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodGet ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeShoppingListsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeShoppingListsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeShoppingListsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyMeShoppingListsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyMeShoppingListsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodGetInput ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeShoppingListsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodPost ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeShoppingListsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeShoppingListsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeShoppingListsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyMeShoppingListsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyMeShoppingListsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodPostInput ¶

type ByProjectKeyMeShoppingListsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeShoppingListsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestBuilder ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodDeleteInput struct {
	Expand  []string
	Version int
}

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodGet ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodPost ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyMeShoppingListsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeShoppingListsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyMeShoppingListsRequestBuilder ¶

type ByProjectKeyMeShoppingListsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeShoppingListsRequestBuilder) Get ¶

func (*ByProjectKeyMeShoppingListsRequestBuilder) Post ¶

func (*ByProjectKeyMeShoppingListsRequestBuilder) WithId ¶

func (*ByProjectKeyMeShoppingListsRequestBuilder) WithKey ¶

type ByProjectKeyMeShoppingListsRequestMethodGet ¶

type ByProjectKeyMeShoppingListsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeShoppingListsRequestMethodGet) Dump ¶

func (r *ByProjectKeyMeShoppingListsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMeShoppingListsRequestMethodGet) Execute ¶

func (*ByProjectKeyMeShoppingListsRequestMethodGet) Expand ¶

func (*ByProjectKeyMeShoppingListsRequestMethodGet) Limit ¶

func (*ByProjectKeyMeShoppingListsRequestMethodGet) Offset ¶

func (*ByProjectKeyMeShoppingListsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyMeShoppingListsRequestMethodGet) Sort ¶

func (*ByProjectKeyMeShoppingListsRequestMethodGet) Where ¶

func (*ByProjectKeyMeShoppingListsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyMeShoppingListsRequestMethodGet) WithTotal ¶

type ByProjectKeyMeShoppingListsRequestMethodGetInput ¶

type ByProjectKeyMeShoppingListsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyMeShoppingListsRequestMethodGetInput) Values ¶

type ByProjectKeyMeShoppingListsRequestMethodPost ¶

type ByProjectKeyMeShoppingListsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeShoppingListsRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeShoppingListsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeShoppingListsRequestMethodPost) Execute ¶

func (*ByProjectKeyMeShoppingListsRequestMethodPost) Expand ¶

func (*ByProjectKeyMeShoppingListsRequestMethodPost) WithHeaders ¶

type ByProjectKeyMeShoppingListsRequestMethodPostInput ¶

type ByProjectKeyMeShoppingListsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyMeShoppingListsRequestMethodPostInput) Values ¶

type ByProjectKeyMeSignupRequestBuilder ¶

type ByProjectKeyMeSignupRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeSignupRequestBuilder) Post ¶

* * If used with an [access token for an anonymous session](ctp:api:type:AnonymousSession), all Orders and Carts that belong to the `anonymousId` are assigned to the newly created Customer. * * Creating a Customer produces the [CustomerCreated](ctp:api:type:CustomerCreatedMessage) Message. *

type ByProjectKeyMeSignupRequestMethodPost ¶

type ByProjectKeyMeSignupRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMeSignupRequestMethodPost) Dump ¶

func (r *ByProjectKeyMeSignupRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyMeSignupRequestMethodPost) Execute ¶

* * If used with an [access token for an anonymous session](ctp:api:type:AnonymousSession), all Orders and Carts that belong to the `anonymousId` are assigned to the newly created Customer. * * Creating a Customer produces the [CustomerCreated](ctp:api:type:CustomerCreatedMessage) Message. *

func (*ByProjectKeyMeSignupRequestMethodPost) WithHeaders ¶

type ByProjectKeyMessagesByIDRequestBuilder ¶

type ByProjectKeyMessagesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMessagesByIDRequestBuilder) Get ¶

* * Deprecated scope: `view_orders:{projectKey}`

type ByProjectKeyMessagesByIDRequestMethodGet ¶

type ByProjectKeyMessagesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMessagesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyMessagesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMessagesByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyMessagesByIDRequestMethodGet) Execute(ctx context.Context) (result *Message, err error)

* * Deprecated scope: `view_orders:{projectKey}`

func (*ByProjectKeyMessagesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyMessagesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyMessagesByIDRequestMethodGetInput ¶

type ByProjectKeyMessagesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyMessagesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyMessagesRequestBuilder ¶

type ByProjectKeyMessagesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMessagesRequestBuilder) Get ¶

* * Deprecated scope: `view_orders:{projectKey}`

func (*ByProjectKeyMessagesRequestBuilder) WithId ¶

type ByProjectKeyMessagesRequestMethodGet ¶

type ByProjectKeyMessagesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyMessagesRequestMethodGet) Dump ¶

func (r *ByProjectKeyMessagesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyMessagesRequestMethodGet) Execute ¶

* * Deprecated scope: `view_orders:{projectKey}`

func (*ByProjectKeyMessagesRequestMethodGet) Expand ¶

func (*ByProjectKeyMessagesRequestMethodGet) Limit ¶

func (*ByProjectKeyMessagesRequestMethodGet) Offset ¶

func (*ByProjectKeyMessagesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyMessagesRequestMethodGet) Sort ¶

func (*ByProjectKeyMessagesRequestMethodGet) Where ¶

func (*ByProjectKeyMessagesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyMessagesRequestMethodGet) WithTotal ¶

type ByProjectKeyMessagesRequestMethodGetInput ¶

type ByProjectKeyMessagesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyMessagesRequestMethodGetInput) Values ¶

type ByProjectKeyOrdersByIDRequestBuilder ¶

type ByProjectKeyOrdersByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersByIDRequestBuilder) Delete ¶

func (*ByProjectKeyOrdersByIDRequestBuilder) Get ¶

func (*ByProjectKeyOrdersByIDRequestBuilder) Post ¶

type ByProjectKeyOrdersByIDRequestMethodDelete ¶

type ByProjectKeyOrdersByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyOrdersByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyOrdersByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyOrdersByIDRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyOrdersByIDRequestMethodDelete) Execute(ctx context.Context) (result *Order, err error)

func (*ByProjectKeyOrdersByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyOrdersByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyOrdersByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyOrdersByIDRequestMethodDeleteInput ¶

type ByProjectKeyOrdersByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyOrdersByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyOrdersByIDRequestMethodGet ¶

type ByProjectKeyOrdersByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyOrdersByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyOrdersByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyOrdersByIDRequestMethodGet) Execute(ctx context.Context) (result *Order, err error)

func (*ByProjectKeyOrdersByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyOrdersByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyOrdersByIDRequestMethodGetInput ¶

type ByProjectKeyOrdersByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyOrdersByIDRequestMethodGetInput) Values ¶

type ByProjectKeyOrdersByIDRequestMethodPost ¶

type ByProjectKeyOrdersByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyOrdersByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyOrdersByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyOrdersByIDRequestMethodPost) Execute(ctx context.Context) (result *Order, err error)

func (*ByProjectKeyOrdersByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyOrdersByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyOrdersByIDRequestMethodPostInput ¶

type ByProjectKeyOrdersByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyOrdersByIDRequestMethodPostInput) Values ¶

type ByProjectKeyOrdersEditsByIDApplyRequestBuilder ¶

type ByProjectKeyOrdersEditsByIDApplyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsByIDApplyRequestBuilder) Post ¶

type ByProjectKeyOrdersEditsByIDApplyRequestMethodPost ¶

type ByProjectKeyOrdersEditsByIDApplyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsByIDApplyRequestMethodPost) Dump ¶

func (*ByProjectKeyOrdersEditsByIDApplyRequestMethodPost) Execute ¶

func (*ByProjectKeyOrdersEditsByIDApplyRequestMethodPost) WithHeaders ¶

type ByProjectKeyOrdersEditsByIDRequestBuilder ¶

type ByProjectKeyOrdersEditsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsByIDRequestBuilder) Apply ¶

func (*ByProjectKeyOrdersEditsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyOrdersEditsByIDRequestBuilder) Get ¶

func (*ByProjectKeyOrdersEditsByIDRequestBuilder) Post ¶

type ByProjectKeyOrdersEditsByIDRequestMethodDelete ¶

type ByProjectKeyOrdersEditsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyOrdersEditsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyOrdersEditsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyOrdersEditsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyOrdersEditsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyOrdersEditsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyOrdersEditsByIDRequestMethodDeleteInput ¶

type ByProjectKeyOrdersEditsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyOrdersEditsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyOrdersEditsByIDRequestMethodGet ¶

type ByProjectKeyOrdersEditsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyOrdersEditsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyOrdersEditsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyOrdersEditsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyOrdersEditsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyOrdersEditsByIDRequestMethodGetInput ¶

type ByProjectKeyOrdersEditsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyOrdersEditsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyOrdersEditsByIDRequestMethodPost ¶

type ByProjectKeyOrdersEditsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyOrdersEditsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyOrdersEditsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyOrdersEditsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyOrdersEditsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyOrdersEditsByIDRequestMethodPostInput ¶

type ByProjectKeyOrdersEditsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyOrdersEditsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestBuilder ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyOrdersEditsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyOrdersEditsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodGet ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyOrdersEditsKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodPost ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyOrdersEditsKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyOrdersEditsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyOrdersEditsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyOrdersEditsRequestBuilder ¶

type ByProjectKeyOrdersEditsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsRequestBuilder) Get ¶

func (*ByProjectKeyOrdersEditsRequestBuilder) Post ¶

func (*ByProjectKeyOrdersEditsRequestBuilder) WithId ¶

func (*ByProjectKeyOrdersEditsRequestBuilder) WithKey ¶

type ByProjectKeyOrdersEditsRequestMethodGet ¶

type ByProjectKeyOrdersEditsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsRequestMethodGet) Dump ¶

func (r *ByProjectKeyOrdersEditsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyOrdersEditsRequestMethodGet) Execute ¶

func (*ByProjectKeyOrdersEditsRequestMethodGet) Expand ¶

func (*ByProjectKeyOrdersEditsRequestMethodGet) Limit ¶

func (*ByProjectKeyOrdersEditsRequestMethodGet) Offset ¶

func (*ByProjectKeyOrdersEditsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyOrdersEditsRequestMethodGet) Sort ¶

func (*ByProjectKeyOrdersEditsRequestMethodGet) Where ¶

func (*ByProjectKeyOrdersEditsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyOrdersEditsRequestMethodGet) WithTotal ¶

type ByProjectKeyOrdersEditsRequestMethodGetInput ¶

type ByProjectKeyOrdersEditsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyOrdersEditsRequestMethodGetInput) Values ¶

type ByProjectKeyOrdersEditsRequestMethodPost ¶

type ByProjectKeyOrdersEditsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersEditsRequestMethodPost) Dump ¶

func (r *ByProjectKeyOrdersEditsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyOrdersEditsRequestMethodPost) Execute ¶

func (*ByProjectKeyOrdersEditsRequestMethodPost) Expand ¶

func (*ByProjectKeyOrdersEditsRequestMethodPost) WithHeaders ¶

type ByProjectKeyOrdersEditsRequestMethodPostInput ¶

type ByProjectKeyOrdersEditsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyOrdersEditsRequestMethodPostInput) Values ¶

type ByProjectKeyOrdersImportRequestBuilder ¶

type ByProjectKeyOrdersImportRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersImportRequestBuilder) Post ¶

* * Create an Order by Import

type ByProjectKeyOrdersImportRequestMethodPost ¶

type ByProjectKeyOrdersImportRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersImportRequestMethodPost) Dump ¶

func (r *ByProjectKeyOrdersImportRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyOrdersImportRequestMethodPost) Execute ¶

func (rb *ByProjectKeyOrdersImportRequestMethodPost) Execute(ctx context.Context) (result *Order, err error)

* * Create an Order by Import

func (*ByProjectKeyOrdersImportRequestMethodPost) WithHeaders ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestBuilder ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestBuilder) Delete ¶

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestBuilder) Get ¶

* * In case the orderNumber does not match the regular expression [a-zA-Z0-9_\-]+, * it should be provided in URL-encoded format. *

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestBuilder) Post ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodDelete ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) Dump ¶

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) Execute ¶

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) Expand ¶

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) Version ¶

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodDelete) WithHeaders ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodDeleteInput ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodDeleteInput) Values ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodGet ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodGet) Dump ¶

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodGet) Execute ¶

* * In case the orderNumber does not match the regular expression [a-zA-Z0-9_\-]+, * it should be provided in URL-encoded format. *

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodGet) Expand ¶

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodGet) WithHeaders ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodGetInput ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodGetInput) Values ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodPost ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodPost) Dump ¶

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodPost) Execute ¶

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodPost) Expand ¶

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodPost) WithHeaders ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodPostInput ¶

type ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyOrdersOrderNumberByOrderNumberRequestMethodPostInput) Values ¶

type ByProjectKeyOrdersQuotesRequestBuilder ¶

type ByProjectKeyOrdersQuotesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersQuotesRequestBuilder) Post ¶

* * Create an Order from a Quote

type ByProjectKeyOrdersQuotesRequestMethodPost ¶

type ByProjectKeyOrdersQuotesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersQuotesRequestMethodPost) Dump ¶

func (r *ByProjectKeyOrdersQuotesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyOrdersQuotesRequestMethodPost) Execute ¶

func (rb *ByProjectKeyOrdersQuotesRequestMethodPost) Execute(ctx context.Context) (result *Order, err error)

* * Create an Order from a Quote

func (*ByProjectKeyOrdersQuotesRequestMethodPost) WithHeaders ¶

type ByProjectKeyOrdersRequestBuilder ¶

type ByProjectKeyOrdersRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersRequestBuilder) Edits ¶

* * OrderEdit are containers for financial changes after an Order has been placed.

func (*ByProjectKeyOrdersRequestBuilder) Get ¶

func (*ByProjectKeyOrdersRequestBuilder) ImportOrder ¶

func (*ByProjectKeyOrdersRequestBuilder) OrderQuote ¶

func (*ByProjectKeyOrdersRequestBuilder) Post ¶

* * Creates an order from a Cart. * The cart must have a shipping address set before creating an order. * When using the Platform TaxMode, the shipping address is used for tax calculation. *

func (*ByProjectKeyOrdersRequestBuilder) Search ¶

* * This endpoint provides high performance search queries over Orders. The order search allows searching through all orders (currently supporting a limit of the 10.000.000 newest orders) in your project. *

func (*ByProjectKeyOrdersRequestBuilder) WithId ¶

func (*ByProjectKeyOrdersRequestBuilder) WithOrderNumber ¶

type ByProjectKeyOrdersRequestMethodGet ¶

type ByProjectKeyOrdersRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersRequestMethodGet) Dump ¶

func (r *ByProjectKeyOrdersRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyOrdersRequestMethodGet) Execute ¶

func (*ByProjectKeyOrdersRequestMethodGet) Expand ¶

func (*ByProjectKeyOrdersRequestMethodGet) Limit ¶

func (*ByProjectKeyOrdersRequestMethodGet) Offset ¶

func (*ByProjectKeyOrdersRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyOrdersRequestMethodGet) Sort ¶

func (*ByProjectKeyOrdersRequestMethodGet) Where ¶

func (*ByProjectKeyOrdersRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyOrdersRequestMethodGet) WithQueryParams ¶

func (*ByProjectKeyOrdersRequestMethodGet) WithTotal ¶

type ByProjectKeyOrdersRequestMethodGetInput ¶

type ByProjectKeyOrdersRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyOrdersRequestMethodGetInput) Values ¶

type ByProjectKeyOrdersRequestMethodPost ¶

type ByProjectKeyOrdersRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersRequestMethodPost) Dump ¶

func (r *ByProjectKeyOrdersRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyOrdersRequestMethodPost) Execute ¶

func (rb *ByProjectKeyOrdersRequestMethodPost) Execute(ctx context.Context) (result *Order, err error)

* * Creates an order from a Cart. * The cart must have a shipping address set before creating an order. * When using the Platform TaxMode, the shipping address is used for tax calculation. *

func (*ByProjectKeyOrdersRequestMethodPost) Expand ¶

func (*ByProjectKeyOrdersRequestMethodPost) WithHeaders ¶

type ByProjectKeyOrdersRequestMethodPostInput ¶

type ByProjectKeyOrdersRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyOrdersRequestMethodPostInput) Values ¶

type ByProjectKeyOrdersSearchRequestBuilder ¶

type ByProjectKeyOrdersSearchRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersSearchRequestBuilder) Head ¶

* * Checks whether a search index for the Project's Orders exists.

func (*ByProjectKeyOrdersSearchRequestBuilder) Post ¶

type ByProjectKeyOrdersSearchRequestMethodHead ¶

type ByProjectKeyOrdersSearchRequestMethodHead struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersSearchRequestMethodHead) Dump ¶

func (r *ByProjectKeyOrdersSearchRequestMethodHead) Dump() map[string]interface{}

func (*ByProjectKeyOrdersSearchRequestMethodHead) Execute ¶

* * Checks whether a search index for the Project's Orders exists.

func (*ByProjectKeyOrdersSearchRequestMethodHead) WithHeaders ¶

type ByProjectKeyOrdersSearchRequestMethodPost ¶

type ByProjectKeyOrdersSearchRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyOrdersSearchRequestMethodPost) Dump ¶

func (r *ByProjectKeyOrdersSearchRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyOrdersSearchRequestMethodPost) Execute ¶

func (*ByProjectKeyOrdersSearchRequestMethodPost) WithHeaders ¶

type ByProjectKeyPaymentsByIDRequestBuilder ¶

type ByProjectKeyPaymentsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyPaymentsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyPaymentsByIDRequestBuilder) Get ¶

func (*ByProjectKeyPaymentsByIDRequestBuilder) Post ¶

type ByProjectKeyPaymentsByIDRequestMethodDelete ¶

type ByProjectKeyPaymentsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyPaymentsByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyPaymentsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyPaymentsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyPaymentsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyPaymentsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyPaymentsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyPaymentsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyPaymentsByIDRequestMethodDeleteInput ¶

type ByProjectKeyPaymentsByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyPaymentsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyPaymentsByIDRequestMethodGet ¶

type ByProjectKeyPaymentsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyPaymentsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyPaymentsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyPaymentsByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyPaymentsByIDRequestMethodGet) Execute(ctx context.Context) (result *Payment, err error)

func (*ByProjectKeyPaymentsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyPaymentsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyPaymentsByIDRequestMethodGetInput ¶

type ByProjectKeyPaymentsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyPaymentsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyPaymentsByIDRequestMethodPost ¶

type ByProjectKeyPaymentsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyPaymentsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyPaymentsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyPaymentsByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyPaymentsByIDRequestMethodPost) Execute(ctx context.Context) (result *Payment, err error)

func (*ByProjectKeyPaymentsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyPaymentsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyPaymentsByIDRequestMethodPostInput ¶

type ByProjectKeyPaymentsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyPaymentsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyPaymentsKeyByKeyRequestBuilder ¶

type ByProjectKeyPaymentsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyPaymentsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyPaymentsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyPaymentsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyPaymentsKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodGet ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyPaymentsKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodPost ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyPaymentsKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyPaymentsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyPaymentsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyPaymentsRequestBuilder ¶

type ByProjectKeyPaymentsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyPaymentsRequestBuilder) Get ¶

func (*ByProjectKeyPaymentsRequestBuilder) Post ¶

* * Creating a Payment produces the [PaymentCreated](ctp:api:type:PaymentCreatedMessage) Message. *

func (*ByProjectKeyPaymentsRequestBuilder) WithId ¶

func (*ByProjectKeyPaymentsRequestBuilder) WithKey ¶

type ByProjectKeyPaymentsRequestMethodGet ¶

type ByProjectKeyPaymentsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyPaymentsRequestMethodGet) Dump ¶

func (r *ByProjectKeyPaymentsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyPaymentsRequestMethodGet) Execute ¶

func (*ByProjectKeyPaymentsRequestMethodGet) Expand ¶

func (*ByProjectKeyPaymentsRequestMethodGet) Limit ¶

func (*ByProjectKeyPaymentsRequestMethodGet) Offset ¶

func (*ByProjectKeyPaymentsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyPaymentsRequestMethodGet) Sort ¶

func (*ByProjectKeyPaymentsRequestMethodGet) Where ¶

func (*ByProjectKeyPaymentsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyPaymentsRequestMethodGet) WithTotal ¶

type ByProjectKeyPaymentsRequestMethodGetInput ¶

type ByProjectKeyPaymentsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyPaymentsRequestMethodGetInput) Values ¶

type ByProjectKeyPaymentsRequestMethodPost ¶

type ByProjectKeyPaymentsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyPaymentsRequestMethodPost) Dump ¶

func (r *ByProjectKeyPaymentsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyPaymentsRequestMethodPost) Execute ¶

func (rb *ByProjectKeyPaymentsRequestMethodPost) Execute(ctx context.Context) (result *Payment, err error)

* * Creating a Payment produces the [PaymentCreated](ctp:api:type:PaymentCreatedMessage) Message. *

func (*ByProjectKeyPaymentsRequestMethodPost) Expand ¶

func (*ByProjectKeyPaymentsRequestMethodPost) WithHeaders ¶

type ByProjectKeyPaymentsRequestMethodPostInput ¶

type ByProjectKeyPaymentsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyPaymentsRequestMethodPostInput) Values ¶

type ByProjectKeyProductDiscountsByIDRequestBuilder ¶

type ByProjectKeyProductDiscountsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyProductDiscountsByIDRequestBuilder) Get ¶

func (*ByProjectKeyProductDiscountsByIDRequestBuilder) Post ¶

type ByProjectKeyProductDiscountsByIDRequestMethodDelete ¶

type ByProjectKeyProductDiscountsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyProductDiscountsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyProductDiscountsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyProductDiscountsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyProductDiscountsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyProductDiscountsByIDRequestMethodDeleteInput ¶

type ByProjectKeyProductDiscountsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyProductDiscountsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyProductDiscountsByIDRequestMethodGet ¶

type ByProjectKeyProductDiscountsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyProductDiscountsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyProductDiscountsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyProductDiscountsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyProductDiscountsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyProductDiscountsByIDRequestMethodGetInput ¶

type ByProjectKeyProductDiscountsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyProductDiscountsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyProductDiscountsByIDRequestMethodPost ¶

type ByProjectKeyProductDiscountsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyProductDiscountsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyProductDiscountsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyProductDiscountsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductDiscountsByIDRequestMethodPostInput ¶

type ByProjectKeyProductDiscountsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyProductDiscountsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestBuilder ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodGet ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodPost ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyProductDiscountsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyProductDiscountsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyProductDiscountsMatchingRequestBuilder ¶

type ByProjectKeyProductDiscountsMatchingRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsMatchingRequestBuilder) Post ¶

* * This endpoint can be used to simulate which Product Discounts would be applied if a specified Product Variant had a specified Price. * Given Product and Product Variant IDs and a Price, this endpoint will return the ProductDiscount(ctp:api:type:ProductDiscount) that would have been applied to that Price. * * If a Product Discount could not be found that could be applied to the Price of a Product Variant, a [NoMatchingProductDiscountFound](ctp:api:type:NoMatchingProductDiscountFoundError) error is returned. *

type ByProjectKeyProductDiscountsMatchingRequestMethodPost ¶

type ByProjectKeyProductDiscountsMatchingRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsMatchingRequestMethodPost) Dump ¶

func (*ByProjectKeyProductDiscountsMatchingRequestMethodPost) Execute ¶

* * This endpoint can be used to simulate which Product Discounts would be applied if a specified Product Variant had a specified Price. * Given Product and Product Variant IDs and a Price, this endpoint will return the ProductDiscount(ctp:api:type:ProductDiscount) that would have been applied to that Price. * * If a Product Discount could not be found that could be applied to the Price of a Product Variant, a [NoMatchingProductDiscountFound](ctp:api:type:NoMatchingProductDiscountFoundError) error is returned. *

func (*ByProjectKeyProductDiscountsMatchingRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductDiscountsRequestBuilder ¶

type ByProjectKeyProductDiscountsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsRequestBuilder) Get ¶

func (*ByProjectKeyProductDiscountsRequestBuilder) Matching ¶

func (*ByProjectKeyProductDiscountsRequestBuilder) Post ¶

func (*ByProjectKeyProductDiscountsRequestBuilder) WithId ¶

func (*ByProjectKeyProductDiscountsRequestBuilder) WithKey ¶

type ByProjectKeyProductDiscountsRequestMethodGet ¶

type ByProjectKeyProductDiscountsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsRequestMethodGet) Dump ¶

func (r *ByProjectKeyProductDiscountsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyProductDiscountsRequestMethodGet) Execute ¶

func (*ByProjectKeyProductDiscountsRequestMethodGet) Expand ¶

func (*ByProjectKeyProductDiscountsRequestMethodGet) Limit ¶

func (*ByProjectKeyProductDiscountsRequestMethodGet) Offset ¶

func (*ByProjectKeyProductDiscountsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyProductDiscountsRequestMethodGet) Sort ¶

func (*ByProjectKeyProductDiscountsRequestMethodGet) Where ¶

func (*ByProjectKeyProductDiscountsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyProductDiscountsRequestMethodGet) WithTotal ¶

type ByProjectKeyProductDiscountsRequestMethodGetInput ¶

type ByProjectKeyProductDiscountsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyProductDiscountsRequestMethodGetInput) Values ¶

type ByProjectKeyProductDiscountsRequestMethodPost ¶

type ByProjectKeyProductDiscountsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductDiscountsRequestMethodPost) Dump ¶

func (r *ByProjectKeyProductDiscountsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyProductDiscountsRequestMethodPost) Execute ¶

func (*ByProjectKeyProductDiscountsRequestMethodPost) Expand ¶

func (*ByProjectKeyProductDiscountsRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductDiscountsRequestMethodPostInput ¶

type ByProjectKeyProductDiscountsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyProductDiscountsRequestMethodPostInput) Values ¶

type ByProjectKeyProductProjectionsByIDRequestBuilder ¶

type ByProjectKeyProductProjectionsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductProjectionsByIDRequestBuilder) Get ¶

* * Gets the current or staged representation of a Product(ctp:api:type:Product) by its ID. When used with an API Client that has the `view_published_products:{projectKey}` scope, this endpoint only returns published (current) Product Projections. *

type ByProjectKeyProductProjectionsByIDRequestMethodGet ¶

type ByProjectKeyProductProjectionsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductProjectionsByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyProductProjectionsByIDRequestMethodGet) Execute ¶

* * Gets the current or staged representation of a Product(ctp:api:type:Product) by its ID. When used with an API Client that has the `view_published_products:{projectKey}` scope, this endpoint only returns published (current) Product Projections. *

func (*ByProjectKeyProductProjectionsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyProductProjectionsByIDRequestMethodGet) LocaleProjection ¶

func (*ByProjectKeyProductProjectionsByIDRequestMethodGet) PriceChannel ¶

func (*ByProjectKeyProductProjectionsByIDRequestMethodGet) PriceCountry ¶

func (*ByProjectKeyProductProjectionsByIDRequestMethodGet) PriceCurrency ¶

func (*ByProjectKeyProductProjectionsByIDRequestMethodGet) PriceCustomerGroup ¶

func (*ByProjectKeyProductProjectionsByIDRequestMethodGet) Staged ¶

func (*ByProjectKeyProductProjectionsByIDRequestMethodGet) StoreProjection ¶

func (*ByProjectKeyProductProjectionsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyProductProjectionsByIDRequestMethodGetInput ¶

type ByProjectKeyProductProjectionsByIDRequestMethodGetInput struct {
	Staged             *bool
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	StoreProjection    *string
	Expand             []string
}

func (*ByProjectKeyProductProjectionsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyProductProjectionsKeyByKeyRequestBuilder ¶

type ByProjectKeyProductProjectionsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductProjectionsKeyByKeyRequestBuilder) Get ¶

* * Gets the current or staged representation of a Product(ctp:api:type:Product) found by Key. * When used with an API Client that has the `view_published_products:{projectKey}` scope, * this endpoint only returns published (current) Product Projections. *

type ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet ¶

type ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet) Execute ¶

* * Gets the current or staged representation of a Product(ctp:api:type:Product) found by Key. * When used with an API Client that has the `view_published_products:{projectKey}` scope, * this endpoint only returns published (current) Product Projections. *

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet) LocaleProjection ¶

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet) PriceChannel ¶

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet) PriceCountry ¶

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet) PriceCurrency ¶

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet) PriceCustomerGroup ¶

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet) Staged ¶

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet) StoreProjection ¶

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyProductProjectionsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyProductProjectionsKeyByKeyRequestMethodGetInput struct {
	Staged             *bool
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	StoreProjection    *string
	Expand             []string
}

func (*ByProjectKeyProductProjectionsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyProductProjectionsRequestBuilder ¶

type ByProjectKeyProductProjectionsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductProjectionsRequestBuilder) Get ¶

* * Use the Product Projections query endpoint to get the current or staged representations of Products. * When used with an API Client that has the `view_published_products:{projectKey}` scope, * this endpoint only returns published (current) Product Projections. *

func (*ByProjectKeyProductProjectionsRequestBuilder) Search ¶

* * This endpoint provides high performance search queries over ProductProjections. The query result contains the * ProductProjections for which at least one ProductVariant matches the search query. This means that variants can * be included in the result also for which the search query does not match. To determine which ProductVariants match * the search query, the returned ProductProjections include the additional field isMatchingVariant. *

func (*ByProjectKeyProductProjectionsRequestBuilder) Suggest ¶

* * The source of data for suggestions is the searchKeyword field in a product

func (*ByProjectKeyProductProjectionsRequestBuilder) WithId ¶

func (*ByProjectKeyProductProjectionsRequestBuilder) WithKey ¶

type ByProjectKeyProductProjectionsRequestMethodGet ¶

type ByProjectKeyProductProjectionsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductProjectionsRequestMethodGet) Dump ¶

func (r *ByProjectKeyProductProjectionsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyProductProjectionsRequestMethodGet) Execute ¶

* * Use the Product Projections query endpoint to get the current or staged representations of Products. * When used with an API Client that has the `view_published_products:{projectKey}` scope, * this endpoint only returns published (current) Product Projections. *

func (*ByProjectKeyProductProjectionsRequestMethodGet) Expand ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) Limit ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) LocaleProjection ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) Offset ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) PriceChannel ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) PriceCountry ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) PriceCurrency ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) PriceCustomerGroup ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) Sort ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) Staged ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) StoreProjection ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) Where ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyProductProjectionsRequestMethodGet) WithTotal ¶

type ByProjectKeyProductProjectionsRequestMethodGetInput ¶

type ByProjectKeyProductProjectionsRequestMethodGetInput struct {
	Staged             *bool
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	StoreProjection    *string
	Expand             []string
	Sort               []string
	Limit              *int
	Offset             *int
	WithTotal          *bool
	Where              []string
	PredicateVar       map[string][]string
}

func (*ByProjectKeyProductProjectionsRequestMethodGetInput) Values ¶

type ByProjectKeyProductProjectionsSearchRequestBuilder ¶

type ByProjectKeyProductProjectionsSearchRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductProjectionsSearchRequestBuilder) Get ¶

* * Product Projection Search

func (*ByProjectKeyProductProjectionsSearchRequestBuilder) Post ¶

* * Product Projection Search

type ByProjectKeyProductProjectionsSearchRequestMethodGet ¶

type ByProjectKeyProductProjectionsSearchRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) Dump ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) Execute ¶

* * Product Projection Search

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) Expand ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) Facet ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) Filter ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) FilterFacets ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) FilterQuery ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) Fuzzy ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) FuzzyLevel ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) Limit ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) LocaleProjection ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) MarkMatchingVariants ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) Offset ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) PriceChannel ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) PriceCountry ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) PriceCurrency ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) PriceCustomerGroup ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) Sort ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) Staged ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) StoreProjection ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) Text ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodGet) WithTotal ¶

type ByProjectKeyProductProjectionsSearchRequestMethodGetInput ¶

type ByProjectKeyProductProjectionsSearchRequestMethodGetInput struct {
	Fuzzy                *bool
	FuzzyLevel           *float64
	MarkMatchingVariants *bool
	Filter               []string
	FilterFacets         []string
	FilterQuery          []string
	Facet                []string
	Text                 map[string][]string
	Sort                 []string
	Limit                *int
	Offset               *int
	WithTotal            *bool
	Staged               *bool
	PriceCurrency        *string
	PriceCountry         *string
	PriceCustomerGroup   *string
	PriceChannel         *string
	LocaleProjection     []string
	StoreProjection      *string
	Expand               []string
}

func (*ByProjectKeyProductProjectionsSearchRequestMethodGetInput) Values ¶

type ByProjectKeyProductProjectionsSearchRequestMethodPost ¶

type ByProjectKeyProductProjectionsSearchRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductProjectionsSearchRequestMethodPost) Dump ¶

func (*ByProjectKeyProductProjectionsSearchRequestMethodPost) Execute ¶

* * Product Projection Search

func (*ByProjectKeyProductProjectionsSearchRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductProjectionsSuggestRequestBuilder ¶

type ByProjectKeyProductProjectionsSuggestRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductProjectionsSuggestRequestBuilder) Get ¶

type ByProjectKeyProductProjectionsSuggestRequestMethodGet ¶

type ByProjectKeyProductProjectionsSuggestRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductProjectionsSuggestRequestMethodGet) Dump ¶

func (*ByProjectKeyProductProjectionsSuggestRequestMethodGet) Execute ¶

func (*ByProjectKeyProductProjectionsSuggestRequestMethodGet) Fuzzy ¶

func (*ByProjectKeyProductProjectionsSuggestRequestMethodGet) Limit ¶

func (*ByProjectKeyProductProjectionsSuggestRequestMethodGet) Offset ¶

func (*ByProjectKeyProductProjectionsSuggestRequestMethodGet) SearchKeywords ¶

func (*ByProjectKeyProductProjectionsSuggestRequestMethodGet) Sort ¶

func (*ByProjectKeyProductProjectionsSuggestRequestMethodGet) Staged ¶

func (*ByProjectKeyProductProjectionsSuggestRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyProductProjectionsSuggestRequestMethodGet) WithTotal ¶

type ByProjectKeyProductProjectionsSuggestRequestMethodGetInput ¶

type ByProjectKeyProductProjectionsSuggestRequestMethodGetInput struct {
	Fuzzy          *bool
	SearchKeywords map[string][]string
	Sort           []string
	Limit          *int
	Offset         *int
	WithTotal      *bool
	Staged         *bool
}

func (*ByProjectKeyProductProjectionsSuggestRequestMethodGetInput) Values ¶

type ByProjectKeyProductSelectionsByIDProductsRequestBuilder ¶

type ByProjectKeyProductSelectionsByIDProductsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsByIDProductsRequestBuilder) Get ¶

type ByProjectKeyProductSelectionsByIDProductsRequestMethodGet ¶

type ByProjectKeyProductSelectionsByIDProductsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsByIDProductsRequestMethodGet) Dump ¶

func (*ByProjectKeyProductSelectionsByIDProductsRequestMethodGet) Execute ¶

func (*ByProjectKeyProductSelectionsByIDProductsRequestMethodGet) Expand ¶

func (*ByProjectKeyProductSelectionsByIDProductsRequestMethodGet) Limit ¶

func (*ByProjectKeyProductSelectionsByIDProductsRequestMethodGet) Offset ¶

func (*ByProjectKeyProductSelectionsByIDProductsRequestMethodGet) Sort ¶

func (*ByProjectKeyProductSelectionsByIDProductsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyProductSelectionsByIDProductsRequestMethodGet) WithTotal ¶

type ByProjectKeyProductSelectionsByIDProductsRequestMethodGetInput ¶

type ByProjectKeyProductSelectionsByIDProductsRequestMethodGetInput struct {
	Expand    []string
	Limit     *int
	Offset    *int
	WithTotal *bool
	Sort      []string
}

func (*ByProjectKeyProductSelectionsByIDProductsRequestMethodGetInput) Values ¶

type ByProjectKeyProductSelectionsByIDRequestBuilder ¶

type ByProjectKeyProductSelectionsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsByIDRequestBuilder) Delete ¶

* * Deletion will only succeed if the Product Selection is not assigned to any Store(/../api/projects/stores#store).

func (*ByProjectKeyProductSelectionsByIDRequestBuilder) Get ¶

func (*ByProjectKeyProductSelectionsByIDRequestBuilder) Post ¶

func (*ByProjectKeyProductSelectionsByIDRequestBuilder) Products ¶

type ByProjectKeyProductSelectionsByIDRequestMethodDelete ¶

type ByProjectKeyProductSelectionsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyProductSelectionsByIDRequestMethodDelete) Execute ¶

* * Deletion will only succeed if the Product Selection is not assigned to any Store(/../api/projects/stores#store).

func (*ByProjectKeyProductSelectionsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyProductSelectionsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyProductSelectionsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyProductSelectionsByIDRequestMethodDeleteInput ¶

type ByProjectKeyProductSelectionsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyProductSelectionsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyProductSelectionsByIDRequestMethodGet ¶

type ByProjectKeyProductSelectionsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsByIDRequestMethodGet) Dump ¶

func (*ByProjectKeyProductSelectionsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyProductSelectionsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyProductSelectionsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyProductSelectionsByIDRequestMethodGetInput ¶

type ByProjectKeyProductSelectionsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyProductSelectionsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyProductSelectionsByIDRequestMethodPost ¶

type ByProjectKeyProductSelectionsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyProductSelectionsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyProductSelectionsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyProductSelectionsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductSelectionsByIDRequestMethodPostInput ¶

type ByProjectKeyProductSelectionsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyProductSelectionsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyProductSelectionsKeyByKeyProductsRequestBuilder ¶

type ByProjectKeyProductSelectionsKeyByKeyProductsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsKeyByKeyProductsRequestBuilder) Get ¶

type ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGet ¶

type ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGet) Dump ¶

func (*ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGet) Execute ¶

func (*ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGet) Expand ¶

func (*ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGet) Limit ¶

func (*ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGet) Offset ¶

func (*ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGet) Sort ¶

func (*ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGet) WithTotal ¶

type ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGetInput ¶

type ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGetInput struct {
	Expand    []string
	Limit     *int
	Offset    *int
	WithTotal *bool
	Sort      []string
}

func (*ByProjectKeyProductSelectionsKeyByKeyProductsRequestMethodGetInput) Values ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestBuilder ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsKeyByKeyRequestBuilder) Delete ¶

* * Deletion will only succeed if the Product Selection is not assigned to any Store(/../api/projects/stores#store).

func (*ByProjectKeyProductSelectionsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyProductSelectionsKeyByKeyRequestBuilder) Products ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodDelete) Execute ¶

* * Deletion will only succeed if the Product Selection is not assigned to any Store(/../api/projects/stores#store).

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodGet ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodPost ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyProductSelectionsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyProductSelectionsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyProductSelectionsRequestBuilder ¶

type ByProjectKeyProductSelectionsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsRequestBuilder) Get ¶

func (*ByProjectKeyProductSelectionsRequestBuilder) Post ¶

func (*ByProjectKeyProductSelectionsRequestBuilder) WithId ¶

func (*ByProjectKeyProductSelectionsRequestBuilder) WithKey ¶

type ByProjectKeyProductSelectionsRequestMethodGet ¶

type ByProjectKeyProductSelectionsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsRequestMethodGet) Dump ¶

func (r *ByProjectKeyProductSelectionsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyProductSelectionsRequestMethodGet) Execute ¶

func (*ByProjectKeyProductSelectionsRequestMethodGet) Expand ¶

func (*ByProjectKeyProductSelectionsRequestMethodGet) Limit ¶

func (*ByProjectKeyProductSelectionsRequestMethodGet) Offset ¶

func (*ByProjectKeyProductSelectionsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyProductSelectionsRequestMethodGet) Sort ¶

func (*ByProjectKeyProductSelectionsRequestMethodGet) Where ¶

func (*ByProjectKeyProductSelectionsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyProductSelectionsRequestMethodGet) WithTotal ¶

type ByProjectKeyProductSelectionsRequestMethodGetInput ¶

type ByProjectKeyProductSelectionsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyProductSelectionsRequestMethodGetInput) Values ¶

type ByProjectKeyProductSelectionsRequestMethodPost ¶

type ByProjectKeyProductSelectionsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductSelectionsRequestMethodPost) Dump ¶

func (r *ByProjectKeyProductSelectionsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyProductSelectionsRequestMethodPost) Execute ¶

func (*ByProjectKeyProductSelectionsRequestMethodPost) Expand ¶

func (*ByProjectKeyProductSelectionsRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductSelectionsRequestMethodPostInput ¶

type ByProjectKeyProductSelectionsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyProductSelectionsRequestMethodPostInput) Values ¶

type ByProjectKeyProductTypesByIDRequestBuilder ¶

type ByProjectKeyProductTypesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesByIDRequestBuilder) Delete ¶

func (*ByProjectKeyProductTypesByIDRequestBuilder) Get ¶

func (*ByProjectKeyProductTypesByIDRequestBuilder) Head ¶

* * Checks if a Product Type with given `id` exists. Responds with a `200 OK` status if the `Product Type` exists or `404 Not Found` otherwise.

func (*ByProjectKeyProductTypesByIDRequestBuilder) Post ¶

type ByProjectKeyProductTypesByIDRequestMethodDelete ¶

type ByProjectKeyProductTypesByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyProductTypesByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyProductTypesByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyProductTypesByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyProductTypesByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyProductTypesByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyProductTypesByIDRequestMethodDeleteInput ¶

type ByProjectKeyProductTypesByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyProductTypesByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyProductTypesByIDRequestMethodGet ¶

type ByProjectKeyProductTypesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyProductTypesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyProductTypesByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyProductTypesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyProductTypesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyProductTypesByIDRequestMethodGetInput ¶

type ByProjectKeyProductTypesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyProductTypesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyProductTypesByIDRequestMethodHead ¶

type ByProjectKeyProductTypesByIDRequestMethodHead struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesByIDRequestMethodHead) Dump ¶

func (r *ByProjectKeyProductTypesByIDRequestMethodHead) Dump() map[string]interface{}

func (*ByProjectKeyProductTypesByIDRequestMethodHead) Execute ¶

* * Checks if a Product Type with given `id` exists. Responds with a `200 OK` status if the `Product Type` exists or `404 Not Found` otherwise.

func (*ByProjectKeyProductTypesByIDRequestMethodHead) WithHeaders ¶

type ByProjectKeyProductTypesByIDRequestMethodPost ¶

type ByProjectKeyProductTypesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyProductTypesByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyProductTypesByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyProductTypesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyProductTypesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductTypesByIDRequestMethodPostInput ¶

type ByProjectKeyProductTypesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyProductTypesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyProductTypesKeyByKeyRequestBuilder ¶

type ByProjectKeyProductTypesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestBuilder) Head ¶

* * Checks if a Product Type with given `key` exists. Responds with a `200 OK` status if the `Product Type` exists or `404 Not Found` otherwise.

func (*ByProjectKeyProductTypesKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodDelete ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodGet ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyProductTypesKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodHead ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodHead struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodHead) Dump ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodHead) Execute ¶

* * Checks if a Product Type with given `key` exists. Responds with a `200 OK` status if the `Product Type` exists or `404 Not Found` otherwise.

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodHead) WithHeaders ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodPost ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyProductTypesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyProductTypesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyProductTypesRequestBuilder ¶

type ByProjectKeyProductTypesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesRequestBuilder) Get ¶

func (*ByProjectKeyProductTypesRequestBuilder) Head ¶

* * Check if Product Types exist. Responds with a `200 OK` status if any Product Types match the Query Predicate, or `404 Not Found` otherwise.

func (*ByProjectKeyProductTypesRequestBuilder) Post ¶

func (*ByProjectKeyProductTypesRequestBuilder) WithId ¶

func (*ByProjectKeyProductTypesRequestBuilder) WithKey ¶

type ByProjectKeyProductTypesRequestMethodGet ¶

type ByProjectKeyProductTypesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesRequestMethodGet) Dump ¶

func (r *ByProjectKeyProductTypesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyProductTypesRequestMethodGet) Execute ¶

func (*ByProjectKeyProductTypesRequestMethodGet) Expand ¶

func (*ByProjectKeyProductTypesRequestMethodGet) Limit ¶

func (*ByProjectKeyProductTypesRequestMethodGet) Offset ¶

func (*ByProjectKeyProductTypesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyProductTypesRequestMethodGet) Sort ¶

func (*ByProjectKeyProductTypesRequestMethodGet) Where ¶

func (*ByProjectKeyProductTypesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyProductTypesRequestMethodGet) WithTotal ¶

type ByProjectKeyProductTypesRequestMethodGetInput ¶

type ByProjectKeyProductTypesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyProductTypesRequestMethodGetInput) Values ¶

type ByProjectKeyProductTypesRequestMethodHead ¶

type ByProjectKeyProductTypesRequestMethodHead struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesRequestMethodHead) Dump ¶

func (r *ByProjectKeyProductTypesRequestMethodHead) Dump() map[string]interface{}

func (*ByProjectKeyProductTypesRequestMethodHead) Execute ¶

* * Check if Product Types exist. Responds with a `200 OK` status if any Product Types match the Query Predicate, or `404 Not Found` otherwise.

func (*ByProjectKeyProductTypesRequestMethodHead) Where ¶

func (*ByProjectKeyProductTypesRequestMethodHead) WithHeaders ¶

type ByProjectKeyProductTypesRequestMethodHeadInput ¶

type ByProjectKeyProductTypesRequestMethodHeadInput struct {
	Where *string
}

func (*ByProjectKeyProductTypesRequestMethodHeadInput) Values ¶

type ByProjectKeyProductTypesRequestMethodPost ¶

type ByProjectKeyProductTypesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductTypesRequestMethodPost) Dump ¶

func (r *ByProjectKeyProductTypesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyProductTypesRequestMethodPost) Execute ¶

func (*ByProjectKeyProductTypesRequestMethodPost) Expand ¶

func (*ByProjectKeyProductTypesRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductTypesRequestMethodPostInput ¶

type ByProjectKeyProductTypesRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyProductTypesRequestMethodPostInput) Values ¶

type ByProjectKeyProductsByIDImagesRequestBuilder ¶

type ByProjectKeyProductsByIDImagesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsByIDImagesRequestBuilder) Post ¶

* * Upload a JPEG, PNG and GIF file to a ProductVariant(ctp:api:type:ProductVariant). The maximum file size of the image is 10MB. `variant` or `sku` is required to update a specific ProductVariant. The image is uploaded to the Master Variant if `variant` or `sku` are not included. Produces the [ProductImageAdded](/projects/messages#product-image-added) Message when the `Small` version of the image has been uploaded to the CDN. *

type ByProjectKeyProductsByIDImagesRequestMethodPost ¶

type ByProjectKeyProductsByIDImagesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsByIDImagesRequestMethodPost) Dump ¶

func (r *ByProjectKeyProductsByIDImagesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyProductsByIDImagesRequestMethodPost) Execute ¶

* * Upload a JPEG, PNG and GIF file to a ProductVariant(ctp:api:type:ProductVariant). The maximum file size of the image is 10MB. `variant` or `sku` is required to update a specific ProductVariant. The image is uploaded to the Master Variant if `variant` or `sku` are not included. Produces the [ProductImageAdded](/projects/messages#product-image-added) Message when the `Small` version of the image has been uploaded to the CDN. *

func (*ByProjectKeyProductsByIDImagesRequestMethodPost) Filename ¶

func (*ByProjectKeyProductsByIDImagesRequestMethodPost) Sku ¶

func (*ByProjectKeyProductsByIDImagesRequestMethodPost) Staged ¶

func (*ByProjectKeyProductsByIDImagesRequestMethodPost) Variant ¶

func (*ByProjectKeyProductsByIDImagesRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductsByIDImagesRequestMethodPostInput ¶

type ByProjectKeyProductsByIDImagesRequestMethodPostInput struct {
	Filename *string
	Variant  *int
	Sku      *string
	Staged   *bool
}

func (*ByProjectKeyProductsByIDImagesRequestMethodPostInput) Values ¶

type ByProjectKeyProductsByIDProductSelectionsRequestBuilder ¶

type ByProjectKeyProductsByIDProductSelectionsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsByIDProductSelectionsRequestBuilder) Get ¶

type ByProjectKeyProductsByIDProductSelectionsRequestMethodGet ¶

type ByProjectKeyProductsByIDProductSelectionsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsByIDProductSelectionsRequestMethodGet) Dump ¶

func (*ByProjectKeyProductsByIDProductSelectionsRequestMethodGet) Execute ¶

func (*ByProjectKeyProductsByIDProductSelectionsRequestMethodGet) Expand ¶

func (*ByProjectKeyProductsByIDProductSelectionsRequestMethodGet) Limit ¶

func (*ByProjectKeyProductsByIDProductSelectionsRequestMethodGet) Offset ¶

func (*ByProjectKeyProductsByIDProductSelectionsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyProductsByIDProductSelectionsRequestMethodGet) Sort ¶

func (*ByProjectKeyProductsByIDProductSelectionsRequestMethodGet) Where ¶

func (*ByProjectKeyProductsByIDProductSelectionsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyProductsByIDProductSelectionsRequestMethodGet) WithTotal ¶

type ByProjectKeyProductsByIDProductSelectionsRequestMethodGetInput ¶

type ByProjectKeyProductsByIDProductSelectionsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyProductsByIDProductSelectionsRequestMethodGetInput) Values ¶

type ByProjectKeyProductsByIDRequestBuilder ¶

type ByProjectKeyProductsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsByIDRequestBuilder) Delete ¶

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response. * Produces the [ProductDeleted](/projects/messages#product-deleted) Message.

func (*ByProjectKeyProductsByIDRequestBuilder) Get ¶

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response.

func (*ByProjectKeyProductsByIDRequestBuilder) Head ¶

* * Check if a Product exists with a specified `id`. Responds with a `200 OK` status if the Product exists or `404 Not Found` otherwise.

func (*ByProjectKeyProductsByIDRequestBuilder) Images ¶

func (*ByProjectKeyProductsByIDRequestBuilder) Post ¶

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response. * * A failed response can return a [DuplicatePriceScope](ctp:api:type:DuplicatePriceScopeError), [DuplicateVariantValues](ctp:api:type:DuplicateVariantValuesError), [DuplicateAttributeValue](ctp:api:type:DuplicateAttributeValueError), or [DuplicateAttributeValues](ctp:api:type:DuplicateAttributeValuesError) error.

func (*ByProjectKeyProductsByIDRequestBuilder) ProductSelections ¶

type ByProjectKeyProductsByIDRequestMethodDelete ¶

type ByProjectKeyProductsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyProductsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyProductsByIDRequestMethodDelete) Execute ¶

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response. * Produces the [ProductDeleted](/projects/messages#product-deleted) Message.

func (*ByProjectKeyProductsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyProductsByIDRequestMethodDelete) LocaleProjection ¶

func (*ByProjectKeyProductsByIDRequestMethodDelete) PriceChannel ¶

func (*ByProjectKeyProductsByIDRequestMethodDelete) PriceCountry ¶

func (*ByProjectKeyProductsByIDRequestMethodDelete) PriceCurrency ¶

func (*ByProjectKeyProductsByIDRequestMethodDelete) PriceCustomerGroup ¶

func (*ByProjectKeyProductsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyProductsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyProductsByIDRequestMethodDeleteInput ¶

type ByProjectKeyProductsByIDRequestMethodDeleteInput struct {
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	Version            int
	Expand             []string
}

func (*ByProjectKeyProductsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyProductsByIDRequestMethodGet ¶

type ByProjectKeyProductsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyProductsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyProductsByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyProductsByIDRequestMethodGet) Execute(ctx context.Context) (result *Product, err error)

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response.

func (*ByProjectKeyProductsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyProductsByIDRequestMethodGet) LocaleProjection ¶

func (*ByProjectKeyProductsByIDRequestMethodGet) PriceChannel ¶

func (*ByProjectKeyProductsByIDRequestMethodGet) PriceCountry ¶

func (*ByProjectKeyProductsByIDRequestMethodGet) PriceCurrency ¶

func (*ByProjectKeyProductsByIDRequestMethodGet) PriceCustomerGroup ¶

func (*ByProjectKeyProductsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyProductsByIDRequestMethodGetInput ¶

type ByProjectKeyProductsByIDRequestMethodGetInput struct {
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	Expand             []string
}

func (*ByProjectKeyProductsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyProductsByIDRequestMethodHead ¶

type ByProjectKeyProductsByIDRequestMethodHead struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsByIDRequestMethodHead) Dump ¶

func (r *ByProjectKeyProductsByIDRequestMethodHead) Dump() map[string]interface{}

func (*ByProjectKeyProductsByIDRequestMethodHead) Execute ¶

* * Check if a Product exists with a specified `id`. Responds with a `200 OK` status if the Product exists or `404 Not Found` otherwise.

func (*ByProjectKeyProductsByIDRequestMethodHead) WithHeaders ¶

type ByProjectKeyProductsByIDRequestMethodPost ¶

type ByProjectKeyProductsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyProductsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyProductsByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyProductsByIDRequestMethodPost) Execute(ctx context.Context) (result *Product, err error)

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response. * * A failed response can return a [DuplicatePriceScope](ctp:api:type:DuplicatePriceScopeError), [DuplicateVariantValues](ctp:api:type:DuplicateVariantValuesError), [DuplicateAttributeValue](ctp:api:type:DuplicateAttributeValueError), or [DuplicateAttributeValues](ctp:api:type:DuplicateAttributeValuesError) error.

func (*ByProjectKeyProductsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyProductsByIDRequestMethodPost) LocaleProjection ¶

func (*ByProjectKeyProductsByIDRequestMethodPost) PriceChannel ¶

func (*ByProjectKeyProductsByIDRequestMethodPost) PriceCountry ¶

func (*ByProjectKeyProductsByIDRequestMethodPost) PriceCurrency ¶

func (*ByProjectKeyProductsByIDRequestMethodPost) PriceCustomerGroup ¶

func (*ByProjectKeyProductsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductsByIDRequestMethodPostInput ¶

type ByProjectKeyProductsByIDRequestMethodPostInput struct {
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	Expand             []string
}

func (*ByProjectKeyProductsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyProductsKeyByKeyProductSelectionsRequestBuilder ¶

type ByProjectKeyProductsKeyByKeyProductSelectionsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestBuilder) Get ¶

type ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet ¶

type ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet) Dump ¶

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet) Execute ¶

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet) Expand ¶

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet) Limit ¶

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet) Offset ¶

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet) Sort ¶

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet) Where ¶

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGet) WithTotal ¶

type ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGetInput ¶

type ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyProductsKeyByKeyProductSelectionsRequestMethodGetInput) Values ¶

type ByProjectKeyProductsKeyByKeyRequestBuilder ¶

type ByProjectKeyProductsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsKeyByKeyRequestBuilder) Delete ¶

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response. * Produces the [ProductDeleted](/projects/messages#product-deleted) Message.

func (*ByProjectKeyProductsKeyByKeyRequestBuilder) Get ¶

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response.

func (*ByProjectKeyProductsKeyByKeyRequestBuilder) Head ¶

* * Check if a Product exists with a specified `key`. Responds with a `200 OK` status if the Product exists or `404 Not Found` otherwise.

func (*ByProjectKeyProductsKeyByKeyRequestBuilder) Post ¶

* * A failed response can return a [DuplicatePriceScope](ctp:api:type:DuplicatePriceScopeError), [DuplicateVariantValues](ctp:api:type:DuplicateVariantValuesError), [DuplicateAttributeValue](ctp:api:type:DuplicateAttributeValueError), or [DuplicateAttributeValues](ctp:api:type:DuplicateAttributeValuesError) error.

func (*ByProjectKeyProductsKeyByKeyRequestBuilder) ProductSelections ¶

type ByProjectKeyProductsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyProductsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyProductsKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyProductsKeyByKeyRequestMethodDelete) Execute ¶

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response. * Produces the [ProductDeleted](/projects/messages#product-deleted) Message.

func (*ByProjectKeyProductsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodDelete) LocaleProjection ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodDelete) PriceChannel ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodDelete) PriceCountry ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodDelete) PriceCurrency ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodDelete) PriceCustomerGroup ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyProductsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyProductsKeyByKeyRequestMethodDeleteInput struct {
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	Version            int
	Expand             []string
}

func (*ByProjectKeyProductsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyProductsKeyByKeyRequestMethodGet ¶

type ByProjectKeyProductsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyProductsKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyProductsKeyByKeyRequestMethodGet) Execute ¶

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response.

func (*ByProjectKeyProductsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodGet) LocaleProjection ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodGet) PriceChannel ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodGet) PriceCountry ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodGet) PriceCurrency ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodGet) PriceCustomerGroup ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyProductsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyProductsKeyByKeyRequestMethodGetInput struct {
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	Expand             []string
}

func (*ByProjectKeyProductsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyProductsKeyByKeyRequestMethodHead ¶

type ByProjectKeyProductsKeyByKeyRequestMethodHead struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsKeyByKeyRequestMethodHead) Dump ¶

func (r *ByProjectKeyProductsKeyByKeyRequestMethodHead) Dump() map[string]interface{}

func (*ByProjectKeyProductsKeyByKeyRequestMethodHead) Execute ¶

* * Check if a Product exists with a specified `key`. Responds with a `200 OK` status if the Product exists or `404 Not Found` otherwise.

func (*ByProjectKeyProductsKeyByKeyRequestMethodHead) WithHeaders ¶

type ByProjectKeyProductsKeyByKeyRequestMethodPost ¶

type ByProjectKeyProductsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyProductsKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyProductsKeyByKeyRequestMethodPost) Execute ¶

* * A failed response can return a [DuplicatePriceScope](ctp:api:type:DuplicatePriceScopeError), [DuplicateVariantValues](ctp:api:type:DuplicateVariantValuesError), [DuplicateAttributeValue](ctp:api:type:DuplicateAttributeValueError), or [DuplicateAttributeValues](ctp:api:type:DuplicateAttributeValuesError) error.

func (*ByProjectKeyProductsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodPost) LocaleProjection ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodPost) PriceChannel ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodPost) PriceCountry ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodPost) PriceCurrency ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodPost) PriceCustomerGroup ¶

func (*ByProjectKeyProductsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyProductsKeyByKeyRequestMethodPostInput struct {
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	Expand             []string
}

func (*ByProjectKeyProductsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyProductsRequestBuilder ¶

type ByProjectKeyProductsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsRequestBuilder) Get ¶

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response.

func (*ByProjectKeyProductsRequestBuilder) Head ¶

* * Check if Products exist. Responds with a `200 OK` status if any Products match the Query Predicate, or `404 Not Found` otherwise.

func (*ByProjectKeyProductsRequestBuilder) Post ¶

* * To create a new Product, send a representation that is going to become the initial _staged_ representation of the new Product in the master catalog. * If [Price Selection](ctp:api:type:ProductPriceSelection) query parameters are provided, selected Prices will be added to the response. * Produces the [ProductCreated](/projects/messages#product-created) Message. *

func (*ByProjectKeyProductsRequestBuilder) WithId ¶

func (*ByProjectKeyProductsRequestBuilder) WithKey ¶

type ByProjectKeyProductsRequestMethodGet ¶

type ByProjectKeyProductsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsRequestMethodGet) Dump ¶

func (r *ByProjectKeyProductsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyProductsRequestMethodGet) Execute ¶

* * If [Price selection](ctp:api:type:ProductPriceSelection) query parameters are provided, the selected Prices are added to the response.

func (*ByProjectKeyProductsRequestMethodGet) Expand ¶

func (*ByProjectKeyProductsRequestMethodGet) Limit ¶

func (*ByProjectKeyProductsRequestMethodGet) LocaleProjection ¶

func (*ByProjectKeyProductsRequestMethodGet) Offset ¶

func (*ByProjectKeyProductsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyProductsRequestMethodGet) PriceChannel ¶

func (*ByProjectKeyProductsRequestMethodGet) PriceCountry ¶

func (*ByProjectKeyProductsRequestMethodGet) PriceCurrency ¶

func (*ByProjectKeyProductsRequestMethodGet) PriceCustomerGroup ¶

func (*ByProjectKeyProductsRequestMethodGet) Sort ¶

func (*ByProjectKeyProductsRequestMethodGet) Where ¶

func (*ByProjectKeyProductsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyProductsRequestMethodGet) WithTotal ¶

type ByProjectKeyProductsRequestMethodGetInput ¶

type ByProjectKeyProductsRequestMethodGetInput struct {
	Where              []string
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	Expand             []string
	Sort               []string
	Limit              *int
	Offset             *int
	WithTotal          *bool
	PredicateVar       map[string][]string
}

func (*ByProjectKeyProductsRequestMethodGetInput) Values ¶

type ByProjectKeyProductsRequestMethodHead ¶

type ByProjectKeyProductsRequestMethodHead struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsRequestMethodHead) Dump ¶

func (r *ByProjectKeyProductsRequestMethodHead) Dump() map[string]interface{}

func (*ByProjectKeyProductsRequestMethodHead) Execute ¶

* * Check if Products exist. Responds with a `200 OK` status if any Products match the Query Predicate, or `404 Not Found` otherwise.

func (*ByProjectKeyProductsRequestMethodHead) Where ¶

func (*ByProjectKeyProductsRequestMethodHead) WithHeaders ¶

type ByProjectKeyProductsRequestMethodHeadInput ¶

type ByProjectKeyProductsRequestMethodHeadInput struct {
	Where []string
}

func (*ByProjectKeyProductsRequestMethodHeadInput) Values ¶

type ByProjectKeyProductsRequestMethodPost ¶

type ByProjectKeyProductsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyProductsRequestMethodPost) Dump ¶

func (r *ByProjectKeyProductsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyProductsRequestMethodPost) Execute ¶

func (rb *ByProjectKeyProductsRequestMethodPost) Execute(ctx context.Context) (result *Product, err error)

* * To create a new Product, send a representation that is going to become the initial _staged_ representation of the new Product in the master catalog. * If [Price Selection](ctp:api:type:ProductPriceSelection) query parameters are provided, selected Prices will be added to the response. * Produces the [ProductCreated](/projects/messages#product-created) Message. *

func (*ByProjectKeyProductsRequestMethodPost) Expand ¶

func (*ByProjectKeyProductsRequestMethodPost) LocaleProjection ¶

func (*ByProjectKeyProductsRequestMethodPost) PriceChannel ¶

func (*ByProjectKeyProductsRequestMethodPost) PriceCountry ¶

func (*ByProjectKeyProductsRequestMethodPost) PriceCurrency ¶

func (*ByProjectKeyProductsRequestMethodPost) PriceCustomerGroup ¶

func (*ByProjectKeyProductsRequestMethodPost) WithHeaders ¶

type ByProjectKeyProductsRequestMethodPostInput ¶

type ByProjectKeyProductsRequestMethodPostInput struct {
	PriceCurrency      *string
	PriceCountry       *string
	PriceCustomerGroup *string
	PriceChannel       *string
	LocaleProjection   []string
	Expand             []string
}

func (*ByProjectKeyProductsRequestMethodPostInput) Values ¶

type ByProjectKeyQuoteRequestsByIDRequestBuilder ¶

type ByProjectKeyQuoteRequestsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuoteRequestsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyQuoteRequestsByIDRequestBuilder) Get ¶

func (*ByProjectKeyQuoteRequestsByIDRequestBuilder) Post ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodDelete ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuoteRequestsByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyQuoteRequestsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyQuoteRequestsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyQuoteRequestsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyQuoteRequestsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyQuoteRequestsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyQuoteRequestsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodDeleteInput ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyQuoteRequestsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodGet ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuoteRequestsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyQuoteRequestsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyQuoteRequestsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyQuoteRequestsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyQuoteRequestsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodGetInput ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyQuoteRequestsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodPost ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuoteRequestsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyQuoteRequestsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyQuoteRequestsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyQuoteRequestsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyQuoteRequestsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodPostInput ¶

type ByProjectKeyQuoteRequestsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyQuoteRequestsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestBuilder ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodGet ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodPost ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyQuoteRequestsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyQuoteRequestsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyQuoteRequestsRequestBuilder ¶

type ByProjectKeyQuoteRequestsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuoteRequestsRequestBuilder) Get ¶

func (*ByProjectKeyQuoteRequestsRequestBuilder) Post ¶

func (*ByProjectKeyQuoteRequestsRequestBuilder) WithId ¶

func (*ByProjectKeyQuoteRequestsRequestBuilder) WithKey ¶

type ByProjectKeyQuoteRequestsRequestMethodGet ¶

type ByProjectKeyQuoteRequestsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuoteRequestsRequestMethodGet) Dump ¶

func (r *ByProjectKeyQuoteRequestsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyQuoteRequestsRequestMethodGet) Execute ¶

func (*ByProjectKeyQuoteRequestsRequestMethodGet) Expand ¶

func (*ByProjectKeyQuoteRequestsRequestMethodGet) Limit ¶

func (*ByProjectKeyQuoteRequestsRequestMethodGet) Offset ¶

func (*ByProjectKeyQuoteRequestsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyQuoteRequestsRequestMethodGet) Sort ¶

func (*ByProjectKeyQuoteRequestsRequestMethodGet) Where ¶

func (*ByProjectKeyQuoteRequestsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyQuoteRequestsRequestMethodGet) WithTotal ¶

type ByProjectKeyQuoteRequestsRequestMethodGetInput ¶

type ByProjectKeyQuoteRequestsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyQuoteRequestsRequestMethodGetInput) Values ¶

type ByProjectKeyQuoteRequestsRequestMethodPost ¶

type ByProjectKeyQuoteRequestsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuoteRequestsRequestMethodPost) Dump ¶

func (r *ByProjectKeyQuoteRequestsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyQuoteRequestsRequestMethodPost) Execute ¶

func (*ByProjectKeyQuoteRequestsRequestMethodPost) Expand ¶

func (*ByProjectKeyQuoteRequestsRequestMethodPost) WithHeaders ¶

type ByProjectKeyQuoteRequestsRequestMethodPostInput ¶

type ByProjectKeyQuoteRequestsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyQuoteRequestsRequestMethodPostInput) Values ¶

type ByProjectKeyQuotesByIDRequestBuilder ¶

type ByProjectKeyQuotesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuotesByIDRequestBuilder) Delete ¶

func (*ByProjectKeyQuotesByIDRequestBuilder) Get ¶

func (*ByProjectKeyQuotesByIDRequestBuilder) Post ¶

type ByProjectKeyQuotesByIDRequestMethodDelete ¶

type ByProjectKeyQuotesByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuotesByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyQuotesByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyQuotesByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyQuotesByIDRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyQuotesByIDRequestMethodDelete) Execute(ctx context.Context) (result *Quote, err error)

func (*ByProjectKeyQuotesByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyQuotesByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyQuotesByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyQuotesByIDRequestMethodDeleteInput ¶

type ByProjectKeyQuotesByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyQuotesByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyQuotesByIDRequestMethodGet ¶

type ByProjectKeyQuotesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuotesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyQuotesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyQuotesByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyQuotesByIDRequestMethodGet) Execute(ctx context.Context) (result *Quote, err error)

func (*ByProjectKeyQuotesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyQuotesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyQuotesByIDRequestMethodGetInput ¶

type ByProjectKeyQuotesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyQuotesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyQuotesByIDRequestMethodPost ¶

type ByProjectKeyQuotesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuotesByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyQuotesByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyQuotesByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyQuotesByIDRequestMethodPost) Execute(ctx context.Context) (result *Quote, err error)

func (*ByProjectKeyQuotesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyQuotesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyQuotesByIDRequestMethodPostInput ¶

type ByProjectKeyQuotesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyQuotesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyQuotesKeyByKeyRequestBuilder ¶

type ByProjectKeyQuotesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuotesKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyQuotesKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyQuotesKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodDelete ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuotesKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyQuotesKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyQuotesKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyQuotesKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyQuotesKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyQuotesKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyQuotesKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyQuotesKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodGet ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuotesKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyQuotesKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyQuotesKeyByKeyRequestMethodGet) Execute ¶

func (rb *ByProjectKeyQuotesKeyByKeyRequestMethodGet) Execute(ctx context.Context) (result *Quote, err error)

func (*ByProjectKeyQuotesKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyQuotesKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyQuotesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodPost ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuotesKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyQuotesKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyQuotesKeyByKeyRequestMethodPost) Execute ¶

func (rb *ByProjectKeyQuotesKeyByKeyRequestMethodPost) Execute(ctx context.Context) (result *Quote, err error)

func (*ByProjectKeyQuotesKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyQuotesKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyQuotesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyQuotesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyQuotesRequestBuilder ¶

type ByProjectKeyQuotesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuotesRequestBuilder) Get ¶

func (*ByProjectKeyQuotesRequestBuilder) Post ¶

func (*ByProjectKeyQuotesRequestBuilder) WithId ¶

func (*ByProjectKeyQuotesRequestBuilder) WithKey ¶

type ByProjectKeyQuotesRequestMethodGet ¶

type ByProjectKeyQuotesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuotesRequestMethodGet) Dump ¶

func (r *ByProjectKeyQuotesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyQuotesRequestMethodGet) Execute ¶

func (*ByProjectKeyQuotesRequestMethodGet) Expand ¶

func (*ByProjectKeyQuotesRequestMethodGet) Limit ¶

func (*ByProjectKeyQuotesRequestMethodGet) Offset ¶

func (*ByProjectKeyQuotesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyQuotesRequestMethodGet) Sort ¶

func (*ByProjectKeyQuotesRequestMethodGet) Where ¶

func (*ByProjectKeyQuotesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyQuotesRequestMethodGet) WithQueryParams ¶

func (*ByProjectKeyQuotesRequestMethodGet) WithTotal ¶

type ByProjectKeyQuotesRequestMethodGetInput ¶

type ByProjectKeyQuotesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyQuotesRequestMethodGetInput) Values ¶

type ByProjectKeyQuotesRequestMethodPost ¶

type ByProjectKeyQuotesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyQuotesRequestMethodPost) Dump ¶

func (r *ByProjectKeyQuotesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyQuotesRequestMethodPost) Execute ¶

func (rb *ByProjectKeyQuotesRequestMethodPost) Execute(ctx context.Context) (result *Quote, err error)

func (*ByProjectKeyQuotesRequestMethodPost) Expand ¶

func (*ByProjectKeyQuotesRequestMethodPost) WithHeaders ¶

type ByProjectKeyQuotesRequestMethodPostInput ¶

type ByProjectKeyQuotesRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyQuotesRequestMethodPostInput) Values ¶

type ByProjectKeyRequestBuilder ¶

type ByProjectKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyRequestBuilder) ApiClients ¶

* * Manage your API Clients via an API. Useful for Infrastructure-as-Code tooling, and regularly rotating API secrets. *

func (*ByProjectKeyRequestBuilder) AsAssociate ¶

func (*ByProjectKeyRequestBuilder) AssociateRoles ¶

* * An Associate Role enables permissions over a Business Unit to an Associate.

func (*ByProjectKeyRequestBuilder) AttributeGroups ¶

* * Attribute groups ... TODO

func (*ByProjectKeyRequestBuilder) BusinessUnits ¶

* * A Business Unit can represent a Company or a Division.

func (*ByProjectKeyRequestBuilder) CartDiscounts ¶

* * Cart discounts are used to change the prices of different elements within a cart.

func (*ByProjectKeyRequestBuilder) Carts ¶

* * A shopping cart holds product variants and can be ordered.

func (*ByProjectKeyRequestBuilder) Categories ¶

* * Categories are used to organize products in a hierarchical structure.

func (*ByProjectKeyRequestBuilder) Channels ¶

* * Channels represent a source or destination of different entities. They can be used to model warehouses or stores. *

func (*ByProjectKeyRequestBuilder) CustomObjects ¶

* * Store custom JSON values.

func (*ByProjectKeyRequestBuilder) CustomerGroups ¶

* * customer-groups are used to evaluate products and channels.

func (*ByProjectKeyRequestBuilder) Customers ¶

* * A Customer is a person purchasing products. Carts, Orders, Quotes, Reviews and Payments can be associated to a Customer. *

func (*ByProjectKeyRequestBuilder) DiscountCodes ¶

* * Discount Codes can be added to a discount-code to enable certain discount-code discounts.

func (*ByProjectKeyRequestBuilder) Extensions ¶

* * Extend the behavior of an API with your business logic

func (*ByProjectKeyRequestBuilder) Get ¶

func (*ByProjectKeyRequestBuilder) Graphql ¶

* * commercetools Composable Commerce provides a GraphQL API

func (*ByProjectKeyRequestBuilder) InBusinessUnitKeyWithBusinessUnitKeyValue ¶

func (rb *ByProjectKeyRequestBuilder) InBusinessUnitKeyWithBusinessUnitKeyValue(businessUnitKey string) *ByProjectKeyInBusinessUnitKeyByBusinessUnitKeyRequestBuilder

func (*ByProjectKeyRequestBuilder) InStoreKeyWithStoreKeyValue ¶

func (rb *ByProjectKeyRequestBuilder) InStoreKeyWithStoreKeyValue(storeKey string) *ByProjectKeyInStoreKeyByStoreKeyRequestBuilder

func (*ByProjectKeyRequestBuilder) Inventory ¶

* * Inventory allows you to track stock quantities.

func (*ByProjectKeyRequestBuilder) Login ¶

* * Retrieves the authenticated customer.

func (*ByProjectKeyRequestBuilder) Me ¶

func (*ByProjectKeyRequestBuilder) Messages ¶

* * A message represents a change or an action performed on a resource (like an Order or a Product).

func (*ByProjectKeyRequestBuilder) Orders ¶

* * An order can be created from a order, usually after a checkout process has been completed.

func (*ByProjectKeyRequestBuilder) Payments ¶

* * Payments hold information about the current state of receiving and/or refunding money

func (*ByProjectKeyRequestBuilder) Post ¶

func (*ByProjectKeyRequestBuilder) ProductDiscounts ¶

* * Product discounts are used to change certain product prices.

func (*ByProjectKeyRequestBuilder) ProductProjections ¶

* * A projected representation of a product shows the product with its current or staged data. The current or staged * representation of a product in a catalog is called a product projection. *

func (*ByProjectKeyRequestBuilder) ProductSelections ¶

* * Manage individual Store assortments through Product Selections. * * After you have created Product Selections and populated them with Products, * you can manage Store assortments by assigning Product Selections to Stores. * Product Selections may be used by a single Store or shared across several Stores. * * As a good practice, we recommend first creating Products in the project, and then creating Product Selection. *

func (*ByProjectKeyRequestBuilder) ProductTypes ¶

* * Product Types are used to describe common characteristics, most importantly common custom attributes, * of many concrete products. *

func (*ByProjectKeyRequestBuilder) Products ¶

* * Products themselves are not sellable. Instead, they act as a parent structure for sellable Product Variants. *

func (*ByProjectKeyRequestBuilder) QuoteRequests ¶

* * A request for a Quote holds product variants and can be ordered.

func (*ByProjectKeyRequestBuilder) Quotes ¶

* * A quote holds the negotiated offer.

func (*ByProjectKeyRequestBuilder) Reviews ¶

* * Reviews are used to evaluate products and channels.

func (*ByProjectKeyRequestBuilder) ShippingMethods ¶

* * ShippingMethods define where orders can be shipped and what the costs are.

func (*ByProjectKeyRequestBuilder) ShoppingLists ¶

* * shopping-lists e.g. for wishlist support

func (*ByProjectKeyRequestBuilder) StagedQuotes ¶

* * A staged quote holds the negotiation between the [Buyer](/../api/quotes-overview#buyer) and the [Seller](/../api/quotes-overview#seller).

func (*ByProjectKeyRequestBuilder) StandalonePrices ¶

* * A standalone price assigns a price to a product variant for a given scope. The API will use the standalone prices associated with a Product if its field [`priceMode`](/projects/products#pricemode) is set to `Standalone` [ProductPriceMode](ctp:api:type:ProductPriceModeEnum).

func (*ByProjectKeyRequestBuilder) States ¶

* * commercetools Composable Commerce allows you to model states of certain objects, such as orders, line items, products, * reviews, and payments in order to define finite state machines reflecting the business logic you'd like to * implement. *

func (*ByProjectKeyRequestBuilder) Stores ¶

* * Stores let you model the context your customers shop in.

func (*ByProjectKeyRequestBuilder) Subscriptions ¶

* * Subscriptions allow you to be notified of new messages or changes via a Message Queue of your choice

func (*ByProjectKeyRequestBuilder) TaxCategories ¶

* * Tax Categories define how products are to be taxed in different countries.

func (*ByProjectKeyRequestBuilder) Types ¶

* * Types define custom fields that are used to enhance resources as you need.

func (*ByProjectKeyRequestBuilder) Zones ¶

* * Zones allow defining ShippingRates for specific Locations.

type ByProjectKeyRequestMethodGet ¶

type ByProjectKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyRequestMethodGet) Execute ¶

func (rb *ByProjectKeyRequestMethodGet) Execute(ctx context.Context) (result *Project, err error)

func (*ByProjectKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyRequestMethodPost ¶

type ByProjectKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyRequestMethodPost) Execute ¶

func (rb *ByProjectKeyRequestMethodPost) Execute(ctx context.Context) (result *Project, err error)

func (*ByProjectKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyReviewsByIDRequestBuilder ¶

type ByProjectKeyReviewsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyReviewsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyReviewsByIDRequestBuilder) Get ¶

func (*ByProjectKeyReviewsByIDRequestBuilder) Post ¶

type ByProjectKeyReviewsByIDRequestMethodDelete ¶

type ByProjectKeyReviewsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyReviewsByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyReviewsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyReviewsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyReviewsByIDRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyReviewsByIDRequestMethodDelete) Execute(ctx context.Context) (result *Review, err error)

func (*ByProjectKeyReviewsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyReviewsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyReviewsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyReviewsByIDRequestMethodDeleteInput ¶

type ByProjectKeyReviewsByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyReviewsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyReviewsByIDRequestMethodGet ¶

type ByProjectKeyReviewsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyReviewsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyReviewsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyReviewsByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyReviewsByIDRequestMethodGet) Execute(ctx context.Context) (result *Review, err error)

func (*ByProjectKeyReviewsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyReviewsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyReviewsByIDRequestMethodGetInput ¶

type ByProjectKeyReviewsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyReviewsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyReviewsByIDRequestMethodPost ¶

type ByProjectKeyReviewsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyReviewsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyReviewsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyReviewsByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyReviewsByIDRequestMethodPost) Execute(ctx context.Context) (result *Review, err error)

func (*ByProjectKeyReviewsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyReviewsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyReviewsByIDRequestMethodPostInput ¶

type ByProjectKeyReviewsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyReviewsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyReviewsKeyByKeyRequestBuilder ¶

type ByProjectKeyReviewsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyReviewsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyReviewsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyReviewsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyReviewsKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyReviewsKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyReviewsKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyReviewsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyReviewsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyReviewsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyReviewsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyReviewsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodGet ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyReviewsKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyReviewsKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyReviewsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyReviewsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyReviewsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyReviewsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodPost ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyReviewsKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyReviewsKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyReviewsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyReviewsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyReviewsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyReviewsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyReviewsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyReviewsRequestBuilder ¶

type ByProjectKeyReviewsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyReviewsRequestBuilder) Get ¶

func (*ByProjectKeyReviewsRequestBuilder) Post ¶

func (*ByProjectKeyReviewsRequestBuilder) WithId ¶

func (*ByProjectKeyReviewsRequestBuilder) WithKey ¶

type ByProjectKeyReviewsRequestMethodGet ¶

type ByProjectKeyReviewsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyReviewsRequestMethodGet) Dump ¶

func (r *ByProjectKeyReviewsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyReviewsRequestMethodGet) Execute ¶

func (*ByProjectKeyReviewsRequestMethodGet) Expand ¶

func (*ByProjectKeyReviewsRequestMethodGet) Limit ¶

func (*ByProjectKeyReviewsRequestMethodGet) Offset ¶

func (*ByProjectKeyReviewsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyReviewsRequestMethodGet) Sort ¶

func (*ByProjectKeyReviewsRequestMethodGet) Where ¶

func (*ByProjectKeyReviewsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyReviewsRequestMethodGet) WithTotal ¶

type ByProjectKeyReviewsRequestMethodGetInput ¶

type ByProjectKeyReviewsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyReviewsRequestMethodGetInput) Values ¶

type ByProjectKeyReviewsRequestMethodPost ¶

type ByProjectKeyReviewsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyReviewsRequestMethodPost) Dump ¶

func (r *ByProjectKeyReviewsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyReviewsRequestMethodPost) Execute ¶

func (rb *ByProjectKeyReviewsRequestMethodPost) Execute(ctx context.Context) (result *Review, err error)

func (*ByProjectKeyReviewsRequestMethodPost) Expand ¶

func (*ByProjectKeyReviewsRequestMethodPost) WithHeaders ¶

type ByProjectKeyReviewsRequestMethodPostInput ¶

type ByProjectKeyReviewsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyReviewsRequestMethodPostInput) Values ¶

type ByProjectKeyShippingMethodsByIDRequestBuilder ¶

type ByProjectKeyShippingMethodsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyShippingMethodsByIDRequestBuilder) Get ¶

func (*ByProjectKeyShippingMethodsByIDRequestBuilder) Post ¶

type ByProjectKeyShippingMethodsByIDRequestMethodDelete ¶

type ByProjectKeyShippingMethodsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyShippingMethodsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyShippingMethodsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyShippingMethodsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyShippingMethodsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyShippingMethodsByIDRequestMethodDeleteInput ¶

type ByProjectKeyShippingMethodsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyShippingMethodsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyShippingMethodsByIDRequestMethodGet ¶

type ByProjectKeyShippingMethodsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyShippingMethodsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyShippingMethodsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyShippingMethodsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyShippingMethodsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyShippingMethodsByIDRequestMethodGetInput ¶

type ByProjectKeyShippingMethodsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyShippingMethodsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyShippingMethodsByIDRequestMethodPost ¶

type ByProjectKeyShippingMethodsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyShippingMethodsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyShippingMethodsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyShippingMethodsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyShippingMethodsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyShippingMethodsByIDRequestMethodPostInput ¶

type ByProjectKeyShippingMethodsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyShippingMethodsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestBuilder ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodGet ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodPost ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyShippingMethodsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyShippingMethodsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyShippingMethodsMatchingCartLocationRequestBuilder ¶

type ByProjectKeyShippingMethodsMatchingCartLocationRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsMatchingCartLocationRequestBuilder) Get ¶

* * Retrieves all the ShippingMethods that can ship to the given Location(/projects/zones#location) * with a `predicate` that matches the given Cart. * Each ShippingMethod contains exactly one ShippingRate with the flag `isMatching` set to `true`. * This ShippingRate is used when the ShippingMethod is [added to the Cart](ctp:api:type:CartSetShippingMethodAction). *

type ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGet ¶

type ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGet) CartId ¶

func (*ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGet) Country ¶

func (*ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGet) Dump ¶

func (*ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGet) Execute ¶

* * Retrieves all the ShippingMethods that can ship to the given Location(/projects/zones#location) * with a `predicate` that matches the given Cart. * Each ShippingMethod contains exactly one ShippingRate with the flag `isMatching` set to `true`. * This ShippingRate is used when the ShippingMethod is [added to the Cart](ctp:api:type:CartSetShippingMethodAction). *

func (*ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGet) Expand ¶

func (*ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGet) State ¶

func (*ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGet) WithHeaders ¶

type ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGetInput ¶

type ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGetInput struct {
	Country string
	State   *string
	CartId  string
	Expand  []string
}

func (*ByProjectKeyShippingMethodsMatchingCartLocationRequestMethodGetInput) Values ¶

type ByProjectKeyShippingMethodsMatchingCartRequestBuilder ¶

type ByProjectKeyShippingMethodsMatchingCartRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsMatchingCartRequestBuilder) Get ¶

* * Retrieves all the ShippingMethods that can ship to the shipping address of the given Cart. * Each ShippingMethod contains exactly one ShippingRate with the flag `isMatching` set to `true`. * This ShippingRate is used when the ShippingMethod is [added to the Cart](ctp:api:type:CartSetShippingMethodAction). *

type ByProjectKeyShippingMethodsMatchingCartRequestMethodGet ¶

type ByProjectKeyShippingMethodsMatchingCartRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsMatchingCartRequestMethodGet) CartId ¶

func (*ByProjectKeyShippingMethodsMatchingCartRequestMethodGet) Dump ¶

func (*ByProjectKeyShippingMethodsMatchingCartRequestMethodGet) Execute ¶

* * Retrieves all the ShippingMethods that can ship to the shipping address of the given Cart. * Each ShippingMethod contains exactly one ShippingRate with the flag `isMatching` set to `true`. * This ShippingRate is used when the ShippingMethod is [added to the Cart](ctp:api:type:CartSetShippingMethodAction). *

func (*ByProjectKeyShippingMethodsMatchingCartRequestMethodGet) Expand ¶

func (*ByProjectKeyShippingMethodsMatchingCartRequestMethodGet) WithHeaders ¶

type ByProjectKeyShippingMethodsMatchingCartRequestMethodGetInput ¶

type ByProjectKeyShippingMethodsMatchingCartRequestMethodGetInput struct {
	CartId string
	Expand []string
}

func (*ByProjectKeyShippingMethodsMatchingCartRequestMethodGetInput) Values ¶

type ByProjectKeyShippingMethodsMatchingLocationRequestBuilder ¶

type ByProjectKeyShippingMethodsMatchingLocationRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsMatchingLocationRequestBuilder) Get ¶

* * Retrieves all the ShippingMethods that can ship to the given Location(/projects/zones#location). * ShippingMethods that have a `predicate` defined are automatically disqualified. * If the `currency` parameter is given, then the ShippingMethods must also have a rate defined in the specified currency. * Each ShippingMethod contains at least one ShippingRate with the flag `isMatching` set to `true`. * If the `currency` parameter is given, exactly one ShippingRate will contain it. *

type ByProjectKeyShippingMethodsMatchingLocationRequestMethodGet ¶

type ByProjectKeyShippingMethodsMatchingLocationRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsMatchingLocationRequestMethodGet) Country ¶

func (*ByProjectKeyShippingMethodsMatchingLocationRequestMethodGet) Currency ¶

func (*ByProjectKeyShippingMethodsMatchingLocationRequestMethodGet) Dump ¶

func (*ByProjectKeyShippingMethodsMatchingLocationRequestMethodGet) Execute ¶

* * Retrieves all the ShippingMethods that can ship to the given Location(/projects/zones#location). * ShippingMethods that have a `predicate` defined are automatically disqualified. * If the `currency` parameter is given, then the ShippingMethods must also have a rate defined in the specified currency. * Each ShippingMethod contains at least one ShippingRate with the flag `isMatching` set to `true`. * If the `currency` parameter is given, exactly one ShippingRate will contain it. *

func (*ByProjectKeyShippingMethodsMatchingLocationRequestMethodGet) Expand ¶

func (*ByProjectKeyShippingMethodsMatchingLocationRequestMethodGet) Sort ¶

func (*ByProjectKeyShippingMethodsMatchingLocationRequestMethodGet) State ¶

func (*ByProjectKeyShippingMethodsMatchingLocationRequestMethodGet) WithHeaders ¶

type ByProjectKeyShippingMethodsMatchingLocationRequestMethodGetInput ¶

type ByProjectKeyShippingMethodsMatchingLocationRequestMethodGetInput struct {
	Country  string
	State    *string
	Currency *string
	Expand   []string
	Sort     []string
}

func (*ByProjectKeyShippingMethodsMatchingLocationRequestMethodGetInput) Values ¶

type ByProjectKeyShippingMethodsMatchingOrdereditRequestBuilder ¶

type ByProjectKeyShippingMethodsMatchingOrdereditRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsMatchingOrdereditRequestBuilder) Get ¶

* * Retrieves all the ShippingMethods that can ship to the given Location(/../api/projects/zones#location) for an OrderEdit(/../api/projects/order-edits). * * If the OrderEdit preview cannot be generated, an [EditPreviewFailed](ctp:api:type:EditPreviewFailedError) error is returned. *

type ByProjectKeyShippingMethodsMatchingOrdereditRequestMethodGet ¶

type ByProjectKeyShippingMethodsMatchingOrdereditRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsMatchingOrdereditRequestMethodGet) Country ¶

func (*ByProjectKeyShippingMethodsMatchingOrdereditRequestMethodGet) Dump ¶

func (*ByProjectKeyShippingMethodsMatchingOrdereditRequestMethodGet) Execute ¶

* * Retrieves all the ShippingMethods that can ship to the given Location(/../api/projects/zones#location) for an OrderEdit(/../api/projects/order-edits). * * If the OrderEdit preview cannot be generated, an [EditPreviewFailed](ctp:api:type:EditPreviewFailedError) error is returned. *

func (*ByProjectKeyShippingMethodsMatchingOrdereditRequestMethodGet) OrderEditId ¶

func (*ByProjectKeyShippingMethodsMatchingOrdereditRequestMethodGet) State ¶

func (*ByProjectKeyShippingMethodsMatchingOrdereditRequestMethodGet) WithHeaders ¶

type ByProjectKeyShippingMethodsMatchingOrdereditRequestMethodGetInput ¶

type ByProjectKeyShippingMethodsMatchingOrdereditRequestMethodGetInput struct {
	OrderEditId string
	Country     string
	State       *string
}

func (*ByProjectKeyShippingMethodsMatchingOrdereditRequestMethodGetInput) Values ¶

type ByProjectKeyShippingMethodsRequestBuilder ¶

type ByProjectKeyShippingMethodsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsRequestBuilder) Get ¶

func (*ByProjectKeyShippingMethodsRequestBuilder) MatchingCart ¶

* * Get ShippingMethods for a cart

func (*ByProjectKeyShippingMethodsRequestBuilder) MatchingCartLocation ¶

* * Get ShippingMethods for a cart and location

func (*ByProjectKeyShippingMethodsRequestBuilder) MatchingLocation ¶

* * Get ShippingMethods for a location

func (*ByProjectKeyShippingMethodsRequestBuilder) MatchingOrderedit ¶

* * Get ShippingMethods for an order edit

func (*ByProjectKeyShippingMethodsRequestBuilder) Post ¶

func (*ByProjectKeyShippingMethodsRequestBuilder) WithId ¶

func (*ByProjectKeyShippingMethodsRequestBuilder) WithKey ¶

type ByProjectKeyShippingMethodsRequestMethodGet ¶

type ByProjectKeyShippingMethodsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsRequestMethodGet) Dump ¶

func (r *ByProjectKeyShippingMethodsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyShippingMethodsRequestMethodGet) Execute ¶

func (*ByProjectKeyShippingMethodsRequestMethodGet) Expand ¶

func (*ByProjectKeyShippingMethodsRequestMethodGet) Limit ¶

func (*ByProjectKeyShippingMethodsRequestMethodGet) Offset ¶

func (*ByProjectKeyShippingMethodsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyShippingMethodsRequestMethodGet) Sort ¶

func (*ByProjectKeyShippingMethodsRequestMethodGet) Where ¶

func (*ByProjectKeyShippingMethodsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyShippingMethodsRequestMethodGet) WithTotal ¶

type ByProjectKeyShippingMethodsRequestMethodGetInput ¶

type ByProjectKeyShippingMethodsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyShippingMethodsRequestMethodGetInput) Values ¶

type ByProjectKeyShippingMethodsRequestMethodPost ¶

type ByProjectKeyShippingMethodsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShippingMethodsRequestMethodPost) Dump ¶

func (r *ByProjectKeyShippingMethodsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyShippingMethodsRequestMethodPost) Execute ¶

func (*ByProjectKeyShippingMethodsRequestMethodPost) Expand ¶

func (*ByProjectKeyShippingMethodsRequestMethodPost) WithHeaders ¶

type ByProjectKeyShippingMethodsRequestMethodPostInput ¶

type ByProjectKeyShippingMethodsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyShippingMethodsRequestMethodPostInput) Values ¶

type ByProjectKeyShoppingListsByIDRequestBuilder ¶

type ByProjectKeyShoppingListsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShoppingListsByIDRequestBuilder) Delete ¶

func (*ByProjectKeyShoppingListsByIDRequestBuilder) Get ¶

func (*ByProjectKeyShoppingListsByIDRequestBuilder) Post ¶

type ByProjectKeyShoppingListsByIDRequestMethodDelete ¶

type ByProjectKeyShoppingListsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShoppingListsByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyShoppingListsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyShoppingListsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyShoppingListsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyShoppingListsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyShoppingListsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyShoppingListsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyShoppingListsByIDRequestMethodDeleteInput ¶

type ByProjectKeyShoppingListsByIDRequestMethodDeleteInput struct {
	Expand      []string
	DataErasure *bool
	Version     int
}

func (*ByProjectKeyShoppingListsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyShoppingListsByIDRequestMethodGet ¶

type ByProjectKeyShoppingListsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShoppingListsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyShoppingListsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyShoppingListsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyShoppingListsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyShoppingListsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyShoppingListsByIDRequestMethodGetInput ¶

type ByProjectKeyShoppingListsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyShoppingListsByIDRequestMethodGetInput) Values ¶

type ByProjectKeyShoppingListsByIDRequestMethodPost ¶

type ByProjectKeyShoppingListsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShoppingListsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyShoppingListsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyShoppingListsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyShoppingListsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyShoppingListsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyShoppingListsByIDRequestMethodPostInput ¶

type ByProjectKeyShoppingListsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyShoppingListsByIDRequestMethodPostInput) Values ¶

type ByProjectKeyShoppingListsKeyByKeyRequestBuilder ¶

type ByProjectKeyShoppingListsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShoppingListsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodDelete ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodDeleteInput struct {
	Expand      []string
	DataErasure *bool
	Version     int
}

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodGet ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodPost ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyShoppingListsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyShoppingListsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyShoppingListsRequestBuilder ¶

type ByProjectKeyShoppingListsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShoppingListsRequestBuilder) Get ¶

func (*ByProjectKeyShoppingListsRequestBuilder) Post ¶

func (*ByProjectKeyShoppingListsRequestBuilder) WithId ¶

func (*ByProjectKeyShoppingListsRequestBuilder) WithKey ¶

type ByProjectKeyShoppingListsRequestMethodGet ¶

type ByProjectKeyShoppingListsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShoppingListsRequestMethodGet) Dump ¶

func (r *ByProjectKeyShoppingListsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyShoppingListsRequestMethodGet) Execute ¶

func (*ByProjectKeyShoppingListsRequestMethodGet) Expand ¶

func (*ByProjectKeyShoppingListsRequestMethodGet) Limit ¶

func (*ByProjectKeyShoppingListsRequestMethodGet) Offset ¶

func (*ByProjectKeyShoppingListsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyShoppingListsRequestMethodGet) Sort ¶

func (*ByProjectKeyShoppingListsRequestMethodGet) Where ¶

func (*ByProjectKeyShoppingListsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyShoppingListsRequestMethodGet) WithTotal ¶

type ByProjectKeyShoppingListsRequestMethodGetInput ¶

type ByProjectKeyShoppingListsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyShoppingListsRequestMethodGetInput) Values ¶

type ByProjectKeyShoppingListsRequestMethodPost ¶

type ByProjectKeyShoppingListsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyShoppingListsRequestMethodPost) Dump ¶

func (r *ByProjectKeyShoppingListsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyShoppingListsRequestMethodPost) Execute ¶

func (*ByProjectKeyShoppingListsRequestMethodPost) Expand ¶

func (*ByProjectKeyShoppingListsRequestMethodPost) WithHeaders ¶

type ByProjectKeyShoppingListsRequestMethodPostInput ¶

type ByProjectKeyShoppingListsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyShoppingListsRequestMethodPostInput) Values ¶

type ByProjectKeyStagedQuotesByIDRequestBuilder ¶

type ByProjectKeyStagedQuotesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStagedQuotesByIDRequestBuilder) Delete ¶

func (*ByProjectKeyStagedQuotesByIDRequestBuilder) Get ¶

func (*ByProjectKeyStagedQuotesByIDRequestBuilder) Post ¶

type ByProjectKeyStagedQuotesByIDRequestMethodDelete ¶

type ByProjectKeyStagedQuotesByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStagedQuotesByIDRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyStagedQuotesByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyStagedQuotesByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyStagedQuotesByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyStagedQuotesByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyStagedQuotesByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyStagedQuotesByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyStagedQuotesByIDRequestMethodDeleteInput ¶

type ByProjectKeyStagedQuotesByIDRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyStagedQuotesByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyStagedQuotesByIDRequestMethodGet ¶

type ByProjectKeyStagedQuotesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStagedQuotesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyStagedQuotesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyStagedQuotesByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyStagedQuotesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyStagedQuotesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyStagedQuotesByIDRequestMethodGetInput ¶

type ByProjectKeyStagedQuotesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyStagedQuotesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyStagedQuotesByIDRequestMethodPost ¶

type ByProjectKeyStagedQuotesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStagedQuotesByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyStagedQuotesByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyStagedQuotesByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyStagedQuotesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyStagedQuotesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyStagedQuotesByIDRequestMethodPostInput ¶

type ByProjectKeyStagedQuotesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStagedQuotesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestBuilder ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStagedQuotesKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodDelete ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodDelete) DataErasure ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodDeleteInput struct {
	DataErasure *bool
	Version     int
	Expand      []string
}

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodGet ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyStagedQuotesKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodPost ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyStagedQuotesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStagedQuotesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyStagedQuotesRequestBuilder ¶

type ByProjectKeyStagedQuotesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStagedQuotesRequestBuilder) Get ¶

func (*ByProjectKeyStagedQuotesRequestBuilder) Post ¶

func (*ByProjectKeyStagedQuotesRequestBuilder) WithId ¶

func (*ByProjectKeyStagedQuotesRequestBuilder) WithKey ¶

type ByProjectKeyStagedQuotesRequestMethodGet ¶

type ByProjectKeyStagedQuotesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStagedQuotesRequestMethodGet) Dump ¶

func (r *ByProjectKeyStagedQuotesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyStagedQuotesRequestMethodGet) Execute ¶

func (*ByProjectKeyStagedQuotesRequestMethodGet) Expand ¶

func (*ByProjectKeyStagedQuotesRequestMethodGet) Limit ¶

func (*ByProjectKeyStagedQuotesRequestMethodGet) Offset ¶

func (*ByProjectKeyStagedQuotesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyStagedQuotesRequestMethodGet) Sort ¶

func (*ByProjectKeyStagedQuotesRequestMethodGet) Where ¶

func (*ByProjectKeyStagedQuotesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyStagedQuotesRequestMethodGet) WithTotal ¶

type ByProjectKeyStagedQuotesRequestMethodGetInput ¶

type ByProjectKeyStagedQuotesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyStagedQuotesRequestMethodGetInput) Values ¶

type ByProjectKeyStagedQuotesRequestMethodPost ¶

type ByProjectKeyStagedQuotesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStagedQuotesRequestMethodPost) Dump ¶

func (r *ByProjectKeyStagedQuotesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyStagedQuotesRequestMethodPost) Execute ¶

func (*ByProjectKeyStagedQuotesRequestMethodPost) Expand ¶

func (*ByProjectKeyStagedQuotesRequestMethodPost) WithHeaders ¶

type ByProjectKeyStagedQuotesRequestMethodPostInput ¶

type ByProjectKeyStagedQuotesRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStagedQuotesRequestMethodPostInput) Values ¶

type ByProjectKeyStandalonePricesByIDRequestBuilder ¶

type ByProjectKeyStandalonePricesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStandalonePricesByIDRequestBuilder) Delete ¶

* * Produces the [StandalonePriceDeleted](ctp:api:type:StandalonePriceDeletedMessage) Message. *

func (*ByProjectKeyStandalonePricesByIDRequestBuilder) Get ¶

func (*ByProjectKeyStandalonePricesByIDRequestBuilder) Post ¶

type ByProjectKeyStandalonePricesByIDRequestMethodDelete ¶

type ByProjectKeyStandalonePricesByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStandalonePricesByIDRequestMethodDelete) Dump ¶

func (*ByProjectKeyStandalonePricesByIDRequestMethodDelete) Execute ¶

* * Produces the [StandalonePriceDeleted](ctp:api:type:StandalonePriceDeletedMessage) Message. *

func (*ByProjectKeyStandalonePricesByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyStandalonePricesByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyStandalonePricesByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyStandalonePricesByIDRequestMethodDeleteInput ¶

type ByProjectKeyStandalonePricesByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyStandalonePricesByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyStandalonePricesByIDRequestMethodGet ¶

type ByProjectKeyStandalonePricesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStandalonePricesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyStandalonePricesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyStandalonePricesByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyStandalonePricesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyStandalonePricesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyStandalonePricesByIDRequestMethodGetInput ¶

type ByProjectKeyStandalonePricesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyStandalonePricesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyStandalonePricesByIDRequestMethodPost ¶

type ByProjectKeyStandalonePricesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStandalonePricesByIDRequestMethodPost) Dump ¶

func (*ByProjectKeyStandalonePricesByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyStandalonePricesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyStandalonePricesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyStandalonePricesByIDRequestMethodPostInput ¶

type ByProjectKeyStandalonePricesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStandalonePricesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestBuilder ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStandalonePricesKeyByKeyRequestBuilder) Delete ¶

* * Produces the [StandalonePriceDeleted](ctp:api:type:StandalonePriceDeletedMessage) Message. *

func (*ByProjectKeyStandalonePricesKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyStandalonePricesKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodDelete ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodDelete) Execute ¶

* * Produces the [StandalonePriceDeleted](ctp:api:type:StandalonePriceDeletedMessage) Message. *

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodGet ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodPost ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyStandalonePricesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStandalonePricesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyStandalonePricesRequestBuilder ¶

type ByProjectKeyStandalonePricesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStandalonePricesRequestBuilder) Get ¶

func (*ByProjectKeyStandalonePricesRequestBuilder) Post ¶

* * Produces the [StandalonePriceCreated](ctp:api:type:StandalonePriceCreatedMessage) Message. *

func (*ByProjectKeyStandalonePricesRequestBuilder) WithId ¶

func (*ByProjectKeyStandalonePricesRequestBuilder) WithKey ¶

type ByProjectKeyStandalonePricesRequestMethodGet ¶

type ByProjectKeyStandalonePricesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStandalonePricesRequestMethodGet) Dump ¶

func (r *ByProjectKeyStandalonePricesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyStandalonePricesRequestMethodGet) Execute ¶

func (*ByProjectKeyStandalonePricesRequestMethodGet) Expand ¶

func (*ByProjectKeyStandalonePricesRequestMethodGet) Limit ¶

func (*ByProjectKeyStandalonePricesRequestMethodGet) Offset ¶

func (*ByProjectKeyStandalonePricesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyStandalonePricesRequestMethodGet) Sort ¶

func (*ByProjectKeyStandalonePricesRequestMethodGet) Where ¶

func (*ByProjectKeyStandalonePricesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyStandalonePricesRequestMethodGet) WithTotal ¶

type ByProjectKeyStandalonePricesRequestMethodGetInput ¶

type ByProjectKeyStandalonePricesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyStandalonePricesRequestMethodGetInput) Values ¶

type ByProjectKeyStandalonePricesRequestMethodPost ¶

type ByProjectKeyStandalonePricesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStandalonePricesRequestMethodPost) Dump ¶

func (r *ByProjectKeyStandalonePricesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyStandalonePricesRequestMethodPost) Execute ¶

* * Produces the [StandalonePriceCreated](ctp:api:type:StandalonePriceCreatedMessage) Message. *

func (*ByProjectKeyStandalonePricesRequestMethodPost) Expand ¶

func (*ByProjectKeyStandalonePricesRequestMethodPost) WithHeaders ¶

type ByProjectKeyStandalonePricesRequestMethodPostInput ¶

type ByProjectKeyStandalonePricesRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStandalonePricesRequestMethodPostInput) Values ¶

type ByProjectKeyStatesByIDRequestBuilder ¶

type ByProjectKeyStatesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStatesByIDRequestBuilder) Delete ¶

func (*ByProjectKeyStatesByIDRequestBuilder) Get ¶

func (*ByProjectKeyStatesByIDRequestBuilder) Post ¶

type ByProjectKeyStatesByIDRequestMethodDelete ¶

type ByProjectKeyStatesByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStatesByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyStatesByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyStatesByIDRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyStatesByIDRequestMethodDelete) Execute(ctx context.Context) (result *State, err error)

func (*ByProjectKeyStatesByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyStatesByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyStatesByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyStatesByIDRequestMethodDeleteInput ¶

type ByProjectKeyStatesByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyStatesByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyStatesByIDRequestMethodGet ¶

type ByProjectKeyStatesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStatesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyStatesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyStatesByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyStatesByIDRequestMethodGet) Execute(ctx context.Context) (result *State, err error)

func (*ByProjectKeyStatesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyStatesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyStatesByIDRequestMethodGetInput ¶

type ByProjectKeyStatesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyStatesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyStatesByIDRequestMethodPost ¶

type ByProjectKeyStatesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStatesByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyStatesByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyStatesByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyStatesByIDRequestMethodPost) Execute(ctx context.Context) (result *State, err error)

func (*ByProjectKeyStatesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyStatesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyStatesByIDRequestMethodPostInput ¶

type ByProjectKeyStatesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStatesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyStatesKeyByKeyRequestBuilder ¶

type ByProjectKeyStatesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStatesKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyStatesKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyStatesKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyStatesKeyByKeyRequestMethodDelete ¶

type ByProjectKeyStatesKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStatesKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyStatesKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyStatesKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyStatesKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyStatesKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyStatesKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyStatesKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyStatesKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyStatesKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyStatesKeyByKeyRequestMethodGet ¶

type ByProjectKeyStatesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStatesKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyStatesKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyStatesKeyByKeyRequestMethodGet) Execute ¶

func (rb *ByProjectKeyStatesKeyByKeyRequestMethodGet) Execute(ctx context.Context) (result *State, err error)

func (*ByProjectKeyStatesKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyStatesKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyStatesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyStatesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyStatesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyStatesKeyByKeyRequestMethodPost ¶

type ByProjectKeyStatesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStatesKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyStatesKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyStatesKeyByKeyRequestMethodPost) Execute ¶

func (rb *ByProjectKeyStatesKeyByKeyRequestMethodPost) Execute(ctx context.Context) (result *State, err error)

func (*ByProjectKeyStatesKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyStatesKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyStatesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyStatesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStatesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyStatesRequestBuilder ¶

type ByProjectKeyStatesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStatesRequestBuilder) Get ¶

func (*ByProjectKeyStatesRequestBuilder) Post ¶

func (*ByProjectKeyStatesRequestBuilder) WithId ¶

func (*ByProjectKeyStatesRequestBuilder) WithKey ¶

type ByProjectKeyStatesRequestMethodGet ¶

type ByProjectKeyStatesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStatesRequestMethodGet) Dump ¶

func (r *ByProjectKeyStatesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyStatesRequestMethodGet) Execute ¶

func (*ByProjectKeyStatesRequestMethodGet) Expand ¶

func (*ByProjectKeyStatesRequestMethodGet) Limit ¶

func (*ByProjectKeyStatesRequestMethodGet) Offset ¶

func (*ByProjectKeyStatesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyStatesRequestMethodGet) Sort ¶

func (*ByProjectKeyStatesRequestMethodGet) Where ¶

func (*ByProjectKeyStatesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyStatesRequestMethodGet) WithQueryParams ¶

func (*ByProjectKeyStatesRequestMethodGet) WithTotal ¶

type ByProjectKeyStatesRequestMethodGetInput ¶

type ByProjectKeyStatesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyStatesRequestMethodGetInput) Values ¶

type ByProjectKeyStatesRequestMethodPost ¶

type ByProjectKeyStatesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStatesRequestMethodPost) Dump ¶

func (r *ByProjectKeyStatesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyStatesRequestMethodPost) Execute ¶

func (rb *ByProjectKeyStatesRequestMethodPost) Execute(ctx context.Context) (result *State, err error)

func (*ByProjectKeyStatesRequestMethodPost) Expand ¶

func (*ByProjectKeyStatesRequestMethodPost) WithHeaders ¶

type ByProjectKeyStatesRequestMethodPostInput ¶

type ByProjectKeyStatesRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStatesRequestMethodPostInput) Values ¶

type ByProjectKeyStoresByIDRequestBuilder ¶

type ByProjectKeyStoresByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStoresByIDRequestBuilder) Delete ¶

func (*ByProjectKeyStoresByIDRequestBuilder) Get ¶

func (*ByProjectKeyStoresByIDRequestBuilder) Post ¶

type ByProjectKeyStoresByIDRequestMethodDelete ¶

type ByProjectKeyStoresByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStoresByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyStoresByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyStoresByIDRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyStoresByIDRequestMethodDelete) Execute(ctx context.Context) (result *Store, err error)

func (*ByProjectKeyStoresByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyStoresByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyStoresByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyStoresByIDRequestMethodDeleteInput ¶

type ByProjectKeyStoresByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyStoresByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyStoresByIDRequestMethodGet ¶

type ByProjectKeyStoresByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStoresByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyStoresByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyStoresByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyStoresByIDRequestMethodGet) Execute(ctx context.Context) (result *Store, err error)

func (*ByProjectKeyStoresByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyStoresByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyStoresByIDRequestMethodGetInput ¶

type ByProjectKeyStoresByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyStoresByIDRequestMethodGetInput) Values ¶

type ByProjectKeyStoresByIDRequestMethodPost ¶

type ByProjectKeyStoresByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStoresByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyStoresByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyStoresByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyStoresByIDRequestMethodPost) Execute(ctx context.Context) (result *Store, err error)

func (*ByProjectKeyStoresByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyStoresByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyStoresByIDRequestMethodPostInput ¶

type ByProjectKeyStoresByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStoresByIDRequestMethodPostInput) Values ¶

type ByProjectKeyStoresKeyByKeyRequestBuilder ¶

type ByProjectKeyStoresKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStoresKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyStoresKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyStoresKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyStoresKeyByKeyRequestMethodDelete ¶

type ByProjectKeyStoresKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStoresKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyStoresKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyStoresKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyStoresKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyStoresKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyStoresKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyStoresKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyStoresKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyStoresKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyStoresKeyByKeyRequestMethodGet ¶

type ByProjectKeyStoresKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStoresKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyStoresKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyStoresKeyByKeyRequestMethodGet) Execute ¶

func (rb *ByProjectKeyStoresKeyByKeyRequestMethodGet) Execute(ctx context.Context) (result *Store, err error)

func (*ByProjectKeyStoresKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyStoresKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyStoresKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyStoresKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyStoresKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyStoresKeyByKeyRequestMethodPost ¶

type ByProjectKeyStoresKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStoresKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyStoresKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyStoresKeyByKeyRequestMethodPost) Execute ¶

func (rb *ByProjectKeyStoresKeyByKeyRequestMethodPost) Execute(ctx context.Context) (result *Store, err error)

func (*ByProjectKeyStoresKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyStoresKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyStoresKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyStoresKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStoresKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyStoresRequestBuilder ¶

type ByProjectKeyStoresRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStoresRequestBuilder) Get ¶

func (*ByProjectKeyStoresRequestBuilder) Post ¶

func (*ByProjectKeyStoresRequestBuilder) WithId ¶

func (*ByProjectKeyStoresRequestBuilder) WithKey ¶

type ByProjectKeyStoresRequestMethodGet ¶

type ByProjectKeyStoresRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStoresRequestMethodGet) Dump ¶

func (r *ByProjectKeyStoresRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyStoresRequestMethodGet) Execute ¶

func (*ByProjectKeyStoresRequestMethodGet) Expand ¶

func (*ByProjectKeyStoresRequestMethodGet) Limit ¶

func (*ByProjectKeyStoresRequestMethodGet) Offset ¶

func (*ByProjectKeyStoresRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyStoresRequestMethodGet) Sort ¶

func (*ByProjectKeyStoresRequestMethodGet) Where ¶

func (*ByProjectKeyStoresRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyStoresRequestMethodGet) WithQueryParams ¶

func (*ByProjectKeyStoresRequestMethodGet) WithTotal ¶

type ByProjectKeyStoresRequestMethodGetInput ¶

type ByProjectKeyStoresRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyStoresRequestMethodGetInput) Values ¶

type ByProjectKeyStoresRequestMethodPost ¶

type ByProjectKeyStoresRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyStoresRequestMethodPost) Dump ¶

func (r *ByProjectKeyStoresRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyStoresRequestMethodPost) Execute ¶

func (rb *ByProjectKeyStoresRequestMethodPost) Execute(ctx context.Context) (result *Store, err error)

func (*ByProjectKeyStoresRequestMethodPost) Expand ¶

func (*ByProjectKeyStoresRequestMethodPost) WithHeaders ¶

type ByProjectKeyStoresRequestMethodPostInput ¶

type ByProjectKeyStoresRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyStoresRequestMethodPostInput) Values ¶

type ByProjectKeySubscriptionsByIDHealthRequestBuilder ¶

type ByProjectKeySubscriptionsByIDHealthRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsByIDHealthRequestBuilder) Get ¶

* * This endpoint can be polled by a monitoring or alerting system that checks the health of your Subscriptions. To ease integration with such systems this endpoint does not require [Authorization](/../api/authorization). *

type ByProjectKeySubscriptionsByIDHealthRequestMethodGet ¶

type ByProjectKeySubscriptionsByIDHealthRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsByIDHealthRequestMethodGet) Dump ¶

func (*ByProjectKeySubscriptionsByIDHealthRequestMethodGet) Execute ¶

* * This endpoint can be polled by a monitoring or alerting system that checks the health of your Subscriptions. To ease integration with such systems this endpoint does not require [Authorization](/../api/authorization). *

func (*ByProjectKeySubscriptionsByIDHealthRequestMethodGet) WithHeaders ¶

type ByProjectKeySubscriptionsByIDRequestBuilder ¶

type ByProjectKeySubscriptionsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsByIDRequestBuilder) Delete ¶

func (*ByProjectKeySubscriptionsByIDRequestBuilder) Get ¶

func (*ByProjectKeySubscriptionsByIDRequestBuilder) Post ¶

func (*ByProjectKeySubscriptionsByIDRequestBuilder) WithIdHealth ¶

type ByProjectKeySubscriptionsByIDRequestMethodDelete ¶

type ByProjectKeySubscriptionsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeySubscriptionsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeySubscriptionsByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeySubscriptionsByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeySubscriptionsByIDRequestMethodDelete) Version ¶

func (*ByProjectKeySubscriptionsByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeySubscriptionsByIDRequestMethodDeleteInput ¶

type ByProjectKeySubscriptionsByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeySubscriptionsByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeySubscriptionsByIDRequestMethodGet ¶

type ByProjectKeySubscriptionsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeySubscriptionsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeySubscriptionsByIDRequestMethodGet) Execute ¶

func (*ByProjectKeySubscriptionsByIDRequestMethodGet) Expand ¶

func (*ByProjectKeySubscriptionsByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeySubscriptionsByIDRequestMethodGetInput ¶

type ByProjectKeySubscriptionsByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeySubscriptionsByIDRequestMethodGetInput) Values ¶

type ByProjectKeySubscriptionsByIDRequestMethodPost ¶

type ByProjectKeySubscriptionsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeySubscriptionsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeySubscriptionsByIDRequestMethodPost) Execute ¶

func (*ByProjectKeySubscriptionsByIDRequestMethodPost) Expand ¶

func (*ByProjectKeySubscriptionsByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeySubscriptionsByIDRequestMethodPostInput ¶

type ByProjectKeySubscriptionsByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeySubscriptionsByIDRequestMethodPostInput) Values ¶

type ByProjectKeySubscriptionsKeyByKeyRequestBuilder ¶

type ByProjectKeySubscriptionsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestBuilder) Post ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodDelete ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodGet ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodGetInput ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodPost ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodPostInput ¶

type ByProjectKeySubscriptionsKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeySubscriptionsKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeySubscriptionsRequestBuilder ¶

type ByProjectKeySubscriptionsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsRequestBuilder) Get ¶

func (*ByProjectKeySubscriptionsRequestBuilder) Post ¶

* * A test message is sent to ensure the correct configuration of the Destination. If the message cannot be delivered, the Subscription will not be created. The payload of the test message is a notification of type [ResourceCreated](/../api/projects/subscriptions#resourcecreateddeliverypayload) for the `resourceTypeId` `subscription`. *

func (*ByProjectKeySubscriptionsRequestBuilder) WithId ¶

func (*ByProjectKeySubscriptionsRequestBuilder) WithKey ¶

type ByProjectKeySubscriptionsRequestMethodGet ¶

type ByProjectKeySubscriptionsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsRequestMethodGet) Dump ¶

func (r *ByProjectKeySubscriptionsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeySubscriptionsRequestMethodGet) Execute ¶

func (*ByProjectKeySubscriptionsRequestMethodGet) Expand ¶

func (*ByProjectKeySubscriptionsRequestMethodGet) Limit ¶

func (*ByProjectKeySubscriptionsRequestMethodGet) Offset ¶

func (*ByProjectKeySubscriptionsRequestMethodGet) PredicateVar ¶

func (*ByProjectKeySubscriptionsRequestMethodGet) Sort ¶

func (*ByProjectKeySubscriptionsRequestMethodGet) Where ¶

func (*ByProjectKeySubscriptionsRequestMethodGet) WithHeaders ¶

func (*ByProjectKeySubscriptionsRequestMethodGet) WithTotal ¶

type ByProjectKeySubscriptionsRequestMethodGetInput ¶

type ByProjectKeySubscriptionsRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeySubscriptionsRequestMethodGetInput) Values ¶

type ByProjectKeySubscriptionsRequestMethodPost ¶

type ByProjectKeySubscriptionsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeySubscriptionsRequestMethodPost) Dump ¶

func (r *ByProjectKeySubscriptionsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeySubscriptionsRequestMethodPost) Execute ¶

* * A test message is sent to ensure the correct configuration of the Destination. If the message cannot be delivered, the Subscription will not be created. The payload of the test message is a notification of type [ResourceCreated](/../api/projects/subscriptions#resourcecreateddeliverypayload) for the `resourceTypeId` `subscription`. *

func (*ByProjectKeySubscriptionsRequestMethodPost) Expand ¶

func (*ByProjectKeySubscriptionsRequestMethodPost) WithHeaders ¶

type ByProjectKeySubscriptionsRequestMethodPostInput ¶

type ByProjectKeySubscriptionsRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeySubscriptionsRequestMethodPostInput) Values ¶

type ByProjectKeyTaxCategoriesByIDRequestBuilder ¶

type ByProjectKeyTaxCategoriesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTaxCategoriesByIDRequestBuilder) Delete ¶

func (*ByProjectKeyTaxCategoriesByIDRequestBuilder) Get ¶

func (*ByProjectKeyTaxCategoriesByIDRequestBuilder) Post ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodDelete ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTaxCategoriesByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyTaxCategoriesByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyTaxCategoriesByIDRequestMethodDelete) Execute ¶

func (*ByProjectKeyTaxCategoriesByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyTaxCategoriesByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyTaxCategoriesByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodDeleteInput ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyTaxCategoriesByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodGet ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTaxCategoriesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyTaxCategoriesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyTaxCategoriesByIDRequestMethodGet) Execute ¶

func (*ByProjectKeyTaxCategoriesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyTaxCategoriesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodGetInput ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyTaxCategoriesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodPost ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTaxCategoriesByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyTaxCategoriesByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyTaxCategoriesByIDRequestMethodPost) Execute ¶

func (*ByProjectKeyTaxCategoriesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyTaxCategoriesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodPostInput ¶

type ByProjectKeyTaxCategoriesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyTaxCategoriesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestBuilder ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodDelete ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodDelete) Dump ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodDelete) Execute ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodGet ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodGet) Dump ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodGet) Execute ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodPost ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodPost) Dump ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodPost) Execute ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyTaxCategoriesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyTaxCategoriesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyTaxCategoriesRequestBuilder ¶

type ByProjectKeyTaxCategoriesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTaxCategoriesRequestBuilder) Get ¶

func (*ByProjectKeyTaxCategoriesRequestBuilder) Post ¶

func (*ByProjectKeyTaxCategoriesRequestBuilder) WithId ¶

func (*ByProjectKeyTaxCategoriesRequestBuilder) WithKey ¶

type ByProjectKeyTaxCategoriesRequestMethodGet ¶

type ByProjectKeyTaxCategoriesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTaxCategoriesRequestMethodGet) Dump ¶

func (r *ByProjectKeyTaxCategoriesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyTaxCategoriesRequestMethodGet) Execute ¶

func (*ByProjectKeyTaxCategoriesRequestMethodGet) Expand ¶

func (*ByProjectKeyTaxCategoriesRequestMethodGet) Limit ¶

func (*ByProjectKeyTaxCategoriesRequestMethodGet) Offset ¶

func (*ByProjectKeyTaxCategoriesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyTaxCategoriesRequestMethodGet) Sort ¶

func (*ByProjectKeyTaxCategoriesRequestMethodGet) Where ¶

func (*ByProjectKeyTaxCategoriesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyTaxCategoriesRequestMethodGet) WithTotal ¶

type ByProjectKeyTaxCategoriesRequestMethodGetInput ¶

type ByProjectKeyTaxCategoriesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyTaxCategoriesRequestMethodGetInput) Values ¶

type ByProjectKeyTaxCategoriesRequestMethodPost ¶

type ByProjectKeyTaxCategoriesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTaxCategoriesRequestMethodPost) Dump ¶

func (r *ByProjectKeyTaxCategoriesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyTaxCategoriesRequestMethodPost) Execute ¶

func (*ByProjectKeyTaxCategoriesRequestMethodPost) Expand ¶

func (*ByProjectKeyTaxCategoriesRequestMethodPost) WithHeaders ¶

type ByProjectKeyTaxCategoriesRequestMethodPostInput ¶

type ByProjectKeyTaxCategoriesRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyTaxCategoriesRequestMethodPostInput) Values ¶

type ByProjectKeyTypesByIDRequestBuilder ¶

type ByProjectKeyTypesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTypesByIDRequestBuilder) Delete ¶

func (*ByProjectKeyTypesByIDRequestBuilder) Get ¶

func (*ByProjectKeyTypesByIDRequestBuilder) Post ¶

type ByProjectKeyTypesByIDRequestMethodDelete ¶

type ByProjectKeyTypesByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTypesByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyTypesByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyTypesByIDRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyTypesByIDRequestMethodDelete) Execute(ctx context.Context) (result *Type, err error)

func (*ByProjectKeyTypesByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyTypesByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyTypesByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyTypesByIDRequestMethodDeleteInput ¶

type ByProjectKeyTypesByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyTypesByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyTypesByIDRequestMethodGet ¶

type ByProjectKeyTypesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTypesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyTypesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyTypesByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyTypesByIDRequestMethodGet) Execute(ctx context.Context) (result *Type, err error)

func (*ByProjectKeyTypesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyTypesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyTypesByIDRequestMethodGetInput ¶

type ByProjectKeyTypesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyTypesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyTypesByIDRequestMethodPost ¶

type ByProjectKeyTypesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTypesByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyTypesByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyTypesByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyTypesByIDRequestMethodPost) Execute(ctx context.Context) (result *Type, err error)

func (*ByProjectKeyTypesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyTypesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyTypesByIDRequestMethodPostInput ¶

type ByProjectKeyTypesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyTypesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyTypesKeyByKeyRequestBuilder ¶

type ByProjectKeyTypesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTypesKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyTypesKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyTypesKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyTypesKeyByKeyRequestMethodDelete ¶

type ByProjectKeyTypesKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTypesKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyTypesKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyTypesKeyByKeyRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyTypesKeyByKeyRequestMethodDelete) Execute(ctx context.Context) (result *Type, err error)

func (*ByProjectKeyTypesKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyTypesKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyTypesKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyTypesKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyTypesKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyTypesKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyTypesKeyByKeyRequestMethodGet ¶

type ByProjectKeyTypesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTypesKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyTypesKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyTypesKeyByKeyRequestMethodGet) Execute ¶

func (rb *ByProjectKeyTypesKeyByKeyRequestMethodGet) Execute(ctx context.Context) (result *Type, err error)

func (*ByProjectKeyTypesKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyTypesKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyTypesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyTypesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyTypesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyTypesKeyByKeyRequestMethodPost ¶

type ByProjectKeyTypesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTypesKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyTypesKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyTypesKeyByKeyRequestMethodPost) Execute ¶

func (rb *ByProjectKeyTypesKeyByKeyRequestMethodPost) Execute(ctx context.Context) (result *Type, err error)

func (*ByProjectKeyTypesKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyTypesKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyTypesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyTypesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyTypesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyTypesRequestBuilder ¶

type ByProjectKeyTypesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTypesRequestBuilder) Get ¶

func (*ByProjectKeyTypesRequestBuilder) Post ¶

func (*ByProjectKeyTypesRequestBuilder) WithId ¶

func (*ByProjectKeyTypesRequestBuilder) WithKey ¶

type ByProjectKeyTypesRequestMethodGet ¶

type ByProjectKeyTypesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTypesRequestMethodGet) Dump ¶

func (r *ByProjectKeyTypesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyTypesRequestMethodGet) Execute ¶

func (*ByProjectKeyTypesRequestMethodGet) Expand ¶

func (*ByProjectKeyTypesRequestMethodGet) Limit ¶

func (*ByProjectKeyTypesRequestMethodGet) Offset ¶

func (*ByProjectKeyTypesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyTypesRequestMethodGet) Sort ¶

func (*ByProjectKeyTypesRequestMethodGet) Where ¶

func (*ByProjectKeyTypesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyTypesRequestMethodGet) WithQueryParams ¶

func (*ByProjectKeyTypesRequestMethodGet) WithTotal ¶

type ByProjectKeyTypesRequestMethodGetInput ¶

type ByProjectKeyTypesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyTypesRequestMethodGetInput) Values ¶

type ByProjectKeyTypesRequestMethodPost ¶

type ByProjectKeyTypesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyTypesRequestMethodPost) Dump ¶

func (r *ByProjectKeyTypesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyTypesRequestMethodPost) Execute ¶

func (rb *ByProjectKeyTypesRequestMethodPost) Execute(ctx context.Context) (result *Type, err error)

func (*ByProjectKeyTypesRequestMethodPost) Expand ¶

func (*ByProjectKeyTypesRequestMethodPost) WithHeaders ¶

func (*ByProjectKeyTypesRequestMethodPost) WithQueryParams ¶

type ByProjectKeyTypesRequestMethodPostInput ¶

type ByProjectKeyTypesRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyTypesRequestMethodPostInput) Values ¶

type ByProjectKeyZonesByIDRequestBuilder ¶

type ByProjectKeyZonesByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyZonesByIDRequestBuilder) Delete ¶

func (*ByProjectKeyZonesByIDRequestBuilder) Get ¶

func (*ByProjectKeyZonesByIDRequestBuilder) Post ¶

type ByProjectKeyZonesByIDRequestMethodDelete ¶

type ByProjectKeyZonesByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyZonesByIDRequestMethodDelete) Dump ¶

func (r *ByProjectKeyZonesByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyZonesByIDRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyZonesByIDRequestMethodDelete) Execute(ctx context.Context) (result *Zone, err error)

func (*ByProjectKeyZonesByIDRequestMethodDelete) Expand ¶

func (*ByProjectKeyZonesByIDRequestMethodDelete) Version ¶

func (*ByProjectKeyZonesByIDRequestMethodDelete) WithHeaders ¶

type ByProjectKeyZonesByIDRequestMethodDeleteInput ¶

type ByProjectKeyZonesByIDRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyZonesByIDRequestMethodDeleteInput) Values ¶

type ByProjectKeyZonesByIDRequestMethodGet ¶

type ByProjectKeyZonesByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyZonesByIDRequestMethodGet) Dump ¶

func (r *ByProjectKeyZonesByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyZonesByIDRequestMethodGet) Execute ¶

func (rb *ByProjectKeyZonesByIDRequestMethodGet) Execute(ctx context.Context) (result *Zone, err error)

func (*ByProjectKeyZonesByIDRequestMethodGet) Expand ¶

func (*ByProjectKeyZonesByIDRequestMethodGet) WithHeaders ¶

type ByProjectKeyZonesByIDRequestMethodGetInput ¶

type ByProjectKeyZonesByIDRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyZonesByIDRequestMethodGetInput) Values ¶

type ByProjectKeyZonesByIDRequestMethodPost ¶

type ByProjectKeyZonesByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyZonesByIDRequestMethodPost) Dump ¶

func (r *ByProjectKeyZonesByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyZonesByIDRequestMethodPost) Execute ¶

func (rb *ByProjectKeyZonesByIDRequestMethodPost) Execute(ctx context.Context) (result *Zone, err error)

func (*ByProjectKeyZonesByIDRequestMethodPost) Expand ¶

func (*ByProjectKeyZonesByIDRequestMethodPost) WithHeaders ¶

type ByProjectKeyZonesByIDRequestMethodPostInput ¶

type ByProjectKeyZonesByIDRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyZonesByIDRequestMethodPostInput) Values ¶

type ByProjectKeyZonesKeyByKeyRequestBuilder ¶

type ByProjectKeyZonesKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyZonesKeyByKeyRequestBuilder) Delete ¶

func (*ByProjectKeyZonesKeyByKeyRequestBuilder) Get ¶

func (*ByProjectKeyZonesKeyByKeyRequestBuilder) Post ¶

type ByProjectKeyZonesKeyByKeyRequestMethodDelete ¶

type ByProjectKeyZonesKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyZonesKeyByKeyRequestMethodDelete) Dump ¶

func (r *ByProjectKeyZonesKeyByKeyRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyZonesKeyByKeyRequestMethodDelete) Execute ¶

func (rb *ByProjectKeyZonesKeyByKeyRequestMethodDelete) Execute(ctx context.Context) (result *Zone, err error)

func (*ByProjectKeyZonesKeyByKeyRequestMethodDelete) Expand ¶

func (*ByProjectKeyZonesKeyByKeyRequestMethodDelete) Version ¶

func (*ByProjectKeyZonesKeyByKeyRequestMethodDelete) WithHeaders ¶

type ByProjectKeyZonesKeyByKeyRequestMethodDeleteInput ¶

type ByProjectKeyZonesKeyByKeyRequestMethodDeleteInput struct {
	Version int
	Expand  []string
}

func (*ByProjectKeyZonesKeyByKeyRequestMethodDeleteInput) Values ¶

type ByProjectKeyZonesKeyByKeyRequestMethodGet ¶

type ByProjectKeyZonesKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyZonesKeyByKeyRequestMethodGet) Dump ¶

func (r *ByProjectKeyZonesKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyZonesKeyByKeyRequestMethodGet) Execute ¶

func (rb *ByProjectKeyZonesKeyByKeyRequestMethodGet) Execute(ctx context.Context) (result *Zone, err error)

func (*ByProjectKeyZonesKeyByKeyRequestMethodGet) Expand ¶

func (*ByProjectKeyZonesKeyByKeyRequestMethodGet) WithHeaders ¶

type ByProjectKeyZonesKeyByKeyRequestMethodGetInput ¶

type ByProjectKeyZonesKeyByKeyRequestMethodGetInput struct {
	Expand []string
}

func (*ByProjectKeyZonesKeyByKeyRequestMethodGetInput) Values ¶

type ByProjectKeyZonesKeyByKeyRequestMethodPost ¶

type ByProjectKeyZonesKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyZonesKeyByKeyRequestMethodPost) Dump ¶

func (r *ByProjectKeyZonesKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyZonesKeyByKeyRequestMethodPost) Execute ¶

func (rb *ByProjectKeyZonesKeyByKeyRequestMethodPost) Execute(ctx context.Context) (result *Zone, err error)

func (*ByProjectKeyZonesKeyByKeyRequestMethodPost) Expand ¶

func (*ByProjectKeyZonesKeyByKeyRequestMethodPost) WithHeaders ¶

type ByProjectKeyZonesKeyByKeyRequestMethodPostInput ¶

type ByProjectKeyZonesKeyByKeyRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyZonesKeyByKeyRequestMethodPostInput) Values ¶

type ByProjectKeyZonesRequestBuilder ¶

type ByProjectKeyZonesRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyZonesRequestBuilder) Get ¶

func (*ByProjectKeyZonesRequestBuilder) Post ¶

func (*ByProjectKeyZonesRequestBuilder) WithId ¶

func (*ByProjectKeyZonesRequestBuilder) WithKey ¶

type ByProjectKeyZonesRequestMethodGet ¶

type ByProjectKeyZonesRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyZonesRequestMethodGet) Dump ¶

func (r *ByProjectKeyZonesRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyZonesRequestMethodGet) Execute ¶

func (*ByProjectKeyZonesRequestMethodGet) Expand ¶

func (*ByProjectKeyZonesRequestMethodGet) Limit ¶

func (*ByProjectKeyZonesRequestMethodGet) Offset ¶

func (*ByProjectKeyZonesRequestMethodGet) PredicateVar ¶

func (*ByProjectKeyZonesRequestMethodGet) Sort ¶

func (*ByProjectKeyZonesRequestMethodGet) Where ¶

func (*ByProjectKeyZonesRequestMethodGet) WithHeaders ¶

func (*ByProjectKeyZonesRequestMethodGet) WithQueryParams ¶

func (*ByProjectKeyZonesRequestMethodGet) WithTotal ¶

type ByProjectKeyZonesRequestMethodGetInput ¶

type ByProjectKeyZonesRequestMethodGetInput struct {
	Expand       []string
	Sort         []string
	Limit        *int
	Offset       *int
	WithTotal    *bool
	Where        []string
	PredicateVar map[string][]string
}

func (*ByProjectKeyZonesRequestMethodGetInput) Values ¶

type ByProjectKeyZonesRequestMethodPost ¶

type ByProjectKeyZonesRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyZonesRequestMethodPost) Dump ¶

func (r *ByProjectKeyZonesRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyZonesRequestMethodPost) Execute ¶

func (rb *ByProjectKeyZonesRequestMethodPost) Execute(ctx context.Context) (result *Zone, err error)

func (*ByProjectKeyZonesRequestMethodPost) Expand ¶

func (*ByProjectKeyZonesRequestMethodPost) WithHeaders ¶

func (*ByProjectKeyZonesRequestMethodPost) WithQueryParams ¶

type ByProjectKeyZonesRequestMethodPostInput ¶

type ByProjectKeyZonesRequestMethodPostInput struct {
	Expand []string
}

func (*ByProjectKeyZonesRequestMethodPostInput) Values ¶

type Cart ¶

type Cart struct {
	// Unique identifier of the Cart.
	ID string `json:"id"`
	// Current version of the Cart.
	Version int `json:"version"`
	// Date and time (UTC) the Cart was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Cart was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// User-defined unique identifier of the Cart.
	Key *string `json:"key,omitempty"`
	// `id` of the [Customer](ctp:api:type:Customer) that the Cart belongs to.
	CustomerId *string `json:"customerId,omitempty"`
	// Email address of the Customer that the Cart belongs to.
	CustomerEmail *string `json:"customerEmail,omitempty"`
	// [Reference](ctp:api:type:Reference) to the Customer Group of the Customer that the Cart belongs to. Used for [LineItem Price selection](ctp:api:type:LineItemPriceSelection).
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// [Anonymous session](ctp:api:type:AnonymousSession) associated with the Cart.
	AnonymousId *string `json:"anonymousId,omitempty"`
	// [Reference](ctp:api:type:Reference) to a Business Unit the Cart belongs to.
	BusinessUnit *BusinessUnitKeyReference `json:"businessUnit,omitempty"`
	// [Reference](ctp:api:type:Reference) to a Store the Cart belongs to.
	Store *StoreKeyReference `json:"store,omitempty"`
	// [Line Items](ctp:api:type:LineItems) added to the Cart.
	LineItems []LineItem `json:"lineItems"`
	// [Custom Line Items](ctp:api:type:CustomLineItems) added to the Cart.
	CustomLineItems []CustomLineItem `json:"customLineItems"`
	// Sum of all [LineItem](ctp:api:type:LineItem) quantities, excluding [CustomLineItems](ctp:api:type:CustomLineItem). Only present when the Cart has at least one LineItem.
	TotalLineItemQuantity *int `json:"totalLineItemQuantity,omitempty"`
	// Sum of the `totalPrice` field of all [LineItems](ctp:api:type:LineItem) and [CustomLineItems](ctp:api:type:CustomLineItem), and if available, the `price` field of [ShippingInfo](ctp:api:type:ShippingInfo).
	//
	// Taxes are included if [TaxRate](ctp:api:type:TaxRate) `includedInPrice` is `true` for each price.
	TotalPrice CentPrecisionMoney `json:"totalPrice"`
	// - For a Cart with `Platform` [TaxMode](ctp:api:type:TaxMode), it is automatically set when a [shipping address is set](ctp:api:type:CartSetShippingAddressAction).
	// - For a Cart with `External` [TaxMode](ctp:api:type:TaxMode), it is automatically set when the external Tax Rate for all Line Items, Custom Line Items, and Shipping Methods in the Cart are set.
	TaxedPrice *TaxedPrice `json:"taxedPrice,omitempty"`
	// Sum of the `taxedPrice` field of [ShippingInfo](ctp:api:type:ShippingInfo) across all Shipping Methods.
	TaxedShippingPrice *TaxedPrice `json:"taxedShippingPrice,omitempty"`
	// Indicates how Tax Rates are set.
	TaxMode TaxMode `json:"taxMode"`
	// Indicates how monetary values are rounded when calculating taxes for `taxedPrice`.
	TaxRoundingMode RoundingMode `json:"taxRoundingMode"`
	// Indicates how taxes are calculated when calculating taxes for `taxedPrice`.
	TaxCalculationMode TaxCalculationMode `json:"taxCalculationMode"`
	// Indicates how stock quantities are tracked for Line Items in the Cart.
	InventoryMode InventoryMode `json:"inventoryMode"`
	// Current status of the Cart.
	CartState CartState `json:"cartState"`
	// Billing address associated with the Cart.
	BillingAddress *Address `json:"billingAddress,omitempty"`
	// Shipping address associated with the Cart. Determines eligible [ShippingMethod](ctp:api:type:ShippingMethod) rates and Tax Rates of Line Items.
	ShippingAddress *Address `json:"shippingAddress,omitempty"`
	// Indicates whether the Cart has one or multiple Shipping Methods.
	ShippingMode ShippingMode `json:"shippingMode"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Single` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
	// Shipping-related information of a Cart with `Single` [ShippingMode](ctp:api:type:ShippingMode). Automatically set when a [Shipping Method is set](ctp:api:type:CartSetShippingMethodAction).
	ShippingInfo *ShippingInfo `json:"shippingInfo,omitempty"`
	// Input used to select a [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	// The data type of this field depends on the `shippingRateInputType.type` configured in the [Project](ctp:api:type:Project):
	//
	// - If `CartClassification`, it is [ClassificationShippingRateInput](ctp:api:type:ClassificationShippingRateInput).
	// - If `CartScore`, it is [ScoreShippingRateInput](ctp:api:type:ScoreShippingRateInput).
	// - If `CartValue`, it cannot be used.
	ShippingRateInput ShippingRateInput `json:"shippingRateInput,omitempty"`
	// Custom Fields of the Shipping Method in a Cart with `Single` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingCustomFields *CustomFields `json:"shippingCustomFields,omitempty"`
	// Shipping-related information of a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode). Updated automatically each time a new [Shipping Method is added](ctp:api:type:CartAddShippingMethodAction).
	Shipping []Shipping `json:"shipping"`
	// Additional shipping addresses of the Cart as specified by [LineItems](ctp:api:type:LineItem) using the `shippingDetails` field.
	//
	// Eligible Shipping Methods or applicable Tax Rates are determined by the address in `shippingAddress`, and not `itemShippingAddresses`.
	ItemShippingAddresses []Address `json:"itemShippingAddresses"`
	// Discount Codes applied to the Cart. A Cart that has `directDiscounts` cannot have `discountCodes`.
	DiscountCodes []DiscountCodeInfo `json:"discountCodes"`
	// Direct Discounts added to the Cart. A Cart that has `discountCodes` cannot have `directDiscounts`.
	DirectDiscounts []DirectDiscount `json:"directDiscounts"`
	// Automatically set when a Line Item with `GiftLineItem` [LineItemMode](ctp:api:type:LineItemMode) is [removed](ctp:api:type:CartRemoveLineItemAction) from the Cart.
	RefusedGifts []CartDiscountReference `json:"refusedGifts"`
	// Payment information related to the Cart.
	PaymentInfo *PaymentInfo `json:"paymentInfo,omitempty"`
	// Used for [LineItem Price selection](ctp:api:type:LineItemPriceSelection).
	Country *string `json:"country,omitempty"`
	// Languages of the Cart. Can only contain languages supported by the [Project](ctp:api:type:Project).
	Locale *string `json:"locale,omitempty"`
	// Indicates how the Cart was created.
	Origin CartOrigin `json:"origin"`
	// Custom Fields of the Cart.
	Custom *CustomFields `json:"custom,omitempty"`
	// Number of days after which an active Cart is deleted since its last modification. Configured in [Project settings](ctp:api:type:CartsConfiguration).
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
	// Present on resources updated after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
}

func (*Cart) UnmarshalJSON ¶

func (obj *Cart) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CartAddCustomLineItemAction ¶

type CartAddCustomLineItemAction struct {
	// Money value of the Custom Line Item.
	// The value can be negative.
	Money Money `json:"money"`
	// Name of the Custom Line Item.
	Name LocalizedString `json:"name"`
	// Number of Custom Line Items to add to the Cart.
	Quantity *int `json:"quantity,omitempty"`
	// User-defined identifier used in a deep-link URL for the Custom Line Item.
	// It must match the pattern `[a-zA-Z0-9_-]{2,256}`.
	Slug string `json:"slug"`
	// Used to select a Tax Rate when a Cart has the `Platform` [TaxMode](ctp:api:type:TaxMode).
	//
	// If [TaxMode](ctp:api:type:TaxMode) is `Platform`, this field must not be empty.
	TaxCategory *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
	// An external Tax Rate can be set if the Cart has `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	// Container for Custom Line Item-specific addresses.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
	// Custom Fields for the Custom Line Item.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// - If `Standard`, Cart Discounts with a matching [CartDiscountCustomLineItemsTarget](ctp:api:type:CartDiscountCustomLineItemsTarget)
	// are applied to the Custom Line Item.
	// - If `External`, Cart Discounts are not considered on the Custom Line Item.
	PriceMode *CustomLineItemPriceMode `json:"priceMode,omitempty"`
}

* * If the Cart already contains a CustomLineItem(ctp:api:type:CustomLineItem) with the same `slug`, `name`, `money`, `taxCategory`, `state`, * and Custom Fields, then only the quantity of the existing Custom Line Item is increased. * If CustomLineItem(ctp:api:type:CustomLineItem) `shippingDetails` are set, they are merged with the `targets` that already exist on the * ItemShippingDetails(ctp:api:type:ItemShippingDetails) of the Custom Line Item. * In case of overlapping address keys the ItemShippingTarget(ctp:api:type:ItemShippingTarget) `quantity` is summed up. * * If the Cart already contains a Custom Line Item with the same slug that is otherwise not identical, an [InvalidOperation](ctp:api:type:InvalidOperationError) error is returned. * * If the Tax Rate is not set, a [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError) error is returned. *

func (CartAddCustomLineItemAction) MarshalJSON ¶

func (obj CartAddCustomLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartAddCustomShippingMethodAction ¶

type CartAddCustomShippingMethodAction struct {
	// User-defined identifier for the custom Shipping Method that must be unique across the Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey string `json:"shippingKey"`
	// Name of the custom Shipping Method.
	ShippingMethodName string `json:"shippingMethodName"`
	// Determines the shipping rate and Tax Rate of the associated Line Items.
	ShippingAddress BaseAddress `json:"shippingAddress"`
	// Determines the shipping price.
	ShippingRate ShippingRateDraft `json:"shippingRate"`
	// Input used to select a [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	// The data type of this field depends on the `shippingRateInputType.type` configured in the [Project](ctp:api:type:Project):
	//
	// - If `CartClassification`, it must be [ClassificationShippingRateInputDraft](ctp:api:type:ClassificationShippingRateInputDraft).
	// - If `CartScore`, it must be [ScoreShippingRateInputDraft](ctp:api:type:ScoreShippingRateInputDraft).
	// - If `CartValue`, it cannot be set.
	ShippingRateInput ShippingRateInputDraft `json:"shippingRateInput,omitempty"`
	// Tax Category used to determine a shipping Tax Rate if the Cart has the `Platform` [TaxMode](ctp:api:type:TaxMode).
	TaxCategory *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
	// Tax Rate used to tax a shipping expense if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	// Deliveries to be shipped with the custom Shipping Method.
	Deliveries []DeliveryDraft `json:"deliveries"`
	// Custom Fields for the custom Shipping Method.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * To add a custom Shipping Method (independent of the [ShippingMethods](ctp:api:type:ShippingMethod) managed through * the [Shipping Methods API](/projects/shippingMethods)) to the Cart, it **must have** the `Multiple` ShippingMode(ctp:api:type:ShippingMode). *

func (CartAddCustomShippingMethodAction) MarshalJSON ¶

func (obj CartAddCustomShippingMethodAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CartAddCustomShippingMethodAction) UnmarshalJSON ¶

func (obj *CartAddCustomShippingMethodAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CartAddDiscountCodeAction ¶

type CartAddDiscountCodeAction struct {
	// `code` of a [DiscountCode](ctp:api:type:DiscountCode).
	Code string `json:"code"`
}

* * Adds a DiscountCode(ctp:api:type:DiscountCode) to the Cart to activate the related [Cart Discounts](/../api/projects/cartDiscounts). * Adding a Discount Code is only possible if no DirectDiscount(ctp:api:type:DirectDiscount) has been applied to the Cart. * Discount Codes can be added to [frozen Carts](ctp:api:type:FrozenCarts), but their DiscountCodeState(ctp:api:type:DiscountCodeState) is then `DoesNotMatchCart`. * * The maximum number of Discount Codes in a Cart is restricted by a [limit](/../api/limits#carts). * * Specific Error Code: [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) *

func (CartAddDiscountCodeAction) MarshalJSON ¶

func (obj CartAddDiscountCodeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartAddItemShippingAddressAction ¶

type CartAddItemShippingAddressAction struct {
	// Address to append to `itemShippingAddresses`.
	//
	// The new Address must have a `key` that is unique accross this Cart.
	Address BaseAddress `json:"address"`
}

* * Adds an address to a Cart when shipping to multiple addresses is desired. *

func (CartAddItemShippingAddressAction) MarshalJSON ¶

func (obj CartAddItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartAddLineItemAction ¶

type CartAddLineItemAction struct {
	// User-defined unique identifier of the LineItem.
	Key *string `json:"key,omitempty"`
	// `id` of the published [Product](ctp:api:type:Product).
	//
	// Either the `productId` and `variantId`, or `sku` must be provided.
	ProductId *string `json:"productId,omitempty"`
	// `id` of the [ProductVariant](ctp:api:type:ProductVariant) in the Product.
	// If not provided, the Master Variant is used.
	//
	// Either the `productId` and `variantId`, or `sku` must be provided.
	VariantId *int `json:"variantId,omitempty"`
	// SKU of the [ProductVariant](ctp:api:type:ProductVariant).
	//
	// Either the `productId` and `variantId`, or `sku` must be provided.
	Sku *string `json:"sku,omitempty"`
	// Quantity of the Product Variant to add to the Cart.
	Quantity *int `json:"quantity,omitempty"`
	// Date and time (UTC) the Product Variant is added to the Cart.
	// If not set, it defaults to the current date and time.
	//
	// Optional for backwards compatibility reasons.
	AddedAt *time.Time `json:"addedAt,omitempty"`
	// Used to [select](ctp:api:type:LineItemPriceSelection) a Product Price.
	// The Channel must have the `ProductDistribution` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	// If the Cart is bound to a [Store](ctp:api:type:Store) with `distributionChannels` set, the Channel must match one of the Store's distribution channels.
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
	// Used to identify [Inventory entries](/../api/projects/inventory) that must be reserved.
	// The Channel must have the `InventorySupply` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
	// Sets the [LineItem](ctp:api:type:LineItem) `price` value, and the `priceMode` to `ExternalPrice` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
	ExternalPrice *Money `json:"externalPrice,omitempty"`
	// Sets the [LineItem](ctp:api:type:LineItem) `price` and `totalPrice` values, and the `priceMode` to `ExternalTotal` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
	ExternalTotalPrice *ExternalLineItemTotalPrice `json:"externalTotalPrice,omitempty"`
	// External Tax Rate for the Line Item, if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	// Inventory mode specific to the Line Item only, and valid for the entire `quantity` of the Line Item.
	// Set only if the inventory mode should be different from the `inventoryMode` specified on the [Cart](ctp:api:type:Cart).
	InventoryMode *InventoryMode `json:"inventoryMode,omitempty"`
	// Container for Line Item-specific addresses.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
	// Custom Fields for the Line Item.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * If the Cart contains a LineItem(ctp:api:type:LineItem) for a Product Variant with the same LineItemMode(ctp:api:type:LineItemMode), [Custom Fields](/../api/projects/custom-fields), supply and distribution channel, then only the quantity of the existing Line Item is increased. * If LineItem(ctp:api:type:LineItem) `shippingDetails` is set, it is merged. All addresses will be present afterwards and, for address keys present in both shipping details, the quantity will be summed up. * A new Line Item is added when the `externalPrice` or `externalTotalPrice` is set in this update action. * The LineItem(ctp:api:type:LineItem) price is set as described in [LineItem Price selection](ctp:api:type:LineItemPriceSelection). * * If the Tax Rate is not set, a [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError) error is returned. * * If the Line Items do not have a Price according to the Product(ctp:api:type:Product) `priceMode` value for a selected currency and/or country, Customer Group, or Channel, a [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) error is returned. *

func (CartAddLineItemAction) MarshalJSON ¶

func (obj CartAddLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartAddPaymentAction ¶

type CartAddPaymentAction struct {
	// Payment to add to the Cart.
	// Must not be assigned to another Order or active Cart already.
	Payment PaymentResourceIdentifier `json:"payment"`
}

func (CartAddPaymentAction) MarshalJSON ¶

func (obj CartAddPaymentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartAddShippingMethodAction ¶

type CartAddShippingMethodAction struct {
	// User-defined identifier for the [Shipping](ctp:api:type:Shipping) that must be unique across the Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey string `json:"shippingKey"`
	// RecourceIdentifier to a [ShippingMethod](ctp:api:type:ShippingMethod) to add to the Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	// If the referenced Shipping Method has a predicate that does not match the Cart, an [InvalidOperation](ctp:api:type:InvalidOperationError) error is returned.
	ShippingMethod ShippingMethodResourceIdentifier `json:"shippingMethod"`
	// Determines the shipping rate and Tax Rate of the Line Items.
	ShippingAddress BaseAddress `json:"shippingAddress"`
	// Input used to select a [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	// The data type of this field depends on the `shippingRateInputType.type` configured in the [Project](ctp:api:type:Project):
	//
	// - If `CartClassification`, it must be [ClassificationShippingRateInputDraft](ctp:api:type:ClassificationShippingRateInputDraft).
	// - If `CartScore`, it must be [ScoreShippingRateInputDraft](ctp:api:type:ScoreShippingRateInputDraft).
	// - If `CartValue`, it cannot be set.
	ShippingRateInput ShippingRateInputDraft `json:"shippingRateInput,omitempty"`
	// Tax Rate used to tax a shipping expense if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	// Deliveries to be shipped with the referenced Shipping Method.
	Deliveries []DeliveryDraft `json:"deliveries"`
	// Custom Fields for the Shipping Method.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * Adds a Shipping Method for a specified shipping address to a Cart with `Multiple` ShippingMode(ctp:api:type:ShippingMode). *

func (CartAddShippingMethodAction) MarshalJSON ¶

func (obj CartAddShippingMethodAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CartAddShippingMethodAction) UnmarshalJSON ¶

func (obj *CartAddShippingMethodAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CartAddShoppingListAction ¶

type CartAddShoppingListAction struct {
	// Shopping List that contains the Line Items to be added.
	ShoppingList ShoppingListResourceIdentifier `json:"shoppingList"`
	// `distributionChannel` to set for all [LineItems](ctp:api:type:LineItem) that are added to the Cart.
	// The Channel must have the `ProductDistribution` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
	// `supplyChannel` to set for all [LineItems](ctp:api:type:LineItem) that are added to the Cart.
	// The Channel must have the `InventorySupply` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
}

* * Adds all [LineItems](ctp:api:type:LineItem) of a ShoppingList(ctp:api:type:ShoppingList) to the Cart. *

func (CartAddShoppingListAction) MarshalJSON ¶

func (obj CartAddShoppingListAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartApplyDeltaToCustomLineItemShippingDetailsTargetsAction ¶

type CartApplyDeltaToCustomLineItemShippingDetailsTargetsAction struct {
	// `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update.
	CustomLineItemId string `json:"customLineItemId"`
	// Using positive or negative quantities increases or decreases the number of items shipped to an address.
	TargetsDelta []ItemShippingTarget `json:"targetsDelta"`
}

func (CartApplyDeltaToCustomLineItemShippingDetailsTargetsAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartApplyDeltaToLineItemShippingDetailsTargetsAction ¶

type CartApplyDeltaToLineItemShippingDetailsTargetsAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Using positive or negative quantities increases or decreases the number of items shipped to an address.
	TargetsDelta []ItemShippingTarget `json:"targetsDelta"`
}

* * To override the shipping details, see [Set LineItemShippingDetails](ctp:api:type:CartSetLineItemShippingDetailsAction). *

func (CartApplyDeltaToLineItemShippingDetailsTargetsAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartChangeCustomLineItemMoneyAction ¶

type CartChangeCustomLineItemMoneyAction struct {
	// `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update.
	CustomLineItemId string `json:"customLineItemId"`
	// Value to set. Must not be empty. Can be a negative amount.
	Money Money `json:"money"`
}

func (CartChangeCustomLineItemMoneyAction) MarshalJSON ¶

func (obj CartChangeCustomLineItemMoneyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartChangeCustomLineItemPriceModeAction ¶

type CartChangeCustomLineItemPriceModeAction struct {
	// `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update.
	CustomLineItemId string `json:"customLineItemId"`
	// New value to set. Must not be empty.
	Mode CustomLineItemPriceMode `json:"mode"`
}

func (CartChangeCustomLineItemPriceModeAction) MarshalJSON ¶

func (obj CartChangeCustomLineItemPriceModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartChangeCustomLineItemQuantityAction ¶

type CartChangeCustomLineItemQuantityAction struct {
	// `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update.
	CustomLineItemId string `json:"customLineItemId"`
	// New value to set.
	//
	// If `0`, the Custom Line Item is removed from the Cart.
	Quantity int `json:"quantity"`
}

* * When multiple shipping addresses are set for a Custom Line Item, * use the [Add CustomLineItem](ctp:api:type:CartAddCustomLineItemAction) update action to change the shipping details. * Since it is not possible for the API to infer how the overall change in the Custom Line Item quantity should be distributed over the sub-quantities, * the `shippingDetails` field is kept in its current state to avoid data loss. * * To change the Custom Line Item quantity and shipping details together, * use this update action in combination with the [Set CustomLineItemShippingDetails](ctp:api:type:CartSetCustomLineItemShippingDetailsAction) update action * in a single Cart update command. *

func (CartChangeCustomLineItemQuantityAction) MarshalJSON ¶

func (obj CartChangeCustomLineItemQuantityAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartChangeLineItemQuantityAction ¶

type CartChangeLineItemQuantityAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// New value to set.
	//
	// If `0`, the Line Item is removed from the Cart.
	Quantity int `json:"quantity"`
	// Sets the [LineItem](ctp:api:type:LineItem) `price` to the given value when changing the quantity of a Line Item with the `ExternalPrice` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
	//
	// The LineItem price is updated as described in LineItem Price selection.
	ExternalPrice *Money `json:"externalPrice,omitempty"`
	// Sets the [LineItem](ctp:api:type:LineItem) `price` and `totalPrice` to the given value when changing the quantity of a Line Item with the `ExternalTotal` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
	ExternalTotalPrice *ExternalLineItemTotalPrice `json:"externalTotalPrice,omitempty"`
}

* * When multiple shipping addresses are set for a Line Item, * use the [Remove LineItem](ctp:api:type:CartRemoveLineItemAction) and [Add LineItem](ctp:api:type:CartAddLineItemAction) update action * to change the shipping details. * Since it is not possible for the API to infer how the overall change in the Line Item quantity should be distributed over the sub-quantities, * the `shippingDetails` field is kept in its current state to avoid data loss. * * To change the Line Item quantity and shipping details together, * use this update action in combination with the [Set LineItemShippingDetails](ctp:api:type:CartSetCustomLineItemShippingDetailsAction) update action * in a single Cart update command. * * The LineItem(ctp:api:type:LineItem) price is set as described in [LineItem Price selection](ctp:api:type:LineItemPriceSelection). *

func (CartChangeLineItemQuantityAction) MarshalJSON ¶

func (obj CartChangeLineItemQuantityAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartChangeTaxCalculationModeAction ¶

type CartChangeTaxCalculationModeAction struct {
	// New value to set.
	TaxCalculationMode TaxCalculationMode `json:"taxCalculationMode"`
}

* * Changing the tax calculation mode leads to [recalculation of taxes](/../api/carts-orders-overview#cart-tax-calculation). *

func (CartChangeTaxCalculationModeAction) MarshalJSON ¶

func (obj CartChangeTaxCalculationModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartChangeTaxModeAction ¶

type CartChangeTaxModeAction struct {
	// The new TaxMode.
	TaxMode TaxMode `json:"taxMode"`
}

* * - When `External` TaxMode(ctp:api:type:TaxMode) is changed to `Platform` or `Disabled`, all previously set external Tax Rates are removed. * - When set to `Platform`, Line Items, Custom Line Items, and Shipping Method require a Tax Category with a Tax Rate for the Cart's `shippingAddress`. *

func (CartChangeTaxModeAction) MarshalJSON ¶

func (obj CartChangeTaxModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartChangeTaxRoundingModeAction ¶

type CartChangeTaxRoundingModeAction struct {
	// New value to set.
	TaxRoundingMode RoundingMode `json:"taxRoundingMode"`
}

* * Changing the tax rounding mode leads to [recalculation of taxes](/../api/carts-orders-overview#cart-tax-calculation). *

func (CartChangeTaxRoundingModeAction) MarshalJSON ¶

func (obj CartChangeTaxRoundingModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartClassificationTier ¶

type CartClassificationTier struct {
	// `key` selected from the `values` of the [CartClassificationType](/projects/project#cartclassificationtype) configured in the Project.
	Value string `json:"value"`
	// Fixed shipping rate for the selected classification.
	Price Money `json:"price"`
	// Appears in response to [Get ShippingMethods for a Cart](ctp:api:endpoint:/{projectKey}/shipping-methods/matching-cart:GET) if the shipping rate matches the search query.
	IsMatching *bool `json:"isMatching,omitempty"`
}

* * Used when the ShippingRate maps to an abstract Cart categorization expressed by strings (for example, `Light`, `Medium`, or `Heavy`). *

func (CartClassificationTier) MarshalJSON ¶

func (obj CartClassificationTier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartClassificationType ¶

type CartClassificationType struct {
	// The classification items that can be used for specifying any [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	Values []CustomFieldLocalizedEnumValue `json:"values"`
}

* * Used when the ShippingRate maps to an abstract Cart categorization expressed by strings (for example, `Light`, `Medium`, or `Heavy`). * Only keys defined in the `values` array can be used to create a tier or to set a value of the `shippingRateInput` on the Cart(ctp:api:type:Cart). * Keys must be unique. *

func (CartClassificationType) MarshalJSON ¶

func (obj CartClassificationType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscount ¶

type CartDiscount struct {
	// Unique identifier of the CartDiscount.
	ID string `json:"id"`
	// Current version of the CartDiscount.
	Version int `json:"version"`
	// Date and time (UTC) for the CartDiscount was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) for the CartDiscount was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources updated after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Name of the CartDiscount.
	Name LocalizedString `json:"name"`
	// User-defined unique identifier of the CartDiscount.
	Key *string `json:"key,omitempty"`
	// Description of the CartDiscount.
	Description *LocalizedString `json:"description,omitempty"`
	// Effect of the CartDiscount.
	Value CartDiscountValue `json:"value"`
	// Valid [Cart Predicate](/../api/projects/predicates#cart-predicates).
	CartPredicate string `json:"cartPredicate"`
	// Sets a [CartDiscountTarget](ctp:api:type:CartDiscountTarget). Empty if `value` has type `giftLineItem`.
	Target CartDiscountTarget `json:"target,omitempty"`
	// Value between `0` and `1`.
	// All matching CartDiscounts are applied to a Cart in the order defined by this field.
	// A Discount with a higher sortOrder is prioritized.
	// The sort order is unambiguous among all CartDiscounts.
	SortOrder string `json:"sortOrder"`
	// Indicates if the CartDiscount is active and can be applied to the Cart.
	IsActive bool `json:"isActive"`
	// Date and time (UTC) from which the Discount is effective.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the Discount is effective.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Indicates if the Discount can be used in connection with a [DiscountCode](ctp:api:type:DiscountCode).
	RequiresDiscountCode bool `json:"requiresDiscountCode"`
	// References of all resources that are addressed in the predicate.
	// The API generates this array from the predicate.
	References []Reference `json:"references"`
	// Indicates whether the application of the CartDiscount causes other discounts to be ignored.
	StackingMode StackingMode `json:"stackingMode"`
	// Custom Fields of the CartDiscount.
	Custom *CustomFields `json:"custom,omitempty"`
}

func (*CartDiscount) UnmarshalJSON ¶

func (obj *CartDiscount) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CartDiscountChangeCartPredicateAction ¶

type CartDiscountChangeCartPredicateAction struct {
	// New value to set.
	CartPredicate string `json:"cartPredicate"`
}

func (CartDiscountChangeCartPredicateAction) MarshalJSON ¶

func (obj CartDiscountChangeCartPredicateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountChangeIsActiveAction ¶

type CartDiscountChangeIsActiveAction struct {
	// New value to set.
	// If set to `true`, the Discount will be applied to the Cart.
	IsActive bool `json:"isActive"`
}

func (CartDiscountChangeIsActiveAction) MarshalJSON ¶

func (obj CartDiscountChangeIsActiveAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountChangeNameAction ¶

type CartDiscountChangeNameAction struct {
	// New value to set.
	Name LocalizedString `json:"name"`
}

func (CartDiscountChangeNameAction) MarshalJSON ¶

func (obj CartDiscountChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountChangeRequiresDiscountCodeAction ¶

type CartDiscountChangeRequiresDiscountCodeAction struct {
	// New value to set.
	// If set to `true`, the Discount can only be used in connection with a [DiscountCode](ctp:api:type:DiscountCode).
	RequiresDiscountCode bool `json:"requiresDiscountCode"`
}

func (CartDiscountChangeRequiresDiscountCodeAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountChangeSortOrderAction ¶

type CartDiscountChangeSortOrderAction struct {
	// New value to set (between `0` and `1`).
	// A Discount with a higher sortOrder is prioritized.
	SortOrder string `json:"sortOrder"`
}

func (CartDiscountChangeSortOrderAction) MarshalJSON ¶

func (obj CartDiscountChangeSortOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountChangeStackingModeAction ¶

type CartDiscountChangeStackingModeAction struct {
	// New value to set.
	StackingMode StackingMode `json:"stackingMode"`
}

func (CartDiscountChangeStackingModeAction) MarshalJSON ¶

func (obj CartDiscountChangeStackingModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountChangeTargetAction ¶

type CartDiscountChangeTargetAction struct {
	// New value to set.
	Target CartDiscountTarget `json:"target"`
}

func (CartDiscountChangeTargetAction) MarshalJSON ¶

func (obj CartDiscountChangeTargetAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CartDiscountChangeTargetAction) UnmarshalJSON ¶

func (obj *CartDiscountChangeTargetAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CartDiscountChangeValueAction ¶

type CartDiscountChangeValueAction struct {
	// New value to set.
	Value CartDiscountValueDraft `json:"value"`
}

func (CartDiscountChangeValueAction) MarshalJSON ¶

func (obj CartDiscountChangeValueAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CartDiscountChangeValueAction) UnmarshalJSON ¶

func (obj *CartDiscountChangeValueAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CartDiscountCustomLineItemsTarget ¶

type CartDiscountCustomLineItemsTarget struct {
	// Valid [CustomLineItem target predicate](/../api/projects/predicates#customlineitem-field-identifiers).
	Predicate string `json:"predicate"`
}

* * Discount is applied to [CustomLineItems](ctp:api:type:CustomLineItem) matching the `predicate`. *

func (CartDiscountCustomLineItemsTarget) MarshalJSON ¶

func (obj CartDiscountCustomLineItemsTarget) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountDraft ¶

type CartDiscountDraft struct {
	// Name of the CartDiscount.
	Name LocalizedString `json:"name"`
	// User-defined unique identifier for the CartDiscount.
	Key *string `json:"key,omitempty"`
	// Description of the CartDiscount.
	Description *LocalizedString `json:"description,omitempty"`
	// Effect of the CartDiscount.
	// For a [target](ctp:api:type:CartDiscountTarget), relative or absolute Discount values or a fixed item Price value can be specified. If no target is specified, a [Gift Line Item](/../api/projects/cartDiscounts#gift-line-item) can be added to the Cart.
	Value CartDiscountValueDraft `json:"value"`
	// Valid [Cart Predicate](/../api/projects/predicates#cart-predicates).
	CartPredicate string `json:"cartPredicate"`
	// Must not be set when the `value` has type `giftLineItem`, otherwise a [CartDiscountTarget](ctp:api:type:CartDiscountTarget) must be set.
	Target CartDiscountTarget `json:"target,omitempty"`
	// Value between `0` and `1`.
	// A Discount with a higher sortOrder is prioritized.
	// The sort order must be unambiguous among all CartDiscounts.
	SortOrder string `json:"sortOrder"`
	// Only active Discounts can be applied to the Cart.
	IsActive *bool `json:"isActive,omitempty"`
	// Date and time (UTC) from which the Discount is effective.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the Discount is effective.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// States whether the Discount can only be used in a connection with a [DiscountCode](ctp:api:type:DiscountCode).
	RequiresDiscountCode *bool `json:"requiresDiscountCode,omitempty"`
	// Specifies whether the application of this discount causes the following discounts to be ignored.
	StackingMode *StackingMode `json:"stackingMode,omitempty"`
	// Custom Fields of the CartDiscount.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (*CartDiscountDraft) UnmarshalJSON ¶

func (obj *CartDiscountDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CartDiscountLineItemsTarget ¶

type CartDiscountLineItemsTarget struct {
	// Valid [LineItem target predicate](/../api/projects/predicates#lineitem-field-identifiers).
	Predicate string `json:"predicate"`
}

* * Discount is applied to [LineItems](ctp:api:type:LineItem) matching the `predicate`. *

func (CartDiscountLineItemsTarget) MarshalJSON ¶

func (obj CartDiscountLineItemsTarget) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountPagedQueryResponse ¶

type CartDiscountPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [CartDiscounts](ctp:api:type:CartDiscount) matching the query.
	Results []CartDiscount `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of CartDiscount(ctp:api:type:CartDiscount). *

type CartDiscountReference ¶

type CartDiscountReference struct {
	// Unique identifier of the referenced [CartDiscount](ctp:api:type:CartDiscount).
	ID string `json:"id"`
	// Contains the representation of the expanded CartDiscount. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for CartDiscounts.
	Obj *CartDiscount `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a CartDiscount(ctp:api:type:CartDiscount). *

func (CartDiscountReference) MarshalJSON ¶

func (obj CartDiscountReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountResourceIdentifier ¶

type CartDiscountResourceIdentifier struct {
	// Unique identifier of the referenced [CartDiscount](ctp:api:type:CartDiscount). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [CartDiscount](ctp:api:type:CartDiscount). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a CartDiscount(ctp:api:type:CartDiscount). *

func (CartDiscountResourceIdentifier) MarshalJSON ¶

func (obj CartDiscountResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountSetCustomFieldAction ¶

type CartDiscountSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CartDiscountSetCustomFieldAction) MarshalJSON ¶

func (obj CartDiscountSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountSetCustomTypeAction ¶

type CartDiscountSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the CartDiscount with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the CartDiscount.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the CartDiscount.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CartDiscountSetCustomTypeAction) MarshalJSON ¶

func (obj CartDiscountSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountSetDescriptionAction ¶

type CartDiscountSetDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

func (CartDiscountSetDescriptionAction) MarshalJSON ¶

func (obj CartDiscountSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountSetKeyAction ¶

type CartDiscountSetKeyAction struct {
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

func (CartDiscountSetKeyAction) MarshalJSON ¶

func (obj CartDiscountSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountSetValidFromAction ¶

type CartDiscountSetValidFromAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
}

func (CartDiscountSetValidFromAction) MarshalJSON ¶

func (obj CartDiscountSetValidFromAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountSetValidFromAndUntilAction ¶

type CartDiscountSetValidFromAndUntilAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Value to set.
	// If empty, any existing value will be removed.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

func (CartDiscountSetValidFromAndUntilAction) MarshalJSON ¶

func (obj CartDiscountSetValidFromAndUntilAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountSetValidUntilAction ¶

type CartDiscountSetValidUntilAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

func (CartDiscountSetValidUntilAction) MarshalJSON ¶

func (obj CartDiscountSetValidUntilAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountShippingCostTarget ¶

type CartDiscountShippingCostTarget struct {
}

* * Discount is applied to the shipping costs of the Cart(ctp:api:type:Cart). *

func (CartDiscountShippingCostTarget) MarshalJSON ¶

func (obj CartDiscountShippingCostTarget) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountTarget ¶

type CartDiscountTarget interface{}

type CartDiscountUpdate ¶

type CartDiscountUpdate struct {
	// Expected version of the CartDiscount on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the CartDiscount.
	Actions []CartDiscountUpdateAction `json:"actions"`
}

func (*CartDiscountUpdate) UnmarshalJSON ¶

func (obj *CartDiscountUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CartDiscountUpdateAction ¶

type CartDiscountUpdateAction interface{}

type CartDiscountValue ¶

type CartDiscountValue interface{}

type CartDiscountValueAbsolute ¶

type CartDiscountValueAbsolute struct {
	// Cent precision money values in different currencies.
	Money []CentPrecisionMoney `json:"money"`
}

* * Discounts the CartDiscountTarget(ctp:api:type:CartDiscountTarget) by an absolute amount (not allowed for MultiBuyLineItemsTarget(ctp:api:type:MultiBuyLineItemsTarget) and MultiBuyCustomLineItemsTarget(ctp:api:type:MultiBuyCustomLineItemsTarget)). *

func (CartDiscountValueAbsolute) MarshalJSON ¶

func (obj CartDiscountValueAbsolute) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountValueAbsoluteDraft ¶

type CartDiscountValueAbsoluteDraft struct {
	// Money values in different currencies.
	// An absolute Cart Discount will only match a price if this array contains a value with the same currency. If it contains 10€ and 15$, the matching € price will be decreased by 10€ and the matching $ price will be decreased by 15$.
	Money []Money `json:"money"`
}

func (CartDiscountValueAbsoluteDraft) MarshalJSON ¶

func (obj CartDiscountValueAbsoluteDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountValueDraft ¶

type CartDiscountValueDraft interface{}

type CartDiscountValueFixed ¶

type CartDiscountValueFixed struct {
	// Cent precision money values in different currencies.
	Money []CentPrecisionMoney `json:"money"`
}

* * Sets the DiscountedLineItemPrice(ctp:api:type:DiscountedLineItemPrice) of the CartDiscountLineItemsTarget(ctp:api:type:CartDiscountLineItemsTarget) or CartDiscountCustomLineItemsTarget(ctp:api:type:CartDiscountCustomLineItemsTarget) to the value specified in the `money` field, if it is lower than the current Line Item price for the same currency. If the Line Item price is already discounted to a price equal to or lower than the respective price in the `money` field, this Discount is not applied. *

func (CartDiscountValueFixed) MarshalJSON ¶

func (obj CartDiscountValueFixed) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountValueFixedDraft ¶

type CartDiscountValueFixedDraft struct {
	// Money values in different currencies.
	// A fixed Cart Discount will only match a price if this array contains a value with the same currency. If it contains 10€ and 15$, the matching € price will be discounted by 10€ and the matching $ price will be discounted to 15$.
	Money []Money `json:"money"`
}

* * Sets the DiscountedLineItemPrice(ctp:api:type:DiscountedLineItemPrice) of the CartDiscountLineItemsTarget(ctp:api:type:CartDiscountLineItemsTarget) or CartDiscountCustomLineItemsTarget(ctp:api:type:CartDiscountCustomLineItemsTarget) to the value specified in the `money` field, if it is lower than the current Line Item price for the same currency. If the Line Item price is already discounted to a price equal to or lower than the respective price in the `money` field, this Discount is not applied. *

func (CartDiscountValueFixedDraft) MarshalJSON ¶

func (obj CartDiscountValueFixedDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountValueGiftLineItem ¶

type CartDiscountValueGiftLineItem struct {
	// Reference to a Product.
	Product ProductReference `json:"product"`
	// [ProductVariant](ctp:api:type:ProductVariant) of the Product.
	VariantId int `json:"variantId"`
	// Channel must have the [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum) `InventorySupply`.
	SupplyChannel *ChannelReference `json:"supplyChannel,omitempty"`
	// Channel must have the [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum) `ProductDistribution`.
	DistributionChannel *ChannelReference `json:"distributionChannel,omitempty"`
}

func (CartDiscountValueGiftLineItem) MarshalJSON ¶

func (obj CartDiscountValueGiftLineItem) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountValueGiftLineItemDraft ¶

type CartDiscountValueGiftLineItemDraft struct {
	// ResourceIdentifier of a Product.
	Product ProductResourceIdentifier `json:"product"`
	// [ProductVariant](ctp:api:type:ProductVariant) of the Product.
	VariantId int `json:"variantId"`
	// Channel must have the role `InventorySupply`.
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
	// Channel must have the role `ProductDistribution`.
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
}

func (CartDiscountValueGiftLineItemDraft) MarshalJSON ¶

func (obj CartDiscountValueGiftLineItemDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountValueRelative ¶

type CartDiscountValueRelative struct {
	// Fraction (per ten thousand) the price is reduced by. For example, `1000` will result in a 10% price reduction.
	Permyriad int `json:"permyriad"`
}

* * Discounts the CartDiscountTarget(ctp:api:type:CartDiscountTarget) relative to its price. *

func (CartDiscountValueRelative) MarshalJSON ¶

func (obj CartDiscountValueRelative) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDiscountValueRelativeDraft ¶

type CartDiscountValueRelativeDraft struct {
	// Fraction (per ten thousand) the price is reduced by. For example, `1000` will result in a 10% price reduction.
	Permyriad int `json:"permyriad"`
}

func (CartDiscountValueRelativeDraft) MarshalJSON ¶

func (obj CartDiscountValueRelativeDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartDraft ¶

type CartDraft struct {
	// Currency the Cart uses.
	Currency string `json:"currency"`
	// User-defined unique identifier for the Cart.
	Key *string `json:"key,omitempty"`
	// `id` of the [Customer](ctp:api:type:Customer) that the Cart belongs to.
	CustomerId *string `json:"customerId,omitempty"`
	// Email address of the Customer that the Cart belongs to.
	CustomerEmail *string `json:"customerEmail,omitempty"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to the Customer Group of the Customer that the Cart belongs to. Used for [LineItem Price selection](ctp:api:type:LineItemPriceSelection).
	//
	// It is automatically set if the Customer referenced in `customerId` belongs to a Customer Group.
	// It can also be set explicitly when no `customerId` is present.
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
	// [Anonymous session](ctp:api:type:AnonymousSession) associated with the Cart.
	AnonymousId *string `json:"anonymousId,omitempty"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to the Business Unit the Cart should belong to. When the `customerId` of the Cart is also set, the [Customer](ctp:api:type:Customer) must be an [Associate](ctp:api:type:Associate) of the Business Unit.
	BusinessUnit *BusinessUnitResourceIdentifier `json:"businessUnit,omitempty"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to the Store the Cart should belong to. Once set, it cannot be updated.
	Store *StoreResourceIdentifier `json:"store,omitempty"`
	// [Line Items](ctp:api:type:LineItems) to add to the Cart.
	LineItems []LineItemDraft `json:"lineItems"`
	// [Custom Line Items](ctp:api:type:CustomLineItems) to add to the Cart.
	CustomLineItems []CustomLineItemDraft `json:"customLineItems"`
	// Determines how Tax Rates are set.
	TaxMode *TaxMode `json:"taxMode,omitempty"`
	// External Tax Rate for the `shippingMethod` if the Cart has `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRateForShippingMethod *ExternalTaxRateDraft `json:"externalTaxRateForShippingMethod,omitempty"`
	// Determines how monetary values are rounded when calculating taxes for `taxedPrice`.
	TaxRoundingMode *RoundingMode `json:"taxRoundingMode,omitempty"`
	// Determines how taxes are calculated when calculating taxes for `taxedPrice`.
	TaxCalculationMode *TaxCalculationMode `json:"taxCalculationMode,omitempty"`
	// Determines how stock quantities are tracked for Line Items in the Cart.
	InventoryMode *InventoryMode `json:"inventoryMode,omitempty"`
	// Billing address associated with the Cart.
	BillingAddress *BaseAddress `json:"billingAddress,omitempty"`
	// Shipping address associated with the Cart. Determines eligible [ShippingMethod](ctp:api:type:ShippingMethod) rates and Tax Rates of Line Items.
	ShippingAddress *BaseAddress `json:"shippingAddress,omitempty"`
	// Shipping Method for a Cart with `Single` [ShippingMode](ctp:api:type:ShippingMode). If the referenced [ShippingMethod](ctp:api:type:ShippingMethod) has a `predicate` that does not match the Cart, an [InvalidOperation](ctp:api:type:InvalidOperationError) error is returned when [creating a Cart](ctp:api:endpoint:/{projectKey}/carts:POST).
	ShippingMethod *ShippingMethodResourceIdentifier `json:"shippingMethod,omitempty"`
	// Used as an input to select a [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	// The data type of this field depends on the `shippingRateInputType.type` configured in the [Project](ctp:api:type:Project):
	//
	// - If `CartClassification`, it must be [ClassificationShippingRateInputDraft](ctp:api:type:ClassificationShippingRateInputDraft).
	// - If `CartScore`, it must be [ScoreShippingRateInputDraft](ctp:api:type:ScoreShippingRateInputDraft).
	// - If `CartValue`, it cannot be set.
	ShippingRateInput ShippingRateInputDraft `json:"shippingRateInput,omitempty"`
	// - If set to `Single`, only a single Shipping Method can be added to the Cart.
	// - If set to `Multiple`, multiple Shipping Methods can be added to the Cart.
	ShippingMode *ShippingMode `json:"shippingMode,omitempty"`
	// Custom Shipping Methods for a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	CustomShipping []CustomShippingDraft `json:"customShipping"`
	// Shipping Methods for a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	Shipping []ShippingDraft `json:"shipping"`
	// Multiple shipping addresses of the Cart. Each address must contain a `key` that is unique in this Cart.
	// The keys are used by [LineItems](ctp:api:type:LineItem) to reference these addresses under their `shippingDetails`.
	//
	// Eligible Shipping Methods or applicable Tax Rates are determined by the address `shippingAddress`, and not `itemShippingAddresses`.
	ItemShippingAddresses []BaseAddress `json:"itemShippingAddresses"`
	// `code` of the existing [DiscountCodes](ctp:api:type:DiscountCode) to add to the Cart.
	DiscountCodes []string `json:"discountCodes"`
	// Used for [LineItem Price selection](ctp:api:type:LineItemPriceSelection).
	// If used for [Create Cart in Store](ctp:api:endpoint:/{projectKey}/in-store/carts:POST), the provided country must be one of the [Store's](ctp:api:type:Store) `countries`.
	Country *string `json:"country,omitempty"`
	// Languages of the Cart. Can only contain languages supported by the [Project](ctp:api:type:Project).
	Locale *string `json:"locale,omitempty"`
	// Indicates how the Cart was created.
	Origin *CartOrigin `json:"origin,omitempty"`
	// Number of days after which an active Cart is deleted since its last modification.
	// If not provided, the default value for this field configured in [Project settings](ctp:api:type:CartsConfiguration) is assigned.
	//
	// Create a [ChangeSubscription](ctp:api:type:ChangeSubscription) for Carts to receive a [ResourceDeletedDeliveryPayload](ctp:api:type:ResourceDeletedDeliveryPayload) upon deletion of the Cart.
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
	// Custom Fields for the Cart.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (CartDraft) MarshalJSON ¶

func (obj CartDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CartDraft) UnmarshalJSON ¶

func (obj *CartDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CartFreezeCartAction ¶

type CartFreezeCartAction struct {
}

* * Changes the CartState(ctp:api:type:CartState) from `Active` to `Frozen`. Results in a [Frozen Cart](ctp:api:type:FrozenCarts). * Fails with [InvalidOperation](ctp:api:type:InvalidOperation) error when the Cart is empty. *

func (CartFreezeCartAction) MarshalJSON ¶

func (obj CartFreezeCartAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartOrigin ¶

type CartOrigin string

* * Indicates who created the Cart. *

const (
	CartOriginCustomer CartOrigin = "Customer"
	CartOriginMerchant CartOrigin = "Merchant"
	CartOriginQuote    CartOrigin = "Quote"
)

type CartPagedQueryResponse ¶

type CartPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [Carts](ctp:api:type:Cart) matching the query.
	Results []Cart `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of Cart(ctp:api:type:Cart). *

type CartRecalculateAction ¶

type CartRecalculateAction struct {
	// - Leave empty or set to `false` to only update the Prices and TaxRates of the Line Items.
	// - Set to `true` to update the Line Items' product data (like `name`, `variant` and `productType`) also.
	UpdateProductData *bool `json:"updateProductData,omitempty"`
}

* * This update action does not set any Cart field in particular, but it triggers several [Cart updates](/../api/carts-orders-overview#cart-updates) * to bring prices and discounts to the latest state. Those can become stale over time when no Cart updates have been performed for a while and * prices on related Products have changed in the meanwhile. * * If the `priceMode` of the Product(ctp:api:type:Product) related to a Line Item is of `Embedded` [ProductPriceMode](ctp:api:type:ProductPriceModeEnum), * the updated `price` of that LineItem(ctp:api:type:LineItem) may not correspond to a Price in the `variant.prices` anymore. *

func (CartRecalculateAction) MarshalJSON ¶

func (obj CartRecalculateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartReference ¶

type CartReference struct {
	// Unique identifier of the referenced [Cart](ctp:api:type:Cart).
	ID string `json:"id"`
	// Contains the representation of the expanded Cart. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for Carts.
	Obj *Cart `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a Cart(ctp:api:type:Cart). *

func (CartReference) MarshalJSON ¶

func (obj CartReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartRemoveCustomLineItemAction ¶

type CartRemoveCustomLineItemAction struct {
	// `id` of the Custom Line Item to remove.
	CustomLineItemId string `json:"customLineItemId"`
}

* * This update action does not support specifying quantities, unlike the [Remove LineItem](ctp:api:type:CartRemoveLineItemAction) update action. * * If `shippingDetails` must be partially removed, use the [Change CustomLineItem Quantity](ctp:api:type:CartChangeCustomLineItemQuantityAction) update action. *

func (CartRemoveCustomLineItemAction) MarshalJSON ¶

func (obj CartRemoveCustomLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartRemoveDiscountCodeAction ¶

type CartRemoveDiscountCodeAction struct {
	// Discount Code to remove from the Cart.
	DiscountCode DiscountCodeReference `json:"discountCode"`
}

func (CartRemoveDiscountCodeAction) MarshalJSON ¶

func (obj CartRemoveDiscountCodeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartRemoveItemShippingAddressAction ¶

type CartRemoveItemShippingAddressAction struct {
	// `key` of the Address to remove from `itemShippingAddresses`.
	AddressKey string `json:"addressKey"`
}

* * An address can only be removed if it is not referenced in any ItemShippingTarget(ctp:api:type:ItemShippingTarget) of the Cart. *

func (CartRemoveItemShippingAddressAction) MarshalJSON ¶

func (obj CartRemoveItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartRemoveLineItemAction ¶

type CartRemoveLineItemAction struct {
	// `id` of the Line Item to remove.
	LineItemId string `json:"lineItemId"`
	// New value to set.
	// If absent or `0`, the Line Item is removed from the Cart.
	Quantity *int `json:"quantity,omitempty"`
	// Sets the [LineItem](ctp:api:type:LineItem) `price` to the given value when decreasing the quantity of a Line Item with the `ExternalPrice` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
	ExternalPrice *Money `json:"externalPrice,omitempty"`
	// Sets the [LineItem](ctp:api:type:LineItem) `price` and `totalPrice` to the given value when decreasing the quantity of a Line Item with the `ExternalTotal` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
	ExternalTotalPrice *ExternalLineItemTotalPrice `json:"externalTotalPrice,omitempty"`
	// Container for Line Item-specific addresses to remove.
	ShippingDetailsToRemove *ItemShippingDetailsDraft `json:"shippingDetailsToRemove,omitempty"`
}

* * The LineItem(ctp:api:type:LineItem) price is updated as described in [LineItem Price selection](ctp:api:type:LineItemPriceSelection). *

func (CartRemoveLineItemAction) MarshalJSON ¶

func (obj CartRemoveLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartRemovePaymentAction ¶

type CartRemovePaymentAction struct {
	// Payment to remove from the Cart.
	Payment PaymentResourceIdentifier `json:"payment"`
}

func (CartRemovePaymentAction) MarshalJSON ¶

func (obj CartRemovePaymentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartRemoveShippingMethodAction ¶

type CartRemoveShippingMethodAction struct {
	// User-defined unique identifier of the Shipping Method to remove from the Cart.
	ShippingKey string `json:"shippingKey"`
}

* * Removes a Shipping Method from a Cart that has the `Multiple` ShippingMode(ctp:api:type:ShippingMode). *

func (CartRemoveShippingMethodAction) MarshalJSON ¶

func (obj CartRemoveShippingMethodAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartResourceIdentifier ¶

type CartResourceIdentifier struct {
	// Unique identifier of the referenced [Cart](ctp:api:type:Cart). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [Cart](ctp:api:type:Cart). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a Cart(ctp:api:type:Cart). *

func (CartResourceIdentifier) MarshalJSON ¶

func (obj CartResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartScoreTier ¶

type CartScoreTier struct {
	// Abstract value for categorizing a Cart. The range starts at `0`. The default price covers `0`, tiers start at `1`. See [Using Tiered Shipping Rates](/../tutorials/shipping-rate) for details and examples.
	Score int `json:"score"`
	// Defines a fixed price for the `score`.
	Price *Money `json:"price,omitempty"`
	// Dynamically calculates a Price for a range of scores.
	PriceFunction *PriceFunction `json:"priceFunction,omitempty"`
	// Appears in response to [Get ShippingMethods for a Cart](ctp:api:endpoint:/{projectKey}/shipping-methods/matching-cart:GET) if the shipping rate matches the search query.
	IsMatching *bool `json:"isMatching,omitempty"`
}

* * Used when the ShippingRate maps to an abstract Cart categorization expressed by integers (such as shipping scores or weight ranges). * Either `price` or `priceFunction` is required. *

func (CartScoreTier) MarshalJSON ¶

func (obj CartScoreTier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartScoreType ¶

type CartScoreType struct {
}

* * Used when the ShippingRate maps to an abstract Cart categorization expressed by integers (such as shipping scores or weight ranges). *

func (CartScoreType) MarshalJSON ¶

func (obj CartScoreType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetAnonymousIdAction ¶

type CartSetAnonymousIdAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	AnonymousId *string `json:"anonymousId,omitempty"`
}

func (CartSetAnonymousIdAction) MarshalJSON ¶

func (obj CartSetAnonymousIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetBillingAddressAction ¶

type CartSetBillingAddressAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	Address *BaseAddress `json:"address,omitempty"`
}

func (CartSetBillingAddressAction) MarshalJSON ¶

func (obj CartSetBillingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetBillingAddressCustomFieldAction ¶

type CartSetBillingAddressCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CartSetBillingAddressCustomFieldAction) MarshalJSON ¶

func (obj CartSetBillingAddressCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetBillingAddressCustomTypeAction ¶

type CartSetBillingAddressCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the `billingAddress` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `billingAddress`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `billingAddress`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CartSetBillingAddressCustomTypeAction) MarshalJSON ¶

func (obj CartSetBillingAddressCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetBusinessUnitAction ¶

type CartSetBusinessUnitAction struct {
	// New Business Unit to assign to the Cart, which must have access to the [Store](/../api/projects/stores) that is set on the Cart.
	BusinessUnit BusinessUnitResourceIdentifier `json:"businessUnit"`
}

* * Updates the Business Unit on the Cart. The Cart must have an existing Business Unit assigned already. *

func (CartSetBusinessUnitAction) MarshalJSON ¶

func (obj CartSetBusinessUnitAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCartTotalTaxAction ¶

type CartSetCartTotalTaxAction struct {
	// The Cart's total gross price becoming the `totalGross` field (`totalNet` + taxes) on the Cart's `taxedPrice`.
	ExternalTotalGross Money `json:"externalTotalGross"`
	// Set if the `externalTotalGross` price is a sum of portions with different tax rates.
	ExternalTaxPortions []TaxPortionDraft `json:"externalTaxPortions"`
}

* * This update action results in the `taxedPrice` field being added to the Cart when the `ExternalAmount` TaxMode(ctp:api:type:TaxMode) is used. *

func (CartSetCartTotalTaxAction) MarshalJSON ¶

func (obj CartSetCartTotalTaxAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCountryAction ¶

type CartSetCountryAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	//
	// If the Cart is bound to a `store`, the provided value must be included in the [Store's](ctp:api:type:Store) `countries`.
	// Otherwise a [CountryNotConfiguredInStore](ctp:api:type:CountryNotConfiguredInStoreError) error is returned.
	Country *string `json:"country,omitempty"`
}

* * Setting the country can lead to changes in the LineItem(ctp:api:type:LineItem) prices. *

func (CartSetCountryAction) MarshalJSON ¶

func (obj CartSetCountryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCustomFieldAction ¶

type CartSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CartSetCustomFieldAction) MarshalJSON ¶

func (obj CartSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCustomLineItemCustomFieldAction ¶

type CartSetCustomLineItemCustomFieldAction struct {
	// `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update.
	CustomLineItemId string `json:"customLineItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CartSetCustomLineItemCustomFieldAction) MarshalJSON ¶

func (obj CartSetCustomLineItemCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCustomLineItemCustomTypeAction ¶

type CartSetCustomLineItemCustomTypeAction struct {
	// `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update.
	CustomLineItemId string `json:"customLineItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the CustomLineItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the CustomLineItem.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the CustomLineItem.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CartSetCustomLineItemCustomTypeAction) MarshalJSON ¶

func (obj CartSetCustomLineItemCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCustomLineItemShippingDetailsAction ¶

type CartSetCustomLineItemShippingDetailsAction struct {
	// `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update.
	CustomLineItemId string `json:"customLineItemId"`
	// Value to set.
	// If empty, any existing value is removed.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
}

func (CartSetCustomLineItemShippingDetailsAction) MarshalJSON ¶

func (obj CartSetCustomLineItemShippingDetailsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCustomLineItemTaxAmountAction ¶

type CartSetCustomLineItemTaxAmountAction struct {
	// `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update.
	CustomLineItemId string `json:"customLineItemId"`
	// Value to set.
	// If empty, any existing value is removed.
	ExternalTaxAmount *ExternalTaxAmountDraft `json:"externalTaxAmount,omitempty"`
}

* * Can be used if the Cart has the `ExternalAmount` TaxMode(ctp:api:type:TaxMode). *

func (CartSetCustomLineItemTaxAmountAction) MarshalJSON ¶

func (obj CartSetCustomLineItemTaxAmountAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCustomLineItemTaxRateAction ¶

type CartSetCustomLineItemTaxRateAction struct {
	// `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update.
	CustomLineItemId string `json:"customLineItemId"`
	// Value to set.
	// If empty, an existing value is removed.
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
}

* * Can be used if the Cart has the `External` TaxMode(ctp:api:type:TaxMode). *

func (CartSetCustomLineItemTaxRateAction) MarshalJSON ¶

func (obj CartSetCustomLineItemTaxRateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCustomShippingMethodAction ¶

type CartSetCustomShippingMethodAction struct {
	// Name of the custom Shipping Method.
	ShippingMethodName string `json:"shippingMethodName"`
	// Determines the shipping price.
	ShippingRate ShippingRateDraft `json:"shippingRate"`
	// Tax Category used to determine the Tax Rate when the Cart has the `Platform` [TaxMode](ctp:api:type:TaxMode).
	TaxCategory *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
	// External Tax Rate for the `shippingRate` to be set if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
}

* * To set the Cart's custom Shipping Method (independent of the [ShippingMethods](ctp:api:type:ShippingMethod) managed through * the [Shipping Methods API](/projects/shippingMethods)) the Cart must have * the `Single` ShippingMode(ctp:api:type:ShippingMode) and a `shippingAddress`. * * To unset a custom Shipping Method on a Cart, use the [Set ShippingMethod](ctp:api:type:CartSetShippingMethodAction) update action * without the `shippingMethod` field instead. *

func (CartSetCustomShippingMethodAction) MarshalJSON ¶

func (obj CartSetCustomShippingMethodAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCustomTypeAction ¶

type CartSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the Cart with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Cart.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Cart.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CartSetCustomTypeAction) MarshalJSON ¶

func (obj CartSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCustomerEmailAction ¶

type CartSetCustomerEmailAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	Email *string `json:"email,omitempty"`
}

func (CartSetCustomerEmailAction) MarshalJSON ¶

func (obj CartSetCustomerEmailAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCustomerGroupAction ¶

type CartSetCustomerGroupAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
}

* * This update action can only be used if a Customer is not assigned to a Cart. * If a Customer is already assigned, the Cart has the same Customer Group as the assigned Customer. * * Setting the Customer Group also updates the LineItem(ctp:api:type:LineItem) `prices` according to the Customer Group. *

func (CartSetCustomerGroupAction) MarshalJSON ¶

func (obj CartSetCustomerGroupAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetCustomerIdAction ¶

type CartSetCustomerIdAction struct {
	// `id` of an existing [Customer](ctp:api:type:Customer). If empty, any value is removed.
	CustomerId *string `json:"customerId,omitempty"`
}

* * Setting the Cart's `customerId` can lead to updates on all its LineItem(ctp:api:type:LineItem) `prices`. * * If the Customer with the specified `id` cannot be found, this update action returns a * [ReferencedResourceNotFound](ctp:api:type:ReferencedResourceNotFoundError) error. *

func (CartSetCustomerIdAction) MarshalJSON ¶

func (obj CartSetCustomerIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetDeleteDaysAfterLastModificationAction ¶

type CartSetDeleteDaysAfterLastModificationAction struct {
	// Value to set.
	// If not provided, the default value for this field configured in [Project settings](ctp:api:type:CartsConfiguration) is assigned.
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
}

* * Number of days after which a Cart with `Active` CartState(ctp:api:type:CartState) is deleted since its last modification. * * If a ChangeSubscription(ctp:api:type:ChangeSubscription) exists for Carts, a ResourceDeletedDeliveryPayload(ctp:api:type:ResourceDeletedDeliveryPayload) is sent. *

func (CartSetDeleteDaysAfterLastModificationAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetDeliveryAddressCustomFieldAction ¶

type CartSetDeliveryAddressCustomFieldAction struct {
	// `id` of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CartSetDeliveryAddressCustomFieldAction) MarshalJSON ¶

func (obj CartSetDeliveryAddressCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetDeliveryAddressCustomTypeAction ¶

type CartSetDeliveryAddressCustomTypeAction struct {
	// `id` of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// Defines the [Type](ctp:api:type:Type) that extends the [Delivery](ctp:api:type:Delivery) `address` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the [Delivery](ctp:api:type:Delivery) `address`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the [Delivery](ctp:api:type:Delivery) `address`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CartSetDeliveryAddressCustomTypeAction) MarshalJSON ¶

func (obj CartSetDeliveryAddressCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetDirectDiscountsAction ¶

type CartSetDirectDiscountsAction struct {
	// - If set, all existing Direct Discounts are replaced.
	//   The discounts apply in the order they are added to the list.
	// - If empty, all existing Direct Discounts are removed and all affected prices on the Cart or Order are recalculated.
	Discounts []DirectDiscountDraft `json:"discounts"`
}

* * Adds a DirectDiscount(ctp:api:type:DirectDiscount), but only if no DiscountCode(ctp:api:type:DiscountCode) has been added to the Cart. * Either a Discount Code or a Direct Discount can exist on a Cart at the same time. *

func (CartSetDirectDiscountsAction) MarshalJSON ¶

func (obj CartSetDirectDiscountsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetItemShippingAddressCustomFieldAction ¶

type CartSetItemShippingAddressCustomFieldAction struct {
	// `key` of the [Address](ctp:api:type:Address) in `itemShippingAddress`.
	AddressKey string `json:"addressKey"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CartSetItemShippingAddressCustomFieldAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetItemShippingAddressCustomTypeAction ¶

type CartSetItemShippingAddressCustomTypeAction struct {
	// `key` of the [Address](ctp:api:type:Address) in `itemShippingAddress`.
	AddressKey string `json:"addressKey"`
	// Defines the [Type](ctp:api:type:Type) that extends the `itemShippingAddress` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `itemShippingAddress`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `itemShippingAddress`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CartSetItemShippingAddressCustomTypeAction) MarshalJSON ¶

func (obj CartSetItemShippingAddressCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetKeyAction ¶

type CartSetKeyAction struct {
	// Value to set.
	// If empty, any existing key will be removed.
	Key *string `json:"key,omitempty"`
}

func (CartSetKeyAction) MarshalJSON ¶

func (obj CartSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetLineItemCustomFieldAction ¶

type CartSetLineItemCustomFieldAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CartSetLineItemCustomFieldAction) MarshalJSON ¶

func (obj CartSetLineItemCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetLineItemCustomTypeAction ¶

type CartSetLineItemCustomTypeAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the Line Item with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Line Item.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Line Item.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CartSetLineItemCustomTypeAction) MarshalJSON ¶

func (obj CartSetLineItemCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetLineItemDistributionChannelAction ¶

type CartSetLineItemDistributionChannelAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// - If present, a [Reference](ctp:api:type:Reference) to the Channel is set for the [LineItem](ctp:api:type:LineItem) specified by `lineItemId`.
	// - If not present, the current [Reference](ctp:api:type:Reference) to a distribution channel is removed from the [LineItem](ctp:api:type:LineItem) specified by `lineItemId`.
	//   The Channel must have the `ProductDistribution` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
}

* * Setting a distribution channel for a LineItem(ctp:api:type:LineItem) can lead to an updated `price` as described in [LineItem Price selection](ctp:api:type:LineItemPriceSelection). *

func (CartSetLineItemDistributionChannelAction) MarshalJSON ¶

func (obj CartSetLineItemDistributionChannelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetLineItemInventoryModeAction ¶

type CartSetLineItemInventoryModeAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Inventory mode specific to the Line Item only, and valid for the entire `quantity` of the Line Item.
	// Set only if the inventory mode should be different from the `inventoryMode` specified on the [Cart](ctp:api:type:Cart).
	InventoryMode *InventoryMode `json:"inventoryMode,omitempty"`
}

func (CartSetLineItemInventoryModeAction) MarshalJSON ¶

func (obj CartSetLineItemInventoryModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetLineItemPriceAction ¶

type CartSetLineItemPriceAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Value to set.
	// If `externalPrice` is not given and the `priceMode` is `ExternalPrice`, the external price is unset and the `priceMode` is set to `Platform`.
	ExternalPrice *Money `json:"externalPrice,omitempty"`
}

* * Sets the LineItem(ctp:api:type:LineItem) `price` and changes the `priceMode` to `ExternalPrice` LineItemPriceMode(ctp:api:type:LineItemPriceMode). *

func (CartSetLineItemPriceAction) MarshalJSON ¶

func (obj CartSetLineItemPriceAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetLineItemShippingDetailsAction ¶

type CartSetLineItemShippingDetailsAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Value to set.
	// If empty, the existing value is removed.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
}

func (CartSetLineItemShippingDetailsAction) MarshalJSON ¶

func (obj CartSetLineItemShippingDetailsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetLineItemSupplyChannelAction ¶

type CartSetLineItemSupplyChannelAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// - If present, a [Reference](ctp:api:type:Reference) to the Channel is set for the [LineItem](ctp:api:type:LineItem) specified by `lineItemId`.
	// - If not present, the current [Reference](ctp:api:type:Reference) to a supply channel will be removed from the [LineItem](ctp:api:type:LineItem) specified by `lineItemId`.
	//   The Channel must have the `InventorySupply` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
}

* * Performing this action has no impact on inventory that should be reserved. *

func (CartSetLineItemSupplyChannelAction) MarshalJSON ¶

func (obj CartSetLineItemSupplyChannelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetLineItemTaxAmountAction ¶

type CartSetLineItemTaxAmountAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Value to set.
	// If empty, any existing value is removed.
	ExternalTaxAmount *ExternalTaxAmountDraft `json:"externalTaxAmount,omitempty"`
	// `key` of the [ShippingMethod](ctp:api:type:ShippingMethod) used for this Line Item.
	// This is required for Carts with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Can be used if the Cart has the `ExternalAmount` TaxMode(ctp:api:type:TaxMode). *

func (CartSetLineItemTaxAmountAction) MarshalJSON ¶

func (obj CartSetLineItemTaxAmountAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetLineItemTaxRateAction ¶

type CartSetLineItemTaxRateAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Value to set.
	// If empty, any existing value is removed.
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	// `key` of the [ShippingMethod](ctp:api:type:ShippingMethod) used for this Line Item.
	// This is required for Carts with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Can be used if the Cart has the `External` TaxMode(ctp:api:type:TaxMode). *

func (CartSetLineItemTaxRateAction) MarshalJSON ¶

func (obj CartSetLineItemTaxRateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetLineItemTotalPriceAction ¶

type CartSetLineItemTotalPriceAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Value to set.
	// If `externalTotalPrice` is not given and the `priceMode` is `ExternalTotal`, the external price is unset and the `priceMode` is set to `Platform`.
	ExternalTotalPrice *ExternalLineItemTotalPrice `json:"externalTotalPrice,omitempty"`
}

* * Sets the LineItem(ctp:api:type:LineItem) `totalPrice` and `price`, and changes the `priceMode` to `ExternalTotal` LineItemPriceMode(ctp:api:type:LineItemPriceMode). *

func (CartSetLineItemTotalPriceAction) MarshalJSON ¶

func (obj CartSetLineItemTotalPriceAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetLocaleAction ¶

type CartSetLocaleAction struct {
	// Value to set.
	// Must be one of the [Project](ctp:api:type:Project)'s `languages`.
	// If empty, any existing value will be removed.
	Locale *string `json:"locale,omitempty"`
}

func (CartSetLocaleAction) MarshalJSON ¶

func (obj CartSetLocaleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetShippingAddressAction ¶

type CartSetShippingAddressAction struct {
	// Value to set.
	// If not set, the shipping address is unset, and the `taxedPrice` and `taxRate` are unset in all Line Items of the Cart.
	Address *BaseAddress `json:"address,omitempty"`
}

* * Setting the shipping address also sets the TaxRate(ctp:api:type:TaxRate) of Line Items and calculates the TaxedPrice(ctp:api:type:TaxedPrice). * * If a matching price cannot be found for the given shipping address during [Line Item Price selection](ctp:api:type:LineItemPriceSelection), * a [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError) error is returned. * * If you want to allow shipping to states inside a country that are not explicitly covered by a TaxRate, * set the `countryTaxRateFallbackEnabled` field to `true` in the CartsConfiguration(ctp:api:type:CartsConfiguration) by using * the [Change CountryTaxRateFallbackEnabled](ctp:api:type:ProjectChangeCountryTaxRateFallbackEnabledAction) update action. *

func (CartSetShippingAddressAction) MarshalJSON ¶

func (obj CartSetShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetShippingAddressCustomFieldAction ¶

type CartSetShippingAddressCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CartSetShippingAddressCustomFieldAction) MarshalJSON ¶

func (obj CartSetShippingAddressCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetShippingAddressCustomTypeAction ¶

type CartSetShippingAddressCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the `shippingAddress` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `shippingAddress`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `shippingAddress`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CartSetShippingAddressCustomTypeAction) MarshalJSON ¶

func (obj CartSetShippingAddressCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetShippingCustomFieldAction ¶

type CartSetShippingCustomFieldAction struct {
	// The `shippingKey` of the [Shipping](ctp:api:type:Shipping) to customize. Used to specify which Shipping Method to customize
	// on a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	// Leave this empty to customize the one and only ShippingMethod on a `Single` ShippingMode Cart.
	ShippingKey *string `json:"shippingKey,omitempty"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Trying to remove a field that does not exist will fail with an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CartSetShippingCustomFieldAction) MarshalJSON ¶

func (obj CartSetShippingCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetShippingCustomTypeAction ¶

type CartSetShippingCustomTypeAction struct {
	// The `shippingKey` of the [Shipping](ctp:api:type:Shipping) to customize. Used to specify which Shipping Method to customize
	// on a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	// Leave this empty to customize the one and only ShippingMethod on a `Single` ShippingMode Cart.
	ShippingKey *string `json:"shippingKey,omitempty"`
	// Defines the [Type](ctp:api:type:Type) that extends the specified ShippingMethod with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the ShippingMethod.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `shippingMethod`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

* * This action sets, overwrites, or removes any existing Custom Type and Custom Fields for the Cart's `shippingMethod` or `shipping`. *

func (CartSetShippingCustomTypeAction) MarshalJSON ¶

func (obj CartSetShippingCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetShippingMethodAction ¶

type CartSetShippingMethodAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	//
	// If the referenced Shipping Method has a predicate that does not match the Cart, an [InvalidOperation](ctp:api:type:InvalidOperationError) error is returned.
	ShippingMethod *ShippingMethodResourceIdentifier `json:"shippingMethod,omitempty"`
	// An external Tax Rate can be set if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
}

* * To set the Cart's Shipping Method the Cart must have the `Single` ShippingMode(ctp:api:type:ShippingMode) and a `shippingAddress`. *

func (CartSetShippingMethodAction) MarshalJSON ¶

func (obj CartSetShippingMethodAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetShippingMethodTaxAmountAction ¶

type CartSetShippingMethodTaxAmountAction struct {
	// `key` of the [ShippingMethod](ctp:api:type:ShippingMethod) to update. This is required for Carts with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
	// Value to set.
	// If empty, any existing value is removed.
	ExternalTaxAmount *ExternalTaxAmountDraft `json:"externalTaxAmount,omitempty"`
}

* * A Shipping Method tax amount can be set if the Cart has the `ExternalAmount` TaxMode(ctp:api:type:TaxMode). *

func (CartSetShippingMethodTaxAmountAction) MarshalJSON ¶

func (obj CartSetShippingMethodTaxAmountAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetShippingMethodTaxRateAction ¶

type CartSetShippingMethodTaxRateAction struct {
	// `key` of the [ShippingMethod](ctp:api:type:ShippingMethod) to update. This is required for Carts with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
	// Value to set.
	// If empty, any existing value is removed.
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
}

* * A Shipping Method Tax Rate can be set if the Cart has the `External` TaxMode(ctp:api:type:TaxMode). *

func (CartSetShippingMethodTaxRateAction) MarshalJSON ¶

func (obj CartSetShippingMethodTaxRateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartSetShippingRateInputAction ¶

type CartSetShippingRateInputAction struct {
	// The data type of this field depends on the `shippingRateInputType.type` configured in the [Project](ctp:api:type:Project):
	//
	// - If `CartClassification`, it must be [ClassificationShippingRateInputDraft](ctp:api:type:ClassificationShippingRateInputDraft).
	// - If `CartScore`, it must be [ScoreShippingRateInputDraft](ctp:api:type:ScoreShippingRateInputDraft).
	// - If `CartValue`, it cannot be set.
	ShippingRateInput ShippingRateInputDraft `json:"shippingRateInput,omitempty"`
}

* * Input used to select a ShippingRatePriceTier(ctp:api:type:ShippingRatePriceTier). * If no matching tier can be found, or the input is not set, the default price for the shipping rate is used. *

func (CartSetShippingRateInputAction) MarshalJSON ¶

func (obj CartSetShippingRateInputAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CartSetShippingRateInputAction) UnmarshalJSON ¶

func (obj *CartSetShippingRateInputAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CartState ¶

type CartState string

* * Indicates the current status of a Cart. *

const (
	CartStateActive  CartState = "Active"
	CartStateMerged  CartState = "Merged"
	CartStateOrdered CartState = "Ordered"
	CartStateFrozen  CartState = "Frozen"
)

type CartUnfreezeCartAction ¶

type CartUnfreezeCartAction struct {
}

* * Changes the CartState(ctp:api:type:CartState) from `Frozen` to `Active`. Reactivates a [Frozen Cart](ctp:api:type:FrozenCarts). * This action updates all prices in the Cart according to latest Prices on related Product Variants and Shipping Methods and by applying all discounts currently being active and applicable for the Cart. *

func (CartUnfreezeCartAction) MarshalJSON ¶

func (obj CartUnfreezeCartAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartUpdate ¶

type CartUpdate struct {
	// Expected version of the Cart on which the changes apply.
	// If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) is returned.
	Version int `json:"version"`
	// Update actions to be performed on the Cart.
	Actions []CartUpdateAction `json:"actions"`
}

func (*CartUpdate) UnmarshalJSON ¶

func (obj *CartUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CartUpdateAction ¶

type CartUpdateAction interface{}

type CartUpdateItemShippingAddressAction ¶

type CartUpdateItemShippingAddressAction struct {
	// The new Address with the same `key` as the Address it will replace.
	Address BaseAddress `json:"address"`
}

* * Updates an address in `itemShippingAddresses` by keeping the Address `key`. *

func (CartUpdateItemShippingAddressAction) MarshalJSON ¶

func (obj CartUpdateItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartValueTier ¶

type CartValueTier struct {
	// Minimum total price of a Cart for which a shipping rate applies.
	MinimumCentAmount int `json:"minimumCentAmount"`
	// Fixed shipping rate Price for a CartValue.
	Price Money `json:"price"`
	// Appears in response to [Get ShippingMethods for a Cart](ctp:api:endpoint:/{projectKey}/shipping-methods/matching-cart:GET) if the shipping rate matches the search query.
	IsMatching *bool `json:"isMatching,omitempty"`
}

* * Used when the ShippingRate maps to the sum of LineItem(ctp:api:type:LineItem) Prices. * The value of the Cart is used to select a tier. * If chosen, it is not possible to set a value for the `shippingRateInput` on the Cart(ctp:api:type:Cart). * Tiers contain the `centAmount` (a value of `100` in the currency `USD` corresponds to `$ 1.00`), and start at `1`.' *

func (CartValueTier) MarshalJSON ¶

func (obj CartValueTier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartValueType ¶

type CartValueType struct {
}

* * Used when the ShippingRate maps to the sum of LineItem(ctp:api:type:LineItem) Prices. * The value of the Cart is used to select a tier. * If chosen, it is not possible to set a value for the `shippingRateInput` on the Cart(ctp:api:type:Cart). *

func (CartValueType) MarshalJSON ¶

func (obj CartValueType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CartsConfiguration ¶

type CartsConfiguration struct {
	// Default value for the `deleteDaysAfterLastModification` parameter of the [CartDraft](ctp:api:type:CartDraft) and [MyCartDraft](ctp:api:type:MyCartDraft).
	// If a [ChangeSubscription](ctp:api:type:ChangeSubscription) for Carts exists, a [ResourceDeletedDeliveryPayload](ctp:api:type:ResourceDeletedDeliveryPayload) is sent upon deletion of a Cart.
	//
	// This field may not be present on Projects created before January 2020.
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
	// Indicates if country _- no state_ Tax Rate fallback should be used when a shipping address state is not explicitly covered in the rates lists of all Tax Categories of a Cart Line Items. This field may not be present on Projects created before June 2020.
	CountryTaxRateFallbackEnabled *bool `json:"countryTaxRateFallbackEnabled,omitempty"`
}

type Category ¶

type Category struct {
	// Unique identifier of the Category.
	ID string `json:"id"`
	// Current version of the Category.
	Version int `json:"version"`
	// Date and time (UTC) the Category was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Category was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources updated after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Name of the Category.
	Name LocalizedString `json:"name"`
	// User-defined identifier used as a deep-link URL to the related Category per [Locale](ctp:api:type:Locale).
	// A Category can have the same slug for different Locales, but they are unique across the [Project](ctp:api:type:Project).
	// Valid slugs match the pattern `^[A-Za-z0-9_-]{2,256}+$`.
	// For [good performance](/../api/predicates/query#performance-considerations), indexes are provided for the first 15 `languages` set in a Project.
	Slug LocalizedString `json:"slug"`
	// Description of the Category.
	Description *LocalizedString `json:"description,omitempty"`
	// Contains the parent path towards the root Category.
	Ancestors []CategoryReference `json:"ancestors"`
	// Parent Category of this Category.
	Parent *CategoryReference `json:"parent,omitempty"`
	// Decimal value between 0 and 1 used to order Categories that are on the same level in the Category tree.
	OrderHint string `json:"orderHint"`
	// Additional identifier for external systems like Customer Relationship Management (CRM) or Enterprise Resource Planning (ERP).
	ExternalId *string `json:"externalId,omitempty"`
	// Name of the Category used by external search engines for improved search engine performance.
	MetaTitle *LocalizedString `json:"metaTitle,omitempty"`
	// Description of the Category used by external search engines for improved search engine performance.
	MetaDescription *LocalizedString `json:"metaDescription,omitempty"`
	// Keywords related to the Category for improved search engine performance.
	MetaKeywords *LocalizedString `json:"metaKeywords,omitempty"`
	// Custom Fields for the Category.
	Custom *CustomFields `json:"custom,omitempty"`
	// Media related to the Category.
	Assets []Asset `json:"assets"`
	// User-defined unique identifier of the Category.
	Key *string `json:"key,omitempty"`
}

func (Category) MarshalJSON ¶

func (obj Category) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryAddAssetAction ¶

type CategoryAddAssetAction struct {
	// Value to append.
	Asset AssetDraft `json:"asset"`
	// Position in the array at which the Asset should be put. When specified, the value must be between `0` and the total number of Assets minus `1`.
	Position *int `json:"position,omitempty"`
}

func (CategoryAddAssetAction) MarshalJSON ¶

func (obj CategoryAddAssetAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryChangeAssetNameAction ¶

type CategoryChangeAssetNameAction struct {
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetId *string `json:"assetId,omitempty"`
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetKey *string `json:"assetKey,omitempty"`
	// New value to set. Must not be empty.
	Name LocalizedString `json:"name"`
}

func (CategoryChangeAssetNameAction) MarshalJSON ¶

func (obj CategoryChangeAssetNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryChangeAssetOrderAction ¶

type CategoryChangeAssetOrderAction struct {
	// New value to set. Must contain all Asset `id`s.
	AssetOrder []string `json:"assetOrder"`
}

* * This update action changes the order of the `assets` array. The new order is defined by listing the `id`s of the Assets. *

func (CategoryChangeAssetOrderAction) MarshalJSON ¶

func (obj CategoryChangeAssetOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryChangeNameAction ¶

type CategoryChangeNameAction struct {
	// New value to set. Must not be empty.
	Name LocalizedString `json:"name"`
}

func (CategoryChangeNameAction) MarshalJSON ¶

func (obj CategoryChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryChangeOrderHintAction ¶

type CategoryChangeOrderHintAction struct {
	// New value to set. Must be a decimal value between 0 and 1.
	OrderHint string `json:"orderHint"`
}

func (CategoryChangeOrderHintAction) MarshalJSON ¶

func (obj CategoryChangeOrderHintAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryChangeParentAction ¶

type CategoryChangeParentAction struct {
	// New value to set as parent.
	Parent CategoryResourceIdentifier `json:"parent"`
}

func (CategoryChangeParentAction) MarshalJSON ¶

func (obj CategoryChangeParentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryChangeSlugAction ¶

type CategoryChangeSlugAction struct {
	// New value to set. Must not be empty.
	// A Category can have the same slug for different [Locales](ctp:api:type:Locale), but it must be unique across the [Project](ctp:api:type:Project).
	// Valid slugs must match the pattern `^[A-Za-z0-9_-]{2,256}+$`.
	Slug LocalizedString `json:"slug"`
}

* * Changing the slug produces the [CategorySlugChanged](ctp:api:type:CategorySlugChangedMessage) Message. *

func (CategoryChangeSlugAction) MarshalJSON ¶

func (obj CategoryChangeSlugAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryCreatedMessage ¶

type CategoryCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Category](ctp:api:type:Category) that was created.
	Category Category `json:"category"`
}

* * Generated after a successful [Create Category](/../api/projects/categories#create-category) request. *

func (CategoryCreatedMessage) MarshalJSON ¶

func (obj CategoryCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CategoryCreatedMessage) UnmarshalJSON ¶

func (obj *CategoryCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CategoryCreatedMessagePayload ¶

type CategoryCreatedMessagePayload struct {
	// [Category](ctp:api:type:Category) that was created.
	Category Category `json:"category"`
}

* * Generated after a successful [Create Category](/../api/projects/categories#create-category) request. *

func (CategoryCreatedMessagePayload) MarshalJSON ¶

func (obj CategoryCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryDraft ¶

type CategoryDraft struct {
	// Name of the Category.
	Name LocalizedString `json:"name"`
	// User-defined identifier used as a deep-link URL to the related Category.
	// A Category can have the same slug for different [Locales](ctp:api:type:Locale), but it must be unique across the [Project](ctp:api:type:Project).
	// Valid slugs must match the pattern `^[A-Za-z0-9_-]{2,256}+$`.
	Slug LocalizedString `json:"slug"`
	// Description of the Category.
	Description *LocalizedString `json:"description,omitempty"`
	// Parent Category of the Category.
	// The parent can be set by its `id` or `key`.
	Parent *CategoryResourceIdentifier `json:"parent,omitempty"`
	// Decimal value between 0 and 1 used to order Categories that are on the same level in the Category tree.
	// If not set, a random value will be assigned.
	OrderHint *string `json:"orderHint,omitempty"`
	// Additional identifier for external systems like Customer Relationship Management (CRM) or Enterprise Resource Planning (ERP).
	ExternalId *string `json:"externalId,omitempty"`
	// Name of the Category used by external search engines for improved search engine performance.
	MetaTitle *LocalizedString `json:"metaTitle,omitempty"`
	// Description of the Category used by external search engines for improved search engine performance.
	MetaDescription *LocalizedString `json:"metaDescription,omitempty"`
	// Keywords related to the Category for improved search engine performance.
	MetaKeywords *LocalizedString `json:"metaKeywords,omitempty"`
	// Custom Fields for the Category.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Media related to the Category.
	Assets []AssetDraft `json:"assets"`
	// User-defined unique identifier for the Category.
	Key *string `json:"key,omitempty"`
}

func (CategoryDraft) MarshalJSON ¶

func (obj CategoryDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryOrderHints ¶

type CategoryOrderHints map[string]string

* * JSON object where the key is a Category(ctp:api:type:Category) `id` and the value is an order hint. * Allows controlling the order of Products and how they appear in Categories. Products with no order hint have an order score below `0`. Order hints are non-unique. * If a subset of Products have the same value for order hint in a specific category, the behavior is undetermined.

type CategoryPagedQueryResponse ¶

type CategoryPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [Category](ctp:api:type:Category) matching the query.
	Results []Category `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of Category(ctp:api:type:Category). *

type CategoryReference ¶

type CategoryReference struct {
	// Unique identifier of the referenced [Category](ctp:api:type:Category).
	ID string `json:"id"`
	// Contains the representation of the expanded Category. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for Categories.
	Obj *Category `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a Category(ctp:api:type:Category). *

func (CategoryReference) MarshalJSON ¶

func (obj CategoryReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryRemoveAssetAction ¶

type CategoryRemoveAssetAction struct {
	// Value to remove. Either `assetId` or `assetKey` is required.
	AssetId *string `json:"assetId,omitempty"`
	// Value to remove. Either `assetId` or `assetKey` is required.
	AssetKey *string `json:"assetKey,omitempty"`
}

func (CategoryRemoveAssetAction) MarshalJSON ¶

func (obj CategoryRemoveAssetAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryResourceIdentifier ¶

type CategoryResourceIdentifier struct {
	// Unique identifier of the referenced [Category](ctp:api:type:Channel). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [Category](ctp:api:type:Category). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a Category(ctp:api:type:Category). *

func (CategoryResourceIdentifier) MarshalJSON ¶

func (obj CategoryResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetAssetCustomFieldAction ¶

type CategorySetAssetCustomFieldAction struct {
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetId *string `json:"assetId,omitempty"`
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetKey *string `json:"assetKey,omitempty"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CategorySetAssetCustomFieldAction) MarshalJSON ¶

func (obj CategorySetAssetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetAssetCustomTypeAction ¶

type CategorySetAssetCustomTypeAction struct {
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetId *string `json:"assetId,omitempty"`
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetKey *string `json:"assetKey,omitempty"`
	// Defines the [Type](ctp:api:type:Type) that extends the Asset with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Asset.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Asset.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CategorySetAssetCustomTypeAction) MarshalJSON ¶

func (obj CategorySetAssetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetAssetDescriptionAction ¶

type CategorySetAssetDescriptionAction struct {
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetId *string `json:"assetId,omitempty"`
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetKey *string `json:"assetKey,omitempty"`
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

func (CategorySetAssetDescriptionAction) MarshalJSON ¶

func (obj CategorySetAssetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetAssetKeyAction ¶

type CategorySetAssetKeyAction struct {
	// Value to set.
	AssetId string `json:"assetId"`
	// Value to set. If empty, any existing value will be removed.
	AssetKey *string `json:"assetKey,omitempty"`
}

* * Set or remove the `key` of an Asset(ctp:api:type:Asset). *

func (CategorySetAssetKeyAction) MarshalJSON ¶

func (obj CategorySetAssetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetAssetSourcesAction ¶

type CategorySetAssetSourcesAction struct {
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetId *string `json:"assetId,omitempty"`
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetKey *string `json:"assetKey,omitempty"`
	// Must not be empty. At least one entry is required.
	Sources []AssetSource `json:"sources"`
}

func (CategorySetAssetSourcesAction) MarshalJSON ¶

func (obj CategorySetAssetSourcesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetAssetTagsAction ¶

type CategorySetAssetTagsAction struct {
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetId *string `json:"assetId,omitempty"`
	// New value to set. Either `assetId` or `assetKey` is required.
	AssetKey *string `json:"assetKey,omitempty"`
	// Keywords for categorizing and organizing Assets.
	Tags []string `json:"tags"`
}

func (CategorySetAssetTagsAction) MarshalJSON ¶

func (obj CategorySetAssetTagsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetCustomFieldAction ¶

type CategorySetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CategorySetCustomFieldAction) MarshalJSON ¶

func (obj CategorySetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetCustomTypeAction ¶

type CategorySetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the Category with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Category.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Category.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CategorySetCustomTypeAction) MarshalJSON ¶

func (obj CategorySetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetDescriptionAction ¶

type CategorySetDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

func (CategorySetDescriptionAction) MarshalJSON ¶

func (obj CategorySetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetExternalIdAction ¶

type CategorySetExternalIdAction struct {
	// Value to set. If empty, any existing value will be removed.
	ExternalId *string `json:"externalId,omitempty"`
}

* * This update action sets a new ID that can be used as an additional identifier for external systems like Customer Relationship Management (CRM) or Enterprise Resource Planning (ERP). *

func (CategorySetExternalIdAction) MarshalJSON ¶

func (obj CategorySetExternalIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetKeyAction ¶

type CategorySetKeyAction struct {
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

func (CategorySetKeyAction) MarshalJSON ¶

func (obj CategorySetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetMetaDescriptionAction ¶

type CategorySetMetaDescriptionAction struct {
	// Value to set.
	MetaDescription *LocalizedString `json:"metaDescription,omitempty"`
}

func (CategorySetMetaDescriptionAction) MarshalJSON ¶

func (obj CategorySetMetaDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetMetaKeywordsAction ¶

type CategorySetMetaKeywordsAction struct {
	// Value to set.
	MetaKeywords *LocalizedString `json:"metaKeywords,omitempty"`
}

func (CategorySetMetaKeywordsAction) MarshalJSON ¶

func (obj CategorySetMetaKeywordsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySetMetaTitleAction ¶

type CategorySetMetaTitleAction struct {
	// Value to set.
	MetaTitle *LocalizedString `json:"metaTitle,omitempty"`
}

func (CategorySetMetaTitleAction) MarshalJSON ¶

func (obj CategorySetMetaTitleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategorySlugChangedMessage ¶

type CategorySlugChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The slug of the [Category](ctp:api:type:Category) after the [Change Slug](ctp:api:type:CategoryChangeSlugAction) update action.
	Slug LocalizedString `json:"slug"`
	// The slug of the [Category](ctp:api:type:Category) before the [Change Slug](ctp:api:type:CategoryChangeSlugAction) update action.
	OldSlug *LocalizedString `json:"oldSlug,omitempty"`
}

* * Generated after a successful [Change Slug](ctp:api:type:CategoryChangeSlugAction) update action. *

func (CategorySlugChangedMessage) MarshalJSON ¶

func (obj CategorySlugChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CategorySlugChangedMessage) UnmarshalJSON ¶

func (obj *CategorySlugChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CategorySlugChangedMessagePayload ¶

type CategorySlugChangedMessagePayload struct {
	// The slug of the [Category](ctp:api:type:Category) after the [Change Slug](ctp:api:type:CategoryChangeSlugAction) update action.
	Slug LocalizedString `json:"slug"`
	// The slug of the [Category](ctp:api:type:Category) before the [Change Slug](ctp:api:type:CategoryChangeSlugAction) update action.
	OldSlug *LocalizedString `json:"oldSlug,omitempty"`
}

* * Generated after a successful [Change Slug](ctp:api:type:CategoryChangeSlugAction) update action. *

func (CategorySlugChangedMessagePayload) MarshalJSON ¶

func (obj CategorySlugChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CategoryUpdate ¶

type CategoryUpdate struct {
	// Expected version of the Category on which the changes should be applied.
	// If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the Category.
	Actions []CategoryUpdateAction `json:"actions"`
}

func (*CategoryUpdate) UnmarshalJSON ¶

func (obj *CategoryUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CategoryUpdateAction ¶

type CategoryUpdateAction interface{}

type CentPrecisionMoney ¶

type CentPrecisionMoney struct {
	// Amount in the smallest indivisible unit of a currency, such as:
	//
	// * Cents for EUR and USD, pence for GBP, or centime for CHF (5 CHF is specified as `500`).
	// * The value in the major unit for currencies without minor units, like JPY (5 JPY is specified as `5`).
	CentAmount int `json:"centAmount"`
	// Currency code compliant to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).
	CurrencyCode string `json:"currencyCode"`
	// The number of default fraction digits for the given currency, like `2` for EUR or `0` for JPY.
	FractionDigits int `json:"fractionDigits"`
}

* * Object that stores cent amounts in a specific currency. *

func (CentPrecisionMoney) MarshalJSON ¶

func (obj CentPrecisionMoney) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CentPrecisionMoneyDraft ¶

type CentPrecisionMoneyDraft struct {
	// Amount in the smallest indivisible unit of a currency, such as:
	//
	// * Cents for EUR and USD, pence for GBP, or centime for CHF (5 CHF is specified as `500`).
	// * The value in the major unit for currencies without minor units, like JPY (5 JPY is specified as `5`).
	CentAmount int `json:"centAmount"`
	// Currency code compliant to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).
	CurrencyCode string `json:"currencyCode"`
	// This field is optional for cent precision. If provided, it must be equal to the default number of fraction digits for the specified currency.
	FractionDigits *int `json:"fractionDigits,omitempty"`
}

* * This draft type is the alternative to Money(ctp:api:type:Money). *

func (CentPrecisionMoneyDraft) MarshalJSON ¶

func (obj CentPrecisionMoneyDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChangeSubscription ¶

type ChangeSubscription struct {
	// Unique identifier for the type of resource, for example, `cart`.
	ResourceTypeId ChangeSubscriptionResourceTypeId `json:"resourceTypeId"`
}

* * Notification about changes to a resource. The payload format differs for resource [creation](ctp:api:type:ResourceCreatedDeliveryPayload), * [update](ctp:api:type:ResourceUpdatedDeliveryPayload), * and [deletion](ctp:api:type:ResourceDeletedDeliveryPayload). *

type ChangeSubscriptionResourceTypeId ¶

type ChangeSubscriptionResourceTypeId string

* * Resource types supported by [ChangeSubscriptions](ctp:api:type:ChangeSubscription): *

const (
	ChangeSubscriptionResourceTypeIdBusinessUnit          ChangeSubscriptionResourceTypeId = "business-unit"
	ChangeSubscriptionResourceTypeIdCart                  ChangeSubscriptionResourceTypeId = "cart"
	ChangeSubscriptionResourceTypeIdCartDiscount          ChangeSubscriptionResourceTypeId = "cart-discount"
	ChangeSubscriptionResourceTypeIdCategory              ChangeSubscriptionResourceTypeId = "category"
	ChangeSubscriptionResourceTypeIdChannel               ChangeSubscriptionResourceTypeId = "channel"
	ChangeSubscriptionResourceTypeIdCustomer              ChangeSubscriptionResourceTypeId = "customer"
	ChangeSubscriptionResourceTypeIdCustomerEmailToken    ChangeSubscriptionResourceTypeId = "customer-email-token"
	ChangeSubscriptionResourceTypeIdCustomerGroup         ChangeSubscriptionResourceTypeId = "customer-group"
	ChangeSubscriptionResourceTypeIdCustomerPasswordToken ChangeSubscriptionResourceTypeId = "customer-password-token"
	ChangeSubscriptionResourceTypeIdDiscountCode          ChangeSubscriptionResourceTypeId = "discount-code"
	ChangeSubscriptionResourceTypeIdExtension             ChangeSubscriptionResourceTypeId = "extension"
	ChangeSubscriptionResourceTypeIdInventoryEntry        ChangeSubscriptionResourceTypeId = "inventory-entry"
	ChangeSubscriptionResourceTypeIdKeyValueDocument      ChangeSubscriptionResourceTypeId = "key-value-document"
	ChangeSubscriptionResourceTypeIdOrder                 ChangeSubscriptionResourceTypeId = "order"
	ChangeSubscriptionResourceTypeIdOrderEdit             ChangeSubscriptionResourceTypeId = "order-edit"
	ChangeSubscriptionResourceTypeIdPayment               ChangeSubscriptionResourceTypeId = "payment"
	ChangeSubscriptionResourceTypeIdProduct               ChangeSubscriptionResourceTypeId = "product"
	ChangeSubscriptionResourceTypeIdProductDiscount       ChangeSubscriptionResourceTypeId = "product-discount"
	ChangeSubscriptionResourceTypeIdProductPrice          ChangeSubscriptionResourceTypeId = "product-price"
	ChangeSubscriptionResourceTypeIdProductSelection      ChangeSubscriptionResourceTypeId = "product-selection"
	ChangeSubscriptionResourceTypeIdProductType           ChangeSubscriptionResourceTypeId = "product-type"
	ChangeSubscriptionResourceTypeIdQuote                 ChangeSubscriptionResourceTypeId = "quote"
	ChangeSubscriptionResourceTypeIdQuoteRequest          ChangeSubscriptionResourceTypeId = "quote-request"
	ChangeSubscriptionResourceTypeIdReview                ChangeSubscriptionResourceTypeId = "review"
	ChangeSubscriptionResourceTypeIdShippingMethod        ChangeSubscriptionResourceTypeId = "shipping-method"
	ChangeSubscriptionResourceTypeIdShoppingList          ChangeSubscriptionResourceTypeId = "shopping-list"
	ChangeSubscriptionResourceTypeIdStagedQuote           ChangeSubscriptionResourceTypeId = "staged-quote"
	ChangeSubscriptionResourceTypeIdStandalonePrice       ChangeSubscriptionResourceTypeId = "standalone-price"
	ChangeSubscriptionResourceTypeIdState                 ChangeSubscriptionResourceTypeId = "state"
	ChangeSubscriptionResourceTypeIdStore                 ChangeSubscriptionResourceTypeId = "store"
	ChangeSubscriptionResourceTypeIdSubscription          ChangeSubscriptionResourceTypeId = "subscription"
	ChangeSubscriptionResourceTypeIdTaxCategory           ChangeSubscriptionResourceTypeId = "tax-category"
	ChangeSubscriptionResourceTypeIdType                  ChangeSubscriptionResourceTypeId = "type"
	ChangeSubscriptionResourceTypeIdZone                  ChangeSubscriptionResourceTypeId = "zone"
)

type Channel ¶

type Channel struct {
	// Unique identifier of the Channel.
	ID string `json:"id"`
	// Current version of the Channel.
	Version int `json:"version"`
	// Date and time (UTC) the Channel was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Channel was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources updated after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the Channel.
	Key string `json:"key"`
	// Roles of the Channel.
	Roles []ChannelRoleEnum `json:"roles"`
	// Name of the Channel.
	Name *LocalizedString `json:"name,omitempty"`
	// Description of the Channel.
	Description *LocalizedString `json:"description,omitempty"`
	// Address where the Channel is located (for example, if the Channel is a physical store).
	Address *Address `json:"address,omitempty"`
	// Statistics about the review ratings taken into account for the Channel.
	ReviewRatingStatistics *ReviewRatingStatistics `json:"reviewRatingStatistics,omitempty"`
	// Custom Fields defined for the Channel.
	Custom *CustomFields `json:"custom,omitempty"`
	// GeoJSON geometry object encoding the geo location of the Channel.
	GeoLocation GeoJson `json:"geoLocation,omitempty"`
}

func (*Channel) UnmarshalJSON ¶

func (obj *Channel) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ChannelAddRolesAction ¶

type ChannelAddRolesAction struct {
	// Value to append to the array.
	Roles []ChannelRoleEnum `json:"roles"`
}

func (ChannelAddRolesAction) MarshalJSON ¶

func (obj ChannelAddRolesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelChangeDescriptionAction ¶

type ChannelChangeDescriptionAction struct {
	// New value to set. Must not be empty.
	Description LocalizedString `json:"description"`
}

func (ChannelChangeDescriptionAction) MarshalJSON ¶

func (obj ChannelChangeDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelChangeKeyAction ¶

type ChannelChangeKeyAction struct {
	// New value to set. Must not be empty.
	Key string `json:"key"`
}

func (ChannelChangeKeyAction) MarshalJSON ¶

func (obj ChannelChangeKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelChangeNameAction ¶

type ChannelChangeNameAction struct {
	// New value to set. Must not be empty.
	Name LocalizedString `json:"name"`
}

func (ChannelChangeNameAction) MarshalJSON ¶

func (obj ChannelChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelDraft ¶

type ChannelDraft struct {
	// User-defined unique identifier for the Channel.
	Key string `json:"key"`
	// Roles of the Channel.
	// Each channel must have at least one role.
	// If not specified, then `InventorySupply` is assigned by default.
	Roles []ChannelRoleEnum `json:"roles"`
	// Name of the Channel.
	Name *LocalizedString `json:"name,omitempty"`
	// Description of the Channel.
	Description *LocalizedString `json:"description,omitempty"`
	// Address where the Channel is located.
	Address *BaseAddress `json:"address,omitempty"`
	// Custom fields defined for the Channel.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// GeoJSON geometry object encoding the geo location of the Channel.
	// Currently, only the [Point](ctp:api:type:GeoJsonPoint) type is supported.
	GeoLocation GeoJson `json:"geoLocation,omitempty"`
}

func (ChannelDraft) MarshalJSON ¶

func (obj ChannelDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ChannelDraft) UnmarshalJSON ¶

func (obj *ChannelDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ChannelPagedQueryResponse ¶

type ChannelPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [Channels](ctp:api:type:Channel) matching the query.
	Results []Channel `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of Channel(ctp:api:type:Channel). *

type ChannelReference ¶

type ChannelReference struct {
	// Unique identifier of the referenced [Channel](ctp:api:type:Channel).
	ID string `json:"id"`
	// Contains the representation of the expanded Channel.
	// Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for Channels.
	Obj *Channel `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a Channel(ctp:api:type:Channel). *

func (ChannelReference) MarshalJSON ¶

func (obj ChannelReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelRemoveRolesAction ¶

type ChannelRemoveRolesAction struct {
	// Value to remove from the array.
	Roles []ChannelRoleEnum `json:"roles"`
}

func (ChannelRemoveRolesAction) MarshalJSON ¶

func (obj ChannelRemoveRolesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelResourceIdentifier ¶

type ChannelResourceIdentifier struct {
	// Unique identifier of the referenced [Channel](ctp:api:type:Channel). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [Channel](ctp:api:type:Channel). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a Channel(ctp:api:type:Channel). *

func (ChannelResourceIdentifier) MarshalJSON ¶

func (obj ChannelResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelRoleEnum ¶

type ChannelRoleEnum string

* * Describes the purpose and type of the Channel. A Channel can have one or more roles. *

const (
	ChannelRoleEnumInventorySupply     ChannelRoleEnum = "InventorySupply"
	ChannelRoleEnumProductDistribution ChannelRoleEnum = "ProductDistribution"
	ChannelRoleEnumOrderExport         ChannelRoleEnum = "OrderExport"
	ChannelRoleEnumOrderImport         ChannelRoleEnum = "OrderImport"
	ChannelRoleEnumPrimary             ChannelRoleEnum = "Primary"
)

type ChannelSetAddressAction ¶

type ChannelSetAddressAction struct {
	// Value to set. If empty, any existing value will be removed.
	Address *BaseAddress `json:"address,omitempty"`
}

func (ChannelSetAddressAction) MarshalJSON ¶

func (obj ChannelSetAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelSetAddressCustomFieldAction ¶

type ChannelSetAddressCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// Specifies the format of the value of the Custom Field defined by `name`.
	// If `value` is absent or `null`, this field will be removed, if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	Value interface{} `json:"value,omitempty"`
}

func (ChannelSetAddressCustomFieldAction) MarshalJSON ¶

func (obj ChannelSetAddressCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelSetAddressCustomTypeAction ¶

type ChannelSetAddressCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the `address` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `address`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `address`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (ChannelSetAddressCustomTypeAction) MarshalJSON ¶

func (obj ChannelSetAddressCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelSetCustomFieldAction ¶

type ChannelSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (ChannelSetCustomFieldAction) MarshalJSON ¶

func (obj ChannelSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelSetCustomTypeAction ¶

type ChannelSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the Channel with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Channel.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Channel.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (ChannelSetCustomTypeAction) MarshalJSON ¶

func (obj ChannelSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelSetGeoLocationAction ¶

type ChannelSetGeoLocationAction struct {
	// Value to set.
	GeoLocation GeoJson `json:"geoLocation,omitempty"`
}

func (ChannelSetGeoLocationAction) MarshalJSON ¶

func (obj ChannelSetGeoLocationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ChannelSetGeoLocationAction) UnmarshalJSON ¶

func (obj *ChannelSetGeoLocationAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ChannelSetRolesAction ¶

type ChannelSetRolesAction struct {
	// Value to set. If not specified, then `InventorySupply` is assigned by default.
	Roles []ChannelRoleEnum `json:"roles"`
}

func (ChannelSetRolesAction) MarshalJSON ¶

func (obj ChannelSetRolesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ChannelUpdate ¶

type ChannelUpdate struct {
	// Expected version of the Channel on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the Channel.
	Actions []ChannelUpdateAction `json:"actions"`
}

func (*ChannelUpdate) UnmarshalJSON ¶

func (obj *ChannelUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ChannelUpdateAction ¶

type ChannelUpdateAction interface{}

type ClassificationShippingRateInput ¶

type ClassificationShippingRateInput struct {
	// Key of the value used as a programmatic identifier.
	Key string `json:"key"`
	// Descriptive localized label of the value.
	Label LocalizedString `json:"label"`
}

func (ClassificationShippingRateInput) MarshalJSON ¶

func (obj ClassificationShippingRateInput) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ClassificationShippingRateInputDraft ¶

type ClassificationShippingRateInputDraft struct {
	// Key of the value used as a programmatic identifier.
	Key string `json:"key"`
}

func (ClassificationShippingRateInputDraft) MarshalJSON ¶

func (obj ClassificationShippingRateInputDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type Client ¶

type Client struct {
	// contains filtered or unexported fields
}

func NewClient ¶

func NewClient(cfg *ClientConfig) (*Client, error)

NewClient creates a new client based on the provided ClientConfig

func (*Client) WithProjectKey ¶

func (c *Client) WithProjectKey(projectKey string) *ByProjectKeyRequestBuilder

* * The Project endpoint is used to retrieve certain information from a project.

type ClientConfig ¶

type ClientConfig struct {
	URL         string
	Credentials *clientcredentials.Config
	LogLevel    int
	HTTPClient  *http.Client
	UserAgent   string
}

type ClientLogging ¶

type ClientLogging struct {
	// `id` of the [APIClient](ctp:api:type:ApiClient) which created the resource.
	ClientId *string `json:"clientId,omitempty"`
	// [External user ID](/../api/client-logging#external-user-ids) provided by `X-External-User-ID` HTTP Header.
	ExternalUserId *string `json:"externalUserId,omitempty"`
	// Indicates the [Customer](ctp:api:type:Customer) who modified the resource using a token from the [password flow](/authorization#password-flow).
	Customer *CustomerReference `json:"customer,omitempty"`
	// Indicates that the resource was modified during an [anonymous session](ctp:api:type:AnonymousSession) with the logged ID.
	AnonymousId *string `json:"anonymousId,omitempty"`
}

* * These objects represent information about which [API Client](/../api/projects/api-clients) created or modified a resource. For more information, see [Client Logging](/client-logging). *

type CloudEventsFormat ¶

type CloudEventsFormat struct {
	CloudEventsVersion string `json:"cloudEventsVersion"`
}

* * The CloudEventsFormat can be used with any Destination(#destination), and the payload is delivered in the `JSON Event Format`. AzureEventGridDestination(ctp:api:type:AzureEventGridDestination) offers native support to filter and route CloudEvents. *

func (CloudEventsFormat) MarshalJSON ¶

func (obj CloudEventsFormat) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CloudEventsPayload ¶

type CloudEventsPayload struct {
	// The version of the [CloudEvents](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md) specification which the event uses.
	Specversion string `json:"specversion"`
	// Unique identifier of the event.
	ID string `json:"id"`
	// The `type` is namespaced with `com.commercetools`, followed by the [ReferenceTypeId](ctp:api:type:ReferenceTypeId), the type of Subscription (either `message` or `change`), and the message or change type.
	// For example, `com.commercetools.product.message.ProductPublished` or `com.commercetools.order.change.ResourceCreated`.
	Type string `json:"type"`
	// The default REST URI of the [ReferenceTypeId](ctp:api:type:ReferenceTypeId) that triggered this event, including the project key.
	Source string `json:"source"`
	// Unique identifier of the resource that triggered the event.
	Subject string `json:"subject"`
	// Corresponds to the `lastModifiedAt` of the resource at the time the event was triggered.
	Time time.Time `json:"time"`
	// Corresponds to the `sequenceNumber` of a [MessageSubscription](ctp:api:type:MessageSubscription). Can be used to process messages in the correct order.
	Sequence *string `json:"sequence,omitempty"`
	// `"Integer"`
	Sequencetype *string `json:"sequencetype,omitempty"`
	// The URI from which the message can be retrieved if messages are [enabled](/../api/projects/messages#enable-querying-messages-via-the-api). Only set for [MessageSubscriptions](ctp:api:type:MessageSubscription).
	Dataref *string `json:"dataref,omitempty"`
	// [MessageDeliveryPayload](ctp:api:type:MessageDeliveryPayload), [ResourceCreatedDeliveryPayload](ctp:api:type:ResourceCreatedDeliveryPayload), [ResourceUpdatedDeliveryPayload](ctp:api:type:ResourceUpdatedDeliveryPayload), or [ResourceDeletedDeliveryPayload](ctp:api:type:ResourceDeletedDeliveryPayload).
	Data DeliveryPayload `json:"data"`
}

* * The CloudEventsFormat(ctp:api:type:CloudEventsFormat) represents event data in a way that conforms to a common specification. The message payload can be found inside the `data` field. *

func (CloudEventsPayload) MarshalJSON ¶

func (obj CloudEventsPayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CloudEventsPayload) UnmarshalJSON ¶

func (obj *CloudEventsPayload) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type Company ¶

type Company struct {
	// Unique identifier of the Business Unit.
	ID string `json:"id"`
	// Current version of the Business Unit.
	Version int `json:"version"`
	// Date and time (UTC) the Business Unit was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Business Unit was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources updated after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the Business Unit.
	Key string `json:"key"`
	// Indicates whether the Business Unit can be edited and used in [Orders](/../api/projects/orders).
	Status BusinessUnitStatus `json:"status"`
	// References to [Stores](ctp:api:type:Store) the Business Unit is associated with. Only present when `storeMode` is `Explicit`.
	//
	// If the Business Unit has Stores defined, then all of its [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [Quotes](ctp:api:type:Quote), or [Quote Requests](ctp:api:type:QuoteRequest) must belong to one of the Business Unit's Stores.
	//
	// If the Business Unit has no Stores, then all of its [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [Quotes](ctp:api:type:Quote), or [Quote Requests](ctp:api:type:QuoteRequest) must not belong to any Store.
	Stores []StoreKeyReference `json:"stores"`
	// Is always `Explicit` since a Company cannot have a parent Business Unit that Stores can be inherited from.
	StoreMode BusinessUnitStoreMode `json:"storeMode"`
	// Name of the Business Unit.
	Name string `json:"name"`
	// Email address of the Business Unit.
	ContactEmail *string `json:"contactEmail,omitempty"`
	// Custom Fields for the Business Unit.
	Custom *CustomFields `json:"custom,omitempty"`
	// Addresses used by the Business Unit.
	Addresses []Address `json:"addresses"`
	// Unique identifiers of addresses used as shipping addresses.
	ShippingAddressIds []string `json:"shippingAddressIds"`
	// Unique identifier of the address used as the default shipping address.
	DefaultShippingAddressId *string `json:"defaultShippingAddressId,omitempty"`
	// Unique identifiers of addresses used as billing addresses.
	BillingAddressIds []string `json:"billingAddressIds"`
	// Unique identifier of the address used as the default billing address.
	DefaultBillingAddressId *string `json:"defaultBillingAddressId,omitempty"`
	// Is always `Explicit` since a Company cannot have a parent Business Unit that Associates can be inherited from.
	AssociateMode BusinessUnitAssociateMode `json:"associateMode"`
	// Associates that are part of the Business Unit in specific [roles](ctp:api:type:AssociateRole).
	Associates []Associate `json:"associates"`
	// Associates that are inherited from a parent Business Unit. This value of this field is [eventually consistent](/../api/general-concepts#eventual-consistency) and is only present when the `associateMode` is set to `ExplicitAndFromParent`.
	InheritedAssociates []InheritedAssociate `json:"inheritedAssociates"`
	// Parent unit of the Business Unit. Only present when the `unitType` is `Division`.
	ParentUnit *BusinessUnitKeyReference `json:"parentUnit,omitempty"`
	// Top-level unit of the Business Unit. The top-level unit is of `unitType` `Company`.
	TopLevelUnit BusinessUnitKeyReference `json:"topLevelUnit"`
}

* * Business Unit type to represent the top level of a business. * Contains specific fields and values that differentiate a Company from the generic BusinessUnit(ctp:api:type:BusinessUnit). *

func (Company) MarshalJSON ¶

func (obj Company) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CompanyDraft ¶

type CompanyDraft struct {
	// User-defined unique identifier for the Business Unit.
	Key string `json:"key"`
	// Indicates whether the Business Unit can be edited and used in [Orders](/../api/projects/orders).
	Status *BusinessUnitStatus `json:"status,omitempty"`
	// Sets the [Stores](ctp:api:type:Store) the Business Unit is associated with. Can only be set when `storeMode` is `Explicit`.
	// Defaults to empty for [Companies](ctp:api:type:BusinessUnitType) and not set for [Divisions](ctp:api:type:BusinessUnitType).
	//
	// If the Business Unit has Stores defined, then all of its [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [Quotes](ctp:api:type:Quote), or [Quote Requests](ctp:api:type:QuoteRequest) must belong to one of the Business Unit's Stores.
	//
	// If the Business Unit has no Stores, then all of its [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [Quotes](ctp:api:type:Quote), or [Quote Requests](ctp:api:type:QuoteRequest) must not belong to any Store.
	Stores []StoreResourceIdentifier `json:"stores"`
	// Defines whether the Stores of the Business Unit are set directly on the Business Unit or are inherited from a parent.
	// `storeMode` is always `Explicit` for [Companies](ctp:api:type:BusinessUnitType) and defaults to `FromParent` for [Divisions](ctp:api:type:BusinessUnitType).
	StoreMode *BusinessUnitStoreMode `json:"storeMode,omitempty"`
	// Name of the Business Unit.
	Name string `json:"name"`
	// Email address of the Business Unit.
	ContactEmail *string `json:"contactEmail,omitempty"`
	// Determines whether the Business Unit can inherit Associates from a parent.
	// Always `Explicit` for [Companies](ctp:api:type:BusinessUnitType) and defaults to `ExplicitAndFromParent` for [Divisions](ctp:api:type:BusinessUnitType).
	AssociateMode *BusinessUnitAssociateMode `json:"associateMode,omitempty"`
	// List of members that are part of the Business Unit in specific [roles](ctp:api:type:AssociateRole).
	Associates []AssociateDraft `json:"associates"`
	// Addresses used by the Business Unit.
	Addresses []BaseAddress `json:"addresses"`
	// Indexes of entries in `addresses` to set as shipping addresses.
	// The `shippingAddressIds` of the [Customer](ctp:api:type:Customer) will be replaced by these addresses.
	ShippingAddresses []int `json:"shippingAddresses"`
	// Index of the entry in `addresses` to set as the default shipping address.
	DefaultShippingAddress *int `json:"defaultShippingAddress,omitempty"`
	// Indexes of entries in `addresses` to set as billing addresses.
	// The `billingAddressIds` of the [Customer](ctp:api:type:Customer) will be replaced by these addresses.
	BillingAddresses []int `json:"billingAddresses"`
	// Index of the entry in `addresses` to set as the default billing address.
	DefaultBillingAddress *int `json:"defaultBillingAddress,omitempty"`
	// Custom Fields for the Business Unit.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * Draft type to represent the top level of a business. Contains the fields and values of the generic BusinessUnitDraft(ctp:api:type:BusinessUnitDraft) that are used specifically for creating a Company(ctp:api:type:Company). *

func (CompanyDraft) MarshalJSON ¶

func (obj CompanyDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConcurrentModificationError ¶

type ConcurrentModificationError struct {
	// `"Object $resourceId has a different version than expected. Expected: $expectedVersion - Actual: $currentVersion."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Current version of the resource.
	CurrentVersion *int `json:"currentVersion,omitempty"`
}

* * Returned when the request conflicts with the current state of the involved resources. Typically, the request attempts to modify a resource that is out of date (that is modified by another client since it was last retrieved). * The client application should resolve the conflict (with or without involving the end-user) before retrying the request. *

func (*ConcurrentModificationError) DecodeStruct ¶

func (obj *ConcurrentModificationError) DecodeStruct(src map[string]interface{}) error

func (ConcurrentModificationError) Error ¶

func (obj ConcurrentModificationError) Error() string

func (ConcurrentModificationError) MarshalJSON ¶

func (obj ConcurrentModificationError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ConcurrentModificationError) UnmarshalJSON ¶

func (obj *ConcurrentModificationError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ConfluentCloudDestination ¶

type ConfluentCloudDestination struct {
	// URL to the bootstrap server including the port number in the format `<xxxxx>.<region>.<provider>.confluent.cloud:9092`.
	BootstrapServer string `json:"bootstrapServer"`
	// Partially hidden on retrieval for security reasons.
	ApiKey string `json:"apiKey"`
	// Partially hidden on retrieval for security reasons.
	ApiSecret string `json:"apiSecret"`
	// The Kafka `acks` value. Can be `"0"`, `"1"`, or `"all"`.
	Acks string `json:"acks"`
	// The name of the topic.
	Topic string `json:"topic"`
	// The Kafka record key.
	Key *string `json:"key,omitempty"`
}

* * This destination can be used to push events and messages to [Confluent Cloud](https://www.confluent.io/confluent-cloud/). * To set up a Subscription of this type, first, create a topic in Confluent Cloud. * Then, to allow Composable Commerce to push events and messages to your topic, generate [API keys](https://docs.confluent.io/cloud/current/access-management/authenticate/api-keys/api-keys.html) for your topic, and create the Subscription destination using the generated credentials. * * The Composable Commerce producer uses the following values: `SASL_SSL` for`security.protocol`, `PLAIN` for`sasl.mechanism`, and the default value (1048576) for `max.request.size`. *

func (ConfluentCloudDestination) MarshalJSON ¶

func (obj ConfluentCloudDestination) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ContainerAndKey ¶

type ContainerAndKey struct {
	// User-defined identifier that is unique within the given container.
	Key string `json:"key"`
	// Namespace to group [Custom Objects](ctp:api:type:CustomObject).
	Container string `json:"container"`
}

* * `ContainerAndKey` is specific to [Custom Objects](ctp:api:type:CustomObject). Custom Objects are grouped into containers, which can be used like namespaces. Within a given container, a user-defined key can be used to uniquely identify resources. *

type CountryNotConfiguredInStoreError ¶

type CountryNotConfiguredInStoreError struct {
	// `"The country $country is not configured for the store $store."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Countries configured for the Store.
	StoreCountries []string `json:"storeCountries"`
	// The country that is not configured for the Store but referenced on the Cart or Order.
	Country string `json:"country"`
}

* * Returned when a Cart(ctp:api:type:Cart) or an Order(ctp:api:type:Order) in a Store(ctp:api:type:Store) references a country that is not included in the countries configured for the Store. * * The error is returned as a failed response to: * * - [Create Cart in Store](ctp:api:endpoint:/{projectKey}/in-store/carts:POST) request and [Set Country](ctp:api:type:CartSetCountryAction) update action on Carts. * - [Create Cart in Store](ctp:api:endpoint:/{projectKey}/in-store/me/carts:POST) request and [Set Country](ctp:api:type:MyCartSetCountryAction) update action on My Carts. * - [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests on Orders. * - [Create Order from Cart in a Store](ctp:api:endpoint:/{projectKey}/in-store/me/orders:POST) requests on My Orders. * - [Create Order from Quote](ctp:api:endpoint:/{projectKey}/orders/quotes:POST) requests on Orders. * - [Create Order from Quote](ctp:api:endpoint:/{projectKey}/me/orders/quotes:POST) requests on My Orders. * - [Create Order by Import](ctp:api:endpoint:/{projectKey}/orders/import:POST) request on Order Import. * - [Set Country](ctp:api:type:StagedOrderSetCountryAction) on Order Edits. *

func (*CountryNotConfiguredInStoreError) DecodeStruct ¶

func (obj *CountryNotConfiguredInStoreError) DecodeStruct(src map[string]interface{}) error

func (CountryNotConfiguredInStoreError) Error ¶

func (CountryNotConfiguredInStoreError) MarshalJSON ¶

func (obj CountryNotConfiguredInStoreError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CountryNotConfiguredInStoreError) UnmarshalJSON ¶

func (obj *CountryNotConfiguredInStoreError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CreatedBy ¶

type CreatedBy struct {
	// `id` of the [APIClient](ctp:api:type:ApiClient) which created the resource.
	ClientId *string `json:"clientId,omitempty"`
	// [External user ID](/../api/client-logging#external-user-ids) provided by `X-External-User-ID` HTTP Header.
	ExternalUserId *string `json:"externalUserId,omitempty"`
	// Indicates the [Customer](ctp:api:type:Customer) who created the resource using a token from the [password flow](/authorization#password-flow).
	Customer *CustomerReference `json:"customer,omitempty"`
	// Indicates the [anonymous session](ctp:api:type:AnonymousSession) during which the resource was created.
	AnonymousId *string `json:"anonymousId,omitempty"`
}

* * Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).

type CustomFieldBooleanType ¶

type CustomFieldBooleanType struct {
}

* * Field type for Boolean values. *

func (CustomFieldBooleanType) MarshalJSON ¶

func (obj CustomFieldBooleanType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomFieldDateTimeType ¶

type CustomFieldDateTimeType struct {
}

* * Field type for [DateTime](ctp:api:type:DateTime) values. *

func (CustomFieldDateTimeType) MarshalJSON ¶

func (obj CustomFieldDateTimeType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomFieldDateType ¶

type CustomFieldDateType struct {
}

* * Field type for Date(ctp:api:type:Date) values. *

func (CustomFieldDateType) MarshalJSON ¶

func (obj CustomFieldDateType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomFieldEnumType ¶

type CustomFieldEnumType struct {
	// Allowed values.
	Values []CustomFieldEnumValue `json:"values"`
}

* * Field type for enum values. *

func (CustomFieldEnumType) MarshalJSON ¶

func (obj CustomFieldEnumType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomFieldEnumValue ¶

type CustomFieldEnumValue struct {
	// Key of the value used as a programmatic identifier.
	Key string `json:"key"`
	// Descriptive label of the value.
	Label string `json:"label"`
}

* * Defines an allowed value of a CustomFieldEnumType(ctp:api:type:CustomFieldEnumType) field. *

type CustomFieldLocalizedEnumType ¶

type CustomFieldLocalizedEnumType struct {
	// Allowed values.
	Values []CustomFieldLocalizedEnumValue `json:"values"`
}

* * Field type for localized enum values. *

func (CustomFieldLocalizedEnumType) MarshalJSON ¶

func (obj CustomFieldLocalizedEnumType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomFieldLocalizedEnumValue ¶

type CustomFieldLocalizedEnumValue struct {
	// Key of the value used as a programmatic identifier.
	Key string `json:"key"`
	// Descriptive localized label of the value.
	Label LocalizedString `json:"label"`
}

* * Defines an allowed value of a CustomFieldLocalizedEnumType(ctp:api:type:CustomFieldLocalizedEnumType) field. *

type CustomFieldLocalizedStringType ¶

type CustomFieldLocalizedStringType struct {
}

* * Field type for LocalizedString(ctp:api:type:LocalizedString) values. *

func (CustomFieldLocalizedStringType) MarshalJSON ¶

func (obj CustomFieldLocalizedStringType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomFieldMoneyType ¶

type CustomFieldMoneyType struct {
}

* * Field type for CentPrecisionMoney(ctp:api:type:CentPrecisionMoney) values. *

func (CustomFieldMoneyType) MarshalJSON ¶

func (obj CustomFieldMoneyType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomFieldNumberType ¶

type CustomFieldNumberType struct {
}

* * Field type for number values. *

func (CustomFieldNumberType) MarshalJSON ¶

func (obj CustomFieldNumberType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomFieldReferenceType ¶

type CustomFieldReferenceType struct {
	// Resource type the Custom Field can reference.
	ReferenceTypeId CustomFieldReferenceValue `json:"referenceTypeId"`
}

* * Field type for Reference(ctp:api:type:Reference) values. *

func (CustomFieldReferenceType) MarshalJSON ¶

func (obj CustomFieldReferenceType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomFieldReferenceValue ¶

type CustomFieldReferenceValue string

* * Defines which resource type a CustomFieldReferenceType(ctp:api:type:CustomFieldReferenceType) can reference. *

const (
	CustomFieldReferenceValueAssociateRole    CustomFieldReferenceValue = "associate-role"
	CustomFieldReferenceValueBusinessUnit     CustomFieldReferenceValue = "business-unit"
	CustomFieldReferenceValueCart             CustomFieldReferenceValue = "cart"
	CustomFieldReferenceValueCategory         CustomFieldReferenceValue = "category"
	CustomFieldReferenceValueChannel          CustomFieldReferenceValue = "channel"
	CustomFieldReferenceValueCustomer         CustomFieldReferenceValue = "customer"
	CustomFieldReferenceValueKeyValueDocument CustomFieldReferenceValue = "key-value-document"
	CustomFieldReferenceValueOrder            CustomFieldReferenceValue = "order"
	CustomFieldReferenceValueProduct          CustomFieldReferenceValue = "product"
	CustomFieldReferenceValueProductType      CustomFieldReferenceValue = "product-type"
	CustomFieldReferenceValueReview           CustomFieldReferenceValue = "review"
	CustomFieldReferenceValueState            CustomFieldReferenceValue = "state"
	CustomFieldReferenceValueShippingMethod   CustomFieldReferenceValue = "shipping-method"
	CustomFieldReferenceValueZone             CustomFieldReferenceValue = "zone"
)

type CustomFieldSetType ¶

type CustomFieldSetType struct {
	// Field type of the elements in the set.
	ElementType FieldType `json:"elementType"`
}

* * Values of a SetType Custom Field are sets of values of the specified `elementType` (without duplicate elements). *

func (CustomFieldSetType) MarshalJSON ¶

func (obj CustomFieldSetType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomFieldSetType) UnmarshalJSON ¶

func (obj *CustomFieldSetType) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomFieldStringType ¶

type CustomFieldStringType struct {
}

* * Field type for string values. *

func (CustomFieldStringType) MarshalJSON ¶

func (obj CustomFieldStringType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomFieldTimeType ¶

type CustomFieldTimeType struct {
}

* * Field type for [Time](ctp:api:type:Time) values. *

func (CustomFieldTimeType) MarshalJSON ¶

func (obj CustomFieldTimeType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomFields ¶

type CustomFields struct {
	// Reference to the [Type](ctp:api:type:Type) that holds the [FieldDefinitions](ctp:api:type:FieldDefinition) for the Custom Fields.
	Type TypeReference `json:"type"`
	// Object containing the Custom Fields for the [customized resource or data type](/../api/projects/types#list-of-customizable-data-types).
	Fields FieldContainer `json:"fields"`
}

* * Serves as value of the `custom` field on a resource or data type customized with a Type(ctp:api:type:Type). *

type CustomFieldsDraft ¶

type CustomFieldsDraft struct {
	// `id` or `key` of the [Type](ctp:api:type:Type).
	Type TypeResourceIdentifier `json:"type"`
	// Object containing the Custom Fields for the [customized resource or data type](/../api/projects/types#list-of-customizable-data-types).
	Fields *FieldContainer `json:"fields,omitempty"`
}

* * The representation used when creating or updating a [customizable data type](/../api/projects/types#list-of-customizable-data-types) with Custom Fields. *

type CustomLineItem ¶

type CustomLineItem struct {
	// Unique identifier of the Custom Line Item.
	ID string `json:"id"`
	// Name of the Custom Line Item.
	Name LocalizedString `json:"name"`
	// Money value of the Custom Line Item.
	Money TypedMoney `json:"money"`
	// Automatically set after the `taxRate` is set.
	TaxedPrice *TaxedItemPrice `json:"taxedPrice,omitempty"`
	// Total price of the Custom Line Item (`money` multiplied by `quantity`).
	// If the Custom Line Item is discounted, the total price is `discountedPricePerQuantity` multiplied by `quantity`.
	//
	// Includes taxes if the [TaxRate](ctp:api:type:TaxRate) `includedInPrice` is `true`.
	TotalPrice CentPrecisionMoney `json:"totalPrice"`
	// User-defined identifier used in a deep-link URL for the Custom Line Item.
	// It matches the pattern `[a-zA-Z0-9_-]{2,256}`.
	Slug string `json:"slug"`
	// Number of Custom Line Items in the Cart.
	Quantity int `json:"quantity"`
	// State of the Custom Line Item in the Cart.
	State []ItemState `json:"state"`
	// Used to select a Tax Rate when a Cart has the `Platform` [TaxMode](ctp:api:type:TaxMode).
	TaxCategory *TaxCategoryReference `json:"taxCategory,omitempty"`
	// - For a Cart with `Platform` [TaxMode](ctp:api:type:TaxMode), the `taxRate` of Custom Line Items is set automatically once a shipping address is set. The rate is based on the [TaxCategory](ctp:api:type:TaxCategory) that applies for the shipping address.
	// - For a Cart with `External` TaxMode, the `taxRate` of Custom Line Items can be set using [ExternalTaxRateDraft](ctp:api:type:ExternalTaxRateDraft).
	TaxRate *TaxRate `json:"taxRate,omitempty"`
	// Discounted price of a single quantity of the Custom Line Item.
	DiscountedPricePerQuantity []DiscountedLineItemPriceForQuantity `json:"discountedPricePerQuantity"`
	// Custom Fields of the Custom Line Item.
	Custom *CustomFields `json:"custom,omitempty"`
	// Container for Custom Line Item-specific addresses.
	ShippingDetails *ItemShippingDetails `json:"shippingDetails,omitempty"`
	// Indicates whether Cart Discounts with a matching [CartDiscountCustomLineItemsTarget](ctp:api:type:CartDiscountCustomLineItemsTarget) are applied to the Custom Line Item.
	PriceMode CustomLineItemPriceMode `json:"priceMode"`
}

* * A generic item that can be added to the Cart but is not bound to a Product that can be used for discounts (negative money), vouchers, complex cart rules, additional services, or fees. * You control the lifecycle of this item. *

func (*CustomLineItem) UnmarshalJSON ¶

func (obj *CustomLineItem) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomLineItemDraft ¶

type CustomLineItemDraft struct {
	// Name of the Custom Line Item.
	Name LocalizedString `json:"name"`
	// Number of Custom Line Items to add to the Cart.
	Quantity *int `json:"quantity,omitempty"`
	// Money value of the Custom Line Item.
	// The value can be negative.
	Money Money `json:"money"`
	// User-defined identifier used in a deep-link URL for the Custom Line Item.
	// It must match the pattern `[a-zA-Z0-9_-]{2,256}`.
	Slug string `json:"slug"`
	// Used to select a Tax Rate when a Cart has the `Platform` [TaxMode](ctp:api:type:TaxMode).
	// This field is required for `Platform` [TaxMode](ctp:api:type:TaxMode).
	TaxCategory *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
	// External Tax Rate for the Custom Line Item if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	// Custom Fields for the Custom Line Item.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Container for Custom Line Item-specific addresses.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
	// - If `Standard`, Cart Discounts with a matching [CartDiscountCustomLineItemsTarget](ctp:api:type:CartDiscountCustomLineItemsTarget)
	// are applied to the Custom Line Item.
	// - If `External`, Cart Discounts are not considered on the Custom Line Item.
	PriceMode CustomLineItemPriceMode `json:"priceMode"`
}

type CustomLineItemImportDraft ¶

type CustomLineItemImportDraft struct {
	Name LocalizedString `json:"name"`
	// The amount of a CustomLineItem in the cart.
	// Must be a positive integer.
	Quantity int `json:"quantity"`
	// The cost to add to the cart. The amount can be negative.
	Money       Money                          `json:"money"`
	Slug        string                         `json:"slug"`
	State       []ItemState                    `json:"state"`
	TaxRate     *TaxRate                       `json:"taxRate,omitempty"`
	TaxCategory *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
	// The custom fields.
	Custom          *CustomFieldsDraft        `json:"custom,omitempty"`
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
	// - If `Standard`, Cart Discounts with a matching [CartDiscountCustomLineItemsTarget](ctp:api:type:CartDiscountCustomLineItemsTarget)
	// are applied to the Custom Line Item.
	// - If `External`, Cart Discounts are not considered on the Custom Line Item.
	PriceMode CustomLineItemPriceMode `json:"priceMode"`
}

func (CustomLineItemImportDraft) MarshalJSON ¶

func (obj CustomLineItemImportDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomLineItemPriceMode ¶

type CustomLineItemPriceMode string

* * Determines if Cart Discounts can be applied to a Custom Line Item in the Cart. *

const (
	CustomLineItemPriceModeStandard CustomLineItemPriceMode = "Standard"
	CustomLineItemPriceModeExternal CustomLineItemPriceMode = "External"
)

type CustomLineItemReturnItem ¶

type CustomLineItemReturnItem struct {
	// Unique identifier of the ReturnItem.
	ID            string              `json:"id"`
	Quantity      int                 `json:"quantity"`
	Comment       *string             `json:"comment,omitempty"`
	ShipmentState ReturnShipmentState `json:"shipmentState"`
	PaymentState  ReturnPaymentState  `json:"paymentState"`
	// Custom Fields of this return item.
	Custom           *CustomFields `json:"custom,omitempty"`
	LastModifiedAt   time.Time     `json:"lastModifiedAt"`
	CreatedAt        time.Time     `json:"createdAt"`
	CustomLineItemId string        `json:"customLineItemId"`
}

func (CustomLineItemReturnItem) MarshalJSON ¶

func (obj CustomLineItemReturnItem) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomLineItemStateTransitionMessage ¶

type CustomLineItemStateTransitionMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Custom Line Item](ctp:api:type:CustomLineItem).
	CustomLineItemId string `json:"customLineItemId"`
	// Date and time (UTC) when the transition of the [Custom Line Item](ctp:api:type:CustomLineItem) [State](ctp:api:type:State) was performed.
	TransitionDate time.Time `json:"transitionDate"`
	// Number of [Custom Line Items](ctp:api:type:CustomLineItem) for which the [State](ctp:api:type:State) was transitioned.
	Quantity int `json:"quantity"`
	// [State](ctp:api:type:State) the [Custom Line Item](ctp:api:type:CustomLineItem) was transitioned from.
	FromState StateReference `json:"fromState"`
	// [State](ctp:api:type:State) the [Custom Line Item](ctp:api:type:CustomLineItem) was transitioned to.
	ToState StateReference `json:"toState"`
}

* * Generated after a successful [Transition Custom Line Item State](ctp:api:type:OrderTransitionCustomLineItemStateAction) update action. *

func (CustomLineItemStateTransitionMessage) MarshalJSON ¶

func (obj CustomLineItemStateTransitionMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomLineItemStateTransitionMessage) UnmarshalJSON ¶

func (obj *CustomLineItemStateTransitionMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomLineItemStateTransitionMessagePayload ¶

type CustomLineItemStateTransitionMessagePayload struct {
	// Unique identifier of the [Custom Line Item](ctp:api:type:CustomLineItem).
	CustomLineItemId string `json:"customLineItemId"`
	// Date and time (UTC) when the transition of the [Custom Line Item](ctp:api:type:CustomLineItem) [State](ctp:api:type:State) was performed.
	TransitionDate time.Time `json:"transitionDate"`
	// Number of [Custom Line Items](ctp:api:type:CustomLineItem) for which the [State](ctp:api:type:State) was transitioned.
	Quantity int `json:"quantity"`
	// [State](ctp:api:type:State) the [Custom Line Item](ctp:api:type:CustomLineItem) was transitioned from.
	FromState StateReference `json:"fromState"`
	// [State](ctp:api:type:State) the [Custom Line Item](ctp:api:type:CustomLineItem) was transitioned to.
	ToState StateReference `json:"toState"`
}

* * Generated after a successful [Transition Custom Line Item State](ctp:api:type:OrderTransitionCustomLineItemStateAction) update action. *

func (CustomLineItemStateTransitionMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomObject ¶

type CustomObject struct {
	// Unique identifier of the CustomObject.
	ID string `json:"id"`
	// Current version of the CustomObject.
	Version int `json:"version"`
	// Date and time (UTC) the CustomObject was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the CustomObject was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Namespace to group CustomObjects.
	Container string `json:"container"`
	// User-defined unique identifier of the CustomObject within the defined `container`.
	Key string `json:"key"`
	// JSON standard types Number, String, Boolean, Array, Object, and [common API data types](/../api/types).
	// For values of type [Reference](ctp:api:type:Reference) the integrity of the data is not guaranteed.
	// If the referenced object is deleted, the API does not delete the corresponding reference to it and the `value` points to a non-existing object in such case.
	Value interface{} `json:"value"`
}

type CustomObjectDraft ¶

type CustomObjectDraft struct {
	// Namespace to group CustomObjects.
	Container string `json:"container"`
	// User-defined unique identifier of the CustomObject within the defined `container`.
	Key string `json:"key"`
	// JSON standard types Number, String, Boolean, Array, Object, and [common API data types](/../api/types).
	// For values of type [Reference](ctp:api:type:Reference) the integrity of the data is not guaranteed.
	// If the referenced object is deleted, the API does not delete the corresponding reference to it and the `value` points to a non-existing object in such case.
	Value interface{} `json:"value"`
	// Current version of the CustomObject.
	Version *int `json:"version,omitempty"`
}

type CustomObjectPagedQueryResponse ¶

type CustomObjectPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// The total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [CustomObjects](ctp:api:type:CustomObject) matching the query.
	Results []CustomObject `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of CustomObject(ctp:api:type:CustomObject). *

type CustomObjectReference ¶

type CustomObjectReference struct {
	// Unique identifier of the referenced [CustomObject](ctp:api:type:CustomObject).
	ID string `json:"id"`
	// Contains the representation of the expanded CustomObject. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for CustomObjects.
	Obj *CustomObject `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a CustomObject(ctp:api:type:CustomObject). *

func (CustomObjectReference) MarshalJSON ¶

func (obj CustomObjectReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomShippingDraft ¶

type CustomShippingDraft struct {
	// User-defined unique identifier of the custom Shipping Method in the Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	Key string `json:"key"`
	// Name of the custom Shipping Method.
	ShippingMethodName string `json:"shippingMethodName"`
	// Determines the shipping rate and Tax Rate of the associated Line Items.
	ShippingAddress *BaseAddress `json:"shippingAddress,omitempty"`
	// Determines the shipping price.
	ShippingRate ShippingRateDraft `json:"shippingRate"`
	// Input used to select a [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	// The data type of this field depends on the `shippingRateInputType.type` configured in the [Project](ctp:api:type:Project):
	//
	// - If `CartClassification`, it must be [ClassificationShippingRateInputDraft](ctp:api:type:ClassificationShippingRateInputDraft).
	// - If `CartScore`, it must be [ScoreShippingRateInputDraft](ctp:api:type:ScoreShippingRateInputDraft).
	// - If `CartValue`, it cannot be set.
	ShippingRateInput ShippingRateInputDraft `json:"shippingRateInput,omitempty"`
	// Tax Category used to determine a shipping Tax Rate if the Cart has the `Platform` [TaxMode](ctp:api:type:TaxMode).
	TaxCategory *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
	// Tax Rate used to tax a shipping expense if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	// Deliveries to be shipped with the custom Shipping Method.
	Deliveries []DeliveryDraft `json:"deliveries"`
	// Custom Fields for the custom Shipping Method.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (CustomShippingDraft) MarshalJSON ¶

func (obj CustomShippingDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomShippingDraft) UnmarshalJSON ¶

func (obj *CustomShippingDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomTokenizer ¶

type CustomTokenizer struct {
	// Contains custom tokens.
	Inputs []string `json:"inputs"`
}

* * Define arbitrary tokens that are used to match the input. *

func (CustomTokenizer) MarshalJSON ¶

func (obj CustomTokenizer) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type Customer ¶

type Customer struct {
	// Unique identifier of the Customer.
	ID string `json:"id"`
	// Current version of the Customer.
	Version int `json:"version"`
	// Date and time (UTC) the Customer was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Customer was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// User-defined unique identifier of the Customer.
	Key *string `json:"key,omitempty"`
	// User-defined unique identifier of the Customer.
	//
	// Can be used to refer to a Customer in a human-readable way (in emails, invoices, and other correspondence).
	CustomerNumber *string `json:"customerNumber,omitempty"`
	// Optional identifier for use in external systems like Customer Relationship Management (CRM) or Enterprise Resource Planning (ERP).
	ExternalId *string `json:"externalId,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Email address of the Customer that is [unique](/../api/customers-overview#customer-uniqueness) for an entire Project or to a Store the Customer is assigned to.
	// It is the mandatory unique identifier of a Customer.
	Email string `json:"email"`
	// Present only when `authenticationMode` is set to `Password`.
	Password *string `json:"password,omitempty"`
	// Given name (first name) of the Customer.
	FirstName *string `json:"firstName,omitempty"`
	// Family name (last name) of the Customer.
	LastName *string `json:"lastName,omitempty"`
	// Middle name of the Customer.
	MiddleName *string `json:"middleName,omitempty"`
	// Title of the Customer, for example, 'Dr.'.
	Title *string `json:"title,omitempty"`
	// Date of birth of the Customer.
	DateOfBirth *Date `json:"dateOfBirth,omitempty"`
	// Company name of the Customer.
	CompanyName *string `json:"companyName,omitempty"`
	// Individual VAT ID of the Customer.
	VatId *string `json:"vatId,omitempty"`
	// Addresses used by the Customer.
	Addresses []Address `json:"addresses"`
	// ID of the address in `addresses` used as the default shipping address.
	DefaultShippingAddressId *string `json:"defaultShippingAddressId,omitempty"`
	// IDs of addresses in `addresses` used as shipping addresses.
	ShippingAddressIds []string `json:"shippingAddressIds"`
	// ID of the address in `addresses` used as the default billing address.
	DefaultBillingAddressId *string `json:"defaultBillingAddressId,omitempty"`
	// IDs of addresses in `addresses` used as billing addresses.
	BillingAddressIds []string `json:"billingAddressIds"`
	// Indicates whether the email address of the Customer is [verified](#email-verification-of-customer).
	IsEmailVerified bool `json:"isEmailVerified"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) to which the Customer belongs.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// Custom Fields for the Customer.
	Custom *CustomFields `json:"custom,omitempty"`
	// Preferred language of the Customer.
	Locale *string `json:"locale,omitempty"`
	// Salutation of the Customer, for example, 'Mr.' or 'Mrs.'.
	Salutation *string `json:"salutation,omitempty"`
	// [Stores](ctp:api:type:Store) to which the Customer is assigned to.
	//
	// - If no Stores are specified, the Customer is a global customer, and can log in using the [Password Flow for global Customers](/../api/authorization#password-flow-for-global-customers).
	// - If any Stores are specified, the Customer can only log in using the [Password Flow for Customers in a Store](/../api/authorization#password-flow-for-customers-in-a-store) for those specific Stores.
	Stores []StoreKeyReference `json:"stores"`
	// Indicates whether the `password` is required for the Customer.
	AuthenticationMode AuthenticationMode `json:"authenticationMode"`
}

* * If `stores` is not empty, the Customer is specific to those Stores. *

func (Customer) MarshalJSON ¶

func (obj Customer) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerAddAddressAction ¶

type CustomerAddAddressAction struct {
	// Value to append to the `addresses` array.
	Address BaseAddress `json:"address"`
}

* * Adding an address to the Customer produces the [CustomerAddressAdded](ctp:api:type:CustomerAddressAddedMessage) Message. *

func (CustomerAddAddressAction) MarshalJSON ¶

func (obj CustomerAddAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerAddBillingAddressIdAction ¶

type CustomerAddBillingAddressIdAction struct {
	// `id` of the [Address](ctp:api:type:Address) to become a billing address.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to become a billing address.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Adds an Address from the `addresses` array to `billingAddressIds`. Either `addressId` or `addressKey` is required. *

func (CustomerAddBillingAddressIdAction) MarshalJSON ¶

func (obj CustomerAddBillingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerAddShippingAddressIdAction ¶

type CustomerAddShippingAddressIdAction struct {
	// `id` of the [Address](ctp:api:type:Address) to become a shipping address.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to become a shipping address.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Adds an Address from the `addresses` array to `shippingAddressIds`. Either `addressId` or `addressKey` is required. *

func (CustomerAddShippingAddressIdAction) MarshalJSON ¶

func (obj CustomerAddShippingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerAddStoreAction ¶

type CustomerAddStoreAction struct {
	// ResourceIdentifier of the Store to add.
	Store StoreResourceIdentifier `json:"store"`
}

* * Associates the Customer with a Store. *

func (CustomerAddStoreAction) MarshalJSON ¶

func (obj CustomerAddStoreAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerAddressAddedMessage ¶

type CustomerAddressAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Address](ctp:api:type:Address) that was added during the [Add Address](ctp:api:type:CustomerAddAddressAction) update action.
	Address Address `json:"address"`
}

* * Generated after a successful [Add Address](ctp:api:type:CustomerAddAddressAction) update action. *

func (CustomerAddressAddedMessage) MarshalJSON ¶

func (obj CustomerAddressAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerAddressAddedMessage) UnmarshalJSON ¶

func (obj *CustomerAddressAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerAddressAddedMessagePayload ¶

type CustomerAddressAddedMessagePayload struct {
	// [Address](ctp:api:type:Address) that was added during the [Add Address](ctp:api:type:CustomerAddAddressAction) update action.
	Address Address `json:"address"`
}

* * Generated after a successful [Add Address](ctp:api:type:CustomerAddAddressAction) update action. *

func (CustomerAddressAddedMessagePayload) MarshalJSON ¶

func (obj CustomerAddressAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerAddressChangedMessage ¶

type CustomerAddressChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Address](ctp:api:type:Address) that was set during the [Change Address](ctp:api:type:CustomerChangeAddressAction) update action.
	Address Address `json:"address"`
}

* * Generated after a successful [Change Address](ctp:api:type:CustomerChangeAddressAction) update action. *

func (CustomerAddressChangedMessage) MarshalJSON ¶

func (obj CustomerAddressChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerAddressChangedMessage) UnmarshalJSON ¶

func (obj *CustomerAddressChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerAddressChangedMessagePayload ¶

type CustomerAddressChangedMessagePayload struct {
	// [Address](ctp:api:type:Address) that was set during the [Change Address](ctp:api:type:CustomerChangeAddressAction) update action.
	Address Address `json:"address"`
}

* * Generated after a successful [Change Address](ctp:api:type:CustomerChangeAddressAction) update action. *

func (CustomerAddressChangedMessagePayload) MarshalJSON ¶

func (obj CustomerAddressChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerAddressRemovedMessage ¶

type CustomerAddressRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Address](ctp:api:type:Address) that was removed during the [Remove Address](ctp:api:type:CustomerRemoveAddressAction) update action.
	Address Address `json:"address"`
}

* * Generated after a successful [Remove Address](ctp:api:type:CustomerRemoveAddressAction) update action. *

func (CustomerAddressRemovedMessage) MarshalJSON ¶

func (obj CustomerAddressRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerAddressRemovedMessage) UnmarshalJSON ¶

func (obj *CustomerAddressRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerAddressRemovedMessagePayload ¶

type CustomerAddressRemovedMessagePayload struct {
	// [Address](ctp:api:type:Address) that was removed during the [Remove Address](ctp:api:type:CustomerRemoveAddressAction) update action.
	Address Address `json:"address"`
}

* * Generated after a successful [Remove Address](ctp:api:type:CustomerRemoveAddressAction) update action. *

func (CustomerAddressRemovedMessagePayload) MarshalJSON ¶

func (obj CustomerAddressRemovedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerChangeAddressAction ¶

type CustomerChangeAddressAction struct {
	// `id` of the [Address](ctp:api:type:Address) to change.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to change.
	AddressKey *string `json:"addressKey,omitempty"`
	// Value to set.
	Address BaseAddress `json:"address"`
}

* * Changing an address of the Customer produces the [CustomerAddressChanged](ctp:api:type:CustomerAddressChangedMessage) Message. * * Either `addressId` or `addressKey` is required. *

func (CustomerChangeAddressAction) MarshalJSON ¶

func (obj CustomerChangeAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerChangeEmailAction ¶

type CustomerChangeEmailAction struct {
	// Value to set.
	Email string `json:"email"`
}

* * Changing the email of the Customer produces the [CustomerEmailChanged](ctp:api:type:CustomerEmailChangedMessage) Message. *

func (CustomerChangeEmailAction) MarshalJSON ¶

func (obj CustomerChangeEmailAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerChangePassword ¶

type CustomerChangePassword struct {
	// Unique identifier of the Customer.
	ID string `json:"id"`
	// Expected version of the Customer on which the changes should be applied.
	Version int `json:"version"`
	// Current password of the Customer.
	//
	// If the current password does not match, an [InvalidCurrentPassword](ctp:api:type:InvalidCurrentPasswordError) error is returned.
	CurrentPassword string `json:"currentPassword"`
	// New password to be set.
	NewPassword string `json:"newPassword"`
}

type CustomerCompanyNameSetMessage ¶

type CustomerCompanyNameSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The `companyName` that was set during the [Set Company Name](ctp:api:type:CustomerSetCompanyNameAction) update action.
	CompanyName *string `json:"companyName,omitempty"`
}

* * Generated after a successful [Set Company Name](ctp:api:type:CustomerSetCompanyNameAction) update action. *

func (CustomerCompanyNameSetMessage) MarshalJSON ¶

func (obj CustomerCompanyNameSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerCompanyNameSetMessage) UnmarshalJSON ¶

func (obj *CustomerCompanyNameSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerCompanyNameSetMessagePayload ¶

type CustomerCompanyNameSetMessagePayload struct {
	// The `companyName` that was set during the [Set Company Name](ctp:api:type:CustomerSetCompanyNameAction) update action.
	CompanyName *string `json:"companyName,omitempty"`
}

* * Generated after a successful [Set Company Name](ctp:api:type:CustomerSetCompanyNameAction) update action. *

func (CustomerCompanyNameSetMessagePayload) MarshalJSON ¶

func (obj CustomerCompanyNameSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerCreateEmailToken ¶

type CustomerCreateEmailToken struct {
	// Unique identifier of the Customer.
	ID string `json:"id"`
	// Expected version of the Customer.
	Version *int `json:"version,omitempty"`
	// Validity period of the generated token in minutes.
	TtlMinutes int `json:"ttlMinutes"`
}

type CustomerCreatePasswordResetToken ¶

type CustomerCreatePasswordResetToken struct {
	// Email address of the Customer treated as [case-insensitive](/../api/customers-overview#email-case-insensitivity).
	Email string `json:"email"`
	// Validity period of the generated token in minutes.
	TtlMinutes *int `json:"ttlMinutes,omitempty"`
}

type CustomerCreatedMessage ¶

type CustomerCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Customer](ctp:api:type:Customer) that was created.
	Customer Customer `json:"customer"`
}

* * Generated after a successful [Create Customer](/../api/projects/customers#create-sign-up-customer) request. *

func (CustomerCreatedMessage) MarshalJSON ¶

func (obj CustomerCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerCreatedMessage) UnmarshalJSON ¶

func (obj *CustomerCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerCreatedMessagePayload ¶

type CustomerCreatedMessagePayload struct {
	// [Customer](ctp:api:type:Customer) that was created.
	Customer Customer `json:"customer"`
}

* * Generated after a successful [Create Customer](/../api/projects/customers#create-sign-up-customer) request. *

func (CustomerCreatedMessagePayload) MarshalJSON ¶

func (obj CustomerCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerDateOfBirthSetMessage ¶

type CustomerDateOfBirthSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The `dateOfBirth` that was set during the [Set Date of Birth](ctp:api:type:CustomerSetDateOfBirthAction) update action.
	DateOfBirth *Date `json:"dateOfBirth,omitempty"`
}

* * Generated after a successful [Set Date of Birth](ctp:api:type:CustomerSetDateOfBirthAction) update action. *

func (CustomerDateOfBirthSetMessage) MarshalJSON ¶

func (obj CustomerDateOfBirthSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerDateOfBirthSetMessage) UnmarshalJSON ¶

func (obj *CustomerDateOfBirthSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerDateOfBirthSetMessagePayload ¶

type CustomerDateOfBirthSetMessagePayload struct {
	// The `dateOfBirth` that was set during the [Set Date of Birth](ctp:api:type:CustomerSetDateOfBirthAction) update action.
	DateOfBirth *Date `json:"dateOfBirth,omitempty"`
}

* * Generated after a successful [Set Date of Birth](ctp:api:type:CustomerSetDateOfBirthAction) update action. *

func (CustomerDateOfBirthSetMessagePayload) MarshalJSON ¶

func (obj CustomerDateOfBirthSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerDeletedMessage ¶

type CustomerDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
}

* * Generated after a successful [Delete Customer](/../api/projects/customers#delete-customer) request. *

func (CustomerDeletedMessage) MarshalJSON ¶

func (obj CustomerDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerDeletedMessage) UnmarshalJSON ¶

func (obj *CustomerDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerDeletedMessagePayload ¶

type CustomerDeletedMessagePayload struct {
}

* * Generated after a successful [Delete Customer](/../api/projects/customers#delete-customer) request. *

func (CustomerDeletedMessagePayload) MarshalJSON ¶

func (obj CustomerDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerDraft ¶

type CustomerDraft struct {
	// User-defined unique identifier for the Customer.
	// The `key` field is preferred over `customerNumber` as it is mutable and provides more flexibility.
	Key *string `json:"key,omitempty"`
	// User-defined unique identifier for a Customer.
	// Once set, it cannot be changed.
	//
	// Can be used to refer to a Customer in a human-readable way (in emails, invoices, and other correspondence).
	CustomerNumber *string `json:"customerNumber,omitempty"`
	// Optional identifier for use in external systems like Customer Relationship Management (CRM) or Enterprise Resource Planning (ERP).
	ExternalId *string `json:"externalId,omitempty"`
	// Email address of the Customer that must be [unique](/../api/customers-overview#customer-uniqueness) for an entire Project or to a Store the Customer is assigned to.
	// It is the mandatory unique identifier of a Customer.
	Email string `json:"email"`
	// Required when `authenticationMode` is set to `Password`.
	// Provide the Customer's password in plain text. The API stores passwords in an encrypted format.
	Password *string `json:"password,omitempty"`
	// Given name (first name) of the Customer.
	FirstName *string `json:"firstName,omitempty"`
	// Family name (last name) of the Customer.
	LastName *string `json:"lastName,omitempty"`
	// Middle name of the Customer.
	MiddleName *string `json:"middleName,omitempty"`
	// Title of the Customer, for example, 'Dr.'.
	Title *string `json:"title,omitempty"`
	// Deprecated since an anonymous [Cart](ctp:api:type:Cart) can be identified by its `id` or external `key`.
	AnonymousCartId *string `json:"anonymousCartId,omitempty"`
	// Identifies a [Cart](ctp:api:type:Cart) that will be assigned to the new Customer.
	AnonymousCart *CartResourceIdentifier `json:"anonymousCart,omitempty"`
	// Identifies Carts and Orders belonging to an anonymous session that will be assigned to the new Customer.
	AnonymousId *string `json:"anonymousId,omitempty"`
	// Date of birth of the Customer.
	DateOfBirth *Date `json:"dateOfBirth,omitempty"`
	// Company name of the Customer. When representing a company as a Customer, [Business Units](ctp:api:type:BusinessUnit) provide extended funtionality.
	CompanyName *string `json:"companyName,omitempty"`
	// Individual VAT ID of the Customer.
	VatId *string `json:"vatId,omitempty"`
	// Addresses of the Customer.
	Addresses []BaseAddress `json:"addresses"`
	// Index of the address in the `addresses` array to use as the default shipping address.
	// The `defaultShippingAddressId` of the Customer will be set to the `id` of that address.
	DefaultShippingAddress *int `json:"defaultShippingAddress,omitempty"`
	// Indices of the shipping addresses in the `addresses` array.
	// The `shippingAddressIds` of the Customer will be set to the IDs of these addresses.
	ShippingAddresses []int `json:"shippingAddresses"`
	// Index of the address in the `addresses` array to use as the default billing address.
	// The `defaultBillingAddressId` of the Customer will be set to the `id` of that address.
	DefaultBillingAddress *int `json:"defaultBillingAddress,omitempty"`
	// Indices of the billing addresses in the `addresses` array.
	// The `billingAddressIds` of the Customer will be set to the IDs of these addresses.
	BillingAddresses []int `json:"billingAddresses"`
	// Set to `true` if the email address of the Customer has been verified already.
	// The intended use is to leave this field unset upon sign-up of the Customer and initiate the [email verification](#email-verification-of-customer) afterwards.
	IsEmailVerified *bool `json:"isEmailVerified,omitempty"`
	// Sets the [CustomerGroup](ctp:api:type:CustomerGroup) for the Customer.
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
	// Custom Fields for the Customer.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Preferred language of the Customer.
	// Must be one of the languages supported by the [Project](ctp:api:type:Project).
	Locale *string `json:"locale,omitempty"`
	// Salutation of the Customer, for example, 'Mr.' or 'Mrs.'.
	Salutation *string `json:"salutation,omitempty"`
	// Sets the [Stores](ctp:api:type:Store) for the Customer.
	//
	// - If no Stores are specified, the Customer is a global customer, and can log in using the [Password Flow for global Customers](/../api/authorization#password-flow-for-global-customers).
	// - If any Stores are specified, the Customer can only log in using the [Password Flow for Customers in a Store](/../api/authorization#password-flow-for-customers-in-a-store) for those specific Stores.
	Stores []StoreResourceIdentifier `json:"stores"`
	// - Set to `Password` to make the `password` field required for the Customer.
	// - Set to `ExternalAuth` when the password is not required for the Customer.
	AuthenticationMode *AuthenticationMode `json:"authenticationMode,omitempty"`
}

func (CustomerDraft) MarshalJSON ¶

func (obj CustomerDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerEmailChangedMessage ¶

type CustomerEmailChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The `email` that was set during the [Change Email](ctp:api:type:CustomerChangeEmailAction) update action.
	Email string `json:"email"`
}

* * Generated after a successful [Change Email](ctp:api:type:CustomerChangeEmailAction) update action. *

func (CustomerEmailChangedMessage) MarshalJSON ¶

func (obj CustomerEmailChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerEmailChangedMessage) UnmarshalJSON ¶

func (obj *CustomerEmailChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerEmailChangedMessagePayload ¶

type CustomerEmailChangedMessagePayload struct {
	// The `email` that was set during the [Change Email](ctp:api:type:CustomerChangeEmailAction) update action.
	Email string `json:"email"`
}

* * Generated after a successful [Change Email](ctp:api:type:CustomerChangeEmailAction) update action. *

func (CustomerEmailChangedMessagePayload) MarshalJSON ¶

func (obj CustomerEmailChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerEmailVerifiedMessage ¶

type CustomerEmailVerifiedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
}

* * Generated after a successful [Verify Customer's Email](/../api/projects/customers#verify-email-of-customer) request. *

func (CustomerEmailVerifiedMessage) MarshalJSON ¶

func (obj CustomerEmailVerifiedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerEmailVerifiedMessage) UnmarshalJSON ¶

func (obj *CustomerEmailVerifiedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerEmailVerifiedMessagePayload ¶

type CustomerEmailVerifiedMessagePayload struct {
}

* * Generated after a successful [Verify Customer's Email](/../api/projects/customers#verify-email-of-customer) request. *

func (CustomerEmailVerifiedMessagePayload) MarshalJSON ¶

func (obj CustomerEmailVerifiedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerEmailVerify ¶

type CustomerEmailVerify struct {
	// Expected version of the Customer.
	Version *int `json:"version,omitempty"`
	// Value of the token to verify Customer email.
	TokenValue string `json:"tokenValue"`
}

type CustomerFirstNameSetMessage ¶

type CustomerFirstNameSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The `firstName` that was set during the [Set First Name](ctp:api:type:CustomerSetFirstNameAction) update action.
	FirstName *string `json:"firstName,omitempty"`
}

* * Generated after a successful [Set First Name](ctp:api:type:CustomerSetFirstNameAction) update action. *

func (CustomerFirstNameSetMessage) MarshalJSON ¶

func (obj CustomerFirstNameSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerFirstNameSetMessage) UnmarshalJSON ¶

func (obj *CustomerFirstNameSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerFirstNameSetMessagePayload ¶

type CustomerFirstNameSetMessagePayload struct {
	// The `firstName` that was set during the [Set First Name](ctp:api:type:CustomerSetFirstNameAction) update action.
	FirstName *string `json:"firstName,omitempty"`
}

* * Generated after a successful [Set First Name](ctp:api:type:CustomerSetFirstNameAction) update action. *

func (CustomerFirstNameSetMessagePayload) MarshalJSON ¶

func (obj CustomerFirstNameSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerGroup ¶

type CustomerGroup struct {
	// Unique identifier of the CustomerGroup.
	ID string `json:"id"`
	// Current version of the CustomerGroup.
	Version int `json:"version"`
	// Date and time (UTC) the CustomerGroup was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the CustomerGroup was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources updated after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier for the CustomerGroup.
	Key *string `json:"key,omitempty"`
	// Unique name of the CustomerGroup.
	Name string `json:"name"`
	// Custom Fields for the CustomerGroup.
	Custom *CustomFields `json:"custom,omitempty"`
}

type CustomerGroupChangeNameAction ¶

type CustomerGroupChangeNameAction struct {
	// New name of the CustomerGroup.
	Name string `json:"name"`
}

func (CustomerGroupChangeNameAction) MarshalJSON ¶

func (obj CustomerGroupChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerGroupDraft ¶

type CustomerGroupDraft struct {
	// User-defined unique identifier for the CustomerGroup.
	Key *string `json:"key,omitempty"`
	// Unique value which must be different from any value used for `name` in [CustomerGroup](ctp:api:type:CustomerGroup) in the Project.
	// If not, a [DuplicateField](ctp:api:type:DuplicateFieldError) error is returned.
	GroupName string `json:"groupName"`
	// Custom Fields for the CustomerGroup.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

type CustomerGroupPagedQueryResponse ¶

type CustomerGroupPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [CustomerGroups](ctp:api:type:CustomerGroup) matching the query.
	Results []CustomerGroup `json:"results"`
}

* * [PagedQueryResult](/general-concepts#pagedqueryresult) with `results` containing an array of CustomerGroup(ctp:api:type:CustomerGroup). *

type CustomerGroupReference ¶

type CustomerGroupReference struct {
	// Unique identifier of the referenced [CustomerGroup](ctp:api:type:CustomerGroup).
	ID string `json:"id"`
	// Contains the representation of the expanded CustomerGroup. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for CustomerGroups.
	Obj *CustomerGroup `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a CustomerGroup(ctp:api:type:CustomerGroup). *

func (CustomerGroupReference) MarshalJSON ¶

func (obj CustomerGroupReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerGroupResourceIdentifier ¶

type CustomerGroupResourceIdentifier struct {
	// Unique identifier of the referenced [CustomerGroup](ctp:api:type:CustomerGroup). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [CustomerGroup](ctp:api:type:CustomerGroup). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a CustomerGroup(ctp:api:type:CustomerGroup). *

func (CustomerGroupResourceIdentifier) MarshalJSON ¶

func (obj CustomerGroupResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerGroupSetCustomFieldAction ¶

type CustomerGroupSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (CustomerGroupSetCustomFieldAction) MarshalJSON ¶

func (obj CustomerGroupSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerGroupSetCustomTypeAction ¶

type CustomerGroupSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the CustomerGroup with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the CustomerGroup.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the CustomerGroup.
	Fields *FieldContainer `json:"fields,omitempty"`
}

* * This action sets or removes the custom type for an existing CustomerGroup. * If present, this action overwrites any existing [custom](/../api/projects/custom-fields) type and fields. *

func (CustomerGroupSetCustomTypeAction) MarshalJSON ¶

func (obj CustomerGroupSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerGroupSetKeyAction ¶

type CustomerGroupSetKeyAction struct {
	// If `key` is absent or `null`, the existing key, if any, will be removed.
	Key *string `json:"key,omitempty"`
}

func (CustomerGroupSetKeyAction) MarshalJSON ¶

func (obj CustomerGroupSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerGroupSetMessage ¶

type CustomerGroupSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Customer Group](ctp:api:type:CustomerGroup) that was set during the [Set Customer Group](ctp:api:type:CustomerSetCustomerGroupAction) update action.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
}

* * Generated after a successful [Set Customer Group](ctp:api:type:CustomerSetCustomerGroupAction) update action. *

func (CustomerGroupSetMessage) MarshalJSON ¶

func (obj CustomerGroupSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerGroupSetMessage) UnmarshalJSON ¶

func (obj *CustomerGroupSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerGroupSetMessagePayload ¶

type CustomerGroupSetMessagePayload struct {
	// [Customer Group](ctp:api:type:CustomerGroup) that was set during the [Set Customer Group](ctp:api:type:CustomerSetCustomerGroupAction) update action.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
}

* * Generated after a successful [Set Customer Group](ctp:api:type:CustomerSetCustomerGroupAction) update action. *

func (CustomerGroupSetMessagePayload) MarshalJSON ¶

func (obj CustomerGroupSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerGroupUpdate ¶

type CustomerGroupUpdate struct {
	// Expected version of the CustomerGroup on which the changes should be applied.
	// If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the CustomerGroup.
	Actions []CustomerGroupUpdateAction `json:"actions"`
}

func (*CustomerGroupUpdate) UnmarshalJSON ¶

func (obj *CustomerGroupUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerGroupUpdateAction ¶

type CustomerGroupUpdateAction interface{}

type CustomerLastNameSetMessage ¶

type CustomerLastNameSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The `lastName` that was set during the [Set Last Name](ctp:api:type:CustomerSetLastNameAction) update action.
	LastName *string `json:"lastName,omitempty"`
}

* * Generated after a successful [Set Last Name](ctp:api:type:CustomerSetLastNameAction) update action. *

func (CustomerLastNameSetMessage) MarshalJSON ¶

func (obj CustomerLastNameSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerLastNameSetMessage) UnmarshalJSON ¶

func (obj *CustomerLastNameSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerLastNameSetMessagePayload ¶

type CustomerLastNameSetMessagePayload struct {
	// The `lastName` that was set during the [Set Last Name](ctp:api:type:CustomerSetLastNameAction) update action.
	LastName *string `json:"lastName,omitempty"`
}

* * Generated after a successful [Set Last Name](ctp:api:type:CustomerSetLastNameAction) update action. *

func (CustomerLastNameSetMessagePayload) MarshalJSON ¶

func (obj CustomerLastNameSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerPagedQueryResponse ¶

type CustomerPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [Customers](ctp:api:type:Customer) matching the query.
	Results []Customer `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of Customer(ctp:api:type:Customer). *

type CustomerPasswordUpdatedMessage ¶

type CustomerPasswordUpdatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Whether the Customer's password was updated during the [Reset password](/../api/projects/customers#password-reset-of-customer) or [Change password](/../api/projects/customers#change-password-of-customer) flow.
	Reset bool `json:"reset"`
}

* * Generated after a successful [Reset Customer's Password](/../api/projects/customers#reset-password-of-customer), [Reset Customer's Password in a Store](/../api/projects/customers#reset-password-of-customer-in-store), [Change Customer's Password](/../api/projects/customers#change-password-of-customer), or [Change Customer's Password in a Store](/../api/projects/customers#change-password-of-customer-in-store) request. This Message is also produced during equivalent requests to the [My Customer Profile](/../api/projects/me-profile) endpoint. *

func (CustomerPasswordUpdatedMessage) MarshalJSON ¶

func (obj CustomerPasswordUpdatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerPasswordUpdatedMessage) UnmarshalJSON ¶

func (obj *CustomerPasswordUpdatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerPasswordUpdatedMessagePayload ¶

type CustomerPasswordUpdatedMessagePayload struct {
	// Whether the Customer's password was updated during the [Reset password](/../api/projects/customers#password-reset-of-customer) or [Change password](/../api/projects/customers#change-password-of-customer) flow.
	Reset bool `json:"reset"`
}

* * Generated after a successful [Reset Customer's Password](/../api/projects/customers#reset-password-of-customer), [Reset Customer's Password in a Store](/../api/projects/customers#reset-password-of-customer-in-store), [Change Customer's Password](/../api/projects/customers#change-password-of-customer), or [Change Customer's Password in a Store](/../api/projects/customers#change-password-of-customer-in-store) request. This Message is also produced during equivalent requests to the [My Customer Profile](/../api/projects/me-profile) endpoint. *

func (CustomerPasswordUpdatedMessagePayload) MarshalJSON ¶

func (obj CustomerPasswordUpdatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerReference ¶

type CustomerReference struct {
	// Unique identifier of the referenced [Customer](ctp:api:type:Customer).
	ID string `json:"id"`
	// Contains the representation of the expanded Customer. Only present in responses to requests with [Reference Expansion](ctp:api:type:Expansion) for Customers.
	Obj *Customer `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a Customer(ctp:api:type:Customer). *

func (CustomerReference) MarshalJSON ¶

func (obj CustomerReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerRemoveAddressAction ¶

type CustomerRemoveAddressAction struct {
	// `id` of the [Address](ctp:api:type:Address) to remove.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to remove.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removing an address from the Customer produces the [CustomerAddressRemoved](ctp:api:type:CustomerAddressRemovedMessage) Message. * * Either `addressId` or `addressKey` is required. *

func (CustomerRemoveAddressAction) MarshalJSON ¶

func (obj CustomerRemoveAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerRemoveBillingAddressIdAction ¶

type CustomerRemoveBillingAddressIdAction struct {
	// `id` of the [Address](ctp:api:type:Address) to remove from `billingAddressesIds`.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to remove from `billingAddressesIds`.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removes a billing address from `billingAddressesIds`. * If the billing address is the default billing address, the `defaultBillingAddressId` is unset. Either `addressId` or `addressKey` is required. *

func (CustomerRemoveBillingAddressIdAction) MarshalJSON ¶

func (obj CustomerRemoveBillingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerRemoveShippingAddressIdAction ¶

type CustomerRemoveShippingAddressIdAction struct {
	// `id` of the [Address](ctp:api:type:Address) to remove from `shippingAddressesIds`.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to remove from `shippingAddressesIds`.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removes a shipping address from `shippingAddressesIds`. * If the shipping address is the default shipping address, the `defaultShippingAddressId` is unset. Either `addressId` or `addressKey` is required. *

func (CustomerRemoveShippingAddressIdAction) MarshalJSON ¶

func (obj CustomerRemoveShippingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerRemoveStoreAction ¶

type CustomerRemoveStoreAction struct {
	// ResourceIdentifier of the Store to remove.
	Store StoreResourceIdentifier `json:"store"`
}

* * Removes the association to a Store from the Customer. * If no more Stores are assigned, the Customer becomes a [global Customer](/../api/customers-overview#global-versus-store-specific-customers). *

func (CustomerRemoveStoreAction) MarshalJSON ¶

func (obj CustomerRemoveStoreAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerResetPassword ¶

type CustomerResetPassword struct {
	// Value of the token to reset the Customer password.
	TokenValue string `json:"tokenValue"`
	// New password to be set.
	NewPassword string `json:"newPassword"`
	// Expected version of the Customer.
	Version *int `json:"version,omitempty"`
}

type CustomerResourceIdentifier ¶

type CustomerResourceIdentifier struct {
	// Unique identifier of the referenced [Customer](ctp:api:type:Customer).
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [Customer](ctp:api:type:Customer).
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a Customer(ctp:api:type:Customer). Either `id` or `key` is required. *

func (CustomerResourceIdentifier) MarshalJSON ¶

func (obj CustomerResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetAddressCustomFieldAction ¶

type CustomerSetAddressCustomFieldAction struct {
	// User-defined unique identifier of the [Address](ctp:api:type:Address) to be updated.
	AddressId string `json:"addressId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// If `value` is provided, it is set for the field defined by `name`.
	// Trying to remove a field that does not exist will fail with an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	Value interface{} `json:"value,omitempty"`
}

func (CustomerSetAddressCustomFieldAction) MarshalJSON ¶

func (obj CustomerSetAddressCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetAddressCustomTypeAction ¶

type CustomerSetAddressCustomTypeAction struct {
	// User-defined unique identifier of the [Address](ctp:api:type:Address) to be updated.
	AddressId string `json:"addressId"`
	// Defines the [Type](ctp:api:type:Type) that extends the `address` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `address`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `address`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CustomerSetAddressCustomTypeAction) MarshalJSON ¶

func (obj CustomerSetAddressCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetAuthenticationModeAction ¶

type CustomerSetAuthenticationModeAction struct {
	// Value to set.
	// Changing a Customer's `authMode` from `Password` to `ExternalAuth` deletes the Customer's password.
	AuthMode AuthenticationMode `json:"authMode"`
	// Required when `authMode` is `Password`.
	Password *string `json:"password,omitempty"`
}

func (CustomerSetAuthenticationModeAction) MarshalJSON ¶

func (obj CustomerSetAuthenticationModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetCompanyNameAction ¶

type CustomerSetCompanyNameAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	CompanyName *string `json:"companyName,omitempty"`
}

* * Setting a company name produces the [CustomerCompanyNameSet](ctp:api:type:CustomerCompanyNameSetMessage) Message. *

func (CustomerSetCompanyNameAction) MarshalJSON ¶

func (obj CustomerSetCompanyNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetCustomFieldAction ¶

type CustomerSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// If `value` is provided, it is set for the field defined by `name`.
	// Trying to remove a field that does not exist will fail with an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	Value interface{} `json:"value,omitempty"`
}

func (CustomerSetCustomFieldAction) MarshalJSON ¶

func (obj CustomerSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetCustomTypeAction ¶

type CustomerSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the Customer with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Customer.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Customer.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (CustomerSetCustomTypeAction) MarshalJSON ¶

func (obj CustomerSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetCustomerGroupAction ¶

type CustomerSetCustomerGroupAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
}

* * Setting the Customer Group of the Customer produces the [CustomerGroupSet](ctp:api:type:CustomerGroupSetMessage) Message. *

func (CustomerSetCustomerGroupAction) MarshalJSON ¶

func (obj CustomerSetCustomerGroupAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetCustomerNumberAction ¶

type CustomerSetCustomerNumberAction struct {
	// Value to set.
	// Once set, it cannot be changed.
	CustomerNumber *string `json:"customerNumber,omitempty"`
}

* * Sets a new ID that can be used to refer to a Customer in a human-reabable way (for use in emails, invoices, etc). *

func (CustomerSetCustomerNumberAction) MarshalJSON ¶

func (obj CustomerSetCustomerNumberAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetDateOfBirthAction ¶

type CustomerSetDateOfBirthAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	DateOfBirth *Date `json:"dateOfBirth,omitempty"`
}

* * Setting the date of birth of the Customer produces the [CustomerDateOfBirthSet](ctp:api:type:CustomerDateOfBirthSetMessage) Message. *

func (CustomerSetDateOfBirthAction) MarshalJSON ¶

func (obj CustomerSetDateOfBirthAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetDefaultBillingAddressAction ¶

type CustomerSetDefaultBillingAddressAction struct {
	// `id` of the [Address](ctp:api:type:Address) to become the default billing address.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to become the default billing address.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Sets the default billing address from `addresses`. * The action adds the `id` of the specified Address to the `billingAddressIds` if not contained already. Either `addressId` or `addressKey` is required. *

func (CustomerSetDefaultBillingAddressAction) MarshalJSON ¶

func (obj CustomerSetDefaultBillingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetDefaultShippingAddressAction ¶

type CustomerSetDefaultShippingAddressAction struct {
	// `id` of the [Address](ctp:api:type:Address) to become the default shipping address.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to become the default shipping address.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Sets the default shipping address from `addresses`. * The action adds the `id` of the specified address to the `shippingAddressIds` if not contained already. Either `addressId` or `addressKey` is required. * * If the Tax Category of the Cart ShippingInfo(ctp:api:type:ShippingInfo) is missing the TaxRate matching country and state given in the `shippingAddress` of that Cart, a [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError) error is returned. *

func (CustomerSetDefaultShippingAddressAction) MarshalJSON ¶

func (obj CustomerSetDefaultShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetExternalIdAction ¶

type CustomerSetExternalIdAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	ExternalId *string `json:"externalId,omitempty"`
}

func (CustomerSetExternalIdAction) MarshalJSON ¶

func (obj CustomerSetExternalIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetFirstNameAction ¶

type CustomerSetFirstNameAction struct {
	// Value to set. If empty, any existing value is removed.
	FirstName *string `json:"firstName,omitempty"`
}

func (CustomerSetFirstNameAction) MarshalJSON ¶

func (obj CustomerSetFirstNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetKeyAction ¶

type CustomerSetKeyAction struct {
	// If `key` is absent or `null`, the existing key, if any, will be removed.
	Key *string `json:"key,omitempty"`
}

func (CustomerSetKeyAction) MarshalJSON ¶

func (obj CustomerSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetLastNameAction ¶

type CustomerSetLastNameAction struct {
	// Value to set. If empty, any existing value is removed.
	LastName *string `json:"lastName,omitempty"`
}

* * Setting the last name of the Customer produces the CustomerLastNameSetMessage(ctp:api:type:CustomerLastNameSetMessage). *

func (CustomerSetLastNameAction) MarshalJSON ¶

func (obj CustomerSetLastNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetLocaleAction ¶

type CustomerSetLocaleAction struct {
	// Value to set.
	// Must be one of the languages supported by the [Project](ctp:api:type:Project).
	Locale *string `json:"locale,omitempty"`
}

func (CustomerSetLocaleAction) MarshalJSON ¶

func (obj CustomerSetLocaleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetMiddleNameAction ¶

type CustomerSetMiddleNameAction struct {
	// Value to set. If empty, any existing value is removed.
	MiddleName *string `json:"middleName,omitempty"`
}

func (CustomerSetMiddleNameAction) MarshalJSON ¶

func (obj CustomerSetMiddleNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetSalutationAction ¶

type CustomerSetSalutationAction struct {
	// Value to set. If empty, any existing value is removed.
	Salutation *string `json:"salutation,omitempty"`
}

func (CustomerSetSalutationAction) MarshalJSON ¶

func (obj CustomerSetSalutationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetStoresAction ¶

type CustomerSetStoresAction struct {
	// ResourceIdentifier of the Stores to set.
	Stores []StoreResourceIdentifier `json:"stores"`
}

* * Sets the Stores the Customer account is associated with. * If no Stores are specified, the Customer becomes a [global Customer](/../api/customers-overview#global-versus-store-specific-customers). *

func (CustomerSetStoresAction) MarshalJSON ¶

func (obj CustomerSetStoresAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetTitleAction ¶

type CustomerSetTitleAction struct {
	// Value to set. If empty, any existing value is removed.
	Title *string `json:"title,omitempty"`
}

* * Setting the title of the Customer produces the CustomerTitleSetMessage(ctp:api:type:CustomerTitleSetMessage). *

func (CustomerSetTitleAction) MarshalJSON ¶

func (obj CustomerSetTitleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSetVatIdAction ¶

type CustomerSetVatIdAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	VatId *string `json:"vatId,omitempty"`
}

func (CustomerSetVatIdAction) MarshalJSON ¶

func (obj CustomerSetVatIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerSignInResult ¶

type CustomerSignInResult struct {
	// Customer [signed up](ctp:api:endpoint:/{projectKey}/customers:POST) or [signed in](ctp:api:endpoint:/{projectKey}/login:POST) after authentication.
	Customer Customer `json:"customer"`
	// Cart associated with the Customer.
	// If empty, the Customer does not have a Cart assigned.
	Cart *Cart `json:"cart,omitempty"`
}

type CustomerSignin ¶

type CustomerSignin struct {
	// Email address of the Customer treated as [case-insensitive](/../api/customers-overview#email-case-insensitivity).
	Email string `json:"email"`
	// Password of the Customer.
	Password string `json:"password"`
	// Deprecated since it is now possible to identify an anonymous cart by using its `id` or external `key`.
	AnonymousCartId *string `json:"anonymousCartId,omitempty"`
	// Identifies a [Cart](ctp:api:type:Cart) that will be assigned to the Customer.
	AnonymousCart *CartResourceIdentifier `json:"anonymousCart,omitempty"`
	// - Set to `MergeWithExistingCustomerCart` if [LineItems](ctp:api:type:LineItem) of the anonymous Cart should be merged with the active Customer Cart that has been modified most recently.
	// - Set to `UseAsNewActiveCustomerCart` if the anonymous Cart should be used as the new active Customer Cart and no [LineItems](ctp:api:type:LineItem) are to be merged.
	AnonymousCartSignInMode *AnonymousCartSignInMode `json:"anonymousCartSignInMode,omitempty"`
	// If both `anonymousCart` and `anonymousId` are provided, the `anonymousId` on the CustomerSignin must match that of the anonymous [Cart](ctp:api:type:Cart).
	// Otherwise a [400 Bad Request](ctp:api:type:InvalidOperationError) `Invalid Operation` error is returned with the message:
	// "Cart with the ID cart-id does not have the expected anonymousId.".
	AnonymousId *string `json:"anonymousId,omitempty"`
	// - If `true`, the [LineItem](ctp:api:type:LineItem) Product data (`name`, `variant`, and `productType`) of the returned Cart will be updated.
	// - If `false`, only the prices, discounts, and tax rates will be updated.
	UpdateProductData *bool `json:"updateProductData,omitempty"`
}

type CustomerTitleSetMessage ¶

type CustomerTitleSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The `title` that was set during the [Set Title](ctp:api:type:CustomerSetTitleAction) update action.
	Title *string `json:"title,omitempty"`
}

* * Generated after a successful [Set Title](ctp:api:type:CustomerSetTitleAction) update action. *

func (CustomerTitleSetMessage) MarshalJSON ¶

func (obj CustomerTitleSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*CustomerTitleSetMessage) UnmarshalJSON ¶

func (obj *CustomerTitleSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerTitleSetMessagePayload ¶

type CustomerTitleSetMessagePayload struct {
	// The `title` that was set during the [Set Title](ctp:api:type:CustomerSetTitleAction) update action.
	Title *string `json:"title,omitempty"`
}

* * Generated after a successful [Set Title](ctp:api:type:CustomerSetTitleAction) update action. *

func (CustomerTitleSetMessagePayload) MarshalJSON ¶

func (obj CustomerTitleSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type CustomerToken ¶

type CustomerToken struct {
	// Unique identifier of the token.
	ID string `json:"id"`
	// Date and time (UTC) the token was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// When the token is created, `lastModifiedAt` is set to `createdAt`.
	LastModifiedAt *time.Time `json:"lastModifiedAt,omitempty"`
	// The `id` of the Customer.
	CustomerId string `json:"customerId"`
	// Date and time (UTC) the token expires.
	ExpiresAt time.Time `json:"expiresAt"`
	// Value of the token.
	Value string `json:"value"`
}

type CustomerUpdate ¶

type CustomerUpdate struct {
	// Expected version of the Customer on which the changes should be applied. If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the Customer.
	Actions []CustomerUpdateAction `json:"actions"`
}

func (*CustomerUpdate) UnmarshalJSON ¶

func (obj *CustomerUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type CustomerUpdateAction ¶

type CustomerUpdateAction interface{}

type Date ¶

type Date struct {
	Year  int
	Month time.Month
	Day   int
}

Date holds date information for Commercetools API format

func NewDate ¶

func NewDate(year int, month time.Month, day int) Date

NewDate initializes a Date struct

func (*Date) MarshalJSON ¶

func (d *Date) MarshalJSON() ([]byte, error)

MarshalJSON marshals into the commercetools date format

func (*Date) UnmarshalJSON ¶

func (d *Date) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data into a Date struct

type DecodeStruct ¶

type DecodeStruct interface {
	DecodeStruct(map[string]interface{}) error
}

type Delivery ¶

type Delivery struct {
	// Unique identifier of the Delivery.
	ID string `json:"id"`
	// User-defined unique identifier of the Delivery.
	Key       *string   `json:"key,omitempty"`
	CreatedAt time.Time `json:"createdAt"`
	// Items which are shipped in this delivery regardless their distribution over several parcels.
	// Can also be specified individually for each Parcel.
	Items   []DeliveryItem `json:"items"`
	Parcels []Parcel       `json:"parcels"`
	Address *Address       `json:"address,omitempty"`
	// Custom Fields for the Transaction.
	Custom *CustomFields `json:"custom,omitempty"`
}

type DeliveryAddedMessage ¶

type DeliveryAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Delivery](ctp:api:type:Delivery) that was added to the [Order](ctp:api:type:Order). The [Delivery](ctp:api:type:Delivery) in the Message body does not contain [Parcels](ctp:api:type:Parcel) if those were part of the initial [Add Delivery](ctp:api:type:OrderAddDeliveryAction) update action. In that case, the update action produces an additional [ParcelAddedToDelivery](ctp:api:type:ParcelAddedToDeliveryMessage) Message containing information about the [Parcels](ctp:api:type:Parcel).
	Delivery Delivery `json:"delivery"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Add Delivery](ctp:api:type:OrderAddDeliveryAction) update action. *

func (DeliveryAddedMessage) MarshalJSON ¶

func (obj DeliveryAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DeliveryAddedMessage) UnmarshalJSON ¶

func (obj *DeliveryAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DeliveryAddedMessagePayload ¶

type DeliveryAddedMessagePayload struct {
	// [Delivery](ctp:api:type:Delivery) that was added to the [Order](ctp:api:type:Order). The [Delivery](ctp:api:type:Delivery) in the Message body does not contain [Parcels](ctp:api:type:Parcel) if those were part of the initial [Add Delivery](ctp:api:type:OrderAddDeliveryAction) update action. In that case, the update action produces an additional [ParcelAddedToDelivery](ctp:api:type:ParcelAddedToDeliveryMessage) Message containing information about the [Parcels](ctp:api:type:Parcel).
	Delivery Delivery `json:"delivery"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Add Delivery](ctp:api:type:OrderAddDeliveryAction) update action. *

func (DeliveryAddedMessagePayload) MarshalJSON ¶

func (obj DeliveryAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DeliveryAddressSetMessage ¶

type DeliveryAddressSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Parcel](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// [Address](ctp:api:type:Address) after the [Set Delivery Address](ctp:api:type:OrderSetDeliveryAddressAction) update action.
	Address *Address `json:"address,omitempty"`
	// [Address](ctp:api:type:Address) before the [Set Delivery Address](ctp:api:type:OrderSetDeliveryAddressAction) update action.
	OldAddress *Address `json:"oldAddress,omitempty"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Set Delivery Address](ctp:api:type:OrderSetDeliveryAddressAction) update action. *

func (DeliveryAddressSetMessage) MarshalJSON ¶

func (obj DeliveryAddressSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DeliveryAddressSetMessage) UnmarshalJSON ¶

func (obj *DeliveryAddressSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DeliveryAddressSetMessagePayload ¶

type DeliveryAddressSetMessagePayload struct {
	// Unique identifier of the [Parcel](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// [Address](ctp:api:type:Address) after the [Set Delivery Address](ctp:api:type:OrderSetDeliveryAddressAction) update action.
	Address *Address `json:"address,omitempty"`
	// [Address](ctp:api:type:Address) before the [Set Delivery Address](ctp:api:type:OrderSetDeliveryAddressAction) update action.
	OldAddress *Address `json:"oldAddress,omitempty"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Set Delivery Address](ctp:api:type:OrderSetDeliveryAddressAction) update action. *

func (DeliveryAddressSetMessagePayload) MarshalJSON ¶

func (obj DeliveryAddressSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DeliveryDraft ¶

type DeliveryDraft struct {
	// User-defined unique identifier of the Delivery.
	Key *string `json:"key,omitempty"`
	// Items which are shipped in this delivery regardless their distribution over several parcels.
	// Can also be specified individually for each Parcel.
	Items   []DeliveryItem `json:"items"`
	Parcels []ParcelDraft  `json:"parcels"`
	Address *AddressDraft  `json:"address,omitempty"`
	// Custom Fields for the Transaction.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (DeliveryDraft) MarshalJSON ¶

func (obj DeliveryDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DeliveryFormat ¶

type DeliveryFormat interface{}

type DeliveryItem ¶

type DeliveryItem struct {
	// Unique identifier of the DeliveryItem.
	ID       string `json:"id"`
	Quantity int    `json:"quantity"`
}

type DeliveryItemsUpdatedMessage ¶

type DeliveryItemsUpdatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// [Delivery Items](ctp:api:type:DeliveryItem) after the [Set Delivery Items](ctp:api:type:OrderSetDeliveryItemsAction) update action.
	Items []DeliveryItem `json:"items"`
	// [Delivery Items](ctp:api:type:DeliveryItem) before the [Set Delivery Items](ctp:api:type:OrderSetDeliveryItemsAction) update action.
	OldItems []DeliveryItem `json:"oldItems"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Set Delivery Items](ctp:api:type:OrderSetDeliveryItemsAction) update action. *

func (DeliveryItemsUpdatedMessage) MarshalJSON ¶

func (obj DeliveryItemsUpdatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DeliveryItemsUpdatedMessage) UnmarshalJSON ¶

func (obj *DeliveryItemsUpdatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DeliveryItemsUpdatedMessagePayload ¶

type DeliveryItemsUpdatedMessagePayload struct {
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// [Delivery Items](ctp:api:type:DeliveryItem) after the [Set Delivery Items](ctp:api:type:OrderSetDeliveryItemsAction) update action.
	Items []DeliveryItem `json:"items"`
	// [Delivery Items](ctp:api:type:DeliveryItem) before the [Set Delivery Items](ctp:api:type:OrderSetDeliveryItemsAction) update action.
	OldItems []DeliveryItem `json:"oldItems"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Set Delivery Items](ctp:api:type:OrderSetDeliveryItemsAction) update action. *

func (DeliveryItemsUpdatedMessagePayload) MarshalJSON ¶

func (obj DeliveryItemsUpdatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DeliveryPayload ¶

type DeliveryPayload interface{}

* * All payloads for the PlatformFormat(ctp:api:type:PlatformFormat) share these common fields. *

type DeliveryRemovedMessage ¶

type DeliveryRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [Delivery](ctp:api:type:Delivery) that was removed from the [Order](ctp:api:type:Order).
	Delivery Delivery `json:"delivery"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Remove Delivery](ctp:api:type:OrderRemoveDeliveryAction) update action. *

func (DeliveryRemovedMessage) MarshalJSON ¶

func (obj DeliveryRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DeliveryRemovedMessage) UnmarshalJSON ¶

func (obj *DeliveryRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DeliveryRemovedMessagePayload ¶

type DeliveryRemovedMessagePayload struct {
	// The [Delivery](ctp:api:type:Delivery) that was removed from the [Order](ctp:api:type:Order).
	Delivery Delivery `json:"delivery"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Remove Delivery](ctp:api:type:OrderRemoveDeliveryAction) update action. *

func (DeliveryRemovedMessagePayload) MarshalJSON ¶

func (obj DeliveryRemovedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type Destination ¶

type Destination interface{}

type DirectDiscount ¶

type DirectDiscount struct {
	// Unique identifier of the Direct Discount.
	ID string `json:"id"`
	// Effect of the Discount on the Cart.
	Value CartDiscountValue `json:"value"`
	// Part of the Cart that is discounted.
	//
	// Empty when the `value` is set to `giftLineItem`.
	Target CartDiscountTarget `json:"target,omitempty"`
}

* * Represents a CartDiscount(ctp:api:type:CartDiscount) that is only associated with a single Cart or Order. *

func (*DirectDiscount) UnmarshalJSON ¶

func (obj *DirectDiscount) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DirectDiscountDraft ¶

type DirectDiscountDraft struct {
	// Defines the effect the Discount will have.
	Value CartDiscountValue `json:"value"`
	// Defines what part of the Cart will be discounted.
	//
	// If `value` is set to `giftLineItem`, this must not be set.
	Target CartDiscountTarget `json:"target,omitempty"`
}

* * Represents a CartDiscount(ctp:api:type:CartDiscount) that can only be associated with a single Cart or Order. * * Direct Discounts are always active and valid, and have the default `Stacking` StackingMode(ctp:api:type:StackingMode). * They apply in the order in which they are listed in the `directDiscounts` array of [Carts](ctp:api:type:Cart) or [Orders](ctp:api:type:Order), and do not have a sorting order like Cart Discounts. * * If a Direct Discount is present, any matching Cart Discounts in the Project are ignored. * Additionally, a Cart or Order supports either Discount Codes or Direct Discounts at the same time. *

func (*DirectDiscountDraft) UnmarshalJSON ¶

func (obj *DirectDiscountDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DirectDiscountReference ¶

type DirectDiscountReference struct {
	// Unique identifier of the referenced [DirectDiscount](ctp:api:type:DirectDiscount).
	ID string `json:"id"`
}

* * Reference(ctp:api:type:Reference) to a DirectDiscount(ctp:api:type:DirectDiscount). *

func (DirectDiscountReference) MarshalJSON ¶

func (obj DirectDiscountReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCode ¶

type DiscountCode struct {
	// Unique identifier of the DiscountCode.
	ID string `json:"id"`
	// Current version of the DiscountCode.
	Version int `json:"version"`
	// Date and time (UTC) the DiscountCode was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the DiscountCode was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Name of the DiscountCode.
	Name *LocalizedString `json:"name,omitempty"`
	// Description of the DiscountCode.
	Description *LocalizedString `json:"description,omitempty"`
	// User-defined unique identifier of the DiscountCode [added to the Cart](/../api/projects/carts#add-discountcode) to apply the related [CartDiscounts](ctp:api:type:CartDiscount).
	Code string `json:"code"`
	// Reference to CartDiscounts that can be applied to the Cart once the DiscountCode is applied.
	CartDiscounts []CartDiscountReference `json:"cartDiscounts"`
	// DiscountCode can only be applied to Carts that match this predicate.
	CartPredicate *string `json:"cartPredicate,omitempty"`
	// Indicates if the DiscountCode is active and can be applied to the Cart.
	IsActive bool `json:"isActive"`
	// Array generated from the Cart predicate.
	// It contains the references of all the resources that are addressed in the predicate.
	References []Reference `json:"references"`
	// Number of times the DiscountCode can be applied.
	// DiscountCode application is counted at the time of Order creation or edit. However, Order cancellation or deletion does not decrement the count.
	MaxApplications *int `json:"maxApplications,omitempty"`
	// Number of times the DiscountCode can be applied per Customer (anonymous Carts are not supported).
	// DiscountCode application is counted at the time of Order creation or edit. However, Order cancellation or deletion does not decrement the count.
	MaxApplicationsPerCustomer *int `json:"maxApplicationsPerCustomer,omitempty"`
	// Custom Fields of the DiscountCode.
	Custom *CustomFields `json:"custom,omitempty"`
	// Groups to which the DiscountCode belongs to.
	Groups []string `json:"groups"`
	// Date and time (UTC) from which the DiscountCode is effective.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the DiscountCode is effective.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Used and managed by the API and must not be used in customer logic.
	// The value can change at any time due to internal and external factors.
	ApplicationVersion *int `json:"applicationVersion,omitempty"`
}

func (*DiscountCode) UnmarshalJSON ¶

func (obj *DiscountCode) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DiscountCodeChangeCartDiscountsAction ¶

type DiscountCodeChangeCartDiscountsAction struct {
	// New value to set.
	CartDiscounts []CartDiscountResourceIdentifier `json:"cartDiscounts"`
}

func (DiscountCodeChangeCartDiscountsAction) MarshalJSON ¶

func (obj DiscountCodeChangeCartDiscountsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeChangeGroupsAction ¶

type DiscountCodeChangeGroupsAction struct {
	// New value to set. An empty array removes the DiscountCode from all groups.
	Groups []string `json:"groups"`
}

func (DiscountCodeChangeGroupsAction) MarshalJSON ¶

func (obj DiscountCodeChangeGroupsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeChangeIsActiveAction ¶

type DiscountCodeChangeIsActiveAction struct {
	// New value to set. Set to `true` to activate the DiscountCode for all matching Discounts.
	IsActive bool `json:"isActive"`
}

func (DiscountCodeChangeIsActiveAction) MarshalJSON ¶

func (obj DiscountCodeChangeIsActiveAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeDraft ¶

type DiscountCodeDraft struct {
	// Name of the DiscountCode.
	Name *LocalizedString `json:"name,omitempty"`
	// Description of the DiscountCode.
	Description *LocalizedString `json:"description,omitempty"`
	// User-defined unique identifier for the DiscountCode that can be [added to the Cart](/../api/projects/carts#add-discountcode) to apply the related [CartDiscounts](ctp:api:type:CartDiscount).
	// It cannot be modified after the DiscountCode is created.
	Code string `json:"code"`
	// Specify what CartDiscounts the API applies when you add the DiscountCode to the Cart.
	CartDiscounts []CartDiscountResourceIdentifier `json:"cartDiscounts"`
	// DiscountCode can only be applied to Carts that match this predicate.
	CartPredicate *string `json:"cartPredicate,omitempty"`
	// Only active DiscountCodes can be applied to the Cart.
	IsActive *bool `json:"isActive,omitempty"`
	// Number of times the DiscountCode can be applied.
	MaxApplications *int `json:"maxApplications,omitempty"`
	// Number of times the DiscountCode can be applied per Customer.
	MaxApplicationsPerCustomer *int `json:"maxApplicationsPerCustomer,omitempty"`
	// Custom Fields for the DiscountCode.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Groups to which the DiscountCode will belong to.
	Groups []string `json:"groups"`
	// Date and time (UTC) from which the DiscountCode is effective. Must be earlier than `validUntil`.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the DiscountCode is effective. Must be later than `validFrom`.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

func (DiscountCodeDraft) MarshalJSON ¶

func (obj DiscountCodeDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeInfo ¶

type DiscountCodeInfo struct {
	// Discount Code associated with the Cart or Order.
	DiscountCode DiscountCodeReference `json:"discountCode"`
	// Indicates the state of the Discount Code applied to the Cart or Order.
	State DiscountCodeState `json:"state"`
}

type DiscountCodeNonApplicableError ¶

type DiscountCodeNonApplicableError struct {
	// `"The discountCode $discountCodeId cannot be applied to the cart."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Discount Code passed to the Cart.
	DiscountCode *string `json:"discountCode,omitempty"`
	// `"DoesNotExist"` or `"TimeRangeNonApplicable"`
	Reason *string `json:"reason,omitempty"`
	// Unique identifier of the Discount Code.
	DiscountCodeId *string `json:"discountCodeId,omitempty"`
	// Date and time (UTC) from which the Discount Code is valid.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the Discount Code is valid.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Date and time (UTC) the Discount Code validity check was last performed.
	ValidityCheckTime *time.Time `json:"validityCheckTime,omitempty"`
}

* * Returned when the Cart contains a Discount Code with a DiscountCodeState(ctp:api:type:DiscountCodeState) other than `MatchesCart`. * * The error is returned as a failed response to: * * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests on Orders. * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/me/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/me/orders:POST) requests on My Orders. *

func (*DiscountCodeNonApplicableError) DecodeStruct ¶

func (obj *DiscountCodeNonApplicableError) DecodeStruct(src map[string]interface{}) error

func (DiscountCodeNonApplicableError) Error ¶

func (DiscountCodeNonApplicableError) MarshalJSON ¶

func (obj DiscountCodeNonApplicableError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DiscountCodeNonApplicableError) UnmarshalJSON ¶

func (obj *DiscountCodeNonApplicableError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DiscountCodePagedQueryResponse ¶

type DiscountCodePagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [DiscountCodes](ctp:api:type:DiscountCode) matching the query.
	Results []DiscountCode `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of DiscountCode(ctp:api:type:DiscountCode). *

type DiscountCodeReference ¶

type DiscountCodeReference struct {
	// Unique identifier of the referenced [DiscountCode](ctp:api:type:DiscountCode).
	ID string `json:"id"`
	// Contains the representation of the expanded DiscountCode. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for DiscountCodes.
	Obj *DiscountCode `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a DiscountCode(ctp:api:type:DiscountCode). *

func (DiscountCodeReference) MarshalJSON ¶

func (obj DiscountCodeReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeResourceIdentifier ¶

type DiscountCodeResourceIdentifier struct {
	// Unique identifier of the referenced [DiscountCode](ctp:api:type:DiscountCode). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [DiscountCode](ctp:api:type:DiscountCode). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a DiscountCode(ctp:api:type:DiscountCode). *

func (DiscountCodeResourceIdentifier) MarshalJSON ¶

func (obj DiscountCodeResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeSetCartPredicateAction ¶

type DiscountCodeSetCartPredicateAction struct {
	// Value to set. If empty, any existing value will be removed.
	CartPredicate *string `json:"cartPredicate,omitempty"`
}

func (DiscountCodeSetCartPredicateAction) MarshalJSON ¶

func (obj DiscountCodeSetCartPredicateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeSetCustomFieldAction ¶

type DiscountCodeSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (DiscountCodeSetCustomFieldAction) MarshalJSON ¶

func (obj DiscountCodeSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeSetCustomTypeAction ¶

type DiscountCodeSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the DiscountCode with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the DiscountCode.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the DiscountCode.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (DiscountCodeSetCustomTypeAction) MarshalJSON ¶

func (obj DiscountCodeSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeSetDescriptionAction ¶

type DiscountCodeSetDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

func (DiscountCodeSetDescriptionAction) MarshalJSON ¶

func (obj DiscountCodeSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeSetMaxApplicationsAction ¶

type DiscountCodeSetMaxApplicationsAction struct {
	// Value to set. If empty, any existing value will be removed.
	MaxApplications *int `json:"maxApplications,omitempty"`
}

func (DiscountCodeSetMaxApplicationsAction) MarshalJSON ¶

func (obj DiscountCodeSetMaxApplicationsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeSetMaxApplicationsPerCustomerAction ¶

type DiscountCodeSetMaxApplicationsPerCustomerAction struct {
	// Value to set. If empty, any existing value will be removed.
	MaxApplicationsPerCustomer *int `json:"maxApplicationsPerCustomer,omitempty"`
}

func (DiscountCodeSetMaxApplicationsPerCustomerAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeSetNameAction ¶

type DiscountCodeSetNameAction struct {
	// Value to set. If empty, any existing value will be removed.
	Name *LocalizedString `json:"name,omitempty"`
}

func (DiscountCodeSetNameAction) MarshalJSON ¶

func (obj DiscountCodeSetNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeSetValidFromAction ¶

type DiscountCodeSetValidFromAction struct {
	// Value to set that must be earlier than `validUntil`. If empty, any existing value will be removed.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
}

func (DiscountCodeSetValidFromAction) MarshalJSON ¶

func (obj DiscountCodeSetValidFromAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeSetValidFromAndUntilAction ¶

type DiscountCodeSetValidFromAndUntilAction struct {
	// Value to set that must be earlier than `validUntil`. If empty, any existing value will be removed.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Value to set that must be later than `validFrom`. If empty, any existing value will be removed.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

func (DiscountCodeSetValidFromAndUntilAction) MarshalJSON ¶

func (obj DiscountCodeSetValidFromAndUntilAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeSetValidUntilAction ¶

type DiscountCodeSetValidUntilAction struct {
	// Value to set that must be later than `validFrom`. If empty, any existing value will be removed.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

func (DiscountCodeSetValidUntilAction) MarshalJSON ¶

func (obj DiscountCodeSetValidUntilAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DiscountCodeState ¶

type DiscountCodeState string

* * Indicates the state of a Discount Code in a Cart. * * If an Order is created from a Cart with a state other than `MatchesCart`, a [DiscountCodeNonApplicable](ctp:api:type:DiscountCodeNonApplicableError) error is returned. *

const (
	DiscountCodeStateNotActive                            DiscountCodeState = "NotActive"
	DiscountCodeStateNotValid                             DiscountCodeState = "NotValid"
	DiscountCodeStateDoesNotMatchCart                     DiscountCodeState = "DoesNotMatchCart"
	DiscountCodeStateMatchesCart                          DiscountCodeState = "MatchesCart"
	DiscountCodeStateMaxApplicationReached                DiscountCodeState = "MaxApplicationReached"
	DiscountCodeStateApplicationStoppedByPreviousDiscount DiscountCodeState = "ApplicationStoppedByPreviousDiscount"
)

type DiscountCodeUpdate ¶

type DiscountCodeUpdate struct {
	// Expected version of the DiscountCode on which the changes should be applied.
	// If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the DiscountCode.
	Actions []DiscountCodeUpdateAction `json:"actions"`
}

func (*DiscountCodeUpdate) UnmarshalJSON ¶

func (obj *DiscountCodeUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DiscountCodeUpdateAction ¶

type DiscountCodeUpdateAction interface{}

type DiscountedLineItemPortion ¶

type DiscountedLineItemPortion struct {
	// A [CartDiscountReference](ctp:api:type:CartDiscountReference) or [DirectDiscountReference](ctp:api:type:DirectDiscountReference) for the applicable discount on the Line Item.
	Discount Reference `json:"discount"`
	// Money value of the discount applicable.
	DiscountedAmount TypedMoney `json:"discountedAmount"`
}

func (*DiscountedLineItemPortion) UnmarshalJSON ¶

func (obj *DiscountedLineItemPortion) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DiscountedLineItemPrice ¶

type DiscountedLineItemPrice struct {
	// Money value of the discounted Line Item or Custom Line Item.
	Value TypedMoney `json:"value"`
	// Discount applicable on the Line Item or Custom Line Item.
	IncludedDiscounts []DiscountedLineItemPortion `json:"includedDiscounts"`
}

func (*DiscountedLineItemPrice) UnmarshalJSON ¶

func (obj *DiscountedLineItemPrice) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DiscountedLineItemPriceDraft ¶

type DiscountedLineItemPriceDraft struct {
	// Draft type that stores amounts only in cent precision for the specified currency.
	Value             Money                       `json:"value"`
	IncludedDiscounts []DiscountedLineItemPortion `json:"includedDiscounts"`
}

type DiscountedLineItemPriceForQuantity ¶

type DiscountedLineItemPriceForQuantity struct {
	// Number of Line Items or Custom Line Items in the Cart.
	Quantity int `json:"quantity"`
	// Discounted price of the Line Item or Custom Line Item.
	DiscountedPrice DiscountedLineItemPrice `json:"discountedPrice"`
}

type DiscountedPrice ¶

type DiscountedPrice struct {
	// Money value of the discounted price.
	Value TypedMoney `json:"value"`
	// [ProductDiscount](ctp:api:type:ProductDiscount) related to the discounted price.
	Discount ProductDiscountReference `json:"discount"`
}

func (*DiscountedPrice) UnmarshalJSON ¶

func (obj *DiscountedPrice) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DiscountedPriceDraft ¶

type DiscountedPriceDraft struct {
	// Sets the money value for the discounted price.
	Value Money `json:"value"`
	// Relates the referenced [ProductDiscount](ctp:api:type:ProductDiscount) to the discounted price.
	Discount ProductDiscountReference `json:"discount"`
}

type Division ¶

type Division struct {
	// Unique identifier of the Business Unit.
	ID string `json:"id"`
	// Current version of the Business Unit.
	Version int `json:"version"`
	// Date and time (UTC) the Business Unit was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Business Unit was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources updated after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the Business Unit.
	Key string `json:"key"`
	// Indicates whether the Business Unit can be edited and used in [Orders](/../api/projects/orders).
	Status BusinessUnitStatus `json:"status"`
	// References to [Stores](ctp:api:type:Store) the Business Unit is associated with. Only present when `storeMode` is `Explicit`.
	//
	// If the Business Unit has Stores defined, then all of its [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [Quotes](ctp:api:type:Quote), or [Quote Requests](ctp:api:type:QuoteRequest) must belong to one of the Business Unit's Stores.
	//
	// If the Business Unit has no Stores, then all of its [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [Quotes](ctp:api:type:Quote), or [Quote Requests](ctp:api:type:QuoteRequest) must not belong to any Store.
	Stores []StoreKeyReference `json:"stores"`
	// Defines whether the Stores of the Division are set explicitly or inherited from a parent Business Unit.
	StoreMode BusinessUnitStoreMode `json:"storeMode"`
	// Name of the Business Unit.
	Name string `json:"name"`
	// Email address of the Business Unit.
	ContactEmail *string `json:"contactEmail,omitempty"`
	// Custom Fields for the Business Unit.
	Custom *CustomFields `json:"custom,omitempty"`
	// Addresses used by the Business Unit.
	Addresses []Address `json:"addresses"`
	// Unique identifiers of addresses used as shipping addresses.
	ShippingAddressIds []string `json:"shippingAddressIds"`
	// Unique identifier of the address used as the default shipping address.
	DefaultShippingAddressId *string `json:"defaultShippingAddressId,omitempty"`
	// Unique identifiers of addresses used as billing addresses.
	BillingAddressIds []string `json:"billingAddressIds"`
	// Unique identifier of the address used as the default billing address.
	DefaultBillingAddressId *string `json:"defaultBillingAddressId,omitempty"`
	// Determines whether the Division can inherit Associates from a parent.
	AssociateMode BusinessUnitAssociateMode `json:"associateMode"`
	// Associates that are part of the Business Unit in specific [roles](ctp:api:type:AssociateRole).
	Associates []Associate `json:"associates"`
	// Associates that are inherited from a parent Business Unit. This value of this field is [eventually consistent](/../api/general-concepts#eventual-consistency) and is only present when the `associateMode` is set to `ExplicitAndFromParent`.
	InheritedAssociates []InheritedAssociate `json:"inheritedAssociates"`
	// Parent unit of the Division.
	ParentUnit BusinessUnitKeyReference `json:"parentUnit"`
	// Top-level unit of the Business Unit. The top-level unit is of `unitType` `Company`.
	TopLevelUnit BusinessUnitKeyReference `json:"topLevelUnit"`
}

* * Business Unit type to model divisions that are part of the Company(ctp:api:type:Company) or a higher-order Division. * Contains specific fields and values that differentiate a Division from the generic BusinessUnit(ctp:api:type:BusinessUnit). *

func (Division) MarshalJSON ¶

func (obj Division) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DivisionDraft ¶

type DivisionDraft struct {
	// User-defined unique identifier for the Business Unit.
	Key string `json:"key"`
	// Indicates whether the Business Unit can be edited and used in [Orders](/../api/projects/orders).
	Status *BusinessUnitStatus `json:"status,omitempty"`
	// Sets the [Stores](ctp:api:type:Store) the Business Unit is associated with. Can only be set when `storeMode` is `Explicit`.
	// Defaults to empty for [Companies](ctp:api:type:BusinessUnitType) and not set for [Divisions](ctp:api:type:BusinessUnitType).
	//
	// If the Business Unit has Stores defined, then all of its [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [Quotes](ctp:api:type:Quote), or [Quote Requests](ctp:api:type:QuoteRequest) must belong to one of the Business Unit's Stores.
	//
	// If the Business Unit has no Stores, then all of its [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [Quotes](ctp:api:type:Quote), or [Quote Requests](ctp:api:type:QuoteRequest) must not belong to any Store.
	Stores []StoreResourceIdentifier `json:"stores"`
	// If not set, the Division inherits the [Stores](ctp:api:type:Store) from a parent unit.
	// Set this to `Explicit` if you want to set the Stores explicitly in the `stores` field instead.
	StoreMode *BusinessUnitStoreMode `json:"storeMode,omitempty"`
	// Name of the Business Unit.
	Name string `json:"name"`
	// Email address of the Business Unit.
	ContactEmail *string `json:"contactEmail,omitempty"`
	// Determines whether the Division can inherit Associates from a parent.
	AssociateMode *BusinessUnitAssociateMode `json:"associateMode,omitempty"`
	// List of members that are part of the Business Unit in specific [roles](ctp:api:type:AssociateRole).
	Associates []AssociateDraft `json:"associates"`
	// Addresses used by the Business Unit.
	Addresses []BaseAddress `json:"addresses"`
	// Indexes of entries in `addresses` to set as shipping addresses.
	// The `shippingAddressIds` of the [Customer](ctp:api:type:Customer) will be replaced by these addresses.
	ShippingAddresses []int `json:"shippingAddresses"`
	// Index of the entry in `addresses` to set as the default shipping address.
	DefaultShippingAddress *int `json:"defaultShippingAddress,omitempty"`
	// Indexes of entries in `addresses` to set as billing addresses.
	// The `billingAddressIds` of the [Customer](ctp:api:type:Customer) will be replaced by these addresses.
	BillingAddresses []int `json:"billingAddresses"`
	// Index of the entry in `addresses` to set as the default billing address.
	DefaultBillingAddress *int `json:"defaultBillingAddress,omitempty"`
	// Custom Fields for the Business Unit.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// The parent unit of this Division. Can be a Company or a Division.
	ParentUnit BusinessUnitResourceIdentifier `json:"parentUnit"`
}

* * Draft type to model divisions that are part of a Company(ctp:api:type:Company) or a higher-order Division(ctp:api:type:Division). * Contains the fields and values of the generic BusinessUnitDraft(ctp:api:type:BusinessUnitDraft) that are used specifically for creating a Division. *

func (DivisionDraft) MarshalJSON ¶

func (obj DivisionDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DuplicateAttributeValueError ¶

type DuplicateAttributeValueError struct {
	// `"Attribute can't have the same value in a different variant."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting Attributes.
	Attribute Attribute `json:"attribute"`
}

* * Returned when the `Unique` [AttributeConstraint](ctp:api:type:AttributeConstraintEnum) criteria are not met during an [Update Product](/../api/projects/products#update-product) request. *

func (*DuplicateAttributeValueError) DecodeStruct ¶

func (obj *DuplicateAttributeValueError) DecodeStruct(src map[string]interface{}) error

func (DuplicateAttributeValueError) Error ¶

func (DuplicateAttributeValueError) MarshalJSON ¶

func (obj DuplicateAttributeValueError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DuplicateAttributeValueError) UnmarshalJSON ¶

func (obj *DuplicateAttributeValueError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DuplicateAttributeValuesError ¶

type DuplicateAttributeValuesError struct {
	// `"The set of attributes must be unique across all variants."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting Attributes.
	Attributes []Attribute `json:"attributes"`
}

* * Returned when the `CombinationUnique` [AttributeConstraint](ctp:api:type:AttributeConstraintEnum) criteria are not met during an [Update Product](/../api/projects/products#update-product) request. *

func (*DuplicateAttributeValuesError) DecodeStruct ¶

func (obj *DuplicateAttributeValuesError) DecodeStruct(src map[string]interface{}) error

func (DuplicateAttributeValuesError) Error ¶

func (DuplicateAttributeValuesError) MarshalJSON ¶

func (obj DuplicateAttributeValuesError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DuplicateAttributeValuesError) UnmarshalJSON ¶

func (obj *DuplicateAttributeValuesError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DuplicateEnumValuesError ¶

type DuplicateEnumValuesError struct {
	// `"The enum values contain duplicate keys: $listOfDuplicateKeys."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Duplicate keys.
	Duplicates []string `json:"duplicates"`
}

* * Returned when an AttributeEnumType(ctp:api:type:AttributeEnumType) or AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType) contains duplicate keys. *

func (*DuplicateEnumValuesError) DecodeStruct ¶

func (obj *DuplicateEnumValuesError) DecodeStruct(src map[string]interface{}) error

func (DuplicateEnumValuesError) Error ¶

func (obj DuplicateEnumValuesError) Error() string

func (DuplicateEnumValuesError) MarshalJSON ¶

func (obj DuplicateEnumValuesError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DuplicateEnumValuesError) UnmarshalJSON ¶

func (obj *DuplicateEnumValuesError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DuplicateFieldError ¶

type DuplicateFieldError struct {
	// `"A duplicate value $duplicateValue exists for field $field."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Name of the conflicting field.
	Field string `json:"field"`
	// Conflicting duplicate value.
	DuplicateValue interface{} `json:"duplicateValue"`
}

* * Returned when a field value conflicts with an existing value causing a duplicate. *

func (*DuplicateFieldError) DecodeStruct ¶

func (obj *DuplicateFieldError) DecodeStruct(src map[string]interface{}) error

func (DuplicateFieldError) Error ¶

func (obj DuplicateFieldError) Error() string

func (DuplicateFieldError) MarshalJSON ¶

func (obj DuplicateFieldError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DuplicateFieldError) UnmarshalJSON ¶

func (obj *DuplicateFieldError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DuplicateFieldWithConflictingResourceError ¶

type DuplicateFieldWithConflictingResourceError struct {
	// `"A duplicate value $duplicateValue exists for field $field on $conflictingResource."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Name of the conflicting field.
	Field string `json:"field"`
	// Conflicting duplicate value.
	DuplicateValue interface{} `json:"duplicateValue"`
	// Reference to the resource that has the conflicting value.
	ConflictingResource Reference `json:"conflictingResource"`
}

* * Returned when a field value conflicts with an existing value stored in a particular resource causing a duplicate. *

func (*DuplicateFieldWithConflictingResourceError) DecodeStruct ¶

func (obj *DuplicateFieldWithConflictingResourceError) DecodeStruct(src map[string]interface{}) error

func (DuplicateFieldWithConflictingResourceError) Error ¶

func (DuplicateFieldWithConflictingResourceError) MarshalJSON ¶

func (obj DuplicateFieldWithConflictingResourceError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DuplicateFieldWithConflictingResourceError) UnmarshalJSON ¶

func (obj *DuplicateFieldWithConflictingResourceError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DuplicatePriceKeyError ¶

type DuplicatePriceKeyError struct {
	// `"Duplicate price key: $priceKey. The price key must be unique per variant."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting Embedded Price.
	ConflictingPrice Price `json:"conflictingPrice"`
}

* * Returned when a Price key conflicts with an existing key. * * Keys of Embedded Prices must be unique per ProductVariant. *

func (*DuplicatePriceKeyError) DecodeStruct ¶

func (obj *DuplicatePriceKeyError) DecodeStruct(src map[string]interface{}) error

func (DuplicatePriceKeyError) Error ¶

func (obj DuplicatePriceKeyError) Error() string

func (DuplicatePriceKeyError) MarshalJSON ¶

func (obj DuplicatePriceKeyError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DuplicatePriceKeyError) UnmarshalJSON ¶

func (obj *DuplicatePriceKeyError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DuplicatePriceScopeError ¶

type DuplicatePriceScopeError struct {
	// `"Duplicate price scope: $priceScope. The combination of currency, country, customerGroup and channel must be unique for each price of a product variant."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting Embedded Price.
	ConflictingPrice Price `json:"conflictingPrice"`
}

* * Returned when a Price scope conflicts with an existing one during an [Update Product](/../api/projects/products#update-product) request. * * Every Price of a Product Variant must have a distinct combination of currency, Customer Group, country, and Channel that constitute the scope of a Price. *

func (*DuplicatePriceScopeError) DecodeStruct ¶

func (obj *DuplicatePriceScopeError) DecodeStruct(src map[string]interface{}) error

func (DuplicatePriceScopeError) Error ¶

func (obj DuplicatePriceScopeError) Error() string

func (DuplicatePriceScopeError) MarshalJSON ¶

func (obj DuplicatePriceScopeError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DuplicatePriceScopeError) UnmarshalJSON ¶

func (obj *DuplicatePriceScopeError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DuplicateStandalonePriceScopeError ¶

type DuplicateStandalonePriceScopeError struct {
	// `"Duplicate standalone price scope for SKU: $sku. The combination of SKU, currency, country, customerGroup, channel, validFrom and validUntil must be unique for each standalone price."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Reference to the conflicting Standalone Price.
	ConflictingStandalonePrice StandalonePriceReference `json:"conflictingStandalonePrice"`
	// SKU of the [ProductVariant](ctp:api:type:ProductVariant) to which the conflicting Standalone Price is associated.
	Sku string `json:"sku"`
	// Currency code of the country.
	Currency string `json:"currency"`
	// Country code of the geographic location.
	Country *string `json:"country,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) for which the Standalone Price is valid.
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
	// [Channel](ctp:api:type:Channel) for which the Standalone Price is valid.
	Channel *ChannelResourceIdentifier `json:"channel,omitempty"`
	// Date and time (UTC) from which the Standalone Price is valid.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the Standalone Price is valid.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

* * Returned when the given Price scope conflicts with the Price scope of an existing Standalone Price. * Every Standalone Price associated with the same SKU must have a distinct combination of currency, country, Customer Group, Channel, and validity periods (`validFrom` and `validUntil`). * * The error is returned as a failed response to the [Create StandalonePrice](/../api/projects/standalone-prices#create-standaloneprice) request. *

func (*DuplicateStandalonePriceScopeError) DecodeStruct ¶

func (obj *DuplicateStandalonePriceScopeError) DecodeStruct(src map[string]interface{}) error

func (DuplicateStandalonePriceScopeError) Error ¶

func (DuplicateStandalonePriceScopeError) MarshalJSON ¶

func (obj DuplicateStandalonePriceScopeError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DuplicateStandalonePriceScopeError) UnmarshalJSON ¶

func (obj *DuplicateStandalonePriceScopeError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DuplicateVariantValuesError ¶

type DuplicateVariantValuesError struct {
	// `"A duplicate combination of the variant values (sku, key, images, prices, attributes) exists."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Every Product Variant must have a distinct combination of SKU, prices, and custom Attribute values.
	VariantValues VariantValues `json:"variantValues"`
}

* * Returned when a [Product Variant](ctp:api:type:ProductVariant) value conflicts with an existing one during an [Update Product](/../api/projects/products#update-product) request. *

func (*DuplicateVariantValuesError) DecodeStruct ¶

func (obj *DuplicateVariantValuesError) DecodeStruct(src map[string]interface{}) error

func (DuplicateVariantValuesError) Error ¶

func (obj DuplicateVariantValuesError) Error() string

func (DuplicateVariantValuesError) MarshalJSON ¶

func (obj DuplicateVariantValuesError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DuplicateVariantValuesError) UnmarshalJSON ¶

func (obj *DuplicateVariantValuesError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type EditPreviewFailedError ¶

type EditPreviewFailedError struct {
	// `"Error while applying staged actions. ShippingMethods could not be determined."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// State of the OrderEdit where the `stagedActions` cannot be applied to the Order.
	Result OrderEditPreviewFailure `json:"result"`
}

* * Returned when a preview to find an appropriate Shipping Method for an OrderEdit could not be generated. * * The error is returned as a failed response to the [Get Shipping Methods for an OrderEdit](/../api/projects/shippingMethods#get-shippingmethods-for-an-orderedit) request. *

func (*EditPreviewFailedError) DecodeStruct ¶

func (obj *EditPreviewFailedError) DecodeStruct(src map[string]interface{}) error

func (EditPreviewFailedError) Error ¶

func (obj EditPreviewFailedError) Error() string

func (EditPreviewFailedError) MarshalJSON ¶

func (obj EditPreviewFailedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*EditPreviewFailedError) UnmarshalJSON ¶

func (obj *EditPreviewFailedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type EnumKeyAlreadyExistsError ¶

type EnumKeyAlreadyExistsError struct {
	// `"The $attributeName attribute definition already contains an enum value with the key $enumKey."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting enum key.
	ConflictingEnumKey string `json:"conflictingEnumKey"`
	// Name of the conflicting Attribute.
	ConflictingAttributeName string `json:"conflictingAttributeName"`
}

* * Returned when an AttributeEnumType(ctp:api:type:AttributeEnumType) or AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType) contains a key that already exists. *

func (*EnumKeyAlreadyExistsError) DecodeStruct ¶

func (obj *EnumKeyAlreadyExistsError) DecodeStruct(src map[string]interface{}) error

func (EnumKeyAlreadyExistsError) Error ¶

func (obj EnumKeyAlreadyExistsError) Error() string

func (EnumKeyAlreadyExistsError) MarshalJSON ¶

func (obj EnumKeyAlreadyExistsError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*EnumKeyAlreadyExistsError) UnmarshalJSON ¶

func (obj *EnumKeyAlreadyExistsError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type EnumKeyDoesNotExistError ¶

type EnumKeyDoesNotExistError struct {
	// `"The $fieldName field definition does not contain an enum value with the key $enumKey."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting enum key.
	ConflictingEnumKey string `json:"conflictingEnumKey"`
	// Name of the conflicting Attribute.
	ConflictingAttributeName string `json:"conflictingAttributeName"`
}

* * Returned when an AttributeEnumType(ctp:api:type:AttributeEnumType) or AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType) already contains a value with the given key. * * The error is returned as a failed response to the [Change the key of an EnumValue](ctp:api:type:ProductTypeChangeEnumKeyAction) update action. *

func (*EnumKeyDoesNotExistError) DecodeStruct ¶

func (obj *EnumKeyDoesNotExistError) DecodeStruct(src map[string]interface{}) error

func (EnumKeyDoesNotExistError) Error ¶

func (obj EnumKeyDoesNotExistError) Error() string

func (EnumKeyDoesNotExistError) MarshalJSON ¶

func (obj EnumKeyDoesNotExistError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*EnumKeyDoesNotExistError) UnmarshalJSON ¶

func (obj *EnumKeyDoesNotExistError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type EnumValueIsUsedError ¶

type EnumValueIsUsedError struct {
	// `"$enumKeysTranscript is used by some products and cannot be deleted because the $attributeName attribute is required."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when an enum value cannot be removed from an Attribute as it is being used by a Product. * * The error is returned as a failed response to the [Remove EnumValues from AttributeDefinition](ctp:api:type:ProductTypeRemoveEnumValuesAction) update action. *

func (*EnumValueIsUsedError) DecodeStruct ¶

func (obj *EnumValueIsUsedError) DecodeStruct(src map[string]interface{}) error

func (EnumValueIsUsedError) Error ¶

func (obj EnumValueIsUsedError) Error() string

func (EnumValueIsUsedError) MarshalJSON ¶

func (obj EnumValueIsUsedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*EnumValueIsUsedError) UnmarshalJSON ¶

func (obj *EnumValueIsUsedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type EnumValuesMustMatchError ¶

type EnumValuesMustMatchError struct {
	// `"The given values must be equal to the existing enum values."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when during an order update of AttributeEnumType(ctp:api:type:AttributeEnumType) or AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType) the new enum values do not match the existing ones. * * The error is returned as a failed response to the [Change the order of EnumValues](ctp:api:type:ProductTypeChangePlainEnumValueOrderAction) and [Change the order of LocalizedEnumValues](ctp:api:type:ProductTypeChangeLocalizedEnumValueOrderAction) update actions. *

func (*EnumValuesMustMatchError) DecodeStruct ¶

func (obj *EnumValuesMustMatchError) DecodeStruct(src map[string]interface{}) error

func (EnumValuesMustMatchError) Error ¶

func (obj EnumValuesMustMatchError) Error() string

func (EnumValuesMustMatchError) MarshalJSON ¶

func (obj EnumValuesMustMatchError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*EnumValuesMustMatchError) UnmarshalJSON ¶

func (obj *EnumValuesMustMatchError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ErrorByExtension ¶

type ErrorByExtension struct {
	// Unique identifier of the Extension.
	ID string `json:"id"`
	// User-defined unique identifier of the Extension.
	Key *string `json:"key,omitempty"`
}

type ErrorObject ¶

type ErrorObject interface{}

* * Represents a single error. Multiple errors may be included in an ErrorResponse(ctp:api:type:ErrorResponse).

type ErrorResponse ¶

type ErrorResponse struct {
	// HTTP status code corresponding to the error.
	StatusCode int `json:"statusCode"`
	// First error message in the `errors` array.
	Message string `json:"message"`
	// Errors returned for a request.
	//
	// A single error response can contain multiple errors if the errors are related to the same HTTP status code such as `400`.
	Errors []ErrorObject `json:"errors"`
}

* * Base representation of an error response containing common fields to all errors. *

func (ErrorResponse) Error ¶

func (obj ErrorResponse) Error() string

func (ErrorResponse) MarshalJSON ¶

func (obj ErrorResponse) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ErrorResponse) UnmarshalJSON ¶

func (obj *ErrorResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type EventBridgeDestination ¶

type EventBridgeDestination struct {
	// AWS region that receives the events.
	Region string `json:"region"`
	// ID of the AWS account that receives the events.
	AccountId string `json:"accountId"`
}

* * [AWS EventBridge](https://aws.amazon.com/eventbridge/) can be used to push events and messages to a serverless event bus that can forward them to AWS SQS, SNS, Lambda, and other AWS services based on forwarding rules. * Once the Subscription is created, an equivalent "partner event source" is created in AWS EventBridge. This event source must be associated with an event bus for the Subscription setup to be complete. *

func (EventBridgeDestination) MarshalJSON ¶

func (obj EventBridgeDestination) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type Extension ¶

type Extension struct {
	// Unique identifier of the Extension.
	ID string `json:"id"`
	// Current version of the Extension.
	Version int `json:"version"`
	// Date and time (UTC) the Extension was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Extension was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the Extension.
	Key *string `json:"key,omitempty"`
	// The configuration for the Extension, including its type, location and authentication details.
	Destination ExtensionDestination `json:"destination"`
	// Describes what triggers the Extension.
	Triggers []ExtensionTrigger `json:"triggers"`
	// Maximum time (in milliseconds) that the Extension can respond within.
	// If no timeout is provided, the default value is used for all types of Extensions.
	// The maximum value is 10000 ms (10 seconds) for `payment` Extensions and 2000 ms (2 seconds) for all other Extensions.
	TimeoutInMs *int `json:"timeoutInMs,omitempty"`
}

func (*Extension) UnmarshalJSON ¶

func (obj *Extension) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ExtensionAction ¶

type ExtensionAction string

* * An Extension gets called during any of the following requests of an API call, but before the result is persisted. *

const (
	ExtensionActionCreate ExtensionAction = "Create"
	ExtensionActionUpdate ExtensionAction = "Update"
)

type ExtensionBadResponseError ¶

type ExtensionBadResponseError struct {
	// Description of the invalid Extension response. For example, `"The extension did not return the expected JSON."`.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// User-defined localized description of the error.
	LocalizedMessage *LocalizedString `json:"localizedMessage,omitempty"`
	// Any information that should be returned to the API caller.
	ExtensionExtraInfo *interface{} `json:"extensionExtraInfo,omitempty"`
	// Additional errors related to the API Extension.
	ExtensionErrors []ExtensionError `json:"extensionErrors"`
	// The response body returned by the Extension.
	ExtensionBody *string `json:"extensionBody,omitempty"`
	// Http status code returned by the Extension.
	ExtensionStatusCode *int `json:"extensionStatusCode,omitempty"`
	// Unique identifier of the Extension.
	ExtensionId string `json:"extensionId"`
	// User-defined unique identifier of the Extension.
	ExtensionKey *string `json:"extensionKey,omitempty"`
}

* * Returned when the response from the API Extension could not be parsed successfully (such as a `500` HTTP status code, or an invalid JSON response). *

func (*ExtensionBadResponseError) DecodeStruct ¶

func (obj *ExtensionBadResponseError) DecodeStruct(src map[string]interface{}) error

func (ExtensionBadResponseError) Error ¶

func (obj ExtensionBadResponseError) Error() string

func (ExtensionBadResponseError) MarshalJSON ¶

func (obj ExtensionBadResponseError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ExtensionBadResponseError) UnmarshalJSON ¶

func (obj *ExtensionBadResponseError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ExtensionChangeDestinationAction ¶

type ExtensionChangeDestinationAction struct {
	// New value to set. Must not be empty.
	Destination ExtensionDestination `json:"destination"`
}

func (ExtensionChangeDestinationAction) MarshalJSON ¶

func (obj ExtensionChangeDestinationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ExtensionChangeDestinationAction) UnmarshalJSON ¶

func (obj *ExtensionChangeDestinationAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ExtensionChangeTriggersAction ¶

type ExtensionChangeTriggersAction struct {
	// New value to set. Must not be empty.
	Triggers []ExtensionTrigger `json:"triggers"`
}

func (ExtensionChangeTriggersAction) MarshalJSON ¶

func (obj ExtensionChangeTriggersAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ExtensionDestination ¶

type ExtensionDestination interface{}

* * Generic type for destinations.

type ExtensionDraft ¶

type ExtensionDraft struct {
	// User-defined unique identifier for the Extension.
	Key *string `json:"key,omitempty"`
	// Defines where the Extension can be reached.
	Destination ExtensionDestination `json:"destination"`
	// Describes what triggers the Extension.
	Triggers []ExtensionTrigger `json:"triggers"`
	// Maximum time (in milliseconds) the Extension can respond within.
	// If no timeout is provided, the default value is used for all types of Extensions.
	// The maximum value is 10000 ms (10 seconds) for `payment` Extensions and 2000 ms (2 seconds) for all other Extensions.
	//
	// This limit can be increased per Project after we review the performance impact.
	// Please contact our support via the [Support Portal](https://support.commercetools.com) and provide the Region, Project key, and use case.
	TimeoutInMs *int `json:"timeoutInMs,omitempty"`
}

func (*ExtensionDraft) UnmarshalJSON ¶

func (obj *ExtensionDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ExtensionError ¶

type ExtensionError struct {
	// Error code caused by the Extension. For example, `InvalidField`.
	Code string `json:"code"`
	// Plain text description of the error.
	Message string `json:"message"`
	// Unique identifier of the Extension.
	ExtensionId string `json:"extensionId"`
	// User-defined unique identifier of the Extension.
	ExtensionKey *string `json:"extensionKey,omitempty"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

func (ExtensionError) Error ¶

func (obj ExtensionError) Error() string

func (ExtensionError) MarshalJSON ¶

func (obj ExtensionError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ExtensionError) UnmarshalJSON ¶

func (obj *ExtensionError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ExtensionInput ¶

type ExtensionInput struct {
	// `Create` or `Update` request.
	Action ExtensionAction `json:"action"`
	// Expanded reference to the resource that triggered the Extension.
	Resource Reference `json:"resource"`
}

func (*ExtensionInput) UnmarshalJSON ¶

func (obj *ExtensionInput) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ExtensionNoResponseError ¶

type ExtensionNoResponseError struct {
	// `"Extension did not respond in time."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifier of the API Extension.
	ExtensionId string `json:"extensionId"`
	// User-defined unique identifier of the API Extension, if available.
	ExtensionKey *string `json:"extensionKey,omitempty"`
}

* * Returned when the API Extension does not respond within the [time limit](/../api/projects/api-extensions#time-limits), or could not be reached. *

func (*ExtensionNoResponseError) DecodeStruct ¶

func (obj *ExtensionNoResponseError) DecodeStruct(src map[string]interface{}) error

func (ExtensionNoResponseError) Error ¶

func (obj ExtensionNoResponseError) Error() string

func (ExtensionNoResponseError) MarshalJSON ¶

func (obj ExtensionNoResponseError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ExtensionNoResponseError) UnmarshalJSON ¶

func (obj *ExtensionNoResponseError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ExtensionPagedQueryResponse ¶

type ExtensionPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Extensions matching the query.
	Results []Extension `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of Extension(ctp:api:type:Extension). *

type ExtensionPredicateEvaluationFailedError ¶

type ExtensionPredicateEvaluationFailedError struct {
	// `"The compared field $fieldName is not present."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Details about the API Extension that was involved in the error.
	ErrorByExtension ErrorByExtension `json:"errorByExtension"`
}

* * Returned when the predicate defined in the ExtensionTrigger(ctp:api:type:ExtensionTrigger) could not be evaluated due to a missing field. *

func (*ExtensionPredicateEvaluationFailedError) DecodeStruct ¶

func (obj *ExtensionPredicateEvaluationFailedError) DecodeStruct(src map[string]interface{}) error

func (ExtensionPredicateEvaluationFailedError) Error ¶

func (ExtensionPredicateEvaluationFailedError) MarshalJSON ¶

func (obj ExtensionPredicateEvaluationFailedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ExtensionPredicateEvaluationFailedError) UnmarshalJSON ¶

func (obj *ExtensionPredicateEvaluationFailedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ExtensionResourceTypeId ¶

type ExtensionResourceTypeId string

* * Extensions are available for: *

const (
	ExtensionResourceTypeIdCart         ExtensionResourceTypeId = "cart"
	ExtensionResourceTypeIdOrder        ExtensionResourceTypeId = "order"
	ExtensionResourceTypeIdPayment      ExtensionResourceTypeId = "payment"
	ExtensionResourceTypeIdCustomer     ExtensionResourceTypeId = "customer"
	ExtensionResourceTypeIdQuoteRequest ExtensionResourceTypeId = "quote-request"
	ExtensionResourceTypeIdStagedQuote  ExtensionResourceTypeId = "staged-quote"
	ExtensionResourceTypeIdQuote        ExtensionResourceTypeId = "quote"
	ExtensionResourceTypeIdBusinessUnit ExtensionResourceTypeId = "business-unit"
)

type ExtensionSetKeyAction ¶

type ExtensionSetKeyAction struct {
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

func (ExtensionSetKeyAction) MarshalJSON ¶

func (obj ExtensionSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ExtensionSetTimeoutInMsAction ¶

type ExtensionSetTimeoutInMsAction struct {
	// Value to set. If not defined, the maximum value is used.
	// If no timeout is provided, the default value is used for all types of Extensions.
	// The maximum value is 10000 ms (10 seconds) for `payment` Extensions and 2000 ms (2 seconds) for all other Extensions.
	//
	// This limit can be increased per Project after we review the performance impact.
	// Please contact our support via the [Support Portal](https://support.commercetools.com/) and provide the Region, Project key, and use case.
	TimeoutInMs *int `json:"timeoutInMs,omitempty"`
}

func (ExtensionSetTimeoutInMsAction) MarshalJSON ¶

func (obj ExtensionSetTimeoutInMsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ExtensionTrigger ¶

type ExtensionTrigger struct {
	// `cart`, `order`, `payment`, `customer`, `quote-request`, `staged-quote`, `quote`, and `business-unit` are supported.
	ResourceTypeId ExtensionResourceTypeId `json:"resourceTypeId"`
	// `Create` and `Update` requests are supported.
	Actions []ExtensionAction `json:"actions"`
	// Valid [predicate](/../api/predicates/query) that controls the conditions under which the API Extension is called. The Extension is not triggered when the specified condition is not fulfilled.
	Condition *string `json:"condition,omitempty"`
}

type ExtensionUpdate ¶

type ExtensionUpdate struct {
	// Expected version of the Extension on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the Extension.
	Actions []ExtensionUpdateAction `json:"actions"`
}

func (*ExtensionUpdate) UnmarshalJSON ¶

func (obj *ExtensionUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ExtensionUpdateAction ¶

type ExtensionUpdateAction interface{}

type ExtensionUpdateActionsFailedError ¶

type ExtensionUpdateActionsFailedError struct {
	// `"The extension returned update actions that could not be executed."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// User-defined localized description of the error.
	LocalizedMessage *LocalizedString `json:"localizedMessage,omitempty"`
	// Any information that should be returned to the API caller.
	ExtensionExtraInfo *interface{} `json:"extensionExtraInfo,omitempty"`
	// Additional errors related to the API Extension.
	ExtensionErrors []ExtensionError `json:"extensionErrors"`
}

* * Returned when update actions could not be applied to the resource (for example, because a referenced resource does not exist). * This would result in a [400 Bad Request](#400-bad-request) response if the same update action was sent from a regular client. *

func (*ExtensionUpdateActionsFailedError) DecodeStruct ¶

func (obj *ExtensionUpdateActionsFailedError) DecodeStruct(src map[string]interface{}) error

func (ExtensionUpdateActionsFailedError) Error ¶

func (ExtensionUpdateActionsFailedError) MarshalJSON ¶

func (obj ExtensionUpdateActionsFailedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ExtensionUpdateActionsFailedError) UnmarshalJSON ¶

func (obj *ExtensionUpdateActionsFailedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ExternalLineItemTotalPrice ¶

type ExternalLineItemTotalPrice struct {
	// Price of the Line Item.
	//
	// The value is selected from the Product Variant according to the [Product](ctp:api:type:Product) `priceMode`.
	Price Money `json:"price"`
	// Total price of the Line Item.
	TotalPrice Money `json:"totalPrice"`
}

type ExternalOAuth ¶

type ExternalOAuth struct {
	// URL with authorization header. If the Project is hosted in the China (AWS, Ningxia) Region, verify that the URL is not blocked due to firewall restrictions.
	Url string `json:"url"`
	// Must not contain any leading or trailing whitespaces. Partially hidden on retrieval.
	AuthorizationHeader string `json:"authorizationHeader"`
}

* * Represents a RFC 7662 compliant [OAuth 2.0 Token Introspection](https://datatracker.ietf.org/doc/html/rfc7662) endpoint. For more information, see [Requesting an access token using an external OAuth 2.0 server](/../api/authorization#requesting-an-access-token-using-an-external-oauth-server). * * You can only configure **one** external OAuth 2.0 endpoint per Project. To authenticate using multiple external services (such as social network logins), use a middle layer authentication service. *

type ExternalOAuthFailedError ¶

type ExternalOAuthFailedError struct {
	// Plain text description detailing the external OAuth error. For example, `"External OAuth did not respond in time."`.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when an [external OAuth Introspection endpoint](/../api/authorization#requesting-an-access-token-using-an-external-oauth-server) does not return a response within the [time limit](/../api/authorization#time-limits), or the response isn't compliant with [RFC 7662](https://www.rfc-editor.org/rfc/rfc7662.html) (for example, an HTTP status code like `500`). *

func (*ExternalOAuthFailedError) DecodeStruct ¶

func (obj *ExternalOAuthFailedError) DecodeStruct(src map[string]interface{}) error

func (ExternalOAuthFailedError) Error ¶

func (obj ExternalOAuthFailedError) Error() string

func (ExternalOAuthFailedError) MarshalJSON ¶

func (obj ExternalOAuthFailedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ExternalOAuthFailedError) UnmarshalJSON ¶

func (obj *ExternalOAuthFailedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ExternalTaxAmountDraft ¶

type ExternalTaxAmountDraft struct {
	// Total gross amount (`totalNet` + `taxPortions`) of the Line Item or Custom Line Item.
	TotalGross Money `json:"totalGross"`
	// Tax Rates and subrates of states and countries.
	TaxRate ExternalTaxRateDraft `json:"taxRate"`
}

* * Cannot be used in LineItemDraft(ctp:api:type:LineItemDraft) or CustomLineItemDraft(ctp:api:type:CustomLineItemDraft). * * Can only be set by these update actions: * * - [Set LineItem TaxAmount](ctp:api:type:CartSetLineItemTaxAmountAction), [Set CustomLineItem TaxAmount](ctp:api:type:CartSetCustomLineItemTaxAmountAction), or [Set ShippingMethod TaxAmount](ctp:api:type:CartSetShippingMethodTaxAmountAction) on Carts * - [Set LineItem TaxAmount](ctp:api:type:OrderEditSetLineItemTaxAmountAction), [Set CustomLineItem TaxAmount](ctp:api:type:OrderEditSetCustomLineItemTaxAmountAction), or [Set ShippingMethod TaxAmount](ctp:api:type:OrderEditSetShippingMethodTaxAmountAction) on Order Edits *

type ExternalTaxRateDraft ¶

type ExternalTaxRateDraft struct {
	// Name of the Tax Rate.
	Name string `json:"name"`
	// Percentage in the range of 0-1.
	//
	// - If no `subRates` are specified, a value must be defined.
	// - If `subRates` are specified, this can be omitted or its value must be the sum of all `subRates` amounts.
	Amount *float64 `json:"amount,omitempty"`
	// - If set to `false`, the related price is considered the net price and the provided `amount` is applied to calculate the gross price.
	// - If set to `true`, the related price is considered the gross price, and the provided `amount` is applied to calculate the net price.
	IncludedInPrice *bool `json:"includedInPrice,omitempty"`
	// Country for which the tax applies.
	Country string `json:"country"`
	// State within the specified country.
	State *string `json:"state,omitempty"`
	// For countries (such as the US) where the total tax is a combination of multiple taxes (such as state and local taxes).
	SubRates []SubRate `json:"subRates"`
}

* * Controls calculation of taxed prices for Line Items, Custom Line Items, and Shipping Methods as explained in [Cart tax calculation](ctp:api:type:CartTaxCalculation). *

func (ExternalTaxRateDraft) MarshalJSON ¶

func (obj ExternalTaxRateDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type FacetRange ¶

type FacetRange struct {
	From         float64 `json:"from"`
	FromStr      string  `json:"fromStr"`
	To           float64 `json:"to"`
	ToStr        string  `json:"toStr"`
	Count        int     `json:"count"`
	ProductCount *int    `json:"productCount,omitempty"`
	Total        float64 `json:"total"`
	Min          float64 `json:"min"`
	Max          float64 `json:"max"`
	Mean         float64 `json:"mean"`
}

type FacetResult ¶

type FacetResult interface{}

type FacetResults ¶

type FacetResults map[string]FacetResult

type FacetTerm ¶

type FacetTerm struct {
	Term         interface{} `json:"term"`
	Count        int         `json:"count"`
	ProductCount *int        `json:"productCount,omitempty"`
}

type FacetTypes ¶

type FacetTypes string
const (
	FacetTypesTerms  FacetTypes = "terms"
	FacetTypesRange  FacetTypes = "range"
	FacetTypesFilter FacetTypes = "filter"
)

type FeatureRemovedError ¶

type FeatureRemovedError struct {
	// Description of the feature that is removed.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the requested feature was removed. *

func (*FeatureRemovedError) DecodeStruct ¶

func (obj *FeatureRemovedError) DecodeStruct(src map[string]interface{}) error

func (FeatureRemovedError) Error ¶

func (obj FeatureRemovedError) Error() string

func (FeatureRemovedError) MarshalJSON ¶

func (obj FeatureRemovedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*FeatureRemovedError) UnmarshalJSON ¶

func (obj *FeatureRemovedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type FieldContainer ¶

type FieldContainer map[string]interface{}

type FieldDefinition ¶

type FieldDefinition struct {
	// Data type of the Custom Field to define.
	Type FieldType `json:"type"`
	// Name of the Custom Field to define.
	// Must be unique for a given [ResourceTypeId](ctp:api:type:ResourceTypeId).
	// In case there is a FieldDefinition with the same `name` in another [Type](ctp:api:type:Type), both FieldDefinitions must have the same `type`.
	Name string `json:"name"`
	// A human-readable label for the field.
	Label LocalizedString `json:"label"`
	// Defines whether the field is required to have a value.
	Required bool `json:"required"`
	// Defines the visual representation of the field in user interfaces like the Merchant Center.
	// It is only relevant for string-based [FieldTypes](ctp:api:type:FieldType) like [CustomFieldStringType](ctp:api:type:CustomFieldStringType) and [CustomFieldLocalizedStringType](ctp:api:type:CustomFieldLocalizedStringType).
	InputHint *TypeTextInputHint `json:"inputHint,omitempty"`
}

* * Defines a [Custom Field](/../api/projects/custom-fields) and its meta-information. * This FieldDefinition is similar to an AttributeDefinition(ctp:api:type:AttributeDefinition) of [Product Types](/../api/projects/productTypes). *

func (*FieldDefinition) UnmarshalJSON ¶

func (obj *FieldDefinition) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type FieldType ¶

type FieldType interface{}

type FilteredFacetResult ¶

type FilteredFacetResult struct {
	Count        int  `json:"count"`
	ProductCount *int `json:"productCount,omitempty"`
}

func (FilteredFacetResult) MarshalJSON ¶

func (obj FilteredFacetResult) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type GeneralError ¶

type GeneralError struct {
	// Description about any known details of the problem, for example, `"Write operations are temporarily unavailable"`.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a server-side problem occurs. * * If you encounter this error, report it using the [Support Portal](https://support.commercetools.com). *

func (*GeneralError) DecodeStruct ¶

func (obj *GeneralError) DecodeStruct(src map[string]interface{}) error

func (GeneralError) Error ¶

func (obj GeneralError) Error() string

func (GeneralError) MarshalJSON ¶

func (obj GeneralError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GeneralError) UnmarshalJSON ¶

func (obj *GeneralError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GenericRequestError ¶

type GenericRequestError struct {
	Content    []byte
	StatusCode int
	Response   *http.Response
}

func (GenericRequestError) Error ¶

func (e GenericRequestError) Error() string

type GeoJson ¶

type GeoJson interface{}

* * GeoJSON Geometry represents a [Geometry Object](https://datatracker.ietf.org/doc/html/rfc7946#section-3.1) as defined in the GeoJSON standard. *

type GeoJsonPoint ¶

type GeoJsonPoint struct {
	// Longitude (stored on index `[0]`) and latitude (stored on index `[1]`) of the [Point](https://datatracker.ietf.org/doc/html/rfc7946#section-3.1.2).
	Coordinates []float64 `json:"coordinates"`
}

func (GeoJsonPoint) MarshalJSON ¶

func (obj GeoJsonPoint) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type GoogleCloudFunctionDestination ¶

type GoogleCloudFunctionDestination struct {
	// URL to the target function.
	Url string `json:"url"`
}

* * For GoogleCloudFunction destinations, you need to grant permissions to the `extensions@commercetools-platform.iam.gserviceaccount.com` service account to invoke your function. If your function's version is 1st gen, grant the service account the IAM role `Cloud Functions Invoker`. For version 2nd gen, assign the IAM role `Cloud Run Invoker` using the Cloud Run console. *

func (GoogleCloudFunctionDestination) MarshalJSON ¶

func (obj GoogleCloudFunctionDestination) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type GoogleCloudPubSubDestination ¶

type GoogleCloudPubSubDestination struct {
	// ID of the Google Cloud project that contains the Pub/Sub topic.
	ProjectId string `json:"projectId"`
	// Name of the topic.
	Topic string `json:"topic"`
}

* * Destination for [Google Cloud Pub/Sub](https://cloud.google.com/pubsub/) that can be used * for [Pull subscriptions](https://cloud.google.com/pubsub/docs/pull) as well as for [Push subscriptions](https://cloud.google.com/pubsub/docs/push). * The `topic` must give the `pubsub.topics.publish` permission to the service account `subscriptions@commercetools-platform.iam.gserviceaccount.com`. * If used with the CloudEventsFormat(#cloudeventsformat), the message conforms to the [PubSub Protocol Binding](https://github.com/google/knative-gcp/blob/master/docs/spec/pubsub-protocol-binding.md) of the [Structured Content Mode](https://github.com/google/knative-gcp/blob/master/docs/spec/pubsub-protocol-binding.md#32-structured-content-mode). *

func (GoogleCloudPubSubDestination) MarshalJSON ¶

func (obj GoogleCloudPubSubDestination) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type GraphQLAnonymousIdAlreadyInUseError ¶

type GraphQLAnonymousIdAlreadyInUseError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the anonymous ID is being used by another resource. * * The client application should choose another anonymous ID or retrieve an automatically generated one. *

func (*GraphQLAnonymousIdAlreadyInUseError) DecodeStruct ¶

func (obj *GraphQLAnonymousIdAlreadyInUseError) DecodeStruct(src map[string]interface{}) error

func (GraphQLAnonymousIdAlreadyInUseError) MarshalJSON ¶

func (obj GraphQLAnonymousIdAlreadyInUseError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLAnonymousIdAlreadyInUseError) UnmarshalJSON ¶

func (obj *GraphQLAnonymousIdAlreadyInUseError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLAssociateMissingPermissionError ¶

type GraphQLAssociateMissingPermissionError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// [ResourceIdentifier](ctp:api:type:CustomerResourceIdentifier) to the [Associate](ctp:api:type:Associate) that tried to perform the action.
	Associate CustomerResourceIdentifier `json:"associate"`
	// [ResourceIdentifier](ctp:api:type:BusinessUnitResourceIdentifier) to the [BusinessUnit](ctp:api:type:BusinessUnit).
	BusinessUnit BusinessUnitResourceIdentifier `json:"businessUnit"`
	// [ResourceIdentifier](ctp:api:type:CustomerResourceIdentifier) of the [Associate](ctp:api:type:Associate) on whose behalf the action is performed.
	AssociateOnBehalf *CustomerResourceIdentifier `json:"associateOnBehalf,omitempty"`
	// The Permissions that the [Associate](ctp:api:type:Associate) performing the action lacks. At least one of these Permissions is needed.
	Permissions []Permission `json:"permissions"`
}

* * Returned when an Associate(/projects/business-units#associate) is missing a Permission(/projects/associate-roles#ctp:api:type:Permission) on a [B2B resource](/associates-overview#b2b-resources). *

func (*GraphQLAssociateMissingPermissionError) DecodeStruct ¶

func (obj *GraphQLAssociateMissingPermissionError) DecodeStruct(src map[string]interface{}) error

func (GraphQLAssociateMissingPermissionError) MarshalJSON ¶

func (obj GraphQLAssociateMissingPermissionError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLAssociateMissingPermissionError) UnmarshalJSON ¶

func (obj *GraphQLAssociateMissingPermissionError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLAttributeDefinitionAlreadyExistsError ¶

type GraphQLAttributeDefinitionAlreadyExistsError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifier of the Product Type containing the conflicting name.
	ConflictingProductTypeId string `json:"conflictingProductTypeId"`
	// Name of the Product Type containing the conflicting name.
	ConflictingProductTypeName string `json:"conflictingProductTypeName"`
	// Name of the conflicting Attribute.
	ConflictingAttributeName string `json:"conflictingAttributeName"`
}

* * Returned when the `name` of the AttributeDefinition(ctp:api:type:AttributeDefinition) conflicts with an existing Attribute. * * The error is returned as a failed response to the [Create ProductType](/../api/projects/productTypes#create-producttype) request or [Change AttributeDefinition Name](ctp:api:type:ProductTypeChangeAttributeNameAction) update action. *

func (*GraphQLAttributeDefinitionAlreadyExistsError) DecodeStruct ¶

func (obj *GraphQLAttributeDefinitionAlreadyExistsError) DecodeStruct(src map[string]interface{}) error

func (GraphQLAttributeDefinitionAlreadyExistsError) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLAttributeDefinitionAlreadyExistsError) UnmarshalJSON ¶

func (obj *GraphQLAttributeDefinitionAlreadyExistsError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLAttributeDefinitionTypeConflictError ¶

type GraphQLAttributeDefinitionTypeConflictError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifier of the Product Type containing the conflicting name.
	ConflictingProductTypeId string `json:"conflictingProductTypeId"`
	// Name of the Product Type containing the conflicting name.
	ConflictingProductTypeName string `json:"conflictingProductTypeName"`
	// Name of the conflicting Attribute.
	ConflictingAttributeName string `json:"conflictingAttributeName"`
}

* * Returned when the `type` is different for an AttributeDefinition using the same `name` in multiple Product Types. * * The error is returned as a failed response to the [Create ProductType](/../api/projects/productTypes#create-producttype) request. *

func (*GraphQLAttributeDefinitionTypeConflictError) DecodeStruct ¶

func (obj *GraphQLAttributeDefinitionTypeConflictError) DecodeStruct(src map[string]interface{}) error

func (GraphQLAttributeDefinitionTypeConflictError) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLAttributeDefinitionTypeConflictError) UnmarshalJSON ¶

func (obj *GraphQLAttributeDefinitionTypeConflictError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLAttributeNameDoesNotExistError ¶

type GraphQLAttributeNameDoesNotExistError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Non-existent Attribute name.
	InvalidAttributeName string `json:"invalidAttributeName"`
}

* * Returned when an AttributeDefinition(ctp:api:type:AttributeDefinition) does not exist for an Attribute `name`. * * The error is returned as a failed response to the [Change AttributeDefinition Name](ctp:api:type:ProductTypeChangeAttributeNameAction) update action. *

func (*GraphQLAttributeNameDoesNotExistError) DecodeStruct ¶

func (obj *GraphQLAttributeNameDoesNotExistError) DecodeStruct(src map[string]interface{}) error

func (GraphQLAttributeNameDoesNotExistError) MarshalJSON ¶

func (obj GraphQLAttributeNameDoesNotExistError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLAttributeNameDoesNotExistError) UnmarshalJSON ¶

func (obj *GraphQLAttributeNameDoesNotExistError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLBadGatewayError ¶

type GraphQLBadGatewayError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a server-side problem is caused by scaling infrastructure resources. * * The client application should retry the request with exponential backoff up to a point where further delay is unacceptable. *

func (*GraphQLBadGatewayError) DecodeStruct ¶

func (obj *GraphQLBadGatewayError) DecodeStruct(src map[string]interface{}) error

func (GraphQLBadGatewayError) MarshalJSON ¶

func (obj GraphQLBadGatewayError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLBadGatewayError) UnmarshalJSON ¶

func (obj *GraphQLBadGatewayError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLConcurrentModificationError ¶

type GraphQLConcurrentModificationError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Current version of the resource.
	CurrentVersion *int `json:"currentVersion,omitempty"`
}

* * Returned when the request conflicts with the current state of the involved resources. Typically, the request attempts to modify a resource that is out of date (that is modified by another client since it was last retrieved). * The client application should resolve the conflict (with or without involving the end-user) before retrying the request. *

func (*GraphQLConcurrentModificationError) DecodeStruct ¶

func (obj *GraphQLConcurrentModificationError) DecodeStruct(src map[string]interface{}) error

func (GraphQLConcurrentModificationError) MarshalJSON ¶

func (obj GraphQLConcurrentModificationError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLConcurrentModificationError) UnmarshalJSON ¶

func (obj *GraphQLConcurrentModificationError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLCountryNotConfiguredInStoreError ¶

type GraphQLCountryNotConfiguredInStoreError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Countries configured for the Store.
	StoreCountries []string `json:"storeCountries"`
	// The country that is not configured for the Store but referenced on the Cart or Order.
	Country string `json:"country"`
}

* * Returned when a Cart(ctp:api:type:Cart) or an Order(ctp:api:type:Order) in a Store(ctp:api:type:Store) references a country that is not included in the countries configured for the Store. * * The error is returned as a failed response to: * * - [Create Cart in Store](ctp:api:endpoint:/{projectKey}/in-store/carts:POST) request and [Set Country](ctp:api:type:CartSetCountryAction) update action on Carts. * - [Create Cart in Store](ctp:api:endpoint:/{projectKey}/in-store/me/carts:POST) request and [Set Country](ctp:api:type:MyCartSetCountryAction) update action on My Carts. * - [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests on Orders. * - [Create Order from Cart in a Store](ctp:api:endpoint:/{projectKey}/in-store/me/orders:POST) requests on My Orders. * - [Create Order from Quote](ctp:api:endpoint:/{projectKey}/orders/quotes:POST) requests on Orders. * - [Create Order from Quote](ctp:api:endpoint:/{projectKey}/me/orders/quotes:POST) requests on My Orders. * - [Create Order by Import](ctp:api:endpoint:/{projectKey}/orders/import:POST) request on Order Import. * - [Set Country](ctp:api:type:StagedOrderSetCountryAction) on Order Edits. *

func (*GraphQLCountryNotConfiguredInStoreError) DecodeStruct ¶

func (obj *GraphQLCountryNotConfiguredInStoreError) DecodeStruct(src map[string]interface{}) error

func (GraphQLCountryNotConfiguredInStoreError) MarshalJSON ¶

func (obj GraphQLCountryNotConfiguredInStoreError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLCountryNotConfiguredInStoreError) UnmarshalJSON ¶

func (obj *GraphQLCountryNotConfiguredInStoreError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLDiscountCodeNonApplicableError ¶

type GraphQLDiscountCodeNonApplicableError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Discount Code passed to the Cart.
	DiscountCode *string `json:"discountCode,omitempty"`
	// `"DoesNotExist"` or `"TimeRangeNonApplicable"`
	Reason *string `json:"reason,omitempty"`
	// Unique identifier of the Discount Code.
	DiscountCodeId *string `json:"discountCodeId,omitempty"`
	// Date and time (UTC) from which the Discount Code is valid.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the Discount Code is valid.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Date and time (UTC) the Discount Code validity check was last performed.
	ValidityCheckTime *time.Time `json:"validityCheckTime,omitempty"`
}

* * Returned when the Cart contains a Discount Code with a DiscountCodeState(ctp:api:type:DiscountCodeState) other than `MatchesCart`. * * The error is returned as a failed response to: * * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests on Orders. * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/me/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/me/orders:POST) requests on My Orders. *

func (*GraphQLDiscountCodeNonApplicableError) DecodeStruct ¶

func (obj *GraphQLDiscountCodeNonApplicableError) DecodeStruct(src map[string]interface{}) error

func (GraphQLDiscountCodeNonApplicableError) MarshalJSON ¶

func (obj GraphQLDiscountCodeNonApplicableError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLDiscountCodeNonApplicableError) UnmarshalJSON ¶

func (obj *GraphQLDiscountCodeNonApplicableError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLDuplicateAttributeValueError ¶

type GraphQLDuplicateAttributeValueError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting Attributes.
	Attribute Attribute `json:"attribute"`
}

* * Returned when the `Unique` [AttributeConstraint](ctp:api:type:AttributeConstraintEnum) criteria are not met during an [Update Product](/../api/projects/products#update-product) request. *

func (*GraphQLDuplicateAttributeValueError) DecodeStruct ¶

func (obj *GraphQLDuplicateAttributeValueError) DecodeStruct(src map[string]interface{}) error

func (GraphQLDuplicateAttributeValueError) MarshalJSON ¶

func (obj GraphQLDuplicateAttributeValueError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLDuplicateAttributeValueError) UnmarshalJSON ¶

func (obj *GraphQLDuplicateAttributeValueError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLDuplicateAttributeValuesError ¶

type GraphQLDuplicateAttributeValuesError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting Attributes.
	Attributes []Attribute `json:"attributes"`
}

* * Returned when the `CombinationUnique` [AttributeConstraint](ctp:api:type:AttributeConstraintEnum) criteria are not met during an [Update Product](/../api/projects/products#update-product) request. *

func (*GraphQLDuplicateAttributeValuesError) DecodeStruct ¶

func (obj *GraphQLDuplicateAttributeValuesError) DecodeStruct(src map[string]interface{}) error

func (GraphQLDuplicateAttributeValuesError) MarshalJSON ¶

func (obj GraphQLDuplicateAttributeValuesError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLDuplicateAttributeValuesError) UnmarshalJSON ¶

func (obj *GraphQLDuplicateAttributeValuesError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLDuplicateEnumValuesError ¶

type GraphQLDuplicateEnumValuesError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Duplicate keys.
	Duplicates []string `json:"duplicates"`
}

* * Returned when an AttributeEnumType(ctp:api:type:AttributeEnumType) or AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType) contains duplicate keys. *

func (*GraphQLDuplicateEnumValuesError) DecodeStruct ¶

func (obj *GraphQLDuplicateEnumValuesError) DecodeStruct(src map[string]interface{}) error

func (GraphQLDuplicateEnumValuesError) MarshalJSON ¶

func (obj GraphQLDuplicateEnumValuesError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLDuplicateEnumValuesError) UnmarshalJSON ¶

func (obj *GraphQLDuplicateEnumValuesError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLDuplicateFieldError ¶

type GraphQLDuplicateFieldError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Name of the conflicting field.
	Field string `json:"field"`
	// Conflicting duplicate value.
	DuplicateValue interface{} `json:"duplicateValue"`
}

* * Returned when a field value conflicts with an existing value causing a duplicate. *

func (*GraphQLDuplicateFieldError) DecodeStruct ¶

func (obj *GraphQLDuplicateFieldError) DecodeStruct(src map[string]interface{}) error

func (GraphQLDuplicateFieldError) MarshalJSON ¶

func (obj GraphQLDuplicateFieldError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLDuplicateFieldError) UnmarshalJSON ¶

func (obj *GraphQLDuplicateFieldError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLDuplicateFieldWithConflictingResourceError ¶

type GraphQLDuplicateFieldWithConflictingResourceError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Name of the conflicting field.
	Field string `json:"field"`
	// Conflicting duplicate value.
	DuplicateValue interface{} `json:"duplicateValue"`
	// Reference to the resource that has the conflicting value.
	ConflictingResource Reference `json:"conflictingResource"`
}

* * Returned when a field value conflicts with an existing value stored in a particular resource causing a duplicate. *

func (*GraphQLDuplicateFieldWithConflictingResourceError) DecodeStruct ¶

func (obj *GraphQLDuplicateFieldWithConflictingResourceError) DecodeStruct(src map[string]interface{}) error

func (GraphQLDuplicateFieldWithConflictingResourceError) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLDuplicateFieldWithConflictingResourceError) UnmarshalJSON ¶

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLDuplicatePriceKeyError ¶

type GraphQLDuplicatePriceKeyError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting Embedded Price.
	ConflictingPrice Price `json:"conflictingPrice"`
}

* * Returned when a Price key conflicts with an existing key. * * Keys of Embedded Prices must be unique per ProductVariant. *

func (*GraphQLDuplicatePriceKeyError) DecodeStruct ¶

func (obj *GraphQLDuplicatePriceKeyError) DecodeStruct(src map[string]interface{}) error

func (GraphQLDuplicatePriceKeyError) MarshalJSON ¶

func (obj GraphQLDuplicatePriceKeyError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLDuplicatePriceKeyError) UnmarshalJSON ¶

func (obj *GraphQLDuplicatePriceKeyError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLDuplicatePriceScopeError ¶

type GraphQLDuplicatePriceScopeError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting Embedded Price.
	ConflictingPrice Price `json:"conflictingPrice"`
}

* * Returned when a Price scope conflicts with an existing one during an [Update Product](/../api/projects/products#update-product) request. * * Every Price of a Product Variant must have a distinct combination of currency, Customer Group, country, and Channel that constitute the scope of a Price. *

func (*GraphQLDuplicatePriceScopeError) DecodeStruct ¶

func (obj *GraphQLDuplicatePriceScopeError) DecodeStruct(src map[string]interface{}) error

func (GraphQLDuplicatePriceScopeError) MarshalJSON ¶

func (obj GraphQLDuplicatePriceScopeError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLDuplicatePriceScopeError) UnmarshalJSON ¶

func (obj *GraphQLDuplicatePriceScopeError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLDuplicateStandalonePriceScopeError ¶

type GraphQLDuplicateStandalonePriceScopeError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Reference to the conflicting Standalone Price.
	ConflictingStandalonePrice StandalonePriceReference `json:"conflictingStandalonePrice"`
	// SKU of the [ProductVariant](ctp:api:type:ProductVariant) to which the conflicting Standalone Price is associated.
	Sku string `json:"sku"`
	// Currency code of the country.
	Currency string `json:"currency"`
	// Country code of the geographic location.
	Country *string `json:"country,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) for which the Standalone Price is valid.
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
	// [Channel](ctp:api:type:Channel) for which the Standalone Price is valid.
	Channel *ChannelResourceIdentifier `json:"channel,omitempty"`
	// Date and time (UTC) from which the Standalone Price is valid.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the Standalone Price is valid.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

* * Returned when the given Price scope conflicts with the Price scope of an existing Standalone Price. * Every Standalone Price associated with the same SKU must have a distinct combination of currency, country, Customer Group, Channel, and validity periods (`validFrom` and `validUntil`). * * The error is returned as a failed response to the [Create StandalonePrice](/../api/projects/standalone-prices#create-standaloneprice) request. *

func (*GraphQLDuplicateStandalonePriceScopeError) DecodeStruct ¶

func (obj *GraphQLDuplicateStandalonePriceScopeError) DecodeStruct(src map[string]interface{}) error

func (GraphQLDuplicateStandalonePriceScopeError) MarshalJSON ¶

func (obj GraphQLDuplicateStandalonePriceScopeError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLDuplicateStandalonePriceScopeError) UnmarshalJSON ¶

func (obj *GraphQLDuplicateStandalonePriceScopeError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLDuplicateVariantValuesError ¶

type GraphQLDuplicateVariantValuesError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Every Product Variant must have a distinct combination of SKU, prices, and custom Attribute values.
	VariantValues VariantValues `json:"variantValues"`
}

* * Returned when a [Product Variant](ctp:api:type:ProductVariant) value conflicts with an existing one during an [Update Product](/../api/projects/products#update-product) request. *

func (*GraphQLDuplicateVariantValuesError) DecodeStruct ¶

func (obj *GraphQLDuplicateVariantValuesError) DecodeStruct(src map[string]interface{}) error

func (GraphQLDuplicateVariantValuesError) MarshalJSON ¶

func (obj GraphQLDuplicateVariantValuesError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLDuplicateVariantValuesError) UnmarshalJSON ¶

func (obj *GraphQLDuplicateVariantValuesError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLEditPreviewFailedError ¶

type GraphQLEditPreviewFailedError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// State of the OrderEdit where the `stagedActions` cannot be applied to the Order.
	Result OrderEditPreviewFailure `json:"result"`
}

* * Returned when a preview to find an appropriate Shipping Method for an OrderEdit could not be generated. * * The error is returned as a failed response to the [Get Shipping Methods for an OrderEdit](/../api/projects/shippingMethods#get-shippingmethods-for-an-orderedit) request. *

func (*GraphQLEditPreviewFailedError) DecodeStruct ¶

func (obj *GraphQLEditPreviewFailedError) DecodeStruct(src map[string]interface{}) error

func (GraphQLEditPreviewFailedError) MarshalJSON ¶

func (obj GraphQLEditPreviewFailedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLEditPreviewFailedError) UnmarshalJSON ¶

func (obj *GraphQLEditPreviewFailedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLEnumKeyAlreadyExistsError ¶

type GraphQLEnumKeyAlreadyExistsError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting enum key.
	ConflictingEnumKey string `json:"conflictingEnumKey"`
	// Name of the conflicting Attribute.
	ConflictingAttributeName string `json:"conflictingAttributeName"`
}

* * Returned when an AttributeEnumType(ctp:api:type:AttributeEnumType) or AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType) contains a key that already exists. *

func (*GraphQLEnumKeyAlreadyExistsError) DecodeStruct ¶

func (obj *GraphQLEnumKeyAlreadyExistsError) DecodeStruct(src map[string]interface{}) error

func (GraphQLEnumKeyAlreadyExistsError) MarshalJSON ¶

func (obj GraphQLEnumKeyAlreadyExistsError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLEnumKeyAlreadyExistsError) UnmarshalJSON ¶

func (obj *GraphQLEnumKeyAlreadyExistsError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLEnumKeyDoesNotExistError ¶

type GraphQLEnumKeyDoesNotExistError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Conflicting enum key.
	ConflictingEnumKey string `json:"conflictingEnumKey"`
	// Name of the conflicting Attribute.
	ConflictingAttributeName string `json:"conflictingAttributeName"`
}

* * Returned when an AttributeEnumType(ctp:api:type:AttributeEnumType) or AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType) already contains a value with the given key. * * The error is returned as a failed response to the [Change the key of an EnumValue](ctp:api:type:ProductTypeChangeEnumKeyAction) update action. *

func (*GraphQLEnumKeyDoesNotExistError) DecodeStruct ¶

func (obj *GraphQLEnumKeyDoesNotExistError) DecodeStruct(src map[string]interface{}) error

func (GraphQLEnumKeyDoesNotExistError) MarshalJSON ¶

func (obj GraphQLEnumKeyDoesNotExistError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLEnumKeyDoesNotExistError) UnmarshalJSON ¶

func (obj *GraphQLEnumKeyDoesNotExistError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLEnumValueIsUsedError ¶

type GraphQLEnumValueIsUsedError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when an enum value cannot be removed from an Attribute as it is being used by a Product. * * The error is returned as a failed response to the [Remove EnumValues from AttributeDefinition](ctp:api:type:ProductTypeRemoveEnumValuesAction) update action. *

func (*GraphQLEnumValueIsUsedError) DecodeStruct ¶

func (obj *GraphQLEnumValueIsUsedError) DecodeStruct(src map[string]interface{}) error

func (GraphQLEnumValueIsUsedError) MarshalJSON ¶

func (obj GraphQLEnumValueIsUsedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLEnumValueIsUsedError) UnmarshalJSON ¶

func (obj *GraphQLEnumValueIsUsedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLEnumValuesMustMatchError ¶

type GraphQLEnumValuesMustMatchError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when during an order update of AttributeEnumType(ctp:api:type:AttributeEnumType) or AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType) the new enum values do not match the existing ones. * * The error is returned as a failed response to the [Change the order of EnumValues](ctp:api:type:ProductTypeChangePlainEnumValueOrderAction) and [Change the order of LocalizedEnumValues](ctp:api:type:ProductTypeChangeLocalizedEnumValueOrderAction) update actions. *

func (*GraphQLEnumValuesMustMatchError) DecodeStruct ¶

func (obj *GraphQLEnumValuesMustMatchError) DecodeStruct(src map[string]interface{}) error

func (GraphQLEnumValuesMustMatchError) MarshalJSON ¶

func (obj GraphQLEnumValuesMustMatchError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLEnumValuesMustMatchError) UnmarshalJSON ¶

func (obj *GraphQLEnumValuesMustMatchError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLError ¶

type GraphQLError struct {
	Message   string                 `json:"message"`
	Locations []GraphQLErrorLocation `json:"locations"`
	Path      []interface{}          `json:"path"`
	// Represents a single error.
	Extensions GraphQLErrorObject `json:"extensions"`
}

func (GraphQLError) Error ¶

func (obj GraphQLError) Error() string

func (GraphQLError) MarshalJSON ¶

func (obj GraphQLError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLError) UnmarshalJSON ¶

func (obj *GraphQLError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLErrorLocation ¶

type GraphQLErrorLocation struct {
	Line   int `json:"line"`
	Column int `json:"column"`
}

type GraphQLErrorObject ¶

type GraphQLErrorObject interface{}

* * Represents a single error.

type GraphQLExtensionBadResponseError ¶

type GraphQLExtensionBadResponseError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// User-defined localized description of the error.
	LocalizedMessage *LocalizedString `json:"localizedMessage,omitempty"`
	// Any information that should be returned to the API caller.
	ExtensionExtraInfo *interface{} `json:"extensionExtraInfo,omitempty"`
	// Additional errors related to the API Extension.
	ExtensionErrors []ExtensionError `json:"extensionErrors"`
	// The response body returned by the Extension.
	ExtensionBody *string `json:"extensionBody,omitempty"`
	// Http status code returned by the Extension.
	ExtensionStatusCode *int `json:"extensionStatusCode,omitempty"`
	// Unique identifier of the Extension.
	ExtensionId string `json:"extensionId"`
	// User-defined unique identifier of the Extension.
	ExtensionKey *string `json:"extensionKey,omitempty"`
}

* * Returned when the response from the API Extension could not be parsed successfully (such as a `500` HTTP status code, or an invalid JSON response). *

func (*GraphQLExtensionBadResponseError) DecodeStruct ¶

func (obj *GraphQLExtensionBadResponseError) DecodeStruct(src map[string]interface{}) error

func (GraphQLExtensionBadResponseError) MarshalJSON ¶

func (obj GraphQLExtensionBadResponseError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLExtensionBadResponseError) UnmarshalJSON ¶

func (obj *GraphQLExtensionBadResponseError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLExtensionNoResponseError ¶

type GraphQLExtensionNoResponseError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifier of the API Extension.
	ExtensionId string `json:"extensionId"`
	// User-defined unique identifier of the API Extension, if available.
	ExtensionKey *string `json:"extensionKey,omitempty"`
}

* * Returned when the API Extension does not respond within the [time limit](/../api/projects/api-extensions#time-limits), or could not be reached. *

func (*GraphQLExtensionNoResponseError) DecodeStruct ¶

func (obj *GraphQLExtensionNoResponseError) DecodeStruct(src map[string]interface{}) error

func (GraphQLExtensionNoResponseError) MarshalJSON ¶

func (obj GraphQLExtensionNoResponseError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLExtensionNoResponseError) UnmarshalJSON ¶

func (obj *GraphQLExtensionNoResponseError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLExtensionPredicateEvaluationFailedError ¶

type GraphQLExtensionPredicateEvaluationFailedError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Details about the API Extension that was involved in the error.
	ErrorByExtension ErrorByExtension `json:"errorByExtension"`
}

* * Returned when the predicate defined in the ExtensionTrigger(ctp:api:type:ExtensionTrigger) could not be evaluated due to a missing field. *

func (*GraphQLExtensionPredicateEvaluationFailedError) DecodeStruct ¶

func (obj *GraphQLExtensionPredicateEvaluationFailedError) DecodeStruct(src map[string]interface{}) error

func (GraphQLExtensionPredicateEvaluationFailedError) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLExtensionPredicateEvaluationFailedError) UnmarshalJSON ¶

func (obj *GraphQLExtensionPredicateEvaluationFailedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLExtensionUpdateActionsFailedError ¶

type GraphQLExtensionUpdateActionsFailedError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// User-defined localized description of the error.
	LocalizedMessage *LocalizedString `json:"localizedMessage,omitempty"`
	// Any information that should be returned to the API caller.
	ExtensionExtraInfo *interface{} `json:"extensionExtraInfo,omitempty"`
	// Additional errors related to the API Extension.
	ExtensionErrors []ExtensionError `json:"extensionErrors"`
}

* * Returned when update actions could not be applied to the resource (for example, because a referenced resource does not exist). * This would result in a [400 Bad Request](#400-bad-request) response if the same update action was sent from a regular client. *

func (*GraphQLExtensionUpdateActionsFailedError) DecodeStruct ¶

func (obj *GraphQLExtensionUpdateActionsFailedError) DecodeStruct(src map[string]interface{}) error

func (GraphQLExtensionUpdateActionsFailedError) MarshalJSON ¶

func (obj GraphQLExtensionUpdateActionsFailedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLExtensionUpdateActionsFailedError) UnmarshalJSON ¶

func (obj *GraphQLExtensionUpdateActionsFailedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLExternalOAuthFailedError ¶

type GraphQLExternalOAuthFailedError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when an [external OAuth Introspection endpoint](/../api/authorization#requesting-an-access-token-using-an-external-oauth-server) does not return a response within the [time limit](/../api/authorization#time-limits), or the response isn't compliant with [RFC 7662](https://www.rfc-editor.org/rfc/rfc7662.html) (for example, an HTTP status code like `500`). *

func (*GraphQLExternalOAuthFailedError) DecodeStruct ¶

func (obj *GraphQLExternalOAuthFailedError) DecodeStruct(src map[string]interface{}) error

func (GraphQLExternalOAuthFailedError) MarshalJSON ¶

func (obj GraphQLExternalOAuthFailedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLExternalOAuthFailedError) UnmarshalJSON ¶

func (obj *GraphQLExternalOAuthFailedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLFeatureRemovedError ¶

type GraphQLFeatureRemovedError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the requested feature was removed. *

func (*GraphQLFeatureRemovedError) DecodeStruct ¶

func (obj *GraphQLFeatureRemovedError) DecodeStruct(src map[string]interface{}) error

func (GraphQLFeatureRemovedError) MarshalJSON ¶

func (obj GraphQLFeatureRemovedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLFeatureRemovedError) UnmarshalJSON ¶

func (obj *GraphQLFeatureRemovedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLGeneralError ¶

type GraphQLGeneralError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a server-side problem occurs. * * If you encounter this error, report it using the [Support Portal](https://support.commercetools.com). *

func (*GraphQLGeneralError) DecodeStruct ¶

func (obj *GraphQLGeneralError) DecodeStruct(src map[string]interface{}) error

func (GraphQLGeneralError) MarshalJSON ¶

func (obj GraphQLGeneralError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLGeneralError) UnmarshalJSON ¶

func (obj *GraphQLGeneralError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLInsufficientScopeError ¶

type GraphQLInsufficientScopeError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

func (*GraphQLInsufficientScopeError) DecodeStruct ¶

func (obj *GraphQLInsufficientScopeError) DecodeStruct(src map[string]interface{}) error

func (GraphQLInsufficientScopeError) MarshalJSON ¶

func (obj GraphQLInsufficientScopeError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLInsufficientScopeError) UnmarshalJSON ¶

func (obj *GraphQLInsufficientScopeError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLInternalConstraintViolatedError ¶

type GraphQLInternalConstraintViolatedError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when certain API-specific constraints were not met. For example, the specified [Discount Code](ctp:api:type:DiscountCode) was never applied and cannot be updated. *

func (*GraphQLInternalConstraintViolatedError) DecodeStruct ¶

func (obj *GraphQLInternalConstraintViolatedError) DecodeStruct(src map[string]interface{}) error

func (GraphQLInternalConstraintViolatedError) MarshalJSON ¶

func (obj GraphQLInternalConstraintViolatedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLInternalConstraintViolatedError) UnmarshalJSON ¶

func (obj *GraphQLInternalConstraintViolatedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLInvalidCredentialsError ¶

type GraphQLInvalidCredentialsError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a Customer with the given credentials (matching the given email/password pair) is not found and authentication fails. * * The error is returned as a failed response to: * * - [Authenticate a global Customer (Sign-in)](/../api/projects/customers#authenticate-sign-in-customer) and [Authenticate Customer (Sign-in) in a Store](/../api/projects/customers#authenticate-sign-in-customer-in-store) requests on Customers. * - [Authenticating Customer (Sign-in)](/../api/projects/me-profile#authenticate-sign-in-customer) and [Authenticate Customer (Sign-in) in a Store](/../api/projects/me-profile#authenticate-sign-in-customer-in-store) requests on My Customer Profile. *

func (*GraphQLInvalidCredentialsError) DecodeStruct ¶

func (obj *GraphQLInvalidCredentialsError) DecodeStruct(src map[string]interface{}) error

func (GraphQLInvalidCredentialsError) MarshalJSON ¶

func (obj GraphQLInvalidCredentialsError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLInvalidCredentialsError) UnmarshalJSON ¶

func (obj *GraphQLInvalidCredentialsError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLInvalidCurrentPasswordError ¶

type GraphQLInvalidCurrentPasswordError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the current password of the Customer does not match. * * The error is returned as a failed response to: * * - [Change Customer Password](/../api/projects/customers#change-password-of-customer) and [Change Customer Password in a Store](/../api/projects/customers#change-password-of-customer-in-store) requests on Customers. * - [Change Customer Password](/../api/projects/me-profile#change-password-of-customer) and [Change Customer Password in a Store](/../api/projects/me-profile#change-password-of-customer-in-store) requests on My Customer Profile. *

func (*GraphQLInvalidCurrentPasswordError) DecodeStruct ¶

func (obj *GraphQLInvalidCurrentPasswordError) DecodeStruct(src map[string]interface{}) error

func (GraphQLInvalidCurrentPasswordError) MarshalJSON ¶

func (obj GraphQLInvalidCurrentPasswordError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLInvalidCurrentPasswordError) UnmarshalJSON ¶

func (obj *GraphQLInvalidCurrentPasswordError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLInvalidFieldError ¶

type GraphQLInvalidFieldError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Name of the field with the invalid value.
	Field string `json:"field"`
	// Value invalid for the field.
	InvalidValue interface{} `json:"invalidValue"`
	// Fixed set of allowed values for the field, if any.
	AllowedValues []interface{} `json:"allowedValues"`
}

* * Returned when a field has an invalid value. *

func (*GraphQLInvalidFieldError) DecodeStruct ¶

func (obj *GraphQLInvalidFieldError) DecodeStruct(src map[string]interface{}) error

func (GraphQLInvalidFieldError) MarshalJSON ¶

func (obj GraphQLInvalidFieldError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLInvalidFieldError) UnmarshalJSON ¶

func (obj *GraphQLInvalidFieldError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLInvalidInputError ¶

type GraphQLInvalidInputError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when an invalid input has been sent. *

func (*GraphQLInvalidInputError) DecodeStruct ¶

func (obj *GraphQLInvalidInputError) DecodeStruct(src map[string]interface{}) error

func (GraphQLInvalidInputError) MarshalJSON ¶

func (obj GraphQLInvalidInputError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLInvalidInputError) UnmarshalJSON ¶

func (obj *GraphQLInvalidInputError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLInvalidItemShippingDetailsError ¶

type GraphQLInvalidItemShippingDetailsError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// `"LineItem"` or `"CustomLineItem"`
	Subject string `json:"subject"`
	// Unique identifier of the Line Item or Custom Line Item.
	ItemId string `json:"itemId"`
}

* * Returned when Line Item or Custom Line Item quantities set under ItemShippingDetails(ctp:api:type:ItemShippingDetails) do not match the sum of the quantities in their respective shipping details. * * The error is returned as a failed response to the [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests. *

func (*GraphQLInvalidItemShippingDetailsError) DecodeStruct ¶

func (obj *GraphQLInvalidItemShippingDetailsError) DecodeStruct(src map[string]interface{}) error

func (GraphQLInvalidItemShippingDetailsError) MarshalJSON ¶

func (obj GraphQLInvalidItemShippingDetailsError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLInvalidItemShippingDetailsError) UnmarshalJSON ¶

func (obj *GraphQLInvalidItemShippingDetailsError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLInvalidJsonInputError ¶

type GraphQLInvalidJsonInputError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Further explanation about why the JSON is invalid.
	DetailedErrorMessage string `json:"detailedErrorMessage"`
}

* * Returned when an invalid JSON input has been sent. * Either the JSON is syntactically incorrect or does not conform to the expected shape (for example is missing a required field). * * The client application should validate the input according to the constraints described in the error message before sending the request. *

func (*GraphQLInvalidJsonInputError) DecodeStruct ¶

func (obj *GraphQLInvalidJsonInputError) DecodeStruct(src map[string]interface{}) error

func (GraphQLInvalidJsonInputError) MarshalJSON ¶

func (obj GraphQLInvalidJsonInputError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLInvalidJsonInputError) UnmarshalJSON ¶

func (obj *GraphQLInvalidJsonInputError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLInvalidOperationError ¶

type GraphQLInvalidOperationError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the resources involved in the request are not in a valid state for the operation. * * The client application should validate the constraints described in the error message before sending the request. *

func (*GraphQLInvalidOperationError) DecodeStruct ¶

func (obj *GraphQLInvalidOperationError) DecodeStruct(src map[string]interface{}) error

func (GraphQLInvalidOperationError) MarshalJSON ¶

func (obj GraphQLInvalidOperationError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLInvalidOperationError) UnmarshalJSON ¶

func (obj *GraphQLInvalidOperationError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLInvalidSubjectError ¶

type GraphQLInvalidSubjectError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

func (*GraphQLInvalidSubjectError) DecodeStruct ¶

func (obj *GraphQLInvalidSubjectError) DecodeStruct(src map[string]interface{}) error

func (GraphQLInvalidSubjectError) MarshalJSON ¶

func (obj GraphQLInvalidSubjectError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLInvalidSubjectError) UnmarshalJSON ¶

func (obj *GraphQLInvalidSubjectError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLInvalidTokenError ¶

type GraphQLInvalidTokenError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

func (*GraphQLInvalidTokenError) DecodeStruct ¶

func (obj *GraphQLInvalidTokenError) DecodeStruct(src map[string]interface{}) error

func (GraphQLInvalidTokenError) MarshalJSON ¶

func (obj GraphQLInvalidTokenError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLInvalidTokenError) UnmarshalJSON ¶

func (obj *GraphQLInvalidTokenError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLLanguageUsedInStoresError ¶

type GraphQLLanguageUsedInStoresError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a language cannot be removed from a Project as it is being used by a Store. * * The error is returned as a failed response to the [Change Languages](ctp:api:type:ProjectChangeLanguagesAction) update action. *

func (*GraphQLLanguageUsedInStoresError) DecodeStruct ¶

func (obj *GraphQLLanguageUsedInStoresError) DecodeStruct(src map[string]interface{}) error

func (GraphQLLanguageUsedInStoresError) MarshalJSON ¶

func (obj GraphQLLanguageUsedInStoresError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLLanguageUsedInStoresError) UnmarshalJSON ¶

func (obj *GraphQLLanguageUsedInStoresError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLMatchingPriceNotFoundError ¶

type GraphQLMatchingPriceNotFoundError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifier of a [Product](ctp:api:type:Product).
	ProductId string `json:"productId"`
	// Unique identifier of a [ProductVariant](ctp:api:type:ProductVariant) in the Product.
	VariantId int `json:"variantId"`
	// Currency code of the country.
	Currency *string `json:"currency,omitempty"`
	// Country code of the geographic location.
	Country *string `json:"country,omitempty"`
	// Customer Group associated with the Price.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// Channel associated with the Price.
	Channel *ChannelReference `json:"channel,omitempty"`
}

* * Returned when the Product Variant does not have a Price according to the Product(ctp:api:type:Product) `priceMode` value for a selected currency, country, Customer Group, or Channel. * * The error is returned as a failed response to: * * - [Add LineItem](ctp:api:type:CartAddLineItemAction), [Add CustomLineItem](ctp:api:type:CartAddCustomLineItemAction), and [Add DiscountCode](ctp:api:type:CartAddDiscountCodeAction) update actions on Carts. * - [Add LineItem](ctp:api:type:StagedOrderAddLineItemAction), [Add CustomLineItem](ctp:api:type:StagedOrderAddCustomLineItemAction), and [Add DiscountCode](ctp:api:type:StagedOrderAddDiscountCodeAction) update actions on Order Edits. * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests on Orders. * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/me/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/me/orders:POST) requests on My Orders. *

func (*GraphQLMatchingPriceNotFoundError) DecodeStruct ¶

func (obj *GraphQLMatchingPriceNotFoundError) DecodeStruct(src map[string]interface{}) error

func (GraphQLMatchingPriceNotFoundError) MarshalJSON ¶

func (obj GraphQLMatchingPriceNotFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLMatchingPriceNotFoundError) UnmarshalJSON ¶

func (obj *GraphQLMatchingPriceNotFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLMaxResourceLimitExceededError ¶

type GraphQLMaxResourceLimitExceededError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Resource type that reached its maximum limit of configured elements (for example, 100 Zones per Project).
	ExceededResource ReferenceTypeId `json:"exceededResource"`
}

* * Returned when a resource type cannot be created as it has reached its [limits](/../api/limits). * * The limits must be adjusted for this resource before sending the request again. *

func (*GraphQLMaxResourceLimitExceededError) DecodeStruct ¶

func (obj *GraphQLMaxResourceLimitExceededError) DecodeStruct(src map[string]interface{}) error

func (GraphQLMaxResourceLimitExceededError) MarshalJSON ¶

func (obj GraphQLMaxResourceLimitExceededError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLMaxResourceLimitExceededError) UnmarshalJSON ¶

func (obj *GraphQLMaxResourceLimitExceededError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLMissingRoleOnChannelError ¶

type GraphQLMissingRoleOnChannelError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a given [Channel](ctp:api:type:Channel).
	Channel *ChannelResourceIdentifier `json:"channel,omitempty"`
	// - `ProductDistribution` for Product Distribution Channels allowed for the Store. Also required for [Standalone Prices](ctp:api:type:StandalonePrice).
	// - `InventorySupply` for Inventory Supply Channels allowed for the Store.
	MissingRole ChannelRoleEnum `json:"missingRole"`
}

* * Returned when one of the following states occur: * * - Channel(ctp:api:type:Channel) is added or set on a Store(ctp:api:type:Store) with missing Channel `roles`. * - [Standalone Price](/../api/projects/standalone-prices#create-standaloneprice) references a Channel that does not contain the `ProductDistribution` role. * * The error is returned as a failed response to: * * - [Add Distribution Channel](ctp:api:type:StoreAddDistributionChannelAction), [Set Distribution Channel](ctp:api:type:StoreSetDistributionChannelsAction), [Add Supply Channel](ctp:api:type:StoreAddSupplyChannelAction), and [Set Supply Channel](ctp:api:type:StoreSetSupplyChannelsAction) update actions. * - [Create a Standalone Price](/../api/projects/standalone-prices#create-standaloneprice) request. *

func (*GraphQLMissingRoleOnChannelError) DecodeStruct ¶

func (obj *GraphQLMissingRoleOnChannelError) DecodeStruct(src map[string]interface{}) error

func (GraphQLMissingRoleOnChannelError) MarshalJSON ¶

func (obj GraphQLMissingRoleOnChannelError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLMissingRoleOnChannelError) UnmarshalJSON ¶

func (obj *GraphQLMissingRoleOnChannelError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLMissingTaxRateForCountryError ¶

type GraphQLMissingTaxRateForCountryError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifier of the [TaxCategory](ctp:api:type:TaxCategory).
	TaxCategoryId string `json:"taxCategoryId"`
	// Country code of the geographic location.
	Country *string `json:"country,omitempty"`
	// State within the country, such as Texas in the United States.
	State *string `json:"state,omitempty"`
}

* * Returned when the Tax Category of at least one of the `lineItems`, `customLineItems`, or `shippingInfo` in the Cart(ctp:api:type:Cart) is missing the TaxRate(ctp:api:type:TaxRate) matching `country` and `state` given in the `shippingAddress` of that Cart. * * The error is returned as a failed response to: * * - [Set Default Shipping Address](ctp:api:type:CustomerSetDefaultShippingAddressAction), [Add LineItem](ctp:api:type:CartAddLineItemAction), [Add CustomLineItem](ctp:api:type:CartAddCustomLineItemAction), [Set Shipping Address](ctp:api:type:CartSetShippingAddressAction), [Add LineItem](ctp:api:type:MyCartAddLineItemAction), [Add LineItem](ctp:api:type:StagedOrderAddLineItemAction), and [Add CustomLineItem](ctp:api:type:StagedOrderAddCustomLineItemAction) update actions * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests. *

func (*GraphQLMissingTaxRateForCountryError) DecodeStruct ¶

func (obj *GraphQLMissingTaxRateForCountryError) DecodeStruct(src map[string]interface{}) error

func (GraphQLMissingTaxRateForCountryError) MarshalJSON ¶

func (obj GraphQLMissingTaxRateForCountryError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLMissingTaxRateForCountryError) UnmarshalJSON ¶

func (obj *GraphQLMissingTaxRateForCountryError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLMoneyOverflowError ¶

type GraphQLMoneyOverflowError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a Money(ctp:api:type:Money) operation overflows the 64-bit integer range. * See [Money usage](/types#usage) for more information. *

func (*GraphQLMoneyOverflowError) DecodeStruct ¶

func (obj *GraphQLMoneyOverflowError) DecodeStruct(src map[string]interface{}) error

func (GraphQLMoneyOverflowError) MarshalJSON ¶

func (obj GraphQLMoneyOverflowError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLMoneyOverflowError) UnmarshalJSON ¶

func (obj *GraphQLMoneyOverflowError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLNoMatchingProductDiscountFoundError ¶

type GraphQLNoMatchingProductDiscountFoundError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a Product Discount could not be found that could be applied to the Price of a Product Variant. * * The error is returned as a failed response to the [Get Matching ProductDiscount](/../api/projects/productDiscounts#get-matching-productdiscount) request. *

func (*GraphQLNoMatchingProductDiscountFoundError) DecodeStruct ¶

func (obj *GraphQLNoMatchingProductDiscountFoundError) DecodeStruct(src map[string]interface{}) error

func (GraphQLNoMatchingProductDiscountFoundError) MarshalJSON ¶

func (obj GraphQLNoMatchingProductDiscountFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLNoMatchingProductDiscountFoundError) UnmarshalJSON ¶

func (obj *GraphQLNoMatchingProductDiscountFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLNotEnabledError ¶

type GraphQLNotEnabledError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the [Project-specific category recommendations feature](/../api/projects/categoryRecommendations#project-specific-category-recommendations) is not enabled for the Project. *

func (*GraphQLNotEnabledError) DecodeStruct ¶

func (obj *GraphQLNotEnabledError) DecodeStruct(src map[string]interface{}) error

func (GraphQLNotEnabledError) MarshalJSON ¶

func (obj GraphQLNotEnabledError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLNotEnabledError) UnmarshalJSON ¶

func (obj *GraphQLNotEnabledError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLObjectNotFoundError ¶

type GraphQLObjectNotFoundError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the requested resource was not found. *

func (*GraphQLObjectNotFoundError) DecodeStruct ¶

func (obj *GraphQLObjectNotFoundError) DecodeStruct(src map[string]interface{}) error

func (GraphQLObjectNotFoundError) MarshalJSON ¶

func (obj GraphQLObjectNotFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLObjectNotFoundError) UnmarshalJSON ¶

func (obj *GraphQLObjectNotFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLOutOfStockError ¶

type GraphQLOutOfStockError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifiers of the Line Items that are out of stock.
	LineItems []string `json:"lineItems"`
	// SKUs of the Line Items that are out of stock.
	Skus []string `json:"skus"`
}

* * Returned when some of the [Line Items](ctp:api:type:LineItem) are out of stock at the time of placing an Order(ctp:api:type:Order). * * The error is returned as a failed response to: * * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST), [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST), and [Create Order by Import](/../api/projects/me-orders) requests on Orders. * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/me/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/me/orders:POST) requests on My Orders. *

func (*GraphQLOutOfStockError) DecodeStruct ¶

func (obj *GraphQLOutOfStockError) DecodeStruct(src map[string]interface{}) error

func (GraphQLOutOfStockError) MarshalJSON ¶

func (obj GraphQLOutOfStockError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLOutOfStockError) UnmarshalJSON ¶

func (obj *GraphQLOutOfStockError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLOverCapacityError ¶

type GraphQLOverCapacityError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the service is having trouble handling the load. * * The client application should retry the request with exponential backoff up to a point where further delay is unacceptable. *

func (*GraphQLOverCapacityError) DecodeStruct ¶

func (obj *GraphQLOverCapacityError) DecodeStruct(src map[string]interface{}) error

func (GraphQLOverCapacityError) MarshalJSON ¶

func (obj GraphQLOverCapacityError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLOverCapacityError) UnmarshalJSON ¶

func (obj *GraphQLOverCapacityError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLOverlappingStandalonePriceValidityError ¶

type GraphQLOverlappingStandalonePriceValidityError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Reference to the conflicting Standalone Price.
	ConflictingStandalonePrice StandalonePriceReference `json:"conflictingStandalonePrice"`
	// SKU of the [ProductVariant](ctp:api:type:ProductVariant) to which the conflicting Standalone Price is associated.
	Sku string `json:"sku"`
	// Currency code of the country.
	Currency string `json:"currency"`
	// Country code of the geographic location.
	Country *string `json:"country,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) for which the Standalone Price is valid.
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
	// [Channel](ctp:api:type:Channel) for which the Standalone Price is valid.
	Channel *ChannelResourceIdentifier `json:"channel,omitempty"`
	// Date and time (UTC) from which the Standalone Price is valid.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the Standalone Price is valid.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Date and time (UTC) from which the conflicting Standalone Price is valid.
	ConflictingValidFrom *time.Time `json:"conflictingValidFrom,omitempty"`
	// Date and time (UTC) until which the conflicting Standalone Price is valid.
	ConflictingValidUntil *time.Time `json:"conflictingValidUntil,omitempty"`
}

* * Returned when a given Price validity period conflicts with an existing one. * Every Standalone Price associated with the same SKU and with the same combination of currency, country, Customer Group, and Channel, must have non-overlapping validity periods (`validFrom` and `validUntil`). * * The error is returned as a failed response to the [Create StandalonePrice](/../api/projects/standalone-prices#create-standaloneprice) request. *

func (*GraphQLOverlappingStandalonePriceValidityError) DecodeStruct ¶

func (obj *GraphQLOverlappingStandalonePriceValidityError) DecodeStruct(src map[string]interface{}) error

func (GraphQLOverlappingStandalonePriceValidityError) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLOverlappingStandalonePriceValidityError) UnmarshalJSON ¶

func (obj *GraphQLOverlappingStandalonePriceValidityError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLPendingOperationError ¶

type GraphQLPendingOperationError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a previous conflicting operation is still pending and needs to finish before the request can succeed. * * The client application should retry the request with exponential backoff up to a point where further delay is unacceptable. * If the error persists, report it using the [Support Portal](https://support.commercetools.com). *

func (*GraphQLPendingOperationError) DecodeStruct ¶

func (obj *GraphQLPendingOperationError) DecodeStruct(src map[string]interface{}) error

func (GraphQLPendingOperationError) MarshalJSON ¶

func (obj GraphQLPendingOperationError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLPendingOperationError) UnmarshalJSON ¶

func (obj *GraphQLPendingOperationError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLPriceChangedError ¶

type GraphQLPriceChangedError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifiers of the Line Items for which the Price or [TaxRate](ctp:api:type:TaxRate) has changed.
	LineItems []string `json:"lineItems"`
	// `true` if the [ShippingRate](ctp:api:type:ShippingRate) has changed.
	Shipping bool `json:"shipping"`
}

* * Returned when the Price, Tax Rate, or Shipping Rate of some Line Items changed since they were last added to the Cart. * * The error is returned as a failed response to: * * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests on Orders. * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/me/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/me/orders:POST) requests on My Orders. *

func (*GraphQLPriceChangedError) DecodeStruct ¶

func (obj *GraphQLPriceChangedError) DecodeStruct(src map[string]interface{}) error

func (GraphQLPriceChangedError) MarshalJSON ¶

func (obj GraphQLPriceChangedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLPriceChangedError) UnmarshalJSON ¶

func (obj *GraphQLPriceChangedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLProductAssignmentMissingError ¶

type GraphQLProductAssignmentMissingError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// [Reference](ctp:api:type:Reference) to the [Product](ctp:api:type:Product) for which the error was returned.
	Product ProductReference `json:"product"`
}

* * Returned when a Product is not assigned to the Product Selection. * The error is returned as a failed response either to the [Set Variant Selection](ctp:api:type:ProductSelectionSetVariantSelectionAction) or to the [Set Variant Exclusion](ctp:api:type:ProductSelectionSetVariantExclusionAction) update action. *

func (*GraphQLProductAssignmentMissingError) DecodeStruct ¶

func (obj *GraphQLProductAssignmentMissingError) DecodeStruct(src map[string]interface{}) error

func (GraphQLProductAssignmentMissingError) MarshalJSON ¶

func (obj GraphQLProductAssignmentMissingError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLProductAssignmentMissingError) UnmarshalJSON ¶

func (obj *GraphQLProductAssignmentMissingError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLProductPresentWithDifferentVariantSelectionError ¶

type GraphQLProductPresentWithDifferentVariantSelectionError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// [Reference](ctp:api:type:Reference) to the [Product](ctp:api:type:Product) for which the error was returned.
	Product ProductReference `json:"product"`
	// Existing Product Variant Selection or Exclusion for the [Product](/../api/projects/products) in the [Product Selection](/../api/projects/product-selections).
	ExistingVariantSelection ProductVariantSelection `json:"existingVariantSelection"`
}

* * Returned when a Product is already assigned to a [Product Selection](/../api/projects/product-selections), but the Product Selection has either a different [Product Variant Selection](ctp:api:type:ProductVariantSelection) or a different [Product Variant Exclusion](ctp:api:type:ProductVariantExclusion). * * The error is returned as a failed response either to the [Add Product](ctp:api:type:ProductSelectionAddProductAction) or to the [Exclude Product](ctp:api:type:ProductSelectionExcludeProductAction) update action. *

func (*GraphQLProductPresentWithDifferentVariantSelectionError) DecodeStruct ¶

func (obj *GraphQLProductPresentWithDifferentVariantSelectionError) DecodeStruct(src map[string]interface{}) error

func (GraphQLProductPresentWithDifferentVariantSelectionError) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLProductPresentWithDifferentVariantSelectionError) UnmarshalJSON ¶

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLProjectNotConfiguredForLanguagesError ¶

type GraphQLProjectNotConfiguredForLanguagesError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Languages configured for the Store.
	Languages []string `json:"languages"`
}

* * Returned when the languages set for a Store are not supported by the Project. * * The error is returned as a failed response to the [Set Languages](ctp:api:type:StoreSetLanguagesAction) update action. *

func (*GraphQLProjectNotConfiguredForLanguagesError) DecodeStruct ¶

func (obj *GraphQLProjectNotConfiguredForLanguagesError) DecodeStruct(src map[string]interface{}) error

func (GraphQLProjectNotConfiguredForLanguagesError) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLProjectNotConfiguredForLanguagesError) UnmarshalJSON ¶

func (obj *GraphQLProjectNotConfiguredForLanguagesError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLQueryComplexityLimitExceededError ¶

type GraphQLQueryComplexityLimitExceededError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

func (*GraphQLQueryComplexityLimitExceededError) DecodeStruct ¶

func (obj *GraphQLQueryComplexityLimitExceededError) DecodeStruct(src map[string]interface{}) error

func (GraphQLQueryComplexityLimitExceededError) MarshalJSON ¶

func (obj GraphQLQueryComplexityLimitExceededError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLQueryComplexityLimitExceededError) UnmarshalJSON ¶

func (obj *GraphQLQueryComplexityLimitExceededError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLQueryTimedOutError ¶

type GraphQLQueryTimedOutError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the query times out. * * If a query constantly times out, please check if it follows the [performance best practices](/../api/predicates/query#performance-considerations). *

func (*GraphQLQueryTimedOutError) DecodeStruct ¶

func (obj *GraphQLQueryTimedOutError) DecodeStruct(src map[string]interface{}) error

func (GraphQLQueryTimedOutError) MarshalJSON ¶

func (obj GraphQLQueryTimedOutError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLQueryTimedOutError) UnmarshalJSON ¶

func (obj *GraphQLQueryTimedOutError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLReferenceExistsError ¶

type GraphQLReferenceExistsError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Type of referenced resource.
	ReferencedBy *ReferenceTypeId `json:"referencedBy,omitempty"`
}

* * Returned when a resource cannot be deleted because it is being referenced by another resource. *

func (*GraphQLReferenceExistsError) DecodeStruct ¶

func (obj *GraphQLReferenceExistsError) DecodeStruct(src map[string]interface{}) error

func (GraphQLReferenceExistsError) MarshalJSON ¶

func (obj GraphQLReferenceExistsError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLReferenceExistsError) UnmarshalJSON ¶

func (obj *GraphQLReferenceExistsError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLReferencedResourceNotFoundError ¶

type GraphQLReferencedResourceNotFoundError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Type of referenced resource.
	TypeId ReferenceTypeId `json:"typeId"`
	// Unique identifier of the referenced resource, if known.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced resource, if known.
	Key *string `json:"key,omitempty"`
}

* * Returned when a resource referenced by a Reference(ctp:api:type:Reference) or a ResourceIdentifier(ctp:api:type:ResourceIdentifier) could not be found. *

func (*GraphQLReferencedResourceNotFoundError) DecodeStruct ¶

func (obj *GraphQLReferencedResourceNotFoundError) DecodeStruct(src map[string]interface{}) error

func (GraphQLReferencedResourceNotFoundError) MarshalJSON ¶

func (obj GraphQLReferencedResourceNotFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLReferencedResourceNotFoundError) UnmarshalJSON ¶

func (obj *GraphQLReferencedResourceNotFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLRequest ¶

type GraphQLRequest struct {
	Query         string               `json:"query"`
	OperationName *string              `json:"operationName,omitempty"`
	Variables     *GraphQLVariablesMap `json:"variables,omitempty"`
}

type GraphQLRequiredFieldError ¶

type GraphQLRequiredFieldError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Name of the field missing the value.
	Field string `json:"field"`
}

* * Returned when a value is not defined for a required field. *

func (*GraphQLRequiredFieldError) DecodeStruct ¶

func (obj *GraphQLRequiredFieldError) DecodeStruct(src map[string]interface{}) error

func (GraphQLRequiredFieldError) MarshalJSON ¶

func (obj GraphQLRequiredFieldError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLRequiredFieldError) UnmarshalJSON ¶

func (obj *GraphQLRequiredFieldError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLResourceNotFoundError ¶

type GraphQLResourceNotFoundError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the resource addressed by the request URL does not exist. *

func (*GraphQLResourceNotFoundError) DecodeStruct ¶

func (obj *GraphQLResourceNotFoundError) DecodeStruct(src map[string]interface{}) error

func (GraphQLResourceNotFoundError) MarshalJSON ¶

func (obj GraphQLResourceNotFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLResourceNotFoundError) UnmarshalJSON ¶

func (obj *GraphQLResourceNotFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLResourceSizeLimitExceededError ¶

type GraphQLResourceSizeLimitExceededError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the resource exceeds the maximum allowed size of 16 MB. *

func (*GraphQLResourceSizeLimitExceededError) DecodeStruct ¶

func (obj *GraphQLResourceSizeLimitExceededError) DecodeStruct(src map[string]interface{}) error

func (GraphQLResourceSizeLimitExceededError) MarshalJSON ¶

func (obj GraphQLResourceSizeLimitExceededError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLResourceSizeLimitExceededError) UnmarshalJSON ¶

func (obj *GraphQLResourceSizeLimitExceededError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLResponse ¶

type GraphQLResponse struct {
	Data   interface{}    `json:"data,omitempty"`
	Errors []GraphQLError `json:"errors"`
}

func (GraphQLResponse) MarshalJSON ¶

func (obj GraphQLResponse) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type GraphQLSearchDeactivatedError ¶

type GraphQLSearchDeactivatedError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the indexing of Product information is deactivated in a Project. * * To activate indexing, call [Change Product Search Indexing Enabled](ctp:api:type:ProjectChangeProductSearchIndexingEnabledAction) and set `enabled` to `true`. *

func (*GraphQLSearchDeactivatedError) DecodeStruct ¶

func (obj *GraphQLSearchDeactivatedError) DecodeStruct(src map[string]interface{}) error

func (GraphQLSearchDeactivatedError) MarshalJSON ¶

func (obj GraphQLSearchDeactivatedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLSearchDeactivatedError) UnmarshalJSON ¶

func (obj *GraphQLSearchDeactivatedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLSearchExecutionFailureError ¶

type GraphQLSearchExecutionFailureError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a search query could not be completed due to an unexpected failure. *

func (*GraphQLSearchExecutionFailureError) DecodeStruct ¶

func (obj *GraphQLSearchExecutionFailureError) DecodeStruct(src map[string]interface{}) error

func (GraphQLSearchExecutionFailureError) MarshalJSON ¶

func (obj GraphQLSearchExecutionFailureError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLSearchExecutionFailureError) UnmarshalJSON ¶

func (obj *GraphQLSearchExecutionFailureError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLSearchFacetPathNotFoundError ¶

type GraphQLSearchFacetPathNotFoundError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a search facet path could not be found. *

func (*GraphQLSearchFacetPathNotFoundError) DecodeStruct ¶

func (obj *GraphQLSearchFacetPathNotFoundError) DecodeStruct(src map[string]interface{}) error

func (GraphQLSearchFacetPathNotFoundError) MarshalJSON ¶

func (obj GraphQLSearchFacetPathNotFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLSearchFacetPathNotFoundError) UnmarshalJSON ¶

func (obj *GraphQLSearchFacetPathNotFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLSearchIndexingInProgressError ¶

type GraphQLSearchIndexingInProgressError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the indexing of Product information is still in progress for Projects that have indexing activated. *

func (*GraphQLSearchIndexingInProgressError) DecodeStruct ¶

func (obj *GraphQLSearchIndexingInProgressError) DecodeStruct(src map[string]interface{}) error

func (GraphQLSearchIndexingInProgressError) MarshalJSON ¶

func (obj GraphQLSearchIndexingInProgressError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLSearchIndexingInProgressError) UnmarshalJSON ¶

func (obj *GraphQLSearchIndexingInProgressError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLSemanticErrorError ¶

type GraphQLSemanticErrorError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a [Discount predicate](/../api/predicates/predicate-operators) or [API Extension predicate](/../api/predicates/query#using-predicates-in-conditional-api-extensions) is not semantically correct. *

func (*GraphQLSemanticErrorError) DecodeStruct ¶

func (obj *GraphQLSemanticErrorError) DecodeStruct(src map[string]interface{}) error

func (GraphQLSemanticErrorError) MarshalJSON ¶

func (obj GraphQLSemanticErrorError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLSemanticErrorError) UnmarshalJSON ¶

func (obj *GraphQLSemanticErrorError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLShippingMethodDoesNotMatchCartError ¶

type GraphQLShippingMethodDoesNotMatchCartError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the Cart contains a ShippingMethod(ctp:api:type:ShippingMethod) that is not allowed for the Cart(ctp:api:type:Cart). In this case, the ShippingMethodState(ctp:api:type:ShippingMethodState) value is `DoesNotMatchCart`. * * The error is returned as a failed response to the [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) or [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests. *

func (*GraphQLShippingMethodDoesNotMatchCartError) DecodeStruct ¶

func (obj *GraphQLShippingMethodDoesNotMatchCartError) DecodeStruct(src map[string]interface{}) error

func (GraphQLShippingMethodDoesNotMatchCartError) MarshalJSON ¶

func (obj GraphQLShippingMethodDoesNotMatchCartError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLShippingMethodDoesNotMatchCartError) UnmarshalJSON ¶

func (obj *GraphQLShippingMethodDoesNotMatchCartError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLSyntaxErrorError ¶

type GraphQLSyntaxErrorError struct {
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a [Discount predicate](/../api/predicates/predicate-operators), [API Extension predicate](/../api/predicates/query#using-predicates-in-conditional-api-extensions), or [search query](/../api/projects/products-search) does not have the correct syntax. *

func (*GraphQLSyntaxErrorError) DecodeStruct ¶

func (obj *GraphQLSyntaxErrorError) DecodeStruct(src map[string]interface{}) error

func (GraphQLSyntaxErrorError) MarshalJSON ¶

func (obj GraphQLSyntaxErrorError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GraphQLSyntaxErrorError) UnmarshalJSON ¶

func (obj *GraphQLSyntaxErrorError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GraphQLVariablesMap ¶

type GraphQLVariablesMap map[string]interface{}

type HighPrecisionMoney ¶

type HighPrecisionMoney struct {
	// Amount in the smallest indivisible unit of a currency, such as:
	//
	// * Cents for EUR and USD, pence for GBP, or centime for CHF (5 CHF is specified as `500`).
	// * The value in the major unit for currencies without minor units, like JPY (5 JPY is specified as `5`).
	CentAmount int `json:"centAmount"`
	// Currency code compliant to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).
	CurrencyCode string `json:"currencyCode"`
	// Number of digits after the decimal separator, greater than the default number of fraction digits for a currency.
	FractionDigits int `json:"fractionDigits"`
	// Amount in 1 / (10 ^ `fractionDigits`) of a currency.
	PreciseAmount int `json:"preciseAmount"`
}

* * Money object that stores an amount of a fraction of the smallest indivisible unit of the specified currency.

func (HighPrecisionMoney) MarshalJSON ¶

func (obj HighPrecisionMoney) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type HighPrecisionMoneyDraft ¶

type HighPrecisionMoneyDraft struct {
	// Amount in the smallest indivisible unit of a currency. This field is optional for high precision. If provided, it is checked for validity. Example:
	//
	// A Price of 1.015 USD can be rounded either to 1.01 USD or 1.02 USD. If it lies outside of this range, an error message stating that centAmount must be rounded correctly will be returned.
	//
	// If `centAmount` is not provided, the API calculates the value automatically using the default rounding mode half even.
	CentAmount *int `json:"centAmount,omitempty"`
	// Currency code compliant to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).
	CurrencyCode string `json:"currencyCode"`
	// Number of fraction digits for a specified high precision money. It must be greater than the default number of fraction digits for the specified currency.
	FractionDigits int `json:"fractionDigits"`
	// Amount in 1 / (10 ^ `fractionDigits`) of a currency.
	PreciseAmount int `json:"preciseAmount"`
}

* * Money draft object to store an amount of a fraction of the smallest indivisible unit of the specified currency.

func (HighPrecisionMoneyDraft) MarshalJSON ¶

func (obj HighPrecisionMoneyDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type Hit ¶

type Hit struct {
	// Unique identifier of the Order.
	ID string `json:"id"`
	// Current version of the Order.
	Version int `json:"version"`
	// The higher the value is, the more relevant the hit is for the search request.
	Relevance *float64 `json:"relevance,omitempty"`
}

type HttpDestination ¶

type HttpDestination struct {
	// URL to the target destination. If the Project is hosted in the China (AWS, Ningxia) Region, verify that the URL is not blocked due to firewall restrictions.
	Url string `json:"url"`
	// Authentication methods (such as `Basic` or `Bearer`).
	Authentication HttpDestinationAuthentication `json:"authentication,omitempty"`
}

* * We recommend an encrypted `HTTPS` connection for production setups. However, we also accept unencrypted `HTTP` connections for development purposes. HTTP redirects will not be followed and cache headers will be ignored. *

func (HttpDestination) MarshalJSON ¶

func (obj HttpDestination) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*HttpDestination) UnmarshalJSON ¶

func (obj *HttpDestination) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type HttpDestinationAuthentication ¶

type HttpDestinationAuthentication interface{}

type Image ¶

type Image struct {
	// URL of the image in its original size that must be unique within a single [ProductVariant](ctp:api:type:ProductVariant). If the Project is hosted in the China (AWS, Ningxia) Region, verify that the URL is not blocked due to firewall restrictions.
	Url string `json:"url"`
	// Dimensions of the original image.
	Dimensions ImageDimensions `json:"dimensions"`
	// Custom label for the image.
	Label *string `json:"label,omitempty"`
}

type ImageDimensions ¶

type ImageDimensions struct {
	// Width of the image.
	W int `json:"w"`
	// Height of the image.
	H int `json:"h"`
}

type IndividualExclusionProductSelectionType ¶

type IndividualExclusionProductSelectionType struct {
	// The name of the ProductSelection which is recommended to be unique.
	Name LocalizedString `json:"name"`
}

func (IndividualExclusionProductSelectionType) MarshalJSON ¶

func (obj IndividualExclusionProductSelectionType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type IndividualProductSelectionType ¶

type IndividualProductSelectionType struct {
	// The name of the ProductSelection which is recommended to be unique.
	Name LocalizedString `json:"name"`
}

func (IndividualProductSelectionType) MarshalJSON ¶

func (obj IndividualProductSelectionType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InheritedAssociate ¶

type InheritedAssociate struct {
	// Inherited roles of the Associate within a Business Unit.
	AssociateRoleAssignments []InheritedAssociateRoleAssignment `json:"associateRoleAssignments"`
	// The [Customer](ctp:api:type:Customer) that acts as an Associate in the Business Unit.
	Customer CustomerReference `json:"customer"`
}

type InheritedAssociateRoleAssignment ¶

type InheritedAssociateRoleAssignment struct {
	// Inherited role the Associate holds within a Business Unit.
	AssociateRole AssociateRoleKeyReference `json:"associateRole"`
	// Reference to the parent Business Unit where the assignment is defined explicitly.
	Source BusinessUnitKeyReference `json:"source"`
}

type InsufficientScopeError ¶

type InsufficientScopeError struct {
	// Plain text description of the cause of the error.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

func (*InsufficientScopeError) DecodeStruct ¶

func (obj *InsufficientScopeError) DecodeStruct(src map[string]interface{}) error

func (InsufficientScopeError) Error ¶

func (obj InsufficientScopeError) Error() string

func (InsufficientScopeError) MarshalJSON ¶

func (obj InsufficientScopeError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InsufficientScopeError) UnmarshalJSON ¶

func (obj *InsufficientScopeError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InternalConstraintViolatedError ¶

type InternalConstraintViolatedError struct {
	// Plain text description of the constraints that were violated.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when certain API-specific constraints were not met. For example, the specified [Discount Code](ctp:api:type:DiscountCode) was never applied and cannot be updated. *

func (*InternalConstraintViolatedError) DecodeStruct ¶

func (obj *InternalConstraintViolatedError) DecodeStruct(src map[string]interface{}) error

func (InternalConstraintViolatedError) Error ¶

func (InternalConstraintViolatedError) MarshalJSON ¶

func (obj InternalConstraintViolatedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InternalConstraintViolatedError) UnmarshalJSON ¶

func (obj *InternalConstraintViolatedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InvalidCredentialsError ¶

type InvalidCredentialsError struct {
	// `"Account with the given credentials not found."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a Customer with the given credentials (matching the given email/password pair) is not found and authentication fails. * * The error is returned as a failed response to: * * - [Authenticate a global Customer (Sign-in)](/../api/projects/customers#authenticate-sign-in-customer) and [Authenticate Customer (Sign-in) in a Store](/../api/projects/customers#authenticate-sign-in-customer-in-store) requests on Customers. * - [Authenticating Customer (Sign-in)](/../api/projects/me-profile#authenticate-sign-in-customer) and [Authenticate Customer (Sign-in) in a Store](/../api/projects/me-profile#authenticate-sign-in-customer-in-store) requests on My Customer Profile. *

func (*InvalidCredentialsError) DecodeStruct ¶

func (obj *InvalidCredentialsError) DecodeStruct(src map[string]interface{}) error

func (InvalidCredentialsError) Error ¶

func (obj InvalidCredentialsError) Error() string

func (InvalidCredentialsError) MarshalJSON ¶

func (obj InvalidCredentialsError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidCredentialsError) UnmarshalJSON ¶

func (obj *InvalidCredentialsError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InvalidCurrentPasswordError ¶

type InvalidCurrentPasswordError struct {
	// `"The given current password does not match."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the current password of the Customer does not match. * * The error is returned as a failed response to: * * - [Change Customer Password](/../api/projects/customers#change-password-of-customer) and [Change Customer Password in a Store](/../api/projects/customers#change-password-of-customer-in-store) requests on Customers. * - [Change Customer Password](/../api/projects/me-profile#change-password-of-customer) and [Change Customer Password in a Store](/../api/projects/me-profile#change-password-of-customer-in-store) requests on My Customer Profile. *

func (*InvalidCurrentPasswordError) DecodeStruct ¶

func (obj *InvalidCurrentPasswordError) DecodeStruct(src map[string]interface{}) error

func (InvalidCurrentPasswordError) Error ¶

func (obj InvalidCurrentPasswordError) Error() string

func (InvalidCurrentPasswordError) MarshalJSON ¶

func (obj InvalidCurrentPasswordError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidCurrentPasswordError) UnmarshalJSON ¶

func (obj *InvalidCurrentPasswordError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InvalidFieldError ¶

type InvalidFieldError struct {
	// `"The value $invalidValue is not valid for field $field."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Name of the field with the invalid value.
	Field string `json:"field"`
	// Value invalid for the field.
	InvalidValue interface{} `json:"invalidValue"`
	// Fixed set of allowed values for the field, if any.
	AllowedValues []interface{} `json:"allowedValues"`
}

* * Returned when a field has an invalid value. *

func (*InvalidFieldError) DecodeStruct ¶

func (obj *InvalidFieldError) DecodeStruct(src map[string]interface{}) error

func (InvalidFieldError) Error ¶

func (obj InvalidFieldError) Error() string

func (InvalidFieldError) MarshalJSON ¶

func (obj InvalidFieldError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidFieldError) UnmarshalJSON ¶

func (obj *InvalidFieldError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InvalidInputError ¶

type InvalidInputError struct {
	// Description of the constraints that are not met by the request. For example, `"Invalid $propertyName. It may be a non-empty string up to $maxLength"`.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when an invalid input has been sent. *

func (*InvalidInputError) DecodeStruct ¶

func (obj *InvalidInputError) DecodeStruct(src map[string]interface{}) error

func (InvalidInputError) Error ¶

func (obj InvalidInputError) Error() string

func (InvalidInputError) MarshalJSON ¶

func (obj InvalidInputError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidInputError) UnmarshalJSON ¶

func (obj *InvalidInputError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InvalidItemShippingDetailsError ¶

type InvalidItemShippingDetailsError struct {
	// `"Inconsistent shipping details for $subject with ID $itemId. $subject quantity is $itemQuantity and shippingTargets quantity sum is $quantitySum."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// `"LineItem"` or `"CustomLineItem"`
	Subject string `json:"subject"`
	// Unique identifier of the Line Item or Custom Line Item.
	ItemId string `json:"itemId"`
}

* * Returned when Line Item or Custom Line Item quantities set under ItemShippingDetails(ctp:api:type:ItemShippingDetails) do not match the sum of the quantities in their respective shipping details. * * The error is returned as a failed response to the [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests. *

func (*InvalidItemShippingDetailsError) DecodeStruct ¶

func (obj *InvalidItemShippingDetailsError) DecodeStruct(src map[string]interface{}) error

func (InvalidItemShippingDetailsError) Error ¶

func (InvalidItemShippingDetailsError) MarshalJSON ¶

func (obj InvalidItemShippingDetailsError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidItemShippingDetailsError) UnmarshalJSON ¶

func (obj *InvalidItemShippingDetailsError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InvalidJsonInputError ¶

type InvalidJsonInputError struct {
	// `"Request body does not contain valid JSON."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Further explanation about why the JSON is invalid.
	DetailedErrorMessage string `json:"detailedErrorMessage"`
}

* * Returned when an invalid JSON input has been sent. * Either the JSON is syntactically incorrect or does not conform to the expected shape (for example is missing a required field). * * The client application should validate the input according to the constraints described in the error message before sending the request. *

func (*InvalidJsonInputError) DecodeStruct ¶

func (obj *InvalidJsonInputError) DecodeStruct(src map[string]interface{}) error

func (InvalidJsonInputError) Error ¶

func (obj InvalidJsonInputError) Error() string

func (InvalidJsonInputError) MarshalJSON ¶

func (obj InvalidJsonInputError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidJsonInputError) UnmarshalJSON ¶

func (obj *InvalidJsonInputError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InvalidOperationError ¶

type InvalidOperationError struct {
	// Plain text description of the error.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the resources involved in the request are not in a valid state for the operation. * * The client application should validate the constraints described in the error message before sending the request. *

func (*InvalidOperationError) DecodeStruct ¶

func (obj *InvalidOperationError) DecodeStruct(src map[string]interface{}) error

func (InvalidOperationError) Error ¶

func (obj InvalidOperationError) Error() string

func (InvalidOperationError) MarshalJSON ¶

func (obj InvalidOperationError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidOperationError) UnmarshalJSON ¶

func (obj *InvalidOperationError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InvalidSubjectError ¶

type InvalidSubjectError struct {
	// Plain text description of the cause of the error.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

func (*InvalidSubjectError) DecodeStruct ¶

func (obj *InvalidSubjectError) DecodeStruct(src map[string]interface{}) error

func (InvalidSubjectError) Error ¶

func (obj InvalidSubjectError) Error() string

func (InvalidSubjectError) MarshalJSON ¶

func (obj InvalidSubjectError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidSubjectError) UnmarshalJSON ¶

func (obj *InvalidSubjectError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InvalidTokenError ¶

type InvalidTokenError struct {
	// Plain text description of the cause of the error.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

func (*InvalidTokenError) DecodeStruct ¶

func (obj *InvalidTokenError) DecodeStruct(src map[string]interface{}) error

func (InvalidTokenError) Error ¶

func (obj InvalidTokenError) Error() string

func (InvalidTokenError) MarshalJSON ¶

func (obj InvalidTokenError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidTokenError) UnmarshalJSON ¶

func (obj *InvalidTokenError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InventoryEntry ¶

type InventoryEntry struct {
	// Unique identifier of the InventoryEntry.
	ID string `json:"id"`
	// Current version of the InventoryEntry.
	Version int `json:"version"`
	// Date and time (UTC) the InventoryEntry was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the InventoryEntry was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the InventoryEntry.
	Key *string `json:"key,omitempty"`
	// [ProductVariant](ctp:api:type:ProductVariant) `sku` of the InventoryEntry.
	Sku string `json:"sku"`
	// [Channel](ctp:api:type:Channel) that supplies this InventoryEntry.
	SupplyChannel *ChannelReference `json:"supplyChannel,omitempty"`
	// Overall amount of stock (`availableQuantity` + reserved).
	QuantityOnStock int `json:"quantityOnStock"`
	// Available amount of stock (`quantityOnStock` - reserved).
	AvailableQuantity int `json:"availableQuantity"`
	// How often the InventoryEntry is restocked (in days).
	RestockableInDays *int `json:"restockableInDays,omitempty"`
	// Date and time of the next restock.
	ExpectedDelivery *time.Time `json:"expectedDelivery,omitempty"`
	// Custom Fields of the InventoryEntry.
	Custom *CustomFields `json:"custom,omitempty"`
}

type InventoryEntryAddQuantityAction ¶

type InventoryEntryAddQuantityAction struct {
	// Value to add to `quantityOnStock`.
	Quantity int `json:"quantity"`
}

* * Updates `availableQuantity` based on the new `quantityOnStock` and amount of active reservations.

func (InventoryEntryAddQuantityAction) MarshalJSON ¶

func (obj InventoryEntryAddQuantityAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntryChangeQuantityAction ¶

type InventoryEntryChangeQuantityAction struct {
	// Value to set for `quantityOnStock`.
	Quantity int `json:"quantity"`
}

* * Updates `availableQuantity` based on the new `quantityOnStock` and amount of active reservations.

func (InventoryEntryChangeQuantityAction) MarshalJSON ¶

func (obj InventoryEntryChangeQuantityAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntryCreatedMessage ¶

type InventoryEntryCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [InventoryEntry](ctp:api:type:InventoryEntry) that was created.
	InventoryEntry InventoryEntry `json:"inventoryEntry"`
}

* * Generated after a successful [Create InventoryEntry](/../api/projects/inventory#create-inventoryentry) request. *

func (InventoryEntryCreatedMessage) MarshalJSON ¶

func (obj InventoryEntryCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InventoryEntryCreatedMessage) UnmarshalJSON ¶

func (obj *InventoryEntryCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InventoryEntryCreatedMessagePayload ¶

type InventoryEntryCreatedMessagePayload struct {
	// [InventoryEntry](ctp:api:type:InventoryEntry) that was created.
	InventoryEntry InventoryEntry `json:"inventoryEntry"`
}

* * Generated after a successful [Create InventoryEntry](/../api/projects/inventory#create-inventoryentry) request. *

func (InventoryEntryCreatedMessagePayload) MarshalJSON ¶

func (obj InventoryEntryCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntryDeletedMessage ¶

type InventoryEntryDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The `sku` of the [InventoryEntry](ctp:api:type:InventoryEntry) that was deleted.
	Sku string `json:"sku"`
	// [Reference](ctp:api:type:Reference) to the [Channel](ctp:api:type:Channel) where the [InventoryEntry](ctp:api:type:InventoryEntry) was deleted.
	SupplyChannel *ChannelReference `json:"supplyChannel,omitempty"`
}

* * Generated after a successful [Delete InventoryEntry](/../api/projects/inventory#delete-inventoryentry) request. *

func (InventoryEntryDeletedMessage) MarshalJSON ¶

func (obj InventoryEntryDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InventoryEntryDeletedMessage) UnmarshalJSON ¶

func (obj *InventoryEntryDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InventoryEntryDeletedMessagePayload ¶

type InventoryEntryDeletedMessagePayload struct {
	// The `sku` of the [InventoryEntry](ctp:api:type:InventoryEntry) that was deleted.
	Sku string `json:"sku"`
	// [Reference](ctp:api:type:Reference) to the [Channel](ctp:api:type:Channel) where the [InventoryEntry](ctp:api:type:InventoryEntry) was deleted.
	SupplyChannel *ChannelReference `json:"supplyChannel,omitempty"`
}

* * Generated after a successful [Delete InventoryEntry](/../api/projects/inventory#delete-inventoryentry) request. *

func (InventoryEntryDeletedMessagePayload) MarshalJSON ¶

func (obj InventoryEntryDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntryDraft ¶

type InventoryEntryDraft struct {
	// [ProductVariant](ctp:api:type:ProductVariant) `sku` of the InventoryEntry.
	Sku string `json:"sku"`
	// User-defined unique identifier for the InventoryEntry.
	Key *string `json:"key,omitempty"`
	// [Channel](ctp:api:type:Channel) that supplies this InventoryEntry.
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
	// Overall amount of stock.
	QuantityOnStock int `json:"quantityOnStock"`
	// How often the InventoryEntry is restocked (in days).
	RestockableInDays *int `json:"restockableInDays,omitempty"`
	// Date and time of the next restock.
	ExpectedDelivery *time.Time `json:"expectedDelivery,omitempty"`
	// Custom Fields of the InventoryEntry.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

type InventoryEntryQuantitySetMessage ¶

type InventoryEntryQuantitySetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Quantity on stock for the [InventoryEntry](ctp:api:type:InventoryEntry) before the quantity was updated.
	OldQuantityOnStock int `json:"oldQuantityOnStock"`
	// Quantity on stock for the [InventoryEntry](ctp:api:type:InventoryEntry) after the quantity was updated.
	NewQuantityOnStock int `json:"newQuantityOnStock"`
	// Available quantity for the [InventoryEntry](ctp:api:type:InventoryEntry) before the quantity was updated.
	OldAvailableQuantity int `json:"oldAvailableQuantity"`
	// Available quantity for the [InventoryEntry](ctp:api:type:InventoryEntry) after the quantity was updated.
	NewAvailableQuantity int `json:"newAvailableQuantity"`
	// [Reference](ctp:api:type:Reference) to the [Channel](ctp:api:type:Channel) where the [InventoryEntry](ctp:api:type:InventoryEntry) quantity was set.
	SupplyChannel *ChannelReference `json:"supplyChannel,omitempty"`
}

* * Generated after a successful [Add Quantity](ctp:api:type:InventoryEntryAddQuantityAction), [Remove Quantity](ctp:api:type:InventoryEntryRemoveQuantityAction) or [Change Quantity](ctp:api:type:InventoryEntryChangeQuantityAction) update action. * Inventory changes as a result of [Order creation](/../api/projects/orders#create-order) do not trigger this message. *

func (InventoryEntryQuantitySetMessage) MarshalJSON ¶

func (obj InventoryEntryQuantitySetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InventoryEntryQuantitySetMessage) UnmarshalJSON ¶

func (obj *InventoryEntryQuantitySetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InventoryEntryQuantitySetMessagePayload ¶

type InventoryEntryQuantitySetMessagePayload struct {
	// Quantity on stock for the [InventoryEntry](ctp:api:type:InventoryEntry) before the quantity was updated.
	OldQuantityOnStock int `json:"oldQuantityOnStock"`
	// Quantity on stock for the [InventoryEntry](ctp:api:type:InventoryEntry) after the quantity was updated.
	NewQuantityOnStock int `json:"newQuantityOnStock"`
	// Available quantity for the [InventoryEntry](ctp:api:type:InventoryEntry) before the quantity was updated.
	OldAvailableQuantity int `json:"oldAvailableQuantity"`
	// Available quantity for the [InventoryEntry](ctp:api:type:InventoryEntry) after the quantity was updated.
	NewAvailableQuantity int `json:"newAvailableQuantity"`
	// [Reference](ctp:api:type:Reference) to the [Channel](ctp:api:type:Channel) where the [InventoryEntry](ctp:api:type:InventoryEntry) quantity was set.
	SupplyChannel *ChannelReference `json:"supplyChannel,omitempty"`
}

* * Generated after a successful [Add Quantity](ctp:api:type:InventoryEntryAddQuantityAction), [Remove Quantity](ctp:api:type:InventoryEntryRemoveQuantityAction) or [Change Quantity](ctp:api:type:InventoryEntryChangeQuantityAction) update action. * Inventory changes as a result of [Order creation](/../api/projects/orders#create-order) do not trigger this message. *

func (InventoryEntryQuantitySetMessagePayload) MarshalJSON ¶

func (obj InventoryEntryQuantitySetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntryReference ¶

type InventoryEntryReference struct {
	// Unique identifier of the referenced [InventoryEntry](ctp:api:type:InventoryEntry).
	ID string `json:"id"`
	// Contains the representation of the expanded InventoryEntry. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for InventoryEntries.
	Obj *InventoryEntry `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to an InventoryEntry(ctp:api:type:InventoryEntry). *

func (InventoryEntryReference) MarshalJSON ¶

func (obj InventoryEntryReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntryRemoveQuantityAction ¶

type InventoryEntryRemoveQuantityAction struct {
	// Value to remove from `quantityOnStock`.
	Quantity int `json:"quantity"`
}

* * Updates `availableQuantity` based on the new `quantityOnStock` and amount of active reservations.

func (InventoryEntryRemoveQuantityAction) MarshalJSON ¶

func (obj InventoryEntryRemoveQuantityAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntryResourceIdentifier ¶

type InventoryEntryResourceIdentifier struct {
	// Unique identifier of the referenced [InventoryEntry](ctp:api:type:InventoryEntry). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [InventoryEntry](ctp:api:type:InventoryEntry). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to an InventoryEntry(ctp:api:type:InventoryEntry). *

func (InventoryEntryResourceIdentifier) MarshalJSON ¶

func (obj InventoryEntryResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntrySetCustomFieldAction ¶

type InventoryEntrySetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (InventoryEntrySetCustomFieldAction) MarshalJSON ¶

func (obj InventoryEntrySetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntrySetCustomTypeAction ¶

type InventoryEntrySetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the InventoryEntry with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the InventoryEntry.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the InventoryEntry.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (InventoryEntrySetCustomTypeAction) MarshalJSON ¶

func (obj InventoryEntrySetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntrySetExpectedDeliveryAction ¶

type InventoryEntrySetExpectedDeliveryAction struct {
	// Value to set. If empty, any existing value will be removed.
	ExpectedDelivery *time.Time `json:"expectedDelivery,omitempty"`
}

func (InventoryEntrySetExpectedDeliveryAction) MarshalJSON ¶

func (obj InventoryEntrySetExpectedDeliveryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntrySetKeyAction ¶

type InventoryEntrySetKeyAction struct {
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

func (InventoryEntrySetKeyAction) MarshalJSON ¶

func (obj InventoryEntrySetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntrySetRestockableInDaysAction ¶

type InventoryEntrySetRestockableInDaysAction struct {
	// Value to set. If empty, any existing value will be removed.
	RestockableInDays *int `json:"restockableInDays,omitempty"`
}

func (InventoryEntrySetRestockableInDaysAction) MarshalJSON ¶

func (obj InventoryEntrySetRestockableInDaysAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntrySetSupplyChannelAction ¶

type InventoryEntrySetSupplyChannelAction struct {
	// Value to set. If empty, any existing value will be removed.
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
}

* * If an entry with the same `sku` and `supplyChannel` already exists, an [DuplicateField](ctp:api:type:DuplicateFieldError) error is returned.

func (InventoryEntrySetSupplyChannelAction) MarshalJSON ¶

func (obj InventoryEntrySetSupplyChannelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type InventoryEntryUpdate ¶

type InventoryEntryUpdate struct {
	// Expected version of the InventoryEntry on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the InventoryEntry.
	Actions []InventoryEntryUpdateAction `json:"actions"`
}

func (*InventoryEntryUpdate) UnmarshalJSON ¶

func (obj *InventoryEntryUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InventoryEntryUpdateAction ¶

type InventoryEntryUpdateAction interface{}

type InventoryMode ¶

type InventoryMode string

* * Indicates how Line Items in a Cart are tracked. *

const (
	InventoryModeNone           InventoryMode = "None"
	InventoryModeTrackOnly      InventoryMode = "TrackOnly"
	InventoryModeReserveOnOrder InventoryMode = "ReserveOnOrder"
)

type InventoryPagedQueryResponse ¶

type InventoryPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [Inventory entries](ctp:api:type:InventoryEntry) matching the query.
	Results []InventoryEntry `json:"results"`
}

type IronMqDestination ¶

type IronMqDestination struct {
	Uri string `json:"uri"`
}

func (IronMqDestination) MarshalJSON ¶

func (obj IronMqDestination) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ItemShippingDetails ¶

type ItemShippingDetails struct {
	// Holds information on the quantity of Line Items or Custom Line Items and the address it is shipped.
	Targets []ItemShippingTarget `json:"targets"`
	// - `true` if the quantity of Line Items or Custom Line Items is equal to the sum of sub-quantities defined in `targets`.
	// - `false` if the quantity of Line Items or Custom Line Items is not equal to the sum of sub-quantities defined in `targets`.
	//   Ordering a Cart when the value is `false` returns an [InvalidItemShippingDetails](ctp:api:type:InvalidItemShippingDetailsError) error.
	Valid bool `json:"valid"`
}

type ItemShippingDetailsDraft ¶

type ItemShippingDetailsDraft struct {
	// Holds information on the quantity of Line Items or Custom Line Items and the address it is shipped.
	//
	// If multiple shipping addresses are present for a Line Item or Custom Line Item, sub-quantities must be specified.
	Targets []ItemShippingTarget `json:"targets"`
}

* * For order creation and updates, the sum of the `targets` must match the quantity of the Line Items or Custom Line Items. *

type ItemShippingTarget ¶

type ItemShippingTarget struct {
	// Key of the address in the [Cart](ctp:api:type:Cart) `itemShippingAddresses`.
	// Duplicate address keys are not allowed.
	AddressKey string `json:"addressKey"`
	// Quantity of Line Items or Custom Line Items shipped to the address with the specified `addressKey`.
	//
	// If a quantity is updated to `0` when defining [ItemShippingDetailsDraft](ctp:api:type:ItemShippingDetailsDraft), the `targets` are removed from a Line Item or Custom Line Item in the resulting [ItemShippingDetails](ctp:api:type:ItemShippingDetails).
	Quantity int `json:"quantity"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	//
	// It connects Line Item quantities with individual shipping addresses.
	ShippingMethodKey *string `json:"shippingMethodKey,omitempty"`
}

* * Determines the address (as a reference to an address in `itemShippingAddresses`) and the quantity shipped to the address. * * If multiple shipping addresses are present for a Line Item or Custom Line Item, sub-quantities must be specified. * An array of addresses and sub-quantities is stored per Line Item or Custom Line Item. *

type ItemState ¶

type ItemState struct {
	Quantity int            `json:"quantity"`
	State    StateReference `json:"state"`
}

type KeyReference ¶

type KeyReference interface{}

* * A KeyReference represents a loose reference to another resource in the same Project identified by the resource's `key` field. If available, the `key` is immutable and mandatory. KeyReferences do not support [Reference Expansion](/general-concepts#reference-expansion). *

type LanguageUsedInStoresError ¶

type LanguageUsedInStoresError struct {
	// `"Language(s) in use by a store cannot be deleted. Remove them in all the stores of this project first."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a language cannot be removed from a Project as it is being used by a Store. * * The error is returned as a failed response to the [Change Languages](ctp:api:type:ProjectChangeLanguagesAction) update action. *

func (*LanguageUsedInStoresError) DecodeStruct ¶

func (obj *LanguageUsedInStoresError) DecodeStruct(src map[string]interface{}) error

func (LanguageUsedInStoresError) Error ¶

func (obj LanguageUsedInStoresError) Error() string

func (LanguageUsedInStoresError) MarshalJSON ¶

func (obj LanguageUsedInStoresError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*LanguageUsedInStoresError) UnmarshalJSON ¶

func (obj *LanguageUsedInStoresError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type LastModifiedBy ¶

type LastModifiedBy struct {
	// `id` of the [APIClient](ctp:api:type:ApiClient) which modified the resource.
	ClientId *string `json:"clientId,omitempty"`
	// [External user ID](/../api/client-logging#external-user-ids) provided by `X-External-User-ID` HTTP Header.
	ExternalUserId *string `json:"externalUserId,omitempty"`
	// Indicates the [Customer](ctp:api:type:Customer) who modified the resource using a token from the [password flow](/authorization#password-flow).
	Customer *CustomerReference `json:"customer,omitempty"`
	// Indicates the [anonymous session](ctp:api:type:AnonymousSession) during which the resource was modified.
	AnonymousId *string `json:"anonymousId,omitempty"`
}

* * Present on resources modified after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).

type LineItem ¶

type LineItem struct {
	// Unique identifier of the LineItem.
	ID string `json:"id"`
	// User-defined unique identifier of the LineItem.
	Key *string `json:"key,omitempty"`
	// `id` of the [Product](ctp:api:type:Product) the Line Item is based on.
	ProductId string `json:"productId"`
	// `key` of the [Product](ctp:api:type:Product).
	//
	// This field is only present on:
	//
	// - Line Items in a [Cart](ctp:api:type:Cart) when the `key` is available on that specific Product at the time the Line Item was created or updated on the Cart.
	// - [Orders](ctp:api:type:Order) when the `key` is available on the specific Product at the time the Order was created from the Cart.
	//
	// Present on resources created or updated after 3 December 2021.
	ProductKey *string `json:"productKey,omitempty"`
	// Name of the Product.
	Name LocalizedString `json:"name"`
	// `slug` of the current version of the Product. Updated automatically if the `slug` changes. Empty if the Product has been deleted.
	// The `productSlug` field of LineItem is not expanded when using [Reference Expansion](/../api/general-concepts#reference-expansion).
	ProductSlug *LocalizedString `json:"productSlug,omitempty"`
	// Product Type of the Product.
	ProductType ProductTypeReference `json:"productType"`
	// Holds the data of the Product Variant added to the Cart.
	//
	// The data is saved at the time the Product Variant is added to the Cart and is not updated automatically when Product Variant data changes.
	// Must be updated using the [Recalculate](ctp:api:type:CartRecalculateAction) update action.
	Variant ProductVariant `json:"variant"`
	// Price of a Line Item selected from the Product Variant according to the [Product](ctp:api:type:Product) `priceMode`. If the `priceMode` is `Embedded` [ProductPriceMode](ctp:api:type:ProductPriceModeEnum) and the `variant` field hasn't been updated, the price may not correspond to a price in `variant.prices`.
	Price Price `json:"price"`
	// Number of Line Items of the given Product Variant present in the Cart.
	Quantity int `json:"quantity"`
	// Total price of this Line Item equalling `price` multiplied by `quantity`. If the Line Item is discounted, the total price is the `discountedPricePerQuantity` multiplied by `quantity`.
	// Includes taxes if the [TaxRate](ctp:api:type:TaxRate) `includedInPrice` is `true`.
	TotalPrice CentPrecisionMoney `json:"totalPrice"`
	// Discounted price of a single quantity of the Line Item.
	DiscountedPricePerQuantity []DiscountedLineItemPriceForQuantity `json:"discountedPricePerQuantity"`
	// Automatically set after `taxRate` is set.
	TaxedPrice *TaxedItemPrice `json:"taxedPrice,omitempty"`
	// Taxed price of the Shipping Method that is automatically set after `perMethodTaxRate` is set.
	TaxedPricePortions []MethodTaxedPrice `json:"taxedPricePortions"`
	// State of the Line Item in the Cart.
	State []ItemState `json:"state"`
	// - For a Cart with `Platform` [TaxMode](ctp:api:type:TaxMode), the `taxRate` of Line Items is set automatically once a shipping address is set. The rate is based on the [TaxCategory](ctp:api:type:TaxCategory) that applies for the shipping address.
	// - For a Cart with `External` TaxMode, the `taxRate` of Line Items can be set using [ExternalTaxRateDraft](ctp:api:type:ExternalTaxRateDraft).
	TaxRate *TaxRate `json:"taxRate,omitempty"`
	// Tax Rate per Shipping Method for a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode). For a Cart with `Platform` [TaxMode](ctp:api:type:TaxMode) it is automatically set after the [Shipping Method is added](ctp:api:type:CartAddShippingMethodAction).
	// For a Cart with `External` [TaxMode](ctp:api:type:TaxMode), the Tax Rate must be set with [ExternalTaxRateDraft](ctp:api:type:ExternalTaxRateDraft).
	PerMethodTaxRate []MethodTaxRate `json:"perMethodTaxRate"`
	// Identifies [Inventory entries](/../api/projects/inventory) that are reserved. The referenced Channel has the `InventorySupply` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	SupplyChannel *ChannelReference `json:"supplyChannel,omitempty"`
	// Used to [select](ctp:api:type:LineItemPriceSelection) a Product Price. The referenced Channel has the `ProductDistribution` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	DistributionChannel *ChannelReference `json:"distributionChannel,omitempty"`
	// Indicates how the Price for the Line Item is set.
	PriceMode LineItemPriceMode `json:"priceMode"`
	// Indicates how the Line Item is added to the Cart.
	LineItemMode LineItemMode `json:"lineItemMode"`
	// Inventory mode specific to this Line Item only, and valid for the entire `quantity` of the Line Item.
	// Only present if the inventory mode is different from the `inventoryMode` specified on the [Cart](ctp:api:type:Cart).
	InventoryMode *InventoryMode `json:"inventoryMode,omitempty"`
	// Container for Line Item-specific addresses.
	ShippingDetails *ItemShippingDetails `json:"shippingDetails,omitempty"`
	// Custom Fields of the Line Item.
	Custom *CustomFields `json:"custom,omitempty"`
	// Date and time (UTC) the Line Item was added to the Cart.
	AddedAt *time.Time `json:"addedAt,omitempty"`
	// Date and time (UTC) the Line Item was last updated.
	LastModifiedAt *time.Time `json:"lastModifiedAt,omitempty"`
}

* * The representation of a [Line Item](/../api/carts-orders-overview#line-items) in a Cart. *

type LineItemDraft ¶

type LineItemDraft struct {
	// User-defined unique identifier of the LineItem.
	Key *string `json:"key,omitempty"`
	// `id` of a published [Product](ctp:api:type:Product).
	ProductId *string `json:"productId,omitempty"`
	// `id` of the [ProductVariant](ctp:api:type:ProductVariant) in the Product.
	// If not provided, the Master Variant is used.
	VariantId *int `json:"variantId,omitempty"`
	// `sku` of the [ProductVariant](ctp:api:type:ProductVariant).
	Sku *string `json:"sku,omitempty"`
	// Quantity of the Product Variant to add to the Cart.
	Quantity *int `json:"quantity,omitempty"`
	// Date and time (UTC) the Product Variant is added to the Cart.
	// If not set, it defaults to the current date and time.
	//
	// Optional for backwards compatibility reasons.
	AddedAt *time.Time `json:"addedAt,omitempty"`
	// Used to [select](ctp:api:type:LineItemPriceSelection) a Product Price.
	// The referenced Channel must have the `ProductDistribution` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	//
	// If the Cart is bound to a [Store](ctp:api:type:Store) with `distributionChannels` set,
	// the Channel must match one of the Store's distribution channels.
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
	// Used to identify [Inventory entries](/../api/projects/inventory) that must be reserved.
	// The referenced Channel must have the `InventorySupply` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
	// Sets the [LineItem](ctp:api:type:LineItem) `price` value, and the `priceMode` to `ExternalPrice` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
	ExternalPrice *Money `json:"externalPrice,omitempty"`
	// Sets the [LineItem](ctp:api:type:LineItem) `price` and `totalPrice` values, and the `priceMode` to `ExternalTotal` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
	ExternalTotalPrice *ExternalLineItemTotalPrice `json:"externalTotalPrice,omitempty"`
	// External Tax Rate for the Line Item if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	// Inventory mode specific to the Line Item only, and valid for the entire `quantity` of the Line Item.
	// Set only if the inventory mode should be different from the `inventoryMode` specified on the [Cart](ctp:api:type:Cart).
	InventoryMode *InventoryMode `json:"inventoryMode,omitempty"`
	// Container for Line Item-specific addresses.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
	// Custom Fields for the Line Item.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * For Product Variant identification, either the `productId` and `variantId`, or `sku` must be provided. *

type LineItemImportDraft ¶

type LineItemImportDraft struct {
	// ID of the existing product.
	// You also need to specify the ID of the variant if this property is set or alternatively you can just specify SKU of the product variant.
	ProductId *string `json:"productId,omitempty"`
	// The product name.
	Name     LocalizedString           `json:"name"`
	Variant  ProductVariantImportDraft `json:"variant"`
	Price    PriceDraft                `json:"price"`
	Quantity int                       `json:"quantity"`
	State    []ItemState               `json:"state"`
	// Connection to a particular supplier.
	// By providing supply channel information, you can uniquely identify
	// inventory entries that should be reserved.
	// The provided channel should have the
	// InventorySupply role.
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
	// The channel is used to select a ProductPrice.
	// The provided channel should have the ProductDistribution role.
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
	TaxRate             *TaxRate                   `json:"taxRate,omitempty"`
	// The custom fields.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Inventory mode specific to the line item only, valid for the entire `quantity` of the line item.
	// Set only if inventory mode should be different from the `inventoryMode` specified on the [OrderImportDraft](ctp:api:type:OrderImportDraft).
	InventoryMode   *InventoryMode            `json:"inventoryMode,omitempty"`
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
}

func (LineItemImportDraft) MarshalJSON ¶

func (obj LineItemImportDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type LineItemMode ¶

type LineItemMode string

* * Indicates how a Line Item is added to a Cart. *

const (
	LineItemModeStandard     LineItemMode = "Standard"
	LineItemModeGiftLineItem LineItemMode = "GiftLineItem"
)

type LineItemPriceMode ¶

type LineItemPriceMode string

* * This mode indicates how the price is set for the Line Item. *

const (
	LineItemPriceModePlatform      LineItemPriceMode = "Platform"
	LineItemPriceModeExternalPrice LineItemPriceMode = "ExternalPrice"
	LineItemPriceModeExternalTotal LineItemPriceMode = "ExternalTotal"
)

type LineItemReturnItem ¶

type LineItemReturnItem struct {
	// Unique identifier of the ReturnItem.
	ID            string              `json:"id"`
	Quantity      int                 `json:"quantity"`
	Comment       *string             `json:"comment,omitempty"`
	ShipmentState ReturnShipmentState `json:"shipmentState"`
	PaymentState  ReturnPaymentState  `json:"paymentState"`
	// Custom Fields of this return item.
	Custom         *CustomFields `json:"custom,omitempty"`
	LastModifiedAt time.Time     `json:"lastModifiedAt"`
	CreatedAt      time.Time     `json:"createdAt"`
	LineItemId     string        `json:"lineItemId"`
}

func (LineItemReturnItem) MarshalJSON ¶

func (obj LineItemReturnItem) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type LineItemStateTransitionMessage ¶

type LineItemStateTransitionMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Line Item](ctp:api:type:LineItem).
	LineItemId string `json:"lineItemId"`
	// Date and time (UTC) when the transition of the [Line Item](ctp:api:type:LineItem) [State](ctp:api:type:State) was performed.
	TransitionDate time.Time `json:"transitionDate"`
	// Number of [Line Items](ctp:api:type:LineItem) for which the [State](ctp:api:type:State) was transitioned.
	Quantity int `json:"quantity"`
	// [State](ctp:api:type:State) the [Line Item](ctp:api:type:LineItem) was transitioned from.
	FromState StateReference `json:"fromState"`
	// [State](ctp:api:type:State) the [Line Item](ctp:api:type:LineItem) was transitioned to.
	ToState StateReference `json:"toState"`
}

* * Generated after a successful [Transition Line Item State](ctp:api:type:OrderTransitionLineItemStateAction) update action. *

func (LineItemStateTransitionMessage) MarshalJSON ¶

func (obj LineItemStateTransitionMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*LineItemStateTransitionMessage) UnmarshalJSON ¶

func (obj *LineItemStateTransitionMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type LineItemStateTransitionMessagePayload ¶

type LineItemStateTransitionMessagePayload struct {
	// Unique identifier of the [Line Item](ctp:api:type:LineItem).
	LineItemId string `json:"lineItemId"`
	// Date and time (UTC) when the transition of the [Line Item](ctp:api:type:LineItem) [State](ctp:api:type:State) was performed.
	TransitionDate time.Time `json:"transitionDate"`
	// Number of [Line Items](ctp:api:type:LineItem) for which the [State](ctp:api:type:State) was transitioned.
	Quantity int `json:"quantity"`
	// [State](ctp:api:type:State) the [Line Item](ctp:api:type:LineItem) was transitioned from.
	FromState StateReference `json:"fromState"`
	// [State](ctp:api:type:State) the [Line Item](ctp:api:type:LineItem) was transitioned to.
	ToState StateReference `json:"toState"`
}

* * Generated after a successful [Transition Line Item State](ctp:api:type:OrderTransitionLineItemStateAction) update action. *

func (LineItemStateTransitionMessagePayload) MarshalJSON ¶

func (obj LineItemStateTransitionMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type LocalizedString ¶

type LocalizedString map[string]string

* * JSON object where the keys are of type [Locale](ctp:api:type:Locale), and the values are the strings used for the corresponding language. *

type Location ¶

type Location struct {
	// Country code of the geographic location.
	Country string `json:"country"`
	// State within the country.
	State *string `json:"state,omitempty"`
}

* * A geographical location representing a country and optionally a state within this country. A location can only be assigned to one Zone.

type MatchingPriceNotFoundError ¶

type MatchingPriceNotFoundError struct {
	// `"The variant $variantId of product $productId does not contain a price for currency $currencyCode, $country, $customerGroup, $channel."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifier of a [Product](ctp:api:type:Product).
	ProductId string `json:"productId"`
	// Unique identifier of a [ProductVariant](ctp:api:type:ProductVariant) in the Product.
	VariantId int `json:"variantId"`
	// Currency code of the country.
	Currency *string `json:"currency,omitempty"`
	// Country code of the geographic location.
	Country *string `json:"country,omitempty"`
	// Customer Group associated with the Price.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// Channel associated with the Price.
	Channel *ChannelReference `json:"channel,omitempty"`
}

* * Returned when the Product Variant does not have a Price according to the Product(ctp:api:type:Product) `priceMode` value for a selected currency, country, Customer Group, or Channel. * * The error is returned as a failed response to: * * - [Add LineItem](ctp:api:type:CartAddLineItemAction), [Add CustomLineItem](ctp:api:type:CartAddCustomLineItemAction), and [Add DiscountCode](ctp:api:type:CartAddDiscountCodeAction) update actions on Carts. * - [Add LineItem](ctp:api:type:StagedOrderAddLineItemAction), [Add CustomLineItem](ctp:api:type:StagedOrderAddCustomLineItemAction), and [Add DiscountCode](ctp:api:type:StagedOrderAddDiscountCodeAction) update actions on Order Edits. * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests on Orders. * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/me/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/me/orders:POST) requests on My Orders. *

func (*MatchingPriceNotFoundError) DecodeStruct ¶

func (obj *MatchingPriceNotFoundError) DecodeStruct(src map[string]interface{}) error

func (MatchingPriceNotFoundError) Error ¶

func (obj MatchingPriceNotFoundError) Error() string

func (MatchingPriceNotFoundError) MarshalJSON ¶

func (obj MatchingPriceNotFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*MatchingPriceNotFoundError) UnmarshalJSON ¶

func (obj *MatchingPriceNotFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MaxResourceLimitExceededError ¶

type MaxResourceLimitExceededError struct {
	// `"You have exceeded the limit of $limit resources of type $resourceTypeId."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Resource type that reached its maximum limit of configured elements (for example, 100 Zones per Project).
	ExceededResource ReferenceTypeId `json:"exceededResource"`
}

* * Returned when a resource type cannot be created as it has reached its [limits](/../api/limits). * * The limits must be adjusted for this resource before sending the request again. *

func (*MaxResourceLimitExceededError) DecodeStruct ¶

func (obj *MaxResourceLimitExceededError) DecodeStruct(src map[string]interface{}) error

func (MaxResourceLimitExceededError) Error ¶

func (MaxResourceLimitExceededError) MarshalJSON ¶

func (obj MaxResourceLimitExceededError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*MaxResourceLimitExceededError) UnmarshalJSON ¶

func (obj *MaxResourceLimitExceededError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type Message ¶

type Message interface{}

* * Base representation of a Message containing common fields to all [Message Types](/../api/projects/messages#message-types). *

type MessageDeliveryPayload ¶

type MessageDeliveryPayload struct {
	// `key` of the [Project](ctp:api:type:Project).
	// Useful in message processing if the Destination receives events from multiple Projects.
	ProjectKey string `json:"projectKey"`
	// Reference to the resource that triggered the message.
	Resource Reference `json:"resource"`
	// User-defined unique identifiers of the resource.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique ID of the message.
	ID string `json:"id"`
	// Last seen version of the resource.
	Version int `json:"version"`
	// Date and time (UTC) the resource was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the resource was last modified.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Used to ensure all messages of the resource are processed in correct order.
	// The `sequenceNumber` of the next message of the resource is a successor of the `sequenceNumber` of the current message.
	SequenceNumber int `json:"sequenceNumber"`
	// Version of the resource on which the change was performed.
	ResourceVersion int `json:"resourceVersion"`
	// If the payload does not fit into the size limit or its format is not accepted by the messaging service, the `payloadNotIncluded` field is present.
	PayloadNotIncluded *PayloadNotIncluded `json:"payloadNotIncluded,omitempty"`
}

* * This payload is sent for a MessageSubscription(ctp:api:type:MessageSubscription). *

func (MessageDeliveryPayload) MarshalJSON ¶

func (obj MessageDeliveryPayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*MessageDeliveryPayload) UnmarshalJSON ¶

func (obj *MessageDeliveryPayload) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MessagePagedQueryResponse ¶

type MessagePagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// [Messages](ctp:api:type:Message) matching the query.
	Results []Message `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of Message(ctp:api:type:Message). *

func (*MessagePagedQueryResponse) UnmarshalJSON ¶

func (obj *MessagePagedQueryResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MessagePayload ¶

type MessagePayload interface{}

type MessageSubscription ¶

type MessageSubscription struct {
	// Unique identifier for the type of resource, for example, `order`.
	ResourceTypeId MessageSubscriptionResourceTypeId `json:"resourceTypeId"`
	// Must contain valid message types for the resource. For example, for resource type `product` the message type `ProductPublished` is valid.
	// If no `types` of messages are given, the Subscription will receive all messages for this resource.
	Types []string `json:"types"`
}

* * For supported resources and message types, see [Message Types](/../api/projects/messages#message-types). Messages will be delivered even if the Messages Query HTTP API [is not enabled](/../api/projects/messages#enable-querying-messages-via-the-api). * * For MessageSubscriptions, the format of the payload is MessageDeliveryPayload(ctp:api:type:MessageDeliveryPayload). *

func (MessageSubscription) MarshalJSON ¶

func (obj MessageSubscription) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MessageSubscriptionResourceTypeId ¶

type MessageSubscriptionResourceTypeId string

* * Resource types supported by [MessageSubscriptions](ctp:api:type:MessageSubscription): *

const (
	MessageSubscriptionResourceTypeIdAssociateRole    MessageSubscriptionResourceTypeId = "associate-role"
	MessageSubscriptionResourceTypeIdBusinessUnit     MessageSubscriptionResourceTypeId = "business-unit"
	MessageSubscriptionResourceTypeIdCategory         MessageSubscriptionResourceTypeId = "category"
	MessageSubscriptionResourceTypeIdCustomer         MessageSubscriptionResourceTypeId = "customer"
	MessageSubscriptionResourceTypeIdInventoryEntry   MessageSubscriptionResourceTypeId = "inventory-entry"
	MessageSubscriptionResourceTypeIdOrder            MessageSubscriptionResourceTypeId = "order"
	MessageSubscriptionResourceTypeIdPayment          MessageSubscriptionResourceTypeId = "payment"
	MessageSubscriptionResourceTypeIdProduct          MessageSubscriptionResourceTypeId = "product"
	MessageSubscriptionResourceTypeIdProductSelection MessageSubscriptionResourceTypeId = "product-selection"
	MessageSubscriptionResourceTypeIdQuote            MessageSubscriptionResourceTypeId = "quote"
	MessageSubscriptionResourceTypeIdQuoteRequest     MessageSubscriptionResourceTypeId = "quote-request"
	MessageSubscriptionResourceTypeIdReview           MessageSubscriptionResourceTypeId = "review"
	MessageSubscriptionResourceTypeIdStagedQuote      MessageSubscriptionResourceTypeId = "staged-quote"
	MessageSubscriptionResourceTypeIdStandalonePrice  MessageSubscriptionResourceTypeId = "standalone-price"
	MessageSubscriptionResourceTypeIdStore            MessageSubscriptionResourceTypeId = "store"
)

type MessagesConfiguration ¶

type MessagesConfiguration struct {
	// When `true`, the [Messages Query](/../api/projects/messages) feature is active.
	Enabled bool `json:"enabled"`
	// Specifies the number of days each Message should be available via the [Messages Query](/../api/projects/messages) API.
	// For Messages older than the specified period, it is not guaranteed that they are still accessible via the API.
	// This field may not be present on Projects created before 8 October 2018.
	DeleteDaysAfterCreation *int `json:"deleteDaysAfterCreation,omitempty"`
}

* * Holds the configuration for the [Messages Query](/../api/projects/messages) feature for the Project.

type MessagesConfigurationDraft ¶

type MessagesConfigurationDraft struct {
	// Setting to `true` activates the [Messages Query](/../api/projects/messages) feature.
	Enabled bool `json:"enabled"`
	// Specifies the number of days each Message should be available via the [Messages Query](/../api/projects/messages) API. For Messages older than the specified period, it is not guaranteed that they are still accessible via the API.
	DeleteDaysAfterCreation int `json:"deleteDaysAfterCreation"`
}

* * Defines the configuration for the [Messages Query](/../api/projects/messages) feature for the Project.

type MethodTaxRate ¶

type MethodTaxRate struct {
	// User-defined unique identifier of the Shipping Method in a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingMethodKey string `json:"shippingMethodKey"`
	// Tax Rate for the Shipping Method.
	TaxRate *TaxRate `json:"taxRate,omitempty"`
}

type MethodTaxedPrice ¶

type MethodTaxedPrice struct {
	// User-defined unique identifier of the Shipping Method in a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingMethodKey string `json:"shippingMethodKey"`
	// Taxed price for the Shipping Method.
	TaxedPrice *TaxedItemPrice `json:"taxedPrice,omitempty"`
}

type MissingRoleOnChannelError ¶

type MissingRoleOnChannelError struct {
	// `"Given channel with $idOrKeyOfChannel does not have the required role $role."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a given [Channel](ctp:api:type:Channel).
	Channel *ChannelResourceIdentifier `json:"channel,omitempty"`
	// - `ProductDistribution` for Product Distribution Channels allowed for the Store. Also required for [Standalone Prices](ctp:api:type:StandalonePrice).
	// - `InventorySupply` for Inventory Supply Channels allowed for the Store.
	MissingRole ChannelRoleEnum `json:"missingRole"`
}

* * Returned when one of the following states occur: * * - Channel(ctp:api:type:Channel) is added or set on a Store(ctp:api:type:Store) with missing Channel `roles`. * - [Standalone Price](/../api/projects/standalone-prices#create-standaloneprice) references a Channel that does not contain the `ProductDistribution` role. * * The error is returned as a failed response to: * * - [Add Distribution Channel](ctp:api:type:StoreAddDistributionChannelAction), [Set Distribution Channel](ctp:api:type:StoreSetDistributionChannelsAction), [Add Supply Channel](ctp:api:type:StoreAddSupplyChannelAction), and [Set Supply Channel](ctp:api:type:StoreSetSupplyChannelsAction) update actions. * - [Create a Standalone Price](/../api/projects/standalone-prices#create-standaloneprice) request. *

func (*MissingRoleOnChannelError) DecodeStruct ¶

func (obj *MissingRoleOnChannelError) DecodeStruct(src map[string]interface{}) error

func (MissingRoleOnChannelError) Error ¶

func (obj MissingRoleOnChannelError) Error() string

func (MissingRoleOnChannelError) MarshalJSON ¶

func (obj MissingRoleOnChannelError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*MissingRoleOnChannelError) UnmarshalJSON ¶

func (obj *MissingRoleOnChannelError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MissingTaxRateForCountryError ¶

type MissingTaxRateForCountryError struct {
	// `"Tax category $taxCategoryId is missing a tax rate for country $countriesAndStates."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifier of the [TaxCategory](ctp:api:type:TaxCategory).
	TaxCategoryId string `json:"taxCategoryId"`
	// Country code of the geographic location.
	Country *string `json:"country,omitempty"`
	// State within the country, such as Texas in the United States.
	State *string `json:"state,omitempty"`
}

* * Returned when the Tax Category of at least one of the `lineItems`, `customLineItems`, or `shippingInfo` in the Cart(ctp:api:type:Cart) is missing the TaxRate(ctp:api:type:TaxRate) matching `country` and `state` given in the `shippingAddress` of that Cart. * * The error is returned as a failed response to: * * - [Set Default Shipping Address](ctp:api:type:CustomerSetDefaultShippingAddressAction), [Add LineItem](ctp:api:type:CartAddLineItemAction), [Add CustomLineItem](ctp:api:type:CartAddCustomLineItemAction), [Set Shipping Address](ctp:api:type:CartSetShippingAddressAction), [Add LineItem](ctp:api:type:MyCartAddLineItemAction), [Add LineItem](ctp:api:type:StagedOrderAddLineItemAction), and [Add CustomLineItem](ctp:api:type:StagedOrderAddCustomLineItemAction) update actions * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests. *

func (*MissingTaxRateForCountryError) DecodeStruct ¶

func (obj *MissingTaxRateForCountryError) DecodeStruct(src map[string]interface{}) error

func (MissingTaxRateForCountryError) Error ¶

func (MissingTaxRateForCountryError) MarshalJSON ¶

func (obj MissingTaxRateForCountryError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*MissingTaxRateForCountryError) UnmarshalJSON ¶

func (obj *MissingTaxRateForCountryError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type Money ¶

type Money struct {
	// Amount in the smallest indivisible unit of a currency, such as:
	//
	// * Cents for EUR and USD, pence for GBP, or centime for CHF (5 CHF is specified as `500`).
	// * The value in the major unit for currencies without minor units, like JPY (5 JPY is specified as `5`).
	CentAmount int `json:"centAmount"`
	// Currency code compliant to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).
	CurrencyCode string `json:"currencyCode"`
}

* * Draft type that stores amounts only in cent precision for the specified currency. *

type MoneyOverflowError ¶

type MoneyOverflowError struct {
	// `"A Money operation resulted in an overflow."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a Money(ctp:api:type:Money) operation overflows the 64-bit integer range. * See [Money usage](/types#usage) for more information. *

func (*MoneyOverflowError) DecodeStruct ¶

func (obj *MoneyOverflowError) DecodeStruct(src map[string]interface{}) error

func (MoneyOverflowError) Error ¶

func (obj MoneyOverflowError) Error() string

func (MoneyOverflowError) MarshalJSON ¶

func (obj MoneyOverflowError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*MoneyOverflowError) UnmarshalJSON ¶

func (obj *MoneyOverflowError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MoneyType ¶

type MoneyType string

* * MoneyType supports two different values, one for amounts in cent precision and another one for sub-cent amounts up to 20 fraction digits.

const (
	MoneyTypeCentPrecision MoneyType = "centPrecision"
	MoneyTypeHighPrecision MoneyType = "highPrecision"
)

type MultiBuyCustomLineItemsTarget ¶

type MultiBuyCustomLineItemsTarget struct {
	// Valid [CustomLineItems target predicate](/../api/projects/predicates#customlineitem-field-identifiers). The Discount will be applied to Custom Line Items that are matched by the predicate.
	Predicate string `json:"predicate"`
	// Number of Custom Line Items to be present in order to trigger an application of this Discount.
	TriggerQuantity int `json:"triggerQuantity"`
	// Number of Custom Line Items that are discounted per application of this Discount.
	DiscountedQuantity int `json:"discountedQuantity"`
	// Maximum number of times this Discount can be applied.
	MaxOccurrence *int `json:"maxOccurrence,omitempty"`
	// Discounts particular Line Items only according to the SelectionMode.
	SelectionMode SelectionMode `json:"selectionMode"`
}

* * This Discount target is similar to `MultiBuyLineItems`, but is applied on Custom Line Items instead of Line Items. *

func (MultiBuyCustomLineItemsTarget) MarshalJSON ¶

func (obj MultiBuyCustomLineItemsTarget) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MultiBuyLineItemsTarget ¶

type MultiBuyLineItemsTarget struct {
	// Valid [LineItem target predicate](/../api/projects/predicates#lineitem-field-identifiers). The Discount will be applied to Line Items that are matched by the predicate.
	Predicate string `json:"predicate"`
	// Number of Line Items to be present in order to trigger an application of this Discount.
	TriggerQuantity int `json:"triggerQuantity"`
	// Number of Line Items that are discounted per application of this Discount.
	DiscountedQuantity int `json:"discountedQuantity"`
	// Maximum number of times this Discount can be applied.
	MaxOccurrence *int `json:"maxOccurrence,omitempty"`
	// Discounts particular Line Items only according to the SelectionMode.
	SelectionMode SelectionMode `json:"selectionMode"`
}

func (MultiBuyLineItemsTarget) MarshalJSON ¶

func (obj MultiBuyLineItemsTarget) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitAddAddressAction ¶

type MyBusinessUnitAddAddressAction struct {
	// The address to add to `addresses`.
	Address BaseAddress `json:"address"`
}

* * Adding an address to a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitAddressAdded](ctp:api:type:BusinessUnitAddressAddedMessage) Message. *

func (MyBusinessUnitAddAddressAction) MarshalJSON ¶

func (obj MyBusinessUnitAddAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitAddBillingAddressIdAction ¶

type MyBusinessUnitAddBillingAddressIdAction struct {
	// ID of the address to add as a billing address. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to add as a billing address. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Adding a billing address to a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitBillingAddressAdded](ctp:api:type:BusinessUnitBillingAddressAddedMessage) Message. *

func (MyBusinessUnitAddBillingAddressIdAction) MarshalJSON ¶

func (obj MyBusinessUnitAddBillingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitAddShippingAddressIdAction ¶

type MyBusinessUnitAddShippingAddressIdAction struct {
	// ID of the address to add as a shipping address. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to add as a shipping address. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Adding a shipping address to a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitShippingAddressAdded](ctp:api:type:BusinessUnitShippingAddressAddedMessage) Message. *

func (MyBusinessUnitAddShippingAddressIdAction) MarshalJSON ¶

func (obj MyBusinessUnitAddShippingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitAssociateDraft ¶

type MyBusinessUnitAssociateDraft struct {
	// Expected version of the BusinessUnit on which the changes should be applied. If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// [Customer](ctp:api:type:Customer) to create and assign to the Business Unit.
	Customer MyCustomerDraft `json:"customer"`
	// Roles assigned to the new Associate within a Business Unit.
	AssociateRoleAssignments []AssociateRoleAssignmentDraft `json:"associateRoleAssignments"`
}

type MyBusinessUnitChangeAddressAction ¶

type MyBusinessUnitChangeAddressAction struct {
	// ID of the address to change. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to change. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
	// New address to set.
	Address BaseAddress `json:"address"`
}

* * Changing the address on a Business Unit generates the [BusinessUnitAddressChanged](ctp:api:type:BusinessUnitAddressChangedMessage) Message. *

func (MyBusinessUnitChangeAddressAction) MarshalJSON ¶

func (obj MyBusinessUnitChangeAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitChangeAssociateAction ¶

type MyBusinessUnitChangeAssociateAction struct {
	// The Associate to add.
	Associate AssociateDraft `json:"associate"`
}

* * Updating the Associate(ctp:api:type:Associate) on a [Business Unit](ctp:api:type:BusinessUnit) generates the [BusinessUnitAssociateChanged](ctp:api:type:BusinessUnitAssociateChangedMessage) Message. *

func (MyBusinessUnitChangeAssociateAction) MarshalJSON ¶

func (obj MyBusinessUnitChangeAssociateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitChangeNameAction ¶

type MyBusinessUnitChangeNameAction struct {
	// New name to set.
	Name string `json:"name"`
}

* * Updating the name on a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitNameChanged](ctp:api:type:BusinessUnitNameChangedMessage) Message. *

func (MyBusinessUnitChangeNameAction) MarshalJSON ¶

func (obj MyBusinessUnitChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitChangeParentUnitAction ¶

type MyBusinessUnitChangeParentUnitAction struct {
	// New parent unit of the [Business Unit](ctp:api:type:BusinessUnit).
	ParentUnit BusinessUnitResourceIdentifier `json:"parentUnit"`
}

* * Changing the parent of a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitParentUnitChanged](ctp:api:type:BusinessUnitParentUnitChangedMessage) Message. *

func (MyBusinessUnitChangeParentUnitAction) MarshalJSON ¶

func (obj MyBusinessUnitChangeParentUnitAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitDraft ¶

type MyBusinessUnitDraft interface{}

type MyBusinessUnitRemoveAddressAction ¶

type MyBusinessUnitRemoveAddressAction struct {
	// ID of the address to be removed. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to be removed. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removing the address from a [Business Unit](ctp:api:type:BusinessUnit) generates the [BusinessUnitAddressRemoved](ctp:api:type:BusinessUnitAddressRemovedMessage) Message. *

func (MyBusinessUnitRemoveAddressAction) MarshalJSON ¶

func (obj MyBusinessUnitRemoveAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitRemoveAssociateAction ¶

type MyBusinessUnitRemoveAssociateAction struct {
	// [Associate](ctp:api:type:Associate) to remove.
	Customer CustomerResourceIdentifier `json:"customer"`
}

* * Removing an Associate(ctp:api:type:Associate) from a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitAssociateRemoved](ctp:api:type:BusinessUnitAssociateRemovedMessage) Message. *

func (MyBusinessUnitRemoveAssociateAction) MarshalJSON ¶

func (obj MyBusinessUnitRemoveAssociateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitRemoveBillingAddressIdAction ¶

type MyBusinessUnitRemoveBillingAddressIdAction struct {
	// ID of the billing address to be removed. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the billing address to be removed. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removing a billing address from a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitBillingAddressRemoved](ctp:api:type:BusinessUnitBillingAddressRemovedMessage) Message. *

func (MyBusinessUnitRemoveBillingAddressIdAction) MarshalJSON ¶

func (obj MyBusinessUnitRemoveBillingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitRemoveShippingAddressIdAction ¶

type MyBusinessUnitRemoveShippingAddressIdAction struct {
	// ID of the shipping address to be removed. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the shipping address to be removed. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removing a shipping address from a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitShippingAddressRemoved](ctp:api:type:BusinessUnitShippingAddressRemovedMessage) Message. *

func (MyBusinessUnitRemoveShippingAddressIdAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitSetAddressCustomFieldAction ¶

type MyBusinessUnitSetAddressCustomFieldAction struct {
	// ID of the `address` to be extended.
	AddressId string `json:"addressId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Trying to remove a field that does not exist will fail with an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (MyBusinessUnitSetAddressCustomFieldAction) MarshalJSON ¶

func (obj MyBusinessUnitSetAddressCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitSetAddressCustomTypeAction ¶

type MyBusinessUnitSetAddressCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the `address` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `address`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `address`.
	Fields *FieldContainer `json:"fields,omitempty"`
	// ID of the `address` to be extended.
	AddressId string `json:"addressId"`
}

func (MyBusinessUnitSetAddressCustomTypeAction) MarshalJSON ¶

func (obj MyBusinessUnitSetAddressCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitSetContactEmailAction ¶

type MyBusinessUnitSetContactEmailAction struct {
	// Email to set.
	// If `contactEmail` is absent or `null`, the existing contact email, if any, will be removed.
	ContactEmail *string `json:"contactEmail,omitempty"`
}

* * Setting the contact email on a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitContactEmailSet](ctp:api:type:BusinessUnitContactEmailSetMessage) Message. *

func (MyBusinessUnitSetContactEmailAction) MarshalJSON ¶

func (obj MyBusinessUnitSetContactEmailAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitSetCustomFieldAction ¶

type MyBusinessUnitSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Trying to remove a field that does not exist will fail with an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (MyBusinessUnitSetCustomFieldAction) MarshalJSON ¶

func (obj MyBusinessUnitSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitSetCustomTypeAction ¶

type MyBusinessUnitSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the BusinessUnit with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the BusinessUnit.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) for the BusinessUnit.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (MyBusinessUnitSetCustomTypeAction) MarshalJSON ¶

func (obj MyBusinessUnitSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitSetDefaultBillingAddressAction ¶

type MyBusinessUnitSetDefaultBillingAddressAction struct {
	// ID of the address to add as a billing address. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to add as a billing address. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Setting the default billing address on a [Business Unit](ctp:api:type:BusinessUnit) generates the [BusinessUnitDefaultBillingAddressSet](ctp:api:type:BusinessUnitDefaultBillingAddressSetMessage) Message. *

func (MyBusinessUnitSetDefaultBillingAddressAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitSetDefaultShippingAddressAction ¶

type MyBusinessUnitSetDefaultShippingAddressAction struct {
	// ID of the address to add as a shipping address. Either `addressId` or `addressKey` is required.
	AddressId *string `json:"addressId,omitempty"`
	// Key of the address to add as a shipping address. Either `addressId` or `addressKey` is required.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Setting the default shipping address on a [Business Unit](ctp:api:type:BusinessUnit) generates a [BusinessUnitDefaultShippingAddressSet](ctp:api:type:BusinessUnitDefaultShippingAddressSetMessage) Message. *

func (MyBusinessUnitSetDefaultShippingAddressAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyBusinessUnitUpdate ¶

type MyBusinessUnitUpdate struct {
	// Expected version of the BusinessUnit on which the changes should be applied.
	// If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the BusinessUnit.
	Actions []BusinessUnitUpdateAction `json:"actions"`
}

func (*MyBusinessUnitUpdate) UnmarshalJSON ¶

func (obj *MyBusinessUnitUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MyBusinessUnitUpdateAction ¶

type MyBusinessUnitUpdateAction interface{}

type MyCartAddDiscountCodeAction ¶

type MyCartAddDiscountCodeAction struct {
	// `code` of a [DiscountCode](ctp:api:type:DiscountCode).
	Code string `json:"code"`
}

* * Adds a DiscountCode(ctp:api:type:DiscountCode) to the Cart to activate the related [CartDiscounts](/../api/projects/cartDiscounts). * Adding a Discount Code is only possible if no DirectDiscount(ctp:api:type:DirectDiscount) has been applied to the Cart. * Discount Codes can be added to [frozen Carts](ctp:api:type:FrozenCarts), but their DiscountCodeState(ctp:api:type:DiscountCodeState) is then `DoesNotMatchCart`. * * The maximum number of Discount Codes in a Cart is restricted by a [limit](/../api/limits#carts). * * Specific Error Code: [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) *

func (MyCartAddDiscountCodeAction) MarshalJSON ¶

func (obj MyCartAddDiscountCodeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartAddItemShippingAddressAction ¶

type MyCartAddItemShippingAddressAction struct {
	// Address to append to `itemShippingAddresses`.
	//
	// The new address must have a key that is unique accross this Cart.
	Address BaseAddress `json:"address"`
}

* * Adds an address to a Cart when shipping to multiple addresses is desired. *

func (MyCartAddItemShippingAddressAction) MarshalJSON ¶

func (obj MyCartAddItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartAddLineItemAction ¶

type MyCartAddLineItemAction struct {
	// User-defined unique identifier of the LineItem.
	Key *string `json:"key,omitempty"`
	// `id` of the [Product](ctp:api:type:Product).
	//
	// Either the `productId` and `variantId`, or `sku` must be provided.
	ProductId *string `json:"productId,omitempty"`
	// `id` of the [ProductVariant](ctp:api:type:ProductVariant) in the Product.
	//
	// If not given, the Master Variant is used.
	//
	// Either the `productId` and `variantId`, or `sku` must be provided.
	VariantId *int `json:"variantId,omitempty"`
	// `sku` of the [ProductVariant](ctp:api:type:ProductVariant).
	//
	// Either the `productId` and `variantId`, or `sku` must be provided.
	Sku *string `json:"sku,omitempty"`
	// Number of Line Items to add to the Cart.
	Quantity *int `json:"quantity,omitempty"`
	// Date and time (UTC) the Line Item was added to the Cart.
	// If not set, it defaults to the current date and time.
	//
	// Optional for backwards compatibility reasons.
	AddedAt *time.Time `json:"addedAt,omitempty"`
	// Used to [select](ctp:api:type:LineItemPriceSelection) a Product Price.
	// The Channel must have the `ProductDistribution` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	// If the Cart is bound to a [Store](ctp:api:type:Store) with `distributionChannels` set, the Channel must match one of the Store's distribution channels.
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
	// Used to identify [Inventory entries](/../api/projects/inventory) that must be reserved.
	// The Channel must have the `InventorySupply` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
	// Container for Line Item-specific addresses.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
	// Custom Fields for the Line Item.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * If the Cart contains a LineItem(ctp:api:type:LineItem) for a Product Variant with the same LineItemMode(ctp:api:type:LineItemMode), [Custom Fields](/../api/projects/custom-fields), supply and distribution channel, then only the quantity of the existing Line Item is increased. * If LineItem(ctp:api:type:LineItem) `shippingDetails` is set, it is merged. All addresses will be present afterwards and, for address keys present in both shipping details, the quantity will be summed up. * A new Line Item is added when the `externalPrice` or `externalTotalPrice` is set in this update action. * The LineItem(ctp:api:type:LineItem) price is set as described in [LineItem Price selection](ctp:api:type:LineItemPriceSelection). * * If the Tax Rate is not set, a [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError) error is returned. * * If the Line Items do not have a Price according to the Product(ctp:api:type:Product) `priceMode` value for a selected currency and/or country, Customer Group, or Channel, a [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) error is returned. *

func (MyCartAddLineItemAction) MarshalJSON ¶

func (obj MyCartAddLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartAddPaymentAction ¶

type MyCartAddPaymentAction struct {
	// Payment to add to the Cart.
	// Must not be assigned to another Order or active Cart already.
	Payment PaymentResourceIdentifier `json:"payment"`
}

func (MyCartAddPaymentAction) MarshalJSON ¶

func (obj MyCartAddPaymentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartApplyDeltaToLineItemShippingDetailsTargetsAction ¶

type MyCartApplyDeltaToLineItemShippingDetailsTargetsAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Using positive or negative quantities increases or decreases the number of items shipped to an address.
	TargetsDelta []ItemShippingTarget `json:"targetsDelta"`
}

* * To override the shipping details, see [Set LineItemShippingDetails](ctp:api:type:MyCartSetLineItemShippingDetailsAction). *

func (MyCartApplyDeltaToLineItemShippingDetailsTargetsAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartChangeLineItemQuantityAction ¶

type MyCartChangeLineItemQuantityAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// New value to set.
	//
	// If `0`, the Line Item is removed from the Cart.
	Quantity int `json:"quantity"`
	// Deprecated. Will be ignored.
	ExternalPrice *Money `json:"externalPrice,omitempty"`
	// Deprecated. Will be ignored.
	ExternalTotalPrice *ExternalLineItemTotalPrice `json:"externalTotalPrice,omitempty"`
}

* * When multiple shipping addresses are set for a Line Item, * use the [Remove LineItem](ctp:api:type:CartRemoveLineItemAction) and [Add LineItem](ctp:api:type:CartAddLineItemAction) update action * to change the shipping details. * Since it is not possible for the API to infer how the overall change in the Line Item quantity should be distributed over the sub-quantities, * the `shippingDetails` field is kept in its current state to avoid data loss. * * To change the Line Item quantity and shipping details together, * use this update action in combination with the [Set LineItemShippingDetails](ctp:api:type:CartSetCustomLineItemShippingDetailsAction) update action * in a single Cart update command. * * When the action applies to [LineItems](ctp:api:type:LineItem) with `ExternalTotal` LineItemPriceMode(ctp:api:type:LineItemPriceMode), * it will be changed to `ExternalPrice` and the existing `externalPrice` value, i.e. `LineItem.price`, will be retained. * The LineItem total will be calculated by the system instead, so that the `externalTotalPrice` will be dropped. *

func (MyCartChangeLineItemQuantityAction) MarshalJSON ¶

func (obj MyCartChangeLineItemQuantityAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartChangeTaxModeAction ¶

type MyCartChangeTaxModeAction struct {
	// The new TaxMode.
	TaxMode TaxMode `json:"taxMode"`
}

* * - When `External` TaxMode(ctp:api:type:TaxMode) is changed to `Platform` or `Disabled`, all previously set external Tax Rates are removed. * - When set to `Platform`, Line Items, Custom Line Items, and Shipping Method require a Tax Category with a Tax Rate for the Cart's `shippingAddress`. *

func (MyCartChangeTaxModeAction) MarshalJSON ¶

func (obj MyCartChangeTaxModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartDraft ¶

type MyCartDraft struct {
	// Currency the Cart uses.
	Currency string `json:"currency"`
	// Email address of the Customer the Cart belongs to.
	CustomerEmail *string `json:"customerEmail,omitempty"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to the Business Unit the Cart should belong to. The [Customer](ctp:api:type:Customer) must be an [Associate](ctp:api:type:Associate) of the Business Unit.
	BusinessUnit *BusinessUnitResourceIdentifier `json:"businessUnit,omitempty"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to the Store the Cart should belong to. Once set, it cannot be updated.
	Store *StoreResourceIdentifier `json:"store,omitempty"`
	// [Line Items](ctp:api:type:LineItems) to add to the Cart.
	LineItems []MyLineItemDraft `json:"lineItems"`
	// Determines how Tax Rates are set. The `Disabled` TaxMode **cannot** be set.
	TaxMode *TaxMode `json:"taxMode,omitempty"`
	// Determines how stock quantities are tracked for Line Items in the Cart.
	InventoryMode *InventoryMode `json:"inventoryMode,omitempty"`
	// Billing address associated with the Cart.
	BillingAddress *BaseAddress `json:"billingAddress,omitempty"`
	// Shipping address associated with the Cart. Determines eligible [ShippingMethod](ctp:api:type:ShippingMethod) rates and Tax Rates of Line Items.
	ShippingAddress *BaseAddress `json:"shippingAddress,omitempty"`
	// Shipping Method for the Cart. If the referenced [ShippingMethod](ctp:api:type:ShippingMethod) has a `predicate` that does not match the Cart, an [InvalidOperation](ctp:api:type:InvalidOperationError) error is returned when [creating a Cart](ctp:api:endpoint:/{projectKey}/carts:POST).
	ShippingMethod *ShippingMethodResourceIdentifier `json:"shippingMethod,omitempty"`
	// Multiple shipping addresses of the Cart. Each address must contain a `key` that is unique in this Cart.
	// The keys are used by [LineItems](ctp:api:type:LineItem) to reference these addresses under their `shippingDetails`.
	//
	// Eligible Shipping Methods or applicable Tax Rates are determined by the [Cart](ctp:api:type:Cart) `shippingAddress`, and not `itemShippingAddresses`.
	ItemShippingAddresses []BaseAddress `json:"itemShippingAddresses"`
	// `code` of the existing [DiscountCodes](ctp:api:type:DiscountCode) to add to the Cart.
	DiscountCodes []string `json:"discountCodes"`
	// Used for [LineItem Price selection](ctp:api:type:LineItemPriceSelection).
	// If used for [Create Cart in Store](ctp:api:endpoint:/{projectKey}/in-store/me/carts:POST), the provided country must be one of the [Store's](ctp:api:type:Store) `countries`.
	Country *string `json:"country,omitempty"`
	// Languages of the Cart.
	// Can only contain languages supported by the [Project](ctp:api:type:Project).
	Locale *string `json:"locale,omitempty"`
	// Number of days after which a Cart with `Active` [CartState](ctp:api:type:CartState) is deleted since its last modification.
	// If not provided, the default value for this field configured in [Project settings](ctp:api:type:CartsConfiguration) is assigned.
	//
	// Create a [ChangeSubscription](ctp:api:type:ChangeSubscription) for Carts to receive a [ResourceDeletedDeliveryPayload](ctp:api:type:ResourceDeletedDeliveryPayload) upon deletion of the Cart.
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
	// Custom Fields for the Cart.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * The `customerId` is determined by a [password flow token](/../api/authorization#password-flow) and * automatically set on the resulting Cart(ctp:api:type:Cart). * The `anonymousId` is determined by a [token for an anonymous session](ctp:api:type:AnonymousSession) and * automatically set on the resulting Cart(ctp:api:type:Cart). *

func (MyCartDraft) MarshalJSON ¶

func (obj MyCartDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartRecalculateAction ¶

type MyCartRecalculateAction struct {
	// - Leave empty or set to `false` to only update the Prices and TaxRates of the Line Items.
	// - Set to `true` to update the Line Items' product data (like `name`, `variant` and `productType`) also.
	UpdateProductData *bool `json:"updateProductData,omitempty"`
}

* * This update action does not set any Cart field in particular, but it triggers several [Cart updates](/../api/carts-orders-overview#cart-updates) * to bring prices and discounts to the latest state. Those can become stale over time when no Cart updates have been performed for a while and * prices on related Products have changed in the meanwhile. * * If the `priceMode` of the Product(ctp:api:type:Product) related to a Line Item is of `Embedded` [ProductPriceMode](ctp:api:type:ProductPriceModeEnum), * the updated `price` of that LineItem(ctp:api:type:LineItem) may not correspond to a Price in the `variant.prices` anymore. *

func (MyCartRecalculateAction) MarshalJSON ¶

func (obj MyCartRecalculateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartRemoveDiscountCodeAction ¶

type MyCartRemoveDiscountCodeAction struct {
	// Discount Code to remove from the Cart.
	DiscountCode DiscountCodeReference `json:"discountCode"`
}

func (MyCartRemoveDiscountCodeAction) MarshalJSON ¶

func (obj MyCartRemoveDiscountCodeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartRemoveItemShippingAddressAction ¶

type MyCartRemoveItemShippingAddressAction struct {
	// `key` of the Address to remove from `itemShippingAddresses`.
	AddressKey string `json:"addressKey"`
}

* * An address can only be removed if it is not referenced in any ItemShippingTarget(ctp:api:type:ItemShippingTarget) of the Cart. *

func (MyCartRemoveItemShippingAddressAction) MarshalJSON ¶

func (obj MyCartRemoveItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartRemoveLineItemAction ¶

type MyCartRemoveLineItemAction struct {
	// `id` of the Line Item to remove.
	LineItemId string `json:"lineItemId"`
	// New value to set.
	//
	// If `0`, the Line Item is removed from the Cart.
	Quantity *int `json:"quantity,omitempty"`
	// Sets the [LineItem](ctp:api:type:LineItem) `price` to the given value when decreasing the quantity of a Line Item with the `ExternalPrice` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
	ExternalPrice *Money `json:"externalPrice,omitempty"`
	// Sets the [LineItem](ctp:api:type:LineItem) `price` and `totalPrice` to the given value when decreasing the quantity of a Line Item with the `ExternalTotal` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
	ExternalTotalPrice *ExternalLineItemTotalPrice `json:"externalTotalPrice,omitempty"`
	// Container for Line Item-specific addresses to remove.
	ShippingDetailsToRemove *ItemShippingDetailsDraft `json:"shippingDetailsToRemove,omitempty"`
}

* * The LineItem(ctp:api:type:LineItem) price is updated as described in [LineItem Price selection](ctp:api:type:LineItemPriceSelection). *

func (MyCartRemoveLineItemAction) MarshalJSON ¶

func (obj MyCartRemoveLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartRemovePaymentAction ¶

type MyCartRemovePaymentAction struct {
	// Payment to remove from the Cart.
	Payment PaymentResourceIdentifier `json:"payment"`
}

func (MyCartRemovePaymentAction) MarshalJSON ¶

func (obj MyCartRemovePaymentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetBillingAddressAction ¶

type MyCartSetBillingAddressAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	Address *BaseAddress `json:"address,omitempty"`
}

func (MyCartSetBillingAddressAction) MarshalJSON ¶

func (obj MyCartSetBillingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetBusinessUnitAction ¶

type MyCartSetBusinessUnitAction struct {
	// New Business Unit to assign to the Cart, which must have access to the [Store](/../api/projects/stores) that is set on the Cart.
	// Additionally, the authenticated user must be an [Associate](/projects/business-units#associate) in the [Business Unit](/projects/business-units#businessunit).
	BusinessUnit BusinessUnitResourceIdentifier `json:"businessUnit"`
}

* * Updates the Business Unit on the Cart. The Cart must have an existing Business Unit assigned already. *

func (MyCartSetBusinessUnitAction) MarshalJSON ¶

func (obj MyCartSetBusinessUnitAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetCountryAction ¶

type MyCartSetCountryAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	//
	// If the Cart is bound to a `store`, the provided value must be included in the [Store's](ctp:api:type:Store) `countries`.
	// Otherwise a [CountryNotConfiguredInStore](ctp:api:type:CountryNotConfiguredInStoreError) error is returned.
	Country *string `json:"country,omitempty"`
}

* * Setting the country can lead to changes in the LineItem(ctp:api:type:LineItem) prices. *

func (MyCartSetCountryAction) MarshalJSON ¶

func (obj MyCartSetCountryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetCustomFieldAction ¶

type MyCartSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (MyCartSetCustomFieldAction) MarshalJSON ¶

func (obj MyCartSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetCustomTypeAction ¶

type MyCartSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the Cart with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Cart.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Cart.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (MyCartSetCustomTypeAction) MarshalJSON ¶

func (obj MyCartSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetCustomerEmailAction ¶

type MyCartSetCustomerEmailAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	Email *string `json:"email,omitempty"`
}

func (MyCartSetCustomerEmailAction) MarshalJSON ¶

func (obj MyCartSetCustomerEmailAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetDeleteDaysAfterLastModificationAction ¶

type MyCartSetDeleteDaysAfterLastModificationAction struct {
	// Value to set.
	// If not provided, the default value for this field configured in [Project settings](ctp:api:type:CartsConfiguration) is assigned.
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
}

* * Number of days after which a Cart with `Active` CartState(ctp:api:type:CartState) is deleted since its last modification. * * If a ChangeSubscription(ctp:api:type:ChangeSubscription) exists for Carts, a ResourceDeletedDeliveryPayload(ctp:api:type:ResourceDeletedDeliveryPayload) is sent. *

func (MyCartSetDeleteDaysAfterLastModificationAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetDirectDiscountsAction ¶

type MyCartSetDirectDiscountsAction struct {
	// - If set, all existing Direct Discounts are replaced.
	//   The discounts apply in the order they are added to the list.
	// - If empty, all existing Direct Discounts are removed and all affected prices on the Cart or Order are recalculated.
	Discounts []DirectDiscountDraft `json:"discounts"`
}

* * Adds a DirectDiscount(ctp:api:type:DirectDiscount), but only if no DiscountCode(ctp:api:type:DiscountCode) has been added to the Cart. * Either a Discount Code or a Direct Discount can exist on a Cart at the same time. *

func (MyCartSetDirectDiscountsAction) MarshalJSON ¶

func (obj MyCartSetDirectDiscountsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetLineItemCustomFieldAction ¶

type MyCartSetLineItemCustomFieldAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (MyCartSetLineItemCustomFieldAction) MarshalJSON ¶

func (obj MyCartSetLineItemCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetLineItemCustomTypeAction ¶

type MyCartSetLineItemCustomTypeAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the LineItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Line Item.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Line Item.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (MyCartSetLineItemCustomTypeAction) MarshalJSON ¶

func (obj MyCartSetLineItemCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetLineItemDistributionChannelAction ¶

type MyCartSetLineItemDistributionChannelAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// - If present, a [Reference](ctp:api:type:Reference) to the Channel is set for the [LineItem](ctp:api:type:LineItem) specified by `lineItemId`.
	// - If not present, the current [Reference](ctp:api:type:Reference) to a distribution channel is removed from the [LineItem](ctp:api:type:LineItem) specified by `lineItemId`.
	//   The Channel must have the `ProductDistribution` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
}

* * Setting a distribution channel for a LineItem(ctp:api:type:LineItem) can lead to an updated `price` as described in [LineItem Price selection](ctp:api:type:LineItemPriceSelection). *

func (MyCartSetLineItemDistributionChannelAction) MarshalJSON ¶

func (obj MyCartSetLineItemDistributionChannelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetLineItemShippingDetailsAction ¶

type MyCartSetLineItemShippingDetailsAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Value to set.
	// If empty, the existing value is removed.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
}

func (MyCartSetLineItemShippingDetailsAction) MarshalJSON ¶

func (obj MyCartSetLineItemShippingDetailsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetLineItemSupplyChannelAction ¶

type MyCartSetLineItemSupplyChannelAction struct {
	// `id` of the [LineItem](ctp:api:type:LineItem) to update.
	LineItemId string `json:"lineItemId"`
	// - If present, a [Reference](ctp:api:type:Reference) to the Channel is set for the [LineItem](ctp:api:type:LineItem) specified by `lineItemId`.
	// - If not present, the current [Reference](ctp:api:type:Reference) to a supply channel will be removed from the [LineItem](ctp:api:type:LineItem) specified by `lineItemId`.
	//   The Channel must have the `InventorySupply` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
}

* * Performing this action has no impact on inventory that should be reserved. *

func (MyCartSetLineItemSupplyChannelAction) MarshalJSON ¶

func (obj MyCartSetLineItemSupplyChannelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetLocaleAction ¶

type MyCartSetLocaleAction struct {
	// Value to set.
	// Must be one of the [Project](ctp:api:type:Project)'s `languages`.
	// If empty, any existing value will be removed.
	Locale *string `json:"locale,omitempty"`
}

func (MyCartSetLocaleAction) MarshalJSON ¶

func (obj MyCartSetLocaleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetShippingAddressAction ¶

type MyCartSetShippingAddressAction struct {
	// Value to set.
	// If not set, the shipping address is unset, and the `taxedPrice` and `taxRate` are unset in all Line Items.
	Address *BaseAddress `json:"address,omitempty"`
}

* * Setting the shipping address also sets the TaxRate(ctp:api:type:TaxRate) of Line Items and calculates the TaxedPrice(ctp:api:type:TaxedPrice). * * If a matching price cannot be found for the given shipping address during [Line Item Price selection](ctp:api:type:LineItemPriceSelection), * a [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError) error is returned. * * If you want to allow shipping to states inside a country that are not explicitly covered by a TaxRate, * set the `countryTaxRateFallbackEnabled` field to `true` in the CartsConfiguration(ctp:api:type:CartsConfiguration) by using * the [Change CountryTaxRateFallbackEnabled](ctp:api:type:ProjectChangeCountryTaxRateFallbackEnabledAction) update action. *

func (MyCartSetShippingAddressAction) MarshalJSON ¶

func (obj MyCartSetShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartSetShippingMethodAction ¶

type MyCartSetShippingMethodAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	//
	// If the referenced Shipping Method has a predicate that does not match the Cart, an [InvalidOperation](ctp:api:type:InvalidOperationError) error is returned.
	ShippingMethod *ShippingMethodResourceIdentifier `json:"shippingMethod,omitempty"`
	// An external Tax Rate can be set if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
}

* * To set the Cart's Shipping Method the Cart must have the `Single` ShippingMode(ctp:api:type:ShippingMode) and a `shippingAddress`. *

func (MyCartSetShippingMethodAction) MarshalJSON ¶

func (obj MyCartSetShippingMethodAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCartUpdate ¶

type MyCartUpdate struct {
	// Expected version of the Cart on which the changes apply.
	// If it does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the Cart.
	Actions []MyCartUpdateAction `json:"actions"`
}

func (*MyCartUpdate) UnmarshalJSON ¶

func (obj *MyCartUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MyCartUpdateAction ¶

type MyCartUpdateAction interface{}

type MyCartUpdateItemShippingAddressAction ¶

type MyCartUpdateItemShippingAddressAction struct {
	// The new Address with the same `key` as the Address it will replace.
	Address BaseAddress `json:"address"`
}

* * Updates an address in `itemShippingAddresses` by keeping the Address `key`. *

func (MyCartUpdateItemShippingAddressAction) MarshalJSON ¶

func (obj MyCartUpdateItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCompanyDraft ¶

type MyCompanyDraft struct {
	// User-defined unique identifier for the BusinessUnit.
	Key string `json:"key"`
	// Name of the Business Unit.
	Name string `json:"name"`
	// Email address of the Business Unit.
	ContactEmail *string `json:"contactEmail,omitempty"`
	// Custom Fields for the Business Unit.
	Custom *CustomFields `json:"custom,omitempty"`
	// Addresses used by the Business Unit.
	Addresses []BaseAddress `json:"addresses"`
	// Indexes of entries in `addresses` to set as shipping addresses.
	// The `shippingAddressIds` of the [Customer](ctp:api:type:Customer) will be replaced by these addresses.
	ShippingAddresses []int `json:"shippingAddresses"`
	// Index of the entry in `addresses` to set as the default shipping address.
	DefaultShippingAddress *int `json:"defaultShippingAddress,omitempty"`
	// Indexes of entries in `addresses` to set as billing addresses.
	// The `billingAddressIds` of the [Customer](ctp:api:type:Customer) will be replaced by these addresses.
	BillingAddresses []int `json:"billingAddresses"`
	// Index of the entry in `addresses` to set as the default billing address.
	DefaultBillingAddress *int `json:"defaultBillingAddress,omitempty"`
}

* * Draft type to represent the top level of a business. * Contains the fields and values of the generic MyBusinessUnitDraft(ctp:api:type:BusinessUnitDraft) that are used specifically for creating a Company(ctp:api:type:Company). *

func (MyCompanyDraft) MarshalJSON ¶

func (obj MyCompanyDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerAddAddressAction ¶

type MyCustomerAddAddressAction struct {
	// Value to append to the `addresses` array.
	Address BaseAddress `json:"address"`
}

* * Adding an address to the Customer produces the [CustomerAddressAdded](ctp:api:type:CustomerAddressAddedMessage) Message. *

func (MyCustomerAddAddressAction) MarshalJSON ¶

func (obj MyCustomerAddAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerAddBillingAddressIdAction ¶

type MyCustomerAddBillingAddressIdAction struct {
	// `id` of the [Address](ctp:api:type:Address) to become a billing address.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to become a billing address.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Adds an address from the `addresses` array to `billingAddressIds`. Either `addressId` or `addressKey` is required. *

func (MyCustomerAddBillingAddressIdAction) MarshalJSON ¶

func (obj MyCustomerAddBillingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerAddShippingAddressIdAction ¶

type MyCustomerAddShippingAddressIdAction struct {
	// `id` of the [Address](ctp:api:type:Address) to become a shipping address.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to become a shipping address.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Adds an address from the `addresses` array to `shippingAddressIds`. Either `addressId` or `addressKey` is required. *

func (MyCustomerAddShippingAddressIdAction) MarshalJSON ¶

func (obj MyCustomerAddShippingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerChangeAddressAction ¶

type MyCustomerChangeAddressAction struct {
	// `id` of the [Address](ctp:api:type:Address) to change.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to change.
	AddressKey *string `json:"addressKey,omitempty"`
	// Value to set.
	Address BaseAddress `json:"address"`
}

* * Changing an address of the Customer produces the [CustomerAddressChanged](ctp:api:type:CustomerAddressChangedMessage) Message. * * Either `addressId` or `addressKey` is required. *

func (MyCustomerChangeAddressAction) MarshalJSON ¶

func (obj MyCustomerChangeAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerChangeEmailAction ¶

type MyCustomerChangeEmailAction struct {
	// New value to set.
	Email string `json:"email"`
}

* * Changing the email of the Customer produces the [CustomerEmailChanged](ctp:api:type:CustomerEmailChangedMessage) Message. *

func (MyCustomerChangeEmailAction) MarshalJSON ¶

func (obj MyCustomerChangeEmailAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerChangePassword ¶

type MyCustomerChangePassword struct {
	// Expected version of the Customer on which the changes should be applied.
	Version int `json:"version"`
	// Current password of the Customer.
	//
	// If the current password does not match, an [InvalidCurrentPassword](ctp:api:type:InvalidCurrentPasswordError) error is returned.
	CurrentPassword string `json:"currentPassword"`
	// New password to be set.
	NewPassword string `json:"newPassword"`
}

type MyCustomerDraft ¶

type MyCustomerDraft struct {
	// Email address of the Customer that is [unique](/../api/customers-overview#customer-uniqueness) for an entire Project or Store the Customer is assigned to.
	// It is the mandatory unique identifier of a Customer.
	Email string `json:"email"`
	// Password of the Customer.
	Password string `json:"password"`
	// Given name (first name) of the Customer.
	FirstName *string `json:"firstName,omitempty"`
	// Family name (last name) of the Customer.
	LastName *string `json:"lastName,omitempty"`
	// Middle name of the Customer.
	MiddleName *string `json:"middleName,omitempty"`
	// Title of the Customer, for example, 'Dr.'.
	Title *string `json:"title,omitempty"`
	// Salutation of the Customer, for example, 'Mr.' or 'Mrs.'.
	Salutation *string `json:"salutation,omitempty"`
	// Date of birth of the Customer.
	DateOfBirth *Date `json:"dateOfBirth,omitempty"`
	// Company name of the Customer.
	CompanyName *string `json:"companyName,omitempty"`
	// Individual VAT ID of the Customer.
	VatId *string `json:"vatId,omitempty"`
	// Addresses of the Customer.
	Addresses []BaseAddress `json:"addresses"`
	// Index of the address in the `addresses` array to use as the default shipping address.
	// The `defaultShippingAddressId` of the Customer will be set to the `id` of that address.
	DefaultShippingAddress *int `json:"defaultShippingAddress,omitempty"`
	// Index of the address in the `addresses` array to use as the default billing address.
	// The `defaultBillingAddressId` of the Customer will be set to the `id` of that address.
	DefaultBillingAddress *int `json:"defaultBillingAddress,omitempty"`
	// Custom Fields for the Customer.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Preferred language of the Customer. Must be one of the languages supported by the [Project](ctp:api:type:Project).
	Locale *string `json:"locale,omitempty"`
	// Sets the [Stores](ctp:api:type:Store) for the Customer.
	Stores []StoreResourceIdentifier `json:"stores"`
}

func (MyCustomerDraft) MarshalJSON ¶

func (obj MyCustomerDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerEmailVerify ¶

type MyCustomerEmailVerify struct {
	// Value of the token to verify Customer email.
	TokenValue string `json:"tokenValue"`
}

type MyCustomerRemoveAddressAction ¶

type MyCustomerRemoveAddressAction struct {
	// `id` of the [Address](ctp:api:type:Address) to remove.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to remove.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removing an address of the Customer produces the [CustomerAddressRemoved](ctp:api:type:CustomerAddressRemovedMessage) Message. * * Either `addressId` or `addressKey` is required. *

func (MyCustomerRemoveAddressAction) MarshalJSON ¶

func (obj MyCustomerRemoveAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerRemoveBillingAddressIdAction ¶

type MyCustomerRemoveBillingAddressIdAction struct {
	// `id` of the [Address](ctp:api:type:Address) to remove from `billingAddressesIds`.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to remove from `billingAddressesIds`.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removes an existing billing address from `billingAddressesIds`. * If the billing address is the default billing address, the `defaultBillingAddressId` is unset. Either `addressId` or `addressKey` is required. *

func (MyCustomerRemoveBillingAddressIdAction) MarshalJSON ¶

func (obj MyCustomerRemoveBillingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerRemoveShippingAddressIdAction ¶

type MyCustomerRemoveShippingAddressIdAction struct {
	// `id` of the [Address](ctp:api:type:Address) to remove from `shippingAddressesIds`.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to remove from `shippingAddressesIds`.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Removes an existing shipping address from `shippingAddressesIds`. * If the shipping address is the default shipping address, the `defaultShippingAddressId` is unset. Either `addressId` or `addressKey` is required. *

func (MyCustomerRemoveShippingAddressIdAction) MarshalJSON ¶

func (obj MyCustomerRemoveShippingAddressIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerResetPassword ¶

type MyCustomerResetPassword struct {
	// Value of the token to reset the Customer password.
	TokenValue string `json:"tokenValue"`
	// New password to be set.
	NewPassword string `json:"newPassword"`
}

type MyCustomerSetCompanyNameAction ¶

type MyCustomerSetCompanyNameAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	CompanyName *string `json:"companyName,omitempty"`
}

* * Setting the `companyName` field on the Customer produces the [CustomerCompanyNameSet](ctp:api:type:CustomerCompanyNameSetMessage) Message. *

func (MyCustomerSetCompanyNameAction) MarshalJSON ¶

func (obj MyCustomerSetCompanyNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetCustomFieldAction ¶

type MyCustomerSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// If `value` is provided, it is set for the field defined by `name`.
	// Trying to remove a field that does not exist will fail with an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	Value interface{} `json:"value,omitempty"`
}

func (MyCustomerSetCustomFieldAction) MarshalJSON ¶

func (obj MyCustomerSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetCustomTypeAction ¶

type MyCustomerSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the MyCustomer with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the MyCustomer.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the MyCustomer.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (MyCustomerSetCustomTypeAction) MarshalJSON ¶

func (obj MyCustomerSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetDateOfBirthAction ¶

type MyCustomerSetDateOfBirthAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	DateOfBirth *Date `json:"dateOfBirth,omitempty"`
}

* * Setting the date of birth of the Customer produces the [CustomerDateOfBirthSet](ctp:api:type:CustomerDateOfBirthSetMessage) Message. *

func (MyCustomerSetDateOfBirthAction) MarshalJSON ¶

func (obj MyCustomerSetDateOfBirthAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetDefaultBillingAddressAction ¶

type MyCustomerSetDefaultBillingAddressAction struct {
	// `id` of the [Address](ctp:api:type:Address) to become the default billing address.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to become the default billing address.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Sets the default billing address from `addresses`. * If the address is not currently a billing address, it is added to `billingAddressIds`. Either `addressId` or `addressKey` is required. *

func (MyCustomerSetDefaultBillingAddressAction) MarshalJSON ¶

func (obj MyCustomerSetDefaultBillingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetDefaultShippingAddressAction ¶

type MyCustomerSetDefaultShippingAddressAction struct {
	// `id` of the [Address](ctp:api:type:Address) to become the default shipping address.
	AddressId *string `json:"addressId,omitempty"`
	// `key` of the [Address](ctp:api:type:Address) to become the default shipping address.
	AddressKey *string `json:"addressKey,omitempty"`
}

* * Sets the default shipping address from `addresses`. * If the address is not currently a shipping address, it is added to `shippingAddressIds`. Either `addressId` or `addressKey` is required. *

func (MyCustomerSetDefaultShippingAddressAction) MarshalJSON ¶

func (obj MyCustomerSetDefaultShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetFirstNameAction ¶

type MyCustomerSetFirstNameAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	FirstName *string `json:"firstName,omitempty"`
}

* * Setting the first name of the Customer produces the CustomerFirstNameSetMessage(ctp:api:type:CustomerFirstNameSetMessage). *

func (MyCustomerSetFirstNameAction) MarshalJSON ¶

func (obj MyCustomerSetFirstNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetLastNameAction ¶

type MyCustomerSetLastNameAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	LastName *string `json:"lastName,omitempty"`
}

* * Setting the last name of the Customer produces the CustomerLastNameSetMessage(ctp:api:type:CustomerLastNameSetMessage). *

func (MyCustomerSetLastNameAction) MarshalJSON ¶

func (obj MyCustomerSetLastNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetLocaleAction ¶

type MyCustomerSetLocaleAction struct {
	// Value to set.
	// Must be one of the languages supported by the [Project](ctp:api:type:Project).
	Locale *string `json:"locale,omitempty"`
}

func (MyCustomerSetLocaleAction) MarshalJSON ¶

func (obj MyCustomerSetLocaleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetMiddleNameAction ¶

type MyCustomerSetMiddleNameAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	MiddleName *string `json:"middleName,omitempty"`
}

func (MyCustomerSetMiddleNameAction) MarshalJSON ¶

func (obj MyCustomerSetMiddleNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetSalutationAction ¶

type MyCustomerSetSalutationAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	Salutation *string `json:"salutation,omitempty"`
}

func (MyCustomerSetSalutationAction) MarshalJSON ¶

func (obj MyCustomerSetSalutationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetTitleAction ¶

type MyCustomerSetTitleAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	Title *string `json:"title,omitempty"`
}

* * Setting the title of the Customer produces the CustomerTitleSetMessage(ctp:api:type:CustomerTitleSetMessage). *

func (MyCustomerSetTitleAction) MarshalJSON ¶

func (obj MyCustomerSetTitleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSetVatIdAction ¶

type MyCustomerSetVatIdAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	VatId *string `json:"vatId,omitempty"`
}

func (MyCustomerSetVatIdAction) MarshalJSON ¶

func (obj MyCustomerSetVatIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyCustomerSignin ¶

type MyCustomerSignin struct {
	// Email address of the Customer treated as [case-insensitive](/../api/customers-overview#email-case-insensitivity).
	Email string `json:"email"`
	// Password of the Customer.
	Password string `json:"password"`
	// - If `MergeWithExistingCustomerCart`, [LineItems](ctp:api:type:LineItem) of the anonymous Cart are merged with the recently modified active Customer Cart.
	// - If `UseAsNewActiveCustomerCart`, the anonymous Cart is used as the new active Customer Cart, and no [LineItems](ctp:api:type:LineItem) are merged.
	ActiveCartSignInMode *AnonymousCartSignInMode `json:"activeCartSignInMode,omitempty"`
	// - If `true`, the [LineItem](ctp:api:type:LineItem) Product data (`name`, `variant`, and `productType`) of the returned Cart is updated.
	// - If `false`, only the prices, discounts, and tax rates are updated.
	UpdateProductData *bool `json:"updateProductData,omitempty"`
}

type MyCustomerUpdate ¶

type MyCustomerUpdate struct {
	// Expected version of the Customer on which the changes should be applied. If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the Customer.
	Actions []MyCustomerUpdateAction `json:"actions"`
}

func (*MyCustomerUpdate) UnmarshalJSON ¶

func (obj *MyCustomerUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MyCustomerUpdateAction ¶

type MyCustomerUpdateAction interface{}

type MyDivisionDraft ¶

type MyDivisionDraft struct {
	// User-defined unique identifier for the BusinessUnit.
	Key string `json:"key"`
	// Name of the Business Unit.
	Name string `json:"name"`
	// Email address of the Business Unit.
	ContactEmail *string `json:"contactEmail,omitempty"`
	// Custom Fields for the Business Unit.
	Custom *CustomFields `json:"custom,omitempty"`
	// Addresses used by the Business Unit.
	Addresses []BaseAddress `json:"addresses"`
	// Indexes of entries in `addresses` to set as shipping addresses.
	// The `shippingAddressIds` of the [Customer](ctp:api:type:Customer) will be replaced by these addresses.
	ShippingAddresses []int `json:"shippingAddresses"`
	// Index of the entry in `addresses` to set as the default shipping address.
	DefaultShippingAddress *int `json:"defaultShippingAddress,omitempty"`
	// Indexes of entries in `addresses` to set as billing addresses.
	// The `billingAddressIds` of the [Customer](ctp:api:type:Customer) will be replaced by these addresses.
	BillingAddresses []int `json:"billingAddresses"`
	// Index of the entry in `addresses` to set as the default billing address.
	DefaultBillingAddress *int `json:"defaultBillingAddress,omitempty"`
	// The parent unit of this Division. Can be a Company or a Division.
	ParentUnit BusinessUnitResourceIdentifier `json:"parentUnit"`
}

* * Draft type to model divisions that are part of the Company(ctp:api:type:Company) or a higher-order Division(ctp:api:type:Division). * Contains the fields and values of the generic MyBusinessUnitDraft(ctp:api:type:MyBusinessUnitDraft) that are used specifically for creating a Division. *

func (MyDivisionDraft) MarshalJSON ¶

func (obj MyDivisionDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyLineItemDraft ¶

type MyLineItemDraft struct {
	// User-defined unique identifier of the LineItem.
	Key *string `json:"key,omitempty"`
	// `id` of the [Product](ctp:api:type:Product).
	ProductId *string `json:"productId,omitempty"`
	// `id` of the [ProductVariant](ctp:api:type:ProductVariant) in the Product.
	// If not provided, the Master Variant is used.
	VariantId *int `json:"variantId,omitempty"`
	// `sku` of the [ProductVariant](ctp:api:type:ProductVariant).
	Sku *string `json:"sku,omitempty"`
	// Number of Product Variants to add to the Cart.
	Quantity *int `json:"quantity,omitempty"`
	// Date and time (UTC) the Product Variant is added to the Cart.
	// If not set, it defaults to the current date and time.
	//
	// Optional for backwards compatibility reasons.
	AddedAt *time.Time `json:"addedAt,omitempty"`
	// Used to identify [Inventory entries](/../api/projects/inventory) that must be reserved.
	// The Channel must have the `InventorySupply` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
	// Used to [select](ctp:api:type:LineItemPriceSelection) a Product Price.
	// The Channel must have the `ProductDistribution` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	//
	// If the Cart is bound to a [Store](ctp:api:type:Store) with `distributionChannels` set,
	// the Channel must match one of the Store's distribution channels.
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
	// Container for Line Item-specific addresses.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
	// Custom Fields for the Cart.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * For Product Variant identification, either the `productId` and `variantId`, or `sku` must be provided. *

type MyOrderFromCartDraft ¶

type MyOrderFromCartDraft struct {
	// Unique identifier of the Cart that initiates an Order creation.
	ID      string `json:"id"`
	Version int    `json:"version"`
}

* * When creating [B2B Orders](/../api/associates-overview#b2b-resources), the Customer must have the `MyOrderFromCartDraft` Permission(ctp:api:type:Permission).

type MyOrderFromQuoteDraft ¶

type MyOrderFromQuoteDraft struct {
	// Unique identifier of the Quote from which the Order is created.
	ID string `json:"id"`
	// `version` of the [Quote](ctp:api:type:quote) from which the Order is created.
	Version int `json:"version"`
	// Set to `true`, if the `quoteState` of the referenced [Quote](ctp:api:type:quote) should be set to `Accepted`.
	QuoteStateToAccepted *bool `json:"quoteStateToAccepted,omitempty"`
}

* * When creating [B2B Orders](/../api/associates-overview#b2b-resources), the Customer must have the `MyOrderFromQuoteDraft` Permission(ctp:api:type:Permission).

type MyPayment ¶

type MyPayment struct {
	// Unique identifier of the Payment.
	ID string `json:"id"`
	// Current version of the Payment.
	Version int `json:"version"`
	// Reference to a [Customer](ctp:api:type:Customer) associated with the Payment. Set automatically with a [password flow token](/../api/authorization#password-flow). Either `customer` or `anonymousId` is present.
	Customer *CustomerReference `json:"customer,omitempty"`
	// [Anonymous session](ctp:api:type:AnonymousSession) associated with the Payment. Set automatically with a [token for an anonymous session](ctp:api:type:AnonymousSession). Either `customer` or `anonymousId` is present.
	AnonymousId *string `json:"anonymousId,omitempty"`
	// Money value the Payment intends to receive from the customer.
	// The value typically matches the [Cart](ctp:api:type:Cart) or [Order](ctp:api:type:Order) gross total.
	AmountPlanned CentPrecisionMoney `json:"amountPlanned"`
	// Information regarding the payment interface (for example, a PSP), and the specific payment method used.
	PaymentMethodInfo PaymentMethodInfo `json:"paymentMethodInfo"`
	// Financial transactions of the Payment. Each Transaction has a [TransactionType](ctp:api:type:TransactionType) and a [TransactionState](ctp:api:type:TransactionState).
	Transactions []Transaction `json:"transactions"`
	// Custom Fields defined for the Payment.
	Custom *CustomFields `json:"custom,omitempty"`
}

type MyPaymentAddTransactionAction ¶

type MyPaymentAddTransactionAction struct {
	// Transaction to add to the Payment.
	Transaction TransactionDraft `json:"transaction"`
}

* * Adding a Transaction to a Payment generates the [PaymentTransactionAdded](ctp:api:type:PaymentTransactionAddedMessage) Message. * Once a Transaction is added to the Payment, it can no longer be updated or deleted using the My Payments API. *

func (MyPaymentAddTransactionAction) MarshalJSON ¶

func (obj MyPaymentAddTransactionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyPaymentChangeAmountPlannedAction ¶

type MyPaymentChangeAmountPlannedAction struct {
	// New value to set.
	Amount Money `json:"amount"`
}

* * Can be used to update the Payment if a customer changes the Cart(ctp:api:type:Cart), or adds or removes a CartDiscount(ctp:api:type:CartDiscount) during checkout. *

func (MyPaymentChangeAmountPlannedAction) MarshalJSON ¶

func (obj MyPaymentChangeAmountPlannedAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyPaymentDraft ¶

type MyPaymentDraft struct {
	// Money value the Payment intends to receive from the customer.
	// The value usually matches the [Cart](ctp:api:type:Cart) or [Order](ctp:api:type:Order) gross total.
	AmountPlanned Money `json:"amountPlanned"`
	// Information regarding the payment interface (for example, a PSP), and the specific payment method used.
	PaymentMethodInfo *PaymentMethodInfo `json:"paymentMethodInfo,omitempty"`
	// Custom Fields for the Payment.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Financial transactions of the [TransactionTypes](ctp:api:type:TransactionType) `Authorization` or `Charge`.
	Transaction *MyTransactionDraft `json:"transaction,omitempty"`
}

type MyPaymentPagedQueryResponse ¶

type MyPaymentPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// [MyPayments](ctp:api:type:MyPayment) matching the query.
	Results []MyPayment `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of MyPayment(ctp:api:type:MyPayment). *

type MyPaymentSetCustomFieldAction ¶

type MyPaymentSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (MyPaymentSetCustomFieldAction) MarshalJSON ¶

func (obj MyPaymentSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyPaymentSetMethodInfoInterfaceAction ¶

type MyPaymentSetMethodInfoInterfaceAction struct {
	// Value to set.
	// Once set, the `paymentInterface` of the `paymentMethodInfo` cannot be changed.
	Interface string `json:"interface"`
}

func (MyPaymentSetMethodInfoInterfaceAction) MarshalJSON ¶

func (obj MyPaymentSetMethodInfoInterfaceAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyPaymentSetMethodInfoMethodAction ¶

type MyPaymentSetMethodInfoMethodAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	Method *string `json:"method,omitempty"`
}

func (MyPaymentSetMethodInfoMethodAction) MarshalJSON ¶

func (obj MyPaymentSetMethodInfoMethodAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyPaymentSetMethodInfoNameAction ¶

type MyPaymentSetMethodInfoNameAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	Name *LocalizedString `json:"name,omitempty"`
}

func (MyPaymentSetMethodInfoNameAction) MarshalJSON ¶

func (obj MyPaymentSetMethodInfoNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyPaymentSetTransactionCustomFieldAction ¶

type MyPaymentSetTransactionCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (MyPaymentSetTransactionCustomFieldAction) MarshalJSON ¶

func (obj MyPaymentSetTransactionCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyPaymentUpdate ¶

type MyPaymentUpdate struct {
	// Expected version of the Payment on which the changes should be applied. If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the Payment.
	Actions []MyPaymentUpdateAction `json:"actions"`
}

func (*MyPaymentUpdate) UnmarshalJSON ¶

func (obj *MyPaymentUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MyPaymentUpdateAction ¶

type MyPaymentUpdateAction interface{}

type MyQuoteChangeMyQuoteStateAction ¶

type MyQuoteChangeMyQuoteStateAction struct {
	// New state to be set for the Quote.
	QuoteState MyQuoteState `json:"quoteState"`
}

* * When accepting, declining, or renegotiating [B2B Quotes](/../api/associates-overview#b2b-resources), the Customer must have the `AcceptMyQuotes`, `DeclineMyQuotes`, or `RenegotiateMyQuotes` Permission(ctp:api:type:Permission), respectively. If the required Permission(/projects/associate-roles#permission) is missing, an [AssociateMissingPermission](/errors#associatemissingpermission) error is returned.

func (MyQuoteChangeMyQuoteStateAction) MarshalJSON ¶

func (obj MyQuoteChangeMyQuoteStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyQuoteRequestCancelAction ¶

type MyQuoteRequestCancelAction struct {
}

* * Transitions the `quoteRequestState` of the Quote Request to `Cancelled`. Can only be used when the Quote Request is in state `Submitted`. *

func (MyQuoteRequestCancelAction) MarshalJSON ¶

func (obj MyQuoteRequestCancelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyQuoteRequestDraft ¶

type MyQuoteRequestDraft struct {
	// `id` of the Cart from which the Quote Request is created.
	CartId string `json:"cartId"`
	// Current version of the Cart.
	CartVersion int `json:"cartVersion"`
	// Message from the Buyer included in the Quote Request.
	Comment string `json:"comment"`
}

type MyQuoteRequestUpdate ¶

type MyQuoteRequestUpdate struct {
	Version int                          `json:"version"`
	Actions []MyQuoteRequestUpdateAction `json:"actions"`
}

func (*MyQuoteRequestUpdate) UnmarshalJSON ¶

func (obj *MyQuoteRequestUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MyQuoteRequestUpdateAction ¶

type MyQuoteRequestUpdateAction interface{}

type MyQuoteState ¶

type MyQuoteState string

* * [QuoteStates](ctp:api:type:QuoteState) that can be set using the [Change My Quote State](ctp:api:type:MyQuoteChangeMyQuoteStateAction) update action. *

const (
	MyQuoteStateDeclined MyQuoteState = "Declined"
	MyQuoteStateAccepted MyQuoteState = "Accepted"
)

type MyQuoteUpdate ¶

type MyQuoteUpdate struct {
	// Expected version of the [Quote](ctp:api:type:Quote) to which the changes should be applied.
	// If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the [Quote](ctp:api:type:Quote).
	Actions []MyQuoteUpdateAction `json:"actions"`
}

func (*MyQuoteUpdate) UnmarshalJSON ¶

func (obj *MyQuoteUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MyQuoteUpdateAction ¶

type MyQuoteUpdateAction interface{}

type MyShoppingListAddLineItemAction ¶

type MyShoppingListAddLineItemAction struct {
	// `sku` of the [ProductVariant](ctp:api:type:ProductVariant).
	Sku *string `json:"sku,omitempty"`
	// Unique identifier of a [Product](ctp:api:type:Product).
	ProductId *string `json:"productId,omitempty"`
	// `id` of the [ProductVariant](ctp:api:type:ProductVariant). If not set, the ShoppingListLineItem refers to the Master Variant.
	VariantId *int `json:"variantId,omitempty"`
	// Number of Products in the [ShoppingListLineItem](ctp:api:type:ShoppingListLineItem).
	Quantity *int `json:"quantity,omitempty"`
	// Date and time the TextLineItem is added to the [ShoppingList](ctp:api:type:ShoppingList). If not set, the current date and time (UTC) is used.
	AddedAt *time.Time `json:"addedAt,omitempty"`
	// Custom Fields defined for the ShoppingListLineItem.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (MyShoppingListAddLineItemAction) MarshalJSON ¶

func (obj MyShoppingListAddLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListAddTextLineItemAction ¶

type MyShoppingListAddTextLineItemAction struct {
	// Name of the [TextLineItem](ctp:api:type:TextLineItem).
	Name LocalizedString `json:"name"`
	// Description of the TextLineItem.
	Description *LocalizedString `json:"description,omitempty"`
	// Number of entries in the TextLineItem.
	Quantity *int `json:"quantity,omitempty"`
	// Date and time the TextLineItem is added to the [ShoppingList](ctp:api:type:ShoppingList). If not set, the current date and time (UTC) is used.
	AddedAt *time.Time `json:"addedAt,omitempty"`
	// Custom Fields defined for the TextLineItem.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (MyShoppingListAddTextLineItemAction) MarshalJSON ¶

func (obj MyShoppingListAddTextLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListChangeLineItemQuantityAction ¶

type MyShoppingListChangeLineItemQuantityAction struct {
	// The `id` of the [ShoppingListLineItem](ctp:api:type:ShoppingListLineItem) to update.
	LineItemId string `json:"lineItemId"`
	// New value to set. If `0`, the ShoppingListLineItem is removed from the ShoppingList.
	Quantity int `json:"quantity"`
}

func (MyShoppingListChangeLineItemQuantityAction) MarshalJSON ¶

func (obj MyShoppingListChangeLineItemQuantityAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListChangeLineItemsOrderAction ¶

type MyShoppingListChangeLineItemsOrderAction struct {
	// All existing [ShoppingListLineItem](ctp:api:type:ShoppingListLineItem) `id`s of the [ShoppingList](ctp:api:type:ShoppingList) in the desired new order.
	LineItemOrder []string `json:"lineItemOrder"`
}

func (MyShoppingListChangeLineItemsOrderAction) MarshalJSON ¶

func (obj MyShoppingListChangeLineItemsOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListChangeNameAction ¶

type MyShoppingListChangeNameAction struct {
	// New value to set. Must not be empty.
	Name LocalizedString `json:"name"`
}

func (MyShoppingListChangeNameAction) MarshalJSON ¶

func (obj MyShoppingListChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListChangeTextLineItemNameAction ¶

type MyShoppingListChangeTextLineItemNameAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// New value to set. Must not be empty.
	Name LocalizedString `json:"name"`
}

func (MyShoppingListChangeTextLineItemNameAction) MarshalJSON ¶

func (obj MyShoppingListChangeTextLineItemNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListChangeTextLineItemQuantityAction ¶

type MyShoppingListChangeTextLineItemQuantityAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// New value to set. If `0`, the TextLineItem is removed from the ShoppingList.
	Quantity int `json:"quantity"`
}

func (MyShoppingListChangeTextLineItemQuantityAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListChangeTextLineItemsOrderAction ¶

type MyShoppingListChangeTextLineItemsOrderAction struct {
	// All existing [TextLineItem](ctp:api:type:TextLineItem) `id`s in the desired new order.
	TextLineItemOrder []string `json:"textLineItemOrder"`
}

func (MyShoppingListChangeTextLineItemsOrderAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListDraft ¶

type MyShoppingListDraft struct {
	// Name of the [ShoppingList](ctp:api:type:ShoppingList).
	Name LocalizedString `json:"name"`
	// Description of the ShoppingList.
	Description *LocalizedString `json:"description,omitempty"`
	// [Line Items](ctp:api:type:ShoppingListLineItem) (containing Products) to add to the ShoppingList.
	LineItems []ShoppingListLineItemDraft `json:"lineItems"`
	// [Line Items](ctp:api:type:TextLineItem) (containing text values) to add to the ShoppingList.
	TextLineItems []TextLineItemDraft `json:"textLineItems"`
	// Custom Fields defined for the ShoppingList.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Number of days after which the ShoppingList will be automatically deleted if it has not been modified. If not set, the [default value](ctp:api:type:ShoppingListsConfiguration) configured in the [Project](ctp:api:type:Project) is used.
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
	// Assigns the new ShoppingList to the [Store](ctp:api:type:Store). The Store assignment can not be modified.
	Store *StoreResourceIdentifier `json:"store,omitempty"`
}

* * A MyShoppingListDraft(ctp:api:type:MyShoppingListDraft) is the object submitted as payload to the [Create MyShoppingList request](ctp:api:endpoint:/{projectKey}/me/shopping-lists:POST). * The `customer` field of ShoppingList(ctp:api:type:ShoppingList) is automatically set with * a [password flow token](/authorization#password-flow). * The `anonymousId` is automatically set with a [token for an anonymous session](/authorization#tokens-for-anonymous-sessions). * The `key` and `slug` fields can not be set. *

func (MyShoppingListDraft) MarshalJSON ¶

func (obj MyShoppingListDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListRemoveLineItemAction ¶

type MyShoppingListRemoveLineItemAction struct {
	// The `id` of the [ShoppingListLineItem](ctp:api:type:ShoppingListLineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Amount to remove from the `quantity` of the ShoppingListLineItem. If not set, the ShoppingListLineItem is removed from the ShoppingList. If this value matches or exceeds the current `quantity` of the ShoppingListLineItem, the ShoppingListLineItem is removed from the ShoppingList.
	Quantity *int `json:"quantity,omitempty"`
}

func (MyShoppingListRemoveLineItemAction) MarshalJSON ¶

func (obj MyShoppingListRemoveLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListRemoveTextLineItemAction ¶

type MyShoppingListRemoveTextLineItemAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// Amount to remove from the `quantity` of the TextLineItem. If not set, the TextLineItem is removed from the ShoppingList. If this value matches or exceeds the current `quantity` of the TextLineItem, the TextLineItem is removed from the ShoppingList.
	Quantity *int `json:"quantity,omitempty"`
}

func (MyShoppingListRemoveTextLineItemAction) MarshalJSON ¶

func (obj MyShoppingListRemoveTextLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListSetCustomFieldAction ¶

type MyShoppingListSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (MyShoppingListSetCustomFieldAction) MarshalJSON ¶

func (obj MyShoppingListSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListSetCustomTypeAction ¶

type MyShoppingListSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the MyShoppingList with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the MyShoppingList.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the MyShoppingList.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (MyShoppingListSetCustomTypeAction) MarshalJSON ¶

func (obj MyShoppingListSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListSetDeleteDaysAfterLastModificationAction ¶

type MyShoppingListSetDeleteDaysAfterLastModificationAction struct {
	// Value to set. If empty, any existing value will be removed.
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
}

func (MyShoppingListSetDeleteDaysAfterLastModificationAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListSetDescriptionAction ¶

type MyShoppingListSetDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

func (MyShoppingListSetDescriptionAction) MarshalJSON ¶

func (obj MyShoppingListSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListSetLineItemCustomFieldAction ¶

type MyShoppingListSetLineItemCustomFieldAction struct {
	// Unique identifier of an existing [ShoppingListLineItem](ctp:api:type:ShoppingListLineItem) in the [ShoppingList](ctp:api:type:ShoppingList).
	LineItemId string `json:"lineItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (MyShoppingListSetLineItemCustomFieldAction) MarshalJSON ¶

func (obj MyShoppingListSetLineItemCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListSetLineItemCustomTypeAction ¶

type MyShoppingListSetLineItemCustomTypeAction struct {
	// Unique identifier of an existing [ShoppingListLineItem](ctp:api:type:ShoppingListLineItem) in the [ShoppingList](ctp:api:type:ShoppingList).
	LineItemId string `json:"lineItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the ShoppingListLineItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the ShoppingListLineItem.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the ShoppingListLineItem.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (MyShoppingListSetLineItemCustomTypeAction) MarshalJSON ¶

func (obj MyShoppingListSetLineItemCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListSetTextLineItemCustomFieldAction ¶

type MyShoppingListSetTextLineItemCustomFieldAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (MyShoppingListSetTextLineItemCustomFieldAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListSetTextLineItemCustomTypeAction ¶

type MyShoppingListSetTextLineItemCustomTypeAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the TextLineItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the TextLineItem.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the TextLineItem.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (MyShoppingListSetTextLineItemCustomTypeAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListSetTextLineItemDescriptionAction ¶

type MyShoppingListSetTextLineItemDescriptionAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

func (MyShoppingListSetTextLineItemDescriptionAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type MyShoppingListUpdate ¶

type MyShoppingListUpdate struct {
	// Expected version of the ShoppingList on which the changes should be applied. If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) will be returned.
	Version int `json:"version"`
	// List of update actions to be performed on the ShoppingList.
	Actions []MyShoppingListUpdateAction `json:"actions"`
}

func (*MyShoppingListUpdate) UnmarshalJSON ¶

func (obj *MyShoppingListUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type MyShoppingListUpdateAction ¶

type MyShoppingListUpdateAction interface{}

type MyTransactionDraft ¶

type MyTransactionDraft struct {
	// Date and time (UTC) the Transaction took place.
	Timestamp *time.Time `json:"timestamp,omitempty"`
	// Type of the Transaction.
	// Only `Authorization` or `Charge` is allowed.
	Type TransactionType `json:"type"`
	// Money value for the Transaction.
	Amount Money `json:"amount"`
	// Identifier used by the payment service that manages the Transaction.
	// Can be used to correlate the Transaction to an interface interaction.
	InteractionId *string `json:"interactionId,omitempty"`
	// Custom Fields of the Transaction.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

type NoMatchingProductDiscountFoundError ¶

type NoMatchingProductDiscountFoundError struct {
	// `"Couldn't find a matching product discount for: productId=$productId, variantId=$variantId, price=$price."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a Product Discount could not be found that could be applied to the Price of a Product Variant. * * The error is returned as a failed response to the [Get Matching ProductDiscount](/../api/projects/productDiscounts#get-matching-productdiscount) request. *

func (*NoMatchingProductDiscountFoundError) DecodeStruct ¶

func (obj *NoMatchingProductDiscountFoundError) DecodeStruct(src map[string]interface{}) error

func (NoMatchingProductDiscountFoundError) Error ¶

func (NoMatchingProductDiscountFoundError) MarshalJSON ¶

func (obj NoMatchingProductDiscountFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*NoMatchingProductDiscountFoundError) UnmarshalJSON ¶

func (obj *NoMatchingProductDiscountFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type NotEnabledError ¶

type NotEnabledError struct {
	// `"The category recommendations API is not yet enabled for your project."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the [Project-specific category recommendations feature](/../api/projects/categoryRecommendations#project-specific-category-recommendations) is not enabled for the Project. *

func (*NotEnabledError) DecodeStruct ¶

func (obj *NotEnabledError) DecodeStruct(src map[string]interface{}) error

func (NotEnabledError) Error ¶

func (obj NotEnabledError) Error() string

func (NotEnabledError) MarshalJSON ¶

func (obj NotEnabledError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*NotEnabledError) UnmarshalJSON ¶

func (obj *NotEnabledError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ObjectNotFoundError ¶

type ObjectNotFoundError struct {
	// `"A $resourceType with identifier $id was unexpectedly not found."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the requested resource was not found. *

func (*ObjectNotFoundError) DecodeStruct ¶

func (obj *ObjectNotFoundError) DecodeStruct(src map[string]interface{}) error

func (ObjectNotFoundError) Error ¶

func (obj ObjectNotFoundError) Error() string

func (ObjectNotFoundError) MarshalJSON ¶

func (obj ObjectNotFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ObjectNotFoundError) UnmarshalJSON ¶

func (obj *ObjectNotFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type Order ¶

type Order struct {
	// Unique identifier of the Order.
	ID string `json:"id"`
	// The current version of the order.
	Version        int       `json:"version"`
	CreatedAt      time.Time `json:"createdAt"`
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// This field will only be present if it was set for Order Import
	CompletedAt *time.Time `json:"completedAt,omitempty"`
	// String that uniquely identifies an order.
	// It can be used to create more human-readable (in contrast to ID) identifier for the order.
	// It should be unique across a project.
	// Once it's set it cannot be changed.
	OrderNumber   *string `json:"orderNumber,omitempty"`
	CustomerId    *string `json:"customerId,omitempty"`
	CustomerEmail *string `json:"customerEmail,omitempty"`
	// Identifies carts and orders belonging to an anonymous session (the customer has not signed up/in yet).
	AnonymousId *string `json:"anonymousId,omitempty"`
	// The Business Unit the Order belongs to.
	BusinessUnit    *BusinessUnitKeyReference `json:"businessUnit,omitempty"`
	Store           *StoreKeyReference        `json:"store,omitempty"`
	LineItems       []LineItem                `json:"lineItems"`
	CustomLineItems []CustomLineItem          `json:"customLineItems"`
	TotalPrice      TypedMoney                `json:"totalPrice"`
	// The taxes are calculated based on the shipping address.
	TaxedPrice *TaxedPrice `json:"taxedPrice,omitempty"`
	// Sum of `taxedPrice` of [ShippingInfo](ctp:api:type:ShippingInfo) across all Shipping Methods.
	// For `Platform` [TaxMode](ctp:api:type:TaxMode), it is set automatically only if [shipping address is set](ctp:api:type:CartSetShippingAddressAction) or [Shipping Method is added](ctp:api:type:CartAddShippingMethodAction) to the Cart.
	TaxedShippingPrice *TaxedPrice `json:"taxedShippingPrice,omitempty"`
	// Holds all shipping-related information per Shipping Method.
	//
	// For `Multi` [ShippingMode](ctp:api:typeShippingMode), it is updated automatically after the Shipping Methods are added.
	ShippingAddress *Address `json:"shippingAddress,omitempty"`
	BillingAddress  *Address `json:"billingAddress,omitempty"`
	// Indicates whether one or multiple Shipping Methods are added to the Cart.
	ShippingMode ShippingMode `json:"shippingMode"`
	// User-defined unique identifier of the Shipping Method with `Single` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
	// Custom Fields of the Shipping Method for `Single` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingCustomFields *CustomFields `json:"shippingCustomFields,omitempty"`
	// Holds all shipping-related information per Shipping Method for `Multi` [ShippingMode](ctp:api:typeShippingMode).
	//
	// It is updated automatically after the [Shipping Method is added](ctp:api:type:CartAddShippingMethodAction).
	Shipping []Shipping `json:"shipping"`
	TaxMode  *TaxMode   `json:"taxMode,omitempty"`
	// When calculating taxes for `taxedPrice`, the selected mode is used for rouding.
	TaxRoundingMode *RoundingMode `json:"taxRoundingMode,omitempty"`
	// Set when the customer is set and the customer is a member of a customer group.
	// Used for product variant price selection.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// A two-digit country code as per [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).
	// Used for product variant price selection.
	Country *string `json:"country,omitempty"`
	// One of the four predefined OrderStates.
	OrderState OrderState `json:"orderState"`
	// This reference can point to a state in a custom workflow.
	State         *StateReference `json:"state,omitempty"`
	ShipmentState *ShipmentState  `json:"shipmentState,omitempty"`
	PaymentState  *PaymentState   `json:"paymentState,omitempty"`
	// Set if the ShippingMethod is set.
	ShippingInfo *ShippingInfo `json:"shippingInfo,omitempty"`
	SyncInfo     []SyncInfo    `json:"syncInfo"`
	ReturnInfo   []ReturnInfo  `json:"returnInfo"`
	// The Purchase Order Number is typically set by the [Buyer](/quotes-overview#buyer) on a [QuoteRequest](ctp:api:type:QuoteRequest) to
	// track the purchase order during the [quote and order flow](/../api/quotes-overview#intended-workflow).
	PurchaseOrderNumber *string            `json:"purchaseOrderNumber,omitempty"`
	DiscountCodes       []DiscountCodeInfo `json:"discountCodes"`
	// Internal-only field.
	LastMessageSequenceNumber *int `json:"lastMessageSequenceNumber,omitempty"`
	// Set when this order was created from a cart.
	// The cart will have the state `Ordered`.
	Cart *CartReference `json:"cart,omitempty"`
	// Set when this order was created from a quote.
	Quote         *QuoteReference `json:"quote,omitempty"`
	Custom        *CustomFields   `json:"custom,omitempty"`
	PaymentInfo   *PaymentInfo    `json:"paymentInfo,omitempty"`
	Locale        *string         `json:"locale,omitempty"`
	InventoryMode *InventoryMode  `json:"inventoryMode,omitempty"`
	Origin        CartOrigin      `json:"origin"`
	// When calculating taxes for `taxedPrice`, the selected mode is used for calculating the price with LineItemLevel (horizontally) or UnitPriceLevel (vertically) calculation mode.
	TaxCalculationMode *TaxCalculationMode `json:"taxCalculationMode,omitempty"`
	// Input used to select a [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	// The data type of this field depends on the `shippingRateInputType.type` configured in the [Project](ctp:api:type:Project):
	//
	// - If `CartClassification`, it is [ClassificationShippingRateInput](ctp:api:type:ClassificationShippingRateInput).
	// - If `CartScore`, it is [ScoreShippingRateInput](ctp:api:type:ScoreShippingRateInput).
	// - If `CartValue`, it cannot be used.
	ShippingRateInput ShippingRateInput `json:"shippingRateInput,omitempty"`
	// Contains addresses for orders with multiple shipping addresses.
	ItemShippingAddresses []Address `json:"itemShippingAddresses"`
	// Automatically filled when a line item with LineItemMode `GiftLineItem` is removed from this order.
	RefusedGifts []CartDiscountReference `json:"refusedGifts"`
}

func (Order) MarshalJSON ¶

func (obj Order) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*Order) UnmarshalJSON ¶

func (obj *Order) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderAddDeliveryAction ¶

type OrderAddDeliveryAction struct {
	// User-defined unique identifier of a Delivery.
	DeliveryKey *string        `json:"deliveryKey,omitempty"`
	Items       []DeliveryItem `json:"items"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address *BaseAddress  `json:"address,omitempty"`
	Parcels []ParcelDraft `json:"parcels"`
	// Custom Fields for the Transaction.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (OrderAddDeliveryAction) MarshalJSON ¶

func (obj OrderAddDeliveryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderAddItemShippingAddressAction ¶

type OrderAddItemShippingAddressAction struct {
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address BaseAddress `json:"address"`
}

func (OrderAddItemShippingAddressAction) MarshalJSON ¶

func (obj OrderAddItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderAddParcelToDeliveryAction ¶

type OrderAddParcelToDeliveryAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey  *string             `json:"deliveryKey,omitempty"`
	ParcelKey    *string             `json:"parcelKey,omitempty"`
	Measurements *ParcelMeasurements `json:"measurements,omitempty"`
	TrackingData *TrackingData       `json:"trackingData,omitempty"`
	Items        []DeliveryItem      `json:"items"`
}

func (OrderAddParcelToDeliveryAction) MarshalJSON ¶

func (obj OrderAddParcelToDeliveryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderAddPaymentAction ¶

type OrderAddPaymentAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) of a [Payment](ctp:api:type:Payment).
	Payment PaymentResourceIdentifier `json:"payment"`
}

func (OrderAddPaymentAction) MarshalJSON ¶

func (obj OrderAddPaymentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderAddReturnInfoAction ¶

type OrderAddReturnInfoAction struct {
	ReturnTrackingId *string           `json:"returnTrackingId,omitempty"`
	Items            []ReturnItemDraft `json:"items"`
	ReturnDate       *time.Time        `json:"returnDate,omitempty"`
}

func (OrderAddReturnInfoAction) MarshalJSON ¶

func (obj OrderAddReturnInfoAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderBillingAddressSetMessage ¶

type OrderBillingAddressSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Billing address on the Order after the [Set Billing Address](ctp:api:type:OrderSetBillingAddressAction) update action.
	Address *Address `json:"address,omitempty"`
	// Billing address on the Order before the [Set Billing Address](ctp:api:type:OrderSetBillingAddressAction) update action.
	OldAddress *Address `json:"oldAddress,omitempty"`
}

* * Generated after a successful [Set Billing Address](ctp:api:type:OrderSetBillingAddressAction) update action. *

func (OrderBillingAddressSetMessage) MarshalJSON ¶

func (obj OrderBillingAddressSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderBillingAddressSetMessage) UnmarshalJSON ¶

func (obj *OrderBillingAddressSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderBillingAddressSetMessagePayload ¶

type OrderBillingAddressSetMessagePayload struct {
	// Billing address on the Order after the [Set Billing Address](ctp:api:type:OrderSetBillingAddressAction) update action.
	Address *Address `json:"address,omitempty"`
	// Billing address on the Order before the [Set Billing Address](ctp:api:type:OrderSetBillingAddressAction) update action.
	OldAddress *Address `json:"oldAddress,omitempty"`
}

* * Generated after a successful [Set Billing Address](ctp:api:type:OrderSetBillingAddressAction) update action. *

func (OrderBillingAddressSetMessagePayload) MarshalJSON ¶

func (obj OrderBillingAddressSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderChangeOrderStateAction ¶

type OrderChangeOrderStateAction struct {
	OrderState OrderState `json:"orderState"`
}

func (OrderChangeOrderStateAction) MarshalJSON ¶

func (obj OrderChangeOrderStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderChangePaymentStateAction ¶

type OrderChangePaymentStateAction struct {
	PaymentState *PaymentState `json:"paymentState,omitempty"`
}

func (OrderChangePaymentStateAction) MarshalJSON ¶

func (obj OrderChangePaymentStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderChangeShipmentStateAction ¶

type OrderChangeShipmentStateAction struct {
	ShipmentState *ShipmentState `json:"shipmentState,omitempty"`
}

func (OrderChangeShipmentStateAction) MarshalJSON ¶

func (obj OrderChangeShipmentStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderCreatedMessage ¶

type OrderCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Order](ctp:api:type:Order) that was created.
	Order Order `json:"order"`
}

* * Generated after a successful [Create Order](/../api/projects/orders#create-order) request. *

func (OrderCreatedMessage) MarshalJSON ¶

func (obj OrderCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderCreatedMessage) UnmarshalJSON ¶

func (obj *OrderCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderCreatedMessagePayload ¶

type OrderCreatedMessagePayload struct {
	// [Order](ctp:api:type:Order) that was created.
	Order Order `json:"order"`
}

* * Generated after a successful [Create Order](/../api/projects/orders#create-order) request. *

func (OrderCreatedMessagePayload) MarshalJSON ¶

func (obj OrderCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderCustomLineItemAddedMessage ¶

type OrderCustomLineItemAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Custom Line Item](ctp:api:type:CustomLineItem) that was added to the [Order](ctp:api:type:Order).
	CustomLineItem CustomLineItem `json:"customLineItem"`
}

* * Generated after a successful [Add Custom Line Item](ctp:api:type:StagedOrderAddCustomLineItemAction) update action. *

func (OrderCustomLineItemAddedMessage) MarshalJSON ¶

func (obj OrderCustomLineItemAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderCustomLineItemAddedMessage) UnmarshalJSON ¶

func (obj *OrderCustomLineItemAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderCustomLineItemAddedMessagePayload ¶

type OrderCustomLineItemAddedMessagePayload struct {
	// [Custom Line Item](ctp:api:type:CustomLineItem) that was added to the [Order](ctp:api:type:Order).
	CustomLineItem CustomLineItem `json:"customLineItem"`
}

* * Generated after a successful [Add Custom Line Item](ctp:api:type:StagedOrderAddCustomLineItemAction) update action. *

func (OrderCustomLineItemAddedMessagePayload) MarshalJSON ¶

func (obj OrderCustomLineItemAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderCustomLineItemDiscountSetMessage ¶

type OrderCustomLineItemDiscountSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier for the [Custom Line Item](ctp:api:type:CustomLineItem).
	CustomLineItemId string `json:"customLineItemId"`
	// Array of [DiscountedLineItemPriceForQuantity](ctp:api:type:DiscountedLineItemPriceForQuantity) after the Discount recalculation.
	DiscountedPricePerQuantity []DiscountedLineItemPriceForQuantity `json:"discountedPricePerQuantity"`
	// [TaxedItemPrice](ctp:api:type:TaxedItemPrice) of the [Custom Line Item](ctp:api:type:CustomLineItem) after the Discount recalculation.
	TaxedPrice *TaxedItemPrice `json:"taxedPrice,omitempty"`
}

* * Generated after a successful recalculation of a Discount on a [Custom Line Item](ctp:api:type:CustomLineItem). *

func (OrderCustomLineItemDiscountSetMessage) MarshalJSON ¶

func (obj OrderCustomLineItemDiscountSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderCustomLineItemDiscountSetMessage) UnmarshalJSON ¶

func (obj *OrderCustomLineItemDiscountSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderCustomLineItemDiscountSetMessagePayload ¶

type OrderCustomLineItemDiscountSetMessagePayload struct {
	// Unique identifier for the [Custom Line Item](ctp:api:type:CustomLineItem).
	CustomLineItemId string `json:"customLineItemId"`
	// Array of [DiscountedLineItemPriceForQuantity](ctp:api:type:DiscountedLineItemPriceForQuantity) after the Discount recalculation.
	DiscountedPricePerQuantity []DiscountedLineItemPriceForQuantity `json:"discountedPricePerQuantity"`
	// [TaxedItemPrice](ctp:api:type:TaxedItemPrice) of the [Custom Line Item](ctp:api:type:CustomLineItem) after the Discount recalculation.
	TaxedPrice *TaxedItemPrice `json:"taxedPrice,omitempty"`
}

* * Generated after a successful recalculation of a Discount on a [Custom Line Item](ctp:api:type:CustomLineItem). *

func (OrderCustomLineItemDiscountSetMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderCustomLineItemQuantityChangedMessage ¶

type OrderCustomLineItemQuantityChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Custom Line Item](ctp:api:type:CustomLineItem).
	CustomLineItemId string `json:"customLineItemId"`
	// [Custom Line Item](ctp:api:type:CustomLineItem) quantity after the [Change Custom Line Item Quantity](ctp:api:type:StagedOrderChangeCustomLineItemQuantityAction) update action.
	Quantity int `json:"quantity"`
	// [Custom Line Item](ctp:api:type:CustomLineItem) quantity before the [Change Custom Line Item Quantity](ctp:api:type:StagedOrderChangeCustomLineItemQuantityAction) update action.
	OldQuantity int `json:"oldQuantity"`
}

* * Generated after a successful [Change Custom Line Item Quantity](ctp:api:type:StagedOrderChangeCustomLineItemQuantityAction) update action. *

func (OrderCustomLineItemQuantityChangedMessage) MarshalJSON ¶

func (obj OrderCustomLineItemQuantityChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderCustomLineItemQuantityChangedMessage) UnmarshalJSON ¶

func (obj *OrderCustomLineItemQuantityChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderCustomLineItemQuantityChangedMessagePayload ¶

type OrderCustomLineItemQuantityChangedMessagePayload struct {
	// Unique identifier of the [Custom Line Item](ctp:api:type:CustomLineItem).
	CustomLineItemId string `json:"customLineItemId"`
	// [Custom Line Item](ctp:api:type:CustomLineItem) quantity after the [Change Custom Line Item Quantity](ctp:api:type:StagedOrderChangeCustomLineItemQuantityAction) update action.
	Quantity int `json:"quantity"`
	// [Custom Line Item](ctp:api:type:CustomLineItem) quantity before the [Change Custom Line Item Quantity](ctp:api:type:StagedOrderChangeCustomLineItemQuantityAction) update action.
	OldQuantity int `json:"oldQuantity"`
}

* * Generated after a successful [Change Custom Line Item Quantity](ctp:api:type:StagedOrderChangeCustomLineItemQuantityAction) update action. *

func (OrderCustomLineItemQuantityChangedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderCustomLineItemRemovedMessage ¶

type OrderCustomLineItemRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Custom Line Item](ctp:api:type:CustomLineItem).
	CustomLineItemId string `json:"customLineItemId"`
	// [Custom Line Item](ctp:api:type:CustomLineItem) that was removed from the [Order](ctp:api:type:Order).
	CustomLineItem CustomLineItem `json:"customLineItem"`
}

* * Generated after a successful [Remove Custom Line Item](ctp:api:type:StagedOrderRemoveCustomLineItemAction) update action. *

func (OrderCustomLineItemRemovedMessage) MarshalJSON ¶

func (obj OrderCustomLineItemRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderCustomLineItemRemovedMessage) UnmarshalJSON ¶

func (obj *OrderCustomLineItemRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderCustomLineItemRemovedMessagePayload ¶

type OrderCustomLineItemRemovedMessagePayload struct {
	// Unique identifier of the [Custom Line Item](ctp:api:type:CustomLineItem).
	CustomLineItemId string `json:"customLineItemId"`
	// [Custom Line Item](ctp:api:type:CustomLineItem) that was removed from the [Order](ctp:api:type:Order).
	CustomLineItem CustomLineItem `json:"customLineItem"`
}

* * Generated after a successful [Remove Custom Line Item](ctp:api:type:StagedOrderRemoveCustomLineItemAction) update action. *

func (OrderCustomLineItemRemovedMessagePayload) MarshalJSON ¶

func (obj OrderCustomLineItemRemovedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderCustomerEmailSetMessage ¶

type OrderCustomerEmailSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Email address on the [Order](ctp:api:type:Order) after the [Set Customer Email](ctp:api:type:OrderSetCustomerEmailAction) update action.
	Email *string `json:"email,omitempty"`
	// Email address on the [Order](ctp:api:type:Order) before the [Set Customer Email](ctp:api:type:OrderSetCustomerEmailAction) update action.
	OldEmail *string `json:"oldEmail,omitempty"`
}

* * Generated after a successful [Set Customer Email](ctp:api:type:OrderSetCustomerEmailAction) update action. *

func (OrderCustomerEmailSetMessage) MarshalJSON ¶

func (obj OrderCustomerEmailSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderCustomerEmailSetMessage) UnmarshalJSON ¶

func (obj *OrderCustomerEmailSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderCustomerEmailSetMessagePayload ¶

type OrderCustomerEmailSetMessagePayload struct {
	// Email address on the [Order](ctp:api:type:Order) after the [Set Customer Email](ctp:api:type:OrderSetCustomerEmailAction) update action.
	Email *string `json:"email,omitempty"`
	// Email address on the [Order](ctp:api:type:Order) before the [Set Customer Email](ctp:api:type:OrderSetCustomerEmailAction) update action.
	OldEmail *string `json:"oldEmail,omitempty"`
}

* * Generated after a successful [Set Customer Email](ctp:api:type:OrderSetCustomerEmailAction) update action. *

func (OrderCustomerEmailSetMessagePayload) MarshalJSON ¶

func (obj OrderCustomerEmailSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderCustomerGroupSetMessage ¶

type OrderCustomerGroupSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) on the [Order](ctp:api:type:Order) after the [Set Customer Group](ctp:api:type:StagedOrderSetCustomerGroupAction) update action.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) on the [Order](ctp:api:type:Order) before the [Set Customer Group](ctp:api:type:StagedOrderSetCustomerGroupAction) update action.
	OldCustomerGroup *CustomerGroupReference `json:"oldCustomerGroup,omitempty"`
}

* * Generated after a successful [Set Customer Group](ctp:api:type:StagedOrderSetCustomerGroupAction) update action. *

func (OrderCustomerGroupSetMessage) MarshalJSON ¶

func (obj OrderCustomerGroupSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderCustomerGroupSetMessage) UnmarshalJSON ¶

func (obj *OrderCustomerGroupSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderCustomerGroupSetMessagePayload ¶

type OrderCustomerGroupSetMessagePayload struct {
	// [CustomerGroup](ctp:api:type:CustomerGroup) on the [Order](ctp:api:type:Order) after the [Set Customer Group](ctp:api:type:StagedOrderSetCustomerGroupAction) update action.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) on the [Order](ctp:api:type:Order) before the [Set Customer Group](ctp:api:type:StagedOrderSetCustomerGroupAction) update action.
	OldCustomerGroup *CustomerGroupReference `json:"oldCustomerGroup,omitempty"`
}

* * Generated after a successful [Set Customer Group](ctp:api:type:StagedOrderSetCustomerGroupAction) update action. *

func (OrderCustomerGroupSetMessagePayload) MarshalJSON ¶

func (obj OrderCustomerGroupSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderCustomerSetMessage ¶

type OrderCustomerSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Customer](ctp:api:type:Customer) on the [Order](ctp:api:type:Order) after the [Set Customer Id](ctp:api:type:OrderSetCustomerIdAction) update action.
	Customer *CustomerReference `json:"customer,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) on the [Order](ctp:api:type:Order) after the [Set Customer Id](ctp:api:type:OrderSetCustomerIdAction) update action.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// [Customer](ctp:api:type:Customer) on the [Order](ctp:api:type:Order) before the [Set Customer Id](ctp:api:type:OrderSetCustomerIdAction) update action.
	OldCustomer *CustomerReference `json:"oldCustomer,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) on the [Order](ctp:api:type:Order) before the [Set Customer Id](ctp:api:type:OrderSetCustomerIdAction) update action.
	OldCustomerGroup *CustomerGroupReference `json:"oldCustomerGroup,omitempty"`
}

* * Generated after a successful [Set Customer Id](ctp:api:type:OrderSetCustomerIdAction) update action. *

func (OrderCustomerSetMessage) MarshalJSON ¶

func (obj OrderCustomerSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderCustomerSetMessage) UnmarshalJSON ¶

func (obj *OrderCustomerSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderCustomerSetMessagePayload ¶

type OrderCustomerSetMessagePayload struct {
	// [Customer](ctp:api:type:Customer) on the [Order](ctp:api:type:Order) after the [Set Customer Id](ctp:api:type:OrderSetCustomerIdAction) update action.
	Customer *CustomerReference `json:"customer,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) on the [Order](ctp:api:type:Order) after the [Set Customer Id](ctp:api:type:OrderSetCustomerIdAction) update action.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// [Customer](ctp:api:type:Customer) on the [Order](ctp:api:type:Order) before the [Set Customer Id](ctp:api:type:OrderSetCustomerIdAction) update action.
	OldCustomer *CustomerReference `json:"oldCustomer,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) on the [Order](ctp:api:type:Order) before the [Set Customer Id](ctp:api:type:OrderSetCustomerIdAction) update action.
	OldCustomerGroup *CustomerGroupReference `json:"oldCustomerGroup,omitempty"`
}

* * Generated after a successful [Set Customer Id](ctp:api:type:OrderSetCustomerIdAction) update action. *

func (OrderCustomerSetMessagePayload) MarshalJSON ¶

func (obj OrderCustomerSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderDeletedMessage ¶

type OrderDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Order](ctp:api:type:Order) that has been deleted.
	Order Order `json:"order"`
}

* * Generated after a successful [Delete Order](/../api/projects/orders#delete-order) request. *

func (OrderDeletedMessage) MarshalJSON ¶

func (obj OrderDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderDeletedMessage) UnmarshalJSON ¶

func (obj *OrderDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderDeletedMessagePayload ¶

type OrderDeletedMessagePayload struct {
	// [Order](ctp:api:type:Order) that has been deleted.
	Order Order `json:"order"`
}

* * Generated after a successful [Delete Order](/../api/projects/orders#delete-order) request. *

func (OrderDeletedMessagePayload) MarshalJSON ¶

func (obj OrderDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderDiscountCodeAddedMessage ¶

type OrderDiscountCodeAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [DiscountCode](ctp:api:type:DiscountCode) that was added.
	DiscountCode DiscountCodeReference `json:"discountCode"`
}

* * Generated after a successful [Add Discount Code](ctp:api:type:StagedOrderAddDiscountCodeAction) update action. *

func (OrderDiscountCodeAddedMessage) MarshalJSON ¶

func (obj OrderDiscountCodeAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderDiscountCodeAddedMessage) UnmarshalJSON ¶

func (obj *OrderDiscountCodeAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderDiscountCodeAddedMessagePayload ¶

type OrderDiscountCodeAddedMessagePayload struct {
	// [DiscountCode](ctp:api:type:DiscountCode) that was added.
	DiscountCode DiscountCodeReference `json:"discountCode"`
}

* * Generated after a successful [Add Discount Code](ctp:api:type:StagedOrderAddDiscountCodeAction) update action. *

func (OrderDiscountCodeAddedMessagePayload) MarshalJSON ¶

func (obj OrderDiscountCodeAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderDiscountCodeRemovedMessage ¶

type OrderDiscountCodeRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [DiscountCode](ctp:api:type:DiscountCode) that was removed.
	DiscountCode DiscountCodeReference `json:"discountCode"`
}

* * Generated after a successful [Remove Discount Code](ctp:api:type:StagedOrderRemoveDiscountCodeAction) update action. *

func (OrderDiscountCodeRemovedMessage) MarshalJSON ¶

func (obj OrderDiscountCodeRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderDiscountCodeRemovedMessage) UnmarshalJSON ¶

func (obj *OrderDiscountCodeRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderDiscountCodeRemovedMessagePayload ¶

type OrderDiscountCodeRemovedMessagePayload struct {
	// [DiscountCode](ctp:api:type:DiscountCode) that was removed.
	DiscountCode DiscountCodeReference `json:"discountCode"`
}

* * Generated after a successful [Remove Discount Code](ctp:api:type:StagedOrderRemoveDiscountCodeAction) update action. *

func (OrderDiscountCodeRemovedMessagePayload) MarshalJSON ¶

func (obj OrderDiscountCodeRemovedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderDiscountCodeStateSetMessage ¶

type OrderDiscountCodeStateSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [DiscountCode](ctp:api:type:DiscountCode) that changed due to the recalculation.
	DiscountCode DiscountCodeReference `json:"discountCode"`
	// [DiscountCodeState](ctp:api:type:DiscountCodeState) after the recalculation.
	State DiscountCodeState `json:"state"`
	// [DiscountCodeState](ctp:api:type:DiscountCodeState) before the recalculation.
	OldState *DiscountCodeState `json:"oldState,omitempty"`
}

* * Generated after the DiscountCodeState(ctp:api:type:DiscountCodeState) changes due to a [recalculation](/../api/projects/carts#recalculate). *

func (OrderDiscountCodeStateSetMessage) MarshalJSON ¶

func (obj OrderDiscountCodeStateSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderDiscountCodeStateSetMessage) UnmarshalJSON ¶

func (obj *OrderDiscountCodeStateSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderDiscountCodeStateSetMessagePayload ¶

type OrderDiscountCodeStateSetMessagePayload struct {
	// [DiscountCode](ctp:api:type:DiscountCode) that changed due to the recalculation.
	DiscountCode DiscountCodeReference `json:"discountCode"`
	// [DiscountCodeState](ctp:api:type:DiscountCodeState) after the recalculation.
	State DiscountCodeState `json:"state"`
	// [DiscountCodeState](ctp:api:type:DiscountCodeState) before the recalculation.
	OldState *DiscountCodeState `json:"oldState,omitempty"`
}

* * Generated after the DiscountCodeState(ctp:api:type:DiscountCodeState) changes due to a [recalculation](/../api/projects/carts#recalculate). *

func (OrderDiscountCodeStateSetMessagePayload) MarshalJSON ¶

func (obj OrderDiscountCodeStateSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderEdit ¶

type OrderEdit struct {
	// Unique identifier of the OrderEdit.
	ID string `json:"id"`
	// The current version of the OrderEdit.
	Version        int       `json:"version"`
	CreatedAt      time.Time `json:"createdAt"`
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the OrderEdit.
	Key *string `json:"key,omitempty"`
	// The order to be updated with this edit.
	Resource OrderReference `json:"resource"`
	// The actions to apply to the Order.
	// Cannot be updated after the edit has been applied.
	StagedActions []StagedOrderUpdateAction `json:"stagedActions"`
	Custom        *CustomFields             `json:"custom,omitempty"`
	// Contains a preview of the changes in case of unapplied edit.
	// For applied edits, it contains the summary of the changes.
	Result OrderEditResult `json:"result"`
	// This field can be used to add textual information regarding the edit.
	Comment *string `json:"comment,omitempty"`
}

func (*OrderEdit) UnmarshalJSON ¶

func (obj *OrderEdit) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderEditAddStagedActionAction ¶

type OrderEditAddStagedActionAction struct {
	StagedAction StagedOrderUpdateAction `json:"stagedAction"`
}

func (OrderEditAddStagedActionAction) MarshalJSON ¶

func (obj OrderEditAddStagedActionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderEditAddStagedActionAction) UnmarshalJSON ¶

func (obj *OrderEditAddStagedActionAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderEditApplied ¶

type OrderEditApplied struct {
	AppliedAt         time.Time    `json:"appliedAt"`
	ExcerptBeforeEdit OrderExcerpt `json:"excerptBeforeEdit"`
	ExcerptAfterEdit  OrderExcerpt `json:"excerptAfterEdit"`
}

func (OrderEditApplied) MarshalJSON ¶

func (obj OrderEditApplied) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderEditAppliedMessage ¶

type OrderEditAppliedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [OrderEdit](ctp:api:type:OrderEdit) that was applied.
	Edit OrderEdit `json:"edit"`
	// Information about a successfully applied [OrderEdit](ctp:api:type:OrderEdit).
	Result OrderEditApplied `json:"result"`
}

* * Generated after a successfully applying an OrderEdit(/../api/projects/order-edits#apply-an-orderedit). *

func (OrderEditAppliedMessage) MarshalJSON ¶

func (obj OrderEditAppliedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderEditAppliedMessage) UnmarshalJSON ¶

func (obj *OrderEditAppliedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderEditAppliedMessagePayload ¶

type OrderEditAppliedMessagePayload struct {
	// [OrderEdit](ctp:api:type:OrderEdit) that was applied.
	Edit OrderEdit `json:"edit"`
	// Information about a successfully applied [OrderEdit](ctp:api:type:OrderEdit).
	Result OrderEditApplied `json:"result"`
}

* * Generated after a successfully applying an OrderEdit(/../api/projects/order-edits#apply-an-orderedit). *

func (OrderEditAppliedMessagePayload) MarshalJSON ¶

func (obj OrderEditAppliedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderEditApply ¶

type OrderEditApply struct {
	EditVersion     int `json:"editVersion"`
	ResourceVersion int `json:"resourceVersion"`
}

type OrderEditDraft ¶

type OrderEditDraft struct {
	// User-defined unique identifier for the OrderEdit.
	Key *string `json:"key,omitempty"`
	// The order to be updated with this edit.
	Resource OrderReference `json:"resource"`
	// The actions to apply to `resource`.
	StagedActions []StagedOrderUpdateAction `json:"stagedActions"`
	// The custom fields.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// This field can be used to add additional textual information regarding the edit.
	Comment *string `json:"comment,omitempty"`
	// When set to `true` the edit is applied on the Order without persisting it.
	DryRun *bool `json:"dryRun,omitempty"`
}

func (OrderEditDraft) MarshalJSON ¶

func (obj OrderEditDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderEditDraft) UnmarshalJSON ¶

func (obj *OrderEditDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderEditNotProcessed ¶

type OrderEditNotProcessed struct {
}

func (OrderEditNotProcessed) MarshalJSON ¶

func (obj OrderEditNotProcessed) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderEditPagedQueryResponse ¶

type OrderEditPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int  `json:"limit"`
	Count int  `json:"count"`
	Total *int `json:"total,omitempty"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset  int         `json:"offset"`
	Results []OrderEdit `json:"results"`
}

type OrderEditPreviewFailure ¶

type OrderEditPreviewFailure struct {
	Errors []ErrorObject `json:"errors"`
}

func (OrderEditPreviewFailure) MarshalJSON ¶

func (obj OrderEditPreviewFailure) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderEditPreviewFailure) UnmarshalJSON ¶

func (obj *OrderEditPreviewFailure) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderEditPreviewSuccess ¶

type OrderEditPreviewSuccess struct {
	Preview         StagedOrder      `json:"preview"`
	MessagePayloads []MessagePayload `json:"messagePayloads"`
}

func (OrderEditPreviewSuccess) MarshalJSON ¶

func (obj OrderEditPreviewSuccess) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderEditPreviewSuccess) UnmarshalJSON ¶

func (obj *OrderEditPreviewSuccess) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderEditReference ¶

type OrderEditReference struct {
	// Unique identifier of the referenced [OrderEdit](ctp:api:type:OrderEdit).
	ID string `json:"id"`
	// Contains the representation of the expanded OrderEdit. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for OrderEdits.
	Obj *OrderEdit `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to an OrderEdit(ctp:api:type:OrderEdit). *

func (OrderEditReference) MarshalJSON ¶

func (obj OrderEditReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderEditResourceIdentifier ¶

type OrderEditResourceIdentifier struct {
	// Unique identifier of the referenced [OrderEdit](ctp:api:type:OrderEdit). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [OrderEdit](ctp:api:type:OrderEdit). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to an OrderEdit(ctp:api:type:OrderEdit). *

func (OrderEditResourceIdentifier) MarshalJSON ¶

func (obj OrderEditResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderEditResult ¶

type OrderEditResult interface{}

type OrderEditSetCommentAction ¶

type OrderEditSetCommentAction struct {
	Comment *string `json:"comment,omitempty"`
}

func (OrderEditSetCommentAction) MarshalJSON ¶

func (obj OrderEditSetCommentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderEditSetCustomFieldAction ¶

type OrderEditSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (OrderEditSetCustomFieldAction) MarshalJSON ¶

func (obj OrderEditSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderEditSetCustomTypeAction ¶

type OrderEditSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the OrderEdit with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the OrderEdit.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the OrderEdit.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (OrderEditSetCustomTypeAction) MarshalJSON ¶

func (obj OrderEditSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderEditSetKeyAction ¶

type OrderEditSetKeyAction struct {
	// If `key` is absent or `null`, this field will be removed if it exists.
	Key *string `json:"key,omitempty"`
}

func (OrderEditSetKeyAction) MarshalJSON ¶

func (obj OrderEditSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderEditSetStagedActionsAction ¶

type OrderEditSetStagedActionsAction struct {
	// The actions to edit the `resource`.
	StagedActions []StagedOrderUpdateAction `json:"stagedActions"`
}

func (OrderEditSetStagedActionsAction) MarshalJSON ¶

func (obj OrderEditSetStagedActionsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderEditSetStagedActionsAction) UnmarshalJSON ¶

func (obj *OrderEditSetStagedActionsAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderEditUpdate ¶

type OrderEditUpdate struct {
	Version int                     `json:"version"`
	Actions []OrderEditUpdateAction `json:"actions"`
	DryRun  *bool                   `json:"dryRun,omitempty"`
}

func (*OrderEditUpdate) UnmarshalJSON ¶

func (obj *OrderEditUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderEditUpdateAction ¶

type OrderEditUpdateAction interface{}

type OrderExcerpt ¶

type OrderExcerpt struct {
	TotalPrice TypedMoney  `json:"totalPrice"`
	TaxedPrice *TaxedPrice `json:"taxedPrice,omitempty"`
	Version    int         `json:"version"`
}

func (*OrderExcerpt) UnmarshalJSON ¶

func (obj *OrderExcerpt) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderFromCartDraft ¶

type OrderFromCartDraft struct {
	// Unique identifier of the Cart from which you can create an Order.
	ID *string `json:"id,omitempty"`
	// ResourceIdentifier of the Cart from which the Order is created.
	Cart *CartResourceIdentifier `json:"cart,omitempty"`
	// Expected version of the Cart from which the Order is created.
	// If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// String that uniquely identifies an order.
	// It can be used to create more human-readable (in contrast to ID) identifier for the order.
	// It should be unique across a project.
	// Once it's set it cannot be changed.
	// For easier use on Get, Update and Delete actions we suggest assigning order numbers that match the regular expression `[a-z0-9_\-]{2,36}`.
	OrderNumber *string `json:"orderNumber,omitempty"`
	// Identifier for a purchase order, usually in a B2B context.
	// The Purchase Order Number is typically entered by the [Buyer](/quotes-overview#buyer) and can also be used with [Quotes](/quotes-overview).
	PurchaseOrderNumber *string `json:"purchaseOrderNumber,omitempty"`
	// Payment state for the Order.
	PaymentState *PaymentState `json:"paymentState,omitempty"`
	// Shipment state for the Order.
	ShipmentState *ShipmentState `json:"shipmentState,omitempty"`
	// Order will be created with `Open` status by default.
	OrderState *OrderState `json:"orderState,omitempty"`
	// [Reference](ctp:api:type:Reference) to a [State](ctp:api:type:State) indicating the Order's state.
	State *StateResourceIdentifier `json:"state,omitempty"`
	// [Custom Fields](/../api/projects/custom-fields) for the Order. The Custom Field type must match the type of the Custom Fields in the referenced [Cart](/../api/projects/carts#cart).
	// If specified, the Custom Fields are merged with the Custom Fields on the referenced [Cart](/../api/projects/carts#cart) and added to the Order.
	// If empty, the Custom Fields on the referenced [Cart](/../api/projects/carts#cart) are added to the Order automatically.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

type OrderFromQuoteDraft ¶

type OrderFromQuoteDraft struct {
	// ResourceIdentifier of the Quote from which this Order is created. If the Quote has `QuoteState` in `Accepted`, `Declined` or `Withdrawn` then the order creation will fail. The creation will also fail if the `Quote` has expired (`validTo` check).
	Quote QuoteResourceIdentifier `json:"quote"`
	// `version` of the [Quote](ctp:api:type:Quote) from which an Order is created.
	Version int `json:"version"`
	// If `true`, the `quoteState` of the referenced [Quote](ctp:api:type:Quote) will be set to `Accepted`.
	QuoteStateToAccepted *bool `json:"quoteStateToAccepted,omitempty"`
	// String that uniquely identifies an order.
	// It can be used to create more human-readable (in contrast to ID) identifier for the order.
	// It should be unique across a project.
	// Once it's set it cannot be changed.
	// For easier use on Get, Update and Delete actions we suggest assigning order numbers that match the regular expression `[a-z0-9_\-]{2,36}`.
	OrderNumber *string `json:"orderNumber,omitempty"`
	// Payment state of the Order.
	PaymentState *PaymentState `json:"paymentState,omitempty"`
	// Shipment state of the Order.
	ShipmentState *ShipmentState `json:"shipmentState,omitempty"`
	// Order will be created with `Open` status by default.
	OrderState *OrderState `json:"orderState,omitempty"`
	// [Reference](ctp:api:type:Reference) to a [State](ctp:api:type:State) indicating the Order's state.
	State *StateResourceIdentifier `json:"state,omitempty"`
}

type OrderImportCustomLineItemStateAction ¶

type OrderImportCustomLineItemStateAction struct {
	CustomLineItemId string      `json:"customLineItemId"`
	State            []ItemState `json:"state"`
}

func (OrderImportCustomLineItemStateAction) MarshalJSON ¶

func (obj OrderImportCustomLineItemStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderImportDraft ¶

type OrderImportDraft struct {
	// String that unique identifies an order.
	// It can be used to create more human-readable (in contrast to ID) identifier for the order.
	// It should be unique within a project.
	OrderNumber *string `json:"orderNumber,omitempty"`
	// If given the customer with that ID must exist in the project.
	CustomerId *string `json:"customerId,omitempty"`
	// The customer email can be used when no check against existing Customers is desired during order import.
	CustomerEmail *string `json:"customerEmail,omitempty"`
	// If not given `customLineItems` must not be empty.
	LineItems []LineItemImportDraft `json:"lineItems"`
	// If not given `lineItems` must not be empty.
	CustomLineItems []CustomLineItemImportDraft `json:"customLineItems"`
	TotalPrice      Money                       `json:"totalPrice"`
	// Order Import does not support calculation of taxes.
	// When setting the draft the taxedPrice is to be provided.
	TaxedPrice      *TaxedPriceDraft `json:"taxedPrice,omitempty"`
	ShippingAddress *BaseAddress     `json:"shippingAddress,omitempty"`
	BillingAddress  *BaseAddress     `json:"billingAddress,omitempty"`
	// Set when the customer is set and the customer is a member of a customer group.
	// Used for product variant price selection.
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
	// A two-digit country code as per [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).
	// Used for product variant price selection.
	Country *string `json:"country,omitempty"`
	// If not given the `Open` state will be assigned by default.
	OrderState *OrderState `json:"orderState,omitempty"`
	// This reference can point to a state in a custom workflow.
	State         *StateReference `json:"state,omitempty"`
	ShipmentState *ShipmentState  `json:"shipmentState,omitempty"`
	PaymentState  *PaymentState   `json:"paymentState,omitempty"`
	// Set if the ShippingMethod is set.
	ShippingInfo *ShippingInfoImportDraft `json:"shippingInfo,omitempty"`
	PaymentInfo  *PaymentInfo             `json:"paymentInfo,omitempty"`
	CompletedAt  *time.Time               `json:"completedAt,omitempty"`
	// The custom fields.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// If not given the mode `None` will be assigned by default.
	InventoryMode *InventoryMode `json:"inventoryMode,omitempty"`
	// If not given the tax rounding mode `HalfEven` will be assigned by default.
	TaxRoundingMode *RoundingMode `json:"taxRoundingMode,omitempty"`
	// Contains addresses for orders with multiple shipping addresses.
	ItemShippingAddresses []BaseAddress `json:"itemShippingAddresses"`
	// The Business Unit the Cart belongs to.
	BusinessUnit *BusinessUnitResourceIdentifier `json:"businessUnit,omitempty"`
	Store        *StoreResourceIdentifier        `json:"store,omitempty"`
	// The default origin is `Customer`.
	Origin *CartOrigin `json:"origin,omitempty"`
}

func (OrderImportDraft) MarshalJSON ¶

func (obj OrderImportDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderImportLineItemStateAction ¶

type OrderImportLineItemStateAction struct {
	LineItemId string      `json:"lineItemId"`
	State      []ItemState `json:"state"`
}

func (OrderImportLineItemStateAction) MarshalJSON ¶

func (obj OrderImportLineItemStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderImportedMessage ¶

type OrderImportedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Order](ctp:api:type:Order) that was imported.
	Order Order `json:"order"`
}

* * Generated after a successful [Order Import](/../api/projects/orders-import#create-an-order-by-import). *

func (OrderImportedMessage) MarshalJSON ¶

func (obj OrderImportedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderImportedMessage) UnmarshalJSON ¶

func (obj *OrderImportedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderImportedMessagePayload ¶

type OrderImportedMessagePayload struct {
	// [Order](ctp:api:type:Order) that was imported.
	Order Order `json:"order"`
}

* * Generated after a successful [Order Import](/../api/projects/orders-import#create-an-order-by-import). *

func (OrderImportedMessagePayload) MarshalJSON ¶

func (obj OrderImportedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderLineItemAddedMessage ¶

type OrderLineItemAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Line Item](ctp:api:type:LineItem) that was added to the [Order](ctp:api:type:Order).
	LineItem LineItem `json:"lineItem"`
	// Quantity of [Line Items](ctp:api:type:LineItem) that were added to the [Order](ctp:api:type:Order).
	AddedQuantity int `json:"addedQuantity"`
}

* * Generated after a successful [Add Line Item](ctp:api:type:StagedOrderAddLineItemAction) update action. *

func (OrderLineItemAddedMessage) MarshalJSON ¶

func (obj OrderLineItemAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderLineItemAddedMessage) UnmarshalJSON ¶

func (obj *OrderLineItemAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderLineItemAddedMessagePayload ¶

type OrderLineItemAddedMessagePayload struct {
	// [Line Item](ctp:api:type:LineItem) that was added to the [Order](ctp:api:type:Order).
	LineItem LineItem `json:"lineItem"`
	// Quantity of [Line Items](ctp:api:type:LineItem) that were added to the [Order](ctp:api:type:Order).
	AddedQuantity int `json:"addedQuantity"`
}

* * Generated after a successful [Add Line Item](ctp:api:type:StagedOrderAddLineItemAction) update action. *

func (OrderLineItemAddedMessagePayload) MarshalJSON ¶

func (obj OrderLineItemAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderLineItemDiscountSetMessage ¶

type OrderLineItemDiscountSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier for the [Line Item](ctp:api:type:LineItem).
	LineItemId string `json:"lineItemId"`
	// Array of [DiscountedLineItemPriceForQuantity](ctp:api:type:DiscountedLineItemPriceForQuantity) after the Discount recalculation.
	DiscountedPricePerQuantity []DiscountedLineItemPriceForQuantity `json:"discountedPricePerQuantity"`
	// Total Price of the [Line Item](ctp:api:type:LineItem) after the Discount recalculation.
	TotalPrice Money `json:"totalPrice"`
	// [TaxedItemPrice](ctp:api:type:TaxedItemPrice) of the [Line Item](ctp:api:type:LineItem) after the Discount recalculation.
	TaxedPrice *TaxedItemPrice `json:"taxedPrice,omitempty"`
	// Taxed price of the Shipping Methods in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	TaxedPricePortions []MethodTaxedPrice `json:"taxedPricePortions"`
}

* * Generated after a successful recalculation of a Discount on a [Line Item](ctp:api:type:LineItem). *

func (OrderLineItemDiscountSetMessage) MarshalJSON ¶

func (obj OrderLineItemDiscountSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderLineItemDiscountSetMessage) UnmarshalJSON ¶

func (obj *OrderLineItemDiscountSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderLineItemDiscountSetMessagePayload ¶

type OrderLineItemDiscountSetMessagePayload struct {
	// Unique identifier for the [Line Item](ctp:api:type:LineItem).
	LineItemId string `json:"lineItemId"`
	// Array of [DiscountedLineItemPriceForQuantity](ctp:api:type:DiscountedLineItemPriceForQuantity) after the Discount recalculation.
	DiscountedPricePerQuantity []DiscountedLineItemPriceForQuantity `json:"discountedPricePerQuantity"`
	// Total Price of the [Line Item](ctp:api:type:LineItem) after the Discount recalculation.
	TotalPrice Money `json:"totalPrice"`
	// [TaxedItemPrice](ctp:api:type:TaxedItemPrice) of the [Line Item](ctp:api:type:LineItem) after the Discount recalculation.
	TaxedPrice *TaxedItemPrice `json:"taxedPrice,omitempty"`
	// Taxed price of the Shipping Methods in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	TaxedPricePortions []MethodTaxedPrice `json:"taxedPricePortions"`
}

* * Generated after a successful recalculation of a Discount on a [Line Item](ctp:api:type:LineItem). *

func (OrderLineItemDiscountSetMessagePayload) MarshalJSON ¶

func (obj OrderLineItemDiscountSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderLineItemDistributionChannelSetMessage ¶

type OrderLineItemDistributionChannelSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Line Item](ctp:api:type:LineItem).
	LineItemId string `json:"lineItemId"`
	// [Distribution Channel](ctp:api:type:Channel) that was set.
	DistributionChannel *ChannelReference `json:"distributionChannel,omitempty"`
}

* * Generated after a successful [Set Line Item Distribution Channel](/../api/projects/order-edits#set-lineitem-distributionchannel) update action. *

func (OrderLineItemDistributionChannelSetMessage) MarshalJSON ¶

func (obj OrderLineItemDistributionChannelSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderLineItemDistributionChannelSetMessage) UnmarshalJSON ¶

func (obj *OrderLineItemDistributionChannelSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderLineItemDistributionChannelSetMessagePayload ¶

type OrderLineItemDistributionChannelSetMessagePayload struct {
	// Unique identifier of the [Line Item](ctp:api:type:LineItem).
	LineItemId string `json:"lineItemId"`
	// [Distribution Channel](ctp:api:type:Channel) that was set.
	DistributionChannel *ChannelReference `json:"distributionChannel,omitempty"`
}

* * Generated after a successful [Set Line Item Distribution Channel](/../api/projects/order-edits#set-lineitem-distributionchannel) update action. *

func (OrderLineItemDistributionChannelSetMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderLineItemRemovedMessage ¶

type OrderLineItemRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Line Item](ctp:api:type:LineItem).
	LineItemId string `json:"lineItemId"`
	// Quantity of [Line Items](ctp:api:type:LineItem) that were removed during the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	RemovedQuantity int `json:"removedQuantity"`
	// [Line Item](ctp:api:type:LineItem) quantity after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewQuantity int `json:"newQuantity"`
	// [ItemStates](ctp:api:type:ItemState) after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewState []ItemState `json:"newState"`
	// `totalPrice` of the [Order](ctp:api:type:Order) after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewTotalPrice CentPrecisionMoney `json:"newTotalPrice"`
	// [TaxedItemPrice](ctp:api:type:TaxedItemPrice) of the [Order](ctp:api:type:Order) after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewTaxedPrice *TaxedItemPrice `json:"newTaxedPrice,omitempty"`
	// [Price](ctp:api:type:Price) of the [Order](ctp:api:type:Order) after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewPrice *Price `json:"newPrice,omitempty"`
	// [Shipping Details](ctp:api:type:ItemShippingDetails) of the [Order](ctp:api:type:Order) after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewShippingDetail *ItemShippingDetails `json:"newShippingDetail,omitempty"`
}

* * Generated after a successful [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action. *

func (OrderLineItemRemovedMessage) MarshalJSON ¶

func (obj OrderLineItemRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderLineItemRemovedMessage) UnmarshalJSON ¶

func (obj *OrderLineItemRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderLineItemRemovedMessagePayload ¶

type OrderLineItemRemovedMessagePayload struct {
	// Unique identifier of the [Line Item](ctp:api:type:LineItem).
	LineItemId string `json:"lineItemId"`
	// Quantity of [Line Items](ctp:api:type:LineItem) that were removed during the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	RemovedQuantity int `json:"removedQuantity"`
	// [Line Item](ctp:api:type:LineItem) quantity after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewQuantity int `json:"newQuantity"`
	// [ItemStates](ctp:api:type:ItemState) after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewState []ItemState `json:"newState"`
	// `totalPrice` of the [Order](ctp:api:type:Order) after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewTotalPrice CentPrecisionMoney `json:"newTotalPrice"`
	// [TaxedItemPrice](ctp:api:type:TaxedItemPrice) of the [Order](ctp:api:type:Order) after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewTaxedPrice *TaxedItemPrice `json:"newTaxedPrice,omitempty"`
	// [Price](ctp:api:type:Price) of the [Order](ctp:api:type:Order) after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewPrice *Price `json:"newPrice,omitempty"`
	// [Shipping Details](ctp:api:type:ItemShippingDetails) of the [Order](ctp:api:type:Order) after the [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action.
	NewShippingDetail *ItemShippingDetails `json:"newShippingDetail,omitempty"`
}

* * Generated after a successful [Remove Line Item](ctp:api:type:StagedOrderRemoveLineItemAction) update action. *

func (OrderLineItemRemovedMessagePayload) MarshalJSON ¶

func (obj OrderLineItemRemovedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderMessage ¶

type OrderMessage interface{}

type OrderMessagePayload ¶

type OrderMessagePayload interface{}

type OrderPagedQueryResponse ¶

type OrderPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int  `json:"limit"`
	Count int  `json:"count"`
	Total *int `json:"total,omitempty"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset  int     `json:"offset"`
	Results []Order `json:"results"`
}

type OrderPagedSearchResponse ¶

type OrderPagedSearchResponse struct {
	// Total number of results matching the query.
	Total int `json:"total"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset *int `json:"offset,omitempty"`
	// Number of [results requested](/../api/general-concepts#limit).
	Limit *int `json:"limit,omitempty"`
	// Actual results.
	Hits []Hit `json:"hits"`
}

type OrderPaymentAddedMessage ¶

type OrderPaymentAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Payment](ctp:api:type:Payment) that was added to the [Order](ctp:api:type:Order).
	Payment PaymentReference `json:"payment"`
}

* * Generated after a successful [Add Payment](ctp:api:type:OrderAddPaymentAction) update action or when a Payment(ctp:api:type:Payment) is added via [Order Edits](ctp:api:type:StagedOrderAddPaymentAction). *

func (OrderPaymentAddedMessage) MarshalJSON ¶

func (obj OrderPaymentAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderPaymentAddedMessage) UnmarshalJSON ¶

func (obj *OrderPaymentAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderPaymentAddedMessagePayload ¶

type OrderPaymentAddedMessagePayload struct {
	// [Payment](ctp:api:type:Payment) that was added to the [Order](ctp:api:type:Order).
	Payment PaymentReference `json:"payment"`
}

* * Generated after a successful [Add Payment](ctp:api:type:OrderAddPaymentAction) update action or when a Payment(ctp:api:type:Payment) is added via [Order Edits](ctp:api:type:StagedOrderAddPaymentAction). *

func (OrderPaymentAddedMessagePayload) MarshalJSON ¶

func (obj OrderPaymentAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderPaymentStateChangedMessage ¶

type OrderPaymentStateChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [PaymentState](ctp:api:type:PaymentState) after the [Change Payment State](ctp:api:type:OrderChangePaymentStateAction) update action.
	PaymentState PaymentState `json:"paymentState"`
	// [PaymentState](ctp:api:type:PaymentState) before the [Change Payment State](ctp:api:type:OrderChangePaymentStateAction) update action.
	OldPaymentState *PaymentState `json:"oldPaymentState,omitempty"`
}

* * Generated after a successful [Change Payment State](ctp:api:type:OrderChangePaymentStateAction) update action. *

func (OrderPaymentStateChangedMessage) MarshalJSON ¶

func (obj OrderPaymentStateChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderPaymentStateChangedMessage) UnmarshalJSON ¶

func (obj *OrderPaymentStateChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderPaymentStateChangedMessagePayload ¶

type OrderPaymentStateChangedMessagePayload struct {
	// [PaymentState](ctp:api:type:PaymentState) after the [Change Payment State](ctp:api:type:OrderChangePaymentStateAction) update action.
	PaymentState PaymentState `json:"paymentState"`
	// [PaymentState](ctp:api:type:PaymentState) before the [Change Payment State](ctp:api:type:OrderChangePaymentStateAction) update action.
	OldPaymentState *PaymentState `json:"oldPaymentState,omitempty"`
}

* * Generated after a successful [Change Payment State](ctp:api:type:OrderChangePaymentStateAction) update action. *

func (OrderPaymentStateChangedMessagePayload) MarshalJSON ¶

func (obj OrderPaymentStateChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderPurchaseOrderNumberSetMessage ¶

type OrderPurchaseOrderNumberSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Purchase order number on the [Order](ctp:api:type:Order) after the [Set PurchaseOrderNumber](/../api/projects/orders#set-purchase-order-number) update action.
	PurchaseOrderNumber *string `json:"purchaseOrderNumber,omitempty"`
	// Purchase order number on the [Order](ctp:api:type:Order) before the [Set PurchaseOrderNumber](/../api/projects/orders#set-purchase-order-number) update action.
	OldPurchaseOrderNumber *string `json:"oldPurchaseOrderNumber,omitempty"`
}

* * Generated after a successful [Set PurchaseOrderNumber](/../api/projects/orders#set-purchase-order-number) update action. *

func (OrderPurchaseOrderNumberSetMessage) MarshalJSON ¶

func (obj OrderPurchaseOrderNumberSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderPurchaseOrderNumberSetMessage) UnmarshalJSON ¶

func (obj *OrderPurchaseOrderNumberSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderPurchaseOrderNumberSetMessagePayload ¶

type OrderPurchaseOrderNumberSetMessagePayload struct {
	// Purchase order number on the [Order](ctp:api:type:Order) after the [Set PurchaseOrderNumber](/../api/projects/orders#set-purchase-order-number) update action.
	PurchaseOrderNumber *string `json:"purchaseOrderNumber,omitempty"`
	// Purchase order number on the [Order](ctp:api:type:Order) before the [Set PurchaseOrderNumber](/../api/projects/orders#set-purchase-order-number) update action.
	OldPurchaseOrderNumber *string `json:"oldPurchaseOrderNumber,omitempty"`
}

* * Generated after a successful [Set PurchaseOrderNumber](/../api/projects/orders#set-purchase-order-number) update action. *

func (OrderPurchaseOrderNumberSetMessagePayload) MarshalJSON ¶

func (obj OrderPurchaseOrderNumberSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderReference ¶

type OrderReference struct {
	// Unique ID of the referenced resource.
	ID  string `json:"id"`
	Obj *Order `json:"obj,omitempty"`
}

func (OrderReference) MarshalJSON ¶

func (obj OrderReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderRemoveDeliveryAction ¶

type OrderRemoveDeliveryAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
}

func (OrderRemoveDeliveryAction) MarshalJSON ¶

func (obj OrderRemoveDeliveryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderRemoveItemShippingAddressAction ¶

type OrderRemoveItemShippingAddressAction struct {
	AddressKey string `json:"addressKey"`
}

func (OrderRemoveItemShippingAddressAction) MarshalJSON ¶

func (obj OrderRemoveItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderRemoveParcelFromDeliveryAction ¶

type OrderRemoveParcelFromDeliveryAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey *string `json:"parcelKey,omitempty"`
}

func (OrderRemoveParcelFromDeliveryAction) MarshalJSON ¶

func (obj OrderRemoveParcelFromDeliveryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderRemovePaymentAction ¶

type OrderRemovePaymentAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) of a [Payment](ctp:api:type:Payment).
	Payment PaymentResourceIdentifier `json:"payment"`
}

func (OrderRemovePaymentAction) MarshalJSON ¶

func (obj OrderRemovePaymentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderResourceIdentifier ¶

type OrderResourceIdentifier struct {
	// Unique identifier of the referenced resource. Required if `key` is absent.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced resource. Required if `id` is absent.
	Key *string `json:"key,omitempty"`
}

func (OrderResourceIdentifier) MarshalJSON ¶

func (obj OrderResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderReturnShipmentStateChangedMessage ¶

type OrderReturnShipmentStateChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [ReturnItem](ctp:api:type:ReturnItem).
	ReturnItemId string `json:"returnItemId"`
	// State of the [ReturnItem](ctp:api:type:ReturnItem) after the [Set Return Shipment State](ctp:api:type:OrderSetReturnShipmentStateAction) update action.
	ReturnShipmentState ReturnShipmentState `json:"returnShipmentState"`
}

* * Generated after a successful [Set Return Shipment State](ctp:api:type:OrderSetReturnShipmentStateAction) update action. *

func (OrderReturnShipmentStateChangedMessage) MarshalJSON ¶

func (obj OrderReturnShipmentStateChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderReturnShipmentStateChangedMessage) UnmarshalJSON ¶

func (obj *OrderReturnShipmentStateChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderReturnShipmentStateChangedMessagePayload ¶

type OrderReturnShipmentStateChangedMessagePayload struct {
	// Unique identifier of the [ReturnItem](ctp:api:type:ReturnItem).
	ReturnItemId string `json:"returnItemId"`
	// State of the [ReturnItem](ctp:api:type:ReturnItem) after the [Set Return Shipment State](ctp:api:type:OrderSetReturnShipmentStateAction) update action.
	ReturnShipmentState ReturnShipmentState `json:"returnShipmentState"`
}

* * Generated after a successful [Set Return Shipment State](ctp:api:type:OrderSetReturnShipmentStateAction) update action. *

func (OrderReturnShipmentStateChangedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSearchAndExpression ¶

type OrderSearchAndExpression struct {
	And []OrderSearchQuery `json:"and"`
}

type OrderSearchAnyValue ¶

type OrderSearchAnyValue struct {
	Field           string      `json:"field"`
	Boost           *int        `json:"boost,omitempty"`
	CustomType      *string     `json:"customType,omitempty"`
	Value           interface{} `json:"value"`
	Language        *string     `json:"language,omitempty"`
	CaseInsensitive *bool       `json:"caseInsensitive,omitempty"`
}

type OrderSearchCompoundExpression ¶

type OrderSearchCompoundExpression map[string]interface{}

type OrderSearchDateRangeExpression ¶

type OrderSearchDateRangeExpression struct {
	Range OrderSearchDateRangeValue `json:"range"`
}

type OrderSearchDateRangeValue ¶

type OrderSearchDateRangeValue struct {
	Field      string     `json:"field"`
	Boost      *int       `json:"boost,omitempty"`
	CustomType *string    `json:"customType,omitempty"`
	Gte        *time.Time `json:"gte,omitempty"`
	Lte        *time.Time `json:"lte,omitempty"`
}

type OrderSearchExactExpression ¶

type OrderSearchExactExpression struct {
	Exact OrderSearchAnyValue `json:"exact"`
}

type OrderSearchExistsExpression ¶

type OrderSearchExistsExpression struct {
	Exists OrderSearchQueryExpressionValue `json:"exists"`
}

type OrderSearchFilterExpression ¶

type OrderSearchFilterExpression struct {
	Filter []OrderSearchQueryExpression `json:"filter"`
}

type OrderSearchFullTextExpression ¶

type OrderSearchFullTextExpression struct {
	FullText OrderSearchFullTextValue `json:"fullText"`
}

type OrderSearchFullTextValue ¶

type OrderSearchFullTextValue struct {
	Field      string                `json:"field"`
	Boost      *int                  `json:"boost,omitempty"`
	CustomType *string               `json:"customType,omitempty"`
	Value      string                `json:"value"`
	Language   *string               `json:"language,omitempty"`
	MustMatch  *OrderSearchMatchType `json:"mustMatch,omitempty"`
}

type OrderSearchLongRangeExpression ¶

type OrderSearchLongRangeExpression struct {
	Range OrderSearchLongRangeValue `json:"range"`
}

type OrderSearchLongRangeValue ¶

type OrderSearchLongRangeValue struct {
	Field      string  `json:"field"`
	Boost      *int    `json:"boost,omitempty"`
	CustomType *string `json:"customType,omitempty"`
	Gte        *int    `json:"gte,omitempty"`
	Lte        *int    `json:"lte,omitempty"`
}

type OrderSearchMatchType ¶

type OrderSearchMatchType string
const (
	OrderSearchMatchTypeAny OrderSearchMatchType = "any"
	OrderSearchMatchTypeAll OrderSearchMatchType = "all"
)

type OrderSearchNotExpression ¶

type OrderSearchNotExpression struct {
	Not []OrderSearchQuery `json:"not"`
}

type OrderSearchNumberRangeExpression ¶

type OrderSearchNumberRangeExpression struct {
	Range OrderSearchNumberRangeValue `json:"range"`
}

type OrderSearchNumberRangeValue ¶

type OrderSearchNumberRangeValue struct {
	Field      string   `json:"field"`
	Boost      *int     `json:"boost,omitempty"`
	CustomType *string  `json:"customType,omitempty"`
	Gte        *float64 `json:"gte,omitempty"`
	Lte        *float64 `json:"lte,omitempty"`
}

type OrderSearchOrExpression ¶

type OrderSearchOrExpression struct {
	Or []OrderSearchQuery `json:"or"`
}

type OrderSearchPrefixExpression ¶

type OrderSearchPrefixExpression struct {
	Prefix OrderSearchStringValue `json:"prefix"`
}

type OrderSearchQuery ¶

type OrderSearchQuery map[string]interface{}

type OrderSearchQueryExpression ¶

type OrderSearchQueryExpression map[string]interface{}

type OrderSearchQueryExpressionValue ¶

type OrderSearchQueryExpressionValue struct {
	Field      string  `json:"field"`
	Boost      *int    `json:"boost,omitempty"`
	CustomType *string `json:"customType,omitempty"`
}

type OrderSearchRequest ¶

type OrderSearchRequest struct {
	// The Order search query.
	Query OrderSearchQuery `json:"query"`
	// Controls how results to your query are sorted. If not provided, the results are sorted by relevance in descending order.
	Sort []OrderSearchSorting `json:"sort"`
	// The maximum number of search results to be returned.
	Limit *int `json:"limit,omitempty"`
	// The number of search results to be skipped in the response for pagination.
	Offset *int `json:"offset,omitempty"`
}

func (OrderSearchRequest) MarshalJSON ¶

func (obj OrderSearchRequest) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSearchSortMode ¶

type OrderSearchSortMode string
const (
	OrderSearchSortModeMin OrderSearchSortMode = "min"
	OrderSearchSortModeMax OrderSearchSortMode = "max"
	OrderSearchSortModeAvg OrderSearchSortMode = "avg"
	OrderSearchSortModeSum OrderSearchSortMode = "sum"
)

type OrderSearchSortOrder ¶

type OrderSearchSortOrder string
const (
	OrderSearchSortOrderAsc  OrderSearchSortOrder = "asc"
	OrderSearchSortOrderDesc OrderSearchSortOrder = "desc"
)

type OrderSearchSorting ¶

type OrderSearchSorting struct {
	Field    string                      `json:"field"`
	Language *string                     `json:"language,omitempty"`
	Order    *OrderSearchSortOrder       `json:"order,omitempty"`
	Mode     *OrderSearchSortMode        `json:"mode,omitempty"`
	Filter   *OrderSearchQueryExpression `json:"filter,omitempty"`
}

type OrderSearchStatus ¶

type OrderSearchStatus string

* * Specifies the status of the [Order Search](/../api/projects/order-search) index.

const (
	OrderSearchStatusActivated   OrderSearchStatus = "Activated"
	OrderSearchStatusDeactivated OrderSearchStatus = "Deactivated"
)

type OrderSearchStringValue ¶

type OrderSearchStringValue struct {
	Field           string  `json:"field"`
	Boost           *int    `json:"boost,omitempty"`
	CustomType      *string `json:"customType,omitempty"`
	Value           string  `json:"value"`
	Language        *string `json:"language,omitempty"`
	CaseInsensitive *bool   `json:"caseInsensitive,omitempty"`
}

type OrderSearchWildCardExpression ¶

type OrderSearchWildCardExpression struct {
	Wildcard OrderSearchStringValue `json:"wildcard"`
}

type OrderSetBillingAddressAction ¶

type OrderSetBillingAddressAction struct {
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address *BaseAddress `json:"address,omitempty"`
}

func (OrderSetBillingAddressAction) MarshalJSON ¶

func (obj OrderSetBillingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetBillingAddressCustomFieldAction ¶

type OrderSetBillingAddressCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (OrderSetBillingAddressCustomFieldAction) MarshalJSON ¶

func (obj OrderSetBillingAddressCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetBillingAddressCustomTypeAction ¶

type OrderSetBillingAddressCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the `billingAddress` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `billingAddress`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `billingAddress`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (OrderSetBillingAddressCustomTypeAction) MarshalJSON ¶

func (obj OrderSetBillingAddressCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetCustomFieldAction ¶

type OrderSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (OrderSetCustomFieldAction) MarshalJSON ¶

func (obj OrderSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetCustomLineItemCustomFieldAction ¶

type OrderSetCustomLineItemCustomFieldAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (OrderSetCustomLineItemCustomFieldAction) MarshalJSON ¶

func (obj OrderSetCustomLineItemCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetCustomLineItemCustomTypeAction ¶

type OrderSetCustomLineItemCustomTypeAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the CustomLineItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the CustomLineItem.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the CustomLineItem.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (OrderSetCustomLineItemCustomTypeAction) MarshalJSON ¶

func (obj OrderSetCustomLineItemCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetCustomLineItemShippingDetailsAction ¶

type OrderSetCustomLineItemShippingDetailsAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	// For order creation and updates, the sum of the `targets` must match the quantity of the Line Items or Custom Line Items.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
}

func (OrderSetCustomLineItemShippingDetailsAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetCustomTypeAction ¶

type OrderSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the Order with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Order.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Order.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (OrderSetCustomTypeAction) MarshalJSON ¶

func (obj OrderSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetCustomerEmailAction ¶

type OrderSetCustomerEmailAction struct {
	Email *string `json:"email,omitempty"`
}

func (OrderSetCustomerEmailAction) MarshalJSON ¶

func (obj OrderSetCustomerEmailAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetCustomerIdAction ¶

type OrderSetCustomerIdAction struct {
	CustomerId *string `json:"customerId,omitempty"`
}

func (OrderSetCustomerIdAction) MarshalJSON ¶

func (obj OrderSetCustomerIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetDeliveryAddressAction ¶

type OrderSetDeliveryAddressAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address *BaseAddress `json:"address,omitempty"`
}

func (OrderSetDeliveryAddressAction) MarshalJSON ¶

func (obj OrderSetDeliveryAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetDeliveryAddressCustomFieldAction ¶

type OrderSetDeliveryAddressCustomFieldAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (OrderSetDeliveryAddressCustomFieldAction) MarshalJSON ¶

func (obj OrderSetDeliveryAddressCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetDeliveryAddressCustomTypeAction ¶

type OrderSetDeliveryAddressCustomTypeAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
	// Defines the [Type](ctp:api:type:Type) that extends the `address` in a Delivery with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `address` in a Delivery.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `address` in a Delivery.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (OrderSetDeliveryAddressCustomTypeAction) MarshalJSON ¶

func (obj OrderSetDeliveryAddressCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetDeliveryCustomFieldAction ¶

type OrderSetDeliveryCustomFieldAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (OrderSetDeliveryCustomFieldAction) MarshalJSON ¶

func (obj OrderSetDeliveryCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetDeliveryCustomTypeAction ¶

type OrderSetDeliveryCustomTypeAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
	// Defines the [Type](ctp:api:type:Type) that extends the Delivery with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Delivery.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Delivery.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (OrderSetDeliveryCustomTypeAction) MarshalJSON ¶

func (obj OrderSetDeliveryCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetDeliveryItemsAction ¶

type OrderSetDeliveryItemsAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string        `json:"deliveryKey,omitempty"`
	Items       []DeliveryItem `json:"items"`
}

func (OrderSetDeliveryItemsAction) MarshalJSON ¶

func (obj OrderSetDeliveryItemsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetItemShippingAddressCustomFieldAction ¶

type OrderSetItemShippingAddressCustomFieldAction struct {
	AddressKey string `json:"addressKey"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (OrderSetItemShippingAddressCustomFieldAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetItemShippingAddressCustomTypeAction ¶

type OrderSetItemShippingAddressCustomTypeAction struct {
	AddressKey string `json:"addressKey"`
	// Defines the [Type](ctp:api:type:Type) that extends the `itemShippingAddress` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `itemShippingAddress`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `itemShippingAddress`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (OrderSetItemShippingAddressCustomTypeAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetLineItemCustomFieldAction ¶

type OrderSetLineItemCustomFieldAction struct {
	LineItemId string `json:"lineItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (OrderSetLineItemCustomFieldAction) MarshalJSON ¶

func (obj OrderSetLineItemCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetLineItemCustomTypeAction ¶

type OrderSetLineItemCustomTypeAction struct {
	LineItemId string `json:"lineItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the LineItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the LineItem.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the LineItem.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (OrderSetLineItemCustomTypeAction) MarshalJSON ¶

func (obj OrderSetLineItemCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetLineItemShippingDetailsAction ¶

type OrderSetLineItemShippingDetailsAction struct {
	LineItemId string `json:"lineItemId"`
	// For order creation and updates, the sum of the `targets` must match the quantity of the Line Items or Custom Line Items.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
}

func (OrderSetLineItemShippingDetailsAction) MarshalJSON ¶

func (obj OrderSetLineItemShippingDetailsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetLocaleAction ¶

type OrderSetLocaleAction struct {
	Locale *string `json:"locale,omitempty"`
}

func (OrderSetLocaleAction) MarshalJSON ¶

func (obj OrderSetLocaleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetOrderNumberAction ¶

type OrderSetOrderNumberAction struct {
	OrderNumber *string `json:"orderNumber,omitempty"`
}

func (OrderSetOrderNumberAction) MarshalJSON ¶

func (obj OrderSetOrderNumberAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetParcelCustomFieldAction ¶

type OrderSetParcelCustomFieldAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey *string `json:"parcelKey,omitempty"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (OrderSetParcelCustomFieldAction) MarshalJSON ¶

func (obj OrderSetParcelCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetParcelCustomTypeAction ¶

type OrderSetParcelCustomTypeAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey *string `json:"parcelKey,omitempty"`
	// Defines the [Type](ctp:api:type:Type) that extends the Parcel with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Parcel.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Parcel.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (OrderSetParcelCustomTypeAction) MarshalJSON ¶

func (obj OrderSetParcelCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetParcelItemsAction ¶

type OrderSetParcelItemsAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey *string        `json:"parcelKey,omitempty"`
	Items     []DeliveryItem `json:"items"`
}

func (OrderSetParcelItemsAction) MarshalJSON ¶

func (obj OrderSetParcelItemsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetParcelMeasurementsAction ¶

type OrderSetParcelMeasurementsAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey    *string             `json:"parcelKey,omitempty"`
	Measurements *ParcelMeasurements `json:"measurements,omitempty"`
}

func (OrderSetParcelMeasurementsAction) MarshalJSON ¶

func (obj OrderSetParcelMeasurementsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetParcelTrackingDataAction ¶

type OrderSetParcelTrackingDataAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey    *string       `json:"parcelKey,omitempty"`
	TrackingData *TrackingData `json:"trackingData,omitempty"`
}

func (OrderSetParcelTrackingDataAction) MarshalJSON ¶

func (obj OrderSetParcelTrackingDataAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetPurchaseOrderNumberAction ¶

type OrderSetPurchaseOrderNumberAction struct {
	// Identifier for a purchase order, usually in a B2B context.
	// The Purchase Order Number is typically entered by the [Buyer](/quotes-overview#buyer) and can also be used with [Quotes](/quotes-overview).
	PurchaseOrderNumber *string `json:"purchaseOrderNumber,omitempty"`
}

func (OrderSetPurchaseOrderNumberAction) MarshalJSON ¶

func (obj OrderSetPurchaseOrderNumberAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetReturnInfoAction ¶

type OrderSetReturnInfoAction struct {
	Items []ReturnInfoDraft `json:"items"`
}

func (OrderSetReturnInfoAction) MarshalJSON ¶

func (obj OrderSetReturnInfoAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetReturnItemCustomFieldAction ¶

type OrderSetReturnItemCustomFieldAction struct {
	ReturnItemId string `json:"returnItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (OrderSetReturnItemCustomFieldAction) MarshalJSON ¶

func (obj OrderSetReturnItemCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetReturnItemCustomTypeAction ¶

type OrderSetReturnItemCustomTypeAction struct {
	ReturnItemId string `json:"returnItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the ReturnItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the ReturnItem.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the ReturnItem.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (OrderSetReturnItemCustomTypeAction) MarshalJSON ¶

func (obj OrderSetReturnItemCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetReturnPaymentStateAction ¶

type OrderSetReturnPaymentStateAction struct {
	ReturnItemId string             `json:"returnItemId"`
	PaymentState ReturnPaymentState `json:"paymentState"`
}

func (OrderSetReturnPaymentStateAction) MarshalJSON ¶

func (obj OrderSetReturnPaymentStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetReturnShipmentStateAction ¶

type OrderSetReturnShipmentStateAction struct {
	ReturnItemId  string              `json:"returnItemId"`
	ShipmentState ReturnShipmentState `json:"shipmentState"`
}

func (OrderSetReturnShipmentStateAction) MarshalJSON ¶

func (obj OrderSetReturnShipmentStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetShippingAddressAction ¶

type OrderSetShippingAddressAction struct {
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address *BaseAddress `json:"address,omitempty"`
}

func (OrderSetShippingAddressAction) MarshalJSON ¶

func (obj OrderSetShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetShippingAddressCustomFieldAction ¶

type OrderSetShippingAddressCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (OrderSetShippingAddressCustomFieldAction) MarshalJSON ¶

func (obj OrderSetShippingAddressCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetShippingAddressCustomTypeAction ¶

type OrderSetShippingAddressCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the `shippingAddress` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `shippingAddress`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `shippingAddress`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (OrderSetShippingAddressCustomTypeAction) MarshalJSON ¶

func (obj OrderSetShippingAddressCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderSetStoreAction ¶

type OrderSetStoreAction struct {
	// [ResourceIdentifier](/../api/types#resourceidentifier) to a [Store](ctp:api:type:Store).
	Store *StoreResourceIdentifier `json:"store,omitempty"`
}

func (OrderSetStoreAction) MarshalJSON ¶

func (obj OrderSetStoreAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderShipmentStateChangedMessage ¶

type OrderShipmentStateChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [ShipmentState](ctp:api:type:ShipmentState) after the [Change Shipment State](ctp:api:type:OrderChangeShipmentStateAction) update action.
	ShipmentState ShipmentState `json:"shipmentState"`
	// [ShipmentState](ctp:api:type:ShipmentState) before the [Change Shipment State](ctp:api:type:OrderChangeShipmentStateAction) update action.
	OldShipmentState ShipmentState `json:"oldShipmentState"`
}

* * Generated after a successful [Change Shipment State](ctp:api:type:OrderChangeShipmentStateAction) update action. *

func (OrderShipmentStateChangedMessage) MarshalJSON ¶

func (obj OrderShipmentStateChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderShipmentStateChangedMessage) UnmarshalJSON ¶

func (obj *OrderShipmentStateChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderShipmentStateChangedMessagePayload ¶

type OrderShipmentStateChangedMessagePayload struct {
	// [ShipmentState](ctp:api:type:ShipmentState) after the [Change Shipment State](ctp:api:type:OrderChangeShipmentStateAction) update action.
	ShipmentState ShipmentState `json:"shipmentState"`
	// [ShipmentState](ctp:api:type:ShipmentState) before the [Change Shipment State](ctp:api:type:OrderChangeShipmentStateAction) update action.
	OldShipmentState ShipmentState `json:"oldShipmentState"`
}

* * Generated after a successful [Change Shipment State](ctp:api:type:OrderChangeShipmentStateAction) update action. *

func (OrderShipmentStateChangedMessagePayload) MarshalJSON ¶

func (obj OrderShipmentStateChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderShippingAddressSetMessage ¶

type OrderShippingAddressSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Shipping address on the Order after the [Set Shipping Address](ctp:api:type:OrderSetShippingAddressAction) update action.
	Address *Address `json:"address,omitempty"`
	// Shipping address on the Order before the [Set Shipping Address](ctp:api:type:OrderSetShippingAddressAction) update action.
	OldAddress *Address `json:"oldAddress,omitempty"`
}

* * Generated after a successful [Set Shipping Address](ctp:api:type:OrderSetShippingAddressAction) update action. *

func (OrderShippingAddressSetMessage) MarshalJSON ¶

func (obj OrderShippingAddressSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderShippingAddressSetMessage) UnmarshalJSON ¶

func (obj *OrderShippingAddressSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderShippingAddressSetMessagePayload ¶

type OrderShippingAddressSetMessagePayload struct {
	// Shipping address on the Order after the [Set Shipping Address](ctp:api:type:OrderSetShippingAddressAction) update action.
	Address *Address `json:"address,omitempty"`
	// Shipping address on the Order before the [Set Shipping Address](ctp:api:type:OrderSetShippingAddressAction) update action.
	OldAddress *Address `json:"oldAddress,omitempty"`
}

* * Generated after a successful [Set Shipping Address](ctp:api:type:OrderSetShippingAddressAction) update action. *

func (OrderShippingAddressSetMessagePayload) MarshalJSON ¶

func (obj OrderShippingAddressSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderShippingInfoSetMessage ¶

type OrderShippingInfoSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [ShippingInfo](ctp:api:type:ShippingInfo) after the [Set Shipping Method](ctp:api:type:StagedOrderSetShippingMethodAction) or [Set Custom Shipping Method](ctp:api:type:StagedOrderSetCustomShippingMethodAction) update action.
	ShippingInfo *ShippingInfo `json:"shippingInfo,omitempty"`
	// [ShippingInfo](ctp:api:type:ShippingInfo) before the [Set Shipping Method](ctp:api:type:StagedOrderSetShippingMethodAction) or [Set Custom Shipping Method](ctp:api:type:StagedOrderSetCustomShippingMethodAction) update action.
	OldShippingInfo *ShippingInfo `json:"oldShippingInfo,omitempty"`
}

* * Generated after a successful [Set Shipping Method](ctp:api:type:StagedOrderSetShippingMethodAction) and [Set Custom Shipping Method](ctp:api:type:StagedOrderSetCustomShippingMethodAction) update actions. *

func (OrderShippingInfoSetMessage) MarshalJSON ¶

func (obj OrderShippingInfoSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderShippingInfoSetMessage) UnmarshalJSON ¶

func (obj *OrderShippingInfoSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderShippingInfoSetMessagePayload ¶

type OrderShippingInfoSetMessagePayload struct {
	// [ShippingInfo](ctp:api:type:ShippingInfo) after the [Set Shipping Method](ctp:api:type:StagedOrderSetShippingMethodAction) or [Set Custom Shipping Method](ctp:api:type:StagedOrderSetCustomShippingMethodAction) update action.
	ShippingInfo *ShippingInfo `json:"shippingInfo,omitempty"`
	// [ShippingInfo](ctp:api:type:ShippingInfo) before the [Set Shipping Method](ctp:api:type:StagedOrderSetShippingMethodAction) or [Set Custom Shipping Method](ctp:api:type:StagedOrderSetCustomShippingMethodAction) update action.
	OldShippingInfo *ShippingInfo `json:"oldShippingInfo,omitempty"`
}

* * Generated after a successful [Set Shipping Method](ctp:api:type:StagedOrderSetShippingMethodAction) and [Set Custom Shipping Method](ctp:api:type:StagedOrderSetCustomShippingMethodAction) update actions. *

func (OrderShippingInfoSetMessagePayload) MarshalJSON ¶

func (obj OrderShippingInfoSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderShippingRateInputSetMessage ¶

type OrderShippingRateInputSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [ShippingRateInput](ctp:api:type:ShippingRateInput) after the [Set ShippingRateInput](ctp:api:type:StagedOrderSetShippingRateInputAction) update action.
	ShippingRateInput ShippingRateInput `json:"shippingRateInput,omitempty"`
	// [ShippingRateInput](ctp:api:type:ShippingRateInput) before the [Set ShippingRateInput](ctp:api:type:StagedOrderSetShippingRateInputAction) update action.
	OldShippingRateInput ShippingRateInput `json:"oldShippingRateInput,omitempty"`
}

* * Generated after a successful [Set ShippingRateInput](ctp:api:type:StagedOrderSetShippingRateInputAction) update action. *

func (OrderShippingRateInputSetMessage) MarshalJSON ¶

func (obj OrderShippingRateInputSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderShippingRateInputSetMessage) UnmarshalJSON ¶

func (obj *OrderShippingRateInputSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderShippingRateInputSetMessagePayload ¶

type OrderShippingRateInputSetMessagePayload struct {
	// [ShippingRateInput](ctp:api:type:ShippingRateInput) after the [Set ShippingRateInput](ctp:api:type:StagedOrderSetShippingRateInputAction) update action.
	ShippingRateInput ShippingRateInput `json:"shippingRateInput,omitempty"`
	// [ShippingRateInput](ctp:api:type:ShippingRateInput) before the [Set ShippingRateInput](ctp:api:type:StagedOrderSetShippingRateInputAction) update action.
	OldShippingRateInput ShippingRateInput `json:"oldShippingRateInput,omitempty"`
}

* * Generated after a successful [Set ShippingRateInput](ctp:api:type:StagedOrderSetShippingRateInputAction) update action. *

func (OrderShippingRateInputSetMessagePayload) MarshalJSON ¶

func (obj OrderShippingRateInputSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderShippingRateInputSetMessagePayload) UnmarshalJSON ¶

func (obj *OrderShippingRateInputSetMessagePayload) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderState ¶

type OrderState string
const (
	OrderStateOpen      OrderState = "Open"
	OrderStateConfirmed OrderState = "Confirmed"
	OrderStateComplete  OrderState = "Complete"
	OrderStateCancelled OrderState = "Cancelled"
)

type OrderStateChangedMessage ¶

type OrderStateChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [OrderState](ctp:api:type:OrderState) after the [Change Order State](ctp:api:type:OrderChangeOrderStateAction) update action.
	OrderState OrderState `json:"orderState"`
	// [OrderState](ctp:api:type:OrderState) before the [Change Order State](ctp:api:type:OrderChangeOrderStateAction) update action.
	OldOrderState OrderState `json:"oldOrderState"`
}

* * Generated after a successful [Change Order State](ctp:api:type:OrderChangeOrderStateAction) update action. *

func (OrderStateChangedMessage) MarshalJSON ¶

func (obj OrderStateChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderStateChangedMessage) UnmarshalJSON ¶

func (obj *OrderStateChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderStateChangedMessagePayload ¶

type OrderStateChangedMessagePayload struct {
	// [OrderState](ctp:api:type:OrderState) after the [Change Order State](ctp:api:type:OrderChangeOrderStateAction) update action.
	OrderState OrderState `json:"orderState"`
	// [OrderState](ctp:api:type:OrderState) before the [Change Order State](ctp:api:type:OrderChangeOrderStateAction) update action.
	OldOrderState OrderState `json:"oldOrderState"`
}

* * Generated after a successful [Change Order State](ctp:api:type:OrderChangeOrderStateAction) update action. *

func (OrderStateChangedMessagePayload) MarshalJSON ¶

func (obj OrderStateChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderStateTransitionMessage ¶

type OrderStateTransitionMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [OrderState](ctp:api:type:OrderState) after the [Transition State](ctp:api:type:OrderTransitionStateAction) update action.
	State StateReference `json:"state"`
	// [OrderState](ctp:api:type:OrderState) before the [Transition State](ctp:api:type:OrderTransitionStateAction) update action.
	OldState *StateReference `json:"oldState,omitempty"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:OrderTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:OrderTransitionStateAction) update action. *

func (OrderStateTransitionMessage) MarshalJSON ¶

func (obj OrderStateTransitionMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderStateTransitionMessage) UnmarshalJSON ¶

func (obj *OrderStateTransitionMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderStateTransitionMessagePayload ¶

type OrderStateTransitionMessagePayload struct {
	// [OrderState](ctp:api:type:OrderState) after the [Transition State](ctp:api:type:OrderTransitionStateAction) update action.
	State StateReference `json:"state"`
	// [OrderState](ctp:api:type:OrderState) before the [Transition State](ctp:api:type:OrderTransitionStateAction) update action.
	OldState *StateReference `json:"oldState,omitempty"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:OrderTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:OrderTransitionStateAction) update action. *

func (OrderStateTransitionMessagePayload) MarshalJSON ¶

func (obj OrderStateTransitionMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderStoreSetMessage ¶

type OrderStoreSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Store](ctp:api:type:Store) that was set.
	Store *StoreKeyReference `json:"store,omitempty"`
}

* * Generated after a successful [Set Store](ctp:api:type:OrderSetStoreAction) update action. *

func (OrderStoreSetMessage) MarshalJSON ¶

func (obj OrderStoreSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OrderStoreSetMessage) UnmarshalJSON ¶

func (obj *OrderStoreSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderStoreSetMessagePayload ¶

type OrderStoreSetMessagePayload struct {
	// [Store](ctp:api:type:Store) that was set.
	Store *StoreKeyReference `json:"store,omitempty"`
}

* * Generated after a successful [Set Store](ctp:api:type:OrderSetStoreAction) update action. *

func (OrderStoreSetMessagePayload) MarshalJSON ¶

func (obj OrderStoreSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderTransitionCustomLineItemStateAction ¶

type OrderTransitionCustomLineItemStateAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	Quantity         int    `json:"quantity"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	FromState StateResourceIdentifier `json:"fromState"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	ToState              StateResourceIdentifier `json:"toState"`
	ActualTransitionDate *time.Time              `json:"actualTransitionDate,omitempty"`
}

func (OrderTransitionCustomLineItemStateAction) MarshalJSON ¶

func (obj OrderTransitionCustomLineItemStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderTransitionLineItemStateAction ¶

type OrderTransitionLineItemStateAction struct {
	LineItemId string `json:"lineItemId"`
	Quantity   int    `json:"quantity"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	FromState StateResourceIdentifier `json:"fromState"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	ToState              StateResourceIdentifier `json:"toState"`
	ActualTransitionDate *time.Time              `json:"actualTransitionDate,omitempty"`
}

func (OrderTransitionLineItemStateAction) MarshalJSON ¶

func (obj OrderTransitionLineItemStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderTransitionStateAction ¶

type OrderTransitionStateAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	State StateResourceIdentifier `json:"state"`
	Force *bool                   `json:"force,omitempty"`
}

func (OrderTransitionStateAction) MarshalJSON ¶

func (obj OrderTransitionStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderUpdate ¶

type OrderUpdate struct {
	// Expected version of the Order on which the changes should be applied.
	// If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the Order.
	Actions []OrderUpdateAction `json:"actions"`
}

func (*OrderUpdate) UnmarshalJSON ¶

func (obj *OrderUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OrderUpdateAction ¶

type OrderUpdateAction interface{}

type OrderUpdateItemShippingAddressAction ¶

type OrderUpdateItemShippingAddressAction struct {
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address BaseAddress `json:"address"`
}

func (OrderUpdateItemShippingAddressAction) MarshalJSON ¶

func (obj OrderUpdateItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OrderUpdateSyncInfoAction ¶

type OrderUpdateSyncInfoAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [Channel](ctp:api:type:Channel).
	Channel    ChannelResourceIdentifier `json:"channel"`
	ExternalId *string                   `json:"externalId,omitempty"`
	SyncedAt   *time.Time                `json:"syncedAt,omitempty"`
}

func (OrderUpdateSyncInfoAction) MarshalJSON ¶

func (obj OrderUpdateSyncInfoAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type OutOfStockError ¶

type OutOfStockError struct {
	// `"Some line items are out of stock at the time of placing the order: $itemSku."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifiers of the Line Items that are out of stock.
	LineItems []string `json:"lineItems"`
	// SKUs of the Line Items that are out of stock.
	Skus []string `json:"skus"`
}

* * Returned when some of the [Line Items](ctp:api:type:LineItem) are out of stock at the time of placing an Order(ctp:api:type:Order). * * The error is returned as a failed response to: * * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST), [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST), and [Create Order by Import](/../api/projects/me-orders) requests on Orders. * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/me/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/me/orders:POST) requests on My Orders. *

func (*OutOfStockError) DecodeStruct ¶

func (obj *OutOfStockError) DecodeStruct(src map[string]interface{}) error

func (OutOfStockError) Error ¶

func (obj OutOfStockError) Error() string

func (OutOfStockError) MarshalJSON ¶

func (obj OutOfStockError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OutOfStockError) UnmarshalJSON ¶

func (obj *OutOfStockError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OverCapacityError ¶

type OverCapacityError struct {
	// Plain text description of the error.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the service is having trouble handling the load. * * The client application should retry the request with exponential backoff up to a point where further delay is unacceptable. *

func (*OverCapacityError) DecodeStruct ¶

func (obj *OverCapacityError) DecodeStruct(src map[string]interface{}) error

func (OverCapacityError) Error ¶

func (obj OverCapacityError) Error() string

func (OverCapacityError) MarshalJSON ¶

func (obj OverCapacityError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OverCapacityError) UnmarshalJSON ¶

func (obj *OverCapacityError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type OverlappingStandalonePriceValidityError ¶

type OverlappingStandalonePriceValidityError struct {
	// `Two standalone prices have overlapping validity periods."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Reference to the conflicting Standalone Price.
	ConflictingStandalonePrice StandalonePriceReference `json:"conflictingStandalonePrice"`
	// SKU of the [ProductVariant](ctp:api:type:ProductVariant) to which the conflicting Standalone Price is associated.
	Sku string `json:"sku"`
	// Currency code of the country.
	Currency string `json:"currency"`
	// Country code of the geographic location.
	Country *string `json:"country,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) for which the Standalone Price is valid.
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
	// [Channel](ctp:api:type:Channel) for which the Standalone Price is valid.
	Channel *ChannelResourceIdentifier `json:"channel,omitempty"`
	// Date and time (UTC) from which the Standalone Price is valid.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the Standalone Price is valid.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Date and time (UTC) from which the conflicting Standalone Price is valid.
	ConflictingValidFrom *time.Time `json:"conflictingValidFrom,omitempty"`
	// Date and time (UTC) until which the conflicting Standalone Price is valid.
	ConflictingValidUntil *time.Time `json:"conflictingValidUntil,omitempty"`
}

* * Returned when a given Price validity period conflicts with an existing one. * Every Standalone Price associated with the same SKU and with the same combination of currency, country, Customer Group, and Channel, must have non-overlapping validity periods (`validFrom` and `validUntil`). * * The error is returned as a failed response to the [Create StandalonePrice](/../api/projects/standalone-prices#create-standaloneprice) request. *

func (*OverlappingStandalonePriceValidityError) DecodeStruct ¶

func (obj *OverlappingStandalonePriceValidityError) DecodeStruct(src map[string]interface{}) error

func (OverlappingStandalonePriceValidityError) Error ¶

func (OverlappingStandalonePriceValidityError) MarshalJSON ¶

func (obj OverlappingStandalonePriceValidityError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*OverlappingStandalonePriceValidityError) UnmarshalJSON ¶

func (obj *OverlappingStandalonePriceValidityError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PagedQueryResponse ¶

type PagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total   *int           `json:"total,omitempty"`
	Results []BaseResource `json:"results"`
	Meta    *interface{}   `json:"meta,omitempty"`
}

type Parcel ¶

type Parcel struct {
	// Unique identifier of the Parcel.
	ID string `json:"id"`
	// User-defined unique identifier of the Parcel.
	Key          *string             `json:"key,omitempty"`
	CreatedAt    time.Time           `json:"createdAt"`
	Measurements *ParcelMeasurements `json:"measurements,omitempty"`
	TrackingData *TrackingData       `json:"trackingData,omitempty"`
	// The delivery items contained in this parcel.
	Items []DeliveryItem `json:"items"`
	// Custom Fields of this parcel.
	Custom *CustomFields `json:"custom,omitempty"`
}

func (Parcel) MarshalJSON ¶

func (obj Parcel) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ParcelAddedToDeliveryMessage ¶

type ParcelAddedToDeliveryMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	Delivery Delivery `json:"delivery"`
	// [Parcel](ctp:api:type:Parcel) that was added to the [Delivery](ctp:api:type:Delivery).
	Parcel Parcel `json:"parcel"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Add Parcel To Delivery](ctp:api:type:OrderAddParcelToDeliveryAction) update action. *

func (ParcelAddedToDeliveryMessage) MarshalJSON ¶

func (obj ParcelAddedToDeliveryMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ParcelAddedToDeliveryMessage) UnmarshalJSON ¶

func (obj *ParcelAddedToDeliveryMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ParcelAddedToDeliveryMessagePayload ¶

type ParcelAddedToDeliveryMessagePayload struct {
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	Delivery Delivery `json:"delivery"`
	// [Parcel](ctp:api:type:Parcel) that was added to the [Delivery](ctp:api:type:Delivery).
	Parcel Parcel `json:"parcel"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Add Parcel To Delivery](ctp:api:type:OrderAddParcelToDeliveryAction) update action. *

func (ParcelAddedToDeliveryMessagePayload) MarshalJSON ¶

func (obj ParcelAddedToDeliveryMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ParcelDraft ¶

type ParcelDraft struct {
	// User-defined unique identifier of the Parcel.
	Key          *string             `json:"key,omitempty"`
	Measurements *ParcelMeasurements `json:"measurements,omitempty"`
	TrackingData *TrackingData       `json:"trackingData,omitempty"`
	// The delivery items contained in this parcel.
	Items []DeliveryItem `json:"items"`
	// Custom Fields of this parcel.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (ParcelDraft) MarshalJSON ¶

func (obj ParcelDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ParcelItemsUpdatedMessage ¶

type ParcelItemsUpdatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Parcel](ctp:api:type:Parcel).
	ParcelId string `json:"parcelId"`
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// [Delivery Items](ctp:api:type:DeliveryItem) after the [Set Parcel Items](ctp:api:type:OrderSetParcelItemsAction) update action.
	Items []DeliveryItem `json:"items"`
	// [Delivery Items](ctp:api:type:DeliveryItem) before the [Set Parcel Items](ctp:api:type:OrderSetParcelItemsAction) update action.
	OldItems []DeliveryItem `json:"oldItems"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Set Parcel Items](ctp:api:type:OrderSetParcelItemsAction) update action. *

func (ParcelItemsUpdatedMessage) MarshalJSON ¶

func (obj ParcelItemsUpdatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ParcelItemsUpdatedMessage) UnmarshalJSON ¶

func (obj *ParcelItemsUpdatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ParcelItemsUpdatedMessagePayload ¶

type ParcelItemsUpdatedMessagePayload struct {
	// Unique identifier of the [Parcel](ctp:api:type:Parcel).
	ParcelId string `json:"parcelId"`
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// [Delivery Items](ctp:api:type:DeliveryItem) after the [Set Parcel Items](ctp:api:type:OrderSetParcelItemsAction) update action.
	Items []DeliveryItem `json:"items"`
	// [Delivery Items](ctp:api:type:DeliveryItem) before the [Set Parcel Items](ctp:api:type:OrderSetParcelItemsAction) update action.
	OldItems []DeliveryItem `json:"oldItems"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Set Parcel Items](ctp:api:type:OrderSetParcelItemsAction) update action. *

func (ParcelItemsUpdatedMessagePayload) MarshalJSON ¶

func (obj ParcelItemsUpdatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ParcelMeasurements ¶

type ParcelMeasurements struct {
	HeightInMillimeter *int `json:"heightInMillimeter,omitempty"`
	LengthInMillimeter *int `json:"lengthInMillimeter,omitempty"`
	WidthInMillimeter  *int `json:"widthInMillimeter,omitempty"`
	WeightInGram       *int `json:"weightInGram,omitempty"`
}

type ParcelMeasurementsUpdatedMessage ¶

type ParcelMeasurementsUpdatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// Unique identifier of the [Parcel](ctp:api:type:Parcel).
	ParcelId string `json:"parcelId"`
	// The [Parcel Measurements](ctp:api:type:ParcelMeasurements) that were set on the [Parcel](ctp:api:type:Parcel).
	Measurements *ParcelMeasurements `json:"measurements,omitempty"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Set Parcel Measurements](ctp:api:type:OrderSetParcelMeasurementsAction) update action. *

func (ParcelMeasurementsUpdatedMessage) MarshalJSON ¶

func (obj ParcelMeasurementsUpdatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ParcelMeasurementsUpdatedMessage) UnmarshalJSON ¶

func (obj *ParcelMeasurementsUpdatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ParcelMeasurementsUpdatedMessagePayload ¶

type ParcelMeasurementsUpdatedMessagePayload struct {
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// Unique identifier of the [Parcel](ctp:api:type:Parcel).
	ParcelId string `json:"parcelId"`
	// The [Parcel Measurements](ctp:api:type:ParcelMeasurements) that were set on the [Parcel](ctp:api:type:Parcel).
	Measurements *ParcelMeasurements `json:"measurements,omitempty"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Set Parcel Measurements](ctp:api:type:OrderSetParcelMeasurementsAction) update action. *

func (ParcelMeasurementsUpdatedMessagePayload) MarshalJSON ¶

func (obj ParcelMeasurementsUpdatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ParcelRemovedFromDeliveryMessage ¶

type ParcelRemovedFromDeliveryMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// [Parcel](ctp:api:type:Parcel) that was removed from the [Delivery](ctp:api:type:Delivery).
	Parcel Parcel `json:"parcel"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Remove Parcel From Delivery](ctp:api:type:OrderRemoveParcelFromDeliveryAction) update action. *

func (ParcelRemovedFromDeliveryMessage) MarshalJSON ¶

func (obj ParcelRemovedFromDeliveryMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ParcelRemovedFromDeliveryMessage) UnmarshalJSON ¶

func (obj *ParcelRemovedFromDeliveryMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ParcelRemovedFromDeliveryMessagePayload ¶

type ParcelRemovedFromDeliveryMessagePayload struct {
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// [Parcel](ctp:api:type:Parcel) that was removed from the [Delivery](ctp:api:type:Delivery).
	Parcel Parcel `json:"parcel"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Remove Parcel From Delivery](ctp:api:type:OrderRemoveParcelFromDeliveryAction) update action. *

func (ParcelRemovedFromDeliveryMessagePayload) MarshalJSON ¶

func (obj ParcelRemovedFromDeliveryMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ParcelTrackingDataUpdatedMessage ¶

type ParcelTrackingDataUpdatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// Unique identifier of the [Parcel](ctp:api:type:Parcel).
	ParcelId string `json:"parcelId"`
	// The [Tracking Data](ctp:api:type:TrackingData) that was added to the [Parcel](ctp:api:type:Parcel).
	TrackingData *TrackingData `json:"trackingData,omitempty"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Set Parcel TrackingData](ctp:api:type:OrderSetParcelTrackingDataAction) update action. *

func (ParcelTrackingDataUpdatedMessage) MarshalJSON ¶

func (obj ParcelTrackingDataUpdatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ParcelTrackingDataUpdatedMessage) UnmarshalJSON ¶

func (obj *ParcelTrackingDataUpdatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ParcelTrackingDataUpdatedMessagePayload ¶

type ParcelTrackingDataUpdatedMessagePayload struct {
	// Unique identifier of the [Delivery](ctp:api:type:Delivery).
	DeliveryId string `json:"deliveryId"`
	// Unique identifier of the [Parcel](ctp:api:type:Parcel).
	ParcelId string `json:"parcelId"`
	// The [Tracking Data](ctp:api:type:TrackingData) that was added to the [Parcel](ctp:api:type:Parcel).
	TrackingData *TrackingData `json:"trackingData,omitempty"`
	// User-defined unique identifier of the Shipping Method in a Cart with `Multi` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

* * Generated after a successful [Set Parcel TrackingData](ctp:api:type:OrderSetParcelTrackingDataAction) update action. *

func (ParcelTrackingDataUpdatedMessagePayload) MarshalJSON ¶

func (obj ParcelTrackingDataUpdatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PayloadNotIncluded ¶

type PayloadNotIncluded struct {
	// Reason the payload is not included. For example, the payload is too large, or its content is not supported by the Subscription destination.
	Reason string `json:"reason"`
	// Value of the `type` field in the original payload.
	PayloadType string `json:"payloadType"`
}

type Payment ¶

type Payment struct {
	// Unique identifier of the Payment.
	ID string `json:"id"`
	// Current version of the Payment.
	Version int `json:"version"`
	// Date and time (UTC) the Payment was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Payment was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Reference to a [Customer](ctp:api:type:Customer) associated with the Payment.
	Customer *CustomerReference `json:"customer,omitempty"`
	// [Anonymous session](ctp:api:type:AnonymousSession) associated with the Payment.
	AnonymousId *string `json:"anonymousId,omitempty"`
	// Additional identifier for external systems like Customer Relationship Management (CRM) or Enterprise Resource Planning (ERP).
	ExternalId *string `json:"externalId,omitempty"`
	// Identifier used by the payment service that processes the Payment (for example, a PSP).
	// The combination of `interfaceId` and the `paymentInterface` field on [PaymentMethodInfo](ctp:api:type:PaymentMethodInfo) must be unique.
	InterfaceId *string `json:"interfaceId,omitempty"`
	// Money value the Payment intends to receive from the customer.
	// The value typically matches the [Cart](ctp:api:type:Cart) or [Order](ctp:api:type:Order) gross total.
	AmountPlanned CentPrecisionMoney `json:"amountPlanned"`
	// Deprecated because its value can be calculated from the total amounts saved in the [Transactions](ctp:api:type:Transaction).
	AmountAuthorized TypedMoney `json:"amountAuthorized,omitempty"`
	// Deprecated because this field is of little practical value, as it is either not reliably known, or the authorization time is fixed for a PSP.
	AuthorizedUntil *string `json:"authorizedUntil,omitempty"`
	// Deprecated because its value can be calculated from the total amounts saved in the [Transactions](ctp:api:type:Transaction).
	AmountPaid TypedMoney `json:"amountPaid,omitempty"`
	// Deprecated because its value can be calculated from the total amounts saved in the [Transactions](ctp:api:type:Transaction).
	AmountRefunded TypedMoney `json:"amountRefunded,omitempty"`
	// Information regarding the payment interface (for example, a PSP), and the specific payment method used.
	PaymentMethodInfo PaymentMethodInfo `json:"paymentMethodInfo"`
	// Current status of the Payment.
	PaymentStatus PaymentStatus `json:"paymentStatus"`
	// Financial transactions of the Payment. Each Transaction has a [TransactionType](ctp:api:type:TransactionType) and a [TransactionState](ctp:api:type:TransactionState).
	Transactions []Transaction `json:"transactions"`
	// Represents information exchange with the payment service, for example, a PSP. An interaction may be a request sent, or a response or notification received from the payment service.
	InterfaceInteractions []CustomFields `json:"interfaceInteractions"`
	// Custom Fields for the Payment.
	Custom *CustomFields `json:"custom,omitempty"`
	// User-defined unique identifier of the Payment.
	Key *string `json:"key,omitempty"`
}

func (*Payment) UnmarshalJSON ¶

func (obj *Payment) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PaymentAddInterfaceInteractionAction ¶

type PaymentAddInterfaceInteractionAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) of a [Type](ctp:api:type:Type).
	Type TypeResourceIdentifier `json:"type"`
	// [Custom Fields](/../api/projects/custom-fields) as per [FieldDefinitions](ctp:api:type:FieldDefinition) of the [Type](ctp:api:type:Type).
	Fields *FieldContainer `json:"fields,omitempty"`
}

* * Adding a Payment interaction generates the [PaymentInteractionAdded](ctp:api:type:PaymentInteractionAddedMessage) Message. *

func (PaymentAddInterfaceInteractionAction) MarshalJSON ¶

func (obj PaymentAddInterfaceInteractionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentAddTransactionAction ¶

type PaymentAddTransactionAction struct {
	// Value to append to the `transactions` array.
	Transaction TransactionDraft `json:"transaction"`
}

* * Adding a Transaction to a Payment generates the [PaymentTransactionAdded](ctp:api:type:PaymentTransactionAddedMessage) Message. *

func (PaymentAddTransactionAction) MarshalJSON ¶

func (obj PaymentAddTransactionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentChangeAmountPlannedAction ¶

type PaymentChangeAmountPlannedAction struct {
	// New value to set.
	Amount Money `json:"amount"`
}

* * Can be used to update the Payment if a customer changes the Cart(ctp:api:type:Cart), or adds or removes a CartDiscount(ctp:api:type:CartDiscount) during checkout. *

func (PaymentChangeAmountPlannedAction) MarshalJSON ¶

func (obj PaymentChangeAmountPlannedAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentChangeTransactionInteractionIdAction ¶

type PaymentChangeTransactionInteractionIdAction struct {
	// Unique identifier of the [Transaction](ctp:api:type:Transaction).
	TransactionId string `json:"transactionId"`
	// New value to set.
	InteractionId string `json:"interactionId"`
}

func (PaymentChangeTransactionInteractionIdAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentChangeTransactionStateAction ¶

type PaymentChangeTransactionStateAction struct {
	// Unique identifier of the [Transaction](ctp:api:type:Transaction).
	TransactionId string `json:"transactionId"`
	// New TransactionState.
	State TransactionState `json:"state"`
}

* * Changing the TransactionState(ctp:api:type:TransactionState) generates the [PaymentTransactionStateChanged](ctp:api:type:PaymentTransactionStateChangedMessage) Message. *

func (PaymentChangeTransactionStateAction) MarshalJSON ¶

func (obj PaymentChangeTransactionStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentChangeTransactionTimestampAction ¶

type PaymentChangeTransactionTimestampAction struct {
	// Unique identifier of the [Transaction](ctp:api:type:Transaction).
	TransactionId string `json:"transactionId"`
	// Timestamp of the Transaction as reported by the payment service.
	Timestamp time.Time `json:"timestamp"`
}

func (PaymentChangeTransactionTimestampAction) MarshalJSON ¶

func (obj PaymentChangeTransactionTimestampAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentCreatedMessage ¶

type PaymentCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Payment](ctp:api:type:Payment) that was created.
	Payment Payment `json:"payment"`
}

* * Generated after a successful [Create Payment](/../api/projects/payments#create-payment) request. *

func (PaymentCreatedMessage) MarshalJSON ¶

func (obj PaymentCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*PaymentCreatedMessage) UnmarshalJSON ¶

func (obj *PaymentCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PaymentCreatedMessagePayload ¶

type PaymentCreatedMessagePayload struct {
	// [Payment](ctp:api:type:Payment) that was created.
	Payment Payment `json:"payment"`
}

* * Generated after a successful [Create Payment](/../api/projects/payments#create-payment) request. *

func (PaymentCreatedMessagePayload) MarshalJSON ¶

func (obj PaymentCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentDraft ¶

type PaymentDraft struct {
	// Reference to a [Customer](ctp:api:type:Customer) associated with the Payment.
	Customer *CustomerResourceIdentifier `json:"customer,omitempty"`
	// [Anonymous session](ctp:api:type:AnonymousSession) associated with the Payment.
	AnonymousId *string `json:"anonymousId,omitempty"`
	// Additional identifier for external systems like Customer Relationship Management (CRM) or Enterprise Resource Planning (ERP).
	ExternalId *string `json:"externalId,omitempty"`
	// Identifier used by the payment service that processes the Payment (for example, a PSP).
	// The combination of `interfaceId` and the `paymentInterface` field on [PaymentMethodInfo](ctp:api:type:PaymentMethodInfo) must be unique.
	// Once set, it cannot be changed.
	InterfaceId *string `json:"interfaceId,omitempty"`
	// Money value the Payment intends to receive from the customer.
	// The value typically matches the [Cart](ctp:api:type:Cart) or [Order](ctp:api:type:Order) gross total.
	AmountPlanned Money `json:"amountPlanned"`
	// Deprecated because the value can be calculated from the total amounts saved in the [Transactions](ctp:api:type:Transaction).
	AmountAuthorized *Money `json:"amountAuthorized,omitempty"`
	// Deprecated because this field is of little practical value, as it is either not reliably known, or the authorization time is fixed for a PSP.
	AuthorizedUntil *string `json:"authorizedUntil,omitempty"`
	// Deprecated because the value can be calculated from the total amounts saved in the [Transactions](ctp:api:type:Transaction).
	AmountPaid *Money `json:"amountPaid,omitempty"`
	// Deprecated because the value can be calculated from the total amounts saved in the [Transactions](ctp:api:type:Transaction).
	AmountRefunded *Money `json:"amountRefunded,omitempty"`
	// Information regarding the payment interface (for example, a PSP), and the specific payment method used.
	PaymentMethodInfo *PaymentMethodInfo `json:"paymentMethodInfo,omitempty"`
	// Current status of the Payment.
	PaymentStatus *PaymentStatusDraft `json:"paymentStatus,omitempty"`
	// Financial transactions of the Payment. Each Transaction has a [TransactionType](ctp:api:type:TransactionType) and a [TransactionState](ctp:api:type:TransactionState).
	Transactions []TransactionDraft `json:"transactions"`
	// Represents information exchange with the payment service, for example, a PSP. An interaction may be a request sent, or a response or notification received from the payment service.
	InterfaceInteractions []CustomFieldsDraft `json:"interfaceInteractions"`
	// Custom Fields for the Payment.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// User-defined unique identifier for the Payment.
	Key *string `json:"key,omitempty"`
}

func (PaymentDraft) MarshalJSON ¶

func (obj PaymentDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentInfo ¶

type PaymentInfo struct {
	Payments []PaymentReference `json:"payments"`
}

type PaymentInteractionAddedMessage ¶

type PaymentInteractionAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The interface interaction that was added to the [Payment](ctp:api:type:Payment).
	Interaction CustomFields `json:"interaction"`
}

* * Generated after a successful [Add InterfaceInteraction](ctp:api:type:PaymentAddInterfaceInteractionAction) update action. *

func (PaymentInteractionAddedMessage) MarshalJSON ¶

func (obj PaymentInteractionAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*PaymentInteractionAddedMessage) UnmarshalJSON ¶

func (obj *PaymentInteractionAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PaymentInteractionAddedMessagePayload ¶

type PaymentInteractionAddedMessagePayload struct {
	// The interface interaction that was added to the [Payment](ctp:api:type:Payment).
	Interaction CustomFields `json:"interaction"`
}

* * Generated after a successful [Add InterfaceInteraction](ctp:api:type:PaymentAddInterfaceInteractionAction) update action. *

func (PaymentInteractionAddedMessagePayload) MarshalJSON ¶

func (obj PaymentInteractionAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentMethodInfo ¶

type PaymentMethodInfo struct {
	// Payment service that processes the Payment (for example, a PSP).
	// Once set, it cannot be changed.
	// The combination of `paymentInterface` and the `interfaceId` of a [Payment](ctp:api:type:Payment) must be unique.
	PaymentInterface *string `json:"paymentInterface,omitempty"`
	// Payment method used, for example, credit card, or cash advance.
	Method *string `json:"method,omitempty"`
	// Localizable name of the payment method.
	Name *LocalizedString `json:"name,omitempty"`
}

type PaymentPagedQueryResponse ¶

type PaymentPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// [Payments](ctp:api:type:Payment) matching the query.
	Results []Payment `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of Payment(ctp:api:type:Payment). *

type PaymentReference ¶

type PaymentReference struct {
	// Unique identifier of the referenced [Payment](ctp:api:type:Payment).
	ID string `json:"id"`
	// Contains the representation of the expanded Payment. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for Payments.
	Obj *Payment `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a Payment(ctp:api:type:Payment). *

func (PaymentReference) MarshalJSON ¶

func (obj PaymentReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentResourceIdentifier ¶

type PaymentResourceIdentifier struct {
	// Unique identifier of the referenced [Payment](ctp:api:type:Payment). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [Payment](ctp:api:type:Payment). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) of a Payment(ctp:api:type:Payment). *

func (PaymentResourceIdentifier) MarshalJSON ¶

func (obj PaymentResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetAmountPaidAction ¶

type PaymentSetAmountPaidAction struct {
	// Draft type that stores amounts only in cent precision for the specified currency.
	Amount *Money `json:"amount,omitempty"`
}

func (PaymentSetAmountPaidAction) MarshalJSON ¶

func (obj PaymentSetAmountPaidAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetAmountRefundedAction ¶

type PaymentSetAmountRefundedAction struct {
	// Draft type that stores amounts only in cent precision for the specified currency.
	Amount *Money `json:"amount,omitempty"`
}

func (PaymentSetAmountRefundedAction) MarshalJSON ¶

func (obj PaymentSetAmountRefundedAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetAnonymousIdAction ¶

type PaymentSetAnonymousIdAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	AnonymousId *string `json:"anonymousId,omitempty"`
}

func (PaymentSetAnonymousIdAction) MarshalJSON ¶

func (obj PaymentSetAnonymousIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetAuthorizationAction ¶

type PaymentSetAuthorizationAction struct {
	// Draft type that stores amounts only in cent precision for the specified currency.
	Amount *Money     `json:"amount,omitempty"`
	Until  *time.Time `json:"until,omitempty"`
}

func (PaymentSetAuthorizationAction) MarshalJSON ¶

func (obj PaymentSetAuthorizationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetCustomFieldAction ¶

type PaymentSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (PaymentSetCustomFieldAction) MarshalJSON ¶

func (obj PaymentSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetCustomTypeAction ¶

type PaymentSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the Payment with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Payment.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Payment.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (PaymentSetCustomTypeAction) MarshalJSON ¶

func (obj PaymentSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetCustomerAction ¶

type PaymentSetCustomerAction struct {
	// Value to set.
	// If empty, any existing reference is removed.
	Customer *CustomerResourceIdentifier `json:"customer,omitempty"`
}

func (PaymentSetCustomerAction) MarshalJSON ¶

func (obj PaymentSetCustomerAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetExternalIdAction ¶

type PaymentSetExternalIdAction struct {
	ExternalId *string `json:"externalId,omitempty"`
}

func (PaymentSetExternalIdAction) MarshalJSON ¶

func (obj PaymentSetExternalIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetInterfaceIdAction ¶

type PaymentSetInterfaceIdAction struct {
	// Value to set.
	// Once set, the `interfaceId` cannot be changed.
	InterfaceId string `json:"interfaceId"`
}

func (PaymentSetInterfaceIdAction) MarshalJSON ¶

func (obj PaymentSetInterfaceIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetKeyAction ¶

type PaymentSetKeyAction struct {
	// Value to set.
	// If `key` is absent or `null`, the existing key, if any, will be removed.
	Key *string `json:"key,omitempty"`
}

func (PaymentSetKeyAction) MarshalJSON ¶

func (obj PaymentSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetMethodInfoInterfaceAction ¶

type PaymentSetMethodInfoInterfaceAction struct {
	// Value to set.
	// Once set, the `paymentInterface` of the `paymentMethodInfo` cannot be changed.
	Interface string `json:"interface"`
}

func (PaymentSetMethodInfoInterfaceAction) MarshalJSON ¶

func (obj PaymentSetMethodInfoInterfaceAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetMethodInfoMethodAction ¶

type PaymentSetMethodInfoMethodAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	Method *string `json:"method,omitempty"`
}

func (PaymentSetMethodInfoMethodAction) MarshalJSON ¶

func (obj PaymentSetMethodInfoMethodAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetMethodInfoNameAction ¶

type PaymentSetMethodInfoNameAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	Name *LocalizedString `json:"name,omitempty"`
}

func (PaymentSetMethodInfoNameAction) MarshalJSON ¶

func (obj PaymentSetMethodInfoNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetStatusInterfaceCodeAction ¶

type PaymentSetStatusInterfaceCodeAction struct {
	// Value to set. If empty, any existing value will be removed.
	InterfaceCode *string `json:"interfaceCode,omitempty"`
}

* * Produces the [PaymentStatusInterfaceCodeSet](ctp:api:type:PaymentStatusInterfaceCodeSetMessage) Message.

func (PaymentSetStatusInterfaceCodeAction) MarshalJSON ¶

func (obj PaymentSetStatusInterfaceCodeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetStatusInterfaceTextAction ¶

type PaymentSetStatusInterfaceTextAction struct {
	// Value to set. If empty, any existing value will be removed.
	InterfaceText string `json:"interfaceText"`
}

func (PaymentSetStatusInterfaceTextAction) MarshalJSON ¶

func (obj PaymentSetStatusInterfaceTextAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetTransactionCustomFieldAction ¶

type PaymentSetTransactionCustomFieldAction struct {
	// Unique identifier of the [Transaction](ctp:api:type:Transaction).
	TransactionId string `json:"transactionId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (PaymentSetTransactionCustomFieldAction) MarshalJSON ¶

func (obj PaymentSetTransactionCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentSetTransactionCustomTypeAction ¶

type PaymentSetTransactionCustomTypeAction struct {
	// Unique identifier of the [Transaction](ctp:api:type:Transaction). If the specified `transactionId` does not exist, the request will fail with an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	TransactionId string `json:"transactionId"`
	// Defines the [Type](ctp:api:type:Type) that extends the Transaction with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Transaction.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Transaction.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (PaymentSetTransactionCustomTypeAction) MarshalJSON ¶

func (obj PaymentSetTransactionCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentState ¶

type PaymentState string
const (
	PaymentStateBalanceDue PaymentState = "BalanceDue"
	PaymentStateFailed     PaymentState = "Failed"
	PaymentStatePending    PaymentState = "Pending"
	PaymentStateCreditOwed PaymentState = "CreditOwed"
	PaymentStatePaid       PaymentState = "Paid"
)

type PaymentStatus ¶

type PaymentStatus struct {
	// External reference that identifies the current status of the Payment.
	InterfaceCode *string `json:"interfaceCode,omitempty"`
	// Text describing the current status of the Payment.
	InterfaceText *string `json:"interfaceText,omitempty"`
	// [Reference](ctp:api:type:Reference) to a [State](ctp:api:type:State).
	State *StateReference `json:"state,omitempty"`
}

type PaymentStatusDraft ¶

type PaymentStatusDraft struct {
	// External reference that identifies the current status of the Payment.
	InterfaceCode *string `json:"interfaceCode,omitempty"`
	// Text describing the current status of the Payment.
	InterfaceText *string `json:"interfaceText,omitempty"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	State *StateResourceIdentifier `json:"state,omitempty"`
}

type PaymentStatusInterfaceCodeSetMessage ¶

type PaymentStatusInterfaceCodeSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier for the [Payment](ctp:api:type:Payment) for which the [Set StatusInterfaceCode](ctp:api:type:PaymentSetStatusInterfaceCodeAction) update action was applied.
	PaymentId string `json:"paymentId"`
	// The `interfaceCode` that was set during the [Set StatusInterfaceCode](ctp:api:type:PaymentSetStatusInterfaceCodeAction) update action.
	InterfaceCode *string `json:"interfaceCode,omitempty"`
}

* * Generated after a successful [Set StatusInterfaceCode](ctp:api:type:PaymentSetStatusInterfaceCodeAction) update action. *

func (PaymentStatusInterfaceCodeSetMessage) MarshalJSON ¶

func (obj PaymentStatusInterfaceCodeSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*PaymentStatusInterfaceCodeSetMessage) UnmarshalJSON ¶

func (obj *PaymentStatusInterfaceCodeSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PaymentStatusInterfaceCodeSetMessagePayload ¶

type PaymentStatusInterfaceCodeSetMessagePayload struct {
	// Unique identifier for the [Payment](ctp:api:type:Payment) for which the [Set StatusInterfaceCode](ctp:api:type:PaymentSetStatusInterfaceCodeAction) update action was applied.
	PaymentId string `json:"paymentId"`
	// The `interfaceCode` that was set during the [Set StatusInterfaceCode](ctp:api:type:PaymentSetStatusInterfaceCodeAction) update action.
	InterfaceCode *string `json:"interfaceCode,omitempty"`
}

* * Generated after a successful [Set StatusInterfaceCode](ctp:api:type:PaymentSetStatusInterfaceCodeAction) update action. *

func (PaymentStatusInterfaceCodeSetMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentStatusStateTransitionMessage ¶

type PaymentStatusStateTransitionMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [State](ctp:api:type:State) of the [Payment](ctp:api:type:Payment) after the [Transition State](ctp:api:type:PaymentTransitionStateAction) update action.
	State StateReference `json:"state"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Change Transaction State](ctp:api:type:PaymentChangeTransactionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:PaymentTransitionStateAction) update action. *

func (PaymentStatusStateTransitionMessage) MarshalJSON ¶

func (obj PaymentStatusStateTransitionMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*PaymentStatusStateTransitionMessage) UnmarshalJSON ¶

func (obj *PaymentStatusStateTransitionMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PaymentStatusStateTransitionMessagePayload ¶

type PaymentStatusStateTransitionMessagePayload struct {
	// [State](ctp:api:type:State) of the [Payment](ctp:api:type:Payment) after the [Transition State](ctp:api:type:PaymentTransitionStateAction) update action.
	State StateReference `json:"state"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Change Transaction State](ctp:api:type:PaymentChangeTransactionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:PaymentTransitionStateAction) update action. *

func (PaymentStatusStateTransitionMessagePayload) MarshalJSON ¶

func (obj PaymentStatusStateTransitionMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentTransactionAddedMessage ¶

type PaymentTransactionAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Transaction](ctp:api:type:Transaction) that was added to the [Payment](ctp:api:type:Payment).
	Transaction Transaction `json:"transaction"`
}

* * Generated after a successful [Add Transaction](ctp:api:type:PaymentAddTransactionAction) update action. *

func (PaymentTransactionAddedMessage) MarshalJSON ¶

func (obj PaymentTransactionAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*PaymentTransactionAddedMessage) UnmarshalJSON ¶

func (obj *PaymentTransactionAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PaymentTransactionAddedMessagePayload ¶

type PaymentTransactionAddedMessagePayload struct {
	// [Transaction](ctp:api:type:Transaction) that was added to the [Payment](ctp:api:type:Payment).
	Transaction Transaction `json:"transaction"`
}

* * Generated after a successful [Add Transaction](ctp:api:type:PaymentAddTransactionAction) update action. *

func (PaymentTransactionAddedMessagePayload) MarshalJSON ¶

func (obj PaymentTransactionAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentTransactionStateChangedMessage ¶

type PaymentTransactionStateChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier for the [Transaction](ctp:api:type:Transaction) for which the [Transaction State](ctp:api:type:TransactionState) changed.
	TransactionId string `json:"transactionId"`
	// [Transaction State](ctp:api:type:TransactionState) after the [Change Transaction State](ctp:api:type:PaymentChangeTransactionStateAction) update action.
	State TransactionState `json:"state"`
}

* * Generated after a successful [Change Transaction State](ctp:api:type:PaymentChangeTransactionStateAction) update action. *

func (PaymentTransactionStateChangedMessage) MarshalJSON ¶

func (obj PaymentTransactionStateChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*PaymentTransactionStateChangedMessage) UnmarshalJSON ¶

func (obj *PaymentTransactionStateChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PaymentTransactionStateChangedMessagePayload ¶

type PaymentTransactionStateChangedMessagePayload struct {
	// Unique identifier for the [Transaction](ctp:api:type:Transaction) for which the [Transaction State](ctp:api:type:TransactionState) changed.
	TransactionId string `json:"transactionId"`
	// [Transaction State](ctp:api:type:TransactionState) after the [Change Transaction State](ctp:api:type:PaymentChangeTransactionStateAction) update action.
	State TransactionState `json:"state"`
}

* * Generated after a successful [Change Transaction State](ctp:api:type:PaymentChangeTransactionStateAction) update action. *

func (PaymentTransactionStateChangedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentTransitionStateAction ¶

type PaymentTransitionStateAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	State StateResourceIdentifier `json:"state"`
	// Set to `true` to skip validations when transitioning to the new State.
	Force *bool `json:"force,omitempty"`
}

* * If the Payment has no current State(ctp:api:type:State), `initial` must be `true` for the new State. * If the existing State has transitions set, the new State must be a valid transition. * If the existing State has no transitions set, no validations are performed when transitioning to the new State. * * Transitioning the State of a Payment produces the [PaymentStatusStateTransition](ctp:api:type:PaymentStatusStateTransitionMessage) Message. *

func (PaymentTransitionStateAction) MarshalJSON ¶

func (obj PaymentTransitionStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PaymentUpdate ¶

type PaymentUpdate struct {
	// Expected version of the Payment on which the changes should be applied. If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the Payment.
	Actions []PaymentUpdateAction `json:"actions"`
}

func (*PaymentUpdate) UnmarshalJSON ¶

func (obj *PaymentUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PaymentUpdateAction ¶

type PaymentUpdateAction interface{}

type PendingOperationError ¶

type PendingOperationError struct {
	// Plain text description of the error.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a previous conflicting operation is still pending and needs to finish before the request can succeed. * * The client application should retry the request with exponential backoff up to a point where further delay is unacceptable. * If the error persists, report it using the [Support Portal](https://support.commercetools.com). *

func (*PendingOperationError) DecodeStruct ¶

func (obj *PendingOperationError) DecodeStruct(src map[string]interface{}) error

func (PendingOperationError) Error ¶

func (obj PendingOperationError) Error() string

func (PendingOperationError) MarshalJSON ¶

func (obj PendingOperationError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*PendingOperationError) UnmarshalJSON ¶

func (obj *PendingOperationError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type Permission ¶

type Permission string

* * Permissions grant granular access to [Business Units](ctp:api:type:BusinessUnit), [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [Quotes](ctp:api:type:Quote), and [QuoteRequests](ctp:api:type:QuoteRequest). *

const (
	PermissionAddChildUnits                      Permission = "AddChildUnits"
	PermissionUpdateAssociates                   Permission = "UpdateAssociates"
	PermissionUpdateBusinessUnitDetails          Permission = "UpdateBusinessUnitDetails"
	PermissionUpdateParentUnit                   Permission = "UpdateParentUnit"
	PermissionViewMyCarts                        Permission = "ViewMyCarts"
	PermissionViewOthersCarts                    Permission = "ViewOthersCarts"
	PermissionUpdateMyCarts                      Permission = "UpdateMyCarts"
	PermissionUpdateOthersCarts                  Permission = "UpdateOthersCarts"
	PermissionCreateMyCarts                      Permission = "CreateMyCarts"
	PermissionCreateOthersCarts                  Permission = "CreateOthersCarts"
	PermissionDeleteMyCarts                      Permission = "DeleteMyCarts"
	PermissionDeleteOthersCarts                  Permission = "DeleteOthersCarts"
	PermissionViewMyOrders                       Permission = "ViewMyOrders"
	PermissionViewOthersOrders                   Permission = "ViewOthersOrders"
	PermissionUpdateMyOrders                     Permission = "UpdateMyOrders"
	PermissionUpdateOthersOrders                 Permission = "UpdateOthersOrders"
	PermissionCreateMyOrdersFromMyCarts          Permission = "CreateMyOrdersFromMyCarts"
	PermissionCreateMyOrdersFromMyQuotes         Permission = "CreateMyOrdersFromMyQuotes"
	PermissionCreateOrdersFromOthersCarts        Permission = "CreateOrdersFromOthersCarts"
	PermissionCreateOrdersFromOthersQuotes       Permission = "CreateOrdersFromOthersQuotes"
	PermissionViewMyQuotes                       Permission = "ViewMyQuotes"
	PermissionViewOthersQuotes                   Permission = "ViewOthersQuotes"
	PermissionAcceptMyQuotes                     Permission = "AcceptMyQuotes"
	PermissionAcceptOthersQuotes                 Permission = "AcceptOthersQuotes"
	PermissionDeclineMyQuotes                    Permission = "DeclineMyQuotes"
	PermissionDeclineOthersQuotes                Permission = "DeclineOthersQuotes"
	PermissionRenegotiateMyQuotes                Permission = "RenegotiateMyQuotes"
	PermissionRenegotiateOthersQuotes            Permission = "RenegotiateOthersQuotes"
	PermissionReassignMyQuotes                   Permission = "ReassignMyQuotes"
	PermissionReassignOthersQuotes               Permission = "ReassignOthersQuotes"
	PermissionViewMyQuoteRequests                Permission = "ViewMyQuoteRequests"
	PermissionViewOthersQuoteRequests            Permission = "ViewOthersQuoteRequests"
	PermissionUpdateMyQuoteRequests              Permission = "UpdateMyQuoteRequests"
	PermissionUpdateOthersQuoteRequests          Permission = "UpdateOthersQuoteRequests"
	PermissionCreateMyQuoteRequestsFromMyCarts   Permission = "CreateMyQuoteRequestsFromMyCarts"
	PermissionCreateQuoteRequestsFromOthersCarts Permission = "CreateQuoteRequestsFromOthersCarts"
)

type PlatformFormat ¶

type PlatformFormat struct {
}

* * The PlatformFormat uses constructs that are similar to the ones used in the REST API, for example, on the [Messages Query HTTP API](/../api/projects/messages). *

func (PlatformFormat) MarshalJSON ¶

func (obj PlatformFormat) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type Price ¶

type Price struct {
	// Unique identifier of this Price.
	ID string `json:"id"`
	// User-defined identifier of the Price. It is unique per [ProductVariant](ctp:api:type:ProductVariant).
	Key *string `json:"key,omitempty"`
	// Money value of this Price.
	Value TypedMoney `json:"value"`
	// Country for which this Price is valid.
	Country *string `json:"country,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) for which this Price is valid.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// `ProductDistribution` [Channel](ctp:api:type:Channel) for which this Price is valid.
	Channel *ChannelReference `json:"channel,omitempty"`
	// Date and time from which this Price is valid.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time until this Price is valid. Prices that are no longer valid are not automatically removed, but they can be [removed](ctp:api:type:ProductRemovePriceAction) if necessary.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Is set if a [ProductDiscount](ctp:api:type:ProductDiscount) has been applied.
	// If set, the API uses the DiscountedPrice value for the [Line Item Price selection](ctp:api:type:LineItemPriceSelection).
	// When a [relative discount](ctp:api:type:ProductDiscountValueRelative) has been applied and the fraction part of the DiscountedPrice `value` is 0.5, the `value` is rounded in favor of the customer with [half-down rounding](https://en.wikipedia.org/wiki/Rounding#Round_half_down).
	Discounted *DiscountedPrice `json:"discounted,omitempty"`
	// Present if different Prices for certain [LineItem](ctp:api:type:LineItem) quantities have been specified.
	Tiers []PriceTier `json:"tiers"`
	// Custom Fields defined for the Price.
	Custom *CustomFields `json:"custom,omitempty"`
}

* * The representation for prices embedded in [LineItems](ctp:api:type:LineItem) and in [ProductVariants](ctp:api:type:ProductVariant) when the [ProductPriceMode](ctp:api:type:ProductPriceModeEnum) is `Embedded`. * For the `Standalone` ProductPriceMode refer to StandalonePrice(ctp:api:type:StandalonePrice).

func (Price) MarshalJSON ¶

func (obj Price) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*Price) UnmarshalJSON ¶

func (obj *Price) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PriceChangedError ¶

type PriceChangedError struct {
	// Plain text description of the reason for the Price change. For example, `"The price or tax of some line items changed at the time of placing the order: $lineItems."`.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Unique identifiers of the Line Items for which the Price or [TaxRate](ctp:api:type:TaxRate) has changed.
	LineItems []string `json:"lineItems"`
	// `true` if the [ShippingRate](ctp:api:type:ShippingRate) has changed.
	Shipping bool `json:"shipping"`
}

* * Returned when the Price, Tax Rate, or Shipping Rate of some Line Items changed since they were last added to the Cart. * * The error is returned as a failed response to: * * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests on Orders. * - [Create Order from Cart](ctp:api:endpoint:/{projectKey}/me/orders:POST) and [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/me/orders:POST) requests on My Orders. *

func (*PriceChangedError) DecodeStruct ¶

func (obj *PriceChangedError) DecodeStruct(src map[string]interface{}) error

func (PriceChangedError) Error ¶

func (obj PriceChangedError) Error() string

func (PriceChangedError) MarshalJSON ¶

func (obj PriceChangedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*PriceChangedError) UnmarshalJSON ¶

func (obj *PriceChangedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PriceDraft ¶

type PriceDraft struct {
	// User-defined identifier for the Price. It must be unique per [ProductVariant](ctp:api:type:ProductVariant).
	Key *string `json:"key,omitempty"`
	// Money value of this Price.
	Value Money `json:"value"`
	// Set this field if this Price is only valid for the specified country.
	Country *string `json:"country,omitempty"`
	// Set this field if this Price is only valid for the referenced [CustomerGroup](ctp:api:type:CustomerGroup).
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
	// Set this field if this Price is only valid for the referenced `ProductDistribution` [Channel](ctp:api:type:Channel).
	Channel *ChannelResourceIdentifier `json:"channel,omitempty"`
	// Set this field if this Price is only valid from the specified date and time. Must be at least 1 ms earlier than `validUntil`.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Set this field if this Price is only valid until the specified date and time. Must be at least 1 ms later than `validFrom`. Prices that are no longer valid are not automatically removed, but they can be [removed](ctp:api:type:ProductRemovePriceAction) if necessary.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Set this field to add a DiscountedPrice from an **external service**.
	//
	// Otherwise, Composable Commerce sets this field automatically if at least one [ProductDiscount](ctp:api:type:ProductDiscount) applies.
	// The DiscountedPrice must reference a ProductDiscount with:
	//
	// * The `isActive` flag set to `true`.
	// * A [ProductDiscountValue](ctp:api:type:ProductDiscountValueExternal) of type `external`.
	// * A `predicate` that matches the [ProductVariant](ctp:api:type:ProductVariant) the Price is referenced from.
	Discounted *DiscountedPriceDraft `json:"discounted,omitempty"`
	// Set this field to specify different Prices for certain [LineItem](ctp:api:type:LineItem) quantities.
	Tiers []PriceTierDraft `json:"tiers"`
	// Custom Fields for the Price.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * The draft representation for prices to be embedded into [ProductVariantDrafts](ctp:api:type:ProductVariantDraft) when the [ProductPriceMode](ctp:api:type:ProductPriceModeEnum) is `Embedded`. For the `Standalone` ProductPriceMode use StandalonePriceDraft(ctp:api:type:StandalonePriceDraft).

func (PriceDraft) MarshalJSON ¶

func (obj PriceDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type PriceFunction ¶

type PriceFunction struct {
	// Currency code compliant to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).
	CurrencyCode string `json:"currencyCode"`
	// To calculate a Price based on the score, use `+`, `-`, `*` and parentheses. The score is inserted with `x`. The function returns the cent amount.
	//
	// For example, to charge $1.99 for a score of `1`, $3.99 for a score of `2`, \$5.99 for a score of `3` and onwards, the function is: `(200 * x) - 1)`. To charge $4.50, $6.00, and \$7.50 for express shipping, the function is: `(150 * x) + 300`.
	Function string `json:"function"`
}

type PriceTier ¶

type PriceTier struct {
	// Minimum quantity this Price tier is valid for.
	//
	// The minimum quantity is always greater than or equal to 2. The base Price is interpreted as valid for a minimum quantity equal to 1.
	// A [Price](ctp:api:type:Price) or [StandalonePrice](ctp:api:type:StandalonePrice) cannot contain more than one tier with the same `minimumQuantity`.
	MinimumQuantity int `json:"minimumQuantity"`
	// Money value that applies when the `minimumQuantity` is greater than or equal to the [LineItem](ctp:api:type:LineItem) `quantity`.
	//
	// The `currencyCode` of a Price tier is always the same as the `currencyCode` in the `value` of the related Price.
	Value TypedMoney `json:"value"`
}

* * A Price tier is selected instead of the default Price when a certain quantity of the ProductVariant(ctp:api:type:ProductVariant) is [added to a Cart](/projects/carts#add-lineitem) and ordered. * _For example: the Price can be lower if more than 10 items are ordered._ * If no Price tier is found for the Order quantity, the base Price is used. * A Price tier is applied for the entire quantity of a Product Variant put as LineItem(/projects/carts#lineitem) in a Cart as soon as the minimum quantity for the Price tier is reached. * The Price tier is applied per Line Item of the Product Variant. If, for example, the same Product Variant appears in the same Cart as several Line Items, (what can be achieved by different values of a Custom Field on the Line Items) for each Line Item the minimum quantity must be reached to get the Price tier. *

func (*PriceTier) UnmarshalJSON ¶

func (obj *PriceTier) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type PriceTierDraft ¶

type PriceTierDraft struct {
	// Minimum quantity this Price tier is valid for.
	//
	// The minimum quantity is always greater than or equal to 2. The base Price is interpreted as valid for a minimum quantity equal to 1.
	// A [Price](ctp:api:type:Price) or [StandalonePrice](ctp:api:type:StandalonePrice) cannot contain more than one tier with the same `minimumQuantity`.
	// In the case one of the constraint is not met an [InvalidField](ctp:api:type:InvalidFieldError) is returned.
	MinimumQuantity int `json:"minimumQuantity"`
	// Money value that applies when the `minimumQuantity` is greater than or equal to the [LineItem](ctp:api:type:LineItem) `quantity`.
	//
	// The `currencyCode` of a Price tier must be the same as the `currencyCode` in the `value` of the related Price.
	Value Money `json:"value"`
}

* * Specifies a Price tier that applies when the minimum quantity for the LineItem(ctp:api:type:LineItem) of a ProductVariant with the related Price is reached in a Cart. *

type Product ¶

type Product struct {
	// Unique identifier of the Product.
	ID string `json:"id"`
	// Current version of the Product.
	Version int `json:"version"`
	// Date and time (UTC) the Product was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Product was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the Product.
	//
	// This is different from the `key` of a [ProductVariant](ctp:api:type:ProductVariant).
	Key *string `json:"key,omitempty"`
	// The Product Type defining the Attributes of the Product. Cannot be changed.
	ProductType ProductTypeReference `json:"productType"`
	// Contains the current and the staged representation of the product information.
	MasterData ProductCatalogData `json:"masterData"`
	// The [TaxCategory](ctp:api:type:TaxCategory) of the Product.
	TaxCategory *TaxCategoryReference `json:"taxCategory,omitempty"`
	// [State](ctp:api:type:State) of the Product.
	State *StateReference `json:"state,omitempty"`
	// Review statistics of the Product.
	ReviewRatingStatistics *ReviewRatingStatistics `json:"reviewRatingStatistics,omitempty"`
	// Type of Price to be used when looking up a price for the Product.
	PriceMode *ProductPriceModeEnum `json:"priceMode,omitempty"`
}

* * An abstract sellable good with a set of Attributes defined by a Product Type. * Products themselves are not sellable. Instead, they act as a parent structure for Product Variants. * Each Product must have at least one Product Variant, which is called the Master Variant. * A single Product representation contains the _current_ and the _staged_ representation of its product data. *

type ProductAddAssetAction ¶

type ProductAddAssetAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged `assets` are updated. If `false`, both the current and staged `assets` are updated.
	Staged *bool `json:"staged,omitempty"`
	// Value to append.
	Asset AssetDraft `json:"asset"`
	// Position in `assets` where the Asset should be put. When specified, the value must be between `0` and the total number of Assets minus `1`.
	Position *int `json:"position,omitempty"`
}

* * Either `variantId` or `sku` is required. *

func (ProductAddAssetAction) MarshalJSON ¶

func (obj ProductAddAssetAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductAddExternalImageAction ¶

type ProductAddExternalImageAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// Value to add to `images`.
	Image Image `json:"image"`
	// If `true`, only the staged `images` is updated. If `false`, both the current and staged `images` is updated.
	Staged *bool `json:"staged,omitempty"`
}

* * Either `variantId` or `sku` is required. Produces the [ProductImageAdded](/projects/messages#product-image-added) Message. *

func (ProductAddExternalImageAction) MarshalJSON ¶

func (obj ProductAddExternalImageAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductAddPriceAction ¶

type ProductAddPriceAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// Embedded Price to add to the Product Variant.
	Price PriceDraft `json:"price"`
	// If `true`, only the staged `prices` is updated. If `false`, both the current and staged `prices` are updated.
	Staged *bool `json:"staged,omitempty"`
}

* * Adds the given Price to the `prices` array of the ProductVariant(ctp:api:type:ProductVariant). * Either `variantId` or `sku` is required. *

func (ProductAddPriceAction) MarshalJSON ¶

func (obj ProductAddPriceAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductAddToCategoryAction ¶

type ProductAddToCategoryAction struct {
	// The Category to add.
	Category CategoryResourceIdentifier `json:"category"`
	// A string representing a number between 0 and 1. Must start with `0.` and cannot end with `0`. If empty, any existing value will be removed.
	OrderHint *string `json:"orderHint,omitempty"`
	// If `true`, only the staged `categories` and `categoryOrderHints` are updated. If `false`, both the current and staged `categories` and `categoryOrderHints` are updated.
	Staged *bool `json:"staged,omitempty"`
}

* * Produces the [ProductAddedToCategory](/projects/messages#product-added-to-category) Message.

func (ProductAddToCategoryAction) MarshalJSON ¶

func (obj ProductAddToCategoryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductAddVariantAction ¶

type ProductAddVariantAction struct {
	// Value to set. Must be unique.
	Sku *string `json:"sku,omitempty"`
	// Value to set. Must be unique.
	Key *string `json:"key,omitempty"`
	// Embedded Prices for the Product Variant.
	Prices []PriceDraft `json:"prices"`
	// Images for the Product Variant.
	Images []Image `json:"images"`
	// Attributes for the Product Variant.
	Attributes []Attribute `json:"attributes"`
	// If `true` the new Product Variant is only staged. If `false` the new Product Variant is both current and staged.
	Staged *bool `json:"staged,omitempty"`
	// Media assets for the Product Variant.
	Assets []AssetDraft `json:"assets"`
}

func (ProductAddVariantAction) MarshalJSON ¶

func (obj ProductAddVariantAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductAddedToCategoryMessage ¶

type ProductAddedToCategoryMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Category](ctp:api:type:Category) the [Product](ctp:api:type:Product) was added to.
	Category CategoryReference `json:"category"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Add To Category](ctp:api:type:ProductAddToCategoryAction) update action. *

func (ProductAddedToCategoryMessage) MarshalJSON ¶

func (obj ProductAddedToCategoryMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductAddedToCategoryMessage) UnmarshalJSON ¶

func (obj *ProductAddedToCategoryMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductAddedToCategoryMessagePayload ¶

type ProductAddedToCategoryMessagePayload struct {
	// [Category](ctp:api:type:Category) the [Product](ctp:api:type:Product) was added to.
	Category CategoryReference `json:"category"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Add To Category](ctp:api:type:ProductAddToCategoryAction) update action. *

func (ProductAddedToCategoryMessagePayload) MarshalJSON ¶

func (obj ProductAddedToCategoryMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductAssignmentMissingError ¶

type ProductAssignmentMissingError struct {
	// For Product Selection of mode Individual, the message is:
	// `"A Product Variant Selection can only be set for a Product that has previously been added to the Product Selection."`
	// For Product Selection of mode IndividualExclusion, the message is:
	// `"A Variant Exclusion can only be set for a Product that has previously been added to the Product Selection of type Individual Exclusion."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// [Reference](ctp:api:type:Reference) to the [Product](ctp:api:type:Product) for which the error was returned.
	Product ProductReference `json:"product"`
}

* * Returned when a Product is not assigned to the Product Selection. * The error is returned as a failed response either to the [Set Variant Selection](ctp:api:type:ProductSelectionSetVariantSelectionAction) or to the [Set Variant Exclusion](ctp:api:type:ProductSelectionSetVariantExclusionAction) update action. *

func (*ProductAssignmentMissingError) DecodeStruct ¶

func (obj *ProductAssignmentMissingError) DecodeStruct(src map[string]interface{}) error

func (ProductAssignmentMissingError) Error ¶

func (ProductAssignmentMissingError) MarshalJSON ¶

func (obj ProductAssignmentMissingError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductAssignmentMissingError) UnmarshalJSON ¶

func (obj *ProductAssignmentMissingError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductCatalogData ¶

type ProductCatalogData struct {
	// `true` if the Product is published.
	Published bool `json:"published"`
	// Current (published) data of the Product.
	Current ProductData `json:"current"`
	// Staged (unpublished) data of the Product.
	Staged ProductData `json:"staged"`
	// `true` if the `staged` data is different from the `current` data.
	HasStagedChanges bool `json:"hasStagedChanges"`
}

* * Contains the `current` and `staged` ProductData(ctp:api:type:ProductData). *

type ProductChangeAssetNameAction ¶

type ProductChangeAssetNameAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged Asset is updated. If `false`, both the current and staged Asset is updated.
	Staged *bool `json:"staged,omitempty"`
	// The `id` of the Asset to update.
	AssetId *string `json:"assetId,omitempty"`
	// The `key` of the Asset to update.
	AssetKey *string `json:"assetKey,omitempty"`
	// New value to set. Must not be empty.
	Name LocalizedString `json:"name"`
}

* * Either `variantId` or `sku` is required. The Asset to update must be specified using either `assetId` or `assetKey`. *

func (ProductChangeAssetNameAction) MarshalJSON ¶

func (obj ProductChangeAssetNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductChangeAssetOrderAction ¶

type ProductChangeAssetOrderAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged `assets` is updated. If `false`, both the current and staged `assets` are updated.
	Staged *bool `json:"staged,omitempty"`
	// All existing Asset `id`s of the ProductVariant in the desired new order.
	AssetOrder []string `json:"assetOrder"`
}

* * Either `variantId` or `sku` is required. *

func (ProductChangeAssetOrderAction) MarshalJSON ¶

func (obj ProductChangeAssetOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductChangeMasterVariantAction ¶

type ProductChangeMasterVariantAction struct {
	// The `id` of the ProductVariant to become the Master Variant.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to become the Master Variant.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged Master Variant is changed. If `false`, both the current and staged Master Variant are changed.
	Staged *bool `json:"staged,omitempty"`
}

* * Assigns the specified Product Variant to the `masterVariant` and removes the same from `variants` at the same time. The current Master Variant becomes part of the `variants` array. * Either `variantId` or `sku` is required. *

func (ProductChangeMasterVariantAction) MarshalJSON ¶

func (obj ProductChangeMasterVariantAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductChangeNameAction ¶

type ProductChangeNameAction struct {
	// Value to set. Must not be empty.
	Name LocalizedString `json:"name"`
	// If `true`, only the staged `name` is updated. If `false`, both the current and staged `name` are updated.
	Staged *bool `json:"staged,omitempty"`
}

func (ProductChangeNameAction) MarshalJSON ¶

func (obj ProductChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductChangePriceAction ¶

type ProductChangePriceAction struct {
	// The `id` of the Embedded Price to update.
	PriceId string `json:"priceId"`
	// Value to set.
	Price PriceDraft `json:"price"`
	// If `true`, only the staged Embedded Price is updated. If `false`, both the current and staged Embedded Price are updated.
	Staged *bool `json:"staged,omitempty"`
}

func (ProductChangePriceAction) MarshalJSON ¶

func (obj ProductChangePriceAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductChangeSlugAction ¶

type ProductChangeSlugAction struct {
	// Value to set. Must not be empty. A Product can have the same slug for different [Locales](ctp:api:type:Locale), but it must be unique across the [Project](ctp:api:type:Project). Must match the pattern `^[A-Za-z0-9_-]{2,256}+$`.
	Slug LocalizedString `json:"slug"`
	// If `true`, only the staged `slug` is updated. If `false`, both the current and staged `slug` are updated.
	Staged *bool `json:"staged,omitempty"`
}

* * Produces the [ProductSlugChanged](ctp:api:type:ProductSlugChangedMessage) Message.

func (ProductChangeSlugAction) MarshalJSON ¶

func (obj ProductChangeSlugAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductCreatedMessage ¶

type ProductCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The staged [Product Projection](ctp:api:type:ProductProjection) of the [Product](ctp:api:type:Product) at the time of creation.
	ProductProjection ProductProjection `json:"productProjection"`
}

* * Generated after a successful [Create Product](/../api/projects/products#create-product) request. *

func (ProductCreatedMessage) MarshalJSON ¶

func (obj ProductCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductCreatedMessage) UnmarshalJSON ¶

func (obj *ProductCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductCreatedMessagePayload ¶

type ProductCreatedMessagePayload struct {
	// The staged [Product Projection](ctp:api:type:ProductProjection) of the [Product](ctp:api:type:Product) at the time of creation.
	ProductProjection ProductProjection `json:"productProjection"`
}

* * Generated after a successful [Create Product](/../api/projects/products#create-product) request. *

func (ProductCreatedMessagePayload) MarshalJSON ¶

func (obj ProductCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductData ¶

type ProductData struct {
	// Name of the Product.
	Name LocalizedString `json:"name"`
	// [Categories](ctp:api:type:Category) assigned to the Product.
	Categories []CategoryReference `json:"categories"`
	// Numerical values to allow ordering of Products within a specified Category.
	CategoryOrderHints *CategoryOrderHints `json:"categoryOrderHints,omitempty"`
	// Description of the Product.
	Description *LocalizedString `json:"description,omitempty"`
	// User-defined identifier used in a deep-link URL for the Product.
	// Must be unique across a Project, but can be the same for Products in different [Locales](ctp:api:type:Locale).
	// Matches the pattern `[a-zA-Z0-9_\\-]{2,256}`.
	Slug LocalizedString `json:"slug"`
	// Title of the Product displayed in search results.
	MetaTitle *LocalizedString `json:"metaTitle,omitempty"`
	// Description of the Product displayed in search results below the meta title.
	MetaDescription *LocalizedString `json:"metaDescription,omitempty"`
	// Keywords that give additional information about the Product to search engines.
	MetaKeywords *LocalizedString `json:"metaKeywords,omitempty"`
	// The Master Variant of the Product.
	MasterVariant ProductVariant `json:"masterVariant"`
	// Additional Product Variants.
	Variants []ProductVariant `json:"variants"`
	// Used by [Product Suggestions](ctp:api:type:ProductSuggestions), but is also considered for a full text search.
	SearchKeywords SearchKeywords `json:"searchKeywords"`
}

* * Contains all the data of a Product and its Product Variants. *

type ProductDeletedMessage ¶

type ProductDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// List of image URLs that were removed during the [Delete Product](ctp:api:type:Product) request.
	RemovedImageUrls []string `json:"removedImageUrls"`
	// Current [Product Projection](ctp:api:type:ProductProjection) of the deleted [Product](ctp:api:type:Product).
	CurrentProjection *ProductProjection `json:"currentProjection,omitempty"`
}

* * Generated after a successful [Delete Product](/../api/projects/products#delete-product) request. *

func (ProductDeletedMessage) MarshalJSON ¶

func (obj ProductDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductDeletedMessage) UnmarshalJSON ¶

func (obj *ProductDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductDeletedMessagePayload ¶

type ProductDeletedMessagePayload struct {
	// List of image URLs that were removed during the [Delete Product](ctp:api:type:Product) request.
	RemovedImageUrls []string `json:"removedImageUrls"`
	// Current [Product Projection](ctp:api:type:ProductProjection) of the deleted [Product](ctp:api:type:Product).
	CurrentProjection *ProductProjection `json:"currentProjection,omitempty"`
}

* * Generated after a successful [Delete Product](/../api/projects/products#delete-product) request. *

func (ProductDeletedMessagePayload) MarshalJSON ¶

func (obj ProductDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscount ¶

type ProductDiscount struct {
	// Unique identifier of the ProductDiscount.
	ID string `json:"id"`
	// Current version of the ProductDiscount.
	Version int `json:"version"`
	// Date and time (UTC) the ProductDiscount was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the ProductDiscount was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Name of the ProductDiscount.
	Name LocalizedString `json:"name"`
	// User-defined unique identifier of the ProductDiscount.
	Key *string `json:"key,omitempty"`
	// Description of the ProductDiscount.
	Description *LocalizedString `json:"description,omitempty"`
	// Type of Discount and its corresponding value.
	Value ProductDiscountValue `json:"value"`
	// Valid [ProductDiscount predicate](/../api/projects/predicates#productdiscount-predicates).
	Predicate string `json:"predicate"`
	// Unique decimal value between 0 and 1 (stored as String literal) defining the order of Product Discounts to apply in case more than one is applicable and active.
	// A Product Discount with a higher value is prioritized.
	SortOrder string `json:"sortOrder"`
	// If `true` the Product Discount is applied to Products matching the `predicate`.
	IsActive bool `json:"isActive"`
	// References of all the resources that are addressed in the `predicate`.
	References []Reference `json:"references"`
	// Date and time (UTC) from which the Discount is effective.
	// Take [Eventual Consistency](/../api/general-concepts#eventual-consistency) into account for calculated discount values.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the Discount is effective.
	// Take [Eventual Consistency](/../api/general-concepts#eventual-consistency) into account for calculated undiscounted values.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

func (*ProductDiscount) UnmarshalJSON ¶

func (obj *ProductDiscount) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductDiscountChangeIsActiveAction ¶

type ProductDiscountChangeIsActiveAction struct {
	// New value to set.
	// If set to `true`, the Discount will be applied to Product Prices.
	IsActive bool `json:"isActive"`
}

func (ProductDiscountChangeIsActiveAction) MarshalJSON ¶

func (obj ProductDiscountChangeIsActiveAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountChangeNameAction ¶

type ProductDiscountChangeNameAction struct {
	// New value to set. Must not be empty.
	Name LocalizedString `json:"name"`
}

func (ProductDiscountChangeNameAction) MarshalJSON ¶

func (obj ProductDiscountChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountChangePredicateAction ¶

type ProductDiscountChangePredicateAction struct {
	// New value to set. Must be a valid [ProductDiscount predicate](/../api/projects/predicates#productdiscount-predicates).
	Predicate string `json:"predicate"`
}

func (ProductDiscountChangePredicateAction) MarshalJSON ¶

func (obj ProductDiscountChangePredicateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountChangeSortOrderAction ¶

type ProductDiscountChangeSortOrderAction struct {
	// New value to set.
	// Must not be empty.
	// The string value must be a number between `0` and `1`.
	// A Discount with a higher sortOrder is prioritized.
	SortOrder string `json:"sortOrder"`
}

func (ProductDiscountChangeSortOrderAction) MarshalJSON ¶

func (obj ProductDiscountChangeSortOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountChangeValueAction ¶

type ProductDiscountChangeValueAction struct {
	// New value to set. Must not be empty.
	Value ProductDiscountValueDraft `json:"value"`
}

func (ProductDiscountChangeValueAction) MarshalJSON ¶

func (obj ProductDiscountChangeValueAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductDiscountChangeValueAction) UnmarshalJSON ¶

func (obj *ProductDiscountChangeValueAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductDiscountDraft ¶

type ProductDiscountDraft struct {
	// Name of the ProductDiscount.
	Name LocalizedString `json:"name"`
	// User-defined unique identifier for the ProductDiscount.
	Key *string `json:"key,omitempty"`
	// Description of the ProductDiscount.
	Description *LocalizedString `json:"description,omitempty"`
	// Type of Discount and its corresponding value.
	Value ProductDiscountValueDraft `json:"value"`
	// Valid [ProductDiscount predicate](/../api/projects/predicates#productdiscount-predicates).
	Predicate string `json:"predicate"`
	// Decimal value between 0 and 1 (passed as String literal) that defines the order of ProductDiscounts to apply in case more than one is applicable and active. A ProductDiscount with a higher `sortOrder` is prioritized.
	// The value must be **unique** among all ProductDiscounts in the [Project](ctp:api:type:Project).
	SortOrder string `json:"sortOrder"`
	// Set to `true` to activate the ProductDiscount, set to `false` to deactivate it (even though the `predicate` matches).
	IsActive bool `json:"isActive"`
	// Date and time (UTC) from which the Discount is effective.
	// Take [Eventual Consistency](/../api/general-concepts#eventual-consistency) into account for calculated discount values.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time (UTC) until which the Discount is effective.
	// Take [Eventual Consistency](/../api/general-concepts#eventual-consistency) into account for calculated undiscounted values.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

func (*ProductDiscountDraft) UnmarshalJSON ¶

func (obj *ProductDiscountDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductDiscountMatchQuery ¶

type ProductDiscountMatchQuery struct {
	// ID of the specified Product.
	ProductId string `json:"productId"`
	// ID of the specified Product Variant.
	VariantId int `json:"variantId"`
	// Controls which [projected representation](/../api/projects/productProjections#current--staged) is applied for the query.
	// Set to `true` for the `staged` Product Projection of the specified Product Variant, set to `false` for the `current` one.
	Staged bool `json:"staged"`
	// Specified Price of the specified Product Variant.
	Price QueryPrice `json:"price"`
}

type ProductDiscountPagedQueryResponse ¶

type ProductDiscountPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [ProductDiscounts](ctp:api:type:ProductDiscount) matching the query.
	Results []ProductDiscount `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of ProductDiscount(ctp:api:type:ProductDiscount). *

type ProductDiscountReference ¶

type ProductDiscountReference struct {
	// Unique identifier of the referenced [ProductDiscount](ctp:api:type:ProductDiscount).
	ID string `json:"id"`
	// Contains the representation of the expanded ProductDiscount. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for ProductDiscounts.
	Obj *ProductDiscount `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a ProductDiscount(ctp:api:type:ProductDiscount). *

func (ProductDiscountReference) MarshalJSON ¶

func (obj ProductDiscountReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountResourceIdentifier ¶

type ProductDiscountResourceIdentifier struct {
	// Unique identifier of the referenced [ProductDiscount](ctp:api:type:ProductDiscount). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [ProductDiscount](ctp:api:type:ProductDiscount). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a ProductDiscount(ctp:api:type:ProductDiscount). *

func (ProductDiscountResourceIdentifier) MarshalJSON ¶

func (obj ProductDiscountResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountSetDescriptionAction ¶

type ProductDiscountSetDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

func (ProductDiscountSetDescriptionAction) MarshalJSON ¶

func (obj ProductDiscountSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountSetKeyAction ¶

type ProductDiscountSetKeyAction struct {
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

func (ProductDiscountSetKeyAction) MarshalJSON ¶

func (obj ProductDiscountSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountSetValidFromAction ¶

type ProductDiscountSetValidFromAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	// Take [Eventual Consistency](/../api/general-concepts#eventual-consistency) into account for calculated discount values.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
}

func (ProductDiscountSetValidFromAction) MarshalJSON ¶

func (obj ProductDiscountSetValidFromAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountSetValidFromAndUntilAction ¶

type ProductDiscountSetValidFromAndUntilAction struct {
	// Value to set.
	// Take [Eventual Consistency](/../api/general-concepts#eventual-consistency) into account for calculated undiscounted values.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Value to set.
	// Take [Eventual Consistency](/../api/general-concepts#eventual-consistency) into account for calculated undiscounted values.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

func (ProductDiscountSetValidFromAndUntilAction) MarshalJSON ¶

func (obj ProductDiscountSetValidFromAndUntilAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountSetValidUntilAction ¶

type ProductDiscountSetValidUntilAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	// Take [Eventual Consistency](/../api/general-concepts#eventual-consistency) into account for calculated undiscounted values.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

func (ProductDiscountSetValidUntilAction) MarshalJSON ¶

func (obj ProductDiscountSetValidUntilAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountUpdate ¶

type ProductDiscountUpdate struct {
	// Expected version of the ProductDiscount on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the ProductDiscount.
	Actions []ProductDiscountUpdateAction `json:"actions"`
}

func (*ProductDiscountUpdate) UnmarshalJSON ¶

func (obj *ProductDiscountUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductDiscountUpdateAction ¶

type ProductDiscountUpdateAction interface{}

type ProductDiscountValue ¶

type ProductDiscountValue interface{}

type ProductDiscountValueAbsolute ¶

type ProductDiscountValueAbsolute struct {
	// Money values in different currencies. An absolute [ProductDiscount](ctp:api:type:ProductDiscount) will only match a price if this array contains a value with the same currency. For example, if it contains 10€ and 15$, the matching € price will be decreased by 10€ and the matching $ price will be decreased by 15\$.
	Money []CentPrecisionMoney `json:"money"`
}

* * Discounts the Product's Price by a fixed amount, defined by the `money` field.

func (ProductDiscountValueAbsolute) MarshalJSON ¶

func (obj ProductDiscountValueAbsolute) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountValueAbsoluteDraft ¶

type ProductDiscountValueAbsoluteDraft struct {
	// Money values in different currencies. An absolute [ProductDiscount](ctp:api:type:ProductDiscount) will only match a price if this array contains a value with the same currency. For example, if it contains 10€ and 15$, the matching € price will be decreased by 10€ and the matching $ price will be decreased by 15\$.
	Money []Money `json:"money"`
}

* * Discounts the Product Price by a fixed amount, defined by the `money` field. *

func (ProductDiscountValueAbsoluteDraft) MarshalJSON ¶

func (obj ProductDiscountValueAbsoluteDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountValueDraft ¶

type ProductDiscountValueDraft interface{}

type ProductDiscountValueExternal ¶

type ProductDiscountValueExternal struct {
}

* * Discounts the Product Price by allowing the client to explicitly [set a discounted value](ctp:api:type:ProductSetDiscountedPriceAction). * Used when setting discounts using an external service. *

func (ProductDiscountValueExternal) MarshalJSON ¶

func (obj ProductDiscountValueExternal) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountValueExternalDraft ¶

type ProductDiscountValueExternalDraft struct {
}

* * Discounts the Product Price by allowing the client to explicitly [set a discounted value](ctp:api:type:ProductSetDiscountedPriceAction). * Use this when setting discounts using an external service. *

func (ProductDiscountValueExternalDraft) MarshalJSON ¶

func (obj ProductDiscountValueExternalDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountValueRelative ¶

type ProductDiscountValueRelative struct {
	// Fraction (per ten thousand) the price is reduced by. For example, `1000` will result in a 10% price reduction.
	Permyriad int `json:"permyriad"`
}

* * Discounts the product price by a percentage, defined by the `permyriad` field.

func (ProductDiscountValueRelative) MarshalJSON ¶

func (obj ProductDiscountValueRelative) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDiscountValueRelativeDraft ¶

type ProductDiscountValueRelativeDraft struct {
	// Fraction (per ten thousand) the price is reduced by. For example, `1000` will result in a 10% price reduction.
	Permyriad int `json:"permyriad"`
}

* * Discounts the Product Price by a percentage, defined by the `permyriad` field. *

func (ProductDiscountValueRelativeDraft) MarshalJSON ¶

func (obj ProductDiscountValueRelativeDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductDraft ¶

type ProductDraft struct {
	// The Product Type defining the Attributes for the Product. Cannot be changed later.
	ProductType ProductTypeResourceIdentifier `json:"productType"`
	// Name of the Product.
	Name LocalizedString `json:"name"`
	// User-defined identifier used in a deep-link URL for the Product.
	// It must be unique across a Project, but a Product can have the same slug in different [Locales](ctp:api:type:Locale).
	// It must match the pattern `[a-zA-Z0-9_\\-]{2,256}`.
	Slug LocalizedString `json:"slug"`
	// User-defined unique identifier for the Product.
	Key *string `json:"key,omitempty"`
	// Description of the Product.
	Description *LocalizedString `json:"description,omitempty"`
	// Categories assigned to the Product.
	Categories []CategoryResourceIdentifier `json:"categories"`
	// Numerical values to allow ordering of Products within a specified Category.
	CategoryOrderHints *CategoryOrderHints `json:"categoryOrderHints,omitempty"`
	// Title of the Product displayed in search results.
	MetaTitle *LocalizedString `json:"metaTitle,omitempty"`
	// Description of the Product displayed in search results.
	MetaDescription *LocalizedString `json:"metaDescription,omitempty"`
	// Keywords that give additional information about the Product to search engines.
	MetaKeywords *LocalizedString `json:"metaKeywords,omitempty"`
	// The Product Variant to be the Master Variant for the Product. Required if `variants` are provided also.
	MasterVariant *ProductVariantDraft `json:"masterVariant,omitempty"`
	// The additional Product Variants for the Product.
	Variants []ProductVariantDraft `json:"variants"`
	// The Tax Category to be assigned to the Product.
	TaxCategory *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
	// Used by [Product Suggestions](ctp:api:type:ProductSuggestions), but is also considered for a [full text search](/projects/products-search#full-text-search).
	SearchKeywords *SearchKeywords `json:"searchKeywords,omitempty"`
	// State to be assigned to the Product.
	State *StateResourceIdentifier `json:"state,omitempty"`
	// If `true`, the Product is published immediately to the current projection.
	Publish *bool `json:"publish,omitempty"`
	// Specifies the type of prices used when looking up a price for the Product.
	PriceMode *ProductPriceModeEnum `json:"priceMode,omitempty"`
}

func (ProductDraft) MarshalJSON ¶

func (obj ProductDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductImageAddedMessage ¶

type ProductImageAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Product Variant](ctp:api:type:ProductVariant) to which the [Image](ctp:api:type:Image) was added.
	VariantId int `json:"variantId"`
	// [Image](ctp:api:type:Image) that was added.
	Image Image `json:"image"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Add External Image](ctp:api:type:ProductAddExternalImageAction) update action or after the successful [upload of an image](/../api/projects/products#upload-product-image). *

func (ProductImageAddedMessage) MarshalJSON ¶

func (obj ProductImageAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductImageAddedMessage) UnmarshalJSON ¶

func (obj *ProductImageAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductImageAddedMessagePayload ¶

type ProductImageAddedMessagePayload struct {
	// Unique identifier of the [Product Variant](ctp:api:type:ProductVariant) to which the [Image](ctp:api:type:Image) was added.
	VariantId int `json:"variantId"`
	// [Image](ctp:api:type:Image) that was added.
	Image Image `json:"image"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Add External Image](ctp:api:type:ProductAddExternalImageAction) update action or after the successful [upload of an image](/../api/projects/products#upload-product-image). *

func (ProductImageAddedMessagePayload) MarshalJSON ¶

func (obj ProductImageAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductLegacySetSkuAction ¶

type ProductLegacySetSkuAction struct {
	Sku       *string `json:"sku,omitempty"`
	VariantId int     `json:"variantId"`
}

func (ProductLegacySetSkuAction) MarshalJSON ¶

func (obj ProductLegacySetSkuAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductMoveImageToPositionAction ¶

type ProductMoveImageToPositionAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// The URL of the image to update.
	ImageUrl string `json:"imageUrl"`
	// Position in `images` where the image should be moved. Must be between `0` and the total number of images minus `1`.
	Position int `json:"position"`
	// If `true`, only the staged `images` is updated. If `false`, both the current and staged `images` is updated.
	Staged *bool `json:"staged,omitempty"`
}

* * Either `variantId` or `sku` is required. *

func (ProductMoveImageToPositionAction) MarshalJSON ¶

func (obj ProductMoveImageToPositionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductPagedQueryResponse ¶

type ProductPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](ctp:api:type:QueryPredicate), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [Products](ctp:api:type:Product) matching the query.
	Results []Product `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of Product(ctp:api:type:Product). *

type ProductPresentWithDifferentVariantSelectionError ¶

type ProductPresentWithDifferentVariantSelectionError struct {
	// `"Product is already present with the following different $variantSelections."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// [Reference](ctp:api:type:Reference) to the [Product](ctp:api:type:Product) for which the error was returned.
	Product ProductReference `json:"product"`
	// Existing Product Variant Selection or Exclusion for the [Product](/../api/projects/products) in the [Product Selection](/../api/projects/product-selections).
	ExistingVariantSelection ProductVariantSelection `json:"existingVariantSelection"`
}

* * Returned when a Product is already assigned to a [Product Selection](/../api/projects/product-selections), but the Product Selection has either a different [Product Variant Selection](ctp:api:type:ProductVariantSelection) or a different [Product Variant Exclusion](ctp:api:type:ProductVariantExclusion). * * The error is returned as a failed response either to the [Add Product](ctp:api:type:ProductSelectionAddProductAction) or to the [Exclude Product](ctp:api:type:ProductSelectionExcludeProductAction) update action. *

func (*ProductPresentWithDifferentVariantSelectionError) DecodeStruct ¶

func (obj *ProductPresentWithDifferentVariantSelectionError) DecodeStruct(src map[string]interface{}) error

func (ProductPresentWithDifferentVariantSelectionError) Error ¶

func (ProductPresentWithDifferentVariantSelectionError) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductPresentWithDifferentVariantSelectionError) UnmarshalJSON ¶

func (obj *ProductPresentWithDifferentVariantSelectionError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductPriceAddedMessage ¶

type ProductPriceAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [ProductVariant](ctp:api:type:ProductVariant) for which the Price was added.
	VariantId int `json:"variantId"`
	// The [Embedded Price](/projects/products#embedded-price) that was added to the [ProductVariant](ctp:api:type:ProductVariant).
	Price Price `json:"price"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Add Embedded Price](ctp:api:type:ProductAddPriceAction) update action. *

func (ProductPriceAddedMessage) MarshalJSON ¶

func (obj ProductPriceAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductPriceAddedMessage) UnmarshalJSON ¶

func (obj *ProductPriceAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductPriceAddedMessagePayload ¶

type ProductPriceAddedMessagePayload struct {
	// Unique identifier of the [ProductVariant](ctp:api:type:ProductVariant) for which the Price was added.
	VariantId int `json:"variantId"`
	// The [Embedded Price](/projects/products#embedded-price) that was added to the [ProductVariant](ctp:api:type:ProductVariant).
	Price Price `json:"price"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Add Embedded Price](ctp:api:type:ProductAddPriceAction) update action. *

func (ProductPriceAddedMessagePayload) MarshalJSON ¶

func (obj ProductPriceAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductPriceChangedMessage ¶

type ProductPriceChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [ProductVariant](ctp:api:type:ProductVariant) for which the Price was changed.
	VariantId int `json:"variantId"`
	// The current [Embedded Price](/projects/products#embedded-price) before the [Change Embedded Price](ctp:api:type:ProductChangePriceAction) update action.
	OldPrice Price `json:"oldPrice"`
	// The [Embedded Price](/projects/products#embedded-price) after the [Change Embedded Price](ctp:api:type:ProductChangePriceAction) update action.
	NewPrice Price `json:"newPrice"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
	// The staged [Embedded Price](/projects/products#embedded-price) before the [Change Embedded Price](ctp:api:type:ProductChangePriceAction) update action.
	OldStagedPrice *Price `json:"oldStagedPrice,omitempty"`
}

* * Generated after a successful [Change Embedded Price](ctp:api:type:ProductChangePriceAction) update action. *

func (ProductPriceChangedMessage) MarshalJSON ¶

func (obj ProductPriceChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductPriceChangedMessage) UnmarshalJSON ¶

func (obj *ProductPriceChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductPriceChangedMessagePayload ¶

type ProductPriceChangedMessagePayload struct {
	// Unique identifier of the [ProductVariant](ctp:api:type:ProductVariant) for which the Price was changed.
	VariantId int `json:"variantId"`
	// The current [Embedded Price](/projects/products#embedded-price) before the [Change Embedded Price](ctp:api:type:ProductChangePriceAction) update action.
	OldPrice Price `json:"oldPrice"`
	// The [Embedded Price](/projects/products#embedded-price) after the [Change Embedded Price](ctp:api:type:ProductChangePriceAction) update action.
	NewPrice Price `json:"newPrice"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
	// The staged [Embedded Price](/projects/products#embedded-price) before the [Change Embedded Price](ctp:api:type:ProductChangePriceAction) update action.
	OldStagedPrice *Price `json:"oldStagedPrice,omitempty"`
}

* * Generated after a successful [Change Embedded Price](ctp:api:type:ProductChangePriceAction) update action. *

func (ProductPriceChangedMessagePayload) MarshalJSON ¶

func (obj ProductPriceChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductPriceDiscountsSetMessage ¶

type ProductPriceDiscountsSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Array containing details about the [Embedded Prices](ctp:api:type:Price) that were updated.
	UpdatedPrices []ProductPriceDiscountsSetUpdatedPrice `json:"updatedPrices"`
}

* * Generated after a Price is updated due to a [Product Discount](ctp:api:type:ProductDiscount). *

func (ProductPriceDiscountsSetMessage) MarshalJSON ¶

func (obj ProductPriceDiscountsSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductPriceDiscountsSetMessage) UnmarshalJSON ¶

func (obj *ProductPriceDiscountsSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductPriceDiscountsSetMessagePayload ¶

type ProductPriceDiscountsSetMessagePayload struct {
	// Array containing details about the [Embedded Prices](ctp:api:type:Price) that were updated.
	UpdatedPrices []ProductPriceDiscountsSetUpdatedPrice `json:"updatedPrices"`
}

* * Generated after a Price is updated due to a [Product Discount](ctp:api:type:ProductDiscount). *

func (ProductPriceDiscountsSetMessagePayload) MarshalJSON ¶

func (obj ProductPriceDiscountsSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductPriceDiscountsSetUpdatedPrice ¶

type ProductPriceDiscountsSetUpdatedPrice struct {
	// Unique identifier of the [ProductVariant](ctp:api:type:ProductVariant) for which the Discount was set.
	VariantId int `json:"variantId"`
	// Key of the [ProductVariant](ctp:api:type:ProductVariant) for which Discount was set.
	VariantKey *string `json:"variantKey,omitempty"`
	// SKU of the [ProductVariant](ctp:api:type:ProductVariant) for which Discount was set.
	Sku *string `json:"sku,omitempty"`
	// Unique identifier of the [Price](ctp:api:type:Price).
	PriceId string `json:"priceId"`
	// Discounted Price for the [ProductVariant](ctp:api:type:ProductVariant) for which Discount was set.
	Discounted *DiscountedPrice `json:"discounted,omitempty"`
	// Whether the update was only applied to the staged [ProductProjection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Details about a [Embedded Price](/projects/products#embedded-price) that was updated due to a Discount. Specific to [ProductPriceDiscountsSet](ctp:api:type:ProductPriceDiscountsSetMessage) Message. *

type ProductPriceExternalDiscountSetMessage ¶

type ProductPriceExternalDiscountSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Product Variant](ctp:api:type:ProductVariant) for which the Discount was set.
	VariantId int `json:"variantId"`
	// Key of the [Product Variant](ctp:api:type:ProductVariant) for which the Discount was set.
	VariantKey *string `json:"variantKey,omitempty"`
	// SKU of the [Product Variant](ctp:api:type:ProductVariant) for which Discount was set.
	Sku *string `json:"sku,omitempty"`
	// Unique identifier of the [Price](ctp:api:type:Price).
	PriceId string `json:"priceId"`
	// Discounted Price for the [Product Variant](ctp:api:type:ProductVariant) for which Discount was set.
	Discounted *DiscountedPrice `json:"discounted,omitempty"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Set Discounted Embedded Price](ctp:api:type:ProductSetDiscountedPriceAction) update action. *

func (ProductPriceExternalDiscountSetMessage) MarshalJSON ¶

func (obj ProductPriceExternalDiscountSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductPriceExternalDiscountSetMessage) UnmarshalJSON ¶

func (obj *ProductPriceExternalDiscountSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductPriceExternalDiscountSetMessagePayload ¶

type ProductPriceExternalDiscountSetMessagePayload struct {
	// Unique identifier of the [Product Variant](ctp:api:type:ProductVariant) for which the Discount was set.
	VariantId int `json:"variantId"`
	// Key of the [Product Variant](ctp:api:type:ProductVariant) for which the Discount was set.
	VariantKey *string `json:"variantKey,omitempty"`
	// SKU of the [Product Variant](ctp:api:type:ProductVariant) for which Discount was set.
	Sku *string `json:"sku,omitempty"`
	// Unique identifier of the [Price](ctp:api:type:Price).
	PriceId string `json:"priceId"`
	// Discounted Price for the [Product Variant](ctp:api:type:ProductVariant) for which Discount was set.
	Discounted *DiscountedPrice `json:"discounted,omitempty"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Set Discounted Embedded Price](ctp:api:type:ProductSetDiscountedPriceAction) update action. *

func (ProductPriceExternalDiscountSetMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductPriceKeySetMessage ¶

type ProductPriceKeySetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	VariantId                       int                      `json:"variantId"`
	// Unique identifier of the [Price](ctp:api:type:Price).
	PriceId *string `json:"priceId,omitempty"`
	// `key` value of the [Price](ctp:api:type:Price) before the [Set Price Key](ctp:api:type:ProductSetPriceKeyAction) update action.
	OldKey *string `json:"oldKey,omitempty"`
	// `key` value of the [Price](ctp:api:type:Price) after the [Set Price Key](ctp:api:type:ProductSetPriceKeyAction) update action.
	Key *string `json:"key,omitempty"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Set Price Key](ctp:api:type:ProductSetPriceKeyAction) update action. *

func (ProductPriceKeySetMessage) MarshalJSON ¶

func (obj ProductPriceKeySetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductPriceKeySetMessage) UnmarshalJSON ¶

func (obj *ProductPriceKeySetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductPriceKeySetMessagePayload ¶

type ProductPriceKeySetMessagePayload struct {
	VariantId int `json:"variantId"`
	// Unique identifier of the [Price](ctp:api:type:Price).
	PriceId *string `json:"priceId,omitempty"`
	// `key` value of the [Price](ctp:api:type:Price) before the [Set Price Key](ctp:api:type:ProductSetPriceKeyAction) update action.
	OldKey *string `json:"oldKey,omitempty"`
	// `key` value of the [Price](ctp:api:type:Price) after the [Set Price Key](ctp:api:type:ProductSetPriceKeyAction) update action.
	Key *string `json:"key,omitempty"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Set Price Key](ctp:api:type:ProductSetPriceKeyAction) update action. *

func (ProductPriceKeySetMessagePayload) MarshalJSON ¶

func (obj ProductPriceKeySetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductPriceModeEnum ¶

type ProductPriceModeEnum string

* * This mode determines the type of Prices used for [Product Price Selection](ctp:api:type:ProductPriceSelection) and for [LineItem Price selection](ctp:api:type:LineItemPriceSelection). *

const (
	ProductPriceModeEnumEmbedded   ProductPriceModeEnum = "Embedded"
	ProductPriceModeEnumStandalone ProductPriceModeEnum = "Standalone"
)

type ProductPriceModeSetMessage ¶

type ProductPriceModeSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [PriceMode](ctp:api:type:ProductPriceModeEnum) that was set.
	To ProductPriceModeEnum `json:"to"`
}

* * Generated after a successful [Set PriceMode](ctp:api:type:ProductSetPriceModeAction) update action. *

func (ProductPriceModeSetMessage) MarshalJSON ¶

func (obj ProductPriceModeSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductPriceModeSetMessage) UnmarshalJSON ¶

func (obj *ProductPriceModeSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductPriceModeSetMessagePayload ¶

type ProductPriceModeSetMessagePayload struct {
	// The [PriceMode](ctp:api:type:ProductPriceModeEnum) that was set.
	To ProductPriceModeEnum `json:"to"`
}

* * Generated after a successful [Set PriceMode](ctp:api:type:ProductSetPriceModeAction) update action. *

func (ProductPriceModeSetMessagePayload) MarshalJSON ¶

func (obj ProductPriceModeSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductPriceRemovedMessage ¶

type ProductPriceRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [ProductVariant](ctp:api:type:ProductVariant) for which the Price was removed.
	VariantId int `json:"variantId"`
	// The [Embedded Price](/projects/products#embedded-price) that was removed from the [ProductVariant](ctp:api:type:ProductVariant).
	Price Price `json:"price"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Remove Embedded Price](ctp:api:type:ProductRemovePriceAction) update action. *

func (ProductPriceRemovedMessage) MarshalJSON ¶

func (obj ProductPriceRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductPriceRemovedMessage) UnmarshalJSON ¶

func (obj *ProductPriceRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductPriceRemovedMessagePayload ¶

type ProductPriceRemovedMessagePayload struct {
	// Unique identifier of the [ProductVariant](ctp:api:type:ProductVariant) for which the Price was removed.
	VariantId int `json:"variantId"`
	// The [Embedded Price](/projects/products#embedded-price) that was removed from the [ProductVariant](ctp:api:type:ProductVariant).
	Price Price `json:"price"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Remove Embedded Price](ctp:api:type:ProductRemovePriceAction) update action. *

func (ProductPriceRemovedMessagePayload) MarshalJSON ¶

func (obj ProductPriceRemovedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductPricesSetMessage ¶

type ProductPricesSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [ProductVariant](ctp:api:type:ProductVariant) for which the Price was set.
	VariantId int `json:"variantId"`
	// The [Embedded Prices](ctp:api:type:Price) that were set on the [ProductVariant](ctp:api:type:ProductVariant).
	Prices []Price `json:"prices"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Set Embedded Prices](ctp:api:type:ProductSetPricesAction) update action. *

func (ProductPricesSetMessage) MarshalJSON ¶

func (obj ProductPricesSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductPricesSetMessage) UnmarshalJSON ¶

func (obj *ProductPricesSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductPricesSetMessagePayload ¶

type ProductPricesSetMessagePayload struct {
	// Unique identifier of the [ProductVariant](ctp:api:type:ProductVariant) for which the Price was set.
	VariantId int `json:"variantId"`
	// The [Embedded Prices](ctp:api:type:Price) that were set on the [ProductVariant](ctp:api:type:ProductVariant).
	Prices []Price `json:"prices"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Set Embedded Prices](ctp:api:type:ProductSetPricesAction) update action. *

func (ProductPricesSetMessagePayload) MarshalJSON ¶

func (obj ProductPricesSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductProjection ¶

type ProductProjection struct {
	// Unique identifier of the [Product](ctp:api:type:Product).
	ID string `json:"id"`
	// Current version of the [Product](ctp:api:type:Product).
	Version int `json:"version"`
	// Date and time (UTC) the ProductProjection was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the ProductProjection was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// User-defined unique identifier of the [Product](ctp:api:type:Product).
	Key *string `json:"key,omitempty"`
	// The [ProductType](ctp:api:type:ProductType) defining the Attributes of the [Product](ctp:api:type:Product).
	ProductType ProductTypeReference `json:"productType"`
	// Name of the [Product](ctp:api:type:Product).
	Name LocalizedString `json:"name"`
	// Description of the [Product](ctp:api:type:Product).
	Description *LocalizedString `json:"description,omitempty"`
	// User-defined identifier used in a deep-link URL for the [Product](ctp:api:type:Product).
	// Must be unique across a Project, but can be the same for Products in different locales.
	// Matches the pattern `[a-zA-Z0-9_\-]{2,256}`.
	// For [good performance](/../api/predicates/query#performance-considerations), indexes are provided for the first 15 `languages` set in the [Project](ctp:api:type:Project).
	Slug LocalizedString `json:"slug"`
	// [Categories](ctp:api:type:Category) assigned to the [Product](ctp:api:type:Product).
	Categories []CategoryReference `json:"categories"`
	// Order of [Product](ctp:api:type:Product) in [Categories](ctp:api:type:Category).
	CategoryOrderHints *CategoryOrderHints `json:"categoryOrderHints,omitempty"`
	// Title of the [Product](ctp:api:type:Product) displayed in search results.
	MetaTitle *LocalizedString `json:"metaTitle,omitempty"`
	// Description of the [Product](ctp:api:type:Product) displayed in search results below the meta title.
	MetaDescription *LocalizedString `json:"metaDescription,omitempty"`
	// Keywords that give additional information about the [Product](ctp:api:type:Product) to search engines.
	MetaKeywords *LocalizedString `json:"metaKeywords,omitempty"`
	// Used by [Product Suggestions](/../api/projects/products-suggestions), but is also considered for a [full text search](ctp:api:type:FullTextSearch).
	SearchKeywords *SearchKeywords `json:"searchKeywords,omitempty"`
	// `true` if the staged data is different from the current data.
	HasStagedChanges *bool `json:"hasStagedChanges,omitempty"`
	// `true` if the [Product](ctp:api:type:Product) is [published](ctp:api:type:CurrentStaged).
	Published *bool `json:"published,omitempty"`
	// The Master Variant of the [Product](ctp:api:type:Product).
	MasterVariant ProductVariant `json:"masterVariant"`
	// Additional Product Variants.
	Variants []ProductVariant `json:"variants"`
	// The [TaxCategory](ctp:api:type:TaxCategory) of the [Product](ctp:api:type:Product).
	TaxCategory *TaxCategoryReference `json:"taxCategory,omitempty"`
	// [State](ctp:api:type:State) of the [Product](ctp:api:type:Product).
	State *StateReference `json:"state,omitempty"`
	// Review statistics of the [Product](ctp:api:type:Product).
	ReviewRatingStatistics *ReviewRatingStatistics `json:"reviewRatingStatistics,omitempty"`
	// Indicates whether the Prices of the Product Projection are [embedded](ctp:api:type:Price) or [standalone](ctp:api:type:StandalonePrice). [Projecting Prices](#prices) only works with `Embedded`, there is currently no support for `Standalone`.
	PriceMode *ProductPriceModeEnum `json:"priceMode,omitempty"`
}

type ProductProjectionPagedQueryResponse ¶

type ProductProjectionPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// [ProductProjections](ctp:api:type:ProductProjection) matching the query.
	Results []ProductProjection `json:"results"`
}

type ProductProjectionPagedSearchResponse ¶

type ProductProjectionPagedSearchResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int  `json:"limit"`
	Count int  `json:"count"`
	Total *int `json:"total,omitempty"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset  int                 `json:"offset"`
	Results []ProductProjection `json:"results"`
	Facets  FacetResults        `json:"facets"`
}

type ProductPublishAction ¶

type ProductPublishAction struct {
	// `All` or `Prices`
	Scope *ProductPublishScope `json:"scope,omitempty"`
}

* * Publishes product data from the Product's staged projection to its current projection. * Produces the [ProductPublished](ctp:api:type:ProductPublishedMessage) Message.

func (ProductPublishAction) MarshalJSON ¶

func (obj ProductPublishAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductPublishScope ¶

type ProductPublishScope string

* * The scope controls which part of the product information is published.

const (
	ProductPublishScopeAll    ProductPublishScope = "All"
	ProductPublishScopePrices ProductPublishScope = "Prices"
)

type ProductPublishedMessage ¶

type ProductPublishedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// List of image URLs which were removed during the [Publish](ctp:api:type:ProductPublishAction) update action.
	RemovedImageUrls []string `json:"removedImageUrls"`
	// Current [Product Projection](ctp:api:type:ProductProjection) of the [Product](ctp:api:type:Product) at the time of creation.
	ProductProjection ProductProjection `json:"productProjection"`
	// [Publishing Scope](ctp:api:type:ProductPublishScope) that was used during the [Publish](ctp:api:type:ProductPublishAction) update action.
	Scope ProductPublishScope `json:"scope"`
}

* * Generated after a successful [Publish](ctp:api:type:ProductPublishAction) update action. *

func (ProductPublishedMessage) MarshalJSON ¶

func (obj ProductPublishedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductPublishedMessage) UnmarshalJSON ¶

func (obj *ProductPublishedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductPublishedMessagePayload ¶

type ProductPublishedMessagePayload struct {
	// List of image URLs which were removed during the [Publish](ctp:api:type:ProductPublishAction) update action.
	RemovedImageUrls []string `json:"removedImageUrls"`
	// Current [Product Projection](ctp:api:type:ProductProjection) of the [Product](ctp:api:type:Product) at the time of creation.
	ProductProjection ProductProjection `json:"productProjection"`
	// [Publishing Scope](ctp:api:type:ProductPublishScope) that was used during the [Publish](ctp:api:type:ProductPublishAction) update action.
	Scope ProductPublishScope `json:"scope"`
}

* * Generated after a successful [Publish](ctp:api:type:ProductPublishAction) update action. *

func (ProductPublishedMessagePayload) MarshalJSON ¶

func (obj ProductPublishedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductReference ¶

type ProductReference struct {
	// Unique identifier of the referenced [Product](ctp:api:type:Product).
	ID string `json:"id"`
	// Contains the representation of the expanded Product. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for Products.
	Obj *Product `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a Product(ctp:api:type:Product). *

func (ProductReference) MarshalJSON ¶

func (obj ProductReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductRemoveAssetAction ¶

type ProductRemoveAssetAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged Asset is removed. If `false`, both the current and staged Asset is removed.
	Staged *bool `json:"staged,omitempty"`
	// The `id` of the Asset to remove.
	AssetId *string `json:"assetId,omitempty"`
	// The `key` of the Asset to remove.
	AssetKey *string `json:"assetKey,omitempty"`
}

* * Either `variantId` or `sku` is required. The Asset to remove must be specified using either `assetId` or `assetKey`. *

func (ProductRemoveAssetAction) MarshalJSON ¶

func (obj ProductRemoveAssetAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductRemoveFromCategoryAction ¶

type ProductRemoveFromCategoryAction struct {
	// The Category to remove.
	Category CategoryResourceIdentifier `json:"category"`
	// If `true`, only the staged `categories` and `categoryOrderHints` are removed. If `false`, both the current and staged `categories` and `categoryOrderHints` are removed.
	Staged *bool `json:"staged,omitempty"`
}

* * Produces the [ProductRemovedFromCategory](ctp:api:type:ProductRemovedFromCategoryMessage) Message.

func (ProductRemoveFromCategoryAction) MarshalJSON ¶

func (obj ProductRemoveFromCategoryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductRemoveImageAction ¶

type ProductRemoveImageAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// The URL of the image to remove.
	ImageUrl string `json:"imageUrl"`
	// If `true`, only the staged image is removed. If `false`, both the current and staged image is removed.
	Staged *bool `json:"staged,omitempty"`
}

* * Removes a Product image and deletes it from the Content Delivery Network (external images are not deleted). Deletion from the CDN is not instant, which means the image file itself will stay available for some time after the deletion. Either `variantId` or `sku` is required. *

func (ProductRemoveImageAction) MarshalJSON ¶

func (obj ProductRemoveImageAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductRemovePriceAction ¶

type ProductRemovePriceAction struct {
	// The `id` of the Embedded Price to remove.
	PriceId string `json:"priceId"`
	// The `sku` of the ProductVariant the provided Price should be removed from.
	// Either 'variantId' or 'sku' is required" when `priceId` is not provided.
	// This field is now deprecated, use 'priceId' instead.
	Sku *string `json:"sku,omitempty"`
	// The `id` of the ProductVariant the provided Price should be removed from.
	// Either 'variantId' or 'sku' is required" when `priceId` is not provided.
	// This field is now deprecated, use 'priceId' instead.
	VariantId *int `json:"variantId,omitempty"`
	// The Price identical to the one to be removed from the ProductVariant.
	// This field is now deprecated, use 'priceId' instead.
	Price *PriceDraft `json:"price,omitempty"`
	// If `true`, only the staged Embedded Price is removed. If `false`, both the current and staged Embedded Price are removed.
	Staged *bool `json:"staged,omitempty"`
}

func (ProductRemovePriceAction) MarshalJSON ¶

func (obj ProductRemovePriceAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductRemoveVariantAction ¶

type ProductRemoveVariantAction struct {
	// The `id` of the ProductVariant to remove.
	ID *int `json:"id,omitempty"`
	// The `sku` of the ProductVariant to remove.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged ProductVariant is removed. If `false`, both the current and staged ProductVariant is removed.
	Staged *bool `json:"staged,omitempty"`
}

* * Either `id` or `sku` is required. * Produces the [ProductVariantDeleted](ctp:api:type:ProductVariantDeletedMessage) Message. * If the Product Variant to remove is part of a ProductSelectionAssignment(ctp:api:type:ProductSelectionAssignment) * its SKU will be automatically removed from the respective ProductVariantSelection(ctp:api:type:ProductVariantSelection). *

func (ProductRemoveVariantAction) MarshalJSON ¶

func (obj ProductRemoveVariantAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductRemovedFromCategoryMessage ¶

type ProductRemovedFromCategoryMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Category](ctp:api:type:Category) the [Product](ctp:api:type:Product) was removed from.
	Category CategoryReference `json:"category"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Remove From Category](ctp:api:type:ProductRemoveFromCategoryAction) update action. *

func (ProductRemovedFromCategoryMessage) MarshalJSON ¶

func (obj ProductRemovedFromCategoryMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductRemovedFromCategoryMessage) UnmarshalJSON ¶

func (obj *ProductRemovedFromCategoryMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductRemovedFromCategoryMessagePayload ¶

type ProductRemovedFromCategoryMessagePayload struct {
	// [Category](ctp:api:type:Category) the [Product](ctp:api:type:Product) was removed from.
	Category CategoryReference `json:"category"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Remove From Category](ctp:api:type:ProductRemoveFromCategoryAction) update action. *

func (ProductRemovedFromCategoryMessagePayload) MarshalJSON ¶

func (obj ProductRemovedFromCategoryMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductResourceIdentifier ¶

type ProductResourceIdentifier struct {
	// Unique identifier of the referenced [Product](ctp:api:type:Product).
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [Product](ctp:api:type:Product).
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a Product(ctp:api:type:Product). Either `id` or `key` is required. *

func (ProductResourceIdentifier) MarshalJSON ¶

func (obj ProductResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductRevertStagedChangesAction ¶

type ProductRevertStagedChangesAction struct {
}

* * Reverts the staged version of a Product to the current version. Produces the [ProductRevertedStagedChanges](ctp:api:type:ProductRevertedStagedChangesMessage) Message. *

func (ProductRevertStagedChangesAction) MarshalJSON ¶

func (obj ProductRevertStagedChangesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductRevertStagedVariantChangesAction ¶

type ProductRevertStagedVariantChangesAction struct {
	// The `id` of the ProductVariant to revert.
	VariantId int `json:"variantId"`
}

* * Reverts the staged version of a ProductVariant to the current version. *

func (ProductRevertStagedVariantChangesAction) MarshalJSON ¶

func (obj ProductRevertStagedVariantChangesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductRevertedStagedChangesMessage ¶

type ProductRevertedStagedChangesMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// List of image URLs that were removed during the [Revert Staged Changes](ctp:api:type:ProductRevertStagedChangesAction) update action.
	RemovedImageUrls []string `json:"removedImageUrls"`
}

* * Generated after a successful [Revert Staged Changes](ctp:api:type:ProductRevertStagedChangesAction) update action. *

func (ProductRevertedStagedChangesMessage) MarshalJSON ¶

func (obj ProductRevertedStagedChangesMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductRevertedStagedChangesMessage) UnmarshalJSON ¶

func (obj *ProductRevertedStagedChangesMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductRevertedStagedChangesMessagePayload ¶

type ProductRevertedStagedChangesMessagePayload struct {
	// List of image URLs that were removed during the [Revert Staged Changes](ctp:api:type:ProductRevertStagedChangesAction) update action.
	RemovedImageUrls []string `json:"removedImageUrls"`
}

* * Generated after a successful [Revert Staged Changes](ctp:api:type:ProductRevertStagedChangesAction) update action. *

func (ProductRevertedStagedChangesMessagePayload) MarshalJSON ¶

func (obj ProductRevertedStagedChangesMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelection ¶

type ProductSelection struct {
	// Unique identifier of the ProductSelection.
	ID string `json:"id"`
	// Current version of the ProductSelection.
	Version int `json:"version"`
	// Date and time (UTC) the ProductSelection was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the ProductSelection was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources updated after 1/02/2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1/02/2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the ProductSelection.
	Key *string `json:"key,omitempty"`
	// Name of the ProductSelection.
	Name LocalizedString `json:"name"`
	// Number of Products that are currently assigned to this ProductSelection.
	ProductCount int `json:"productCount"`
	// Specifies in which way the Products are assigned to the ProductSelection.
	// Currently, the only way of doing this is to specify each Product individually, either by [including or excluding](ctp:api:type:ProductSelectionMode) them explicitly.
	Type *ProductSelectionTypeEnum `json:"type,omitempty"`
	// Specifies in which way the Products are assigned to the ProductSelection.
	// Currently, the only way of doing this is to specify each Product individually, either by [including or excluding](ctp:api:type:ProductSelectionMode) them explicitly.
	Mode ProductSelectionMode `json:"mode"`
	// Custom Fields of the ProductSelection.
	Custom *CustomFields `json:"custom,omitempty"`
}

type ProductSelectionAddProductAction ¶

type ProductSelectionAddProductAction struct {
	// ResourceIdentifier of the Product
	Product ProductResourceIdentifier `json:"product"`
	// Defines which Variants of the Product will be included in the Product Selection.
	// If not supplied all Variants are deemed to be included.
	VariantSelection ProductVariantSelection `json:"variantSelection,omitempty"`
}

* * Adds a Product to the Product Selection. * * If the specified Product is already assigned to the Product Selection, but the existing Product Selection has a different Product Variant Selection, a [ProductPresentWithDifferentVariantSelection](ctp:api:type:ProductPresentWithDifferentVariantSelectionError) error is returned. *

func (ProductSelectionAddProductAction) MarshalJSON ¶

func (obj ProductSelectionAddProductAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSelectionAddProductAction) UnmarshalJSON ¶

func (obj *ProductSelectionAddProductAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionAssignment ¶

type ProductSelectionAssignment struct {
	// Reference to a Product that is assigned to the ProductSelection.
	Product ProductReference `json:"product"`
	// Reference to the Product Selection that this assignment is part of.
	ProductSelection ProductSelectionReference `json:"productSelection"`
	// Define which Variants of the added Product will be included in the Product Selection.
	//
	// This field is only available for assignments to a Product Selection with `Individual` [ProductSelectionMode](ctp:api:type:ProductSelectionMode).
	// The list of SKUs will be updated automatically on any change of those performed on the respective Product itself.
	VariantSelection ProductVariantSelection `json:"variantSelection,omitempty"`
	// Defines which Variants of the Product will be excluded from the Product Selection.
	//
	// This field is only available for assignments to a Product Selection with `IndividualExclusion` [ProductSelectionMode](ctp:api:type:ProductSelectionMode).
	// The list of SKUs will be updated automatically on any change of those performed on the respective Product itself.
	VariantExclusion *ProductVariantExclusion `json:"variantExclusion,omitempty"`
}

* * * Given the mode of Product Selection, this assignment refers to, it may contain: * * - `variantSelection` field for a Product Selection with `Individual` ProductSelectionMode(ctp:api:type:ProductSelectionMode). * - `variantExclusion` field for a Product Selection with `IndividualExclusion` ProductSelectionMode(ctp:api:type:ProductSelectionMode) ([BETA](/../offering/api-contract#public-beta)).

func (*ProductSelectionAssignment) UnmarshalJSON ¶

func (obj *ProductSelectionAssignment) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionChangeNameAction ¶

type ProductSelectionChangeNameAction struct {
	// The new name to be set for the ProductSelection.
	Name LocalizedString `json:"name"`
}

func (ProductSelectionChangeNameAction) MarshalJSON ¶

func (obj ProductSelectionChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionCreatedMessage ¶

type ProductSelectionCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Product Selection](ctp:api:type:ProductSelection) that was created.
	ProductSelection ProductSelection `json:"productSelection"`
}

* * Generated after a successful [Create Product Selection](/../api/projects/product-selections#create-product-selection) request. *

func (ProductSelectionCreatedMessage) MarshalJSON ¶

func (obj ProductSelectionCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSelectionCreatedMessage) UnmarshalJSON ¶

func (obj *ProductSelectionCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionCreatedMessagePayload ¶

type ProductSelectionCreatedMessagePayload struct {
	// [Product Selection](ctp:api:type:ProductSelection) that was created.
	ProductSelection ProductSelection `json:"productSelection"`
}

* * Generated after a successful [Create Product Selection](/../api/projects/product-selections#create-product-selection) request. *

func (ProductSelectionCreatedMessagePayload) MarshalJSON ¶

func (obj ProductSelectionCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionDeletedMessage ¶

type ProductSelectionDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
}

* * Generated after a successful [Delete Product Selection](/../api/projects/product-selections#create-product-selection) request. *

func (ProductSelectionDeletedMessage) MarshalJSON ¶

func (obj ProductSelectionDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSelectionDeletedMessage) UnmarshalJSON ¶

func (obj *ProductSelectionDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionDeletedMessagePayload ¶

type ProductSelectionDeletedMessagePayload struct {
}

* * Generated after a successful [Delete Product Selection](/../api/projects/product-selections#create-product-selection) request. *

func (ProductSelectionDeletedMessagePayload) MarshalJSON ¶

func (obj ProductSelectionDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionDraft ¶

type ProductSelectionDraft struct {
	// User-defined unique identifier for the ProductSelection.
	Key *string `json:"key,omitempty"`
	// Name of the ProductSelection. Not checked for uniqueness, but distinct names are recommended.
	Name LocalizedString `json:"name"`
	// Custom Fields of this ProductSelection.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Type of the Product Selection.
	Type *ProductSelectionTypeEnum `json:"type,omitempty"`
	// Mode of the Product Selection.
	Mode *ProductSelectionMode `json:"mode,omitempty"`
}

type ProductSelectionExcludeProductAction ¶

type ProductSelectionExcludeProductAction struct {
	// ResourceIdentifier of the Product
	Product ProductResourceIdentifier `json:"product"`
	// Defines which Variants of the Product will be excluded from the Product Selection.
	// If not supplied all Variants are deemed to be excluded.
	VariantExclusion *ProductVariantExclusion `json:"variantExclusion,omitempty"`
}

* * Excludes a Product from a Product Selection with `IndividualExclusion` ProductSelectionMode(ctp:api:type:ProductSelectionMode). * * If the specified Product is already assigned to the Product Selection, but the existing Product Selection has a different Product Variant Exclusion, a [ProductPresentWithDifferentVariantSelection](ctp:api:type:ProductPresentWithDifferentVariantSelectionError) error is returned. *

func (ProductSelectionExcludeProductAction) MarshalJSON ¶

func (obj ProductSelectionExcludeProductAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionMode ¶

type ProductSelectionMode string

* * Product Selections can have the following modes: *

const (
	ProductSelectionModeIndividual          ProductSelectionMode = "Individual"
	ProductSelectionModeIndividualExclusion ProductSelectionMode = "IndividualExclusion"
)

type ProductSelectionPagedQueryResponse ¶

type ProductSelectionPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/general-concepts#strong-consistency).
	// Unlike other endpoints, the Product Selection endpoint does not return this field by default.
	// To get `total`, pass the query parameter `withTotal` set to `true`.
	// When the results are filtered with a [Query Predicate](/predicates/query), `total` is subject to a [limit](/limits#queries).
	Total *int `json:"total,omitempty"`
	// [ProductSelections](ctp:api:type:ProductSelection) matching the query.
	Results []ProductSelection `json:"results"`
}

* * [PagedQueryResult](/general-concepts#pagedqueryresult) containing an array of ProductSelection(ctp:api:type:ProductSelection). *

type ProductSelectionProductAddedMessage ¶

type ProductSelectionProductAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Product](ctp:api:type:Product) that was added to the [Product Selection](ctp:api:type:ProductSelection).
	Product ProductReference `json:"product"`
	// Product Variant Selection after the [Add Product](ctp:api:type:ProductSelectionAddProductAction) update action.
	VariantSelection ProductVariantSelection `json:"variantSelection"`
}

* * Generated after a successful [Add Product](ctp:api:type:ProductSelectionAddProductAction) update action. *

func (ProductSelectionProductAddedMessage) MarshalJSON ¶

func (obj ProductSelectionProductAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSelectionProductAddedMessage) UnmarshalJSON ¶

func (obj *ProductSelectionProductAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionProductAddedMessagePayload ¶

type ProductSelectionProductAddedMessagePayload struct {
	// [Product](ctp:api:type:Product) that was added to the [Product Selection](ctp:api:type:ProductSelection).
	Product ProductReference `json:"product"`
	// Product Variant Selection after the [Add Product](ctp:api:type:ProductSelectionAddProductAction) update action.
	VariantSelection ProductVariantSelection `json:"variantSelection"`
}

* * Generated after a successful [Add Product](ctp:api:type:ProductSelectionAddProductAction) update action. *

func (ProductSelectionProductAddedMessagePayload) MarshalJSON ¶

func (obj ProductSelectionProductAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSelectionProductAddedMessagePayload) UnmarshalJSON ¶

func (obj *ProductSelectionProductAddedMessagePayload) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionProductExcludedMessage ¶

type ProductSelectionProductExcludedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Product](ctp:api:type:Product) that was excluded from the [Product Selection](ctp:api:type:ProductSelection).
	Product ProductReference `json:"product"`
	// Product Variant Exclusion after the [Exclude Product](ctp:api:type:ProductSelectionExcludeProductAction) update action.
	VariantExclusion ProductVariantExclusion `json:"variantExclusion"`
}

* * Generated after a successful [Exclude Product](ctp:api:type:ProductSelectionExcludeProductAction) update action. *

func (ProductSelectionProductExcludedMessage) MarshalJSON ¶

func (obj ProductSelectionProductExcludedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSelectionProductExcludedMessage) UnmarshalJSON ¶

func (obj *ProductSelectionProductExcludedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionProductExcludedMessagePayload ¶

type ProductSelectionProductExcludedMessagePayload struct {
	// [Product](ctp:api:type:Product) that was excluded from the [Product Selection](ctp:api:type:ProductSelection).
	Product ProductReference `json:"product"`
	// Product Variant Exclusion after the [Exclude Product](ctp:api:type:ProductSelectionExcludeProductAction) update action.
	VariantExclusion ProductVariantExclusion `json:"variantExclusion"`
}

* * Generated after a successful [Exclude Product](ctp:api:type:ProductSelectionExcludeProductAction) update action. *

func (ProductSelectionProductExcludedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionProductPagedQueryResponse ¶

type ProductSelectionProductPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/general-concepts#strong-consistency).
	// Unlike other endpoints, the Product Selection endpoint does not return this field by default.
	// To get `total`, pass the query parameter `withTotal` set to `true`.
	// When the results are filtered with a [Query Predicate](/predicates/query), `total` is subject to a [limit](/limits#queries).
	Total *int `json:"total,omitempty"`
	// References to Products that are assigned to the ProductSelection.
	Results []AssignedProductReference `json:"results"`
}

* * [PagedQueryResult](/general-concepts#pagedqueryresult) containing an array of AssignedProductReference(ctp:api:type:AssignedProductReference). *

type ProductSelectionProductRemovedMessage ¶

type ProductSelectionProductRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Product](ctp:api:type:Product) that was removed from the Product Selection.
	Product ProductReference `json:"product"`
}

* * Generated after a successful [Remove Product](ctp:api:type:ProductSelectionRemoveProductAction) update action. *

func (ProductSelectionProductRemovedMessage) MarshalJSON ¶

func (obj ProductSelectionProductRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSelectionProductRemovedMessage) UnmarshalJSON ¶

func (obj *ProductSelectionProductRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionProductRemovedMessagePayload ¶

type ProductSelectionProductRemovedMessagePayload struct {
	// [Product](ctp:api:type:Product) that was removed from the Product Selection.
	Product ProductReference `json:"product"`
}

* * Generated after a successful [Remove Product](ctp:api:type:ProductSelectionRemoveProductAction) update action. *

func (ProductSelectionProductRemovedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionReference ¶

type ProductSelectionReference struct {
	// Unique identifier of the referenced [ProductSelection](ctp:api:type:ProductSelection).
	ID string `json:"id"`
	// Contains the representation of the expanded ProductSelection. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for ProductSelections.
	Obj *ProductSelection `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a ProductSelection(ctp:api:type:ProductSelection). *

func (ProductSelectionReference) MarshalJSON ¶

func (obj ProductSelectionReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionRemoveProductAction ¶

type ProductSelectionRemoveProductAction struct {
	// ResourceIdentifier of the Product
	Product ProductResourceIdentifier `json:"product"`
}

func (ProductSelectionRemoveProductAction) MarshalJSON ¶

func (obj ProductSelectionRemoveProductAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionResourceIdentifier ¶

type ProductSelectionResourceIdentifier struct {
	// Unique identifier of the referenced [ProductSelection](ctp:api:type:ProductSelection). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [ProductSelection](ctp:api:type:ProductSelection). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a ProductSelection(ctp:api:type:ProductSelection). *

func (ProductSelectionResourceIdentifier) MarshalJSON ¶

func (obj ProductSelectionResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionSetCustomFieldAction ¶

type ProductSelectionSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (ProductSelectionSetCustomFieldAction) MarshalJSON ¶

func (obj ProductSelectionSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionSetCustomTypeAction ¶

type ProductSelectionSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the ProductSelection with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the ProductSelection.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the ProductSelection.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (ProductSelectionSetCustomTypeAction) MarshalJSON ¶

func (obj ProductSelectionSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionSetKeyAction ¶

type ProductSelectionSetKeyAction struct {
	// If `key` is absent or `null`, the existing key, if any, will be removed.
	Key *string `json:"key,omitempty"`
}

func (ProductSelectionSetKeyAction) MarshalJSON ¶

func (obj ProductSelectionSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionSetVariantExclusionAction ¶

type ProductSelectionSetVariantExclusionAction struct {
	// ResourceIdentifier of the Product
	Product ProductResourceIdentifier `json:"product"`
	// Determines which Variants of the previously excluded Product are to be included in the Product Selection with `IndividualExclusion` [ProductSelectionMode](ctp:api:type:ProductSelectionMode).
	// Leave it empty to unset an existing Variant Exclusion.
	VariantExclusion *ProductVariantExclusion `json:"variantExclusion,omitempty"`
}

* * Updates the Product Variant Exclusion of an existing [Product Selection Assignment](ctp:api:type:ProductSelectionAssignment). * A ProductVariantExclusion(ctp:api:type:ProductVariantExclusion) can only be set if the Product(ctp:api:type:Product) has already been excluded from the [Product Selection](ctp:api:type:ProductSelection) with `IndividualExclusion` ProductSelectionMode(ctp:api:type:ProductSelectionMode). * * If the specified Product is not assigned to the Product Selection, a [ProductAssignmentMissing](ctp:api:type:ProductAssignmentMissingError) error is returned. *

func (ProductSelectionSetVariantExclusionAction) MarshalJSON ¶

func (obj ProductSelectionSetVariantExclusionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionSetVariantSelectionAction ¶

type ProductSelectionSetVariantSelectionAction struct {
	// ResourceIdentifier of the Product
	Product ProductResourceIdentifier `json:"product"`
	// Determines which Variants of the previously added Product are to be included in, or excluded from, the Product Selection.
	// Leave it empty to unset an existing Variant Selection.
	VariantSelection ProductVariantSelection `json:"variantSelection,omitempty"`
}

* * Updates the Product Variant Selection of an existing [Product Selection Assignment](ctp:api:type:ProductSelectionAssignment). * A ProductVariantSelection(ctp:api:type:ProductVariantSelection) can only be set if the Product(ctp:api:type:Product) has already been included in the Product Selection with `Individual` ProductSelectionMode(ctp:api:type:ProductSelectionMode). * * If the specified Product is not assigned to the Product Selection, a [ProductAssignmentMissing](ctp:api:type:ProductAssignmentMissingError) error is returned. *

func (ProductSelectionSetVariantSelectionAction) MarshalJSON ¶

func (obj ProductSelectionSetVariantSelectionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSelectionSetVariantSelectionAction) UnmarshalJSON ¶

func (obj *ProductSelectionSetVariantSelectionAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionSetting ¶

type ProductSelectionSetting struct {
	// Reference to a ProductSelection.
	ProductSelection ProductSelectionReference `json:"productSelection"`
	// If `true`, all Products assigned to this Product Selection are part of the Store's assortment.
	Active bool `json:"active"`
}

type ProductSelectionSettingDraft ¶

type ProductSelectionSettingDraft struct {
	// Resource Identifier of a ProductSelection.
	ProductSelection ProductSelectionResourceIdentifier `json:"productSelection"`
	// Set to `true` if all Products assigned to the Product Selection should become part of the Store's assortment.
	Active *bool `json:"active,omitempty"`
}

type ProductSelectionType ¶

type ProductSelectionType interface{}

type ProductSelectionTypeEnum ¶

type ProductSelectionTypeEnum string

* * The following types of Product Selections are supported: *

const (
	ProductSelectionTypeEnumIndividual          ProductSelectionTypeEnum = "individual"
	ProductSelectionTypeEnumIndividualExclusion ProductSelectionTypeEnum = "individualExclusion"
)

type ProductSelectionUpdate ¶

type ProductSelectionUpdate struct {
	Version int                            `json:"version"`
	Actions []ProductSelectionUpdateAction `json:"actions"`
}

func (*ProductSelectionUpdate) UnmarshalJSON ¶

func (obj *ProductSelectionUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionUpdateAction ¶

type ProductSelectionUpdateAction interface{}

type ProductSelectionVariantExclusionChangedMessage ¶

type ProductSelectionVariantExclusionChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Product](ctp:api:type:Product) for which the Product Variant Exclusion changed.
	Product ProductReference `json:"product"`
	// Product Variant Exclusion before the [Set Variant Exclusion](ctp:api:type:ProductSelectionSetVariantExclusionAction) update action.
	OldVariantExclusion ProductVariantExclusion `json:"oldVariantExclusion"`
	// Product Variant Exclusion after the [Set Variant Exclusion](ctp:api:type:ProductSelectionSetVariantExclusionAction) update action.
	NewVariantExclusion ProductVariantExclusion `json:"newVariantExclusion"`
}

* * Generated after a successful [Set Variant Exclusion](ctp:api:type:ProductSelectionSetVariantExclusionAction) update action. *

func (ProductSelectionVariantExclusionChangedMessage) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSelectionVariantExclusionChangedMessage) UnmarshalJSON ¶

func (obj *ProductSelectionVariantExclusionChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionVariantExclusionChangedMessagePayload ¶

type ProductSelectionVariantExclusionChangedMessagePayload struct {
	// [Product](ctp:api:type:Product) for which the Product Variant Exclusion changed.
	Product ProductReference `json:"product"`
	// Product Variant Exclusion before the [Set Variant Exclusion](ctp:api:type:ProductSelectionSetVariantExclusionAction) update action.
	OldVariantExclusion ProductVariantExclusion `json:"oldVariantExclusion"`
	// Product Variant Exclusion after the [Set Variant Exclusion](ctp:api:type:ProductSelectionSetVariantExclusionAction) update action.
	NewVariantExclusion ProductVariantExclusion `json:"newVariantExclusion"`
}

* * Generated after a successful [Set Variant Exclusion](ctp:api:type:ProductSelectionSetVariantExclusionAction) update action. *

func (ProductSelectionVariantExclusionChangedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSelectionVariantSelectionChangedMessage ¶

type ProductSelectionVariantSelectionChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Product](ctp:api:type:Product) for which the Product Variant Selection changed.
	Product ProductReference `json:"product"`
	// Product Variant Selection before the [Set Variant Selection](ctp:api:type:ProductSelectionSetVariantSelectionAction) update action.
	OldVariantSelection ProductVariantSelection `json:"oldVariantSelection"`
	// Product Variant Selection after the [Set Variant Selection](ctp:api:type:ProductSelectionSetVariantSelectionAction) update action.
	NewVariantSelection ProductVariantSelection `json:"newVariantSelection"`
}

* * Generated after a successful [Set Variant Selection](ctp:api:type:ProductSelectionSetVariantSelectionAction) update action. *

func (ProductSelectionVariantSelectionChangedMessage) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSelectionVariantSelectionChangedMessage) UnmarshalJSON ¶

func (obj *ProductSelectionVariantSelectionChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSelectionVariantSelectionChangedMessagePayload ¶

type ProductSelectionVariantSelectionChangedMessagePayload struct {
	// [Product](ctp:api:type:Product) for which the Product Variant Selection changed.
	Product ProductReference `json:"product"`
	// Product Variant Selection before the [Set Variant Selection](ctp:api:type:ProductSelectionSetVariantSelectionAction) update action.
	OldVariantSelection ProductVariantSelection `json:"oldVariantSelection"`
	// Product Variant Selection after the [Set Variant Selection](ctp:api:type:ProductSelectionSetVariantSelectionAction) update action.
	NewVariantSelection ProductVariantSelection `json:"newVariantSelection"`
}

* * Generated after a successful [Set Variant Selection](ctp:api:type:ProductSelectionSetVariantSelectionAction) update action. *

func (ProductSelectionVariantSelectionChangedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSelectionVariantSelectionChangedMessagePayload) UnmarshalJSON ¶

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSetAssetCustomFieldAction ¶

type ProductSetAssetCustomFieldAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged Asset is updated. If `false`, both the current and staged Asset is updated.
	Staged *bool `json:"staged,omitempty"`
	// The `id` of the Asset to update.
	AssetId *string `json:"assetId,omitempty"`
	// The `key` of the Asset to update.
	AssetKey *string `json:"assetKey,omitempty"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

* * Either `variantId` or `sku` is required. The Asset(ctp:api:type:Asset) to update must be specified using either `assetId` or `assetKey`. *

func (ProductSetAssetCustomFieldAction) MarshalJSON ¶

func (obj ProductSetAssetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetAssetCustomTypeAction ¶

type ProductSetAssetCustomTypeAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged Asset is updated. If `false`, both the current and staged Asset is updated.
	Staged *bool `json:"staged,omitempty"`
	// The `id` of the Asset to update.
	AssetId *string `json:"assetId,omitempty"`
	// The `key` of the Asset to update.
	AssetKey *string `json:"assetKey,omitempty"`
	// Defines the [Type](ctp:api:type:Type) that extends the Asset with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Asset.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Asset.
	Fields *FieldContainer `json:"fields,omitempty"`
}

* * Either `variantId` or `sku` is required. The Asset(ctp:api:type:Asset) to update must be specified using either `assetId` or `assetKey`. *

func (ProductSetAssetCustomTypeAction) MarshalJSON ¶

func (obj ProductSetAssetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetAssetDescriptionAction ¶

type ProductSetAssetDescriptionAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged Asset is updated. If `false`, both the current and staged Asset is updated.
	Staged *bool `json:"staged,omitempty"`
	// The `id` of the Asset to update.
	AssetId *string `json:"assetId,omitempty"`
	// The `key` of the Asset to update.
	AssetKey *string `json:"assetKey,omitempty"`
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

* * Either `variantId` or `sku` is required. The Asset(ctp:api:type:Asset) to update must be specified using either `assetId` or `assetKey`. *

func (ProductSetAssetDescriptionAction) MarshalJSON ¶

func (obj ProductSetAssetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetAssetKeyAction ¶

type ProductSetAssetKeyAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged Asset is updated. If `false`, both the current and staged Asset is updated.
	Staged *bool `json:"staged,omitempty"`
	// The `id` of the Asset to update.
	AssetId string `json:"assetId"`
	// Value to set. If empty, any existing value will be removed.
	AssetKey *string `json:"assetKey,omitempty"`
}

* * Either `variantId` or `sku` is required. *

func (ProductSetAssetKeyAction) MarshalJSON ¶

func (obj ProductSetAssetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetAssetSourcesAction ¶

type ProductSetAssetSourcesAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged Asset is updated. If `false` both the current and staged Asset is updated.
	Staged *bool `json:"staged,omitempty"`
	// The `id` of the Asset to update.
	AssetId *string `json:"assetId,omitempty"`
	// The `key` of the Asset to update.
	AssetKey *string `json:"assetKey,omitempty"`
	// Value to set.
	Sources []AssetSource `json:"sources"`
}

* * Either `variantId` or `sku` is required. The Asset(ctp:api:type:Asset) to update must be specified using either `assetId` or `assetKey`. *

func (ProductSetAssetSourcesAction) MarshalJSON ¶

func (obj ProductSetAssetSourcesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetAssetTagsAction ¶

type ProductSetAssetTagsAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged Asset is updated. If `false`, both the current and staged Asset is updated.
	Staged *bool `json:"staged,omitempty"`
	// The `id` of the Asset to update.
	AssetId *string `json:"assetId,omitempty"`
	// The `key` of the Asset to update.
	AssetKey *string `json:"assetKey,omitempty"`
	// Keywords for categorizing and organizing Assets.
	Tags []string `json:"tags"`
}

* * Either `variantId` or `sku` is required. The Asset to update must be specified using either `assetId` or `assetKey`. *

func (ProductSetAssetTagsAction) MarshalJSON ¶

func (obj ProductSetAssetTagsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetAttributeAction ¶

type ProductSetAttributeAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// The name of the Attribute to set.
	Name string `json:"name"`
	// Value to set for the Attribute. If empty, any existing value will be removed.
	//
	// The [AttributeType](ctp:api:type:AttributeType) determines the format of the Attribute `value` to be provided:
	//
	// - For [Enum Type](ctp:api:type:AttributeEnumType) and [Localized Enum Type](ctp:api:type:AttributeLocalizedEnumType),
	//   use the `key` of the [Plain Enum Value](ctp:api:type:AttributePlainEnumValue) or [Localized Enum Value](ctp:api:type:AttributeLocalizedEnumValue) objects,
	//   or the complete objects as `value`.
	// - For [Localizable Text Type](ctp:api:type:AttributeLocalizableTextType), use the [LocalizedString](ctp:api:type:LocalizedString) object as `value`.
	// - For [Money Type](ctp:api:type:AttributeMoneyType) Attributes, use the [Money](ctp:api:type:Money) object as `value`.
	// - For [Set Type](ctp:api:type:AttributeSetType) Attributes, use the entire `set` object  as `value`.
	// - For [Nested Type](ctp:api:type:AttributeNestedType) Attributes, use the list of values of all Attributes of the nested Product as `value`.
	// - For [Reference Type](ctp:api:type:AttributeReferenceType) Attributes, use the [Reference](ctp:api:type:Reference) object as `value`.
	Value interface{} `json:"value,omitempty"`
	// If `true`, only the staged Attribute is set. If `false`, both current and staged Attribute is set.
	Staged *bool `json:"staged,omitempty"`
}

* * Either `variantId` or `sku` is required. *

func (ProductSetAttributeAction) MarshalJSON ¶

func (obj ProductSetAttributeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetAttributeInAllVariantsAction ¶

type ProductSetAttributeInAllVariantsAction struct {
	// The name of the Attribute to set.
	Name string `json:"name"`
	// Value to set for the Attributes. If empty, any existing value will be removed.
	//
	// The [AttributeType](ctp:api:type:AttributeType) determines the format of the Attribute `value` to be provided:
	//
	// - For [Enum Type](ctp:api:type:AttributeEnumType) and [Localized Enum Type](ctp:api:type:AttributeLocalizedEnumType),
	//   use the `key` of the [Plain Enum Value](ctp:api:type:AttributePlainEnumValue) or [Localized Enum Value](ctp:api:type:AttributeLocalizedEnumValue) objects,
	//   or the complete objects as `value`.
	// - For [Localizable Text Type](ctp:api:type:AttributeLocalizableTextType), use the [LocalizedString](ctp:api:type:LocalizedString) object as `value`.
	// - For [Money Type](ctp:api:type:AttributeMoneyType) Attributes, use the [Money](ctp:api:type:Money) object as `value`.
	// - For [Set Type](ctp:api:type:AttributeSetType) Attributes, use the entire `set` object  as `value`.
	// - For [Nested Type](ctp:api:type:AttributeNestedType) Attributes, use the list of values of all Attributes of the nested Product as `value`.
	// - For [Reference Type](ctp:api:type:AttributeReferenceType) Attributes, use the [Reference](ctp:api:type:Reference) object as `value`.
	Value interface{} `json:"value,omitempty"`
	// If `true`, only the staged Attributes are set. If `false`, both the current and staged Attributes are set.
	Staged *bool `json:"staged,omitempty"`
}

* * Adds, removes, or changes a Product Attribute in all Product Variants at the same time. * This action is useful for setting values for Attributes with the [Constraint](ctp:api:type:AttributeConstraintEnum) `SameForAll`.

func (ProductSetAttributeInAllVariantsAction) MarshalJSON ¶

func (obj ProductSetAttributeInAllVariantsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetCategoryOrderHintAction ¶

type ProductSetCategoryOrderHintAction struct {
	// The `id` of the Category to add the `orderHint`.
	CategoryId string `json:"categoryId"`
	// A string representing a number between 0 and 1. Must start with `0.` and cannot end with `0`. If empty, any existing value will be removed.
	OrderHint *string `json:"orderHint,omitempty"`
	// If `true`, only the staged `categoryOrderHints` is updated. If `false`, both the current and staged `categoryOrderHints` are updated.
	Staged *bool `json:"staged,omitempty"`
}

func (ProductSetCategoryOrderHintAction) MarshalJSON ¶

func (obj ProductSetCategoryOrderHintAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetDescriptionAction ¶

type ProductSetDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
	// If `true`, only the staged `description` is updated. If `false`, both the current and staged `description` are updated.
	Staged *bool `json:"staged,omitempty"`
}

func (ProductSetDescriptionAction) MarshalJSON ¶

func (obj ProductSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetDiscountedPriceAction ¶

type ProductSetDiscountedPriceAction struct {
	// The `id` of the [Price](ctp:api:type:Price) to set the Discount.
	PriceId string `json:"priceId"`
	// If `true`, only the staged Embedded Price is updated. If `false`, both the current and staged Embedded Price are updated.
	Staged *bool `json:"staged,omitempty"`
	// Value to set. If empty, any existing value will be removed.
	// The referenced [ProductDiscount](ctp:api:type:ProductDiscount) must have the Type `external`, be active, and its predicate must match the referenced Price.
	Discounted *DiscountedPriceDraft `json:"discounted,omitempty"`
}

* * Produces the [ProductPriceExternalDiscountSet](ctp:api:type:ProductPriceExternalDiscountSetMessage) Message. *

func (ProductSetDiscountedPriceAction) MarshalJSON ¶

func (obj ProductSetDiscountedPriceAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetImageLabelAction ¶

type ProductSetImageLabelAction struct {
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The URL of the image to set the label.
	ImageUrl string `json:"imageUrl"`
	// Value to set. If empty, any existing value will be removed.
	Label *string `json:"label,omitempty"`
	// If `true`, only the staged image is updated. If `false`, both the current and staged image is updated.
	Staged *bool `json:"staged,omitempty"`
}

* * Either `variantId` or `sku` is required. *

func (ProductSetImageLabelAction) MarshalJSON ¶

func (obj ProductSetImageLabelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetKeyAction ¶

type ProductSetKeyAction struct {
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

func (ProductSetKeyAction) MarshalJSON ¶

func (obj ProductSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetMetaDescriptionAction ¶

type ProductSetMetaDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	MetaDescription *LocalizedString `json:"metaDescription,omitempty"`
	// If `true`, only the staged `metaDescription` is updated. If `false`, both the current and staged `metaDescription` are updated.
	Staged *bool `json:"staged,omitempty"`
}

func (ProductSetMetaDescriptionAction) MarshalJSON ¶

func (obj ProductSetMetaDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetMetaKeywordsAction ¶

type ProductSetMetaKeywordsAction struct {
	// Value to set. If empty, any existing value will be removed.
	MetaKeywords *LocalizedString `json:"metaKeywords,omitempty"`
	// If `true`, only the staged `metaKeywords` is updated. If `false`, both the current and staged `metaKeywords` are updated.
	Staged *bool `json:"staged,omitempty"`
}

func (ProductSetMetaKeywordsAction) MarshalJSON ¶

func (obj ProductSetMetaKeywordsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetMetaTitleAction ¶

type ProductSetMetaTitleAction struct {
	// Value to set. If empty, any existing value will be removed.
	MetaTitle *LocalizedString `json:"metaTitle,omitempty"`
	// If `true`, only the staged `metaTitle` is updated. If `false`, both the current and staged `metaTitle` are updated.
	Staged *bool `json:"staged,omitempty"`
}

func (ProductSetMetaTitleAction) MarshalJSON ¶

func (obj ProductSetMetaTitleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetPriceKeyAction ¶

type ProductSetPriceKeyAction struct {
	// The `id` of the [Price](ctp:api:type:Price) to set the key.
	PriceId string `json:"priceId"`
	// If `true`, only the staged [Embedded Price](/projects/products#embedded-price) is updated. If `false`, both the current and staged Embedded Price are updated.
	Staged *bool `json:"staged,omitempty"`
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

* * Sets the key of an [Embedded Price](/projects/products#embedded-price). Produces the [ProductPriceKeySet](ctp:api:type:ProductPriceKeySetMessage) Message. *

func (ProductSetPriceKeyAction) MarshalJSON ¶

func (obj ProductSetPriceKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetPriceModeAction ¶

type ProductSetPriceModeAction struct {
	// Specifies which type of Prices should be used when looking up a price for the Product.
	PriceMode *ProductPriceModeEnum `json:"priceMode,omitempty"`
}

* * Controls whether the Prices of a Product Variant are embedded into the Product or standalone. *

func (ProductSetPriceModeAction) MarshalJSON ¶

func (obj ProductSetPriceModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetPricesAction ¶

type ProductSetPricesAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// The Embedded Prices to set.
	// Each Price must have its unique Price scope (with same currency, country, Customer Group, Channel, `validFrom` and `validUntil`).
	Prices []PriceDraft `json:"prices"`
	// If `true`, only the staged ProductVariant is updated. If `false`, both the current and staged ProductVariant are updated.
	Staged *bool `json:"staged,omitempty"`
}

* * Either `variantId` or `sku` is required. *

func (ProductSetPricesAction) MarshalJSON ¶

func (obj ProductSetPricesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetProductPriceCustomFieldAction ¶

type ProductSetProductPriceCustomFieldAction struct {
	// The `id` of the Embedded Price to update.
	PriceId string `json:"priceId"`
	// If `true`, only the staged Embedded Price Custom Field is updated. If `false`, both the current and staged Embedded Price Custom Field are updated.
	Staged *bool `json:"staged,omitempty"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (ProductSetProductPriceCustomFieldAction) MarshalJSON ¶

func (obj ProductSetProductPriceCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetProductPriceCustomTypeAction ¶

type ProductSetProductPriceCustomTypeAction struct {
	// The `id` of the Embedded Price to update.
	PriceId string `json:"priceId"`
	// If `true`, only the staged Embedded Price is updated. If `false`, both the current and staged Embedded Price is updated.
	Staged *bool `json:"staged,omitempty"`
	// Defines the [Type](ctp:api:type:Type) that extends the Price with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Embedded Price.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Embedded Price.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (ProductSetProductPriceCustomTypeAction) MarshalJSON ¶

func (obj ProductSetProductPriceCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetProductVariantKeyAction ¶

type ProductSetProductVariantKeyAction struct {
	// The `id` of the ProductVariant to update.
	VariantId *int `json:"variantId,omitempty"`
	// The `sku` of the ProductVariant to update.
	Sku *string `json:"sku,omitempty"`
	// Value to set. Must be unique. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
	// If `true`, only the staged `key` is set. If `false`, both the current and staged `key` are set.
	Staged *bool `json:"staged,omitempty"`
}

* * Either `variantId` or `sku` is required. *

func (ProductSetProductVariantKeyAction) MarshalJSON ¶

func (obj ProductSetProductVariantKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetSearchKeywordsAction ¶

type ProductSetSearchKeywordsAction struct {
	// Value to set.
	SearchKeywords SearchKeywords `json:"searchKeywords"`
	// If `true`, only the staged `searchKeywords` is updated. If `false`, both the current and staged `searchKeywords` are updated.
	Staged *bool `json:"staged,omitempty"`
}

func (ProductSetSearchKeywordsAction) MarshalJSON ¶

func (obj ProductSetSearchKeywordsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetSkuAction ¶

type ProductSetSkuAction struct {
	// The `id` of the ProductVariant to update.
	VariantId int `json:"variantId"`
	// Value to set. Must be unique. If empty, any existing value will be removed.
	Sku *string `json:"sku,omitempty"`
	// If `true`, only the staged `sku` is updated. If `false`, both the current and staged `sku` are updated.
	Staged *bool `json:"staged,omitempty"`
}

* * SKU cannot be changed or removed if it is associated with an InventoryEntry(ctp:api:type:InventoryEntry). * If the SKU to set or unset is part of a ProductSelectionAssignment(ctp:api:type:ProductSelectionAssignment) * it will be automatically added or removed from the respective ProductVariantSelection(ctp:api:type:ProductVariantSelection). *

func (ProductSetSkuAction) MarshalJSON ¶

func (obj ProductSetSkuAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSetTaxCategoryAction ¶

type ProductSetTaxCategoryAction struct {
	// The Tax Category to set. If empty, any existing value will be removed.
	TaxCategory *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
}

* * Cannot be staged. Published Products are immediately updated. *

func (ProductSetTaxCategoryAction) MarshalJSON ¶

func (obj ProductSetTaxCategoryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductSlugChangedMessage ¶

type ProductSlugChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The slug of the [Product](ctp:api:type:Product) after the [Change Slug](ctp:api:type:ProductChangeSlugAction) update action.
	Slug LocalizedString `json:"slug"`
	// The slug of the [Product](ctp:api:type:Product) before the [Change Slug](ctp:api:type:ProductChangeSlugAction) update action.
	OldSlug *LocalizedString `json:"oldSlug,omitempty"`
}

* * Generated after a successful [Change Slug](ctp:api:type:ProductChangeSlugAction) update action. *

func (ProductSlugChangedMessage) MarshalJSON ¶

func (obj ProductSlugChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductSlugChangedMessage) UnmarshalJSON ¶

func (obj *ProductSlugChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductSlugChangedMessagePayload ¶

type ProductSlugChangedMessagePayload struct {
	// The slug of the [Product](ctp:api:type:Product) after the [Change Slug](ctp:api:type:ProductChangeSlugAction) update action.
	Slug LocalizedString `json:"slug"`
	// The slug of the [Product](ctp:api:type:Product) before the [Change Slug](ctp:api:type:ProductChangeSlugAction) update action.
	OldSlug *LocalizedString `json:"oldSlug,omitempty"`
}

* * Generated after a successful [Change Slug](ctp:api:type:ProductChangeSlugAction) update action. *

func (ProductSlugChangedMessagePayload) MarshalJSON ¶

func (obj ProductSlugChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductStateTransitionMessage ¶

type ProductStateTransitionMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Product [State](ctp:api:type:State) after the [Transition State](ctp:api:type:ProductTransitionStateAction) update action.
	State StateReference `json:"state"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:ProductTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:ProductTransitionStateAction) update action. *

func (ProductStateTransitionMessage) MarshalJSON ¶

func (obj ProductStateTransitionMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductStateTransitionMessage) UnmarshalJSON ¶

func (obj *ProductStateTransitionMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductStateTransitionMessagePayload ¶

type ProductStateTransitionMessagePayload struct {
	// Product [State](ctp:api:type:State) after the [Transition State](ctp:api:type:ProductTransitionStateAction) update action.
	State StateReference `json:"state"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:ProductTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:ProductTransitionStateAction) update action. *

func (ProductStateTransitionMessagePayload) MarshalJSON ¶

func (obj ProductStateTransitionMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTransitionStateAction ¶

type ProductTransitionStateAction struct {
	// The State to transition to. If there is no existing State, this must be an initial State.
	State *StateResourceIdentifier `json:"state,omitempty"`
	// If `true`, validations are disabled.
	Force *bool `json:"force,omitempty"`
}

* * If the existing State(ctp:api:type:State) has set `transitions`, there must be a direct transition to the new State. If `transitions` is not set, no validation is performed. Produces the [ProductStateTransition](ctp:api:type:ProductStateTransitionMessage) Message. *

func (ProductTransitionStateAction) MarshalJSON ¶

func (obj ProductTransitionStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductType ¶

type ProductType struct {
	// Unique identifier of the ProductType.
	ID string `json:"id"`
	// Current version of the ProductType.
	Version int `json:"version"`
	// Date and time (UTC) the ProductType was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the ProductType was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the ProductType.
	Key *string `json:"key,omitempty"`
	// Name of the ProductType.
	Name string `json:"name"`
	// Description of the ProductType.
	Description string `json:"description"`
	// Attributes specified for the ProductType.
	Attributes []AttributeDefinition `json:"attributes"`
}

func (ProductType) MarshalJSON ¶

func (obj ProductType) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeAddAttributeDefinitionAction ¶

type ProductTypeAddAttributeDefinitionAction struct {
	// Value to append to `attributes`.
	Attribute AttributeDefinitionDraft `json:"attribute"`
}

func (ProductTypeAddAttributeDefinitionAction) MarshalJSON ¶

func (obj ProductTypeAddAttributeDefinitionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeAddLocalizedEnumValueAction ¶

type ProductTypeAddLocalizedEnumValueAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// Value to append to the array.
	Value AttributeLocalizedEnumValue `json:"value"`
}

* * Adds a localizable enum to the values of AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType). It can update an AttributeLocalizedEnumType AttributeDefinition or an AttributeSetType(ctp:api:type:AttributeSetType) of AttributeLocalizedEnumType AttributeDefinition. *

func (ProductTypeAddLocalizedEnumValueAction) MarshalJSON ¶

func (obj ProductTypeAddLocalizedEnumValueAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeAddPlainEnumValueAction ¶

type ProductTypeAddPlainEnumValueAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// Value to append to the array.
	Value AttributePlainEnumValue `json:"value"`
}

* * Adds an enum to the values of AttributeEnumType(ctp:api:type:AttributeEnumType) AttributeDefinition, or AttributeSetType(ctp:api:type:AttributeSetType) of AttributeEnumType AttributeDefinition. *

func (ProductTypeAddPlainEnumValueAction) MarshalJSON ¶

func (obj ProductTypeAddPlainEnumValueAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeAttributeConstraintAction ¶

type ProductTypeChangeAttributeConstraintAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// `None`
	NewValue AttributeConstraintEnumDraft `json:"newValue"`
}

* * Updates the `attributeConstraint` of an AttributeDefinition(ctp:api:type:AttributeDefinition). For now only following changes are supported: `SameForAll` to `None` and `Unique` to `None`. *

func (ProductTypeChangeAttributeConstraintAction) MarshalJSON ¶

func (obj ProductTypeChangeAttributeConstraintAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeAttributeNameAction ¶

type ProductTypeChangeAttributeNameAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// New user-defined name of the Attribute that is unique with the [Project](ctp:api:type:Project).
	//
	// When using the same `name` for an Attribute in two or more ProductTypes, all fields of the AttributeDefinition of this Attribute must be the same across the ProductTypes. If not, an [AttributeDefinitionAlreadyExists](ctp:api:type:AttributeDefinitionAlreadyExistsError) error is returned.
	// An exception to this are the values of an `enum` or `lenum` type and sets thereof.
	NewAttributeName string `json:"newAttributeName"`
}

* * Renames an AttributeDefinition and also renames all corresponding Attributes on all [Products](/projects/products) with this ProductType. The renaming of the Attributes is [eventually consistent](/general-concepts#eventual-consistency). * * If the AttributeDefinition name to be changed does not exist, an [AttributeNameDoesNotExist](ctp:api:type:AttributeNameDoesNotExistError) error is returned. *

func (ProductTypeChangeAttributeNameAction) MarshalJSON ¶

func (obj ProductTypeChangeAttributeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeAttributeOrderAction ¶

type ProductTypeChangeAttributeOrderAction struct {
	Attributes []AttributeDefinition `json:"attributes"`
}

func (ProductTypeChangeAttributeOrderAction) MarshalJSON ¶

func (obj ProductTypeChangeAttributeOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeAttributeOrderByNameAction ¶

type ProductTypeChangeAttributeOrderByNameAction struct {
	// Names of Attributes to reorder. This array must include all Attributes currently present on a ProductType in a different order.
	AttributeNames []string `json:"attributeNames"`
}

func (ProductTypeChangeAttributeOrderByNameAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeDescriptionAction ¶

type ProductTypeChangeDescriptionAction struct {
	// New value to set.
	Description string `json:"description"`
}

func (ProductTypeChangeDescriptionAction) MarshalJSON ¶

func (obj ProductTypeChangeDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeEnumKeyAction ¶

type ProductTypeChangeEnumKeyAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// Existing key to be changed.
	Key string `json:"key"`
	// New key to be set.
	NewKey string `json:"newKey"`
}

* * Updates the key of a single enum `value` in an AttributeEnumType(ctp:api:type:AttributeEnumType) AttributeDefinition, AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType) AttributeDefinition, AttributeSetType(ctp:api:type:AttributeSetType) of AttributeEnumType AttributeDefinition, or AttributeSetType of AttributeLocalizedEnumType AttributeDefinition. * * If the AttributeDefinition does not contain an enum with the referenced key, a [EnumKeyDoesNotExist](ctp:api:type:EnumKeyDoesNotExistError) error is returned. * * All Products will be updated to the new key in an [eventually consistent](/general-concepts#eventual-consistency) way. *

func (ProductTypeChangeEnumKeyAction) MarshalJSON ¶

func (obj ProductTypeChangeEnumKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeInputHintAction ¶

type ProductTypeChangeInputHintAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// `SingleLine` or `MultiLine`
	NewValue TextInputHint `json:"newValue"`
}

* * Updates the `inputHint` of an AttributeDefinition(ctp:api:type:AttributeDefinition). *

func (ProductTypeChangeInputHintAction) MarshalJSON ¶

func (obj ProductTypeChangeInputHintAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeIsSearchableAction ¶

type ProductTypeChangeIsSearchableAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// Determines whether the Attribute's values can be used in full-text search queries, filters, and facets. See [AttributeDefinition](ctp:api:type:AttributeDefinition) for details.
	IsSearchable bool `json:"isSearchable"`
}

* * Following this update the Products are reindexed asynchronously to reflect this change on the search endpoint. When enabling search on an existing Attribute type definition, the constraint regarding the maximum size of a searchable Attribute will not be enforced. Instead, Product AttributeDefinitions exceeding this limit will be treated as not searchable and will not be available for full-text search. *

func (ProductTypeChangeIsSearchableAction) MarshalJSON ¶

func (obj ProductTypeChangeIsSearchableAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeLabelAction ¶

type ProductTypeChangeLabelAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// New value to set. Must not be empty.
	Label LocalizedString `json:"label"`
}

func (ProductTypeChangeLabelAction) MarshalJSON ¶

func (obj ProductTypeChangeLabelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeLocalizedEnumValueLabelAction ¶

type ProductTypeChangeLocalizedEnumValueLabelAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// New value to set. Must be different from the existing value.
	NewValue AttributeLocalizedEnumValue `json:"newValue"`
}

* * Updates the label of a single enum `value` in an AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType) AttributeDefinition, or AttributeSetType(ctp:api:type:AttributeSetType) of AttributeLocalizedEnumType AttributeDefinition. * * All Products will be updated to the new label in an [eventually consistent](/general-concepts#eventual-consistency) way. *

func (ProductTypeChangeLocalizedEnumValueLabelAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeLocalizedEnumValueOrderAction ¶

type ProductTypeChangeLocalizedEnumValueOrderAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// Values must be equal to the values of the Attribute enum values (except for the order). If not, an [EnumValuesMustMatch](ctp:api:type:EnumValuesMustMatchError) error is returned.
	Values []AttributeLocalizedEnumValue `json:"values"`
}

* * Updates the order of localized enum `values` in an AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType) AttributeDefinition. It can update an AttributeLocalizedEnumType AttributeDefinition or an AttributeSetType(ctp:api:type:AttributeSetType) of AttributeLocalizedEnumType AttributeDefinition. *

func (ProductTypeChangeLocalizedEnumValueOrderAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangeNameAction ¶

type ProductTypeChangeNameAction struct {
	// New value to set.
	Name string `json:"name"`
}

func (ProductTypeChangeNameAction) MarshalJSON ¶

func (obj ProductTypeChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangePlainEnumValueLabelAction ¶

type ProductTypeChangePlainEnumValueLabelAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// New value to set. Must be different from the existing value.
	NewValue AttributePlainEnumValue `json:"newValue"`
}

* * Updates the label of a single enum `value` in an AttributeEnumType(ctp:api:type:AttributeEnumType) AttributeDefinition, or AttributeSetType(ctp:api:type:AttributeSetType) of AttributeEnumType AttributeDefinition. * * All Products will be updated to the new label in an [eventually consistent](/general-concepts#eventual-consistency) way. *

func (ProductTypeChangePlainEnumValueLabelAction) MarshalJSON ¶

func (obj ProductTypeChangePlainEnumValueLabelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeChangePlainEnumValueOrderAction ¶

type ProductTypeChangePlainEnumValueOrderAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// Values must be equal to the values of the Attribute enum values (except for the order). If not, an [EnumValuesMustMatch](ctp:api:type:EnumValuesMustMatchError) error is returned.
	Values []AttributePlainEnumValue `json:"values"`
}

* * Updates the order of enum `values` in an AttributeEnumType(ctp:api:type:AttributeEnumType) AttributeDefinition. It can update an AttributeEnumType AttributeDefinition or an AttributeSetType(ctp:api:type:AttributeSetType) of AttributeEnumType AttributeDefinition. *

func (ProductTypeChangePlainEnumValueOrderAction) MarshalJSON ¶

func (obj ProductTypeChangePlainEnumValueOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeDraft ¶

type ProductTypeDraft struct {
	// User-defined unique identifier for the ProductType.
	Key *string `json:"key,omitempty"`
	// Name of the ProductType.
	Name string `json:"name"`
	// Description of the ProductType.
	Description string `json:"description"`
	// Attributes to specify for the ProductType. Products of this ProductType have these Attributes available on their [ProductVariants](ctp:api:type:ProductVariant).
	Attributes []AttributeDefinitionDraft `json:"attributes"`
}

func (ProductTypeDraft) MarshalJSON ¶

func (obj ProductTypeDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypePagedQueryResponse ¶

type ProductTypePagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [ProductTypes](ctp:api:type:ProductType) matching the query.
	Results []ProductType `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of ProductType(ctp:api:type:ProductType). *

type ProductTypeReference ¶

type ProductTypeReference struct {
	// Unique identifier of the referenced [ProductType](ctp:api:type:ProductType).
	ID string `json:"id"`
	// Contains the representation of the expanded ProductType. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for ProductTypes.
	Obj *ProductType `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a ProductType(ctp:api:type:ProductType). *

func (ProductTypeReference) MarshalJSON ¶

func (obj ProductTypeReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeRemoveAttributeDefinitionAction ¶

type ProductTypeRemoveAttributeDefinitionAction struct {
	// Name of the Attribute to remove.
	Name string `json:"name"`
}

* * Removes an AttributeDefinition and also deletes all corresponding Attributes on all [Products](/projects/products) with this ProductType. The removal of the Attributes is [eventually consistent](/general-concepts#eventual-consistency). * * The `CombinationUnique` constraint is not checked when an Attribute is removed, and uniqueness violations may occur when you remove an Attribute with a `CombinationUnique` constraint. *

func (ProductTypeRemoveAttributeDefinitionAction) MarshalJSON ¶

func (obj ProductTypeRemoveAttributeDefinitionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeRemoveEnumValuesAction ¶

type ProductTypeRemoveEnumValuesAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// Keys of [AttributeEnumType](ctp:api:type:AttributeEnumType) or [AttributeLocalizedEnumType](ctp:api:type:AttributeLocalizedEnumType) to remove.
	Keys []string `json:"keys"`
}

* * Removes enum values from an AttributeDefinition of AttributeEnumType(ctp:api:type:AttributeEnumType), AttributeLocalizedEnumType(ctp:api:type:AttributeLocalizedEnumType), AttributeSetType(ctp:api:type:AttributeSetType) of AttributeEnumType, or AttributeSetType of AttributeLocalizedEnumType. * * If the Attribute is **not** required, the Attributes of all Products using those enum keys will also be removed in an [eventually consistent](/general-concepts#eventual-consistency) way. If the Attribute is required, the operation returns an [EnumValueIsUsed](ctp:api:type:EnumValueIsUsedError) error. *

func (ProductTypeRemoveEnumValuesAction) MarshalJSON ¶

func (obj ProductTypeRemoveEnumValuesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeResourceIdentifier ¶

type ProductTypeResourceIdentifier struct {
	// Unique identifier of the referenced [ProductType](ctp:api:type:ProductType). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [ProductType](ctp:api:type:ProductType). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a ProductType(ctp:api:type:ProductType). *

func (ProductTypeResourceIdentifier) MarshalJSON ¶

func (obj ProductTypeResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeSetInputTipAction ¶

type ProductTypeSetInputTipAction struct {
	// Name of the AttributeDefinition to update.
	AttributeName string `json:"attributeName"`
	// Value to set. If empty, any existing value will be removed.
	InputTip *LocalizedString `json:"inputTip,omitempty"`
}

func (ProductTypeSetInputTipAction) MarshalJSON ¶

func (obj ProductTypeSetInputTipAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeSetKeyAction ¶

type ProductTypeSetKeyAction struct {
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

func (ProductTypeSetKeyAction) MarshalJSON ¶

func (obj ProductTypeSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductTypeUpdate ¶

type ProductTypeUpdate struct {
	// Expected version of the ProductType on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the ProductType.
	Actions []ProductTypeUpdateAction `json:"actions"`
}

func (*ProductTypeUpdate) UnmarshalJSON ¶

func (obj *ProductTypeUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductTypeUpdateAction ¶

type ProductTypeUpdateAction interface{}

type ProductUnpublishAction ¶

type ProductUnpublishAction struct {
}

* * Removes the current [projection](/../api/projects/productProjections#current--staged) of the Product. The staged projection is unaffected. To retrieve unpublished Products, the `staged` parameter must be set to `false` when [querying](/projects/productProjections#query-productprojections)/[searching](/projects/products-search#product-projection-search) Product Projections. Produces the [ProductUnpublished](ctp:api:type:ProductUnpublishedMessage) Message. * * Unpublished Products cannot be added to a Cart. However, if a Cart contains Line Items for Products that were added before the Product was unpublished, the Cart is unaffected and can still be used to create an Order. To prevent this, in addition to unpublishing the Product you should remove the Prices from the Product using [Remove Price](ctp:api:type:ProductRemovePriceAction) for Embedded Prices or [Delete StandalonePrice](/projects/standalone-prices#delete-standaloneprice) for Standalone Prices. *

func (ProductUnpublishAction) MarshalJSON ¶

func (obj ProductUnpublishAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductUnpublishedMessage ¶

type ProductUnpublishedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
}

* * Generated after a successful [Unpublish Product](ctp:api:type:ProductUnpublishAction) update action. *

func (ProductUnpublishedMessage) MarshalJSON ¶

func (obj ProductUnpublishedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductUnpublishedMessage) UnmarshalJSON ¶

func (obj *ProductUnpublishedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductUnpublishedMessagePayload ¶

type ProductUnpublishedMessagePayload struct {
}

* * Generated after a successful [Unpublish Product](ctp:api:type:ProductUnpublishAction) update action. *

func (ProductUnpublishedMessagePayload) MarshalJSON ¶

func (obj ProductUnpublishedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductUpdate ¶

type ProductUpdate struct {
	// Expected version of the Product on which the changes should be applied. If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the Product.
	Actions []ProductUpdateAction `json:"actions"`
}

func (*ProductUpdate) UnmarshalJSON ¶

func (obj *ProductUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductUpdateAction ¶

type ProductUpdateAction interface{}

type ProductVariant ¶

type ProductVariant struct {
	// A unique, sequential identifier of the Product Variant within the Product.
	ID int `json:"id"`
	// User-defined unique SKU of the Product Variant.
	Sku *string `json:"sku,omitempty"`
	// User-defined unique identifier of the ProductVariant.
	//
	// This is different from [Product](ctp:api:type:Product) `key`.
	Key *string `json:"key,omitempty"`
	// The Embedded Prices of the Product Variant.
	// Cannot contain two Prices of the same Price scope (with same currency, country, Customer Group, Channel, `validFrom` and `validUntil`).
	Prices []Price `json:"prices"`
	// Attributes of the Product Variant.
	Attributes []Attribute `json:"attributes"`
	// Only available when [Price selection](#price-selection) is used.
	// Cannot be used in a [Query Predicate](ctp:api:type:QueryPredicate).
	Price *Price `json:"price,omitempty"`
	// Images of the Product Variant.
	Images []Image `json:"images"`
	// Media assets of the Product Variant.
	Assets []Asset `json:"assets"`
	// Set if the Product Variant is tracked by [Inventory](ctp:api:type:InventoryEntry).
	// Can be used as an optimization to reduce calls to the Inventory service.
	// May not contain the latest Inventory State (it is [eventually consistent](/general-concepts#eventual-consistency)).
	Availability *ProductVariantAvailability `json:"availability,omitempty"`
	// `true` if the Product Variant matches the search query.
	// Only available in response to a [Product Projection Search](ctp:api:type:ProductProjectionSearch) request.
	IsMatchingVariant *bool `json:"isMatchingVariant,omitempty"`
	// Only available in response to a [Product Projection Search](ctp:api:type:ProductProjectionSearch) request
	// with [price selection](ctp:api:type:ProductPriceSelection).
	// Can be used to sort, [filter](ctp:api:type:ProductProjectionSearchFilterScopedPrice), and facet.
	ScopedPrice *ScopedPrice `json:"scopedPrice,omitempty"`
	// Only available in response to a [Product Projection Search](ctp:api:type:ProductProjectionSearchFilterScopedPrice) request
	// with [price selection](ctp:api:type:ProductPriceSelection).
	ScopedPriceDiscounted *bool `json:"scopedPriceDiscounted,omitempty"`
}

* * A concrete sellable good for which inventory can be tracked. Product Variants are generally mapped to specific SKUs. *

func (ProductVariant) MarshalJSON ¶

func (obj ProductVariant) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductVariantAddedMessage ¶

type ProductVariantAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Product Variant](ctp:api:type:ProductVariant) that was added.
	Variant ProductVariant `json:"variant"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Add Product Variant](ctp:api:type:ProductAddVariantAction) update action. *

func (ProductVariantAddedMessage) MarshalJSON ¶

func (obj ProductVariantAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductVariantAddedMessage) UnmarshalJSON ¶

func (obj *ProductVariantAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductVariantAddedMessagePayload ¶

type ProductVariantAddedMessagePayload struct {
	// Unique identifier of the [Product Variant](ctp:api:type:ProductVariant) that was added.
	Variant ProductVariant `json:"variant"`
	// Whether the update was only applied to the staged [Product Projection](ctp:api:type:ProductProjection).
	Staged bool `json:"staged"`
}

* * Generated after a successful [Add Product Variant](ctp:api:type:ProductAddVariantAction) update action. *

func (ProductVariantAddedMessagePayload) MarshalJSON ¶

func (obj ProductVariantAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductVariantAvailability ¶

type ProductVariantAvailability struct {
	// For each [InventoryEntry](ctp:api:type:InventoryEntry) with a supply Channel, an entry is added to `channels`.
	Channels *ProductVariantChannelAvailabilityMap `json:"channels,omitempty"`
	// Indicates whether a Product Variant is in stock.
	IsOnStock *bool `json:"isOnStock,omitempty"`
	// Number of days to restock a Product Variant once it is out of stock.
	RestockableInDays *int `json:"restockableInDays,omitempty"`
	// Number of items of the Product Variant that are in stock.
	AvailableQuantity *int `json:"availableQuantity,omitempty"`
}

* * The InventoryEntry(ctp:api:type:InventoryEntry) information of the Product Variant. If there is a supply Channel(ctp:api:type:Channel) for the InventoryEntry, then `channels` is returned. If not, then `isOnStock`, `restockableInDays`, and `quantityOnStock` are returned. *

type ProductVariantChannelAvailability ¶

type ProductVariantChannelAvailability struct {
	// Indicates whether a Product Variant is in stock in a specified [Channel](ctp:api:type:Channel).
	IsOnStock *bool `json:"isOnStock,omitempty"`
	// Number of days to restock a Product Variant once it is out of stock in a specified [Channel](ctp:api:type:Channel).
	RestockableInDays *int `json:"restockableInDays,omitempty"`
	// Number of items of this Product Variant that are in stock in a specified [Channel](ctp:api:type:Channel).
	AvailableQuantity *int `json:"availableQuantity,omitempty"`
	// Unique identifier of the [InventoryEntry](ctp:api:type:InventoryEntry).
	ID string `json:"id"`
	// Current version of the [InventoryEntry](ctp:api:type:InventoryEntry).
	Version int `json:"version"`
}

type ProductVariantChannelAvailabilityMap ¶

type ProductVariantChannelAvailabilityMap map[string]ProductVariantChannelAvailability

* * JSON object where the key is a supply Channel(ctp:api:type:Channel) `id` and the value is the ProductVariantChannelAvailability(ctp:api:type:ProductVariantChannelAvailability) of the InventoryEntry(ctp:api:type:InventoryEntry). *

type ProductVariantDeletedMessage ¶

type ProductVariantDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Unique identifier of the [Product Variant](ctp:api:type:ProductVariant) that was added.
	Variant *ProductVariant `json:"variant,omitempty"`
	// List of image URLs that were removed with the [Remove Product Variant](ctp:api:type:ProductRemoveVariantAction) update action.
	RemovedImageUrls []string `json:"removedImageUrls"`
}

* * Generated after a successful [Remove Product Variant](ctp:api:type:ProductRemoveVariantAction) update action. *

func (ProductVariantDeletedMessage) MarshalJSON ¶

func (obj ProductVariantDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProductVariantDeletedMessage) UnmarshalJSON ¶

func (obj *ProductVariantDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProductVariantDeletedMessagePayload ¶

type ProductVariantDeletedMessagePayload struct {
	// Unique identifier of the [Product Variant](ctp:api:type:ProductVariant) that was added.
	Variant *ProductVariant `json:"variant,omitempty"`
	// List of image URLs that were removed with the [Remove Product Variant](ctp:api:type:ProductRemoveVariantAction) update action.
	RemovedImageUrls []string `json:"removedImageUrls"`
}

* * Generated after a successful [Remove Product Variant](ctp:api:type:ProductRemoveVariantAction) update action. *

func (ProductVariantDeletedMessagePayload) MarshalJSON ¶

func (obj ProductVariantDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductVariantDraft ¶

type ProductVariantDraft struct {
	// User-defined unique SKU of the Product Variant.
	Sku *string `json:"sku,omitempty"`
	// User-defined unique identifier for the ProductVariant.
	Key *string `json:"key,omitempty"`
	// The Embedded Prices for the Product Variant.
	// Each Price must have its unique Price scope (with same currency, country, Customer Group, Channel, `validFrom` and `validUntil`).
	Prices []PriceDraft `json:"prices"`
	// Attributes according to the respective [AttributeDefinition](ctp:api:type:AttributeDefinition).
	Attributes []Attribute `json:"attributes"`
	// Images for the Product Variant.
	Images []Image `json:"images"`
	// Media assets for the Product Variant.
	Assets []AssetDraft `json:"assets"`
}

* * Creates a Product Variant when included in the `masterVariant` and `variants` fields of the ProductDraft(ctp:api:type:ProductDraft). *

func (ProductVariantDraft) MarshalJSON ¶

func (obj ProductVariantDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductVariantExclusion ¶

type ProductVariantExclusion struct {
	// Non-empty array of SKUs representing Product Variants to be included in the Product Selection with `IndividualExclusion` [ProductSelectionMode](ctp:api:type:ProductSelectionMode).
	Skus []string `json:"skus"`
}

* * Only Product Variants with the explicitly listed SKUs are part of a Product Selection with `IndividualExclusion` ProductSelectionMode(ctp:api:type:ProductSelectionMode). *

type ProductVariantImportDraft ¶

type ProductVariantImportDraft struct {
	// The sequential ID of the variant within the product.
	// The variant with provided ID should exist in some existing product, so you also need to specify the productId if this property is set,
	// or alternatively you can just specify SKU of the product variant.
	ID *int `json:"id,omitempty"`
	// The SKU of the existing variant.
	Sku *string `json:"sku,omitempty"`
	// The [Embedded Prices](ctp:api:type:Price) of the variant.
	// The prices should not contain two prices for the same price scope (same currency, country, customer group, channel, valid from and valid until).
	// If this property is defined, then it will override the `prices` property from the original product variant, otherwise `prices` property from the original product variant would be copied in the resulting order.
	Prices []PriceDraft `json:"prices"`
	// If this property is defined, then it will override the `attributes` property from the original
	// product variant, otherwise `attributes` property from the original product variant would be copied in the resulting order.
	Attributes []Attribute `json:"attributes"`
	// If this property is defined, then it will override the `images` property from the original
	// product variant, otherwise `images` property from the original product variant would be copied in the resulting order.
	Images []Image `json:"images"`
}

func (ProductVariantImportDraft) MarshalJSON ¶

func (obj ProductVariantImportDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductVariantSelection ¶

type ProductVariantSelection interface{}

* * Polymorphic base type for Product Variant Selections. The actual type is determined by the `type` field. *

type ProductVariantSelectionExclusion ¶

type ProductVariantSelectionExclusion struct {
	// Non-empty array of SKUs representing Product Variants to be excluded from the Product Selection.
	Skus []string `json:"skus"`
}

* * All Product Variants except the explicitly stated SKUs are part of the Product Selection. *

func (ProductVariantSelectionExclusion) MarshalJSON ¶

func (obj ProductVariantSelectionExclusion) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductVariantSelectionIncludeAllExcept ¶

type ProductVariantSelectionIncludeAllExcept struct {
	// Non-empty array of SKUs representing Product Variants to be excluded from the Product Selection.
	Skus []string `json:"skus"`
}

* * All Product Variants except the explicitly stated SKUs are part of the Product Selection. *

func (ProductVariantSelectionIncludeAllExcept) MarshalJSON ¶

func (obj ProductVariantSelectionIncludeAllExcept) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductVariantSelectionIncludeOnly ¶

type ProductVariantSelectionIncludeOnly struct {
	// Non-empty array of SKUs representing Product Variants to be included into the Product Selection.
	Skus []string `json:"skus"`
}

* * Only Product Variants with explicitly stated SKUs are part of the Product Selection. *

func (ProductVariantSelectionIncludeOnly) MarshalJSON ¶

func (obj ProductVariantSelectionIncludeOnly) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductVariantSelectionInclusion ¶

type ProductVariantSelectionInclusion struct {
	// Non-empty array of SKUs representing Product Variants to be included into the Product Selection.
	Skus []string `json:"skus"`
}

* * Only Product Variants with explicitly stated SKUs are part of the Product Selection. *

func (ProductVariantSelectionInclusion) MarshalJSON ¶

func (obj ProductVariantSelectionInclusion) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProductVariantSelectionTypeEnum ¶

type ProductVariantSelectionTypeEnum string
const (
	ProductVariantSelectionTypeEnumInclusion        ProductVariantSelectionTypeEnum = "inclusion"
	ProductVariantSelectionTypeEnumExclusion        ProductVariantSelectionTypeEnum = "exclusion"
	ProductVariantSelectionTypeEnumIncludeOnly      ProductVariantSelectionTypeEnum = "includeOnly"
	ProductVariantSelectionTypeEnumIncludeAllExcept ProductVariantSelectionTypeEnum = "includeAllExcept"
)

type ProductsInStorePagedQueryResponse ¶

type ProductsInStorePagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/general-concepts#strong-consistency).
	// Unlike other endpoints, the Product Selection endpoint does not return this field by default.
	// To get `total`, pass the query parameter `withTotal` set to `true`.
	// When the results are filtered with a [Query Predicate](/predicates/query), `total` is subject to a [limit](/limits#queries).
	Total *int `json:"total,omitempty"`
	// ProductSelectionAssignments matching the query.
	Results []ProductSelectionAssignment `json:"results"`
}

* * [PagedQueryResult](/general-concepts#pagedqueryresult) containing an array of ProductSelectionAssignment(ctp:api:type:ProductSelectionAssignment). *

type Project ¶

type Project struct {
	// Current version of the Project.
	Version int `json:"version"`
	// User-defined unique identifier of the Project.
	Key string `json:"key"`
	// Name of the Project.
	Name string `json:"name"`
	// Country code of the geographic location.
	Countries []string `json:"countries"`
	// Currency code of the country. A Project must have at least one currency.
	Currencies []string `json:"currencies"`
	// Language of the country. A Project must have at least one language.
	Languages []string `json:"languages"`
	// Date and time (UTC) the Project was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date in YYYY-MM format specifying when the trial period for the Project ends. Only present on Projects in trial period.
	TrialUntil *string `json:"trialUntil,omitempty"`
	// Holds the configuration for the [Messages Query](/../api/projects/messages) feature.
	Messages MessagesConfiguration `json:"messages"`
	// Holds the configuration for the [Carts](/../api/projects/carts) feature.
	Carts CartsConfiguration `json:"carts"`
	// Holds the configuration for the [Shopping Lists](/../api/projects/shoppingLists) feature. This field may not be present on Projects created before January 2020.
	ShoppingLists *ShoppingListsConfiguration `json:"shoppingLists,omitempty"`
	// Holds the configuration for the [tiered shipping rates](ctp:api:type:ShippingRatePriceTier) feature.
	ShippingRateInputType ShippingRateInputType `json:"shippingRateInputType,omitempty"`
	// Represents a RFC 7662 compliant [OAuth 2.0 Token Introspection](https://datatracker.ietf.org/doc/html/rfc7662) endpoint.
	ExternalOAuth *ExternalOAuth `json:"externalOAuth,omitempty"`
	// Controls indexing of resources to be provided on high performance read-only search endpoints.
	SearchIndexing *SearchIndexingConfiguration `json:"searchIndexing,omitempty"`
	// Holds configuration specific to [Business Units](ctp:api:type:BusinessUnit).
	BusinessUnits *BusinessUnitConfiguration `json:"businessUnits,omitempty"`
}

func (*Project) UnmarshalJSON ¶

func (obj *Project) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProjectChangeBusinessUnitStatusOnCreationAction ¶

type ProjectChangeBusinessUnitStatusOnCreationAction struct {
	// Status for Business Units created using the [My Business Unit endpoint](ctp:api:endpoint:/{projectKey}/me/business-units:POST).
	Status BusinessUnitConfigurationStatus `json:"status"`
}

func (ProjectChangeBusinessUnitStatusOnCreationAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectChangeCartsConfigurationAction ¶

type ProjectChangeCartsConfigurationAction struct {
	// Configuration for the [Carts](/../api/projects/carts) feature.
	CartsConfiguration CartsConfiguration `json:"cartsConfiguration"`
}

func (ProjectChangeCartsConfigurationAction) MarshalJSON ¶

func (obj ProjectChangeCartsConfigurationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectChangeCountriesAction ¶

type ProjectChangeCountriesAction struct {
	// New value to set. Must not be empty.
	Countries []string `json:"countries"`
}

func (ProjectChangeCountriesAction) MarshalJSON ¶

func (obj ProjectChangeCountriesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectChangeCountryTaxRateFallbackEnabledAction ¶

type ProjectChangeCountryTaxRateFallbackEnabledAction struct {
	// When `true`, country _- no state_ Tax Rate is used as fallback. See [CartsConfiguration](ctp:api:type:CartsConfiguration).
	CountryTaxRateFallbackEnabled bool `json:"countryTaxRateFallbackEnabled"`
}

func (ProjectChangeCountryTaxRateFallbackEnabledAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectChangeCurrenciesAction ¶

type ProjectChangeCurrenciesAction struct {
	// New value to set. Must not be empty.
	Currencies []string `json:"currencies"`
}

func (ProjectChangeCurrenciesAction) MarshalJSON ¶

func (obj ProjectChangeCurrenciesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectChangeLanguagesAction ¶

type ProjectChangeLanguagesAction struct {
	// New value to set. Must not be empty.
	Languages []string `json:"languages"`
}

* * Removing a language used by a Store(ctp:api:type:Store) returns a [LanguageUsedInStores](ctp:api:type:LanguageUsedInStoresError) error. *

func (ProjectChangeLanguagesAction) MarshalJSON ¶

func (obj ProjectChangeLanguagesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectChangeMessagesConfigurationAction ¶

type ProjectChangeMessagesConfigurationAction struct {
	// Configuration for the [Messages Query](/../api/projects/messages) feature.
	MessagesConfiguration MessagesConfigurationDraft `json:"messagesConfiguration"`
}

func (ProjectChangeMessagesConfigurationAction) MarshalJSON ¶

func (obj ProjectChangeMessagesConfigurationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectChangeMessagesEnabledAction ¶

type ProjectChangeMessagesEnabledAction struct {
	MessagesEnabled bool `json:"messagesEnabled"`
}

func (ProjectChangeMessagesEnabledAction) MarshalJSON ¶

func (obj ProjectChangeMessagesEnabledAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectChangeNameAction ¶

type ProjectChangeNameAction struct {
	// New value to set. Must not be empty.
	Name string `json:"name"`
}

func (ProjectChangeNameAction) MarshalJSON ¶

func (obj ProjectChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectChangeOrderSearchStatusAction ¶

type ProjectChangeOrderSearchStatusAction struct {
	// Activates or deactivates the [Order Search](/../api/projects/order-search) feature. Activation will trigger building a search index for the Orders in the Project.
	Status OrderSearchStatus `json:"status"`
}

func (ProjectChangeOrderSearchStatusAction) MarshalJSON ¶

func (obj ProjectChangeOrderSearchStatusAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectChangeProductSearchIndexingEnabledAction ¶

type ProjectChangeProductSearchIndexingEnabledAction struct {
	// - If `false`, the indexing of [Product](ctp:api:type:Product) information will stop and the [Product Projection Search](/../api/projects/products-search) as well as the [Product Suggestions](/../api/projects/products-suggestions) endpoint will not be available anymore for this Project. The Project's [SearchIndexingConfiguration](ctp:api:type:SearchIndexingConfiguration) `status` for `products` will be changed to `"Deactivated"`.
	// - If `true`, the indexing of [Product](ctp:api:type:Product) information will start and the [Product Projection Search](/../api/projects/products-search) as well as the [Product Suggestions](/../api/projects/products-suggestions) endpoint will become available soon after for this Project. Proportional to the amount of information being indexed, the Project's [SearchIndexingConfiguration](ctp:api:type:SearchIndexingConfiguration) `status` for `products` will be shown as `"Indexing"` during this time. As soon as the indexing has finished, the configuration status will be changed to `"Activated"` making the aforementioned endpoints fully available for this Project.
	Enabled bool `json:"enabled"`
}

func (ProjectChangeProductSearchIndexingEnabledAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectChangeShoppingListsConfigurationAction ¶

type ProjectChangeShoppingListsConfigurationAction struct {
	// Configuration for the [Shopping Lists](/../api/projects/shoppingLists) feature.
	ShoppingListsConfiguration ShoppingListsConfiguration `json:"shoppingListsConfiguration"`
}

func (ProjectChangeShoppingListsConfigurationAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectNotConfiguredForLanguagesError ¶

type ProjectNotConfiguredForLanguagesError struct {
	// `"The project is not configured for given languages."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Languages configured for the Store.
	Languages []string `json:"languages"`
}

* * Returned when the languages set for a Store are not supported by the Project. * * The error is returned as a failed response to the [Set Languages](ctp:api:type:StoreSetLanguagesAction) update action. *

func (*ProjectNotConfiguredForLanguagesError) DecodeStruct ¶

func (obj *ProjectNotConfiguredForLanguagesError) DecodeStruct(src map[string]interface{}) error

func (ProjectNotConfiguredForLanguagesError) Error ¶

func (ProjectNotConfiguredForLanguagesError) MarshalJSON ¶

func (obj ProjectNotConfiguredForLanguagesError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProjectNotConfiguredForLanguagesError) UnmarshalJSON ¶

func (obj *ProjectNotConfiguredForLanguagesError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProjectSetBusinessUnitAssociateRoleOnCreationAction ¶

type ProjectSetBusinessUnitAssociateRoleOnCreationAction struct {
	// Default [Associate Role](ctp:api:type:AssociateRole) assigned to the Associate creating a Business Unit using the [My Business Unit endpoint](ctp:api:endpoint:/{projectKey}/me/business-units:POST).
	AssociateRole AssociateRoleResourceIdentifier `json:"associateRole"`
}

func (ProjectSetBusinessUnitAssociateRoleOnCreationAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectSetExternalOAuthAction ¶

type ProjectSetExternalOAuthAction struct {
	// Value to set. If empty, any existing value will be removed.
	ExternalOAuth *ExternalOAuth `json:"externalOAuth,omitempty"`
}

func (ProjectSetExternalOAuthAction) MarshalJSON ¶

func (obj ProjectSetExternalOAuthAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ProjectSetShippingRateInputTypeAction ¶

type ProjectSetShippingRateInputTypeAction struct {
	// Value to set. If empty, any existing value will be removed.
	ShippingRateInputType ShippingRateInputType `json:"shippingRateInputType,omitempty"`
}

func (ProjectSetShippingRateInputTypeAction) MarshalJSON ¶

func (obj ProjectSetShippingRateInputTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ProjectSetShippingRateInputTypeAction) UnmarshalJSON ¶

func (obj *ProjectSetShippingRateInputTypeAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProjectUpdate ¶

type ProjectUpdate struct {
	// Expected version of the Project on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the Project.
	Actions []ProjectUpdateAction `json:"actions"`
}

func (*ProjectUpdate) UnmarshalJSON ¶

func (obj *ProjectUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ProjectUpdateAction ¶

type ProjectUpdateAction interface{}

type QueryComplexityLimitExceededError ¶

type QueryComplexityLimitExceededError struct {
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

func (*QueryComplexityLimitExceededError) DecodeStruct ¶

func (obj *QueryComplexityLimitExceededError) DecodeStruct(src map[string]interface{}) error

func (QueryComplexityLimitExceededError) Error ¶

func (QueryComplexityLimitExceededError) MarshalJSON ¶

func (obj QueryComplexityLimitExceededError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QueryComplexityLimitExceededError) UnmarshalJSON ¶

func (obj *QueryComplexityLimitExceededError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QueryPrice ¶

type QueryPrice struct {
	// Unique identifier of the given Price.
	ID *string `json:"id,omitempty"`
	// Money value of the given Price.
	Value Money `json:"value"`
	// Country for which the given Price is valid.
	Country *string `json:"country,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) for which the given Price is valid.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// `ProductDistribution` [Channel](ctp:api:type:Channel) for which the given Price is valid.
	Channel *ChannelReference `json:"channel,omitempty"`
	// Date from which the given Price is valid.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date until which the given Price is valid.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// [DiscountedPrice](ctp:api:type:DiscountedPrice) you specify for the given Price.
	Discounted *DiscountedPriceDraft `json:"discounted,omitempty"`
	// Custom Fields for the Price.
	Custom *CustomFields `json:"custom,omitempty"`
	// Price tier applied when the minimum quantity for the [LineItem](ctp:api:type:LineItem) of a ProductVariant with the related Price is reached in a Cart.
	Tiers []PriceTierDraft `json:"tiers"`
}

func (QueryPrice) MarshalJSON ¶

func (obj QueryPrice) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QueryTimedOutError ¶

type QueryTimedOutError struct {
	// `"The query timed out. If your query constantly times out, please check that it follows the performance best practices (see https://docs.commercetools.com/api/predicates/query#performance-considerations)."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the query times out. * * If a query constantly times out, please check if it follows the [performance best practices](/../api/predicates/query#performance-considerations). *

func (*QueryTimedOutError) DecodeStruct ¶

func (obj *QueryTimedOutError) DecodeStruct(src map[string]interface{}) error

func (QueryTimedOutError) Error ¶

func (obj QueryTimedOutError) Error() string

func (QueryTimedOutError) MarshalJSON ¶

func (obj QueryTimedOutError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QueryTimedOutError) UnmarshalJSON ¶

func (obj *QueryTimedOutError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type Quote ¶

type Quote struct {
	// Unique identifier of the Quote.
	ID string `json:"id"`
	// Current version of the Quote.
	Version int `json:"version"`
	// Date and time (UTC) the Quote was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Quote was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// User-defined unique identifier of the Quote.
	Key *string `json:"key,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Quote Request related to the Quote.
	QuoteRequest QuoteRequestReference `json:"quoteRequest"`
	// Staged Quote related to the Quote.
	StagedQuote StagedQuoteReference `json:"stagedQuote"`
	// The [Buyer](/../api/quotes-overview#buyer) who owns the Quote.
	Customer *CustomerReference `json:"customer,omitempty"`
	// Set automatically when `customer` is set and the Customer is a member of a Customer Group.
	// Not updated if Customer is changed after Quote creation.
	// Used for Product Variant price selection.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// Expiration date for the Quote.
	ValidTo *time.Time `json:"validTo,omitempty"`
	// Message from the [Seller](/../api/quotes-overview#seller) included in the offer.
	SellerComment *string `json:"sellerComment,omitempty"`
	// Message from the [Buyer](/../api/quotes-overview#buyer) included in the [renegotiation request](ctp:api:type:QuoteRequestQuoteRenegotiationAction).
	BuyerComment *string `json:"buyerComment,omitempty"`
	// The Store to which the [Buyer](/../api/quotes-overview#buyer) belongs.
	Store *StoreKeyReference `json:"store,omitempty"`
	// The Line Items for which the Quote is requested.
	LineItems []LineItem `json:"lineItems"`
	// The Custom Line Items for which the Quote is requested.
	CustomLineItems []CustomLineItem `json:"customLineItems"`
	// Sum of all `totalPrice` fields of the `lineItems` and `customLineItems`, as well as the `price` field of `shippingInfo` (if it exists).
	// `totalPrice` may or may not include the taxes: it depends on the taxRate.includedInPrice property of each price.
	TotalPrice TypedMoney `json:"totalPrice"`
	// Not set until the shipping address is set.
	// Will be set automatically in the `Platform` TaxMode.
	// For the `External` tax mode it will be set  as soon as the external tax rates for all line items, custom line items, and shipping in the cart are set.
	TaxedPrice *TaxedPrice `json:"taxedPrice,omitempty"`
	// Used to determine the eligible [ShippingMethods](ctp:api:type:ShippingMethod)
	// and rates as well as the tax rate of the Line Items.
	ShippingAddress *Address `json:"shippingAddress,omitempty"`
	// Address used for invoicing.
	BillingAddress *Address `json:"billingAddress,omitempty"`
	// Inventory mode of the Cart referenced in the [QuoteRequestDraft](ctp:api:type:QuoteRequestDraft).
	InventoryMode *InventoryMode `json:"inventoryMode,omitempty"`
	// Tax mode of the Cart referenced in the [QuoteRequestDraft](ctp:api:type:QuoteRequestDraft).
	TaxMode TaxMode `json:"taxMode"`
	// When calculating taxes for `taxedPrice`, the selected mode is used for rounding.
	TaxRoundingMode RoundingMode `json:"taxRoundingMode"`
	// When calculating taxes for `taxedPrice`, the selected mode is used for calculating the price with `LineItemLevel` (horizontally) or `UnitPriceLevel` (vertically) calculation mode.
	TaxCalculationMode TaxCalculationMode `json:"taxCalculationMode"`
	// Used for Product Variant price selection.
	Country *string `json:"country,omitempty"`
	// Set automatically once the [ShippingMethod](ctp:api:type:ShippingMethod) is set.
	ShippingInfo *ShippingInfo `json:"shippingInfo,omitempty"`
	// Log of payment transactions related to the Quote.
	PaymentInfo *PaymentInfo `json:"paymentInfo,omitempty"`
	// Used to select a [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	ShippingRateInput ShippingRateInput `json:"shippingRateInput,omitempty"`
	// Contains addresses for carts with multiple shipping addresses.
	// Line items reference these addresses under their `shippingDetails`.
	// The addresses captured here are not used to determine eligible shipping methods or the applicable tax rate.
	// Only the cart's `shippingAddress` is used for this.
	ItemShippingAddresses []Address `json:"itemShippingAddresses"`
	// Discounts that are only valid for the Quote and cannot be associated to any other Cart or Order.
	DirectDiscounts []DirectDiscount `json:"directDiscounts"`
	// Custom Fields on the Quote.
	Custom *CustomFields `json:"custom,omitempty"`
	// Predefined states tracking the status of the Quote.
	QuoteState QuoteState `json:"quoteState"`
	// [State](ctp:api:type:State) of the Quote.
	// This reference can point to a State in a custom workflow.
	State *StateReference `json:"state,omitempty"`
	// The Purchase Order Number is typically set by the [Buyer](/quotes-overview#buyer) on a [QuoteRequest](ctp:api:type:QuoteRequest) to
	// track the purchase order during the [quote and order flow](/../api/quotes-overview#intended-workflow).
	PurchaseOrderNumber *string `json:"purchaseOrderNumber,omitempty"`
	// The [BusinessUnit](ctp:api:type:BusinessUnit) for the Quote.
	BusinessUnit *BusinessUnitKeyReference `json:"businessUnit,omitempty"`
}

func (Quote) MarshalJSON ¶

func (obj Quote) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*Quote) UnmarshalJSON ¶

func (obj *Quote) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteChangeCustomerAction ¶

type QuoteChangeCustomerAction struct {
	// New Customer to own the Quote.
	Customer CustomerResourceIdentifier `json:"customer"`
}

* * Changes the owner of a Quote to a different Customer. * Customer Group is not updated. * This update action produces the [Quote Customer Changed](ctp:api:type:QuoteCustomerChangedMessage) Message. *

func (QuoteChangeCustomerAction) MarshalJSON ¶

func (obj QuoteChangeCustomerAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteChangeQuoteStateAction ¶

type QuoteChangeQuoteStateAction struct {
	// New state to be set for the Quote.
	QuoteState QuoteState `json:"quoteState"`
}

func (QuoteChangeQuoteStateAction) MarshalJSON ¶

func (obj QuoteChangeQuoteStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteCreatedMessage ¶

type QuoteCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Quote](/../api/projects/quotes) that was created.
	Quote Quote `json:"quote"`
}

* * Generated after a successful [Create Quote](/../api/projects/quotes#create-quote) request. *

func (QuoteCreatedMessage) MarshalJSON ¶

func (obj QuoteCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QuoteCreatedMessage) UnmarshalJSON ¶

func (obj *QuoteCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteCreatedMessagePayload ¶

type QuoteCreatedMessagePayload struct {
	// [Quote](/../api/projects/quotes) that was created.
	Quote Quote `json:"quote"`
}

* * Generated after a successful [Create Quote](/../api/projects/quotes#create-quote) request. *

func (QuoteCreatedMessagePayload) MarshalJSON ¶

func (obj QuoteCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteCustomerChangedMessage ¶

type QuoteCustomerChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [Buyer](/../api/quotes-overview#buyer) who now owns the Quote.
	Customer CustomerReference `json:"customer"`
	// The previous [Buyer](/../api/quotes-overview#buyer).
	PreviousCustomer CustomerReference `json:"previousCustomer"`
}

* * Generated after a successful [Change Customer](ctp:api:type:QuoteChangeCustomerAction) update action. *

func (QuoteCustomerChangedMessage) MarshalJSON ¶

func (obj QuoteCustomerChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QuoteCustomerChangedMessage) UnmarshalJSON ¶

func (obj *QuoteCustomerChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteCustomerChangedMessagePayload ¶

type QuoteCustomerChangedMessagePayload struct {
	// The [Buyer](/../api/quotes-overview#buyer) who now owns the Quote.
	Customer CustomerReference `json:"customer"`
	// The previous [Buyer](/../api/quotes-overview#buyer).
	PreviousCustomer CustomerReference `json:"previousCustomer"`
}

* * Generated after a successful [Change Customer](ctp:api:type:QuoteChangeCustomerAction) update action. *

func (QuoteCustomerChangedMessagePayload) MarshalJSON ¶

func (obj QuoteCustomerChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteDeletedMessage ¶

type QuoteDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
}

* * Generated after a successful [Delete Quote](/../api/projects/quotes#delete-quote) request. *

func (QuoteDeletedMessage) MarshalJSON ¶

func (obj QuoteDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QuoteDeletedMessage) UnmarshalJSON ¶

func (obj *QuoteDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteDeletedMessagePayload ¶

type QuoteDeletedMessagePayload struct {
}

* * Generated after a successful [Delete Quote](/../api/projects/quotes#delete-quote) request. *

func (QuoteDeletedMessagePayload) MarshalJSON ¶

func (obj QuoteDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteDraft ¶

type QuoteDraft struct {
	// User-defined unique identifier for the Quote.
	Key *string `json:"key,omitempty"`
	// StagedQuote from which the Quote is created.
	StagedQuote StagedQuoteResourceIdentifier `json:"stagedQuote"`
	// Current version of the StagedQuote.
	StagedQuoteVersion int `json:"stagedQuoteVersion"`
	// If `true`, the `stagedQuoteState` of the referenced [StagedQuote](/../api/projects/staged-quotes#stagedquote) will be set to `Sent`.
	StagedQuoteStateToSent *bool `json:"stagedQuoteStateToSent,omitempty"`
	// [State](ctp:api:type:State) of the Quote.
	// This reference can point to a State in a custom workflow.
	State *StateReference `json:"state,omitempty"`
	// [Custom Fields](/../api/projects/custom-fields) to be added to the Quote.
	//
	// - If specified, the Custom Fields are merged with the Custom Fields on the referenced [StagedQuote](/../api/projects/staged-quotes#stagedquote) and added to the Quote.
	// - If empty, the Custom Fields on the referenced [StagedQuote](/../api/projects/staged-quotes#stagedquote) are added to the Quote automatically.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

type QuotePagedQueryResponse ¶

type QuotePagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Quotes matching the query.
	Results []Quote `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of Quote(ctp:api:type:Quote). *

type QuoteReference ¶

type QuoteReference struct {
	// Unique ID of the referenced resource.
	ID string `json:"id"`
	// Contains the representation of the expanded Quote.
	// Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for Quote.
	Obj *Quote `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a Quote(ctp:api:type:Quote). *

func (QuoteReference) MarshalJSON ¶

func (obj QuoteReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequest ¶

type QuoteRequest struct {
	// Unique identifier of the QuoteRequest.
	ID string `json:"id"`
	// Current version of the QuoteRequest.
	Version int `json:"version"`
	// Date and time (UTC) the QuoteRequest was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the QuoteRequest was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// User-defined unique identifier of the QuoteRequest.
	Key *string `json:"key,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Indicates the current state of the Quote Request in the negotiation process.
	QuoteRequestState QuoteRequestState `json:"quoteRequestState"`
	// Message from the Buyer included in the Quote Request.
	Comment *string `json:"comment,omitempty"`
	// The [Buyer](/../api/quotes-overview#buyer) who owns the request.
	Customer CustomerReference `json:"customer"`
	// Set automatically when `customer` is set and the Customer is a member of a Customer Group.
	// Not updated if Customer is changed after Quote Request creation.
	// Used for Product Variant price selection.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// The Store to which the [Buyer](/../api/quotes-overview#buyer) belongs.
	Store *StoreKeyReference `json:"store,omitempty"`
	// The Line Items for which a Quote is requested.
	LineItems []LineItem `json:"lineItems"`
	// The Custom Line Items for which a Quote is requested.
	CustomLineItems []CustomLineItem `json:"customLineItems"`
	// Sum of all `totalPrice` fields of the `lineItems` and `customLineItems`, as well as the `price` field of `shippingInfo` (if it exists).
	// `totalPrice` may or may not include the taxes: it depends on the taxRate.includedInPrice property of each price.
	TotalPrice TypedMoney `json:"totalPrice"`
	// Not set until the shipping address is set.
	// Will be set automatically in the `Platform` TaxMode.
	// For the `External` tax mode it will be set  as soon as the external tax rates for all line items, custom line items, and shipping in the cart are set.
	TaxedPrice *TaxedPrice `json:"taxedPrice,omitempty"`
	// Used to determine the eligible [ShippingMethods](ctp:api:type:ShippingMethod)
	// and rates as well as the tax rate of the Line Items.
	ShippingAddress *Address `json:"shippingAddress,omitempty"`
	// Address used for invoicing.
	BillingAddress *Address `json:"billingAddress,omitempty"`
	// Inventory mode of the Cart referenced in the [QuoteRequestDraft](ctp:api:type:QuoteRequestDraft).
	InventoryMode *InventoryMode `json:"inventoryMode,omitempty"`
	// Tax mode of the Cart referenced in the [QuoteRequestDraft](ctp:api:type:QuoteRequestDraft).
	TaxMode TaxMode `json:"taxMode"`
	// When calculating taxes for `taxedPrice`, the selected mode is used for rounding.
	TaxRoundingMode RoundingMode `json:"taxRoundingMode"`
	// When calculating taxes for `taxedPrice`, the selected mode is used for calculating the price with `LineItemLevel` (horizontally) or `UnitPriceLevel` (vertically) calculation mode.
	TaxCalculationMode TaxCalculationMode `json:"taxCalculationMode"`
	// Used for Product Variant price selection.
	Country *string `json:"country,omitempty"`
	// Set automatically once the [ShippingMethod](ctp:api:type:ShippingMethod) is set.
	ShippingInfo *ShippingInfo `json:"shippingInfo,omitempty"`
	// Log of payment transactions related to the Quote.
	PaymentInfo *PaymentInfo `json:"paymentInfo,omitempty"`
	// Used to select a [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	ShippingRateInput ShippingRateInput `json:"shippingRateInput,omitempty"`
	// Contains addresses for carts with multiple shipping addresses.
	// Line items reference these addresses under their `shippingDetails`.
	// The addresses captured here are not used to determine eligible shipping methods or the applicable tax rate.
	// Only the cart's `shippingAddress` is used for this.
	ItemShippingAddresses []Address `json:"itemShippingAddresses"`
	// Discounts that are only valid for the Quote and cannot be associated to any other Cart or Order.
	DirectDiscounts []DirectDiscount `json:"directDiscounts"`
	// Custom Fields of the Quote Request.
	Custom *CustomFields `json:"custom,omitempty"`
	// [State](ctp:api:type:State) of the Quote Request.
	// This reference can point to a State in a custom workflow.
	State *StateReference `json:"state,omitempty"`
	// Identifier for a purchase order, usually in a B2B context.
	// The Purchase Order Number is typically entered by the [Buyer](/quotes-overview#buyer).
	PurchaseOrderNumber *string `json:"purchaseOrderNumber,omitempty"`
	// The [BusinessUnit](ctp:api:type:BusinessUnit) for the Quote Request.
	BusinessUnit *BusinessUnitKeyReference `json:"businessUnit,omitempty"`
}

func (QuoteRequest) MarshalJSON ¶

func (obj QuoteRequest) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QuoteRequest) UnmarshalJSON ¶

func (obj *QuoteRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteRequestChangeCustomerAction ¶

type QuoteRequestChangeCustomerAction struct {
	// New Customer to own the Quote Request.
	Customer CustomerResourceIdentifier `json:"customer"`
}

* * Changes the owner of a Quote Request to a different Customer. * Customer Group is not updated. * This update action produces the [Quote Request Customer Changed](ctp:api:type:QuoteRequestCustomerChangedMessage) Message. *

func (QuoteRequestChangeCustomerAction) MarshalJSON ¶

func (obj QuoteRequestChangeCustomerAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestChangeQuoteRequestStateAction ¶

type QuoteRequestChangeQuoteRequestStateAction struct {
	// New state to be set for the Quote Request.
	QuoteRequestState QuoteRequestState `json:"quoteRequestState"`
}

* * Transitions the Quote Request to a different state. * A Buyer is only allowed to cancel a Quote Request when it is in `Submitted` state. *

func (QuoteRequestChangeQuoteRequestStateAction) MarshalJSON ¶

func (obj QuoteRequestChangeQuoteRequestStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestCreatedMessage ¶

type QuoteRequestCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Quote Request](/../api/projects/quote-requests) that was created.
	QuoteRequest QuoteRequest `json:"quoteRequest"`
}

* * Generated after a successful [Create Quote Request](/../api/projects/quote-requests#create-quoterequest) request. *

func (QuoteRequestCreatedMessage) MarshalJSON ¶

func (obj QuoteRequestCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QuoteRequestCreatedMessage) UnmarshalJSON ¶

func (obj *QuoteRequestCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteRequestCreatedMessagePayload ¶

type QuoteRequestCreatedMessagePayload struct {
	// [Quote Request](/../api/projects/quote-requests) that was created.
	QuoteRequest QuoteRequest `json:"quoteRequest"`
}

* * Generated after a successful [Create Quote Request](/../api/projects/quote-requests#create-quoterequest) request. *

func (QuoteRequestCreatedMessagePayload) MarshalJSON ¶

func (obj QuoteRequestCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestCustomerChangedMessage ¶

type QuoteRequestCustomerChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [Buyer](/../api/quotes-overview#buyer) who now owns the Quote Request.
	Customer CustomerReference `json:"customer"`
	// The previous [Buyer](/../api/quotes-overview#buyer).
	PreviousCustomer CustomerReference `json:"previousCustomer"`
}

* * Generated after a successful [Change Customer](ctp:api:type:QuoteRequestChangeCustomerAction) update action. *

func (QuoteRequestCustomerChangedMessage) MarshalJSON ¶

func (obj QuoteRequestCustomerChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QuoteRequestCustomerChangedMessage) UnmarshalJSON ¶

func (obj *QuoteRequestCustomerChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteRequestCustomerChangedMessagePayload ¶

type QuoteRequestCustomerChangedMessagePayload struct {
	// The [Buyer](/../api/quotes-overview#buyer) who now owns the Quote Request.
	Customer CustomerReference `json:"customer"`
	// The previous [Buyer](/../api/quotes-overview#buyer).
	PreviousCustomer CustomerReference `json:"previousCustomer"`
}

* * Generated after a successful [Change Customer](ctp:api:type:QuoteRequestChangeCustomerAction) update action. *

func (QuoteRequestCustomerChangedMessagePayload) MarshalJSON ¶

func (obj QuoteRequestCustomerChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestDeletedMessage ¶

type QuoteRequestDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
}

* * Generated after a successful [Delete Quote Request](/../api/projects/quote-requests#delete-quoterequest) request. *

func (QuoteRequestDeletedMessage) MarshalJSON ¶

func (obj QuoteRequestDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QuoteRequestDeletedMessage) UnmarshalJSON ¶

func (obj *QuoteRequestDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteRequestDeletedMessagePayload ¶

type QuoteRequestDeletedMessagePayload struct {
}

* * Generated after a successful [Delete Quote Request](/../api/projects/quote-requests#delete-quoterequest) request. *

func (QuoteRequestDeletedMessagePayload) MarshalJSON ¶

func (obj QuoteRequestDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestDraft ¶

type QuoteRequestDraft struct {
	// Cart for which a Quote is requested.
	// Anonymous Carts, Carts with [Discount Codes](ctp:api:type:DiscountCode), or Carts with a `Multiple` [ShippingMode](ctp:api:type:ShippingMode) are not supported.
	Cart CartResourceIdentifier `json:"cart"`
	// Current version of the referenced Cart.
	CartVersion int `json:"cartVersion"`
	// User-defined unique identifier for the QuoteRequest.
	Key *string `json:"key,omitempty"`
	// Message from the Buyer included in the Quote Request.
	Comment string `json:"comment"`
	// Custom Fields to be added to the Quote Request.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// [State](ctp:api:type:State) of the Quote Request.
	// This reference can point to a State in a custom workflow.
	State *StateReference `json:"state,omitempty"`
	// Identifier for a purchase order, usually in a B2B context.
	// The Purchase Order Number is typically entered by the [Buyer](/quotes-overview#buyer).
	PurchaseOrderNumber *string `json:"purchaseOrderNumber,omitempty"`
}

type QuoteRequestPagedQueryResponse ¶

type QuoteRequestPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Quote Requests matching the query.
	Results []QuoteRequest `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of QuoteRequest(ctp:api:type:QuoteRequest). *

type QuoteRequestQuoteRenegotiationAction ¶

type QuoteRequestQuoteRenegotiationAction struct {
	// Message from the [Buyer](/api/quotes-overview#buyer) regarding the Quote renegotiation request.
	BuyerComment *string `json:"buyerComment,omitempty"`
}

* * Represents the Buyer requesting renegotiation for a Quote. Valid for Quotes in a `Pending` or `Failed` [state](ctp:api:type:QuoteState). *

func (QuoteRequestQuoteRenegotiationAction) MarshalJSON ¶

func (obj QuoteRequestQuoteRenegotiationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestReference ¶

type QuoteRequestReference struct {
	// Unique ID of the referenced resource.
	ID string `json:"id"`
	// Contains the representation of the expanded QuoteRequest.
	// Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for QuoteRequest.
	Obj *QuoteRequest `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a QuoteRequest(ctp:api:type:QuoteRequest). *

func (QuoteRequestReference) MarshalJSON ¶

func (obj QuoteRequestReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestResourceIdentifier ¶

type QuoteRequestResourceIdentifier struct {
	// Unique identifier of the referenced resource. Required if `key` is absent.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced resource. Required if `id` is absent.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a QuoteRequest(ctp:api:type:QuoteRequest). *

func (QuoteRequestResourceIdentifier) MarshalJSON ¶

func (obj QuoteRequestResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestSetCustomFieldAction ¶

type QuoteRequestSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (QuoteRequestSetCustomFieldAction) MarshalJSON ¶

func (obj QuoteRequestSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestSetCustomTypeAction ¶

type QuoteRequestSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the QuoteRequest with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the QuoteRequest.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the QuoteRequest.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (QuoteRequestSetCustomTypeAction) MarshalJSON ¶

func (obj QuoteRequestSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestState ¶

type QuoteRequestState string

* * Predefined states tracking the status of the Quote Request in the negotiation process. *

const (
	QuoteRequestStateSubmitted QuoteRequestState = "Submitted"
	QuoteRequestStateAccepted  QuoteRequestState = "Accepted"
	QuoteRequestStateClosed    QuoteRequestState = "Closed"
	QuoteRequestStateRejected  QuoteRequestState = "Rejected"
	QuoteRequestStateCancelled QuoteRequestState = "Cancelled"
)

type QuoteRequestStateChangedMessage ¶

type QuoteRequestStateChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// State of the Quote Request after the [Change Quote Request State](ctp:api:type:QuoteRequestChangeQuoteRequestStateAction) update action.
	QuoteRequestState QuoteRequestState `json:"quoteRequestState"`
	// State of the Quote Request before the [Change Quote Request State](ctp:api:type:QuoteRequestChangeQuoteRequestStateAction) update action.
	OldQuoteRequestState QuoteRequestState `json:"oldQuoteRequestState"`
}

* * Generated after a successful [Change Quote Request State](ctp:api:type:QuoteRequestChangeQuoteRequestStateAction) update action. *

func (QuoteRequestStateChangedMessage) MarshalJSON ¶

func (obj QuoteRequestStateChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QuoteRequestStateChangedMessage) UnmarshalJSON ¶

func (obj *QuoteRequestStateChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteRequestStateChangedMessagePayload ¶

type QuoteRequestStateChangedMessagePayload struct {
	// State of the Quote Request after the [Change Quote Request State](ctp:api:type:QuoteRequestChangeQuoteRequestStateAction) update action.
	QuoteRequestState QuoteRequestState `json:"quoteRequestState"`
	// State of the Quote Request before the [Change Quote Request State](ctp:api:type:QuoteRequestChangeQuoteRequestStateAction) update action.
	OldQuoteRequestState QuoteRequestState `json:"oldQuoteRequestState"`
}

* * Generated after a successful [Change Quote Request State](ctp:api:type:QuoteRequestChangeQuoteRequestStateAction) update action. *

func (QuoteRequestStateChangedMessagePayload) MarshalJSON ¶

func (obj QuoteRequestStateChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestStateTransitionMessage ¶

type QuoteRequestStateTransitionMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) after the [Transition State](ctp:api:type:QuoteRequestTransitionStateAction) update action.
	State StateReference `json:"state"`
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) before the [Transition State](ctp:api:type:QuoteRequestTransitionStateAction) update action.
	OldState *StateReference `json:"oldState,omitempty"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:QuoteRequestTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:QuoteRequestTransitionStateAction) update action. *

func (QuoteRequestStateTransitionMessage) MarshalJSON ¶

func (obj QuoteRequestStateTransitionMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QuoteRequestStateTransitionMessage) UnmarshalJSON ¶

func (obj *QuoteRequestStateTransitionMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteRequestStateTransitionMessagePayload ¶

type QuoteRequestStateTransitionMessagePayload struct {
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) after the [Transition State](ctp:api:type:QuoteRequestTransitionStateAction) update action.
	State StateReference `json:"state"`
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) before the [Transition State](ctp:api:type:QuoteRequestTransitionStateAction) update action.
	OldState *StateReference `json:"oldState,omitempty"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:QuoteRequestTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:QuoteRequestTransitionStateAction) update action. *

func (QuoteRequestStateTransitionMessagePayload) MarshalJSON ¶

func (obj QuoteRequestStateTransitionMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestTransitionStateAction ¶

type QuoteRequestTransitionStateAction struct {
	// Value to set.
	// If there is no State yet, this must be an initial State.
	State StateResourceIdentifier `json:"state"`
	// Switch validations on or off.
	Force *bool `json:"force,omitempty"`
}

* * If the existing State(ctp:api:type:State) has set `transitions`, there must be a direct transition to the new State. If `transitions` is not set, no validation is performed. This update action produces the [Quote Request State Transition](ctp:api:type:QuoteRequestStateTransitionMessage) Message. *

func (QuoteRequestTransitionStateAction) MarshalJSON ¶

func (obj QuoteRequestTransitionStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteRequestUpdate ¶

type QuoteRequestUpdate struct {
	// Expected version of the [QuoteRequest](ctp:api:type:QuoteRequest) to which the changes should be applied.
	// If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the [QuoteRequest](ctp:api:type:QuoteRequest).
	Actions []QuoteRequestUpdateAction `json:"actions"`
}

func (*QuoteRequestUpdate) UnmarshalJSON ¶

func (obj *QuoteRequestUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteRequestUpdateAction ¶

type QuoteRequestUpdateAction interface{}

type QuoteResourceIdentifier ¶

type QuoteResourceIdentifier struct {
	// Unique identifier of the referenced resource. Required if `key` is absent.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced resource. Required if `id` is absent.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a Quote(ctp:api:type:Quote). *

func (QuoteResourceIdentifier) MarshalJSON ¶

func (obj QuoteResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteSetCustomFieldAction ¶

type QuoteSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (QuoteSetCustomFieldAction) MarshalJSON ¶

func (obj QuoteSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteSetCustomTypeAction ¶

type QuoteSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the Quote with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Quote.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Quote.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (QuoteSetCustomTypeAction) MarshalJSON ¶

func (obj QuoteSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteState ¶

type QuoteState string

* * Predefined states tracking the status of the Quote. *

const (
	QuoteStatePending                  QuoteState = "Pending"
	QuoteStateDeclined                 QuoteState = "Declined"
	QuoteStateDeclinedForRenegotiation QuoteState = "DeclinedForRenegotiation"
	QuoteStateRenegotiationAddressed   QuoteState = "RenegotiationAddressed"
	QuoteStateAccepted                 QuoteState = "Accepted"
	QuoteStateFailed                   QuoteState = "Failed"
	QuoteStateWithdrawn                QuoteState = "Withdrawn"
)

type QuoteStateChangedMessage ¶

type QuoteStateChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// State of the Quote after the [Change Quote State](ctp:api:type:QuoteChangeQuoteStateAction) update action.
	QuoteState QuoteState `json:"quoteState"`
	// State of the Quote before the [Change Quote State](ctp:api:type:QuoteChangeQuoteStateAction) update action.
	OldQuoteState QuoteState `json:"oldQuoteState"`
}

* * Generated after a successful [Change Quote State](ctp:api:type:QuoteChangeQuoteStateAction) update action. *

func (QuoteStateChangedMessage) MarshalJSON ¶

func (obj QuoteStateChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QuoteStateChangedMessage) UnmarshalJSON ¶

func (obj *QuoteStateChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteStateChangedMessagePayload ¶

type QuoteStateChangedMessagePayload struct {
	// State of the Quote after the [Change Quote State](ctp:api:type:QuoteChangeQuoteStateAction) update action.
	QuoteState QuoteState `json:"quoteState"`
	// State of the Quote before the [Change Quote State](ctp:api:type:QuoteChangeQuoteStateAction) update action.
	OldQuoteState QuoteState `json:"oldQuoteState"`
}

* * Generated after a successful [Change Quote State](ctp:api:type:QuoteChangeQuoteStateAction) update action. *

func (QuoteStateChangedMessagePayload) MarshalJSON ¶

func (obj QuoteStateChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteStateTransitionMessage ¶

type QuoteStateTransitionMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) after the [Transition State](ctp:api:type:QuoteTransitionStateAction) update action.
	State StateReference `json:"state"`
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) before the [Transition State](ctp:api:type:QuoteTransitionStateAction) update action.
	OldState *StateReference `json:"oldState,omitempty"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:QuoteTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:QuoteTransitionStateAction) update action. *

func (QuoteStateTransitionMessage) MarshalJSON ¶

func (obj QuoteStateTransitionMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*QuoteStateTransitionMessage) UnmarshalJSON ¶

func (obj *QuoteStateTransitionMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteStateTransitionMessagePayload ¶

type QuoteStateTransitionMessagePayload struct {
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) after the [Transition State](ctp:api:type:QuoteTransitionStateAction) update action.
	State StateReference `json:"state"`
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) before the [Transition State](ctp:api:type:QuoteTransitionStateAction) update action.
	OldState *StateReference `json:"oldState,omitempty"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:QuoteTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:QuoteTransitionStateAction) update action. *

func (QuoteStateTransitionMessagePayload) MarshalJSON ¶

func (obj QuoteStateTransitionMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteTransitionStateAction ¶

type QuoteTransitionStateAction struct {
	// Value to set.
	// If there is no State yet, this must be an initial State.
	State StateResourceIdentifier `json:"state"`
	// Switch validations on or off.
	Force *bool `json:"force,omitempty"`
}

* * If the existing State(ctp:api:type:State) has set `transitions`, there must be a direct transition to the new State. If `transitions` is not set, no validation is performed. This update action produces the [Quote State Transition](ctp:api:type:QuoteStateTransitionMessage) Message. *

func (QuoteTransitionStateAction) MarshalJSON ¶

func (obj QuoteTransitionStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type QuoteUpdate ¶

type QuoteUpdate struct {
	// Expected version of the [Quote](ctp:api:type:Quote) to which the changes should be applied.
	// If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the [Quote](ctp:api:type:Quote).
	Actions []QuoteUpdateAction `json:"actions"`
}

func (*QuoteUpdate) UnmarshalJSON ¶

func (obj *QuoteUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type QuoteUpdateAction ¶

type QuoteUpdateAction interface{}

type RangeFacetResult ¶

type RangeFacetResult struct {
	Ranges []FacetRange `json:"ranges"`
}

func (RangeFacetResult) MarshalJSON ¶

func (obj RangeFacetResult) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type Reference ¶

type Reference interface{}

* * A Reference represents a loose reference to another resource in the same Project identified by its `id`. The `typeId` indicates the type of the referenced resource. Each resource type has its corresponding Reference type, like ChannelReference(ctp:api:type:ChannelReference). A referenced resource can be embedded through [Reference Expansion](/general-concepts#reference-expansion). The expanded reference is the value of an additional `obj` field then. *

type ReferenceExistsError ¶

type ReferenceExistsError struct {
	// `"Can not delete a $resource while it is referenced by at least one $referencedBy."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Type of referenced resource.
	ReferencedBy *ReferenceTypeId `json:"referencedBy,omitempty"`
}

* * Returned when a resource cannot be deleted because it is being referenced by another resource. *

func (*ReferenceExistsError) DecodeStruct ¶

func (obj *ReferenceExistsError) DecodeStruct(src map[string]interface{}) error

func (ReferenceExistsError) Error ¶

func (obj ReferenceExistsError) Error() string

func (ReferenceExistsError) MarshalJSON ¶

func (obj ReferenceExistsError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ReferenceExistsError) UnmarshalJSON ¶

func (obj *ReferenceExistsError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReferenceTypeId ¶

type ReferenceTypeId string

* * Type of resource the value should reference. Supported resource type identifiers are: *

const (
	ReferenceTypeIdAssociateRole    ReferenceTypeId = "associate-role"
	ReferenceTypeIdAttributeGroup   ReferenceTypeId = "attribute-group"
	ReferenceTypeIdBusinessUnit     ReferenceTypeId = "business-unit"
	ReferenceTypeIdCart             ReferenceTypeId = "cart"
	ReferenceTypeIdCartDiscount     ReferenceTypeId = "cart-discount"
	ReferenceTypeIdCategory         ReferenceTypeId = "category"
	ReferenceTypeIdChannel          ReferenceTypeId = "channel"
	ReferenceTypeIdCustomer         ReferenceTypeId = "customer"
	ReferenceTypeIdCustomerGroup    ReferenceTypeId = "customer-group"
	ReferenceTypeIdDirectDiscount   ReferenceTypeId = "direct-discount"
	ReferenceTypeIdDiscountCode     ReferenceTypeId = "discount-code"
	ReferenceTypeIdExtension        ReferenceTypeId = "extension"
	ReferenceTypeIdInventoryEntry   ReferenceTypeId = "inventory-entry"
	ReferenceTypeIdKeyValueDocument ReferenceTypeId = "key-value-document"
	ReferenceTypeIdOrder            ReferenceTypeId = "order"
	ReferenceTypeIdOrderEdit        ReferenceTypeId = "order-edit"
	ReferenceTypeIdPayment          ReferenceTypeId = "payment"
	ReferenceTypeIdProduct          ReferenceTypeId = "product"
	ReferenceTypeIdProductDiscount  ReferenceTypeId = "product-discount"
	ReferenceTypeIdProductPrice     ReferenceTypeId = "product-price"
	ReferenceTypeIdProductSelection ReferenceTypeId = "product-selection"
	ReferenceTypeIdProductType      ReferenceTypeId = "product-type"
	ReferenceTypeIdQuote            ReferenceTypeId = "quote"
	ReferenceTypeIdQuoteRequest     ReferenceTypeId = "quote-request"
	ReferenceTypeIdReview           ReferenceTypeId = "review"
	ReferenceTypeIdShippingMethod   ReferenceTypeId = "shipping-method"
	ReferenceTypeIdShoppingList     ReferenceTypeId = "shopping-list"
	ReferenceTypeIdStagedQuote      ReferenceTypeId = "staged-quote"
	ReferenceTypeIdStandalonePrice  ReferenceTypeId = "standalone-price"
	ReferenceTypeIdState            ReferenceTypeId = "state"
	ReferenceTypeIdStore            ReferenceTypeId = "store"
	ReferenceTypeIdSubscription     ReferenceTypeId = "subscription"
	ReferenceTypeIdTaxCategory      ReferenceTypeId = "tax-category"
	ReferenceTypeIdType             ReferenceTypeId = "type"
	ReferenceTypeIdZone             ReferenceTypeId = "zone"
)

type ReferencedResourceNotFoundError ¶

type ReferencedResourceNotFoundError struct {
	// `"The referenced object of type $typeId $predicate was not found. It either doesn't exist, or it can't be accessed from this endpoint (e.g., if the endpoint filters by store or customer account)."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Type of referenced resource.
	TypeId ReferenceTypeId `json:"typeId"`
	// Unique identifier of the referenced resource, if known.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced resource, if known.
	Key *string `json:"key,omitempty"`
}

* * Returned when a resource referenced by a Reference(ctp:api:type:Reference) or a ResourceIdentifier(ctp:api:type:ResourceIdentifier) could not be found. *

func (*ReferencedResourceNotFoundError) DecodeStruct ¶

func (obj *ReferencedResourceNotFoundError) DecodeStruct(src map[string]interface{}) error

func (ReferencedResourceNotFoundError) Error ¶

func (ReferencedResourceNotFoundError) MarshalJSON ¶

func (obj ReferencedResourceNotFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ReferencedResourceNotFoundError) UnmarshalJSON ¶

func (obj *ReferencedResourceNotFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReplicaCartDraft ¶

type ReplicaCartDraft struct {
	// [Reference](ctp:api:type:Reference) to a [Cart](ctp:api:type:Cart) or [Order](ctp:api:type:Order) that is replicated.
	Reference interface{} `json:"reference"`
	// User-defined unique identifier for the Cart.
	Key *string `json:"key,omitempty"`
}

* * Used for [replicating an existing Cart](/../api/projects/carts#replicate-cart) or Order. *

type ReplicaMyCartDraft ¶

type ReplicaMyCartDraft struct {
	// [Reference](ctp:api:type:Reference) to a [Cart](ctp:api:type:Cart) or [Order](ctp:api:type:Order) that is replicated.
	Reference interface{} `json:"reference"`
}

type RequiredFieldError ¶

type RequiredFieldError struct {
	// `"A value is required for field $field."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Name of the field missing the value.
	Field string `json:"field"`
}

* * Returned when a value is not defined for a required field. *

func (*RequiredFieldError) DecodeStruct ¶

func (obj *RequiredFieldError) DecodeStruct(src map[string]interface{}) error

func (RequiredFieldError) Error ¶

func (obj RequiredFieldError) Error() string

func (RequiredFieldError) MarshalJSON ¶

func (obj RequiredFieldError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*RequiredFieldError) UnmarshalJSON ¶

func (obj *RequiredFieldError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ResourceCreatedDeliveryPayload ¶

type ResourceCreatedDeliveryPayload struct {
	// `key` of the [Project](ctp:api:type:Project).
	// Useful in message processing if the Destination receives events from multiple Projects.
	ProjectKey string `json:"projectKey"`
	// Reference to the resource that triggered the message.
	Resource Reference `json:"resource"`
	// User-defined unique identifiers of the resource.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Last seen version of the resource.
	Version int `json:"version"`
	// Date and time (UTC) the resource was last modified.
	ModifiedAt time.Time `json:"modifiedAt"`
}

* * This payload is sent for a ChangeSubscription(ctp:api:type:ChangeSubscription) when a resource is created. *

func (ResourceCreatedDeliveryPayload) MarshalJSON ¶

func (obj ResourceCreatedDeliveryPayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ResourceCreatedDeliveryPayload) UnmarshalJSON ¶

func (obj *ResourceCreatedDeliveryPayload) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ResourceDeletedDeliveryPayload ¶

type ResourceDeletedDeliveryPayload struct {
	// `key` of the [Project](ctp:api:type:Project).
	// Useful in message processing if the Destination receives events from multiple Projects.
	ProjectKey string `json:"projectKey"`
	// Reference to the resource that triggered the message.
	Resource Reference `json:"resource"`
	// User-defined unique identifiers of the resource.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Last seen version of the resource.
	Version int `json:"version"`
	// Date and time (UTC) the resource was last deleted.
	ModifiedAt time.Time `json:"modifiedAt"`
	// `true` if the `dataErasure` [parameter](/../api/general-concepts#data-erasure-of-personal-data) on the `DELETE` request was set to `true`.
	DataErasure *bool `json:"dataErasure,omitempty"`
}

* * This payload is sent for a ChangeSubscription(ctp:api:type:ChangeSubscription) when a resource is deleted. *

func (ResourceDeletedDeliveryPayload) MarshalJSON ¶

func (obj ResourceDeletedDeliveryPayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ResourceDeletedDeliveryPayload) UnmarshalJSON ¶

func (obj *ResourceDeletedDeliveryPayload) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ResourceIdentifier ¶

type ResourceIdentifier interface{}

* * Draft type to create a Reference(ctp:api:type:Reference) or a KeyReference(ctp:api:type:KeyReference) to a resource. Provide either the `id` or (wherever supported) the `key` of the resource to reference, but depending on the API endpoint the response returns either a Reference or a KeyReference. For example, the field `parent` of a CategoryDraft(ctp:api:type:CategoryDraft) takes a ResourceIdentifier for its value while the value of the corresponding field of a Category(ctp:api:type:Category) is a Reference. * * Each resource type has its corresponding ResourceIdentifier, like ChannelResourceIdentifier(ctp:api:type:ChannelResourceIdentifier). *

type ResourceNotFoundError ¶

type ResourceNotFoundError struct {
	// `"The Resource with ID $resourceId was not found."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the resource addressed by the request URL does not exist. *

func (*ResourceNotFoundError) DecodeStruct ¶

func (obj *ResourceNotFoundError) DecodeStruct(src map[string]interface{}) error

func (ResourceNotFoundError) Error ¶

func (obj ResourceNotFoundError) Error() string

func (ResourceNotFoundError) MarshalJSON ¶

func (obj ResourceNotFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ResourceNotFoundError) UnmarshalJSON ¶

func (obj *ResourceNotFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ResourceSizeLimitExceededError ¶

type ResourceSizeLimitExceededError struct {
	// `"The resource size exceeds the maximal allowed size of 16 MB."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the resource exceeds the maximum allowed size of 16 MB. *

func (*ResourceSizeLimitExceededError) DecodeStruct ¶

func (obj *ResourceSizeLimitExceededError) DecodeStruct(src map[string]interface{}) error

func (ResourceSizeLimitExceededError) Error ¶

func (ResourceSizeLimitExceededError) MarshalJSON ¶

func (obj ResourceSizeLimitExceededError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ResourceSizeLimitExceededError) UnmarshalJSON ¶

func (obj *ResourceSizeLimitExceededError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ResourceTypeId ¶

type ResourceTypeId string

* * IDs indicating the [customizable resources and data types](/../api/projects/types#list-of-customizable-data-types). *

const (
	ResourceTypeIdAddress                     ResourceTypeId = "address"
	ResourceTypeIdAsset                       ResourceTypeId = "asset"
	ResourceTypeIdAssociateRole               ResourceTypeId = "associate-role"
	ResourceTypeIdBusinessUnit                ResourceTypeId = "business-unit"
	ResourceTypeIdCartDiscount                ResourceTypeId = "cart-discount"
	ResourceTypeIdCategory                    ResourceTypeId = "category"
	ResourceTypeIdChannel                     ResourceTypeId = "channel"
	ResourceTypeIdCustomer                    ResourceTypeId = "customer"
	ResourceTypeIdCustomerGroup               ResourceTypeId = "customer-group"
	ResourceTypeIdCustomLineItem              ResourceTypeId = "custom-line-item"
	ResourceTypeIdDiscountCode                ResourceTypeId = "discount-code"
	ResourceTypeIdInventoryEntry              ResourceTypeId = "inventory-entry"
	ResourceTypeIdLineItem                    ResourceTypeId = "line-item"
	ResourceTypeIdOrder                       ResourceTypeId = "order"
	ResourceTypeIdOrderEdit                   ResourceTypeId = "order-edit"
	ResourceTypeIdOrderDelivery               ResourceTypeId = "order-delivery"
	ResourceTypeIdOrderParcel                 ResourceTypeId = "order-parcel"
	ResourceTypeIdOrderReturnItem             ResourceTypeId = "order-return-item"
	ResourceTypeIdPayment                     ResourceTypeId = "payment"
	ResourceTypeIdPaymentInterfaceInteraction ResourceTypeId = "payment-interface-interaction"
	ResourceTypeIdProductPrice                ResourceTypeId = "product-price"
	ResourceTypeIdProductSelection            ResourceTypeId = "product-selection"
	ResourceTypeIdQuote                       ResourceTypeId = "quote"
	ResourceTypeIdReview                      ResourceTypeId = "review"
	ResourceTypeIdShipping                    ResourceTypeId = "shipping"
	ResourceTypeIdShippingMethod              ResourceTypeId = "shipping-method"
	ResourceTypeIdShoppingList                ResourceTypeId = "shopping-list"
	ResourceTypeIdShoppingListTextLineItem    ResourceTypeId = "shopping-list-text-line-item"
	ResourceTypeIdStandalonePrice             ResourceTypeId = "standalone-price"
	ResourceTypeIdStore                       ResourceTypeId = "store"
	ResourceTypeIdTransaction                 ResourceTypeId = "transaction"
)

type ResourceUpdatedDeliveryPayload ¶

type ResourceUpdatedDeliveryPayload struct {
	// `key` of the [Project](ctp:api:type:Project).
	// Useful in message processing if the Destination receives events from multiple Projects.
	ProjectKey string `json:"projectKey"`
	// Reference to the resource that triggered the message.
	Resource Reference `json:"resource"`
	// User-defined unique identifiers of the resource.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Last seen version of the resource.
	Version int `json:"version"`
	// Version of the resource before the update.
	OldVersion int `json:"oldVersion"`
	// Date and time (UTC) the resource was last updated.
	ModifiedAt time.Time `json:"modifiedAt"`
}

* * This payload is sent for a ChangeSubscription(ctp:api:type:ChangeSubscription) when a resource is updated. This includes updates by a background process, like a change in product availability. *

func (ResourceUpdatedDeliveryPayload) MarshalJSON ¶

func (obj ResourceUpdatedDeliveryPayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ResourceUpdatedDeliveryPayload) UnmarshalJSON ¶

func (obj *ResourceUpdatedDeliveryPayload) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReturnInfo ¶

type ReturnInfo struct {
	Items []ReturnItem `json:"items"`
	// Identifies, which return tracking ID is connected to this particular return.
	ReturnTrackingId *string    `json:"returnTrackingId,omitempty"`
	ReturnDate       *time.Time `json:"returnDate,omitempty"`
}

func (*ReturnInfo) UnmarshalJSON ¶

func (obj *ReturnInfo) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReturnInfoAddedMessage ¶

type ReturnInfoAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [ReturnInfo](ctp:api:type:ReturnInfo) that was added to the [Order](ctp:api:type:Order).
	ReturnInfo ReturnInfo `json:"returnInfo"`
}

* * Generated after a successful [Add Return Info](ctp:api:type:OrderAddReturnInfoAction) update action. *

func (ReturnInfoAddedMessage) MarshalJSON ¶

func (obj ReturnInfoAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ReturnInfoAddedMessage) UnmarshalJSON ¶

func (obj *ReturnInfoAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReturnInfoAddedMessagePayload ¶

type ReturnInfoAddedMessagePayload struct {
	// The [ReturnInfo](ctp:api:type:ReturnInfo) that was added to the [Order](ctp:api:type:Order).
	ReturnInfo ReturnInfo `json:"returnInfo"`
}

* * Generated after a successful [Add Return Info](ctp:api:type:OrderAddReturnInfoAction) update action. *

func (ReturnInfoAddedMessagePayload) MarshalJSON ¶

func (obj ReturnInfoAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReturnInfoDraft ¶

type ReturnInfoDraft struct {
	Items []ReturnItemDraft `json:"items"`
	// Identifies, which return tracking ID is connected to this particular return.
	ReturnTrackingId *string    `json:"returnTrackingId,omitempty"`
	ReturnDate       *time.Time `json:"returnDate,omitempty"`
}

type ReturnInfoSetMessage ¶

type ReturnInfoSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [ReturnInfo](ctp:api:type:ReturnInfo) that was set on the [Order](ctp:api:type:Order) or [Order Edit](ctp:api:type:OrderEdit).
	ReturnInfo []ReturnInfo `json:"returnInfo"`
}

* * Generated after a successful [Set Return Info](ctp:api:type:OrderSetReturnInfoAction) update action on [Orders](ctp:api:type:Order) and [Order Edits](ctp:api:type:OrderEdit). *

func (ReturnInfoSetMessage) MarshalJSON ¶

func (obj ReturnInfoSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ReturnInfoSetMessage) UnmarshalJSON ¶

func (obj *ReturnInfoSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReturnInfoSetMessagePayload ¶

type ReturnInfoSetMessagePayload struct {
	// The [ReturnInfo](ctp:api:type:ReturnInfo) that was set on the [Order](ctp:api:type:Order) or [Order Edit](ctp:api:type:OrderEdit).
	ReturnInfo []ReturnInfo `json:"returnInfo"`
}

* * Generated after a successful [Set Return Info](ctp:api:type:OrderSetReturnInfoAction) update action on [Orders](ctp:api:type:Order) and [Order Edits](ctp:api:type:OrderEdit). *

func (ReturnInfoSetMessagePayload) MarshalJSON ¶

func (obj ReturnInfoSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReturnItem ¶

type ReturnItem interface{}

type ReturnItemDraft ¶

type ReturnItemDraft struct {
	Quantity         int                 `json:"quantity"`
	LineItemId       *string             `json:"lineItemId,omitempty"`
	CustomLineItemId *string             `json:"customLineItemId,omitempty"`
	Comment          *string             `json:"comment,omitempty"`
	ShipmentState    ReturnShipmentState `json:"shipmentState"`
	// Custom Fields of this return item.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

type ReturnPaymentState ¶

type ReturnPaymentState string
const (
	ReturnPaymentStateNonRefundable ReturnPaymentState = "NonRefundable"
	ReturnPaymentStateInitial       ReturnPaymentState = "Initial"
	ReturnPaymentStateRefunded      ReturnPaymentState = "Refunded"
	ReturnPaymentStateNotRefunded   ReturnPaymentState = "NotRefunded"
)

type ReturnShipmentState ¶

type ReturnShipmentState string
const (
	ReturnShipmentStateAdvised     ReturnShipmentState = "Advised"
	ReturnShipmentStateReturned    ReturnShipmentState = "Returned"
	ReturnShipmentStateBackInStock ReturnShipmentState = "BackInStock"
	ReturnShipmentStateUnusable    ReturnShipmentState = "Unusable"
)

type Review ¶

type Review struct {
	// Unique identifier of the Review.
	ID string `json:"id"`
	// Current version of the Review.
	Version int `json:"version"`
	// Date and time (UTC) the Review was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Review was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the Review.
	Key *string `json:"key,omitempty"`
	// Must be unique among Reviews. For example, if this value is set to Customer `id` + Product `id`, only one Review per Customer and per Product is allowed.
	UniquenessValue *string `json:"uniquenessValue,omitempty"`
	// Language in which the content of the Review is written.
	Locale *string `json:"locale,omitempty"`
	// Name of the author.
	AuthorName *string `json:"authorName,omitempty"`
	// Title of the Review.
	Title *string `json:"title,omitempty"`
	// Content of the Review.
	Text *string `json:"text,omitempty"`
	// Identifies the target of the Review. Can be a [Product](ctp:api:type:Product) or a [Channel](ctp:api:type:Channel), specified as [ProductReference](ctp:api:type:ProductReference) or [ChannelReference](ctp:api:type:ChannelReference), respectively.
	Target interface{} `json:"target,omitempty"`
	// Indicates if this Review is taken into account in the ratings statistics of the target.
	// A Review is per default used in the statistics, unless the Review is in a state that does not have the [role](ctp:api:type:StateRoleEnum) `ReviewIncludedInStatistics`.
	// If the role of a [State](ctp:api:type:State) is modified after the calculation of this field, the calculation is not updated.
	IncludedInStatistics bool `json:"includedInStatistics"`
	// Rating of the Product or Channel.
	Rating *int `json:"rating,omitempty"`
	// State of the Review. Used for approval processes, see [Review approval process](/../tutorials/review-ratings#review-approval-process) for details.
	State *StateReference `json:"state,omitempty"`
	// Customer who created the Review.
	Customer *CustomerReference `json:"customer,omitempty"`
	// Custom Fields of the Review.
	Custom *CustomFields `json:"custom,omitempty"`
}

type ReviewCreatedMessage ¶

type ReviewCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Review](ctp:api:type:Review) that was created.
	Review Review `json:"review"`
}

* * Generated after a successful [Create Review](/../api/projects/reviews#create-a-review) request. *

func (ReviewCreatedMessage) MarshalJSON ¶

func (obj ReviewCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ReviewCreatedMessage) UnmarshalJSON ¶

func (obj *ReviewCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReviewCreatedMessagePayload ¶

type ReviewCreatedMessagePayload struct {
	// [Review](ctp:api:type:Review) that was created.
	Review Review `json:"review"`
}

* * Generated after a successful [Create Review](/../api/projects/reviews#create-a-review) request. *

func (ReviewCreatedMessagePayload) MarshalJSON ¶

func (obj ReviewCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewDraft ¶

type ReviewDraft struct {
	// User-defined unique identifier for the Review.
	Key *string `json:"key,omitempty"`
	// If set, this value must be unique among Reviews.
	// For example, if you want to have only one Review per Customer and per Product, you can set the value to Customer `id` + Product `id`.
	UniquenessValue *string `json:"uniquenessValue,omitempty"`
	// Language in which the content of the Review is written.
	Locale *string `json:"locale,omitempty"`
	// Name of the author.
	AuthorName *string `json:"authorName,omitempty"`
	// Title of the Review.
	Title *string `json:"title,omitempty"`
	// Content of the Review.
	Text *string `json:"text,omitempty"`
	// Identifies the target of the Review. Can be a [Product](ctp:api:type:Product) or a [Channel](ctp:api:type:Channel), specified as [ProductResourceIdentifier](ctp:api:type:ProductResourceIdentifier) or [ChannelResourceIdentifier](ctp:api:type:ChannelResourceIdentifier), respectively.
	Target interface{} `json:"target,omitempty"`
	// State of the Review. Used for approval processes, see [Review approval process](/../tutorials/review-ratings#review-approval-process) for details.
	State *StateResourceIdentifier `json:"state,omitempty"`
	// Rating of the targeted Product or Channel.
	// This rating can represent the number of stars, a percentage, or a like (+1)/dislike (-1).
	// A rating is used in the ratings statistics of the targeted object, unless the Review is in a State that does not have the role `ReviewIncludedInStatistics`.
	Rating *int `json:"rating,omitempty"`
	// Customer who created the Review.
	Customer *CustomerResourceIdentifier `json:"customer,omitempty"`
	// Custom Fields for the Review.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * When creating a new Review, at least one of `title`, `text` or `rating` should be set. *

type ReviewPagedQueryResponse ¶

type ReviewPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// [Reviews](ctp:api:type:Review) matching the query.
	Results []Review `json:"results"`
}

type ReviewRatingSetMessage ¶

type ReviewRatingSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The `rating` of the [Review](ctp:api:type:Review) before the [Set Rating](ctp:api:type:ReviewSetRatingAction) update action.
	OldRating *float64 `json:"oldRating,omitempty"`
	// The `rating` of the [Review](ctp:api:type:Review) after the [Set Rating](ctp:api:type:ReviewSetRatingAction) update action.
	NewRating *float64 `json:"newRating,omitempty"`
	// Whether the [Review](ctp:api:type:Review) was taken into account in the ratings statistics of the target.
	IncludedInStatistics bool `json:"includedInStatistics"`
	// [Reference](ctp:api:type:Reference) to the resource that the [Review](ctp:api:type:Review) belongs to.
	Target Reference `json:"target,omitempty"`
}

* * Generated after a successful [Set Rating](ctp:api:type:ReviewSetRatingAction) update action. *

func (ReviewRatingSetMessage) MarshalJSON ¶

func (obj ReviewRatingSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ReviewRatingSetMessage) UnmarshalJSON ¶

func (obj *ReviewRatingSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReviewRatingSetMessagePayload ¶

type ReviewRatingSetMessagePayload struct {
	// The `rating` of the [Review](ctp:api:type:Review) before the [Set Rating](ctp:api:type:ReviewSetRatingAction) update action.
	OldRating *float64 `json:"oldRating,omitempty"`
	// The `rating` of the [Review](ctp:api:type:Review) after the [Set Rating](ctp:api:type:ReviewSetRatingAction) update action.
	NewRating *float64 `json:"newRating,omitempty"`
	// Whether the [Review](ctp:api:type:Review) was taken into account in the ratings statistics of the target.
	IncludedInStatistics bool `json:"includedInStatistics"`
	// [Reference](ctp:api:type:Reference) to the resource that the [Review](ctp:api:type:Review) belongs to.
	Target Reference `json:"target,omitempty"`
}

* * Generated after a successful [Set Rating](ctp:api:type:ReviewSetRatingAction) update action. *

func (ReviewRatingSetMessagePayload) MarshalJSON ¶

func (obj ReviewRatingSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ReviewRatingSetMessagePayload) UnmarshalJSON ¶

func (obj *ReviewRatingSetMessagePayload) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReviewRatingStatistics ¶

type ReviewRatingStatistics struct {
	// Average rating of one target
	// This number is rounded with 5 decimals.
	AverageRating float64 `json:"averageRating"`
	// Highest rating of one target
	HighestRating float64 `json:"highestRating"`
	// Lowest rating of one target
	LowestRating float64 `json:"lowestRating"`
	// Number of ratings taken into account
	Count int `json:"count"`
	// Full distribution of the ratings.
	// The keys are the different ratings and the values are the count of reviews having this rating.
	// Only the used ratings appear in this object.
	RatingsDistribution interface{} `json:"ratingsDistribution"`
}

type ReviewReference ¶

type ReviewReference struct {
	// Unique identifier of the referenced [Review](ctp:api:type:Review).
	ID string `json:"id"`
	// Contains the representation of the expanded Review. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for Reviews.
	Obj *Review `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a Review(ctp:api:type:Review). *

func (ReviewReference) MarshalJSON ¶

func (obj ReviewReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewResourceIdentifier ¶

type ReviewResourceIdentifier struct {
	// Unique identifier of the referenced [Review](ctp:api:type:Review). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [Review](ctp:api:type:Review). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a Review(ctp:api:type:Review). *

func (ReviewResourceIdentifier) MarshalJSON ¶

func (obj ReviewResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewSetAuthorNameAction ¶

type ReviewSetAuthorNameAction struct {
	// Value to set. If empty, any existing value will be removed.
	AuthorName *string `json:"authorName,omitempty"`
}

func (ReviewSetAuthorNameAction) MarshalJSON ¶

func (obj ReviewSetAuthorNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewSetCustomFieldAction ¶

type ReviewSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (ReviewSetCustomFieldAction) MarshalJSON ¶

func (obj ReviewSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewSetCustomTypeAction ¶

type ReviewSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the Review with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Review.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Review.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (ReviewSetCustomTypeAction) MarshalJSON ¶

func (obj ReviewSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewSetCustomerAction ¶

type ReviewSetCustomerAction struct {
	// Value to set. If empty, any existing value will be removed.
	Customer *CustomerResourceIdentifier `json:"customer,omitempty"`
}

func (ReviewSetCustomerAction) MarshalJSON ¶

func (obj ReviewSetCustomerAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewSetKeyAction ¶

type ReviewSetKeyAction struct {
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

func (ReviewSetKeyAction) MarshalJSON ¶

func (obj ReviewSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewSetLocaleAction ¶

type ReviewSetLocaleAction struct {
	// Value to set. If empty, any existing value will be removed.
	Locale *string `json:"locale,omitempty"`
}

func (ReviewSetLocaleAction) MarshalJSON ¶

func (obj ReviewSetLocaleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewSetRatingAction ¶

type ReviewSetRatingAction struct {
	// Value to set. If empty, any existing value will be removed.
	Rating *int `json:"rating,omitempty"`
}

* * This update action produces the [ReviewRatingSet](ctp:api:type:ReviewRatingSetMessage) Message. *

func (ReviewSetRatingAction) MarshalJSON ¶

func (obj ReviewSetRatingAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewSetTargetAction ¶

type ReviewSetTargetAction struct {
	// Value to set, specified as [ProductResourceIdentifier](ctp:api:type:ProductResourceIdentifier) or [ChannelResourceIdentifier](ctp:api:type:ChannelResourceIdentifier), respectively. If empty, any existing value will be removed.
	Target interface{} `json:"target"`
}

func (ReviewSetTargetAction) MarshalJSON ¶

func (obj ReviewSetTargetAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewSetTextAction ¶

type ReviewSetTextAction struct {
	// Value to set. If empty, any existing value will be removed.
	Text *string `json:"text,omitempty"`
}

func (ReviewSetTextAction) MarshalJSON ¶

func (obj ReviewSetTextAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewSetTitleAction ¶

type ReviewSetTitleAction struct {
	// Value to set. If empty, any existing value will be removed.
	Title *string `json:"title,omitempty"`
}

func (ReviewSetTitleAction) MarshalJSON ¶

func (obj ReviewSetTitleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewStateTransitionMessage ¶

type ReviewStateTransitionMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [State](ctp:api:type:State) of the [Review](ctp:api:type:Review) before the [Transition State](ctp:api:type:ReviewTransitionStateAction) update action.
	OldState *StateReference `json:"oldState,omitempty"`
	// [State](ctp:api:type:State) of the [Review](ctp:api:type:Review) after the [Transition State](ctp:api:type:ReviewTransitionStateAction) update action.
	NewState StateReference `json:"newState"`
	// Whether the old [Review](ctp:api:type:Review) was taken into account in the rating statistics of the target before the state transition.
	OldIncludedInStatistics bool `json:"oldIncludedInStatistics"`
	// Whether the new [Review](ctp:api:type:Review) was taken into account in the rating statistics of the target after the state transition.
	NewIncludedInStatistics bool `json:"newIncludedInStatistics"`
	// [Reference](ctp:api:type:Reference) to the resource that the [Review](ctp:api:type:Review) belongs to.
	Target Reference `json:"target,omitempty"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:ReviewTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:ReviewTransitionStateAction) update action. *

func (ReviewStateTransitionMessage) MarshalJSON ¶

func (obj ReviewStateTransitionMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ReviewStateTransitionMessage) UnmarshalJSON ¶

func (obj *ReviewStateTransitionMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReviewStateTransitionMessagePayload ¶

type ReviewStateTransitionMessagePayload struct {
	// [State](ctp:api:type:State) of the [Review](ctp:api:type:Review) before the [Transition State](ctp:api:type:ReviewTransitionStateAction) update action.
	OldState *StateReference `json:"oldState,omitempty"`
	// [State](ctp:api:type:State) of the [Review](ctp:api:type:Review) after the [Transition State](ctp:api:type:ReviewTransitionStateAction) update action.
	NewState StateReference `json:"newState"`
	// Whether the old [Review](ctp:api:type:Review) was taken into account in the rating statistics of the target before the state transition.
	OldIncludedInStatistics bool `json:"oldIncludedInStatistics"`
	// Whether the new [Review](ctp:api:type:Review) was taken into account in the rating statistics of the target after the state transition.
	NewIncludedInStatistics bool `json:"newIncludedInStatistics"`
	// [Reference](ctp:api:type:Reference) to the resource that the [Review](ctp:api:type:Review) belongs to.
	Target Reference `json:"target,omitempty"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:ReviewTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:ReviewTransitionStateAction) update action. *

func (ReviewStateTransitionMessagePayload) MarshalJSON ¶

func (obj ReviewStateTransitionMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ReviewStateTransitionMessagePayload) UnmarshalJSON ¶

func (obj *ReviewStateTransitionMessagePayload) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReviewTransitionStateAction ¶

type ReviewTransitionStateAction struct {
	// Value to set. If there is no State yet, the new State must be an initial State. If the existing State has `transitions` set, there must be a direct transition to the new State. If `transitions` is not set, no validation is performed. If the new State does not have the [role](ctp:api:type:StateRoleEnum) `ReviewIncludedInStatistics`, the Review is not taken into account in the ratings statistics of the target.
	State StateResourceIdentifier `json:"state"`
	// Switch validations on or off.
	Force *bool `json:"force,omitempty"`
}

* * Transition to a new State. This update action produces the [Review State Transition](ctp:api:type:ReviewStateTransitionMessage) Message. *

func (ReviewTransitionStateAction) MarshalJSON ¶

func (obj ReviewTransitionStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ReviewUpdate ¶

type ReviewUpdate struct {
	// The expected version of the review on which the changes should be applied. If the expected version does not match the actual version, a 409 Conflict will be returned.
	Version int `json:"version"`
	// The list of update actions to be performed on the review.
	Actions []ReviewUpdateAction `json:"actions"`
}

func (*ReviewUpdate) UnmarshalJSON ¶

func (obj *ReviewUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ReviewUpdateAction ¶

type ReviewUpdateAction interface{}

type RoundingMode ¶

type RoundingMode string

* * Determines how monetary values are rounded. *

const (
	RoundingModeHalfEven RoundingMode = "HalfEven"
	RoundingModeHalfUp   RoundingMode = "HalfUp"
	RoundingModeHalfDown RoundingMode = "HalfDown"
)

type ScopedPrice ¶

type ScopedPrice struct {
	// Platform-generated unique identifier of the Price.
	ID string `json:"id"`
	// Original value of the Price.
	Value TypedMoney `json:"value"`
	// If available, either the original price `value` or `discounted` value.
	CurrentValue TypedMoney `json:"currentValue"`
	// Country code of the geographic location.
	Country *string `json:"country,omitempty"`
	// Reference to a CustomerGroup.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// Reference to a Channel.
	Channel *ChannelReference `json:"channel,omitempty"`
	// Date and time from which the Price is valid.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date and time until which the Price is valid.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Is set when a matching [ProductDiscount](ctp:api:type:ProductDiscount) exists. If set, the [Cart](ctp:api:type:Cart) uses the discounted value for the [Cart Price calculation](ctp:api:type:CartAddLineItemAction).
	//
	// When a [relative Product Discount](ctp:api:type:ProductDiscountValueRelative) is applied and the fractional part of the discounted Price is 0.5, the discounted Price is [rounded half down](https://en.wikipedia.org/wiki/Rounding#Round_half_down) in favor of the Customer.
	Discounted *DiscountedPrice `json:"discounted,omitempty"`
	// Custom Fields for the Price.
	Custom *CustomFields `json:"custom,omitempty"`
}

* * Scoped Price is contained in a ProductVariant(ctp:api:type:ProductVariant) which is returned in response to a * [Product Projection Search](ctp:api:type:ProductProjectionSearchFilterScopedPrice) request when [Scoped Price Search](ctp:api:type:ScopedPriceSearch) is used. *

func (*ScopedPrice) UnmarshalJSON ¶

func (obj *ScopedPrice) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ScoreShippingRateInput ¶

type ScoreShippingRateInput struct {
	// Abstract value for categorizing a Cart.
	Score int `json:"score"`
}

func (ScoreShippingRateInput) MarshalJSON ¶

func (obj ScoreShippingRateInput) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ScoreShippingRateInputDraft ¶

type ScoreShippingRateInputDraft struct {
	// Abstract value for categorizing a Cart.
	Score int `json:"score"`
}

func (ScoreShippingRateInputDraft) MarshalJSON ¶

func (obj ScoreShippingRateInputDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type SearchDeactivatedError ¶

type SearchDeactivatedError struct {
	// `"The endpoint is deactivated for this project. Please enable it via the Project endpoint, via the Merchant Center in the Project settings, or reach out to Support to enable it."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the indexing of Product information is deactivated in a Project. * * To activate indexing, call [Change Product Search Indexing Enabled](ctp:api:type:ProjectChangeProductSearchIndexingEnabledAction) and set `enabled` to `true`. *

func (*SearchDeactivatedError) DecodeStruct ¶

func (obj *SearchDeactivatedError) DecodeStruct(src map[string]interface{}) error

func (SearchDeactivatedError) Error ¶

func (obj SearchDeactivatedError) Error() string

func (SearchDeactivatedError) MarshalJSON ¶

func (obj SearchDeactivatedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*SearchDeactivatedError) UnmarshalJSON ¶

func (obj *SearchDeactivatedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type SearchExecutionFailureError ¶

type SearchExecutionFailureError struct {
	// `"Something went wrong during the search query execution. In most case this happens due to usage of non-existing fields and custom product attributes. Please verify all filters and facets in your search query and make sure that all paths are correct."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a search query could not be completed due to an unexpected failure. *

func (*SearchExecutionFailureError) DecodeStruct ¶

func (obj *SearchExecutionFailureError) DecodeStruct(src map[string]interface{}) error

func (SearchExecutionFailureError) Error ¶

func (obj SearchExecutionFailureError) Error() string

func (SearchExecutionFailureError) MarshalJSON ¶

func (obj SearchExecutionFailureError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*SearchExecutionFailureError) UnmarshalJSON ¶

func (obj *SearchExecutionFailureError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type SearchFacetPathNotFoundError ¶

type SearchFacetPathNotFoundError struct {
	// `"Facet path $path not found."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a search facet path could not be found. *

func (*SearchFacetPathNotFoundError) DecodeStruct ¶

func (obj *SearchFacetPathNotFoundError) DecodeStruct(src map[string]interface{}) error

func (SearchFacetPathNotFoundError) Error ¶

func (SearchFacetPathNotFoundError) MarshalJSON ¶

func (obj SearchFacetPathNotFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*SearchFacetPathNotFoundError) UnmarshalJSON ¶

func (obj *SearchFacetPathNotFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type SearchIndexingConfiguration ¶

type SearchIndexingConfiguration struct {
	// Configuration for the [Product Projection Search](/../api/projects/products-search) and [Product Suggestions](/../api/projects/products-suggestions) endpoints.
	Products *SearchIndexingConfigurationValues `json:"products,omitempty"`
	// Configuration for the [Order Search](/../api/projects/order-search) feature.
	Orders *SearchIndexingConfigurationValues `json:"orders,omitempty"`
}

* * Controls indexing of resources to be provided on high performance read-only search endpoints. *

type SearchIndexingConfigurationStatus ¶

type SearchIndexingConfigurationStatus string

* * Status of resource indexing.

const (
	SearchIndexingConfigurationStatusActivated   SearchIndexingConfigurationStatus = "Activated"
	SearchIndexingConfigurationStatusDeactivated SearchIndexingConfigurationStatus = "Deactivated"
	SearchIndexingConfigurationStatusIndexing    SearchIndexingConfigurationStatus = "Indexing"
)

type SearchIndexingConfigurationValues ¶

type SearchIndexingConfigurationValues struct {
	// Current status of resource indexing. Present on Projects from 1 February 2019.
	Status *SearchIndexingConfigurationStatus `json:"status,omitempty"`
	// Date and time (UTC) the Project was last updated. Only present on Projects last modified after 1 February 2019.
	LastModifiedAt *time.Time `json:"lastModifiedAt,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
}

type SearchIndexingInProgressError ¶

type SearchIndexingInProgressError struct {
	// `"The indexing is currently in progress. Please wait until the status is "Activated" to execute search requests."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the indexing of Product information is still in progress for Projects that have indexing activated. *

func (*SearchIndexingInProgressError) DecodeStruct ¶

func (obj *SearchIndexingInProgressError) DecodeStruct(src map[string]interface{}) error

func (SearchIndexingInProgressError) Error ¶

func (SearchIndexingInProgressError) MarshalJSON ¶

func (obj SearchIndexingInProgressError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*SearchIndexingInProgressError) UnmarshalJSON ¶

func (obj *SearchIndexingInProgressError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type SearchKeyword ¶

type SearchKeyword struct {
	// Text to return in the result of a [suggest query](ctp:api:type:ProductSuggestionsSuggestQuery).
	Text string `json:"text"`
	// If no tokenizer is defined, the `text` is used as a single token.
	SuggestTokenizer SuggestTokenizer `json:"suggestTokenizer,omitempty"`
}

func (*SearchKeyword) UnmarshalJSON ¶

func (obj *SearchKeyword) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type SearchKeywords ¶

type SearchKeywords map[string][]SearchKeyword

* * Search keywords are JSON objects primarily used by [Product Suggestions](ctp:api:type:ProductSuggestions), but are also considered for a full text search. The keys are of type [Locale](ctp:api:type:Locale), and the values are an array of SearchKeyword(ctp:api:type:SearchKeyword). *

type SelectionMode ¶

type SelectionMode string

* * Defines which matching items are to be discounted. *

const (
	SelectionModeCheapest      SelectionMode = "Cheapest"
	SelectionModeMostExpensive SelectionMode = "MostExpensive"
)

type SemanticErrorError ¶

type SemanticErrorError struct {
	// Plain text description of the error concerning the predicate. For example, `"Invalid country code $countryCode provided for the field $fieldDefinition."`.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a [Discount predicate](/../api/predicates/predicate-operators) or [API Extension predicate](/../api/predicates/query#using-predicates-in-conditional-api-extensions) is not semantically correct. *

func (*SemanticErrorError) DecodeStruct ¶

func (obj *SemanticErrorError) DecodeStruct(src map[string]interface{}) error

func (SemanticErrorError) Error ¶

func (obj SemanticErrorError) Error() string

func (SemanticErrorError) MarshalJSON ¶

func (obj SemanticErrorError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*SemanticErrorError) UnmarshalJSON ¶

func (obj *SemanticErrorError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type SetUserAgentTransport ¶

type SetUserAgentTransport struct {
	T http.RoundTripper
	// contains filtered or unexported fields
}

func (*SetUserAgentTransport) RoundTrip ¶

func (sat *SetUserAgentTransport) RoundTrip(req *http.Request) (*http.Response, error)

type ShipmentState ¶

type ShipmentState string
const (
	ShipmentStateShipped   ShipmentState = "Shipped"
	ShipmentStateDelivered ShipmentState = "Delivered"
	ShipmentStateReady     ShipmentState = "Ready"
	ShipmentStatePending   ShipmentState = "Pending"
	ShipmentStateDelayed   ShipmentState = "Delayed"
	ShipmentStatePartial   ShipmentState = "Partial"
	ShipmentStateBackorder ShipmentState = "Backorder"
)

type Shipping ¶

type Shipping struct {
	// User-defined unique identifier of the Shipping in a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey string `json:"shippingKey"`
	// Automatically set when the [Shipping Method is added](ctp:api:type:CartAddShippingMethodAction).
	ShippingInfo ShippingInfo `json:"shippingInfo"`
	// Determines the shipping rates and Tax Rates of associated Line Items.
	ShippingAddress Address `json:"shippingAddress"`
	// Used as an input to select a [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	// The data type of this field depends on the `shippingRateInputType.type` configured in the [Project](ctp:api:type:Project):
	//
	// - If `CartClassification`, it is [ClassificationShippingRateInput](ctp:api:type:ClassificationShippingRateInput).
	// - If `CartScore`, it is [ScoreShippingRateInput](ctp:api:type:ScoreShippingRateInput).
	// - If `CartValue`, it cannot be used.
	ShippingRateInput ShippingRateInput `json:"shippingRateInput,omitempty"`
	// Custom Fields of Shipping with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingCustomFields *CustomFields `json:"shippingCustomFields,omitempty"`
}

func (*Shipping) UnmarshalJSON ¶

func (obj *Shipping) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ShippingDraft ¶

type ShippingDraft struct {
	// User-defined unique identifier for the Shipping in a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	Key string `json:"key"`
	// Shipping Methods added to the Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingMethod *ShippingMethodReference `json:"shippingMethod,omitempty"`
	// Determines the shipping rate and Tax Rate of the associated Line Items.
	ShippingAddress BaseAddress `json:"shippingAddress"`
	// Input used to select a [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	// The data type of this field depends on the `shippingRateInputType.type` configured in the [Project](ctp:api:type:Project):
	//
	// - If `CartClassification`, it must be [ClassificationShippingRateInputDraft](ctp:api:type:ClassificationShippingRateInputDraft).
	// - If `CartScore`, it must be [ScoreShippingRateInputDraft](ctp:api:type:ScoreShippingRateInputDraft).
	// - If `CartValue`, it cannot be set.
	ShippingRateInput ShippingRateInputDraft `json:"shippingRateInput,omitempty"`
	// Tax Rate used for taxing a shipping expense if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	// Deliveries to be shipped with the Shipping Method.
	Deliveries []DeliveryDraft `json:"deliveries"`
	// Custom Fields for Shipping.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * Wraps all shipping-related information (such as address, rate, deliveries) per Shipping Method for Carts with multiple Shipping Methods. *

func (ShippingDraft) MarshalJSON ¶

func (obj ShippingDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ShippingDraft) UnmarshalJSON ¶

func (obj *ShippingDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ShippingInfo ¶

type ShippingInfo struct {
	// Name of the Shipping Method.
	ShippingMethodName string `json:"shippingMethodName"`
	// Determined based on the [ShippingRate](ctp:api:type:ShippingRate) and its tiered prices, and either the sum of [LineItem](ctp:api:type:LineItem) prices or the `shippingRateInput` field.
	Price CentPrecisionMoney `json:"price"`
	// Used to determine the price.
	ShippingRate ShippingRate `json:"shippingRate"`
	// Automatically set after the `taxRate` is set.
	TaxedPrice *TaxedItemPrice `json:"taxedPrice,omitempty"`
	// Automatically set in the `Platform` [TaxMode](ctp:api:type:TaxMode) after the [shipping address is set](ctp:api:type:CartSetShippingAddressAction).
	//
	// For the `External` [TaxMode](ctp:api:type:TaxMode) the Tax Rate must be set explicitly with the [ExternalTaxRateDraft](ctp:api:type:ExternalTaxRateDraft).
	TaxRate *TaxRate `json:"taxRate,omitempty"`
	// Used to select a Tax Rate when a Cart has the `Platform` [TaxMode](ctp:api:type:TaxMode).
	TaxCategory *TaxCategoryReference `json:"taxCategory,omitempty"`
	// Not set if a custom Shipping Method is used.
	ShippingMethod *ShippingMethodReference `json:"shippingMethod,omitempty"`
	// Information on how items are delivered to customers.
	Deliveries []Delivery `json:"deliveries"`
	// Discounted price of the Shipping Method.
	DiscountedPrice *DiscountedLineItemPrice `json:"discountedPrice,omitempty"`
	// Indicates whether the [ShippingMethod](ctp:api:type:ShippingMethod) referenced in this ShippingInfo is allowed for the Cart.
	ShippingMethodState ShippingMethodState `json:"shippingMethodState"`
}

func (ShippingInfo) MarshalJSON ¶

func (obj ShippingInfo) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingInfoImportDraft ¶

type ShippingInfoImportDraft struct {
	ShippingMethodName string `json:"shippingMethodName"`
	Price              Money  `json:"price"`
	// The shipping rate used to determine the price.
	ShippingRate ShippingRateDraft              `json:"shippingRate"`
	TaxRate      *TaxRate                       `json:"taxRate,omitempty"`
	TaxCategory  *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
	// Not set if custom shipping method is used.
	ShippingMethod *ShippingMethodResourceIdentifier `json:"shippingMethod,omitempty"`
	// Deliveries are compilations of information on how the articles are being delivered to the customers.
	Deliveries      []DeliveryDraft               `json:"deliveries"`
	DiscountedPrice *DiscountedLineItemPriceDraft `json:"discountedPrice,omitempty"`
	// Indicates whether the ShippingMethod referenced is allowed for the cart or not.
	ShippingMethodState *ShippingMethodState `json:"shippingMethodState,omitempty"`
}

func (ShippingInfoImportDraft) MarshalJSON ¶

func (obj ShippingInfoImportDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethod ¶

type ShippingMethod struct {
	// Unique identifier of the ShippingMethod.
	ID string `json:"id"`
	// Current version of the ShippingMethod.
	Version int `json:"version"`
	// Date and time (UTC) the ShippingMethod was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the ShippingMethod was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the ShippingMethod.
	Key *string `json:"key,omitempty"`
	// Name of the ShippingMethod.
	Name string `json:"name"`
	// Localized name of the ShippingMethod.
	LocalizedName *LocalizedString `json:"localizedName,omitempty"`
	// Description of the ShippingMethod.
	Description *string `json:"description,omitempty"`
	// Localized description of the ShippingMethod.
	LocalizedDescription *LocalizedString `json:"localizedDescription,omitempty"`
	// [TaxCategory](ctp:api:type:TaxCategory) of all ZoneRates of the ShippingMethod.
	TaxCategory TaxCategoryReference `json:"taxCategory"`
	// Defines [ShippingRates](ctp:api:type:ShippingRate) (prices) for specific Zones.
	ZoneRates []ZoneRate `json:"zoneRates"`
	// If `true` this ShippingMethod is the [Project](ctp:api:type:Project)'s default ShippingMethod.
	IsDefault bool `json:"isDefault"`
	// Valid [Cart predicate](/projects/predicates#cart-predicates) to select a ShippingMethod for a Cart.
	Predicate *string `json:"predicate,omitempty"`
	// Custom Fields of the ShippingMethod.
	Custom *CustomFields `json:"custom,omitempty"`
}

type ShippingMethodAddShippingRateAction ¶

type ShippingMethodAddShippingRateAction struct {
	// [Zone](ctp:api:type:Zone) to which the ShippingRate should be added.
	Zone ZoneResourceIdentifier `json:"zone"`
	// Value to add to `shippingRates`.
	ShippingRate ShippingRateDraft `json:"shippingRate"`
}

func (ShippingMethodAddShippingRateAction) MarshalJSON ¶

func (obj ShippingMethodAddShippingRateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodAddZoneAction ¶

type ShippingMethodAddZoneAction struct {
	// Value to add to `zoneRates`.
	Zone ZoneResourceIdentifier `json:"zone"`
}

func (ShippingMethodAddZoneAction) MarshalJSON ¶

func (obj ShippingMethodAddZoneAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodChangeIsDefaultAction ¶

type ShippingMethodChangeIsDefaultAction struct {
	// Value to set. Only one ShippingMethod can be default in a [Project](ctp:api:type:Project).
	IsDefault bool `json:"isDefault"`
}

func (ShippingMethodChangeIsDefaultAction) MarshalJSON ¶

func (obj ShippingMethodChangeIsDefaultAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodChangeNameAction ¶

type ShippingMethodChangeNameAction struct {
	// Value to set. Must not be empty.
	Name string `json:"name"`
}

func (ShippingMethodChangeNameAction) MarshalJSON ¶

func (obj ShippingMethodChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodChangeTaxCategoryAction ¶

type ShippingMethodChangeTaxCategoryAction struct {
	// Value to set.
	TaxCategory TaxCategoryResourceIdentifier `json:"taxCategory"`
}

func (ShippingMethodChangeTaxCategoryAction) MarshalJSON ¶

func (obj ShippingMethodChangeTaxCategoryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodDoesNotMatchCartError ¶

type ShippingMethodDoesNotMatchCartError struct {
	// `"The predicate does not match the cart."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the Cart contains a ShippingMethod(ctp:api:type:ShippingMethod) that is not allowed for the Cart(ctp:api:type:Cart). In this case, the ShippingMethodState(ctp:api:type:ShippingMethodState) value is `DoesNotMatchCart`. * * The error is returned as a failed response to the [Create Order from Cart](ctp:api:endpoint:/{projectKey}/orders:POST) or [Create Order in Store from Cart](ctp:api:endpoint:/{projectKey}/in-store/orders:POST) requests. *

func (*ShippingMethodDoesNotMatchCartError) DecodeStruct ¶

func (obj *ShippingMethodDoesNotMatchCartError) DecodeStruct(src map[string]interface{}) error

func (ShippingMethodDoesNotMatchCartError) Error ¶

func (ShippingMethodDoesNotMatchCartError) MarshalJSON ¶

func (obj ShippingMethodDoesNotMatchCartError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ShippingMethodDoesNotMatchCartError) UnmarshalJSON ¶

func (obj *ShippingMethodDoesNotMatchCartError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ShippingMethodDraft ¶

type ShippingMethodDraft struct {
	// User-defined unique identifier for the ShippingMethod.
	Key *string `json:"key,omitempty"`
	// Name of the ShippingMethod.
	Name string `json:"name"`
	// Localized name of the ShippingMethod.
	LocalizedName *LocalizedString `json:"localizedName,omitempty"`
	// Description of the ShippingMethod.
	Description *string `json:"description,omitempty"`
	// Localized description of the ShippingMethod.
	LocalizedDescription *LocalizedString `json:"localizedDescription,omitempty"`
	// [TaxCategory](ctp:api:type:TaxCategory) for all ZoneRates of the ShippingMethod.
	TaxCategory TaxCategoryResourceIdentifier `json:"taxCategory"`
	// Defines [ShippingRates](ctp:api:type:ShippingRate) (prices) for specific zones.
	ZoneRates []ZoneRateDraft `json:"zoneRates"`
	// If `true` the ShippingMethod will be the [Project](ctp:api:type:Project)'s default ShippingMethod.
	IsDefault bool `json:"isDefault"`
	// Valid [Cart predicate](/projects/predicates#cart-predicates) to select a ShippingMethod for a Cart.
	Predicate *string `json:"predicate,omitempty"`
	// Custom Fields for the ShippingMethod.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

type ShippingMethodPagedQueryResponse ¶

type ShippingMethodPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit *int `json:"limit,omitempty"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset *int `json:"offset,omitempty"`
	// [Shipping Methods](ctp:api:type:ShippingMethod) matching the query.
	Results []ShippingMethod `json:"results"`
}

* * [PagedQueryResult](/general-concepts#pagedqueryresult) with `results` containing an array of ShippingMethod(ctp:api:type:ShippingMethod). *

type ShippingMethodReference ¶

type ShippingMethodReference struct {
	// Unique identifier of the referenced [ShippingMethod](ctp:api:type:ShippingMethod).
	ID string `json:"id"`
	// Contains the representation of the expanded ShippingMethod. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for ShippingMethods.
	Obj *ShippingMethod `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a ShippingMethod(ctp:api:type:ShippingMethod). *

func (ShippingMethodReference) MarshalJSON ¶

func (obj ShippingMethodReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodRemoveShippingRateAction ¶

type ShippingMethodRemoveShippingRateAction struct {
	// [Zone](ctp:api:type:Zone) from which the ShippingRate should be removed.
	Zone ZoneResourceIdentifier `json:"zone"`
	// Value to remove from `shippingRates`.
	ShippingRate ShippingRateDraft `json:"shippingRate"`
}

func (ShippingMethodRemoveShippingRateAction) MarshalJSON ¶

func (obj ShippingMethodRemoveShippingRateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodRemoveZoneAction ¶

type ShippingMethodRemoveZoneAction struct {
	// Value to remove from `zoneRates`.
	Zone ZoneResourceIdentifier `json:"zone"`
}

func (ShippingMethodRemoveZoneAction) MarshalJSON ¶

func (obj ShippingMethodRemoveZoneAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodResourceIdentifier ¶

type ShippingMethodResourceIdentifier struct {
	// Unique identifier of the referenced [ShippingMethod](ctp:api:type:ShippingMethod). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [ShippingMethod](ctp:api:type:ShippingMethod). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a ShippingMethod(ctp:api:type:ShippingMethod). *

func (ShippingMethodResourceIdentifier) MarshalJSON ¶

func (obj ShippingMethodResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodSetCustomFieldAction ¶

type ShippingMethodSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

* * This action sets, overwrites, or removes any existing [Custom Field](/projects/custom-fields) for an existing ShippingMethod. *

func (ShippingMethodSetCustomFieldAction) MarshalJSON ¶

func (obj ShippingMethodSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodSetCustomTypeAction ¶

type ShippingMethodSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the ShippingMethod with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the ShippingMethod.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the ShippingMethod.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (ShippingMethodSetCustomTypeAction) MarshalJSON ¶

func (obj ShippingMethodSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodSetDescriptionAction ¶

type ShippingMethodSetDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	Description *string `json:"description,omitempty"`
}

func (ShippingMethodSetDescriptionAction) MarshalJSON ¶

func (obj ShippingMethodSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodSetKeyAction ¶

type ShippingMethodSetKeyAction struct {
	// If `key` is absent or `null`, the existing key, if any, will be removed.
	Key *string `json:"key,omitempty"`
}

func (ShippingMethodSetKeyAction) MarshalJSON ¶

func (obj ShippingMethodSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodSetLocalizedDescriptionAction ¶

type ShippingMethodSetLocalizedDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	LocalizedDescription *LocalizedString `json:"localizedDescription,omitempty"`
}

func (ShippingMethodSetLocalizedDescriptionAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodSetLocalizedNameAction ¶

type ShippingMethodSetLocalizedNameAction struct {
	// Value to set. If empty, any existing value will be removed.
	LocalizedName *LocalizedString `json:"localizedName,omitempty"`
}

func (ShippingMethodSetLocalizedNameAction) MarshalJSON ¶

func (obj ShippingMethodSetLocalizedNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodSetPredicateAction ¶

type ShippingMethodSetPredicateAction struct {
	// A valid [Cart predicate](/projects/predicates#cart-predicates). If `predicate` is absent or `null`, it is removed if it exists.
	Predicate *string `json:"predicate,omitempty"`
}

func (ShippingMethodSetPredicateAction) MarshalJSON ¶

func (obj ShippingMethodSetPredicateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShippingMethodState ¶

type ShippingMethodState string

* * Determines whether a ShippingMethod(ctp:api:type:ShippingMethod) is allowed for a Cart. *

const (
	ShippingMethodStateDoesNotMatchCart ShippingMethodState = "DoesNotMatchCart"
	ShippingMethodStateMatchesCart      ShippingMethodState = "MatchesCart"
)

type ShippingMethodUpdate ¶

type ShippingMethodUpdate struct {
	// Expected version of the ShippingMethod on which the changes should be applied. If the expected version does not match the actual version, a 409 Conflict will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the [ShippingMethod](/projects/shippingMethods#shippingmethod).
	Actions []ShippingMethodUpdateAction `json:"actions"`
}

func (*ShippingMethodUpdate) UnmarshalJSON ¶

func (obj *ShippingMethodUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ShippingMethodUpdateAction ¶

type ShippingMethodUpdateAction interface{}

type ShippingMode ¶

type ShippingMode string
const (
	ShippingModeSingle   ShippingMode = "Single"
	ShippingModeMultiple ShippingMode = "Multiple"
)

type ShippingRate ¶

type ShippingRate struct {
	// Currency amount of the ShippingRate.
	Price TypedMoney `json:"price"`
	// Shipping is free if the sum of the (Custom) Line Item Prices reaches the specified value.
	FreeAbove TypedMoney `json:"freeAbove,omitempty"`
	// `true` if the ShippingRate matches given [Cart](ctp:api:type:Cart) or [Location](ctp:api:type:Location).
	// Only appears in response to requests for [Get ShippingMethods for a Cart](ctp:api:endpoint:/{projectKey}/shipping-methods/matching-cart:GET) or
	// [Get ShippingMethods for a Location](ctp:api:endpoint:/{projectKey}/shipping-methods/matching-location:GET).
	IsMatching *bool `json:"isMatching,omitempty"`
	// Price tiers for the ShippingRate.
	Tiers []ShippingRatePriceTier `json:"tiers"`
}

func (*ShippingRate) UnmarshalJSON ¶

func (obj *ShippingRate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ShippingRateDraft ¶

type ShippingRateDraft struct {
	// Money value of the ShippingRate.
	Price Money `json:"price"`
	// Shipping is free if the sum of the (Custom) Line Item Prices reaches the specified value.
	FreeAbove *Money `json:"freeAbove,omitempty"`
	// Price tiers for the ShippingRate.
	Tiers []ShippingRatePriceTier `json:"tiers"`
}

func (ShippingRateDraft) MarshalJSON ¶

func (obj ShippingRateDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ShippingRateDraft) UnmarshalJSON ¶

func (obj *ShippingRateDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ShippingRateInput ¶

type ShippingRateInput interface{}

type ShippingRateInputDraft ¶

type ShippingRateInputDraft interface{}

* * Generic type holding specifc ShippingRateInputDraft types.

type ShippingRateInputType ¶

type ShippingRateInputType interface{}

type ShippingRatePriceTier ¶

type ShippingRatePriceTier interface{}

type ShippingRateTierType ¶

type ShippingRateTierType string
const (
	ShippingRateTierTypeCartValue          ShippingRateTierType = "CartValue"
	ShippingRateTierTypeCartClassification ShippingRateTierType = "CartClassification"
	ShippingRateTierTypeCartScore          ShippingRateTierType = "CartScore"
)

type ShoppingList ¶

type ShoppingList struct {
	// Unique identifier of the ShoppingList.
	ID string `json:"id"`
	// Current version of the ShoppingList.
	Version int `json:"version"`
	// Date and time (UTC) the ShoppingList was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the ShoppingList was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Name of the ShoppingList.
	Name LocalizedString `json:"name"`
	// User-defined unique identifier of the ShoppingList.
	Key *string `json:"key,omitempty"`
	// Reference to a [Customer](ctp:api:type:Customer) associated with the ShoppingList.
	Customer *CustomerReference `json:"customer,omitempty"`
	// Human-readable identifiers usually used as deep-link URL to the related ShoppingList.
	// Each slug is unique across a Project, but a ShoppingList can have the same slug for different languages.
	// The slug must match the pattern `[a-zA-Z0-9_-]{2,256}`. For [good performance](/predicates/query#performance-considerations), indexes are provided for the first 15 `languages` set on the [Project](ctp:api:type:Project).
	Slug *LocalizedString `json:"slug,omitempty"`
	// Description of the ShoppingList.
	Description *LocalizedString `json:"description,omitempty"`
	// Line Items (containing Products) of the ShoppingList.
	LineItems []ShoppingListLineItem `json:"lineItems"`
	// Line Items (containing text values) of the ShoppingList.
	TextLineItems []TextLineItem `json:"textLineItems"`
	// Number of days after which the ShoppingList will be automatically deleted if it has not been modified.
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
	// Identifies ShoppingLists belonging to an [anonymous session](ctp:api:type:AnonymousSession).
	AnonymousId *string `json:"anonymousId,omitempty"`
	// Store to which the ShoppingList is assigned.
	Store *StoreKeyReference `json:"store,omitempty"`
	// Custom Fields defined for the ShoppingList.
	Custom *CustomFields `json:"custom,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
}

type ShoppingListAddLineItemAction ¶

type ShoppingListAddLineItemAction struct {
	// `sku` of the [ProductVariant](ctp:api:type:ProductVariant).
	Sku *string `json:"sku,omitempty"`
	// Unique identifier of a [Product](ctp:api:type:Product).
	ProductId *string `json:"productId,omitempty"`
	// `id` of the [ProductVariant](ctp:api:type:ProductVariant). If not set, the ShoppingListLineItem refers to the Master Variant.
	VariantId *int `json:"variantId,omitempty"`
	// Number of Products in the ShoppingListLineItem.
	Quantity *int `json:"quantity,omitempty"`
	// Date and time the TextLineItem is added to the [ShoppingList](ctp:api:type:ShoppingList). If not set, the current date and time (UTC) is used.
	AddedAt *time.Time `json:"addedAt,omitempty"`
	// Custom Fields defined for the ShoppingListLineItem.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

* * The ProductVariant(ctp:api:type:ProductVariant) to be included in the ShoppingListLineItem must be specified using the `productID` and `variantID`, or by the `sku`. * If the ShoppingList already contains a ShoppingListLineItem for the same Product Variant with the same Custom Fields, then only the quantity of the existing ShoppingListLineItem is increased. * A ShoppingListLineItem with an empty `variantId` is not considered the same as a ShoppingListLineItem with a `variantId` currently referring to the Master Variant. *

func (ShoppingListAddLineItemAction) MarshalJSON ¶

func (obj ShoppingListAddLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListAddTextLineItemAction ¶

type ShoppingListAddTextLineItemAction struct {
	// Name of the TextLineItem.
	Name LocalizedString `json:"name"`
	// Description of the TextLineItem.
	Description *LocalizedString `json:"description,omitempty"`
	// Number of entries in the TextLineItem.
	Quantity *int `json:"quantity,omitempty"`
	// Date and time the TextLineItem is added to the [ShoppingList](ctp:api:type:ShoppingList). If not set, the current date and time (UTC) is used.
	AddedAt *time.Time `json:"addedAt,omitempty"`
	// Custom Fields defined for the TextLineItem.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (ShoppingListAddTextLineItemAction) MarshalJSON ¶

func (obj ShoppingListAddTextLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListChangeLineItemQuantityAction ¶

type ShoppingListChangeLineItemQuantityAction struct {
	// The `id` of the [ShoppingListLineItem](ctp:api:type:ShoppingListLineItem) to update.
	LineItemId string `json:"lineItemId"`
	// New value to set. If `0`, the ShoppingListLineItem is removed from the ShoppingList.
	Quantity int `json:"quantity"`
}

func (ShoppingListChangeLineItemQuantityAction) MarshalJSON ¶

func (obj ShoppingListChangeLineItemQuantityAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListChangeLineItemsOrderAction ¶

type ShoppingListChangeLineItemsOrderAction struct {
	// All existing ShoppingListLineItem `id`s in the desired new order.
	LineItemOrder []string `json:"lineItemOrder"`
}

func (ShoppingListChangeLineItemsOrderAction) MarshalJSON ¶

func (obj ShoppingListChangeLineItemsOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListChangeNameAction ¶

type ShoppingListChangeNameAction struct {
	// New value to set. Must not be empty.
	Name LocalizedString `json:"name"`
}

func (ShoppingListChangeNameAction) MarshalJSON ¶

func (obj ShoppingListChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListChangeTextLineItemNameAction ¶

type ShoppingListChangeTextLineItemNameAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// New value to set. Must not be empty.
	Name LocalizedString `json:"name"`
}

func (ShoppingListChangeTextLineItemNameAction) MarshalJSON ¶

func (obj ShoppingListChangeTextLineItemNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListChangeTextLineItemQuantityAction ¶

type ShoppingListChangeTextLineItemQuantityAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// New value to set. If `0`, the TextLineItem is removed from the ShoppingList.
	Quantity int `json:"quantity"`
}

func (ShoppingListChangeTextLineItemQuantityAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListChangeTextLineItemsOrderAction ¶

type ShoppingListChangeTextLineItemsOrderAction struct {
	// Must contain all existing [TextLineItem](ctp:api:type:TextLineItem) `id`s in the desired new order.
	TextLineItemOrder []string `json:"textLineItemOrder"`
}

func (ShoppingListChangeTextLineItemsOrderAction) MarshalJSON ¶

func (obj ShoppingListChangeTextLineItemsOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListDraft ¶

type ShoppingListDraft struct {
	// Name of the ShoppingList.
	Name LocalizedString `json:"name"`
	// Human-readable identifiers usually used as deep-link URL to the related ShoppingList.
	// Each slug is unique across a Project, but a ShoppingList can have the same slug for different languages.
	// The slug must match the pattern `[a-zA-Z0-9_-]{2,256}`.
	Slug *LocalizedString `json:"slug,omitempty"`
	// The [Customer](ctp:api:type:Customer) the ShoppingList should be associated to.
	Customer *CustomerResourceIdentifier `json:"customer,omitempty"`
	// User-defined unique identifier for the ShoppingList.
	Key *string `json:"key,omitempty"`
	// Description of the ShoppingList.
	Description *LocalizedString `json:"description,omitempty"`
	// Identifies ShoppingLists belonging to an [anonymous session](ctp:api:type:AnonymousSession).
	AnonymousId *string `json:"anonymousId,omitempty"`
	// Number of days after which the ShoppingList will be automatically deleted if it has not been modified. If not set, the [default value](ctp:api:type:ShoppingListsConfiguration) configured in the [Project](ctp:api:type:Project) is used.
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
	// Line Items (containing Products) to add to the ShoppingList.
	LineItems []ShoppingListLineItemDraft `json:"lineItems"`
	// Line Items (containing text values) to add to the ShoppingList.
	TextLineItems []TextLineItemDraft `json:"textLineItems"`
	// Assigns the new ShoppingList to the [Store](ctp:api:type:Store).
	Store *StoreResourceIdentifier `json:"store,omitempty"`
	// Custom Fields defined for the ShoppingList.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (ShoppingListDraft) MarshalJSON ¶

func (obj ShoppingListDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListLineItem ¶

type ShoppingListLineItem struct {
	// Date and time (UTC) the ShoppingListLineItem was added to the ShoppingList.
	AddedAt time.Time `json:"addedAt"`
	// Custom Fields of the ShoppingListLineItem.
	Custom *CustomFields `json:"custom,omitempty"`
	// If the Product or Product Variant is deleted, `deactivatedAt` is the date and time (UTC) of deletion.
	//
	// This data is updated in an [eventual consistent manner](/general-concepts#eventual-consistency) when the Product Variant cannot be ordered anymore.
	DeactivatedAt *time.Time `json:"deactivatedAt,omitempty"`
	// Unique identifier of the ShoppingListLineItem.
	ID string `json:"id"`
	// Name of the Product.
	//
	// This data is updated in an [eventual consistent manner](/general-concepts#eventual-consistency) when the Product's name changes.
	Name LocalizedString `json:"name"`
	// Unique identifier of a [Product](ctp:api:type:Product).
	ProductId string `json:"productId"`
	// The Product Type defining the Attributes of the [Product](ctp:api:type:Product).
	ProductType ProductTypeReference `json:"productType"`
	// Number of Products in the ShoppingListLineItem.
	Quantity int `json:"quantity"`
	// `id` of the [ProductVariant](ctp:api:type:ProductVariant) the ShoppingListLineItem refers to. If not set, the ShoppingListLineItem refers to the Master Variant.
	VariantId *int `json:"variantId,omitempty"`
	// Data of the [ProductVariant](ctp:api:type:ProductVariant).
	//
	// Returned when expanded using `expand=lineItems[*].variant`. You cannot expand only a single element of the array.
	Variant *ProductVariant `json:"variant,omitempty"`
	// Slug of the current [ProductData](ctp:api:type:ProductData).
	//
	// Returned when expanded using `expand=lineItems[*].productSlug`. You cannot expand only a single element of the array.
	ProductSlug *LocalizedString `json:"productSlug,omitempty"`
}

* * ShoppingListLineItems are Line Items that contain references to [ProductVariants](ctp:api:type:ProductVariant) in a Product(ctp:api:type:Product). * * In addition to standard [Reference Expansion](/general-concepts#reference-expansion), a ShoppingListLineItem offers expansion on `productSlug` and `variant`, defined with the query parameter `expand`. *

type ShoppingListLineItemDraft ¶

type ShoppingListLineItemDraft struct {
	// Unique identifier of a [Product](ctp:api:type:Product).
	ProductId *string `json:"productId,omitempty"`
	// `id` of the [ProductVariant](ctp:api:type:ProductVariant). If not set, the ShoppingListLineItem refers to the Master Variant.
	VariantId *int `json:"variantId,omitempty"`
	// `sku` of the [ProductVariant](ctp:api:type:ProductVariant).
	Sku *string `json:"sku,omitempty"`
	// Date and time the ShoppingListLineItem is added to the [ShoppingList](ctp:api:type:ShoppingList). If not set, the current date and time (UTC) is used.
	AddedAt *time.Time `json:"addedAt,omitempty"`
	// Custom Fields of the ShoppingListLineItem.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Number of Products in the ShoppingListLineItem.
	Quantity *int `json:"quantity,omitempty"`
}

* * The ProductVariant(ctp:api:type:ProductVariant) to be included in the ShoppingListLineItem must be specified using the `productID` and `variantID`, or by the `sku`. *

type ShoppingListPagedQueryResponse ¶

type ShoppingListPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// [ShoppingLists](ctp:api:type:ShoppingList) matching the query.
	Results []ShoppingList `json:"results"`
}

type ShoppingListReference ¶

type ShoppingListReference struct {
	// Unique identifier of the referenced [ShoppingList](ctp:api:type:ShoppingList).
	ID string `json:"id"`
	// Contains the representation of the expanded ShoppingList. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for ShoppingLists.
	Obj *ShoppingList `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a ShoppingList(ctp:api:type:ShoppingList). *

func (ShoppingListReference) MarshalJSON ¶

func (obj ShoppingListReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListRemoveLineItemAction ¶

type ShoppingListRemoveLineItemAction struct {
	// The `id` of the [ShoppingListLineItem](ctp:api:type:ShoppingListLineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Amount to remove from the `quantity` of the ShoppingListLineItem. If not set, the ShoppingListLineItem is removed from the ShoppingList. If this value matches or exceeds the current `quantity` of the ShoppingListLineItem, the ShoppingListLineItem is removed from the ShoppingList.
	Quantity *int `json:"quantity,omitempty"`
}

func (ShoppingListRemoveLineItemAction) MarshalJSON ¶

func (obj ShoppingListRemoveLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListRemoveTextLineItemAction ¶

type ShoppingListRemoveTextLineItemAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// Amount to remove from the `quantity` of the TextLineItem. If not set, the TextLineItem is removed from the ShoppingList. If this value matches or exceeds the current `quantity` of the TextLineItem, the TextLineItem is removed from the ShoppingList.
	Quantity *int `json:"quantity,omitempty"`
}

func (ShoppingListRemoveTextLineItemAction) MarshalJSON ¶

func (obj ShoppingListRemoveTextLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListResourceIdentifier ¶

type ShoppingListResourceIdentifier struct {
	// Unique identifier of the referenced [ShoppingList](ctp:api:type:ShoppingList). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [ShoppingList](ctp:api:type:ShoppingList). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a ShoppingList(ctp:api:type:ShoppingList). *

func (ShoppingListResourceIdentifier) MarshalJSON ¶

func (obj ShoppingListResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetAnonymousIdAction ¶

type ShoppingListSetAnonymousIdAction struct {
	// Value to set. If empty, any existing value will be removed.
	AnonymousId *string `json:"anonymousId,omitempty"`
}

func (ShoppingListSetAnonymousIdAction) MarshalJSON ¶

func (obj ShoppingListSetAnonymousIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetCustomFieldAction ¶

type ShoppingListSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (ShoppingListSetCustomFieldAction) MarshalJSON ¶

func (obj ShoppingListSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetCustomTypeAction ¶

type ShoppingListSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the ShoppingList with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the ShoppingList.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the ShoppingList.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (ShoppingListSetCustomTypeAction) MarshalJSON ¶

func (obj ShoppingListSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetCustomerAction ¶

type ShoppingListSetCustomerAction struct {
	// The [Customer](ctp:api:type:Customer) the ShoppingList should be associated to. If empty, any existing value will be removed.
	Customer *CustomerResourceIdentifier `json:"customer,omitempty"`
}

func (ShoppingListSetCustomerAction) MarshalJSON ¶

func (obj ShoppingListSetCustomerAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetDeleteDaysAfterLastModificationAction ¶

type ShoppingListSetDeleteDaysAfterLastModificationAction struct {
	// Value to set. If empty, any existing value will be removed.
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
}

func (ShoppingListSetDeleteDaysAfterLastModificationAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetDescriptionAction ¶

type ShoppingListSetDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

func (ShoppingListSetDescriptionAction) MarshalJSON ¶

func (obj ShoppingListSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetKeyAction ¶

type ShoppingListSetKeyAction struct {
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

func (ShoppingListSetKeyAction) MarshalJSON ¶

func (obj ShoppingListSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetLineItemCustomFieldAction ¶

type ShoppingListSetLineItemCustomFieldAction struct {
	// The `id` of the [ShoppingListLineItem](ctp:api:type:ShoppingListLineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (ShoppingListSetLineItemCustomFieldAction) MarshalJSON ¶

func (obj ShoppingListSetLineItemCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetLineItemCustomTypeAction ¶

type ShoppingListSetLineItemCustomTypeAction struct {
	// The `id` of the [ShoppingListLineItem](ctp:api:type:ShoppingListLineItem) to update.
	LineItemId string `json:"lineItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the ShoppingListLineItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the ShoppingListLineItem.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the ShoppingListLineItem.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (ShoppingListSetLineItemCustomTypeAction) MarshalJSON ¶

func (obj ShoppingListSetLineItemCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetSlugAction ¶

type ShoppingListSetSlugAction struct {
	// Value to set. If empty, any existing value will be removed. Each slug is unique across a Project, but a ShoppingList can have the same slug for different languages. Must match the pattern `^[A-Za-z0-9_-]{2,256}+$`
	Slug *LocalizedString `json:"slug,omitempty"`
}

func (ShoppingListSetSlugAction) MarshalJSON ¶

func (obj ShoppingListSetSlugAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetStoreAction ¶

type ShoppingListSetStoreAction struct {
	// The [Store](ctp:api:type:Store) the ShoppingList should be assigned to. If empty, any existing value will be removed.
	Store *StoreResourceIdentifier `json:"store,omitempty"`
}

func (ShoppingListSetStoreAction) MarshalJSON ¶

func (obj ShoppingListSetStoreAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetTextLineItemCustomFieldAction ¶

type ShoppingListSetTextLineItemCustomFieldAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (ShoppingListSetTextLineItemCustomFieldAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetTextLineItemCustomTypeAction ¶

type ShoppingListSetTextLineItemCustomTypeAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the TextLineItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the TextLineItem.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the TextLineItem.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (ShoppingListSetTextLineItemCustomTypeAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListSetTextLineItemDescriptionAction ¶

type ShoppingListSetTextLineItemDescriptionAction struct {
	// The `id` of the [TextLineItem](ctp:api:type:TextLineItem) to update.
	TextLineItemId string `json:"textLineItemId"`
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

func (ShoppingListSetTextLineItemDescriptionAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListStoreSetMessagePayload ¶

type ShoppingListStoreSetMessagePayload struct {
	// [Reference](/../api/types#reference) to a [Store](ctp:api:type:Store) by its key.
	Store StoreKeyReference `json:"store"`
}

func (ShoppingListStoreSetMessagePayload) MarshalJSON ¶

func (obj ShoppingListStoreSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ShoppingListUpdate ¶

type ShoppingListUpdate struct {
	// Expected version of the ShoppingList on which the changes should be applied. If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) will be returned.
	Version int `json:"version"`
	// List of update actions to be performed on the ShoppingList.
	Actions []ShoppingListUpdateAction `json:"actions"`
}

func (*ShoppingListUpdate) UnmarshalJSON ¶

func (obj *ShoppingListUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ShoppingListUpdateAction ¶

type ShoppingListUpdateAction interface{}

type ShoppingListsConfiguration ¶

type ShoppingListsConfiguration struct {
	// Default value for the `deleteDaysAfterLastModification` parameter of the [ShoppingListDraft](ctp:api:type:ShoppingListDraft).
	// This field may not be present on Projects created before January 2020.
	DeleteDaysAfterLastModification *int `json:"deleteDaysAfterLastModification,omitempty"`
}

type SnsDestination ¶

type SnsDestination struct {
	// Only present if `authenticationMode` is set to `Credentials`.
	AccessKey *string `json:"accessKey,omitempty"`
	// Only present if `authenticationMode` is set to `Credentials`.
	AccessSecret *string `json:"accessSecret,omitempty"`
	// Amazon Resource Name (ARN) of the topic.
	TopicArn string `json:"topicArn"`
	// Defines the method of authentication for the SNS topic.
	AuthenticationMode *AwsAuthenticationMode `json:"authenticationMode,omitempty"`
}

* * [AWS SNS](https://aws.amazon.com/sns/) can be used to push messages to AWS Lambda, HTTP endpoints (webhooks), or fan-out messages to SQS queues. The SQS queue must be a [Standard](https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/standard-queues.html) queue type. * * We recommend setting `authenticationMode` to `IAM`, to avoid unnecessary key management. For IAM authentication and before creating the Subscription, give permissions to the following user account: `arn:aws-cn:iam::417094354346:user/subscriptions` if the Project is hosted in the China (AWS, Ningxia) Region; `arn:aws:iam::362576667341:user/subscriptions` for all other [Regions](/../api/general-concepts#regions). Otherwise, a test message will not be sent. * * If you prefer to use `Credentials` for authentication, we recommend [creating an IAM user](https://docs.aws.amazon.com/sns/latest/dg/sns-setting-up.html#create-iam-user) with an `accessKey` and `accessSecret` pair specifically for each Subscription. * * The IAM user should only have the `sns:Publish` permission on this topic. *

func (SnsDestination) MarshalJSON ¶

func (obj SnsDestination) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type SqsDestination ¶

type SqsDestination struct {
	// Only present if `authenticationMode` is set to `Credentials`.
	AccessKey *string `json:"accessKey,omitempty"`
	// Only present if `authenticationMode` is set to `Credentials`.
	AccessSecret *string `json:"accessSecret,omitempty"`
	// URL of the Amazon SQS queue.
	QueueUrl string `json:"queueUrl"`
	// [AWS Region](https://docs.aws.amazon.com/general/latest/gr/rande-manage.html) the message queue is located in.
	Region string `json:"region"`
	// Defines the method of authentication for the SQS queue.
	AuthenticationMode *AwsAuthenticationMode `json:"authenticationMode,omitempty"`
}

* * [AWS SQS](https://aws.amazon.com/sqs/) is a pull-queue on AWS. * The queue must be a [Standard](https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/standard-queues.html) queue type with a `MaximumMessageSize` of `256 KB`. * * We recommend setting `authenticationMode` to `IAM`, to avoid unnecessary key management. For IAM authentication and before creating the Subscription, give permissions to the following user account: `arn:aws-cn:iam::417094354346:user/subscriptions` if the Project is hosted in the China (AWS, Ningxia) Region; `arn:aws:iam::362576667341:user/subscriptions` for all other [Regions](/../api/general-concepts#regions). Otherwise, a test message will not be sent. * * If you prefer to use `Credentials` for authentication, we recommend [creating an IAM user](https://docs.aws.amazon.com/sns/latest/dg/sns-setting-up.html#create-iam-user) with an `accessKey` and `accessSecret` pair specifically for each Subscription. * * The IAM user should only have the `sqs:SendMessage` permission on this queue. *

func (SqsDestination) MarshalJSON ¶

func (obj SqsDestination) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StackingMode ¶

type StackingMode string

* * Describes how the Cart Discount interacts with other Discounts. *

const (
	StackingModeStacking              StackingMode = "Stacking"
	StackingModeStopAfterThisDiscount StackingMode = "StopAfterThisDiscount"
)

type StagedOrder ¶

type StagedOrder struct {
	// Unique identifier of the Order.
	ID string `json:"id"`
	// The current version of the order.
	Version        int       `json:"version"`
	CreatedAt      time.Time `json:"createdAt"`
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// This field will only be present if it was set for Order Import
	CompletedAt *time.Time `json:"completedAt,omitempty"`
	// String that uniquely identifies an order.
	// It can be used to create more human-readable (in contrast to ID) identifier for the order.
	// It should be unique across a project.
	// Once it's set it cannot be changed.
	OrderNumber   *string `json:"orderNumber,omitempty"`
	CustomerId    *string `json:"customerId,omitempty"`
	CustomerEmail *string `json:"customerEmail,omitempty"`
	// Identifies carts and orders belonging to an anonymous session (the customer has not signed up/in yet).
	AnonymousId *string `json:"anonymousId,omitempty"`
	// The Business Unit the Order belongs to.
	BusinessUnit    *BusinessUnitKeyReference `json:"businessUnit,omitempty"`
	Store           *StoreKeyReference        `json:"store,omitempty"`
	LineItems       []LineItem                `json:"lineItems"`
	CustomLineItems []CustomLineItem          `json:"customLineItems"`
	TotalPrice      TypedMoney                `json:"totalPrice"`
	// The taxes are calculated based on the shipping address.
	TaxedPrice *TaxedPrice `json:"taxedPrice,omitempty"`
	// Sum of `taxedPrice` of [ShippingInfo](ctp:api:type:ShippingInfo) across all Shipping Methods.
	// For `Platform` [TaxMode](ctp:api:type:TaxMode), it is set automatically only if [shipping address is set](ctp:api:type:CartSetShippingAddressAction) or [Shipping Method is added](ctp:api:type:CartAddShippingMethodAction) to the Cart.
	TaxedShippingPrice *TaxedPrice `json:"taxedShippingPrice,omitempty"`
	// Holds all shipping-related information per Shipping Method.
	//
	// For `Multi` [ShippingMode](ctp:api:typeShippingMode), it is updated automatically after the Shipping Methods are added.
	ShippingAddress *Address `json:"shippingAddress,omitempty"`
	BillingAddress  *Address `json:"billingAddress,omitempty"`
	// Indicates whether one or multiple Shipping Methods are added to the Cart.
	ShippingMode ShippingMode `json:"shippingMode"`
	// User-defined unique identifier of the Shipping Method with `Single` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
	// Custom Fields of the Shipping Method for `Single` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingCustomFields *CustomFields `json:"shippingCustomFields,omitempty"`
	// Holds all shipping-related information per Shipping Method for `Multi` [ShippingMode](ctp:api:typeShippingMode).
	//
	// It is updated automatically after the [Shipping Method is added](ctp:api:type:CartAddShippingMethodAction).
	Shipping []Shipping `json:"shipping"`
	TaxMode  *TaxMode   `json:"taxMode,omitempty"`
	// When calculating taxes for `taxedPrice`, the selected mode is used for rouding.
	TaxRoundingMode *RoundingMode `json:"taxRoundingMode,omitempty"`
	// Set when the customer is set and the customer is a member of a customer group.
	// Used for product variant price selection.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// A two-digit country code as per [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).
	// Used for product variant price selection.
	Country *string `json:"country,omitempty"`
	// One of the four predefined OrderStates.
	OrderState OrderState `json:"orderState"`
	// This reference can point to a state in a custom workflow.
	State         *StateReference `json:"state,omitempty"`
	ShipmentState *ShipmentState  `json:"shipmentState,omitempty"`
	PaymentState  *PaymentState   `json:"paymentState,omitempty"`
	// Set if the ShippingMethod is set.
	ShippingInfo *ShippingInfo `json:"shippingInfo,omitempty"`
	SyncInfo     []SyncInfo    `json:"syncInfo"`
	ReturnInfo   []ReturnInfo  `json:"returnInfo"`
	// The Purchase Order Number is typically set by the [Buyer](/quotes-overview#buyer) on a [QuoteRequest](ctp:api:type:QuoteRequest) to
	// track the purchase order during the [quote and order flow](/../api/quotes-overview#intended-workflow).
	PurchaseOrderNumber *string            `json:"purchaseOrderNumber,omitempty"`
	DiscountCodes       []DiscountCodeInfo `json:"discountCodes"`
	// Internal-only field.
	LastMessageSequenceNumber *int `json:"lastMessageSequenceNumber,omitempty"`
	// Set when this order was created from a cart.
	// The cart will have the state `Ordered`.
	Cart *CartReference `json:"cart,omitempty"`
	// Set when this order was created from a quote.
	Quote         *QuoteReference `json:"quote,omitempty"`
	Custom        *CustomFields   `json:"custom,omitempty"`
	PaymentInfo   *PaymentInfo    `json:"paymentInfo,omitempty"`
	Locale        *string         `json:"locale,omitempty"`
	InventoryMode *InventoryMode  `json:"inventoryMode,omitempty"`
	Origin        CartOrigin      `json:"origin"`
	// When calculating taxes for `taxedPrice`, the selected mode is used for calculating the price with LineItemLevel (horizontally) or UnitPriceLevel (vertically) calculation mode.
	TaxCalculationMode *TaxCalculationMode `json:"taxCalculationMode,omitempty"`
	// Input used to select a [ShippingRatePriceTier](ctp:api:type:ShippingRatePriceTier).
	// The data type of this field depends on the `shippingRateInputType.type` configured in the [Project](ctp:api:type:Project):
	//
	// - If `CartClassification`, it is [ClassificationShippingRateInput](ctp:api:type:ClassificationShippingRateInput).
	// - If `CartScore`, it is [ScoreShippingRateInput](ctp:api:type:ScoreShippingRateInput).
	// - If `CartValue`, it cannot be used.
	ShippingRateInput ShippingRateInput `json:"shippingRateInput,omitempty"`
	// Contains addresses for orders with multiple shipping addresses.
	ItemShippingAddresses []Address `json:"itemShippingAddresses"`
	// Automatically filled when a line item with LineItemMode `GiftLineItem` is removed from this order.
	RefusedGifts []CartDiscountReference `json:"refusedGifts"`
}

func (StagedOrder) MarshalJSON ¶

func (obj StagedOrder) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StagedOrder) UnmarshalJSON ¶

func (obj *StagedOrder) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StagedOrderAddCustomLineItemAction ¶

type StagedOrderAddCustomLineItemAction struct {
	// Draft type that stores amounts only in cent precision for the specified currency.
	Money Money `json:"money"`
	// JSON object where the keys are of type [Locale](ctp:api:type:Locale), and the values are the strings used for the corresponding language.
	Name     LocalizedString `json:"name"`
	Quantity *int            `json:"quantity,omitempty"`
	Slug     string          `json:"slug"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [TaxCategory](ctp:api:type:TaxCategory).
	TaxCategory *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
	// The representation used when creating or updating a [customizable data type](/../api/projects/types#list-of-customizable-data-types) with Custom Fields.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Controls calculation of taxed prices for Line Items, Custom Line Items, and Shipping Methods as explained in [Cart tax calculation](ctp:api:type:CartTaxCalculation).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	// - If `Standard`, Cart Discounts with a matching [CartDiscountCustomLineItemsTarget](ctp:api:type:CartDiscountCustomLineItemsTarget)
	// are applied to the Custom Line Item.
	// - If `External`, Cart Discounts are not considered on the Custom Line Item.
	PriceMode *CustomLineItemPriceMode `json:"priceMode,omitempty"`
}

func (StagedOrderAddCustomLineItemAction) MarshalJSON ¶

func (obj StagedOrderAddCustomLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderAddDeliveryAction ¶

type StagedOrderAddDeliveryAction struct {
	// User-defined unique identifier of a Delivery.
	DeliveryKey *string        `json:"deliveryKey,omitempty"`
	Items       []DeliveryItem `json:"items"`
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address *BaseAddress  `json:"address,omitempty"`
	Parcels []ParcelDraft `json:"parcels"`
	// Custom Fields for the Transaction.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (StagedOrderAddDeliveryAction) MarshalJSON ¶

func (obj StagedOrderAddDeliveryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderAddDiscountCodeAction ¶

type StagedOrderAddDiscountCodeAction struct {
	Code string `json:"code"`
}

func (StagedOrderAddDiscountCodeAction) MarshalJSON ¶

func (obj StagedOrderAddDiscountCodeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderAddItemShippingAddressAction ¶

type StagedOrderAddItemShippingAddressAction struct {
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address BaseAddress `json:"address"`
}

func (StagedOrderAddItemShippingAddressAction) MarshalJSON ¶

func (obj StagedOrderAddItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderAddLineItemAction ¶

type StagedOrderAddLineItemAction struct {
	// User-defined unique identifier of the LineItem.
	Key *string `json:"key,omitempty"`
	// The representation used when creating or updating a [customizable data type](/../api/projects/types#list-of-customizable-data-types) with Custom Fields.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [Channel](ctp:api:type:Channel).
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
	// Controls calculation of taxed prices for Line Items, Custom Line Items, and Shipping Methods as explained in [Cart tax calculation](ctp:api:type:CartTaxCalculation).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	ProductId       *string               `json:"productId,omitempty"`
	VariantId       *int                  `json:"variantId,omitempty"`
	Sku             *string               `json:"sku,omitempty"`
	Quantity        *int                  `json:"quantity,omitempty"`
	AddedAt         *time.Time            `json:"addedAt,omitempty"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [Channel](ctp:api:type:Channel).
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
	// Draft type that stores amounts only in cent precision for the specified currency.
	ExternalPrice      *Money                      `json:"externalPrice,omitempty"`
	ExternalTotalPrice *ExternalLineItemTotalPrice `json:"externalTotalPrice,omitempty"`
	// For order creation and updates, the sum of the `targets` must match the quantity of the Line Items or Custom Line Items.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
}

func (StagedOrderAddLineItemAction) MarshalJSON ¶

func (obj StagedOrderAddLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderAddParcelToDeliveryAction ¶

type StagedOrderAddParcelToDeliveryAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey  *string             `json:"deliveryKey,omitempty"`
	ParcelKey    *string             `json:"parcelKey,omitempty"`
	Measurements *ParcelMeasurements `json:"measurements,omitempty"`
	TrackingData *TrackingData       `json:"trackingData,omitempty"`
	Items        []DeliveryItem      `json:"items"`
}

func (StagedOrderAddParcelToDeliveryAction) MarshalJSON ¶

func (obj StagedOrderAddParcelToDeliveryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderAddPaymentAction ¶

type StagedOrderAddPaymentAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) of a [Payment](ctp:api:type:Payment).
	Payment PaymentResourceIdentifier `json:"payment"`
}

func (StagedOrderAddPaymentAction) MarshalJSON ¶

func (obj StagedOrderAddPaymentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderAddReturnInfoAction ¶

type StagedOrderAddReturnInfoAction struct {
	ReturnTrackingId *string           `json:"returnTrackingId,omitempty"`
	Items            []ReturnItemDraft `json:"items"`
	ReturnDate       *time.Time        `json:"returnDate,omitempty"`
}

func (StagedOrderAddReturnInfoAction) MarshalJSON ¶

func (obj StagedOrderAddReturnInfoAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderAddShoppingListAction ¶

type StagedOrderAddShoppingListAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [ShoppingList](ctp:api:type:ShoppingList).
	ShoppingList ShoppingListResourceIdentifier `json:"shoppingList"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [Channel](ctp:api:type:Channel).
	SupplyChannel *ChannelResourceIdentifier `json:"supplyChannel,omitempty"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [Channel](ctp:api:type:Channel).
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
}

func (StagedOrderAddShoppingListAction) MarshalJSON ¶

func (obj StagedOrderAddShoppingListAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderChangeCustomLineItemMoneyAction ¶

type StagedOrderChangeCustomLineItemMoneyAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	// Draft type that stores amounts only in cent precision for the specified currency.
	Money Money `json:"money"`
}

func (StagedOrderChangeCustomLineItemMoneyAction) MarshalJSON ¶

func (obj StagedOrderChangeCustomLineItemMoneyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderChangeCustomLineItemQuantityAction ¶

type StagedOrderChangeCustomLineItemQuantityAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	Quantity         int    `json:"quantity"`
}

func (StagedOrderChangeCustomLineItemQuantityAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderChangeLineItemQuantityAction ¶

type StagedOrderChangeLineItemQuantityAction struct {
	LineItemId string `json:"lineItemId"`
	Quantity   int    `json:"quantity"`
	// Draft type that stores amounts only in cent precision for the specified currency.
	ExternalPrice      *Money                      `json:"externalPrice,omitempty"`
	ExternalTotalPrice *ExternalLineItemTotalPrice `json:"externalTotalPrice,omitempty"`
}

func (StagedOrderChangeLineItemQuantityAction) MarshalJSON ¶

func (obj StagedOrderChangeLineItemQuantityAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderChangeOrderStateAction ¶

type StagedOrderChangeOrderStateAction struct {
	OrderState OrderState `json:"orderState"`
}

func (StagedOrderChangeOrderStateAction) MarshalJSON ¶

func (obj StagedOrderChangeOrderStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderChangePaymentStateAction ¶

type StagedOrderChangePaymentStateAction struct {
	PaymentState *PaymentState `json:"paymentState,omitempty"`
}

func (StagedOrderChangePaymentStateAction) MarshalJSON ¶

func (obj StagedOrderChangePaymentStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderChangeShipmentStateAction ¶

type StagedOrderChangeShipmentStateAction struct {
	ShipmentState *ShipmentState `json:"shipmentState,omitempty"`
}

func (StagedOrderChangeShipmentStateAction) MarshalJSON ¶

func (obj StagedOrderChangeShipmentStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderChangeTaxCalculationModeAction ¶

type StagedOrderChangeTaxCalculationModeAction struct {
	// Determines in which [Tax calculation mode](/carts-orders-overview#tax-calculation-mode) taxed prices are calculated.
	TaxCalculationMode TaxCalculationMode `json:"taxCalculationMode"`
}

func (StagedOrderChangeTaxCalculationModeAction) MarshalJSON ¶

func (obj StagedOrderChangeTaxCalculationModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderChangeTaxModeAction ¶

type StagedOrderChangeTaxModeAction struct {
	// Indicates how taxes are set on the Cart.
	TaxMode TaxMode `json:"taxMode"`
}

func (StagedOrderChangeTaxModeAction) MarshalJSON ¶

func (obj StagedOrderChangeTaxModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderChangeTaxRoundingModeAction ¶

type StagedOrderChangeTaxRoundingModeAction struct {
	// Determines how monetary values are rounded.
	TaxRoundingMode RoundingMode `json:"taxRoundingMode"`
}

func (StagedOrderChangeTaxRoundingModeAction) MarshalJSON ¶

func (obj StagedOrderChangeTaxRoundingModeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderImportCustomLineItemStateAction ¶

type StagedOrderImportCustomLineItemStateAction struct {
	CustomLineItemId string      `json:"customLineItemId"`
	State            []ItemState `json:"state"`
}

func (StagedOrderImportCustomLineItemStateAction) MarshalJSON ¶

func (obj StagedOrderImportCustomLineItemStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderImportLineItemStateAction ¶

type StagedOrderImportLineItemStateAction struct {
	LineItemId string      `json:"lineItemId"`
	State      []ItemState `json:"state"`
}

func (StagedOrderImportLineItemStateAction) MarshalJSON ¶

func (obj StagedOrderImportLineItemStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderRemoveCustomLineItemAction ¶

type StagedOrderRemoveCustomLineItemAction struct {
	CustomLineItemId string `json:"customLineItemId"`
}

func (StagedOrderRemoveCustomLineItemAction) MarshalJSON ¶

func (obj StagedOrderRemoveCustomLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderRemoveDeliveryAction ¶

type StagedOrderRemoveDeliveryAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
}

func (StagedOrderRemoveDeliveryAction) MarshalJSON ¶

func (obj StagedOrderRemoveDeliveryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderRemoveDiscountCodeAction ¶

type StagedOrderRemoveDiscountCodeAction struct {
	// [Reference](ctp:api:type:Reference) to a [DiscountCode](ctp:api:type:DiscountCode).
	DiscountCode DiscountCodeReference `json:"discountCode"`
}

func (StagedOrderRemoveDiscountCodeAction) MarshalJSON ¶

func (obj StagedOrderRemoveDiscountCodeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderRemoveItemShippingAddressAction ¶

type StagedOrderRemoveItemShippingAddressAction struct {
	AddressKey string `json:"addressKey"`
}

func (StagedOrderRemoveItemShippingAddressAction) MarshalJSON ¶

func (obj StagedOrderRemoveItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderRemoveLineItemAction ¶

type StagedOrderRemoveLineItemAction struct {
	LineItemId string `json:"lineItemId"`
	Quantity   *int   `json:"quantity,omitempty"`
	// Draft type that stores amounts only in cent precision for the specified currency.
	ExternalPrice      *Money                      `json:"externalPrice,omitempty"`
	ExternalTotalPrice *ExternalLineItemTotalPrice `json:"externalTotalPrice,omitempty"`
	// For order creation and updates, the sum of the `targets` must match the quantity of the Line Items or Custom Line Items.
	ShippingDetailsToRemove *ItemShippingDetailsDraft `json:"shippingDetailsToRemove,omitempty"`
}

func (StagedOrderRemoveLineItemAction) MarshalJSON ¶

func (obj StagedOrderRemoveLineItemAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderRemoveParcelFromDeliveryAction ¶

type StagedOrderRemoveParcelFromDeliveryAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey *string `json:"parcelKey,omitempty"`
}

func (StagedOrderRemoveParcelFromDeliveryAction) MarshalJSON ¶

func (obj StagedOrderRemoveParcelFromDeliveryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderRemovePaymentAction ¶

type StagedOrderRemovePaymentAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) of a [Payment](ctp:api:type:Payment).
	Payment PaymentResourceIdentifier `json:"payment"`
}

func (StagedOrderRemovePaymentAction) MarshalJSON ¶

func (obj StagedOrderRemovePaymentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetBillingAddressAction ¶

type StagedOrderSetBillingAddressAction struct {
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address *BaseAddress `json:"address,omitempty"`
}

func (StagedOrderSetBillingAddressAction) MarshalJSON ¶

func (obj StagedOrderSetBillingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetBillingAddressCustomFieldAction ¶

type StagedOrderSetBillingAddressCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StagedOrderSetBillingAddressCustomFieldAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetBillingAddressCustomTypeAction ¶

type StagedOrderSetBillingAddressCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the `billingAddress` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `billingAddress`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `billingAddress`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StagedOrderSetBillingAddressCustomTypeAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCountryAction ¶

type StagedOrderSetCountryAction struct {
	Country *string `json:"country,omitempty"`
}

func (StagedOrderSetCountryAction) MarshalJSON ¶

func (obj StagedOrderSetCountryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCustomFieldAction ¶

type StagedOrderSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StagedOrderSetCustomFieldAction) MarshalJSON ¶

func (obj StagedOrderSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCustomLineItemCustomFieldAction ¶

type StagedOrderSetCustomLineItemCustomFieldAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StagedOrderSetCustomLineItemCustomFieldAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCustomLineItemCustomTypeAction ¶

type StagedOrderSetCustomLineItemCustomTypeAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the CustomLineItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the CustomLineItem.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the CustomLineItem.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StagedOrderSetCustomLineItemCustomTypeAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCustomLineItemShippingDetailsAction ¶

type StagedOrderSetCustomLineItemShippingDetailsAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	// For order creation and updates, the sum of the `targets` must match the quantity of the Line Items or Custom Line Items.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
}

func (StagedOrderSetCustomLineItemShippingDetailsAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCustomLineItemTaxAmountAction ¶

type StagedOrderSetCustomLineItemTaxAmountAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	// Cannot be used in [LineItemDraft](ctp:api:type:LineItemDraft) or [CustomLineItemDraft](ctp:api:type:CustomLineItemDraft).
	//
	// Can only be set by these update actions:
	//
	// - [Set LineItem TaxAmount](ctp:api:type:CartSetLineItemTaxAmountAction), [Set CustomLineItem TaxAmount](ctp:api:type:CartSetCustomLineItemTaxAmountAction), or [Set ShippingMethod TaxAmount](ctp:api:type:CartSetShippingMethodTaxAmountAction) on Carts
	// - [Set LineItem TaxAmount](ctp:api:type:OrderEditSetLineItemTaxAmountAction), [Set CustomLineItem TaxAmount](ctp:api:type:OrderEditSetCustomLineItemTaxAmountAction), or [Set ShippingMethod TaxAmount](ctp:api:type:OrderEditSetShippingMethodTaxAmountAction) on Order Edits
	ExternalTaxAmount *ExternalTaxAmountDraft `json:"externalTaxAmount,omitempty"`
}

func (StagedOrderSetCustomLineItemTaxAmountAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCustomLineItemTaxRateAction ¶

type StagedOrderSetCustomLineItemTaxRateAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	// Controls calculation of taxed prices for Line Items, Custom Line Items, and Shipping Methods as explained in [Cart tax calculation](ctp:api:type:CartTaxCalculation).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
}

func (StagedOrderSetCustomLineItemTaxRateAction) MarshalJSON ¶

func (obj StagedOrderSetCustomLineItemTaxRateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCustomShippingMethodAction ¶

type StagedOrderSetCustomShippingMethodAction struct {
	ShippingMethodName string            `json:"shippingMethodName"`
	ShippingRate       ShippingRateDraft `json:"shippingRate"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [TaxCategory](ctp:api:type:TaxCategory).
	TaxCategory *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
	// Controls calculation of taxed prices for Line Items, Custom Line Items, and Shipping Methods as explained in [Cart tax calculation](ctp:api:type:CartTaxCalculation).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
}

func (StagedOrderSetCustomShippingMethodAction) MarshalJSON ¶

func (obj StagedOrderSetCustomShippingMethodAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCustomTypeAction ¶

type StagedOrderSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the StagedOrder with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the StagedOrder.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the StagedOrder.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StagedOrderSetCustomTypeAction) MarshalJSON ¶

func (obj StagedOrderSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCustomerEmailAction ¶

type StagedOrderSetCustomerEmailAction struct {
	Email *string `json:"email,omitempty"`
}

func (StagedOrderSetCustomerEmailAction) MarshalJSON ¶

func (obj StagedOrderSetCustomerEmailAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCustomerGroupAction ¶

type StagedOrderSetCustomerGroupAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [CustomerGroup](ctp:api:type:CustomerGroup).
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
}

func (StagedOrderSetCustomerGroupAction) MarshalJSON ¶

func (obj StagedOrderSetCustomerGroupAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetCustomerIdAction ¶

type StagedOrderSetCustomerIdAction struct {
	CustomerId *string `json:"customerId,omitempty"`
}

func (StagedOrderSetCustomerIdAction) MarshalJSON ¶

func (obj StagedOrderSetCustomerIdAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetDeliveryAddressAction ¶

type StagedOrderSetDeliveryAddressAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address *BaseAddress `json:"address,omitempty"`
}

func (StagedOrderSetDeliveryAddressAction) MarshalJSON ¶

func (obj StagedOrderSetDeliveryAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetDeliveryAddressCustomFieldAction ¶

type StagedOrderSetDeliveryAddressCustomFieldAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StagedOrderSetDeliveryAddressCustomFieldAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetDeliveryAddressCustomTypeAction ¶

type StagedOrderSetDeliveryAddressCustomTypeAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
	// Defines the [Type](ctp:api:type:Type) that extends the `address` in a Delivery with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `address` in a Delivery.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `address` in a Delivery.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StagedOrderSetDeliveryAddressCustomTypeAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetDeliveryCustomFieldAction ¶

type StagedOrderSetDeliveryCustomFieldAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StagedOrderSetDeliveryCustomFieldAction) MarshalJSON ¶

func (obj StagedOrderSetDeliveryCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetDeliveryCustomTypeAction ¶

type StagedOrderSetDeliveryCustomTypeAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string `json:"deliveryKey,omitempty"`
	// Defines the [Type](ctp:api:type:Type) that extends the Delivery with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Delivery.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Delivery.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StagedOrderSetDeliveryCustomTypeAction) MarshalJSON ¶

func (obj StagedOrderSetDeliveryCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetDeliveryItemsAction ¶

type StagedOrderSetDeliveryItemsAction struct {
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryId *string `json:"deliveryId,omitempty"`
	// Either `deliveryId` or `deliveryKey` is required for this update action.
	DeliveryKey *string        `json:"deliveryKey,omitempty"`
	Items       []DeliveryItem `json:"items"`
}

func (StagedOrderSetDeliveryItemsAction) MarshalJSON ¶

func (obj StagedOrderSetDeliveryItemsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetItemShippingAddressCustomFieldAction ¶

type StagedOrderSetItemShippingAddressCustomFieldAction struct {
	AddressKey string `json:"addressKey"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StagedOrderSetItemShippingAddressCustomFieldAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetItemShippingAddressCustomTypeAction ¶

type StagedOrderSetItemShippingAddressCustomTypeAction struct {
	AddressKey string `json:"addressKey"`
	// Defines the [Type](ctp:api:type:Type) that extends the `itemShippingAddress` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `itemShippingAddress`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `itemShippingAddress`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StagedOrderSetItemShippingAddressCustomTypeAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetLineItemCustomFieldAction ¶

type StagedOrderSetLineItemCustomFieldAction struct {
	LineItemId string `json:"lineItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StagedOrderSetLineItemCustomFieldAction) MarshalJSON ¶

func (obj StagedOrderSetLineItemCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetLineItemCustomTypeAction ¶

type StagedOrderSetLineItemCustomTypeAction struct {
	LineItemId string `json:"lineItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the LineItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the LineItem.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the LineItem.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StagedOrderSetLineItemCustomTypeAction) MarshalJSON ¶

func (obj StagedOrderSetLineItemCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetLineItemDistributionChannelAction ¶

type StagedOrderSetLineItemDistributionChannelAction struct {
	LineItemId string `json:"lineItemId"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [Channel](ctp:api:type:Channel).
	DistributionChannel *ChannelResourceIdentifier `json:"distributionChannel,omitempty"`
}

func (StagedOrderSetLineItemDistributionChannelAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetLineItemPriceAction ¶

type StagedOrderSetLineItemPriceAction struct {
	LineItemId string `json:"lineItemId"`
	// Draft type that stores amounts only in cent precision for the specified currency.
	ExternalPrice *Money `json:"externalPrice,omitempty"`
}

func (StagedOrderSetLineItemPriceAction) MarshalJSON ¶

func (obj StagedOrderSetLineItemPriceAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetLineItemShippingDetailsAction ¶

type StagedOrderSetLineItemShippingDetailsAction struct {
	LineItemId string `json:"lineItemId"`
	// For order creation and updates, the sum of the `targets` must match the quantity of the Line Items or Custom Line Items.
	ShippingDetails *ItemShippingDetailsDraft `json:"shippingDetails,omitempty"`
}

func (StagedOrderSetLineItemShippingDetailsAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetLineItemTaxAmountAction ¶

type StagedOrderSetLineItemTaxAmountAction struct {
	LineItemId string `json:"lineItemId"`
	// Cannot be used in [LineItemDraft](ctp:api:type:LineItemDraft) or [CustomLineItemDraft](ctp:api:type:CustomLineItemDraft).
	//
	// Can only be set by these update actions:
	//
	// - [Set LineItem TaxAmount](ctp:api:type:CartSetLineItemTaxAmountAction), [Set CustomLineItem TaxAmount](ctp:api:type:CartSetCustomLineItemTaxAmountAction), or [Set ShippingMethod TaxAmount](ctp:api:type:CartSetShippingMethodTaxAmountAction) on Carts
	// - [Set LineItem TaxAmount](ctp:api:type:OrderEditSetLineItemTaxAmountAction), [Set CustomLineItem TaxAmount](ctp:api:type:OrderEditSetCustomLineItemTaxAmountAction), or [Set ShippingMethod TaxAmount](ctp:api:type:OrderEditSetShippingMethodTaxAmountAction) on Order Edits
	ExternalTaxAmount *ExternalTaxAmountDraft `json:"externalTaxAmount,omitempty"`
	// `key` of the [ShippingMethod](ctp:api:type:ShippingMethod) used for this Line Item.“`
	// This is required for Carts with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

func (StagedOrderSetLineItemTaxAmountAction) MarshalJSON ¶

func (obj StagedOrderSetLineItemTaxAmountAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetLineItemTaxRateAction ¶

type StagedOrderSetLineItemTaxRateAction struct {
	LineItemId string `json:"lineItemId"`
	// Controls calculation of taxed prices for Line Items, Custom Line Items, and Shipping Methods as explained in [Cart tax calculation](ctp:api:type:CartTaxCalculation).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
	// `key` of the [ShippingMethod](ctp:api:type:ShippingMethod) used for this Line Item.
	// This is required for Carts with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
}

func (StagedOrderSetLineItemTaxRateAction) MarshalJSON ¶

func (obj StagedOrderSetLineItemTaxRateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetLineItemTotalPriceAction ¶

type StagedOrderSetLineItemTotalPriceAction struct {
	LineItemId         string                      `json:"lineItemId"`
	ExternalTotalPrice *ExternalLineItemTotalPrice `json:"externalTotalPrice,omitempty"`
}

func (StagedOrderSetLineItemTotalPriceAction) MarshalJSON ¶

func (obj StagedOrderSetLineItemTotalPriceAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetLocaleAction ¶

type StagedOrderSetLocaleAction struct {
	Locale *string `json:"locale,omitempty"`
}

func (StagedOrderSetLocaleAction) MarshalJSON ¶

func (obj StagedOrderSetLocaleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetOrderNumberAction ¶

type StagedOrderSetOrderNumberAction struct {
	OrderNumber *string `json:"orderNumber,omitempty"`
}

func (StagedOrderSetOrderNumberAction) MarshalJSON ¶

func (obj StagedOrderSetOrderNumberAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetOrderTotalTaxAction ¶

type StagedOrderSetOrderTotalTaxAction struct {
	// Draft type that stores amounts only in cent precision for the specified currency.
	ExternalTotalGross  Money             `json:"externalTotalGross"`
	ExternalTaxPortions []TaxPortionDraft `json:"externalTaxPortions"`
}

func (StagedOrderSetOrderTotalTaxAction) MarshalJSON ¶

func (obj StagedOrderSetOrderTotalTaxAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetParcelCustomFieldAction ¶

type StagedOrderSetParcelCustomFieldAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey *string `json:"parcelKey,omitempty"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StagedOrderSetParcelCustomFieldAction) MarshalJSON ¶

func (obj StagedOrderSetParcelCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetParcelCustomTypeAction ¶

type StagedOrderSetParcelCustomTypeAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey *string `json:"parcelKey,omitempty"`
	// Defines the [Type](ctp:api:type:Type) that extends the Parcel with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Parcel.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Parcel.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StagedOrderSetParcelCustomTypeAction) MarshalJSON ¶

func (obj StagedOrderSetParcelCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetParcelItemsAction ¶

type StagedOrderSetParcelItemsAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey *string        `json:"parcelKey,omitempty"`
	Items     []DeliveryItem `json:"items"`
}

func (StagedOrderSetParcelItemsAction) MarshalJSON ¶

func (obj StagedOrderSetParcelItemsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetParcelMeasurementsAction ¶

type StagedOrderSetParcelMeasurementsAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey    *string             `json:"parcelKey,omitempty"`
	Measurements *ParcelMeasurements `json:"measurements,omitempty"`
}

func (StagedOrderSetParcelMeasurementsAction) MarshalJSON ¶

func (obj StagedOrderSetParcelMeasurementsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetParcelTrackingDataAction ¶

type StagedOrderSetParcelTrackingDataAction struct {
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelId *string `json:"parcelId,omitempty"`
	// Either `parcelId` or `parcelKey` is required for this update action.
	ParcelKey    *string       `json:"parcelKey,omitempty"`
	TrackingData *TrackingData `json:"trackingData,omitempty"`
}

func (StagedOrderSetParcelTrackingDataAction) MarshalJSON ¶

func (obj StagedOrderSetParcelTrackingDataAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetPurchaseOrderNumberAction ¶

type StagedOrderSetPurchaseOrderNumberAction struct {
	// Identifier for a purchase order, usually in a B2B context.
	// The Purchase Order Number is typically entered by the [Buyer](/quotes-overview#buyer) and can also be used with [Quotes](/quotes-overview).
	PurchaseOrderNumber *string `json:"purchaseOrderNumber,omitempty"`
}

func (StagedOrderSetPurchaseOrderNumberAction) MarshalJSON ¶

func (obj StagedOrderSetPurchaseOrderNumberAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetReturnInfoAction ¶

type StagedOrderSetReturnInfoAction struct {
	Items []ReturnInfoDraft `json:"items"`
}

func (StagedOrderSetReturnInfoAction) MarshalJSON ¶

func (obj StagedOrderSetReturnInfoAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetReturnItemCustomFieldAction ¶

type StagedOrderSetReturnItemCustomFieldAction struct {
	ReturnItemId string `json:"returnItemId"`
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StagedOrderSetReturnItemCustomFieldAction) MarshalJSON ¶

func (obj StagedOrderSetReturnItemCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetReturnItemCustomTypeAction ¶

type StagedOrderSetReturnItemCustomTypeAction struct {
	ReturnItemId string `json:"returnItemId"`
	// Defines the [Type](ctp:api:type:Type) that extends the ReturnItem with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the ReturnItem.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the ReturnItem.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StagedOrderSetReturnItemCustomTypeAction) MarshalJSON ¶

func (obj StagedOrderSetReturnItemCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetReturnPaymentStateAction ¶

type StagedOrderSetReturnPaymentStateAction struct {
	ReturnItemId string             `json:"returnItemId"`
	PaymentState ReturnPaymentState `json:"paymentState"`
}

func (StagedOrderSetReturnPaymentStateAction) MarshalJSON ¶

func (obj StagedOrderSetReturnPaymentStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetReturnShipmentStateAction ¶

type StagedOrderSetReturnShipmentStateAction struct {
	ReturnItemId  string              `json:"returnItemId"`
	ShipmentState ReturnShipmentState `json:"shipmentState"`
}

func (StagedOrderSetReturnShipmentStateAction) MarshalJSON ¶

func (obj StagedOrderSetReturnShipmentStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetShippingAddressAction ¶

type StagedOrderSetShippingAddressAction struct {
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address *BaseAddress `json:"address,omitempty"`
}

func (StagedOrderSetShippingAddressAction) MarshalJSON ¶

func (obj StagedOrderSetShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetShippingAddressAndCustomShippingMethodAction ¶

type StagedOrderSetShippingAddressAndCustomShippingMethodAction struct {
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address            BaseAddress       `json:"address"`
	ShippingMethodName string            `json:"shippingMethodName"`
	ShippingRate       ShippingRateDraft `json:"shippingRate"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [TaxCategory](ctp:api:type:TaxCategory).
	TaxCategory *TaxCategoryResourceIdentifier `json:"taxCategory,omitempty"`
	// Controls calculation of taxed prices for Line Items, Custom Line Items, and Shipping Methods as explained in [Cart tax calculation](ctp:api:type:CartTaxCalculation).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
}

func (StagedOrderSetShippingAddressAndCustomShippingMethodAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetShippingAddressAndShippingMethodAction ¶

type StagedOrderSetShippingAddressAndShippingMethodAction struct {
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address BaseAddress `json:"address"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [ShippingMethod](ctp:api:type:ShippingMethod).
	ShippingMethod *ShippingMethodResourceIdentifier `json:"shippingMethod,omitempty"`
	// Controls calculation of taxed prices for Line Items, Custom Line Items, and Shipping Methods as explained in [Cart tax calculation](ctp:api:type:CartTaxCalculation).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
}

func (StagedOrderSetShippingAddressAndShippingMethodAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetShippingAddressCustomFieldAction ¶

type StagedOrderSetShippingAddressCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StagedOrderSetShippingAddressCustomFieldAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetShippingAddressCustomTypeAction ¶

type StagedOrderSetShippingAddressCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the `shippingAddress` with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the `shippingAddress`.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the `shippingAddress`.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StagedOrderSetShippingAddressCustomTypeAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetShippingMethodAction ¶

type StagedOrderSetShippingMethodAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [ShippingMethod](ctp:api:type:ShippingMethod).
	ShippingMethod *ShippingMethodResourceIdentifier `json:"shippingMethod,omitempty"`
	// Controls calculation of taxed prices for Line Items, Custom Line Items, and Shipping Methods as explained in [Cart tax calculation](ctp:api:type:CartTaxCalculation).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
}

func (StagedOrderSetShippingMethodAction) MarshalJSON ¶

func (obj StagedOrderSetShippingMethodAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetShippingMethodTaxAmountAction ¶

type StagedOrderSetShippingMethodTaxAmountAction struct {
	// `key` of the [ShippingMethod](ctp:api:type:ShippingMethod) to update. This is required for Orders with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
	// Cannot be used in [LineItemDraft](ctp:api:type:LineItemDraft) or [CustomLineItemDraft](ctp:api:type:CustomLineItemDraft).
	//
	// Can only be set by these update actions:
	//
	// - [Set LineItem TaxAmount](ctp:api:type:CartSetLineItemTaxAmountAction), [Set CustomLineItem TaxAmount](ctp:api:type:CartSetCustomLineItemTaxAmountAction), or [Set ShippingMethod TaxAmount](ctp:api:type:CartSetShippingMethodTaxAmountAction) on Carts
	// - [Set LineItem TaxAmount](ctp:api:type:OrderEditSetLineItemTaxAmountAction), [Set CustomLineItem TaxAmount](ctp:api:type:OrderEditSetCustomLineItemTaxAmountAction), or [Set ShippingMethod TaxAmount](ctp:api:type:OrderEditSetShippingMethodTaxAmountAction) on Order Edits
	ExternalTaxAmount *ExternalTaxAmountDraft `json:"externalTaxAmount,omitempty"`
}

func (StagedOrderSetShippingMethodTaxAmountAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetShippingMethodTaxRateAction ¶

type StagedOrderSetShippingMethodTaxRateAction struct {
	// `key` of the [ShippingMethod](ctp:api:type:ShippingMethod) to update. This is required for Orders with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
	ShippingKey *string `json:"shippingKey,omitempty"`
	// Controls calculation of taxed prices for Line Items, Custom Line Items, and Shipping Methods as explained in [Cart tax calculation](ctp:api:type:CartTaxCalculation).
	ExternalTaxRate *ExternalTaxRateDraft `json:"externalTaxRate,omitempty"`
}

func (StagedOrderSetShippingMethodTaxRateAction) MarshalJSON ¶

func (obj StagedOrderSetShippingMethodTaxRateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderSetShippingRateInputAction ¶

type StagedOrderSetShippingRateInputAction struct {
	// Generic type holding specifc ShippingRateInputDraft types.
	ShippingRateInput ShippingRateInputDraft `json:"shippingRateInput,omitempty"`
}

func (StagedOrderSetShippingRateInputAction) MarshalJSON ¶

func (obj StagedOrderSetShippingRateInputAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StagedOrderSetShippingRateInputAction) UnmarshalJSON ¶

func (obj *StagedOrderSetShippingRateInputAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StagedOrderTransitionCustomLineItemStateAction ¶

type StagedOrderTransitionCustomLineItemStateAction struct {
	CustomLineItemId string `json:"customLineItemId"`
	Quantity         int    `json:"quantity"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	FromState StateResourceIdentifier `json:"fromState"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	ToState              StateResourceIdentifier `json:"toState"`
	ActualTransitionDate *time.Time              `json:"actualTransitionDate,omitempty"`
}

func (StagedOrderTransitionCustomLineItemStateAction) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderTransitionLineItemStateAction ¶

type StagedOrderTransitionLineItemStateAction struct {
	LineItemId string `json:"lineItemId"`
	Quantity   int    `json:"quantity"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	FromState StateResourceIdentifier `json:"fromState"`
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	ToState              StateResourceIdentifier `json:"toState"`
	ActualTransitionDate *time.Time              `json:"actualTransitionDate,omitempty"`
}

func (StagedOrderTransitionLineItemStateAction) MarshalJSON ¶

func (obj StagedOrderTransitionLineItemStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderTransitionStateAction ¶

type StagedOrderTransitionStateAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [State](ctp:api:type:State).
	State StateResourceIdentifier `json:"state"`
	Force *bool                   `json:"force,omitempty"`
}

func (StagedOrderTransitionStateAction) MarshalJSON ¶

func (obj StagedOrderTransitionStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderUpdateAction ¶

type StagedOrderUpdateAction interface{}

type StagedOrderUpdateItemShippingAddressAction ¶

type StagedOrderUpdateItemShippingAddressAction struct {
	// Polymorphic base type that represents a postal address and contact details.
	// Depending on the read or write action, it can be either [Address](ctp:api:type:Address) or [AddressDraft](ctp:api:type:AddressDraft) that
	// only differ in the data type for the optional `custom` field.
	Address BaseAddress `json:"address"`
}

func (StagedOrderUpdateItemShippingAddressAction) MarshalJSON ¶

func (obj StagedOrderUpdateItemShippingAddressAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedOrderUpdateSyncInfoAction ¶

type StagedOrderUpdateSyncInfoAction struct {
	// [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [Channel](ctp:api:type:Channel).
	Channel    ChannelResourceIdentifier `json:"channel"`
	ExternalId *string                   `json:"externalId,omitempty"`
	SyncedAt   *time.Time                `json:"syncedAt,omitempty"`
}

func (StagedOrderUpdateSyncInfoAction) MarshalJSON ¶

func (obj StagedOrderUpdateSyncInfoAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuote ¶

type StagedQuote struct {
	// The unique ID of the StagedQuote.
	ID string `json:"id"`
	// Current version of the StagedQuote.
	Version int `json:"version"`
	// Date and time (UTC) the StagedQuote was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the StagedQuote was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// User-specific unique identifier of the staged quote.
	Key *string `json:"key,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Predefined states tracking the status of the Staged Quote.
	StagedQuoteState StagedQuoteState `json:"stagedQuoteState"`
	// The [Buyer](/../api/quotes-overview#buyer) who requested the Quote.
	Customer *CustomerReference `json:"customer,omitempty"`
	// Quote Request related to the Staged Quote.
	QuoteRequest QuoteRequestReference `json:"quoteRequest"`
	// [Cart](ctp:api:type:Cart) containing the offered items. May contain either [DirectDiscounts](ctp:api:type:DirectDiscount) or [CartDiscounts](ctp:api:type:CartDiscount).
	QuotationCart CartReference `json:"quotationCart"`
	// Expiration date for the Quote.
	ValidTo *time.Time `json:"validTo,omitempty"`
	// Message from the [Seller](/../api/quotes-overview#seller) included in the offer.
	SellerComment *string `json:"sellerComment,omitempty"`
	// Custom Fields of the Staged Quote.
	Custom *CustomFields `json:"custom,omitempty"`
	// [State](ctp:api:type:State) of the Staged Quote.
	// This reference can point to a State in a custom workflow.
	State *StateReference `json:"state,omitempty"`
	// The Purchase Order Number is typically set by the [Buyer](/quotes-overview#buyer) on a [QuoteRequest](ctp:api:type:QuoteRequest) to
	// track the purchase order during the [quote and order flow](/../api/quotes-overview#intended-workflow).
	PurchaseOrderNumber *string `json:"purchaseOrderNumber,omitempty"`
	// The [BusinessUnit](ctp:api:type:BusinessUnit) for the Staged Quote.
	BusinessUnit *BusinessUnitKeyReference `json:"businessUnit,omitempty"`
}

type StagedQuoteChangeStagedQuoteStateAction ¶

type StagedQuoteChangeStagedQuoteStateAction struct {
	// New state to be set for the Staged Quote.
	StagedQuoteState StagedQuoteState `json:"stagedQuoteState"`
}

func (StagedQuoteChangeStagedQuoteStateAction) MarshalJSON ¶

func (obj StagedQuoteChangeStagedQuoteStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteCreatedMessage ¶

type StagedQuoteCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Staged Quote](/../api/projects/staged-quotes) that was created.
	StagedQuote StagedQuote `json:"stagedQuote"`
}

* * Generated after a successful [Create Staged Quote](/../api/projects/staged-quotes#create-stagedquote) request. *

func (StagedQuoteCreatedMessage) MarshalJSON ¶

func (obj StagedQuoteCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StagedQuoteCreatedMessage) UnmarshalJSON ¶

func (obj *StagedQuoteCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StagedQuoteCreatedMessagePayload ¶

type StagedQuoteCreatedMessagePayload struct {
	// [Staged Quote](/../api/projects/staged-quotes) that was created.
	StagedQuote StagedQuote `json:"stagedQuote"`
}

* * Generated after a successful [Create Staged Quote](/../api/projects/staged-quotes#create-stagedquote) request. *

func (StagedQuoteCreatedMessagePayload) MarshalJSON ¶

func (obj StagedQuoteCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteDeletedMessage ¶

type StagedQuoteDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
}

* * Generated after a successful [Delete Staged Quote](/../api/projects/staged-quotes#delete-stagedquote) request. *

func (StagedQuoteDeletedMessage) MarshalJSON ¶

func (obj StagedQuoteDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StagedQuoteDeletedMessage) UnmarshalJSON ¶

func (obj *StagedQuoteDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StagedQuoteDeletedMessagePayload ¶

type StagedQuoteDeletedMessagePayload struct {
}

* * Generated after a successful [Delete Staged Quote](/../api/projects/staged-quotes#delete-stagedquote) request. *

func (StagedQuoteDeletedMessagePayload) MarshalJSON ¶

func (obj StagedQuoteDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteDraft ¶

type StagedQuoteDraft struct {
	// QuoteRequest from which the StagedQuote is created.
	QuoteRequest QuoteRequestResourceIdentifier `json:"quoteRequest"`
	// Current version of the QuoteRequest.
	QuoteRequestVersion int `json:"quoteRequestVersion"`
	// If `true`, the `quoteRequestState` of the referenced [QuoteRequest](ctp:api:type:QuoteRequest) will be set to `Accepted`.
	QuoteRequestStateToAccepted *bool `json:"quoteRequestStateToAccepted,omitempty"`
	// User-defined unique identifier for the StagedQuote.
	Key *string `json:"key,omitempty"`
	// [Custom Fields](/../api/projects/custom-fields) to be added to the StagedQuote.
	//
	// - If specified, the Custom Fields are merged with the Custom Fields on the referenced [QuoteRequest](ctp:api:type:QuoteRequest) and added to the StagedQuote.
	// - If empty, the Custom Fields on the referenced [QuoteRequest](ctp:api:type:QuoteRequest) are added to the StagedQuote automatically.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// [State](ctp:api:type:State) of the Staged Quote.
	// This reference can point to a State in a custom workflow.
	State *StateReference `json:"state,omitempty"`
}

type StagedQuotePagedQueryResponse ¶

type StagedQuotePagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Staged Quotes matching the query.
	Results []StagedQuote `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of StagedQuote(ctp:api:type:StagedQuote). *

type StagedQuoteReference ¶

type StagedQuoteReference struct {
	// Unique ID of the referenced resource.
	ID string `json:"id"`
	// Contains the representation of the expanded StagedQuote.
	// Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for StagedQuote.
	Obj *StagedQuote `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a StagedQuote(ctp:api:type:StagedQuote). *

func (StagedQuoteReference) MarshalJSON ¶

func (obj StagedQuoteReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteResourceIdentifier ¶

type StagedQuoteResourceIdentifier struct {
	// Unique identifier of the referenced resource. Required if `key` is absent.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced resource. Required if `id` is absent.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a StagedQuote(ctp:api:type:StagedQuote). *

func (StagedQuoteResourceIdentifier) MarshalJSON ¶

func (obj StagedQuoteResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteSellerCommentSetMessage ¶

type StagedQuoteSellerCommentSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// `sellerComment` on the [StagedQuote](ctp:api:type:StagedQuote) after a successful [Set Seller Comment](ctp:api:type:StagedQuoteSetSellerCommentAction) update action.
	SellerComment string `json:"sellerComment"`
}

* * Generated after a successful [Set Seller Comment](ctp:api:type:StagedQuoteSetSellerCommentAction) update action. *

func (StagedQuoteSellerCommentSetMessage) MarshalJSON ¶

func (obj StagedQuoteSellerCommentSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StagedQuoteSellerCommentSetMessage) UnmarshalJSON ¶

func (obj *StagedQuoteSellerCommentSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StagedQuoteSellerCommentSetMessagePayload ¶

type StagedQuoteSellerCommentSetMessagePayload struct {
	// `sellerComment` on the [StagedQuote](ctp:api:type:StagedQuote) after a successful [Set Seller Comment](ctp:api:type:StagedQuoteSetSellerCommentAction) update action.
	SellerComment string `json:"sellerComment"`
}

* * Generated after a successful [Set Seller Comment](ctp:api:type:StagedQuoteSetSellerCommentAction) update action. *

func (StagedQuoteSellerCommentSetMessagePayload) MarshalJSON ¶

func (obj StagedQuoteSellerCommentSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteSetCustomFieldAction ¶

type StagedQuoteSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StagedQuoteSetCustomFieldAction) MarshalJSON ¶

func (obj StagedQuoteSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteSetCustomTypeAction ¶

type StagedQuoteSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the StagedQuote with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the StagedQuote.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the StagedQuote.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StagedQuoteSetCustomTypeAction) MarshalJSON ¶

func (obj StagedQuoteSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteSetSellerCommentAction ¶

type StagedQuoteSetSellerCommentAction struct {
	// If `sellerComment` is absent or `null`, this field will be removed if it exists.
	SellerComment *string `json:"sellerComment,omitempty"`
}

func (StagedQuoteSetSellerCommentAction) MarshalJSON ¶

func (obj StagedQuoteSetSellerCommentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteSetValidToAction ¶

type StagedQuoteSetValidToAction struct {
	// If `validTo` is absent or `null`, this field will be removed if it exists.
	ValidTo *time.Time `json:"validTo,omitempty"`
}

func (StagedQuoteSetValidToAction) MarshalJSON ¶

func (obj StagedQuoteSetValidToAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteState ¶

type StagedQuoteState string

* * Predefined states tracking the status of the Staged Quote. *

const (
	StagedQuoteStateInProgress StagedQuoteState = "InProgress"
	StagedQuoteStateSent       StagedQuoteState = "Sent"
	StagedQuoteStateClosed     StagedQuoteState = "Closed"
)

type StagedQuoteStateChangedMessage ¶

type StagedQuoteStateChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// State of the Staged Quote after the [Change Staged Quote State](ctp:api:type:StagedQuoteChangeStagedQuoteStateAction) update action.
	StagedQuoteState StagedQuoteState `json:"stagedQuoteState"`
	// State of the Staged Quote before the [Change Staged Quote State](ctp:api:type:StagedQuoteChangeStagedQuoteStateAction) update action.
	OldStagedQuoteState StagedQuoteState `json:"oldStagedQuoteState"`
}

* * Generated after a successful [Change Staged Quote State](ctp:api:type:StagedQuoteChangeStagedQuoteStateAction) update action. *

func (StagedQuoteStateChangedMessage) MarshalJSON ¶

func (obj StagedQuoteStateChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StagedQuoteStateChangedMessage) UnmarshalJSON ¶

func (obj *StagedQuoteStateChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StagedQuoteStateChangedMessagePayload ¶

type StagedQuoteStateChangedMessagePayload struct {
	// State of the Staged Quote after the [Change Staged Quote State](ctp:api:type:StagedQuoteChangeStagedQuoteStateAction) update action.
	StagedQuoteState StagedQuoteState `json:"stagedQuoteState"`
	// State of the Staged Quote before the [Change Staged Quote State](ctp:api:type:StagedQuoteChangeStagedQuoteStateAction) update action.
	OldStagedQuoteState StagedQuoteState `json:"oldStagedQuoteState"`
}

* * Generated after a successful [Change Staged Quote State](ctp:api:type:StagedQuoteChangeStagedQuoteStateAction) update action. *

func (StagedQuoteStateChangedMessagePayload) MarshalJSON ¶

func (obj StagedQuoteStateChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteStateTransitionMessage ¶

type StagedQuoteStateTransitionMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) after the [Transition State](ctp:api:type:StagedQuoteTransitionStateAction) update action.
	State StateReference `json:"state"`
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) before the [Transition State](ctp:api:type:StagedQuoteTransitionStateAction) update action.
	OldState *StateReference `json:"oldState,omitempty"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:StagedQuoteTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:StagedQuoteTransitionStateAction) update action. *

func (StagedQuoteStateTransitionMessage) MarshalJSON ¶

func (obj StagedQuoteStateTransitionMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StagedQuoteStateTransitionMessage) UnmarshalJSON ¶

func (obj *StagedQuoteStateTransitionMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StagedQuoteStateTransitionMessagePayload ¶

type StagedQuoteStateTransitionMessagePayload struct {
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) after the [Transition State](ctp:api:type:StagedQuoteTransitionStateAction) update action.
	State StateReference `json:"state"`
	// [State](ctp:api:type:State) of the [Quote](ctp:api:type:Quote) before the [Transition State](ctp:api:type:StagedQuoteTransitionStateAction) update action.
	OldState *StateReference `json:"oldState,omitempty"`
	// Whether [State](ctp:api:type:State) transition validations were turned off during the [Transition State](ctp:api:type:StagedQuoteTransitionStateAction) update action.
	Force bool `json:"force"`
}

* * Generated after a successful [Transition State](ctp:api:type:StagedQuoteTransitionStateAction) update action. *

func (StagedQuoteStateTransitionMessagePayload) MarshalJSON ¶

func (obj StagedQuoteStateTransitionMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteTransitionStateAction ¶

type StagedQuoteTransitionStateAction struct {
	// Value to set.
	// If there is no State yet, the new State must be an initial State.
	State StateResourceIdentifier `json:"state"`
	// Switch validations on or off.
	Force *bool `json:"force,omitempty"`
}

* * If the existing State(ctp:api:type:State) has set `transitions`, there must be a direct transition to the new State. If `transitions` is not set, no validation is performed. This update action produces the [Staged Quote State Transition](ctp:api:type:StagedQuoteStateTransitionMessage) Message. *

func (StagedQuoteTransitionStateAction) MarshalJSON ¶

func (obj StagedQuoteTransitionStateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedQuoteUpdate ¶

type StagedQuoteUpdate struct {
	// Expected version of the [StagedQuote](ctp:api:type:StagedQuote) to which the changes should be applied.
	// If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) error will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the [StagedQuote](ctp:api:type:StagedQuote).
	Actions []StagedQuoteUpdateAction `json:"actions"`
}

func (*StagedQuoteUpdate) UnmarshalJSON ¶

func (obj *StagedQuoteUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StagedQuoteUpdateAction ¶

type StagedQuoteUpdateAction interface{}

type StagedQuoteValidToSetMessage ¶

type StagedQuoteValidToSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Expiration date for the Staged Quote after the [Set Valid To](ctp:api:type:StagedQuoteSetValidToAction) update action.
	ValidTo time.Time `json:"validTo"`
}

* * Generated after a successful [Set Valid To](ctp:api:type:StagedQuoteSetValidToAction) update action. *

func (StagedQuoteValidToSetMessage) MarshalJSON ¶

func (obj StagedQuoteValidToSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StagedQuoteValidToSetMessage) UnmarshalJSON ¶

func (obj *StagedQuoteValidToSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StagedQuoteValidToSetMessagePayload ¶

type StagedQuoteValidToSetMessagePayload struct {
	// Expiration date for the Staged Quote after the [Set Valid To](ctp:api:type:StagedQuoteSetValidToAction) update action.
	ValidTo time.Time `json:"validTo"`
}

* * Generated after a successful [Set Valid To](ctp:api:type:StagedQuoteSetValidToAction) update action. *

func (StagedQuoteValidToSetMessagePayload) MarshalJSON ¶

func (obj StagedQuoteValidToSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StagedStandalonePrice ¶

type StagedStandalonePrice struct {
	// Money value of the StagedStandalonePrice.
	Value TypedMoney `json:"value"`
	// Discounted price for the StagedStandalonePrice.
	Discounted *DiscountedPrice `json:"discounted,omitempty"`
}

* * Staged changes on a Standalone Price. To update the `value` property of a Staged Standalone Price, use the corresponding [update action](ctp:api:type:StandalonePriceChangeValueAction). To apply all staged changes to the Standalone Price, use the `applyStagedChanges` update action.

func (*StagedStandalonePrice) UnmarshalJSON ¶

func (obj *StagedStandalonePrice) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePrice ¶

type StandalonePrice struct {
	// Unique identifier of the StandalonePrice.
	ID string `json:"id"`
	// Current version of the StandalonePrice.
	Version int `json:"version"`
	// Date and time (UTC) the StandalonePrice was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the StandalonePrice was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the StandalonePrice.
	Key *string `json:"key,omitempty"`
	// SKU of the [ProductVariant](ctp:api:type:ProductVariant) to which this Price is associated.
	Sku string `json:"sku"`
	// Money value of this Price.
	Value TypedMoney `json:"value"`
	// Country for which this Price is valid.
	Country *string `json:"country,omitempty"`
	// [CustomerGroup](ctp:api:type:CustomerGroup) for which this Price is valid.
	CustomerGroup *CustomerGroupReference `json:"customerGroup,omitempty"`
	// Product distribution [Channel](ctp:api:type:Channel) for which this Price is valid.
	Channel *ChannelReference `json:"channel,omitempty"`
	// Date from which the Price is valid.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Date until the Price is valid. Standalone Prices that are no longer valid are not automatically deleted, but they can be [deleted](/../api/projects/standalone-prices#delete-standaloneprice) if necessary.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Price tiers if any are defined.
	Tiers []PriceTier `json:"tiers"`
	// Set if a matching [ProductDiscount](ctp:api:type:ProductDiscount) exists. If set, the API uses the `discounted` value for the [LineItem Price selection](ctp:api:type:LineItemPriceSelection).
	// When a [relative discount](/../api/projects/productDiscounts#productdiscountvaluerelative) is applied and the fraction part of the `discounted` price is 0.5, the discounted price is rounded in favor of the customer with the [half down rounding](https://en.wikipedia.org/wiki/Rounding#Round_half_down).
	Discounted *DiscountedPrice `json:"discounted,omitempty"`
	// Custom Fields for the StandalonePrice.
	Custom *CustomFields `json:"custom,omitempty"`
	// Staged changes of the StandalonePrice. Only present if the StandalonePrice has staged changes.
	Staged *StagedStandalonePrice `json:"staged,omitempty"`
	// If set to `true`, the StandalonePrice is considered during [price selection](ctp:api:type:ProductPriceSelection).
	// If set to `false`, the StandalonePrice is not considered during [price selection](ctp:api:type:ProductPriceSelection).
	Active bool `json:"active"`
}

func (StandalonePrice) MarshalJSON ¶

func (obj StandalonePrice) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePrice) UnmarshalJSON ¶

func (obj *StandalonePrice) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceActiveChangedMessage ¶

type StandalonePriceActiveChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Value of the `active` field of the StandalonePrice after the [Change Active](ctp:api:types:StandalonePriceChangeActiveAction) update action.
	Active bool `json:"active"`
	// Value of the `active` field of the StandalonePrice before the [Change Active](ctp:api:types:StandalonePriceChangeActiveAction) update action.
	OldActive bool `json:"oldActive"`
}

* * Generated after a successful [Change Active](ctp:api:types:StandalonePriceChangeActiveAction) update action. *

func (StandalonePriceActiveChangedMessage) MarshalJSON ¶

func (obj StandalonePriceActiveChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceActiveChangedMessage) UnmarshalJSON ¶

func (obj *StandalonePriceActiveChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceActiveChangedMessagePayload ¶

type StandalonePriceActiveChangedMessagePayload struct {
	// Value of the `active` field of the StandalonePrice after the [Change Active](ctp:api:types:StandalonePriceChangeActiveAction) update action.
	Active bool `json:"active"`
	// Value of the `active` field of the StandalonePrice before the [Change Active](ctp:api:types:StandalonePriceChangeActiveAction) update action.
	OldActive bool `json:"oldActive"`
}

* * Generated after a successful [Change Active](ctp:api:types:StandalonePriceChangeActiveAction) update action. *

func (StandalonePriceActiveChangedMessagePayload) MarshalJSON ¶

func (obj StandalonePriceActiveChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceAddPriceTierAction ¶

type StandalonePriceAddPriceTierAction struct {
	// The [PriceTier](ctp:api:type:PriceTier) to be added to the `tiers` field of the [StandalonePrice](ctp:api:type:StandalonePrice).
	// The action returns an [InvalidField](ctp:api:type:InvalidFieldError) error in the following cases:
	//
	// * Trying to add a PriceTier with `minimumQuantity` < `2`.
	// * Trying to add a PriceTier with `minimumQuantity` that already exists for the StandalonePrice.
	Tier PriceTierDraft `json:"tier"`
}

* * Adding a PriceTier(ctp:api:type:PriceTier) to a StandalonePrice(ctp:api:type:StandalonePrice) produces the [Standalone Price Tier Added](ctp:api:type:StandalonePriceTierAddedMessage) Message. *

func (StandalonePriceAddPriceTierAction) MarshalJSON ¶

func (obj StandalonePriceAddPriceTierAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceApplyStagedChangesAction ¶

type StandalonePriceApplyStagedChangesAction struct {
}

* * Applies all staged changes to the StandalonePrice by overwriting all current values with the values in the StagedStandalonePrice(ctp:api:type:StagedStandalonePrice). After successfully applied, the StagedStandalonePrice(ctp:api:type:StagedStandalonePrice) will be removed from the StandalonePrice. An `applyStagedChanges` update action on a StandalonePrice that does not contain any staged changes will return a `400 Bad Request` error. Applying staged changes successfully will produce the [StandalonePriceStagedChangesApplied](ctp:api:type:StandalonePriceStagedChangesAppliedMessage) Message. *

func (StandalonePriceApplyStagedChangesAction) MarshalJSON ¶

func (obj StandalonePriceApplyStagedChangesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceChangeActiveAction ¶

type StandalonePriceChangeActiveAction struct {
	// New value to set for the `active` field of the [StandalonePrice](ctp:api:type:StandalonePrice).
	Active bool `json:"active"`
}

* * Updating the value of a StandalonePrice(ctp:api:type:StandalonePrice) produces the StandalonePriceActiveChangedMessage(ctp:api:type:StandalonePriceActiveChangedMessage). *

func (StandalonePriceChangeActiveAction) MarshalJSON ¶

func (obj StandalonePriceChangeActiveAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceChangeValueAction ¶

type StandalonePriceChangeValueAction struct {
	// New value to set. Must not be empty.
	Value Money `json:"value"`
	// If set to `true` the update action applies to the [StagedStandalonePrice](ctp:api:type:StagedStandalonePrice). If set to `false`, the update action applies to the current [StandalonePrice](ctp:api:type:StandalonePrice).
	Staged *bool `json:"staged,omitempty"`
}

* * Updating the value of a StandalonePrice(ctp:api:type:StandalonePrice) produces the StandalonePriceValueChangedMessage(ctp:api:type:StandalonePriceValueChangedMessage). *

func (StandalonePriceChangeValueAction) MarshalJSON ¶

func (obj StandalonePriceChangeValueAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceCreatedMessage ¶

type StandalonePriceCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Standalone Price](ctp:api:type:StandalonePrice) that was created.
	StandalonePrice StandalonePrice `json:"standalonePrice"`
}

* * Generated after a successful [Create StandalonePrice](/../api/projects/standalone-prices#create-standaloneprice) request. *

func (StandalonePriceCreatedMessage) MarshalJSON ¶

func (obj StandalonePriceCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceCreatedMessage) UnmarshalJSON ¶

func (obj *StandalonePriceCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceCreatedMessagePayload ¶

type StandalonePriceCreatedMessagePayload struct {
	// [Standalone Price](ctp:api:type:StandalonePrice) that was created.
	StandalonePrice StandalonePrice `json:"standalonePrice"`
}

* * Generated after a successful [Create StandalonePrice](/../api/projects/standalone-prices#create-standaloneprice) request. *

func (StandalonePriceCreatedMessagePayload) MarshalJSON ¶

func (obj StandalonePriceCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceDeletedMessage ¶

type StandalonePriceDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// SKU of the [ProductVariant](ctp:api:type:ProductVariant) to which the deleted Standalone Price was associated.
	Sku string `json:"sku"`
}

* * Generated after a successful [Delete StandalonePrice](/../api/projects/standalone-prices#delete-standaloneprice) request. *

func (StandalonePriceDeletedMessage) MarshalJSON ¶

func (obj StandalonePriceDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceDeletedMessage) UnmarshalJSON ¶

func (obj *StandalonePriceDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceDeletedMessagePayload ¶

type StandalonePriceDeletedMessagePayload struct {
	// SKU of the [ProductVariant](ctp:api:type:ProductVariant) to which the deleted Standalone Price was associated.
	Sku string `json:"sku"`
}

* * Generated after a successful [Delete StandalonePrice](/../api/projects/standalone-prices#delete-standaloneprice) request. *

func (StandalonePriceDeletedMessagePayload) MarshalJSON ¶

func (obj StandalonePriceDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceDiscountSetMessage ¶

type StandalonePriceDiscountSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The new `discounted` value of the updated [StandalonePrice](ctp:api:type:StandalonePrice).
	Discounted *DiscountedPrice `json:"discounted,omitempty"`
}

* * Generated after a [Product Discount](ctp:api:type:ProductDiscount) is successfully applied to a StandalonePrice. *

func (StandalonePriceDiscountSetMessage) MarshalJSON ¶

func (obj StandalonePriceDiscountSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceDiscountSetMessage) UnmarshalJSON ¶

func (obj *StandalonePriceDiscountSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceDiscountSetMessagePayload ¶

type StandalonePriceDiscountSetMessagePayload struct {
	// The new `discounted` value of the updated [StandalonePrice](ctp:api:type:StandalonePrice).
	Discounted *DiscountedPrice `json:"discounted,omitempty"`
}

* * Generated after a [Product Discount](ctp:api:type:ProductDiscount) is successfully applied to a StandalonePrice. *

func (StandalonePriceDiscountSetMessagePayload) MarshalJSON ¶

func (obj StandalonePriceDiscountSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceDraft ¶

type StandalonePriceDraft struct {
	// User-defined unique identifier for the StandalonePrice.
	Key *string `json:"key,omitempty"`
	// Specifies to which [ProductVariant](ctp:api:type:ProductVariant) the API associates this Price.
	// It is not validated to exist in product variants.
	Sku string `json:"sku"`
	// Sets the money value of this Price.
	Value Money `json:"value"`
	// Sets the country for which this Price is valid.
	Country *string `json:"country,omitempty"`
	// Sets the [CustomerGroup](ctp:api:type:CustomerGroup) for which this Price is valid.
	CustomerGroup *CustomerGroupResourceIdentifier `json:"customerGroup,omitempty"`
	// Sets the product distribution [Channel](ctp:api:type:Channel) for which this Price is valid.
	Channel *ChannelResourceIdentifier `json:"channel,omitempty"`
	// Sets the date from which the Price is valid. Must be at least 1 ms earlier than `validUntil`.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Sets the date until the Price is valid. Must be at least 1 ms later than `validFrom`. Standalone Prices that are no longer valid are not automatically deleted, but they can be [deleted](/../api/projects/standalone-prices#delete-standaloneprice) if necessary.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Sets price tiers.
	Tiers []PriceTierDraft `json:"tiers"`
	// Sets a discounted price for this Price that is different from the base price with `value`.
	Discounted *DiscountedPriceDraft `json:"discounted,omitempty"`
	// Custom Fields for the StandalonePrice.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// If set to `true`, the StandalonePrice is considered during [price selection](ctp:api:type:ProductPriceSelection).
	// If set to `false`, the StandalonePrice is not considered during [price selection](ctp:api:type:ProductPriceSelection).
	Active *bool `json:"active,omitempty"`
}

* * Standalone Prices are defined with a scope consisting of `currency` and optionally `country`, `customerGroup`, and `channel` and/or a validity period (`validFrom` and/or `validTo`). For more information see [price selection](/../api/projects/products#price-selection). * * Creating a Standalone Price for an SKU which has a Standalone Price with exactly the same price scope, or with overlapping validity periods within the same price scope returns the [DuplicateStandalonePriceScope](ctp:api:type:DuplicateStandalonePriceScopeError) and [OverlappingStandalonePriceValidity](ctp:api:type:OverlappingStandalonePriceValidityError) errors, respectively. A Price without validity period does not conflict with a Price defined for a time period.

func (StandalonePriceDraft) MarshalJSON ¶

func (obj StandalonePriceDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceExternalDiscountSetMessage ¶

type StandalonePriceExternalDiscountSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The `discounted` value of the [StandalonePrice](ctp:api:type:StandalonePrice) after the [Set Discounted Price](ctp:api:type:StandalonePriceSetDiscountedPriceAction) update action.
	Discounted *DiscountedPrice `json:"discounted,omitempty"`
}

* * Generated after a successful [Set Discounted Price](ctp:api:type:StandalonePriceSetDiscountedPriceAction) update action. *

func (StandalonePriceExternalDiscountSetMessage) MarshalJSON ¶

func (obj StandalonePriceExternalDiscountSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceExternalDiscountSetMessage) UnmarshalJSON ¶

func (obj *StandalonePriceExternalDiscountSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceExternalDiscountSetMessagePayload ¶

type StandalonePriceExternalDiscountSetMessagePayload struct {
	// The `discounted` value of the [StandalonePrice](ctp:api:type:StandalonePrice) after the [Set Discounted Price](ctp:api:type:StandalonePriceSetDiscountedPriceAction) update action.
	Discounted *DiscountedPrice `json:"discounted,omitempty"`
}

* * Generated after a successful [Set Discounted Price](ctp:api:type:StandalonePriceSetDiscountedPriceAction) update action. *

func (StandalonePriceExternalDiscountSetMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceKeySetMessage ¶

type StandalonePriceKeySetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// `key` value of the [StandalonePrice](ctp:api:type:StandalonePrice) after the [Set Key](ctp:api:type:StandalonePriceSetKeyAction) update action.
	Key *string `json:"key,omitempty"`
	// `key` value of the [StandalonePrice](ctp:api:type:StandalonePrice) before the [Set Key](ctp:api:type:StandalonePriceSetKeyAction) update action.
	OldKey *string `json:"oldKey,omitempty"`
}

* * Generated after a successful [Set Key](ctp:api:type:StandalonePriceSetKeyAction) update action. *

func (StandalonePriceKeySetMessage) MarshalJSON ¶

func (obj StandalonePriceKeySetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceKeySetMessage) UnmarshalJSON ¶

func (obj *StandalonePriceKeySetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceKeySetMessagePayload ¶

type StandalonePriceKeySetMessagePayload struct {
	// `key` value of the [StandalonePrice](ctp:api:type:StandalonePrice) after the [Set Key](ctp:api:type:StandalonePriceSetKeyAction) update action.
	Key *string `json:"key,omitempty"`
	// `key` value of the [StandalonePrice](ctp:api:type:StandalonePrice) before the [Set Key](ctp:api:type:StandalonePriceSetKeyAction) update action.
	OldKey *string `json:"oldKey,omitempty"`
}

* * Generated after a successful [Set Key](ctp:api:type:StandalonePriceSetKeyAction) update action. *

func (StandalonePriceKeySetMessagePayload) MarshalJSON ¶

func (obj StandalonePriceKeySetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePricePagedQueryResponse ¶

type StandalonePricePagedQueryResponse struct {
	// Number of requested results.
	Limit int `json:"limit"`
	// Offset supplied by the client or server default. It is the number of elements skipped, not a page number.
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [StandalonePrices](ctp:api:type:StandalonePrice) matching the query.
	Results []StandalonePrice `json:"results"`
}

type StandalonePriceReference ¶

type StandalonePriceReference struct {
	// Unique ID of the referenced resource.
	ID string `json:"id"`
	// Contains the representation of the expanded StandalonePrice. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for StandalonePrice.
	Obj *StandalonePrice `json:"obj,omitempty"`
}

* * Reference(/../api/types#reference) to a StandalonePrice(ctp:api:type:StandalonePrice). *

func (StandalonePriceReference) MarshalJSON ¶

func (obj StandalonePriceReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceRemovePriceTierAction ¶

type StandalonePriceRemovePriceTierAction struct {
	// The `minimumQuantity` of the [PriceTier](ctp:api:type:PriceTier) to be removed from the `tiers` field of the [StandalonePrice](ctp:api:type:StandalonePrice).
	TierMinimumQuantity int `json:"tierMinimumQuantity"`
}

* * Removing a PriceTier(ctp:api:type:PriceTier) from a StandalonePrice(ctp:api:type:StandalonePrice) produces the [Standalone Price Tier Removed](ctp:api:type:StandalonePriceTierRemovedMessage) Message. *

func (StandalonePriceRemovePriceTierAction) MarshalJSON ¶

func (obj StandalonePriceRemovePriceTierAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceResourceIdentifier ¶

type StandalonePriceResourceIdentifier struct {
	// Unique identifier of the referenced resource. Required if `key` is absent.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced resource. Required if `id` is absent.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(/../api/types#resourceidentifier) to a StandalonePrice(ctp:api:type:StandalonePrice). *

func (StandalonePriceResourceIdentifier) MarshalJSON ¶

func (obj StandalonePriceResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceSetCustomFieldAction ¶

type StandalonePriceSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StandalonePriceSetCustomFieldAction) MarshalJSON ¶

func (obj StandalonePriceSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceSetCustomTypeAction ¶

type StandalonePriceSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the StandalonePrice with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the StandalonePrice.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the StandalonePrice.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StandalonePriceSetCustomTypeAction) MarshalJSON ¶

func (obj StandalonePriceSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceSetDiscountedPriceAction ¶

type StandalonePriceSetDiscountedPriceAction struct {
	// Value to set. If empty, any existing value will be removed.
	Discounted *DiscountedPriceDraft `json:"discounted,omitempty"`
}

* * Discounts a Standalone Price. The referenced ProductDiscount(ctp:api:type:ProductDiscount) in the discounted field must be of type external, active, and its predicate must match the referenced Price. Produces the [StandalonePriceExternalDiscountSet](ctp:api:type:StandalonePriceExternalDiscountSetMessage) Message. *

func (StandalonePriceSetDiscountedPriceAction) MarshalJSON ¶

func (obj StandalonePriceSetDiscountedPriceAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceSetKeyAction ¶

type StandalonePriceSetKeyAction struct {
	// Value to set. Must be unique. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

* * Sets the key on a Standalone Price. Produces the [StandalonePriceKeySet](ctp:api:type:StandalonePriceKeySetMessage) Message. *

func (StandalonePriceSetKeyAction) MarshalJSON ¶

func (obj StandalonePriceSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceSetPriceTiersAction ¶

type StandalonePriceSetPriceTiersAction struct {
	// Value to set. If empty, any existing value will be removed.
	// The `minimumQuantity` of the PriceTiers must be unique and greater than `1`, otherwise an [InvalidField](ctp:api:type:InvalidFieldError) error is returned.
	Tiers []PriceTierDraft `json:"tiers"`
}

* * Sets all [PriceTiers](ctp:api:type:PriceTier) for a StandalonePrice(ctp:api:type:StandalonePrice) in one action, produces the [Standalone Price Tiers Set](ctp:api:type:StandalonePriceTiersSetMessage) Message. *

func (StandalonePriceSetPriceTiersAction) MarshalJSON ¶

func (obj StandalonePriceSetPriceTiersAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceSetValidFromAction ¶

type StandalonePriceSetValidFromAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
}

* * Updating the `validFrom` value generates the [StandalonePriceValidFromSet](ctp:api:type:StandalonePriceValidFromSetMessage) Message. * * As the validity dates are part of the price scope and are not allowed to overlap, this update might return the [DuplicateStandalonePriceScope](ctp:api:type:DuplicateStandalonePriceScopeError) and [OverlappingStandalonePriceValidity](ctp:api:type:OverlappingStandalonePriceValidityError) errors, respectively. A Price without validity period does not conflict with a Price defined for a time period. *

func (StandalonePriceSetValidFromAction) MarshalJSON ¶

func (obj StandalonePriceSetValidFromAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceSetValidFromAndUntilAction ¶

type StandalonePriceSetValidFromAndUntilAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Value to set.
	// If empty, any existing value is removed.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

* * Updating the `validFrom` and `validUntil` values generates the [StandalonePriceValidFromAndUntilSet](ctp:api:type:StandalonePriceValidFromAndUntilSetMessage) Message. * * As the validity dates are part of the price scope and are not allowed to overlap, this update might return the [DuplicateStandalonePriceScope](ctp:api:type:DuplicateStandalonePriceScopeError) and [OverlappingStandalonePriceValidity](ctp:api:type:OverlappingStandalonePriceValidityError) errors, respectively. A Price without validity period does not conflict with a Price defined for a time period. *

func (StandalonePriceSetValidFromAndUntilAction) MarshalJSON ¶

func (obj StandalonePriceSetValidFromAndUntilAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceSetValidUntilAction ¶

type StandalonePriceSetValidUntilAction struct {
	// Value to set.
	// If empty, any existing value is removed.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
}

* * Updating the `validUntil` value generates the [StandalonePriceValidUntilSet](ctp:api:type:StandalonePriceValidUntilSetMessage) Message. * * As the validity dates are part of the price scope and are not allowed to overlap, this update might return the [DuplicateStandalonePriceScope](ctp:api:type:DuplicateStandalonePriceScopeError) and [OverlappingStandalonePriceValidity](ctp:api:type:OverlappingStandalonePriceValidityError) errors, respectively. A Price without validity period does not conflict with a Price defined for a time period. *

func (StandalonePriceSetValidUntilAction) MarshalJSON ¶

func (obj StandalonePriceSetValidUntilAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceStagedChangesAppliedMessage ¶

type StandalonePriceStagedChangesAppliedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Applied changes of the [StandalonePrice](/../api/projects/standalone-prices) after the [Apply Staged Changes](ctp:api:types:StandalonePriceApplyStagedChangesAction) update action.
	StagedChanges StagedStandalonePrice `json:"stagedChanges"`
}

* * Generated after a successful [Apply Staged Changes](ctp:api:types:StandalonePriceApplyStagedChangesAction) update action. *

func (StandalonePriceStagedChangesAppliedMessage) MarshalJSON ¶

func (obj StandalonePriceStagedChangesAppliedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceStagedChangesAppliedMessage) UnmarshalJSON ¶

func (obj *StandalonePriceStagedChangesAppliedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceStagedChangesAppliedMessagePayload ¶

type StandalonePriceStagedChangesAppliedMessagePayload struct {
	// Applied changes of the [StandalonePrice](/../api/projects/standalone-prices) after the [Apply Staged Changes](ctp:api:types:StandalonePriceApplyStagedChangesAction) update action.
	StagedChanges StagedStandalonePrice `json:"stagedChanges"`
}

* * Generated after a successful [Apply Staged Changes](ctp:api:types:StandalonePriceApplyStagedChangesAction) update action. *

func (StandalonePriceStagedChangesAppliedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceTierAddedMessage ¶

type StandalonePriceTierAddedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [Price Tier](ctp:api:type:PriceTier) that has been added to the array field `tiers` for the [StandalonePrice](ctp:api:type:StandalonePrice).
	Tier PriceTier `json:"tier"`
}

* * Generated after a successful [Add Price Tier](ctp:api:type:StandalonePriceAddPriceTierAction) update action *

func (StandalonePriceTierAddedMessage) MarshalJSON ¶

func (obj StandalonePriceTierAddedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceTierAddedMessage) UnmarshalJSON ¶

func (obj *StandalonePriceTierAddedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceTierAddedMessagePayload ¶

type StandalonePriceTierAddedMessagePayload struct {
	// The [Price Tier](ctp:api:type:PriceTier) that has been added to the array field `tiers` for the [StandalonePrice](ctp:api:type:StandalonePrice).
	Tier PriceTier `json:"tier"`
}

* * Generated after a successful [Add Price Tier](ctp:api:type:StandalonePriceAddPriceTierAction) update action *

func (StandalonePriceTierAddedMessagePayload) MarshalJSON ¶

func (obj StandalonePriceTierAddedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceTierRemovedMessage ¶

type StandalonePriceTierRemovedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The [Price Tier](ctp:api:type:PriceTier) that has been removed from the array field `tiers` for the [StandalonePrice](ctp:api:type:StandalonePrice).
	RemovedTier PriceTier `json:"removedTier"`
}

* * Generated after a successful [Remove Price Tier](ctp:api:type:StandalonePriceRemovePriceTierAction) update action *

func (StandalonePriceTierRemovedMessage) MarshalJSON ¶

func (obj StandalonePriceTierRemovedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceTierRemovedMessage) UnmarshalJSON ¶

func (obj *StandalonePriceTierRemovedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceTierRemovedMessagePayload ¶

type StandalonePriceTierRemovedMessagePayload struct {
	// The [Price Tier](ctp:api:type:PriceTier) that has been removed from the array field `tiers` for the [StandalonePrice](ctp:api:type:StandalonePrice).
	RemovedTier PriceTier `json:"removedTier"`
}

* * Generated after a successful [Remove Price Tier](ctp:api:type:StandalonePriceRemovePriceTierAction) update action *

func (StandalonePriceTierRemovedMessagePayload) MarshalJSON ¶

func (obj StandalonePriceTierRemovedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceTiersSetMessage ¶

type StandalonePriceTiersSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The updated content of the field `tiers` of the affected [StandalonePrice](ctp:api:type:StandalonePrice).
	Tiers []PriceTier `json:"tiers"`
	// The previous content of the field `tiers` of the affected [StandalonePrice](ctp:api:type:StandalonePrice).
	PreviousTiers []PriceTier `json:"previousTiers"`
}

* * Generated after a successful [Set Price Tier](ctp:api:type:StandalonePriceSetPriceTiersAction) update action *

func (StandalonePriceTiersSetMessage) MarshalJSON ¶

func (obj StandalonePriceTiersSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceTiersSetMessage) UnmarshalJSON ¶

func (obj *StandalonePriceTiersSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceTiersSetMessagePayload ¶

type StandalonePriceTiersSetMessagePayload struct {
	// The updated content of the field `tiers` of the affected [StandalonePrice](ctp:api:type:StandalonePrice).
	Tiers []PriceTier `json:"tiers"`
	// The previous content of the field `tiers` of the affected [StandalonePrice](ctp:api:type:StandalonePrice).
	PreviousTiers []PriceTier `json:"previousTiers"`
}

* * Generated after a successful [Set Price Tier](ctp:api:type:StandalonePriceSetPriceTiersAction) update action *

func (StandalonePriceTiersSetMessagePayload) MarshalJSON ¶

func (obj StandalonePriceTiersSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceUpdate ¶

type StandalonePriceUpdate struct {
	// Expected version of the StandalonePrice on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the StandalonePrice.
	Actions []StandalonePriceUpdateAction `json:"actions"`
}

func (*StandalonePriceUpdate) UnmarshalJSON ¶

func (obj *StandalonePriceUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceUpdateAction ¶

type StandalonePriceUpdateAction interface{}

type StandalonePriceValidFromAndUntilSetMessage ¶

type StandalonePriceValidFromAndUntilSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validFrom` after the [Set Valid From and Until](ctp:api:type:StandalonePriceSetValidFromAndUntilAction) update action.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validFrom` before the [Set Valid From and Until](ctp:api:type:StandalonePriceSetValidFromAndUntilAction) update action.
	PreviousValidFrom *time.Time `json:"previousValidFrom,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validUntil` after the [Set Valid From and Until](ctp:api:type:StandalonePriceSetValidFromAndUntilAction) update action.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validUntil` before the [Set Valid From and Until](ctp:api:type:StandalonePriceSetValidFromAndUntilAction) update action.
	PreviousValidUntil *time.Time `json:"previousValidUntil,omitempty"`
}

* * Generated after a successful [Set Valid From and Until](ctp:api:type:StandalonePriceSetValidFromAndUntilAction) update action. *

func (StandalonePriceValidFromAndUntilSetMessage) MarshalJSON ¶

func (obj StandalonePriceValidFromAndUntilSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceValidFromAndUntilSetMessage) UnmarshalJSON ¶

func (obj *StandalonePriceValidFromAndUntilSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceValidFromAndUntilSetMessagePayload ¶

type StandalonePriceValidFromAndUntilSetMessagePayload struct {
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validFrom` after the [Set Valid From and Until](ctp:api:type:StandalonePriceSetValidFromAndUntilAction) update action.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validFrom` before the [Set Valid From and Until](ctp:api:type:StandalonePriceSetValidFromAndUntilAction) update action.
	PreviousValidFrom *time.Time `json:"previousValidFrom,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validUntil` after the [Set Valid From and Until](ctp:api:type:StandalonePriceSetValidFromAndUntilAction) update action.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validUntil` before the [Set Valid From and Until](ctp:api:type:StandalonePriceSetValidFromAndUntilAction) update action.
	PreviousValidUntil *time.Time `json:"previousValidUntil,omitempty"`
}

* * Generated after a successful [Set Valid From and Until](ctp:api:type:StandalonePriceSetValidFromAndUntilAction) update action. *

func (StandalonePriceValidFromAndUntilSetMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceValidFromSetMessage ¶

type StandalonePriceValidFromSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validFrom` after the [Set Valid From](ctp:api:type:StandalonePriceSetValidFromAction) update action.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validFrom` before the [Set Valid From](ctp:api:type:StandalonePriceSetValidFromAction) update action.
	PreviousValidFrom *time.Time `json:"previousValidFrom,omitempty"`
}

* * Generated after a successful [Set Valid From](ctp:api:type:StandalonePriceSetValidFromAction) update action. *

func (StandalonePriceValidFromSetMessage) MarshalJSON ¶

func (obj StandalonePriceValidFromSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceValidFromSetMessage) UnmarshalJSON ¶

func (obj *StandalonePriceValidFromSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceValidFromSetMessagePayload ¶

type StandalonePriceValidFromSetMessagePayload struct {
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validFrom` after the [Set Valid From](ctp:api:type:StandalonePriceSetValidFromAction) update action.
	ValidFrom *time.Time `json:"validFrom,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validFrom` before the [Set Valid From](ctp:api:type:StandalonePriceSetValidFromAction) update action.
	PreviousValidFrom *time.Time `json:"previousValidFrom,omitempty"`
}

* * Generated after a successful [Set Valid From](ctp:api:type:StandalonePriceSetValidFromAction) update action. *

func (StandalonePriceValidFromSetMessagePayload) MarshalJSON ¶

func (obj StandalonePriceValidFromSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceValidUntilSetMessage ¶

type StandalonePriceValidUntilSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validUntil` after the [Set Valid Until](ctp:api:type:StandalonePriceSetValidUntilAction) update action.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validUntil` before the [Set Valid Until](ctp:api:type:StandalonePriceSetValidUntilAction) update action.
	PreviousValidUntil *time.Time `json:"previousValidUntil,omitempty"`
}

* * Generated after a successful [Set Valid Until](ctp:api:type:StandalonePriceSetValidUntilAction) update action. *

func (StandalonePriceValidUntilSetMessage) MarshalJSON ¶

func (obj StandalonePriceValidUntilSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceValidUntilSetMessage) UnmarshalJSON ¶

func (obj *StandalonePriceValidUntilSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceValidUntilSetMessagePayload ¶

type StandalonePriceValidUntilSetMessagePayload struct {
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validUntil` after the [Set Valid Until](ctp:api:type:StandalonePriceSetValidUntilAction) update action.
	ValidUntil *time.Time `json:"validUntil,omitempty"`
	// Value of [StandalonePrice](ctp:api:type:StandalonePrice) `validUntil` before the [Set Valid Until](ctp:api:type:StandalonePriceSetValidUntilAction) update action.
	PreviousValidUntil *time.Time `json:"previousValidUntil,omitempty"`
}

* * Generated after a successful [Set Valid Until](ctp:api:type:StandalonePriceSetValidUntilAction) update action. *

func (StandalonePriceValidUntilSetMessagePayload) MarshalJSON ¶

func (obj StandalonePriceValidUntilSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StandalonePriceValueChangedMessage ¶

type StandalonePriceValueChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The new value of the updated [StandalonePrice](ctp:api:type:StandalonePrice).
	Value Money `json:"value"`
	// Whether the new value was applied to the current or the staged representation of the StandalonePrice. Staged changes are stored on the [StagedStandalonePrice](ctp:api:type:StagedStandalonePrice).
	Staged bool `json:"staged"`
	// The old value of the updated [StandalonePrice](ctp:api:type:StandalonePrice).
	// Present on Messages created after 3 February 2023. Optional for backwards compatibility.
	OldValue *Money `json:"oldValue,omitempty"`
}

* * Generated after a successful [Change Value](ctp:api:type:StandalonePriceChangeValueAction) update action. *

func (StandalonePriceValueChangedMessage) MarshalJSON ¶

func (obj StandalonePriceValueChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StandalonePriceValueChangedMessage) UnmarshalJSON ¶

func (obj *StandalonePriceValueChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StandalonePriceValueChangedMessagePayload ¶

type StandalonePriceValueChangedMessagePayload struct {
	// The new value of the updated [StandalonePrice](ctp:api:type:StandalonePrice).
	Value Money `json:"value"`
	// Whether the new value was applied to the current or the staged representation of the StandalonePrice. Staged changes are stored on the [StagedStandalonePrice](ctp:api:type:StagedStandalonePrice).
	Staged bool `json:"staged"`
	// The old value of the updated [StandalonePrice](ctp:api:type:StandalonePrice).
	// Present on Messages created after 3 February 2023. Optional for backwards compatibility.
	OldValue *Money `json:"oldValue,omitempty"`
}

* * Generated after a successful [Change Value](ctp:api:type:StandalonePriceChangeValueAction) update action. *

func (StandalonePriceValueChangedMessagePayload) MarshalJSON ¶

func (obj StandalonePriceValueChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type State ¶

type State struct {
	// Unique identifier of the State.
	ID string `json:"id"`
	// Current version of the State.
	Version int `json:"version"`
	// Date and time (UTC) the State was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the State was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the State.
	Key string `json:"key"`
	// Indicates to which resource or object types the State is assigned to.
	Type StateTypeEnum `json:"type"`
	// Name of the State.
	Name *LocalizedString `json:"name,omitempty"`
	// Description of the State.
	Description *LocalizedString `json:"description,omitempty"`
	// `true` for an initial State, the first State in a workflow.
	Initial bool `json:"initial"`
	// `true` for States that are an integral part of the [Project](ctp:api:type:Project). Those States cannot be deleted and their `key` cannot be changed.
	BuiltIn bool `json:"builtIn"`
	// Roles the State can fulfill for [Reviews](ctp:api:type:Review) and [Line Items](ctp:api:type:LineItem).
	Roles []StateRoleEnum `json:"roles"`
	// - list of States of the same `type` that the current State can be transitioned to. For example, when the current State is the _Initial_ State of [StateType](ctp:api:type:StateTypeEnum) `OrderState` and this list contains the reference to the _Shipped_ `OrderState`, the transition _Initial_ -> _Shipped_ is allowed.
	// - if empty, no transitions are allowed from the current State, defining the current State as final for this workflow.
	// - if not set, the validation is turned off and the current State can be transitioned to any other State of the same `type` as the current State.
	Transitions []StateReference `json:"transitions"`
}

func (State) MarshalJSON ¶

func (obj State) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateAddRolesAction ¶

type StateAddRolesAction struct {
	// Value to append to the array.
	Roles []StateRoleEnum `json:"roles"`
}

func (StateAddRolesAction) MarshalJSON ¶

func (obj StateAddRolesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateChangeInitialAction ¶

type StateChangeInitialAction struct {
	// Set to `true` for defining the State as initial State in a state machine and making it the first step in a workflow.
	Initial bool `json:"initial"`
}

func (StateChangeInitialAction) MarshalJSON ¶

func (obj StateChangeInitialAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateChangeKeyAction ¶

type StateChangeKeyAction struct {
	// New value to set.
	// Must not be empty.
	Key string `json:"key"`
}

func (StateChangeKeyAction) MarshalJSON ¶

func (obj StateChangeKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateChangeTypeAction ¶

type StateChangeTypeAction struct {
	// Resource or object types the State shall be assigned to.
	// Must not be empty.
	Type StateTypeEnum `json:"type"`
}

func (StateChangeTypeAction) MarshalJSON ¶

func (obj StateChangeTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateDraft ¶

type StateDraft struct {
	// User-defined unique identifier for the State.
	Key string `json:"key"`
	// Specify to which resource or object type the State is assigned to.
	Type StateTypeEnum `json:"type"`
	// Name of the State.
	Name *LocalizedString `json:"name,omitempty"`
	// Description of the State.
	Description *LocalizedString `json:"description,omitempty"`
	// Set to `false` if the State is not the first step in a workflow.
	Initial *bool `json:"initial,omitempty"`
	// If suitable, assign predifined roles the State can fulfill in case the State's `type` is `LineItemState` or `ReviewState`.
	Roles []StateRoleEnum `json:"roles"`
	// Define the list of States of the same `type` to which the current State can be transitioned to.
	//
	// - If, for example, the current State is the _Initial_ State of [StateType](ctp:api:type:StateTypeEnum) `OrderState` and you want to allow the transition _Initial_ -> _Shipped_, then add the [StateResourceIdentifier](ctp:api:type:StateResourceIdentifier) to the _Shipped_ `OrderState` to this list.
	// - Set to empty list for not allowing any transition from the current State and defining it as final State for a workflow.
	// - Do not set this field at all to turn off validation and allowing transitions to any other State of the same `type` as the current State.
	Transitions []StateResourceIdentifier `json:"transitions"`
}

func (StateDraft) MarshalJSON ¶

func (obj StateDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StatePagedQueryResponse ¶

type StatePagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [States](ctp:api:type:State) matching the query.
	Results []State `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of State(ctp:api:type:State). *

type StateReference ¶

type StateReference struct {
	// Unique identifier of the referenced [State](ctp:api:type:State).
	ID string `json:"id"`
	// Contains the representation of the expanded State. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for States.
	Obj *State `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a State(ctp:api:type:State). *

func (StateReference) MarshalJSON ¶

func (obj StateReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateRemoveRolesAction ¶

type StateRemoveRolesAction struct {
	// Roles to remove from the State.
	Roles []StateRoleEnum `json:"roles"`
}

func (StateRemoveRolesAction) MarshalJSON ¶

func (obj StateRemoveRolesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateResourceIdentifier ¶

type StateResourceIdentifier struct {
	// Unique identifier of the referenced [State](ctp:api:type:State). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [State](ctp:api:type:State). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a State(ctp:api:type:State). *

func (StateResourceIdentifier) MarshalJSON ¶

func (obj StateResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateRoleEnum ¶

type StateRoleEnum string

* * For some resource types, a State can fulfill the following predefined roles: *

const (
	StateRoleEnumReviewIncludedInStatistics StateRoleEnum = "ReviewIncludedInStatistics"
	StateRoleEnumReturn                     StateRoleEnum = "Return"
)

type StateSetDescriptionAction ¶

type StateSetDescriptionAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	Description LocalizedString `json:"description"`
}

func (StateSetDescriptionAction) MarshalJSON ¶

func (obj StateSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateSetNameAction ¶

type StateSetNameAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	Name LocalizedString `json:"name"`
}

func (StateSetNameAction) MarshalJSON ¶

func (obj StateSetNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateSetRolesAction ¶

type StateSetRolesAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	Roles []StateRoleEnum `json:"roles"`
}

func (StateSetRolesAction) MarshalJSON ¶

func (obj StateSetRolesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateSetTransitionsAction ¶

type StateSetTransitionsAction struct {
	// Value to set.
	// If empty, any existing value will be removed.
	//
	// Possible transformations of the current State to other States of the same `type` (for example, _Initial_ -> _Shipped_).
	// When performing a `transitionState` update action and `transitions` is set, the currently referenced State must have a transition to the new State.
	//
	// If `transitions` is an empty list, it means the current State is a final State and no further transitions are allowed.
	// If `transitions` is not set, the validation is turned off.
	//
	// When performing a `transitionState` update action, any other State of the same `type` can be transitioned to.
	Transitions []StateResourceIdentifier `json:"transitions"`
}

func (StateSetTransitionsAction) MarshalJSON ¶

func (obj StateSetTransitionsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StateTypeEnum ¶

type StateTypeEnum string

* * Resource or object type the State can be assigned to. *

const (
	StateTypeEnumOrderState        StateTypeEnum = "OrderState"
	StateTypeEnumLineItemState     StateTypeEnum = "LineItemState"
	StateTypeEnumProductState      StateTypeEnum = "ProductState"
	StateTypeEnumReviewState       StateTypeEnum = "ReviewState"
	StateTypeEnumPaymentState      StateTypeEnum = "PaymentState"
	StateTypeEnumQuoteRequestState StateTypeEnum = "QuoteRequestState"
	StateTypeEnumStagedQuoteState  StateTypeEnum = "StagedQuoteState"
	StateTypeEnumQuoteState        StateTypeEnum = "QuoteState"
)

type StateUpdate ¶

type StateUpdate struct {
	// Expected version of the State on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the State.
	Actions []StateUpdateAction `json:"actions"`
}

func (*StateUpdate) UnmarshalJSON ¶

func (obj *StateUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StateUpdateAction ¶

type StateUpdateAction interface{}

type Store ¶

type Store struct {
	// Unique ID of the Store.
	ID string `json:"id"`
	// Current version of the Store.
	Version int `json:"version"`
	// Date and time (UTC) the Store was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Store was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique and immutable identifier for the Store.
	Key string `json:"key"`
	// Name of the Store.
	Name *LocalizedString `json:"name,omitempty"`
	// Languages configured for the Store.
	Languages []string `json:"languages"`
	// Countries defined for the Store.
	Countries []StoreCountry `json:"countries"`
	// Product Distribution Channels allowed for the Store.
	DistributionChannels []ChannelReference `json:"distributionChannels"`
	// Inventory Supply Channels allowed for the Store.
	SupplyChannels []ChannelReference `json:"supplyChannels"`
	// Controls availability of Products for this Store via Product Selections:
	//
	// - Leave empty if all Products in the [Project](ctp:api:type:Project) should be available in this Store.
	// - If only `inactive` Product Selections with `IndividualExclusion` [ProductSelectionMode](ctp:api:type:ProductSelectionMode) are provided, all the Products are availlable in this Store.
	// - If all the Product Selections provided are `inactive` and there's at least a Product Selection of mode `Individual`, no Product is availlable in this Store.
	// - If at least an `active` Product Selection is provided, only `active` Product Selections are considered to compute the availlability in this Store.
	ProductSelections []ProductSelectionSetting `json:"productSelections"`
	// Custom fields for the Store.
	Custom *CustomFields `json:"custom,omitempty"`
}

type StoreAddCountryAction ¶

type StoreAddCountryAction struct {
	// Value to append to `countries`.
	Country StoreCountry `json:"country"`
}

* * This update action produces the [StoreCountriesChanged](ctp:api:type:StoreCountriesChangedMessage) Message. * It has no effect if the given country is already present in a Store. *

func (StoreAddCountryAction) MarshalJSON ¶

func (obj StoreAddCountryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreAddDistributionChannelAction ¶

type StoreAddDistributionChannelAction struct {
	// Value to append.
	DistributionChannel ChannelResourceIdentifier `json:"distributionChannel"`
}

* * This update action produces the [StoreDistributionChannelsChanged](ctp:api:type:StoreDistributionChannelsChangedMessage) Message. * It has no effect if a given distribution channel is already present in a Store. * * Adding a Channel(ctp:api:type:Channel) without the `ProductDistribution` ChannelRoleEnum(ctp:api:type:ChannelRoleEnum) returns a [MissingRoleOnChannel](ctp:api:type:MissingRoleOnChannelError) error. *

func (StoreAddDistributionChannelAction) MarshalJSON ¶

func (obj StoreAddDistributionChannelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreAddProductSelectionAction ¶

type StoreAddProductSelectionAction struct {
	// Product Selection to add to the Store either activated or deactivated.
	ProductSelection ProductSelectionResourceIdentifier `json:"productSelection"`
	// Set to `true` to make all Products assigned to the referenced Product Selection available in the Store.
	Active *bool `json:"active,omitempty"`
}

* * To make all included Products available to your customers of a given Store, add the [Product Selections](/../api/projects/product-selections) to the respective Store. This action has no effect if the given Product Selection is already present in the Store and has the same `active` flag. *

func (StoreAddProductSelectionAction) MarshalJSON ¶

func (obj StoreAddProductSelectionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreAddSupplyChannelAction ¶

type StoreAddSupplyChannelAction struct {
	// Value to append.
	SupplyChannel ChannelResourceIdentifier `json:"supplyChannel"`
}

* * This action has no effect if a given supply channel is already present in a Store. * * Adding a supply channel produces the [StoreSupplyChannelsChanged](ctp:api:type:StoreSupplyChannelsChangedMessage) Message. * * Adding a Channel(ctp:api:type:Channel) without the `InventorySupply` ChannelRoleEnum(ctp:api:type:ChannelRoleEnum) returns a [MissingRoleOnChannel](ctp:api:type:MissingRoleOnChannelError) error. *

func (StoreAddSupplyChannelAction) MarshalJSON ¶

func (obj StoreAddSupplyChannelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreChangeProductSelectionAction ¶

type StoreChangeProductSelectionAction struct {
	// Current Product Selection of the Store to be activated or deactivated.
	ProductSelection ProductSelectionResourceIdentifier `json:"productSelection"`
	// Set to `true` if all Products assigned to the Product Selection should become part of the Store's assortment.
	Active *bool `json:"active,omitempty"`
}

* * ProductSelection(ctp:api:type:ProductSelection) in a Store can be activated or deactivated using this update action. *

func (StoreChangeProductSelectionAction) MarshalJSON ¶

func (obj StoreChangeProductSelectionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreCountriesChangedMessage ¶

type StoreCountriesChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Countries](ctp:api:type:StoreCountry) added to the [Store](ctp:api:type:Store).
	AddedCountries []StoreCountry `json:"addedCountries"`
	// [Countries](ctp:api:type:StoreCountry) removed from the [Store](ctp:api:type:Store).
	RemovedCountries []StoreCountry `json:"removedCountries"`
}

* * Generated after a successful [Add Country](ctp:api:type:StoreAddCountryAction), * [Remove Country](ctp:api:type:StoreRemoveCountryAction), or * [Set Countries](ctp:api:type:StoreSetCountriesAction) update action. *

func (StoreCountriesChangedMessage) MarshalJSON ¶

func (obj StoreCountriesChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StoreCountriesChangedMessage) UnmarshalJSON ¶

func (obj *StoreCountriesChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StoreCountriesChangedMessagePayload ¶

type StoreCountriesChangedMessagePayload struct {
	// [Countries](ctp:api:type:StoreCountry) added to the [Store](ctp:api:type:Store).
	AddedCountries []StoreCountry `json:"addedCountries"`
	// [Countries](ctp:api:type:StoreCountry) removed from the [Store](ctp:api:type:Store).
	RemovedCountries []StoreCountry `json:"removedCountries"`
}

* * Generated after a successful [Add Country](ctp:api:type:StoreAddCountryAction), * [Remove Country](ctp:api:type:StoreRemoveCountryAction), or * [Set Countries](ctp:api:type:StoreSetCountriesAction) update action. *

func (StoreCountriesChangedMessagePayload) MarshalJSON ¶

func (obj StoreCountriesChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreCountry ¶

type StoreCountry struct {
	// Two-digit country code as per [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).
	Code string `json:"code"`
}

type StoreCreatedMessage ¶

type StoreCreatedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// The `name` of the [Store](ctp:api:type:Store) that was created.
	Name *LocalizedString `json:"name,omitempty"`
	// Languages of the [Store](ctp:api:type:Store) that was created. Languages are represented as [IETF language tags](https://en.wikipedia.org/wiki/IETF_language_tag).
	Languages []string `json:"languages"`
	// [Countries](ctp:api:type:StoreCountry) of the [Store](ctp:api:type:Store) that was created.
	Countries []StoreCountry `json:"countries"`
	// [Distribution Channels](ctp:api:type:ChannelRoleEnum) of the [Store](ctp:api:type:Store) that was created.
	DistributionChannels []ChannelReference `json:"distributionChannels"`
	// [Supply Channels](ctp:api:type:ChannelRoleEnum) of the [Store](ctp:api:type:Store) that was created.
	SupplyChannels []ChannelReference `json:"supplyChannels"`
	// [ProductSelectionSettings](ctp:api:type:ProductSelectionSetting) of the [Store](ctp:api:type:Store) that was created.
	ProductSelections []ProductSelectionSetting `json:"productSelections"`
	// [Custom Fields](ctp:api:type:CustomFields) on the [Store](ctp:api:type:Store) that was created.
	Custom *CustomFields `json:"custom,omitempty"`
}

* * Generated after a successful [Create Store](/../api/projects/stores#create-store) request. *

func (StoreCreatedMessage) MarshalJSON ¶

func (obj StoreCreatedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StoreCreatedMessage) UnmarshalJSON ¶

func (obj *StoreCreatedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StoreCreatedMessagePayload ¶

type StoreCreatedMessagePayload struct {
	// The `name` of the [Store](ctp:api:type:Store) that was created.
	Name *LocalizedString `json:"name,omitempty"`
	// Languages of the [Store](ctp:api:type:Store) that was created. Languages are represented as [IETF language tags](https://en.wikipedia.org/wiki/IETF_language_tag).
	Languages []string `json:"languages"`
	// [Countries](ctp:api:type:StoreCountry) of the [Store](ctp:api:type:Store) that was created.
	Countries []StoreCountry `json:"countries"`
	// [Distribution Channels](ctp:api:type:ChannelRoleEnum) of the [Store](ctp:api:type:Store) that was created.
	DistributionChannels []ChannelReference `json:"distributionChannels"`
	// [Supply Channels](ctp:api:type:ChannelRoleEnum) of the [Store](ctp:api:type:Store) that was created.
	SupplyChannels []ChannelReference `json:"supplyChannels"`
	// [ProductSelectionSettings](ctp:api:type:ProductSelectionSetting) of the [Store](ctp:api:type:Store) that was created.
	ProductSelections []ProductSelectionSetting `json:"productSelections"`
	// [Custom Fields](ctp:api:type:CustomFields) on the [Store](ctp:api:type:Store) that was created.
	Custom *CustomFields `json:"custom,omitempty"`
}

* * Generated after a successful [Create Store](/../api/projects/stores#create-store) request. *

func (StoreCreatedMessagePayload) MarshalJSON ¶

func (obj StoreCreatedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreDeletedMessage ¶

type StoreDeletedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
}

* * Generated after a successful [Delete Store](/../api/projects/quote-requests#delete-quoterequest) request. *

func (StoreDeletedMessage) MarshalJSON ¶

func (obj StoreDeletedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StoreDeletedMessage) UnmarshalJSON ¶

func (obj *StoreDeletedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StoreDeletedMessagePayload ¶

type StoreDeletedMessagePayload struct {
}

* * Generated after a successful [Delete Store](/../api/projects/quote-requests#delete-quoterequest) request. *

func (StoreDeletedMessagePayload) MarshalJSON ¶

func (obj StoreDeletedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreDistributionChannelsChangedMessage ¶

type StoreDistributionChannelsChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Product distribution Channels that have been added to the [Store](ctp:api:type:Store).
	AddedDistributionChannels []ChannelReference `json:"addedDistributionChannels"`
	// Product distribution Channels that have been removed from the [Store](ctp:api:type:Store).
	RemovedDistributionChannels []ChannelReference `json:"removedDistributionChannels"`
}

* * Generated after a successful [Add Distribution Channel](ctp:api:type:StoreAddDistributionChannelAction), * [Remove Distribution Channel](ctp:api:type:StoreRemoveDistributionChannelAction), or * [Set Distribution Channels](ctp:api:type:StoreSetDistributionChannelsAction) update action. *

func (StoreDistributionChannelsChangedMessage) MarshalJSON ¶

func (obj StoreDistributionChannelsChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StoreDistributionChannelsChangedMessage) UnmarshalJSON ¶

func (obj *StoreDistributionChannelsChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StoreDistributionChannelsChangedMessagePayload ¶

type StoreDistributionChannelsChangedMessagePayload struct {
	// Product distribution Channels that have been added to the [Store](ctp:api:type:Store).
	AddedDistributionChannels []ChannelReference `json:"addedDistributionChannels"`
	// Product distribution Channels that have been removed from the [Store](ctp:api:type:Store).
	RemovedDistributionChannels []ChannelReference `json:"removedDistributionChannels"`
}

* * Generated after a successful [Add Distribution Channel](ctp:api:type:StoreAddDistributionChannelAction), * [Remove Distribution Channel](ctp:api:type:StoreRemoveDistributionChannelAction), or * [Set Distribution Channels](ctp:api:type:StoreSetDistributionChannelsAction) update action. *

func (StoreDistributionChannelsChangedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreDraft ¶

type StoreDraft struct {
	// User-defined unique and immutable identifier for the Store.
	// Keys can only contain alphanumeric characters, underscores, and hyphens.
	Key string `json:"key"`
	// Name of the Store.
	Name *LocalizedString `json:"name,omitempty"`
	// Languages defined in [Project](ctp:api:type:Project). Only languages defined in the Project can be used.
	Languages []string `json:"languages"`
	// Countries defined for the Store.
	Countries []StoreCountry `json:"countries"`
	// ResourceIdentifier of a Channel with `ProductDistribution` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	DistributionChannels []ChannelResourceIdentifier `json:"distributionChannels"`
	// ResourceIdentifier of a Channel with `InventorySupply` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	SupplyChannels []ChannelResourceIdentifier `json:"supplyChannels"`
	// Controls availability of Products for this Store via active/inactive Product Selections:
	//
	// - Leave empty if all Products in the [Project](ctp:api:type:Project) should be available in this Store.
	// - If only `inactive` Product Selections with `IndividualExclusion` [ProductSelectionMode](ctp:api:type:ProductSelectionMode) are provided, all the Products are available in this Store.
	// - If all the Product Selections provided are `inactive` and there's at least a Product Selection of mode `Individual`, no Product is available in this Store.
	// - If at least an `active` Product Selection is provided, only `active` Product Selections are considered to compute the availability in this Store.
	ProductSelections []ProductSelectionSettingDraft `json:"productSelections"`
	// Custom fields for the Store.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

func (StoreDraft) MarshalJSON ¶

func (obj StoreDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreKeyReference ¶

type StoreKeyReference struct {
	// Unique and immutable key of the referenced [Store](ctp:api:type:Store).
	Key string `json:"key"`
}

* * Reference(/../api/types#reference) to a Store(ctp:api:type:Store) by its key. *

func (StoreKeyReference) MarshalJSON ¶

func (obj StoreKeyReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreLanguagesChangedMessage ¶

type StoreLanguagesChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [Locales](ctp:api:type:Locale) added to the [Store](ctp:api:type:Store) after the [Set Languages](ctp:api:type:StoreSetLanguagesAction) update action.
	AddedLanguages []string `json:"addedLanguages"`
	// [Locales](ctp:api:type:Locale) removed from the [Store](ctp:api:type:Store) during the [Set Languages](ctp:api:type:StoreSetLanguagesAction) update action.
	RemovedLanguages []string `json:"removedLanguages"`
}

* * Generated after a successful [Set Languages](ctp:api:type:StoreSetLanguagesAction) update action. *

func (StoreLanguagesChangedMessage) MarshalJSON ¶

func (obj StoreLanguagesChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StoreLanguagesChangedMessage) UnmarshalJSON ¶

func (obj *StoreLanguagesChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StoreLanguagesChangedMessagePayload ¶

type StoreLanguagesChangedMessagePayload struct {
	// [Locales](ctp:api:type:Locale) added to the [Store](ctp:api:type:Store) after the [Set Languages](ctp:api:type:StoreSetLanguagesAction) update action.
	AddedLanguages []string `json:"addedLanguages"`
	// [Locales](ctp:api:type:Locale) removed from the [Store](ctp:api:type:Store) during the [Set Languages](ctp:api:type:StoreSetLanguagesAction) update action.
	RemovedLanguages []string `json:"removedLanguages"`
}

* * Generated after a successful [Set Languages](ctp:api:type:StoreSetLanguagesAction) update action. *

func (StoreLanguagesChangedMessagePayload) MarshalJSON ¶

func (obj StoreLanguagesChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreNameSetMessage ¶

type StoreNameSetMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Name of the [Store](ctp:api:type:Store) set during the [Set Name](ctp:api:type:StoreSetNameAction) update action.
	Name *LocalizedString `json:"name,omitempty"`
	// Names set for the [Store](ctp:api:type:Store) in different locales.
	NameAllLocales []LocalizedString `json:"nameAllLocales"`
}

* * Generated after a successful [Set Name](ctp:api:type:StoreSetNameAction) update action. *

func (StoreNameSetMessage) MarshalJSON ¶

func (obj StoreNameSetMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StoreNameSetMessage) UnmarshalJSON ¶

func (obj *StoreNameSetMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StoreNameSetMessagePayload ¶

type StoreNameSetMessagePayload struct {
	// Name of the [Store](ctp:api:type:Store) set during the [Set Name](ctp:api:type:StoreSetNameAction) update action.
	Name *LocalizedString `json:"name,omitempty"`
	// Names set for the [Store](ctp:api:type:Store) in different locales.
	NameAllLocales []LocalizedString `json:"nameAllLocales"`
}

* * Generated after a successful [Set Name](ctp:api:type:StoreSetNameAction) update action. *

func (StoreNameSetMessagePayload) MarshalJSON ¶

func (obj StoreNameSetMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StorePagedQueryResponse ¶

type StorePagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [Stores](ctp:api:type:Store) matching the query.
	Results []Store `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of Store(ctp:api:type:Store). *

type StoreProductSelectionsChangedMessage ¶

type StoreProductSelectionsChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// [ProductSelectionSettings](ctp:api:type:ProductSelectionSetting) that were added to the [Store](ctp:api:type:Store).
	AddedProductSelections []ProductSelectionSetting `json:"addedProductSelections"`
	// [ProductSelectionSettings](ctp:api:type:ProductSelectionSetting) that were removed from the [Store](ctp:api:type:Store).
	RemovedProductSelections []ProductSelectionSetting `json:"removedProductSelections"`
	// [ProductSelectionSettings](ctp:api:type:ProductSelectionSetting) that were updated in the [Store](ctp:api:type:Store).
	UpdatedProductSelections []ProductSelectionSetting `json:"updatedProductSelections"`
}

* * Generated by a successful [Add Product Selection](ctp:api:type:StoreAddProductSelectionAction), * [Remove Product Selection](ctp:api:type:StoreRemoveProductSelectionAction), * [Set Product Selections](ctp:api:type:StoreSetProductSelectionsAction), * or [Change Product Selections Active](ctp:api:type:StoreChangeProductSelectionAction) update action. *

func (StoreProductSelectionsChangedMessage) MarshalJSON ¶

func (obj StoreProductSelectionsChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StoreProductSelectionsChangedMessage) UnmarshalJSON ¶

func (obj *StoreProductSelectionsChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StoreProductSelectionsChangedMessagePayload ¶

type StoreProductSelectionsChangedMessagePayload struct {
	// [ProductSelectionSettings](ctp:api:type:ProductSelectionSetting) that were added to the [Store](ctp:api:type:Store).
	AddedProductSelections []ProductSelectionSetting `json:"addedProductSelections"`
	// [ProductSelectionSettings](ctp:api:type:ProductSelectionSetting) that were removed from the [Store](ctp:api:type:Store).
	RemovedProductSelections []ProductSelectionSetting `json:"removedProductSelections"`
	// [ProductSelectionSettings](ctp:api:type:ProductSelectionSetting) that were updated in the [Store](ctp:api:type:Store).
	UpdatedProductSelections []ProductSelectionSetting `json:"updatedProductSelections"`
}

* * Generated by a successful [Add Product Selection](ctp:api:type:StoreAddProductSelectionAction), * [Remove Product Selection](ctp:api:type:StoreRemoveProductSelectionAction), * [Set Product Selections](ctp:api:type:StoreSetProductSelectionsAction), * or [Change Product Selections Active](ctp:api:type:StoreChangeProductSelectionAction) update action. *

func (StoreProductSelectionsChangedMessagePayload) MarshalJSON ¶

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreReference ¶

type StoreReference struct {
	// Unique ID of the referenced [Store](ctp:api:type:Store).
	ID string `json:"id"`
	// Contains the representation of the expanded Store. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for Stores.
	Obj *Store `json:"obj,omitempty"`
}

* * Reference(/../api/types#reference) to a Store(ctp:api:type:Store). *

func (StoreReference) MarshalJSON ¶

func (obj StoreReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreRemoveCountryAction ¶

type StoreRemoveCountryAction struct {
	// Value to remove from `countries`.
	Country StoreCountry `json:"country"`
}

* * This update action produces the [StoreCountriesChanged](ctp:api:type:StoreCountriesChangedMessage) Message. * It has no effect if a given country is not present in a Store. *

func (StoreRemoveCountryAction) MarshalJSON ¶

func (obj StoreRemoveCountryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreRemoveDistributionChannelAction ¶

type StoreRemoveDistributionChannelAction struct {
	// Value to remove. ResourceIdentifier of a Channel with the `ProductDistribution` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	DistributionChannel ChannelResourceIdentifier `json:"distributionChannel"`
}

* * This update action produces the [StoreDistributionChannelsChanged](ctp:api:type:StoreDistributionChannelsChangedMessage) Message. *

func (StoreRemoveDistributionChannelAction) MarshalJSON ¶

func (obj StoreRemoveDistributionChannelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreRemoveProductSelectionAction ¶

type StoreRemoveProductSelectionAction struct {
	// Value to remove. The removed Product Selection is made offline.
	ProductSelection ProductSelectionResourceIdentifier `json:"productSelection"`
}

* * This action has no effect if the given Product Selection is not in the Store. *

func (StoreRemoveProductSelectionAction) MarshalJSON ¶

func (obj StoreRemoveProductSelectionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreRemoveSupplyChannelAction ¶

type StoreRemoveSupplyChannelAction struct {
	// Value to remove. ResourceIdentifier of a Channel with the `InventorySupply` [ChannelRoleEnum](ctp:api:type:ChannelRoleEnum).
	SupplyChannel ChannelResourceIdentifier `json:"supplyChannel"`
}

* * This update action produces the [StoreSupplyChannelsChanged](ctp:api:type:StoreSupplyChannelsChangedMessage) Message. *

func (StoreRemoveSupplyChannelAction) MarshalJSON ¶

func (obj StoreRemoveSupplyChannelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreResourceIdentifier ¶

type StoreResourceIdentifier struct {
	// Unique ID of the referenced [Store](ctp:api:type:Store). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// Unique key of the referenced [Store](ctp:api:type:Store). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(/../api/types#resourceidentifier) to a Store(ctp:api:type:Store). *

func (StoreResourceIdentifier) MarshalJSON ¶

func (obj StoreResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreSetCountriesAction ¶

type StoreSetCountriesAction struct {
	// New value to set.
	Countries []StoreCountry `json:"countries"`
}

* * This update action produces the [StoreCountriesChanged](ctp:api:type:StoreCountriesChangedMessage) Message. *

func (StoreSetCountriesAction) MarshalJSON ¶

func (obj StoreSetCountriesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreSetCustomFieldAction ¶

type StoreSetCustomFieldAction struct {
	// Name of the [Custom Field](/../api/projects/custom-fields).
	Name string `json:"name"`
	// If `value` is absent or `null`, this field will be removed if it exists.
	// Removing a field that does not exist returns an [InvalidOperation](ctp:api:type:InvalidOperationError) error.
	// If `value` is provided, it is set for the field defined by `name`.
	Value interface{} `json:"value,omitempty"`
}

func (StoreSetCustomFieldAction) MarshalJSON ¶

func (obj StoreSetCustomFieldAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreSetCustomTypeAction ¶

type StoreSetCustomTypeAction struct {
	// Defines the [Type](ctp:api:type:Type) that extends the Store with [Custom Fields](/../api/projects/custom-fields).
	// If absent, any existing Type and Custom Fields are removed from the Store.
	Type *TypeResourceIdentifier `json:"type,omitempty"`
	// Sets the [Custom Fields](/../api/projects/custom-fields) fields for the Store.
	Fields *FieldContainer `json:"fields,omitempty"`
}

func (StoreSetCustomTypeAction) MarshalJSON ¶

func (obj StoreSetCustomTypeAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreSetDistributionChannelsAction ¶

type StoreSetDistributionChannelsAction struct {
	// Value to set.
	// If not defined, the Store's `distributionChannels` are unset.
	DistributionChannels []ChannelResourceIdentifier `json:"distributionChannels"`
}

* * This update action produces the [StoreDistributionChannelsChanged](ctp:api:type:StoreDistributionChannelsChangedMessage) Message. * * Setting a Channel(ctp:api:type:Channel) without the `ProductDistribution` ChannelRoleEnum(ctp:api:type:ChannelRoleEnum) returns a [MissingRoleOnChannel](ctp:api:type:MissingRoleOnChannelError) error. *

func (StoreSetDistributionChannelsAction) MarshalJSON ¶

func (obj StoreSetDistributionChannelsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreSetLanguagesAction ¶

type StoreSetLanguagesAction struct {
	// Value to set.
	Languages []string `json:"languages"`
}

* * This update action produces the [StoreLanguagesChanged](ctp:api:type:StoreLanguagesChangedMessage) Message. * Adding a language other than the ones defined in the Project(ctp:api:type:Project) returns a [ProjectNotConfiguredForLanguages](ctp:api:type:ProjectNotConfiguredForLanguagesError) error. *

func (StoreSetLanguagesAction) MarshalJSON ¶

func (obj StoreSetLanguagesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreSetNameAction ¶

type StoreSetNameAction struct {
	// Value to set.
	Name *LocalizedString `json:"name,omitempty"`
}

* * This update action produces the [StoreNameSet](ctp:api:type:StoreNameSetMessage) Message. *

func (StoreSetNameAction) MarshalJSON ¶

func (obj StoreSetNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreSetProductSelectionsAction ¶

type StoreSetProductSelectionsAction struct {
	// Value to set.
	//
	// - If provided, Product Selections for which `active` is set to `true` are available in the Store.
	// - If not provided or provided as empty array, the action removes all Product Selections from this Store, meaning all Products in the [Project](ctp:api:type:Project) are available in this Store.
	ProductSelections []ProductSelectionSettingDraft `json:"productSelections"`
}

* * Instead of adding or removing [Product Selections](/../api/projects/product-selections) individually, you can also change all the Store's Product Selections in one go using this update action. The Store will only contain the Product Selections specified in the request. *

func (StoreSetProductSelectionsAction) MarshalJSON ¶

func (obj StoreSetProductSelectionsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreSetSupplyChannelsAction ¶

type StoreSetSupplyChannelsAction struct {
	// Value to set.
	// If not defined, the Store's `supplyChannels` are unset.
	SupplyChannels []ChannelResourceIdentifier `json:"supplyChannels"`
}

* * Setting a supply channel produces the [StoreSupplyChannelsChanged](ctp:api:type:StoreSupplyChannelsChangedMessage) Message. * * Setting a Channel(ctp:api:type:Channel) without the `InventorySupply` ChannelRoleEnum(ctp:api:type:ChannelRoleEnum) returns a [MissingRoleOnChannel](ctp:api:type:MissingRoleOnChannelError) error. *

func (StoreSetSupplyChannelsAction) MarshalJSON ¶

func (obj StoreSetSupplyChannelsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreSupplyChannelsChangedMessage ¶

type StoreSupplyChannelsChangedMessage struct {
	// Unique identifier of the Message. Can be used to track which Messages have been processed.
	ID string `json:"id"`
	// Version of a resource. In case of Messages, this is always `1`.
	Version int `json:"version"`
	// Date and time (UTC) the Message was generated.
	CreatedAt time.Time `json:"createdAt"`
	// Value of `createdAt`.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Value of `createdBy`.
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Message number in relation to other Messages for a given resource. The `sequenceNumber` of the next Message for the resource is the successor of the `sequenceNumber` of the current Message. Meaning, the `sequenceNumber` of the next Message equals the `sequenceNumber` of the current Message + 1.
	// `sequenceNumber` can be used to ensure that Messages are processed in the correct order for a particular resource.
	SequenceNumber int `json:"sequenceNumber"`
	// [Reference](ctp:api:type:Reference) to the resource on which the change or action was performed.
	Resource Reference `json:"resource"`
	// Version of the resource on which the change or action was performed.
	ResourceVersion int `json:"resourceVersion"`
	// User-provided identifiers of the resource, such as `key` or `externalId`. Only present if the resource has such identifiers.
	ResourceUserProvidedIdentifiers *UserProvidedIdentifiers `json:"resourceUserProvidedIdentifiers,omitempty"`
	// Inventory supply Channels that have been added to the [Store](ctp:api:type:Store).
	AddedSupplyChannels []ChannelReference `json:"addedSupplyChannels"`
	// Inventory supply Channels that have been removed from the [Store](ctp:api:type:Store).
	RemovedSupplyChannels []ChannelReference `json:"removedSupplyChannels"`
}

* * Generated after a successful [Add Supply Channel](ctp:api:type:StoreAddSupplyChannelAction), * [Remove Supply Channel](ctp:api:type:StoreRemoveSupplyChannelAction), or * [Set Supply Channels](ctp:api:type:StoreSetSupplyChannelsAction) update action. *

func (StoreSupplyChannelsChangedMessage) MarshalJSON ¶

func (obj StoreSupplyChannelsChangedMessage) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*StoreSupplyChannelsChangedMessage) UnmarshalJSON ¶

func (obj *StoreSupplyChannelsChangedMessage) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StoreSupplyChannelsChangedMessagePayload ¶

type StoreSupplyChannelsChangedMessagePayload struct {
	// Inventory supply Channels that have been added to the [Store](ctp:api:type:Store).
	AddedSupplyChannels []ChannelReference `json:"addedSupplyChannels"`
	// Inventory supply Channels that have been removed from the [Store](ctp:api:type:Store).
	RemovedSupplyChannels []ChannelReference `json:"removedSupplyChannels"`
}

* * Generated after a successful [Add Supply Channel](ctp:api:type:StoreAddSupplyChannelAction), * [Remove Supply Channel](ctp:api:type:StoreRemoveSupplyChannelAction), or * [Set Supply Channels](ctp:api:type:StoreSetSupplyChannelsAction) update action. *

func (StoreSupplyChannelsChangedMessagePayload) MarshalJSON ¶

func (obj StoreSupplyChannelsChangedMessagePayload) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type StoreUpdate ¶

type StoreUpdate struct {
	// Expected version of the Store on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the Store.
	Actions []StoreUpdateAction `json:"actions"`
}

func (*StoreUpdate) UnmarshalJSON ¶

func (obj *StoreUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type StoreUpdateAction ¶

type StoreUpdateAction interface{}

type SubRate ¶

type SubRate struct {
	// Name of the SubRate.
	Name   string  `json:"name"`
	Amount float64 `json:"amount"`
}

* * It is used to calculate the [taxPortions](/../api/projects/carts#taxedprice) field in a Cart or Order.

type Subscription ¶

type Subscription struct {
	// Unique identifier of the Subscription.
	ID string `json:"id"`
	// Current version of the Subscription.
	Version int `json:"version"`
	// Date and time (UTC) the Subscription was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Subscription was last modified.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Change notifications subscribed to.
	Changes []ChangeSubscription `json:"changes"`
	// Messaging service to which the messages are to be sent.
	Destination Destination `json:"destination"`
	// User-defined unique identifier of the Subscription.
	Key *string `json:"key,omitempty"`
	// Messages subscribed to.
	Messages []MessageSubscription `json:"messages"`
	// Format in which the payload is delivered.
	Format DeliveryFormat `json:"format"`
	// Status of the Subscription.
	Status SubscriptionHealthStatus `json:"status"`
}

func (*Subscription) UnmarshalJSON ¶

func (obj *Subscription) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type SubscriptionChangeDestinationAction ¶

type SubscriptionChangeDestinationAction struct {
	// New value to set. Must not be empty.
	Destination Destination `json:"destination"`
}

* * A test message is sent to ensure the correct configuration of the Destination. If the message cannot be delivered, the update will fail. The payload of the test message is a notification of type [ResourceCreated](ctp:api:type:ResourceCreatedDeliveryPayload) for the `resourceTypeId` `subscription`. The `status` will change to [Healthy](ctp:api:type:SubscriptionHealthStatus), if it isn't already. *

func (SubscriptionChangeDestinationAction) MarshalJSON ¶

func (obj SubscriptionChangeDestinationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*SubscriptionChangeDestinationAction) UnmarshalJSON ¶

func (obj *SubscriptionChangeDestinationAction) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type SubscriptionDraft ¶

type SubscriptionDraft struct {
	// Change notifications to be subscribed to.
	Changes []ChangeSubscription `json:"changes"`
	// Messaging service to which the messages are sent.
	Destination Destination `json:"destination"`
	// User-defined unique identifier for the Subscription.
	Key *string `json:"key,omitempty"`
	// Messages to be subscribed to.
	Messages []MessageSubscription `json:"messages"`
	// Format in which the payload is delivered. When not provided, the [PlatformFormat](ctp:api:type:PlatformFormat) is selected by default.
	Format DeliveryFormat `json:"format,omitempty"`
}

* * Either `messages` or `changes` must be set. *

func (SubscriptionDraft) MarshalJSON ¶

func (obj SubscriptionDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*SubscriptionDraft) UnmarshalJSON ¶

func (obj *SubscriptionDraft) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type SubscriptionHealthStatus ¶

type SubscriptionHealthStatus string

* * The health status of the Subscription that indicates whether messages are being delivered to the Destination. *

const (
	SubscriptionHealthStatusHealthy                           SubscriptionHealthStatus = "Healthy"
	SubscriptionHealthStatusConfigurationError                SubscriptionHealthStatus = "ConfigurationError"
	SubscriptionHealthStatusConfigurationErrorDeliveryStopped SubscriptionHealthStatus = "ConfigurationErrorDeliveryStopped"
	SubscriptionHealthStatusTemporaryError                    SubscriptionHealthStatus = "TemporaryError"
)

type SubscriptionPagedQueryResponse ¶

type SubscriptionPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// Subscriptions matching the query.
	Results []Subscription `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of Subscription(ctp:api:type:Subscription). *

type SubscriptionSetChangesAction ¶

type SubscriptionSetChangesAction struct {
	// Value to set. Can only be unset if `messages` is set.
	Changes []ChangeSubscription `json:"changes"`
}

func (SubscriptionSetChangesAction) MarshalJSON ¶

func (obj SubscriptionSetChangesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type SubscriptionSetKeyAction ¶

type SubscriptionSetKeyAction struct {
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

func (SubscriptionSetKeyAction) MarshalJSON ¶

func (obj SubscriptionSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type SubscriptionSetMessagesAction ¶

type SubscriptionSetMessagesAction struct {
	// Value to set. Can only be unset if `changes` is set.
	Messages []MessageSubscription `json:"messages"`
}

func (SubscriptionSetMessagesAction) MarshalJSON ¶

func (obj SubscriptionSetMessagesAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type SubscriptionUpdate ¶

type SubscriptionUpdate struct {
	// Expected version of the Subscription on which the changes should be applied. If the expected version does not match the actual version, a [409 Conflict](/../api/errors#409-conflict) will be returned.
	Version int `json:"version"`
	// Update actions to be performed on the Subscription.
	Actions []SubscriptionUpdateAction `json:"actions"`
}

func (*SubscriptionUpdate) UnmarshalJSON ¶

func (obj *SubscriptionUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type SubscriptionUpdateAction ¶

type SubscriptionUpdateAction interface{}

type SuggestTokenizer ¶

type SuggestTokenizer interface{}

type Suggestion ¶

type Suggestion struct {
	// The suggested text.
	Text string `json:"text"`
}

type SuggestionResult ¶

type SuggestionResult map[string][]Suggestion

type SyncInfo ¶

type SyncInfo struct {
	// Connection to a particular synchronization destination.
	Channel ChannelReference `json:"channel"`
	// Can be used to reference an external order instance, file etc.
	ExternalId *string   `json:"externalId,omitempty"`
	SyncedAt   time.Time `json:"syncedAt"`
}

type SyntaxErrorError ¶

type SyntaxErrorError struct {
	// `"Syntax error while parsing $fieldDefinition."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a [Discount predicate](/../api/predicates/predicate-operators), [API Extension predicate](/../api/predicates/query#using-predicates-in-conditional-api-extensions), or [search query](/../api/projects/products-search) does not have the correct syntax. *

func (*SyntaxErrorError) DecodeStruct ¶

func (obj *SyntaxErrorError) DecodeStruct(src map[string]interface{}) error

func (SyntaxErrorError) Error ¶

func (obj SyntaxErrorError) Error() string

func (SyntaxErrorError) MarshalJSON ¶

func (obj SyntaxErrorError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*SyntaxErrorError) UnmarshalJSON ¶

func (obj *SyntaxErrorError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type TaxCalculationMode ¶

type TaxCalculationMode string

* * Determines in which [Tax calculation mode](/carts-orders-overview#tax-calculation-mode) taxed prices are calculated. *

const (
	TaxCalculationModeLineItemLevel  TaxCalculationMode = "LineItemLevel"
	TaxCalculationModeUnitPriceLevel TaxCalculationMode = "UnitPriceLevel"
)

type TaxCategory ¶

type TaxCategory struct {
	// Unique identifier of the TaxCategory.
	ID string `json:"id"`
	// Current version of the TaxCategory.
	Version int `json:"version"`
	// Date and time (UTC) the TaxCategory was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the TaxCategory was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// Name of the TaxCategory.
	Name string `json:"name"`
	// Description of the TaxCategory.
	Description *string `json:"description,omitempty"`
	// Tax rates and subrates of states and countries. Each TaxRate in the array has a unique ID.
	Rates []TaxRate `json:"rates"`
	// User-defined unique identifier of the TaxCategory.
	Key *string `json:"key,omitempty"`
}

type TaxCategoryAddTaxRateAction ¶

type TaxCategoryAddTaxRateAction struct {
	// Value to append to the `rates` array.
	TaxRate TaxRateDraft `json:"taxRate"`
}

func (TaxCategoryAddTaxRateAction) MarshalJSON ¶

func (obj TaxCategoryAddTaxRateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TaxCategoryChangeNameAction ¶

type TaxCategoryChangeNameAction struct {
	// New value to set. Must not be empty.
	Name string `json:"name"`
}

func (TaxCategoryChangeNameAction) MarshalJSON ¶

func (obj TaxCategoryChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TaxCategoryDraft ¶

type TaxCategoryDraft struct {
	// Name of the TaxCategory.
	Name string `json:"name"`
	// Description of the TaxCategory.
	Description *string `json:"description,omitempty"`
	// Tax rates and subrates of states and countries.
	Rates []TaxRateDraft `json:"rates"`
	// User-defined unique identifier for the TaxCategory.
	Key *string `json:"key,omitempty"`
}

func (TaxCategoryDraft) MarshalJSON ¶

func (obj TaxCategoryDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TaxCategoryPagedQueryResponse ¶

type TaxCategoryPagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [TaxCategories](ctp:api:type:TaxCategory) matching the query.
	Results []TaxCategory `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of TaxCategory(ctp:api:type:TaxCategory). *

type TaxCategoryReference ¶

type TaxCategoryReference struct {
	// Unique identifier of the referenced [TaxCategory](ctp:api:type:TaxCategory).
	ID string `json:"id"`
	// Contains the representation of the expanded TaxCategory. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for TaxCategories.
	Obj *TaxCategory `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a TaxCategory(ctp:api:type:TaxCategory). *

func (TaxCategoryReference) MarshalJSON ¶

func (obj TaxCategoryReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TaxCategoryRemoveTaxRateAction ¶

type TaxCategoryRemoveTaxRateAction struct {
	// ID of the TaxRate to remove.
	// Either `taxRateId` or `taxRateKey` is required for this update action.
	TaxRateId *string `json:"taxRateId,omitempty"`
	// Key of the TaxRate to remove.
	// Either `taxRateId` or `taxRateKey` is required for this update action.
	TaxRateKey *string `json:"taxRateKey,omitempty"`
}

func (TaxCategoryRemoveTaxRateAction) MarshalJSON ¶

func (obj TaxCategoryRemoveTaxRateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TaxCategoryReplaceTaxRateAction ¶

type TaxCategoryReplaceTaxRateAction struct {
	// ID of the TaxRate to replace.
	// Either `taxRateId` or `taxRateKey` is required for this update action.
	TaxRateId *string `json:"taxRateId,omitempty"`
	// Key of the TaxRate to replace.
	// Either `taxRateId` or `taxRateKey` is required for this update action.
	TaxRateKey *string `json:"taxRateKey,omitempty"`
	// New TaxRate to replace with.
	TaxRate TaxRateDraft `json:"taxRate"`
}

func (TaxCategoryReplaceTaxRateAction) MarshalJSON ¶

func (obj TaxCategoryReplaceTaxRateAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TaxCategoryResourceIdentifier ¶

type TaxCategoryResourceIdentifier struct {
	// Unique identifier of the referenced [TaxCategory](ctp:api:type:TaxCategory). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [TaxCategory](ctp:api:type:TaxCategory). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a TaxCategory(ctp:api:type:TaxCategory). *

func (TaxCategoryResourceIdentifier) MarshalJSON ¶

func (obj TaxCategoryResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TaxCategorySetDescriptionAction ¶

type TaxCategorySetDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	Description *string `json:"description,omitempty"`
}

func (TaxCategorySetDescriptionAction) MarshalJSON ¶

func (obj TaxCategorySetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TaxCategorySetKeyAction ¶

type TaxCategorySetKeyAction struct {
	// Value to set. If empty, any existing value will be removed.
	Key *string `json:"key,omitempty"`
}

func (TaxCategorySetKeyAction) MarshalJSON ¶

func (obj TaxCategorySetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TaxCategoryUpdate ¶

type TaxCategoryUpdate struct {
	// Expected version of the TaxCategory on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the TaxCategory.
	Actions []TaxCategoryUpdateAction `json:"actions"`
}

func (*TaxCategoryUpdate) UnmarshalJSON ¶

func (obj *TaxCategoryUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type TaxCategoryUpdateAction ¶

type TaxCategoryUpdateAction interface{}

type TaxMode ¶

type TaxMode string

* * Indicates how taxes are set on the Cart. *

const (
	TaxModePlatform       TaxMode = "Platform"
	TaxModeExternal       TaxMode = "External"
	TaxModeExternalAmount TaxMode = "ExternalAmount"
	TaxModeDisabled       TaxMode = "Disabled"
)

type TaxPortion ¶

type TaxPortion struct {
	// Name of the tax portion.
	Name *string `json:"name,omitempty"`
	// A number in the range 0-1.
	Rate float64 `json:"rate"`
	// Money value of the tax portion.
	Amount CentPrecisionMoney `json:"amount"`
}

* * The tax portions are calculated from the [TaxRates](ctp:api:type:TaxRate). * If a Tax Rate has [SubRates](ctp:api:type:SubRate), they are used and can be identified by name. * Tax portions from Line Items with the same `rate` and `name` are accumulated to the same tax portion. *

type TaxPortionDraft ¶

type TaxPortionDraft struct {
	// Name of the tax portion.
	Name *string `json:"name,omitempty"`
	// A number in the range 0-1.
	Rate float64 `json:"rate"`
	// Money value for the tax portion.
	Amount Money `json:"amount"`
}

* * Represents the portions that sum up to the `totalGross` field of a TaxedPrice(ctp:api:type:TaxedPrice). * * The portions are calculated from the [TaxRates](ctp:api:type:TaxRate). * If a Tax Rate has [SubRates](ctp:api:type:SubRate), they are used and can be identified by name. * Tax portions from Line Items with the same `rate` and `name` will be accumulated to the same tax portion. *

type TaxRate ¶

type TaxRate struct {
	// Present if the TaxRate is part of a [TaxCategory](ctp:api:type:TaxCategory).
	// Absent for external TaxRates in [LineItem](ctp:api:type:LineItem), [CustomLineItem](ctp:api:type:CustomLineItem), and [ShippingInfo](ctp:api:type:ShippingInfo).
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the TaxRate.
	// Present when set using [TaxRateDraft](ctp:api:type:TaxRateDraft). Not available for external TaxRates created using [ExternalTaxRateDraft](ctp:api:type:ExternalTaxRateDraft).
	Key *string `json:"key,omitempty"`
	// Name of the TaxRate.
	Name string `json:"name"`
	// Tax rate. If subrates are used, the amount must be the sum of all subrates.
	Amount float64 `json:"amount"`
	// If `true`, tax is included in [Embedded Prices](ctp:api:type:Price) or [Standalone Prices](ctp:api:type:StandalonePrice), and the `taxedPrice` is present on [LineItems](ctp:api:type:LineItem). In this case, the `totalNet` price on [TaxedPrice](ctp:api:type:TaxedPrice) includes the TaxRate.
	IncludedInPrice bool `json:"includedInPrice"`
	// Country in which the tax rate is applied in [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
	Country string `json:"country"`
	// State within the country, such as Texas in the United States.
	State *string `json:"state,omitempty"`
	// Used to calculate the [taxPortions](/../api/projects/carts#taxedprice) field in a Cart or Order. It is useful if the total tax of a country (such as the US) is a combination of multiple taxes (such as state and local taxes).
	SubRates []SubRate `json:"subRates"`
}

func (TaxRate) MarshalJSON ¶

func (obj TaxRate) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TaxRateDraft ¶

type TaxRateDraft struct {
	// Name of the TaxRate.
	Name string `json:"name"`
	// Tax rate.
	// Must be supplied if no `subRates` are specified.
	// If `subRates` are specified, this field can be omitted or it must be the sum of amounts of all `subRates`.
	Amount *float64 `json:"amount,omitempty"`
	// If `true`, tax is included in [Embedded Prices](ctp:api:type:Price) or [Standalone Prices](ctp:api:type:StandalonePrice), and the `taxedPrice` is present on [LineItems](ctp:api:type:LineItem). In this case, the `totalNet` price on [TaxedPrice](ctp:api:type:TaxedPrice) includes the TaxRate.
	IncludedInPrice bool `json:"includedInPrice"`
	// Country in which the tax rate is applied in [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
	Country string `json:"country"`
	// State within the country, such as Texas in the United States.
	State *string `json:"state,omitempty"`
	// Used to calculate the [taxPortions](/../api/projects/carts#taxedprice) field in a Cart or Order. It is useful if the total tax of a country (such as the US) is a combination of multiple taxes (such as state and local taxes).
	SubRates []SubRate `json:"subRates"`
	// User-defined unique identifier of the TaxRate.
	Key *string `json:"key,omitempty"`
}

func (TaxRateDraft) MarshalJSON ¶

func (obj TaxRateDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TaxedItemPrice ¶

type TaxedItemPrice struct {
	// Total net amount of the Line Item or Custom Line Item.
	TotalNet CentPrecisionMoney `json:"totalNet"`
	// Total gross amount of the Line Item or Custom Line Item.
	TotalGross CentPrecisionMoney `json:"totalGross"`
	// Total tax applicable for the Line Item or Custom Line Item.
	// Automatically calculated as the difference between the `totalGross` and `totalNet` values.
	TotalTax *CentPrecisionMoney `json:"totalTax,omitempty"`
}

type TaxedItemPriceDraft ¶

type TaxedItemPriceDraft struct {
	// Draft type that stores amounts only in cent precision for the specified currency.
	TotalNet Money `json:"totalNet"`
	// Draft type that stores amounts only in cent precision for the specified currency.
	TotalGross Money `json:"totalGross"`
}

type TaxedPrice ¶

type TaxedPrice struct {
	// Total net price of the Cart or Order.
	TotalNet CentPrecisionMoney `json:"totalNet"`
	// Total gross price of the Cart or Order.
	TotalGross CentPrecisionMoney `json:"totalGross"`
	// Taxable portions added to the total net price.
	//
	// Calculated from the [TaxRates](ctp:api:type:TaxRate).
	TaxPortions []TaxPortion `json:"taxPortions"`
	// Total tax applicable for the Cart or Order.
	//
	// Automatically calculated as the difference between the `totalGross` and `totalNet` values.
	TotalTax *CentPrecisionMoney `json:"totalTax,omitempty"`
}

type TaxedPriceDraft ¶

type TaxedPriceDraft struct {
	// Total net price of the Line Item or Custom Line Item.
	TotalNet Money `json:"totalNet"`
	// Total gross price of the Line Item or Custom Line Item.
	TotalGross Money `json:"totalGross"`
	// Taxable portions added to the `totalGross`.
	//
	// Calculated from the [TaxRates](ctp:api:type:TaxRate).
	TaxPortions []TaxPortionDraft `json:"taxPortions"`
}

type TermFacetResult ¶

type TermFacetResult struct {
	DataType TermFacetResultType `json:"dataType"`
	Missing  int                 `json:"missing"`
	Total    int                 `json:"total"`
	Other    int                 `json:"other"`
	Terms    []FacetTerm         `json:"terms"`
}

func (TermFacetResult) MarshalJSON ¶

func (obj TermFacetResult) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TermFacetResultType ¶

type TermFacetResultType string
const (
	TermFacetResultTypeText     TermFacetResultType = "text"
	TermFacetResultTypeDate     TermFacetResultType = "date"
	TermFacetResultTypeTime     TermFacetResultType = "time"
	TermFacetResultTypeDatetime TermFacetResultType = "datetime"
	TermFacetResultTypeBoolean  TermFacetResultType = "boolean"
	TermFacetResultTypeNumber   TermFacetResultType = "number"
)

type TextInputHint ¶

type TextInputHint string

* * A text input hint is a string with one of the following values: *

const (
	TextInputHintSingleLine TextInputHint = "SingleLine"
	TextInputHintMultiLine  TextInputHint = "MultiLine"
)

type TextLineItem ¶

type TextLineItem struct {
	// Date and time (UTC) the TextLineItem was added to the [ShoppingList](ctp:api:type:ShoppingList).
	AddedAt time.Time `json:"addedAt"`
	// Custom Fields of the TextLineItem.
	Custom *CustomFields `json:"custom,omitempty"`
	// Description of the TextLineItem.
	Description *LocalizedString `json:"description,omitempty"`
	// Unique identifier of the TextLineItem.
	ID string `json:"id"`
	// Name of the TextLineItem.
	Name LocalizedString `json:"name"`
	// Number of entries in the TextLineItem.
	Quantity int `json:"quantity"`
}

* * TextLineItems are Line Items that use text values instead of references to Products. *

type TextLineItemDraft ¶

type TextLineItemDraft struct {
	// Date and time the TextLineItem is added to the [ShoppingList](ctp:api:type:ShoppingList). If not set, the current date and time (UTC) is used.
	AddedAt *time.Time `json:"addedAt,omitempty"`
	// Custom Fields for the TextLineItem.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
	// Description of the TextLineItem.
	Description *LocalizedString `json:"description,omitempty"`
	// Name of the TextLineItem.
	Name LocalizedString `json:"name"`
	// Number of entries in the TextLineItem.
	Quantity *int `json:"quantity,omitempty"`
}

type TrackingData ¶

type TrackingData struct {
	// The ID to track one parcel.
	TrackingId *string `json:"trackingId,omitempty"`
	// The carrier that delivers the parcel.
	Carrier             *string `json:"carrier,omitempty"`
	Provider            *string `json:"provider,omitempty"`
	ProviderTransaction *string `json:"providerTransaction,omitempty"`
	// Flag to distinguish if the parcel is on the way to the customer (false) or on the way back (true).
	IsReturn *bool `json:"isReturn,omitempty"`
}

type Transaction ¶

type Transaction struct {
	// Unique identifier of the Transaction.
	ID string `json:"id"`
	// Date and time (UTC) the Transaction took place.
	Timestamp *time.Time `json:"timestamp,omitempty"`
	// Type of the Transaction. For example, `Authorization`.
	Type TransactionType `json:"type"`
	// Money value of the Transaction.
	Amount CentPrecisionMoney `json:"amount"`
	// Identifier used by the interface that manages the Transaction (usually the PSP).
	// If a matching interaction was logged in the `interfaceInteractions` array, the corresponding interaction can be found with this ID.
	InteractionId *string `json:"interactionId,omitempty"`
	// State of the Transaction.
	State TransactionState `json:"state"`
	// Custom Fields defined for the Transaction.
	Custom *CustomFields `json:"custom,omitempty"`
}

* * Represents a financial transaction typically created as a result of a notification from the payment service. *

type TransactionDraft ¶

type TransactionDraft struct {
	// Date and time (UTC) the Transaction took place.
	Timestamp *time.Time `json:"timestamp,omitempty"`
	// Type of the Transaction.
	Type TransactionType `json:"type"`
	// Money value for the Transaction.
	Amount Money `json:"amount"`
	// Identifier used by the payment service that manages the Transaction.
	// Can be used to correlate the Transaction to an interface interaction.
	InteractionId *string `json:"interactionId,omitempty"`
	// State of the Transaction.
	State *TransactionState `json:"state,omitempty"`
	// Custom Fields of the Transaction.
	Custom *CustomFieldsDraft `json:"custom,omitempty"`
}

type TransactionState ¶

type TransactionState string

* * Transactions can be in one of the following States: *

const (
	TransactionStateInitial TransactionState = "Initial"
	TransactionStatePending TransactionState = "Pending"
	TransactionStateSuccess TransactionState = "Success"
	TransactionStateFailure TransactionState = "Failure"
)

type TransactionType ¶

type TransactionType string
const (
	TransactionTypeAuthorization       TransactionType = "Authorization"
	TransactionTypeCancelAuthorization TransactionType = "CancelAuthorization"
	TransactionTypeCharge              TransactionType = "Charge"
	TransactionTypeRefund              TransactionType = "Refund"
	TransactionTypeChargeback          TransactionType = "Chargeback"
)

type Type ¶

type Type struct {
	// Unique identifier of the Type.
	ID string `json:"id"`
	// Current version of the Type.
	Version int `json:"version"`
	// Date and time (UTC) the Type was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Type was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the Type.
	Key string `json:"key"`
	// Name of the Type.
	Name LocalizedString `json:"name"`
	// Description of the Type.
	Description *LocalizedString `json:"description,omitempty"`
	// Resources and/or data types for which the Type is defined.
	ResourceTypeIds []ResourceTypeId `json:"resourceTypeIds"`
	// Defines Custom Fields.
	FieldDefinitions []FieldDefinition `json:"fieldDefinitions"`
}

type TypeAddEnumValueAction ¶

type TypeAddEnumValueAction struct {
	// `name` of the [Field Definition](ctp:api:type:FieldDefinition) to update.
	FieldName string `json:"fieldName"`
	// Value to append to the array.
	Value CustomFieldEnumValue `json:"value"`
}

* * Adds a value to an [EnumType](ctp:api:type:CustomFieldEnumType). * This update action can be used to update an [EnumType](ctp:api:type:CustomFieldEnumType) FieldDefinition and a [SetType](ctp:api:type:CustomFieldSetType) FieldDefinition of [EnumType](ctp:api:type:CustomFieldEnumType). *

func (TypeAddEnumValueAction) MarshalJSON ¶

func (obj TypeAddEnumValueAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeAddFieldDefinitionAction ¶

type TypeAddFieldDefinitionAction struct {
	// Value to append to the array.
	FieldDefinition FieldDefinition `json:"fieldDefinition"`
}

* * Defines a new field for a Type. Adding new required fields to a Type that is already referenced by existing entities can put those entities in a temporarily inconsistent state. * * If a Type that is already in use requires new fields, we recommend making them optional (`required` set to `false`) whenever possible. Alternatively, any new required fields should be added one at a time followed by an update to all the resources using the Type. This prevents validation errors caused by an entity missing more than one required custom field. *

func (TypeAddFieldDefinitionAction) MarshalJSON ¶

func (obj TypeAddFieldDefinitionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeAddLocalizedEnumValueAction ¶

type TypeAddLocalizedEnumValueAction struct {
	// `name` of the [FieldDefinition](ctp:api:type:FieldDefinition) to update.
	FieldName string `json:"fieldName"`
	// Value to append to the array.
	Value CustomFieldLocalizedEnumValue `json:"value"`
}

* * Adds a value to a [LocalizedEnumType](ctp:api:type:CustomFieldLocalizedEnumType). * This update action can be used to update a [LocalizedEnumType](ctp:api:type:CustomFieldLocalizedEnumType) FieldDefinition and a [SetType](ctp:api:type:CustomFieldSetType) FieldDefinition of CustomFieldLocalizedEnumType(ctp:api:type:CustomFieldLocalizedEnumType). *

func (TypeAddLocalizedEnumValueAction) MarshalJSON ¶

func (obj TypeAddLocalizedEnumValueAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeChangeEnumValueLabelAction ¶

type TypeChangeEnumValueLabelAction struct {
	// `name` of the [FieldDefinition](ctp:api:type:FieldDefinition) to update.
	FieldName string `json:"fieldName"`
	// New value to set.
	// Must not be empty.
	Value CustomFieldEnumValue `json:"value"`
}

* * Changes the `label` of an [EnumValue](ctp:api:type:CustomFieldEnumValue) of an [EnumType](ctp:api:type:CustomFieldEnumType) FieldDefinition. *

func (TypeChangeEnumValueLabelAction) MarshalJSON ¶

func (obj TypeChangeEnumValueLabelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeChangeEnumValueOrderAction ¶

type TypeChangeEnumValueOrderAction struct {
	// `name` of the [FieldDefinition](ctp:api:type:FieldDefinition) to update.
	FieldName string `json:"fieldName"`
	// Must match the set of `key`s of the EnumValues in the FieldDefinition (apart from their order).
	Keys []string `json:"keys"`
}

* * Changes the order of [EnumValues](ctp:api:type:CustomFieldEnumValue) in an [EnumType](ctp:api:type:CustomFieldEnumType) FieldDefinition. * This update action can be used to update an [EnumType](ctp:api:type:CustomFieldEnumType) FieldDefinition and a [SetType](ctp:api:type:CustomFieldSetType) FieldDefinition of [EnumType](ctp:api:type:CustomFieldEnumType). *

func (TypeChangeEnumValueOrderAction) MarshalJSON ¶

func (obj TypeChangeEnumValueOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeChangeFieldDefinitionLabelAction ¶

type TypeChangeFieldDefinitionLabelAction struct {
	// `name` of the [FieldDefinition](ctp:api:type:FieldDefinition) to update.
	FieldName string `json:"fieldName"`
	// New value to set.
	// Must not be empty.
	Label LocalizedString `json:"label"`
}

func (TypeChangeFieldDefinitionLabelAction) MarshalJSON ¶

func (obj TypeChangeFieldDefinitionLabelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeChangeFieldDefinitionOrderAction ¶

type TypeChangeFieldDefinitionOrderAction struct {
	// Must match the set of `name`s of FieldDefinitions (up to order).
	FieldNames []string `json:"fieldNames"`
}

func (TypeChangeFieldDefinitionOrderAction) MarshalJSON ¶

func (obj TypeChangeFieldDefinitionOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeChangeInputHintAction ¶

type TypeChangeInputHintAction struct {
	// `name` of the [Field Definition](ctp:api:type:FieldDefinition) to update.
	FieldName string `json:"fieldName"`
	// New value to set.
	// Must not be empty.
	InputHint TypeTextInputHint `json:"inputHint"`
}

* * Changes the `inputHint` of CustomFieldStringType(ctp:api:type:CustomFieldStringType) FieldDefinition(ctp:api:type:FieldDefinition), a CustomFieldLocalizedStringType(ctp:api:type:CustomFieldLocalizedStringType) FieldDefinition(ctp:api:type:FieldDefinition), and CustomFieldSetType(ctp:api:type:CustomFieldSetType) FieldDefinition(ctp:api:type:FieldDefinition) of these string-based FieldTypes. *

func (TypeChangeInputHintAction) MarshalJSON ¶

func (obj TypeChangeInputHintAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeChangeKeyAction ¶

type TypeChangeKeyAction struct {
	// New value to set.
	// Must not be empty.
	Key string `json:"key"`
}

func (TypeChangeKeyAction) MarshalJSON ¶

func (obj TypeChangeKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeChangeLabelAction ¶

type TypeChangeLabelAction struct {
	// Name of the [Field Definition](ctp:api:type:FieldDefinition) to update.
	FieldName string `json:"fieldName"`
	// JSON object where the keys are of type [Locale](ctp:api:type:Locale), and the values are the strings used for the corresponding language.
	Label LocalizedString `json:"label"`
}

func (TypeChangeLabelAction) MarshalJSON ¶

func (obj TypeChangeLabelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeChangeLocalizedEnumValueLabelAction ¶

type TypeChangeLocalizedEnumValueLabelAction struct {
	// `name` of the [FieldDefinition](ctp:api:type:FieldDefinition) to update.
	FieldName string `json:"fieldName"`
	// New value to set.
	// Must not be empty.
	Value CustomFieldLocalizedEnumValue `json:"value"`
}

* * Changes the `label` of a [LocalizedEnumValue](ctp:api:type:CustomFieldLocalizedEnumValue) of a [LocalizedEnumType](ctp:api:type:CustomFieldLocalizedEnumType) FieldDefinition. *

func (TypeChangeLocalizedEnumValueLabelAction) MarshalJSON ¶

func (obj TypeChangeLocalizedEnumValueLabelAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeChangeLocalizedEnumValueOrderAction ¶

type TypeChangeLocalizedEnumValueOrderAction struct {
	// `name` of the [Field Definition](ctp:api:type:FieldDefinition) to update.
	FieldName string `json:"fieldName"`
	// Must match the set of `key`s of the LocalizedEnumValues in the FieldDefinition (up to order).
	Keys []string `json:"keys"`
}

* * Changes the order of [LocalizedEnumValues](ctp:api:type:CustomFieldLocalizedEnumValue) in a [LocalizedEnumType](ctp:api:type:CustomFieldLocalizedEnumType) FieldDefinition. * This update action can be used to update a [LocalizedEnumType](ctp:api:type:CustomFieldLocalizedEnumType) FieldDefinition and a [SetType](ctp:api:type:CustomFieldSetType) of [LocalizedEnumType](ctp:api:type:CustomFieldLocalizedEnumType) FieldDefinitions. *

func (TypeChangeLocalizedEnumValueOrderAction) MarshalJSON ¶

func (obj TypeChangeLocalizedEnumValueOrderAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeChangeNameAction ¶

type TypeChangeNameAction struct {
	// New value to set.
	// Must not be empty.
	Name LocalizedString `json:"name"`
}

func (TypeChangeNameAction) MarshalJSON ¶

func (obj TypeChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeDraft ¶

type TypeDraft struct {
	// User-defined unique identifier for the Type.
	Key string `json:"key"`
	// Name of the Type.
	Name LocalizedString `json:"name"`
	// Description of the Type.
	Description *LocalizedString `json:"description,omitempty"`
	// Resources and/or data types for which the Type is defined.
	ResourceTypeIds []ResourceTypeId `json:"resourceTypeIds"`
	// Defines Custom Fields.
	FieldDefinitions []FieldDefinition `json:"fieldDefinitions"`
}

func (TypeDraft) MarshalJSON ¶

func (obj TypeDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypePagedQueryResponse ¶

type TypePagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](ctp:api:type:QueryPredicate), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [Types](ctp:api:type:Type) matching the query.
	Results []Type `json:"results"`
}

* * [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with `results` containing an array of [Types](ctp:api:type:Type). *

type TypeReference ¶

type TypeReference struct {
	// Unique identifier of the referenced [Type](ctp:api:type:Type).
	ID string `json:"id"`
	// Contains the representation of the expanded Type.
	// Only present in responses to requests with [Reference Expansion](ctp:api:type:Expansion) for Types.
	Obj *Type `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a Type(ctp:api:type:Type). *

func (TypeReference) MarshalJSON ¶

func (obj TypeReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeRemoveFieldDefinitionAction ¶

type TypeRemoveFieldDefinitionAction struct {
	// `name` of the [FieldDefinition](ctp:api:type:FieldDefinition) to remove.
	// The removal of a FieldDefinition deletes [asynchronously](/../api/general-concepts#eventual-consistency) all Custom Fields using the FieldDefinition as well.
	FieldName string `json:"fieldName"`
}

func (TypeRemoveFieldDefinitionAction) MarshalJSON ¶

func (obj TypeRemoveFieldDefinitionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeResourceIdentifier ¶

type TypeResourceIdentifier struct {
	// Unique identifier of the referenced [Type](ctp:api:type:Type). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [Type](ctp:api:type:Type). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) of a Type(ctp:api:type:Type). *

func (TypeResourceIdentifier) MarshalJSON ¶

func (obj TypeResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeSetDescriptionAction ¶

type TypeSetDescriptionAction struct {
	// Value to set. If empty, any existing value will be removed.
	Description *LocalizedString `json:"description,omitempty"`
}

func (TypeSetDescriptionAction) MarshalJSON ¶

func (obj TypeSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type TypeTextInputHint ¶

type TypeTextInputHint string

* * Provides a visual representation type for this field. It is only relevant for string-based field types like CustomFieldStringType(ctp:api:type:CustomFieldStringType) and CustomFieldLocalizedStringType(ctp:api:type:CustomFieldLocalizedStringType). Following values are supported: *

const (
	TypeTextInputHintSingleLine TypeTextInputHint = "SingleLine"
	TypeTextInputHintMultiLine  TypeTextInputHint = "MultiLine"
)

type TypeUpdate ¶

type TypeUpdate struct {
	// Expected version of the type on which the changes should be applied.
	// If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the Type.
	Actions []TypeUpdateAction `json:"actions"`
}

func (*TypeUpdate) UnmarshalJSON ¶

func (obj *TypeUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type TypeUpdateAction ¶

type TypeUpdateAction interface{}

type TypedMoney ¶

type TypedMoney interface{}

* * Base polymorphic read-only Money type which is stored in cent precision or high precision. The actual type is determined by the `type` field. *

type TypedMoneyDraft ¶

type TypedMoneyDraft interface{}

type Update ¶

type Update struct {
	Version int            `json:"version"`
	Actions []UpdateAction `json:"actions"`
}

type UpdateAction ¶

type UpdateAction struct {
	Action string `json:"action"`
}

type UserProvidedIdentifiers ¶

type UserProvidedIdentifiers struct {
	// User-provided unique identifier of the resource.
	Key *string `json:"key,omitempty"`
	// User-provided unique identifier of the resource.
	ExternalId *string `json:"externalId,omitempty"`
	// User-provided unique identifier of an [Order](ctp:api:type:Order).
	OrderNumber *string `json:"orderNumber,omitempty"`
	// User-provided unique identifier of a [Customer](ctp:api:type:Customer).
	CustomerNumber *string `json:"customerNumber,omitempty"`
	// Unique SKU of a [Product Variant](ctp:api:type:ProductVariant).
	Sku *string `json:"sku,omitempty"`
	// Unique identifier usually used in deep-link URLs for a [Product](ctp:api:type:Product). The value corresponds to the slug in the `current` [Product Projection](ctp:api:type:ProductProjection).
	Slug *LocalizedString `json:"slug,omitempty"`
	// Unique identifier of a [Custom Object](/../api/projects/custom-objects).
	ContainerAndKey *ContainerAndKey `json:"containerAndKey,omitempty"`
}

* * User-provided identifiers present on the resource for which the Message is created. The value of the identifier stored in the Message corresponds to the one that was set on the resource at the version shown in `resourceVersion`. *

type VariantValues ¶

type VariantValues struct {
	// SKU of the [ProductVariant](ctp:api:type:ProductVariant).
	Sku *string `json:"sku,omitempty"`
	// Embedded Prices of the [ProductVariant](ctp:api:type:ProductVariant).
	Prices []PriceDraft `json:"prices"`
	// Attributes of the [ProductVariant](ctp:api:type:ProductVariant).
	Attributes []Attribute `json:"attributes"`
}

type WhitespaceTokenizer ¶

type WhitespaceTokenizer struct {
}

* * Creates tokens by splitting the `text` field in SearchKeyword(ctp:api:type:SearchKeyword) by whitespaces. *

func (WhitespaceTokenizer) MarshalJSON ¶

func (obj WhitespaceTokenizer) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type Zone ¶

type Zone struct {
	// Unique identifier of the Zone.
	ID string `json:"id"`
	// Current version of the Zone.
	Version int `json:"version"`
	// Date and time (UTC) the Zone was initially created.
	CreatedAt time.Time `json:"createdAt"`
	// Date and time (UTC) the Zone was last updated.
	LastModifiedAt time.Time `json:"lastModifiedAt"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	LastModifiedBy *LastModifiedBy `json:"lastModifiedBy,omitempty"`
	// Present on resources created after 1 February 2019 except for [events not tracked](/../api/client-logging#events-tracked).
	CreatedBy *CreatedBy `json:"createdBy,omitempty"`
	// User-defined unique identifier of the Zone.
	Key *string `json:"key,omitempty"`
	// Name of the Zone.
	Name string `json:"name"`
	// Description of the Zone.
	Description *string `json:"description,omitempty"`
	// List of locations that belong to the Zone.
	Locations []Location `json:"locations"`
}

type ZoneAddLocationAction ¶

type ZoneAddLocationAction struct {
	// Location to be added to the Zone.
	Location Location `json:"location"`
}

func (ZoneAddLocationAction) MarshalJSON ¶

func (obj ZoneAddLocationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ZoneChangeNameAction ¶

type ZoneChangeNameAction struct {
	// New name of the Zone.
	Name string `json:"name"`
}

func (ZoneChangeNameAction) MarshalJSON ¶

func (obj ZoneChangeNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ZoneDraft ¶

type ZoneDraft struct {
	// User-defined unique identifier for the Zone.
	Key *string `json:"key,omitempty"`
	// Name of the Zone.
	Name string `json:"name"`
	// Description of the Zone.
	Description *string `json:"description,omitempty"`
	// List of locations that belong to the Zone.
	Locations []Location `json:"locations"`
}

func (ZoneDraft) MarshalJSON ¶

func (obj ZoneDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ZonePagedQueryResponse ¶

type ZonePagedQueryResponse struct {
	// Number of [results requested](/../api/general-concepts#limit).
	Limit int `json:"limit"`
	// Number of [elements skipped](/../api/general-concepts#offset).
	Offset int `json:"offset"`
	// Actual number of results returned.
	Count int `json:"count"`
	// Total number of results matching the query.
	// This number is an estimation that is not [strongly consistent](/../api/general-concepts#strong-consistency).
	// This field is returned by default.
	// For improved performance, calculating this field can be deactivated by using the query parameter `withTotal=false`.
	// When the results are filtered with a [Query Predicate](/../api/predicates/query), `total` is subject to a [limit](/../api/limits#queries).
	Total *int `json:"total,omitempty"`
	// [Zones](ctp:api:type:Zone) matching the query.
	Results []Zone `json:"results"`
}

* * [PagedQueryResult](/general-concepts#pagedqueryresult) with `results` containing an array of Zone(ctp:api:type:Zone). *

type ZoneRate ¶

type ZoneRate struct {
	// [Zone](ctp:api:type:Zone) for which the shipping rates are valid.
	Zone ZoneReference `json:"zone"`
	// Shipping rates defined per currency.
	ShippingRates []ShippingRate `json:"shippingRates"`
}

* * Defines shipping rates in different currencies for a specific Zone(ctp:api:type:Zone). *

type ZoneRateDraft ¶

type ZoneRateDraft struct {
	// Sets the [Zone](ctp:api:type:Zone) for which the shippng rates are valid.
	Zone ZoneResourceIdentifier `json:"zone"`
	// Shipping rates for the `currencies` configured in the [Project](ctp:api:type:Project). The array must not contain two ShippingRates with the same [CurrencyCode](ctp:api:type:CurrencyCode).
	ShippingRates []ShippingRateDraft `json:"shippingRates"`
}

type ZoneReference ¶

type ZoneReference struct {
	// Unique identifier of the referenced [Zone](ctp:api:type:Zone).
	ID string `json:"id"`
	// Contains the representation of the expanded Zone. Only present in responses to requests with [Reference Expansion](/../api/general-concepts#reference-expansion) for Zones.
	Obj *Zone `json:"obj,omitempty"`
}

* * Reference(ctp:api:type:Reference) to a Zone(ctp:api:type:Zone). *

func (ZoneReference) MarshalJSON ¶

func (obj ZoneReference) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ZoneRemoveLocationAction ¶

type ZoneRemoveLocationAction struct {
	// Location to be removed from the Zone.
	Location Location `json:"location"`
}

func (ZoneRemoveLocationAction) MarshalJSON ¶

func (obj ZoneRemoveLocationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ZoneResourceIdentifier ¶

type ZoneResourceIdentifier struct {
	// Unique identifier of the referenced [Zone](ctp:api:type:Zone). Either `id` or `key` is required.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced [Zone](ctp:api:type:Zone). Either `id` or `key` is required.
	Key *string `json:"key,omitempty"`
}

* * ResourceIdentifier(ctp:api:type:ResourceIdentifier) to a Zone(ctp:api:type:Zone). *

func (ZoneResourceIdentifier) MarshalJSON ¶

func (obj ZoneResourceIdentifier) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ZoneSetDescriptionAction ¶

type ZoneSetDescriptionAction struct {
	// Description of the Zone.
	Description *string `json:"description,omitempty"`
}

func (ZoneSetDescriptionAction) MarshalJSON ¶

func (obj ZoneSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ZoneSetKeyAction ¶

type ZoneSetKeyAction struct {
	// If `key` is absent or `null`, the existing key, if any, will be removed.
	Key *string `json:"key,omitempty"`
}

func (ZoneSetKeyAction) MarshalJSON ¶

func (obj ZoneSetKeyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ZoneUpdate ¶

type ZoneUpdate struct {
	// Expected version of the Zone on which the changes should be applied. If the expected version does not match the actual version, a [ConcurrentModification](ctp:api:type:ConcurrentModificationError) error is returned.
	Version int `json:"version"`
	// Update actions to be performed on the Zone.
	Actions []ZoneUpdateAction `json:"actions"`
}

func (*ZoneUpdate) UnmarshalJSON ¶

func (obj *ZoneUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ZoneUpdateAction ¶

type ZoneUpdateAction interface{}

Source Files ¶

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL