Representations of resources that can be imported into a Project using the Import API.
id values are not included.parent of a CategoryImport, only KeyReferences are accepted.
This ensures that resources can be imported to multiple Projects, such as production and staging, without needing to change Project-specific id values.Types that are identical on the HTTP API, we do not document here, but refer to the respective type on the HTTP API instead.
for Business Units
Business Units are represented as either Companies or Divisions.
CompanyBusinessUnitImport
keyString | User-defined unique identifier. If a BusinessUnit with this MinLength: key exists, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
unitType | CompanyThe type of Business Unit. |
nameString | The name of the Business Unit. |
status | The status of the Business Unit. |
contactEmailString | The contact email address for the Business Unit. |
associatesArray of AssociateDraft | List of Associates to be assigned to the Business Unit. |
addressesArray of Address | The addresses for the Business Unit. |
shippingAddressesArray of Integer | The indices of the shipping addresses in the addresses array. |
defaultShippingAddressInt | The index of the default shipping address in the addresses array. |
billingAddressesArray of Integer | The indices of the billing addresses in the addresses array. |
defaultBillingAddressInt | The index of the default billing address in the addresses array. |
storesArray of StoreKeyReference | The Stores of the Business Unit. |
storeMode | Default: Explicit |
custom | Custom fields for the Business Unit. |
{
"key": "acme-business-unit",
"name": "ACME Business Unit",
"unitType": "Company"
}DivisionBusinessUnitImport
keyString | User-defined unique identifier. If a BusinessUnit with this MinLength: key exists, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
unitType | DivisionThe type of Business Unit. |
nameString | The name of the Business Unit. |
status | The status of the Business Unit. |
contactEmailString | The contact email address for the Business Unit. |
associatesArray of AssociateDraft | List of Associates to be assigned to the Business Unit. |
addressesArray of Address | The addresses for the Business Unit. |
shippingAddressesArray of Integer | The indices of the shipping addresses in the addresses array. |
defaultShippingAddressInt | The index of the default shipping address in the addresses array. |
billingAddressesArray of Integer | The indices of the billing addresses in the addresses array. |
defaultBillingAddressInt | The index of the default billing address in the addresses array. |
storesArray of StoreKeyReference | The Stores of the Business Unit. |
storeMode | If Default: Explicit, the stores field cannot be empty and the Business Unit is explicitly associated with the given Stores. If FromParent, the Business Unit inherits the Stores from its parent.FromParent |
parentUnit | The parent Business Unit of this Division. |
associateMode | If Default: Explicit, Associates are not inherited from the parent. If ExplicitAndFromParent, Associates are inherited from the parent.ExplicitAndFromParent |
approvalRuleMode | If Default: Explicit, approval rules are not inherited from the parent. If ExplicitAndFromParent, approval rules are inherited from the parent.ExplicitAndFromParent |
custom | Custom fields for the Business Unit. |
{
"key": "acme-business-unit-division-a",
"name": "ACME Business Unit: Division A",
"unitType": "Division",
"parentUnit": {
"key": "acme-business-unit",
"typeId": "business-unit"
}
}AssociateDraft
Draft for an Associate in a Business Unit.
customer | The Customer to be part of the Business Unit. |
associateRoleAssignmentsArray of AssociateRoleAssignmentDraft | The roles to assign to the Associate. |
AssociateRoleAssignmentDraft
The role of an Associate in a Business Unit.
associateRole | The role to assign to the Associate. |
inheritance | Determines whether the AssociateRole is inherited. If Disabled, the AssociateRole is not inherited from a parent Business Unit. |
for Categories
CategoryImport
keyString | User-defined unique identifier. If a Category with this MinLength: key exists, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
externalIdString | Maps to Category.externalId. |
name | Maps to Category.name. |
slug | Maps to Category.slug. Must match the pattern ^[A-Za-z0-9_-]{2,256}+$. |
description | Maps to Category.description. |
parent | Maps to Category.parent. If the referenced Category does not exist, the state of the ImportOperation will be set to unresolved until the referenced Category is created. |
orderHintString | Maps to Category.orderHint. |
metaTitle | Maps to Category.metaTitle. |
metaDescription | Maps to Category.metaDescription. |
metaKeywords | Maps to Category.metaKeywords. |
assetsArray of Asset | Maps to Category.assets. |
custom | Maps to Category.custom. |
{
"key": "category-to-import",
"name": {
"en": "Category to import"
},
"slug": {
"en": "category-to-import-slug"
},
"description": {
"en": "Description of category to import"
},
"parent": {
"typeId": "category",
"key": "key-of-parent-category"
}
}for Customers
CustomerImport
keyString | User-defined unique identifier. If a Customer with this MinLength: key exists, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
customerNumberString | Maps to Customer.customerNumber. |
externalIdString | Maps to Customer.externalId. |
emailString | Maps to Customer.email. |
passwordString | Maps to Customer.password. Required when authenticationMode is set to Password. This field is only used when creating new Customers, and is ignored when updating Customers. However, due to the Import API's upsert behavior, a non-empty value must still be provided when updating Customers. |
storesArray of StoreKeyReference | Maps to Customer.stores. If the referenced Stores do not exist, the state of the ImportOperation will be set to unresolved until the referenced Stores are created. |
firstNameString | Maps to Customer.firstName. |
lastNameString | Maps to Customer.lastName. |
middleNameString | Maps to Customer.middleName. |
titleString | Maps to Customer.title. |
salutationString | Maps to Customer.salutation. |
dateOfBirthDate | Maps to Customer.dateOfBirth. |
companyNameString | Maps to Customer.companyName. |
vatIdString | Maps to Customer.vatId. |
isEmailVerifiedBoolean | Maps to Customer.isEmailVerified. |
customerGroup | Maps to Customer.customerGroup. If the referenced CustomerGroup does not exist, the state of the ImportOperation will be set to unresolved until the referenced CustomerGroup is created. |
addressesArray of CustomerAddress | Maps to Customer.addresses. |
defaultBillingAddressInt | 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. |
billingAddressesArray of Integer | Indices of the billing addresses in the addresses array. The billingAddressIds of the Customer will be set to the id of these addresses. |
defaultShippingAddressInt | The index of the address in the addresses array. The defaultShippingAddressId of the Customer will be set to the id of that address. |
shippingAddressesArray of Integer | Indices of the shipping addresses in the addresses array. The shippingAddressIds of the Customer will be set to the id of these addresses. |
localeString | Maps to Pattern: Customer.locale.^[a-zA-Z]{2,3}(?:-[a-zA-Z]{4})?(?:-(?:[a-zA-Z]{2}|d{3}))?$ |
authenticationMode |
Password |
custom | Maps to Customer.custom. |
{
"key": "customer-to-import",
"customerNumber": "12345",
"email": "john@example.com",
"password": "D0cEx@mpl3!2025",
"firstName": "John",
"lastName": "Doe",
"dateOfBirth": "1980-01-01",
"isEmailVerified": false,
"externalId": "external-id-123",
"customerGroup": {
"typeId": "customer-group",
"key": "customer-group-key"
},
"addresses": [
{
"key": "john-doe-address-key",
"streetName": "Main Street",
"streetNumber": "123",
"postalCode": "12345",
"city": "Berlin",
"country": "DE"
}
],
"authenticationMode": "Password"
}CustomerAddress
keyString | User-defined identifier for the address. Must be unique per customer. MinLength:2MaxLength: 256Pattern: ^[a-zA-Z0-9_-]{2,256}$ |
externalIdString | ID for the contact used in an external system. |
country | Name of the country. Pattern:^[A-Z]{2}$ |
titleString | Title of the contact, for example 'Dr.' |
salutationString | Salutation of the contact, for example 'Mr.' or 'Ms.' |
firstNameString | Given name (first name) of the contact. |
lastNameString | Family name (last name) of the contact. |
streetNameString | Name of the street. |
streetNumberString | Street number. |
additionalStreetInfoString | Further information on the street address. |
postalCodeString | Postal code. |
cityString | Name of the city. |
regionString | Name of the region. |
stateString | Name of the state, for example, Colorado. |
companyString | Name of the company. |
departmentString | Name of the department. |
buildingString | Number or name of the building. |
apartmentString | Number or name of the apartment. |
pOBoxString | Post office box number. |
phoneString | Phone number of the contact. |
mobileString | Mobile phone number of the contact. |
emailString | Email address of the contact. |
faxString | Fax number of the contact. |
additionalAddressInfoString | Further information on the Address. |
custom | Custom Fields for the address. |
{
"key": "john-doe-address-key",
"streetName": "Main Street",
"streetNumber": "123",
"postalCode": "12345",
"city": "Berlin",
"country": "DE"
}for Discount Codes
DiscountCodeImport
keyString | User-defined unique identifier. If a DiscountCode with this MinLength: key exists, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
name | Maps to DiscountCode.name. |
description | Maps to DiscountCode.description. |
codeString | Maps to DiscountCode.code. This value cannot be updated. Attempting to update this value will result in an InvalidFieldsUpdate error. |
cartDiscountsArray of CartDiscountKeyReference | Maps to DiscountCode.cartDiscounts. If the referenced CartDiscounts do not exist, the state of the ImportOperation will be set to unresolved until the referenced CartDiscounts are created. |
cartPredicateString | Maps to DiscountCode.cartPredicate. |
isActiveBoolean | Maps to DiscountCode.isActive. |
maxApplicationsInt | Maps to DiscountCode.maxApplications. |
maxApplicationsPerCustomerInt | Maps to DiscountCode.maxApplicationsPerCustomer. |
groupsArray of String | Maps to DiscountCode.groups. |
validFrom | Maps to DiscountCode.validFrom. |
validUntil | Maps to DiscountCode.validUntil. |
custom | Maps to DiscountCode.custom. |
{
"key": "discountCodeKey",
"code": "Save10",
"name": {
"en": "Save10"
},
"cartDiscounts": [
{
"typeId": "cart-discount",
"key": "cartDiscountKey"
}
],
"isActive": false,
"groups": []
}for Inventory
InventoryImport
keyString | User-defined unique identifier. If an InventoryEntry with this MinLength: key exists, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
skuString | Maps to InventoryEntry.sku |
quantityOnStockInt | Maps to InventoryEntry.quantityOnStock |
restockableInDaysInt | Maps to InventoryEntry.restockableInDays |
expectedDelivery | Maps to InventoryEntry.expectedDelivery |
supplyChannel | Maps to InventoryEntry.supplyChannel. If the referenced Channel does not exist, the state of the ImportOperation will be set to unresolved until the referenced Channel is created. |
custom | Maps to InventoryEntry.custom. |
{
"key": "inventory-import-key",
"sku": "product-variant-sku",
"quantityOnStock": 15,
"restockableInDays": 2,
"expectedDelivery": "2022-06-30T14:00:00.000Z",
"supplyChannel": {
"typeId": "channel",
"key": "channel-key"
}
}for Product Types
ProductTypeImport
keyString | User-defined unique identifier. If a ProductType with this MinLength: key exists, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
nameString | Maps to ProductType.name. |
descriptionString | Maps to ProductType.description. |
attributesArray of AttributeDefinition | The attributes of ProductType. |
{
"key": "product-type-key",
"name": "Product Type name",
"description": "Test product type",
"attributes": [
{
"name": "product-ref-attribute",
"label": {
"en": "selling product"
},
"isRequired": false,
"isSearchable": false,
"type": {
"name": "reference",
"referenceTypeId": "category"
},
"attributeConstraint": "Unique",
"inputTip": {
"en": "product input tip"
},
"inputHint": "SingleLine"
}
]
}for Products
When updating existing Products by import, you must include the existing values of the Product. The import process will remove the values of omitted fields.
ProductImport
This is the minimal representation required for creating a Product in Composable Commerce.
keyString | User-defined unique identifier. If a Product with this MinLength: key exists, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
name | Maps to ProductData.name. |
productType | Maps to Product.productType. If the referenced ProductType does not exist, the state of the ImportOperation will be set to unresolved until the referenced ProductType is created. |
slug | Maps to ProductData.slug. |
description | Maps to ProductData.description. |
categoriesArray of CategoryKeyReference | Maps to ProductData.categories. If the referenced Categories do not exist, the state of the ImportOperation will be set to unresolved until the referenced Categories are created. |
attributesArray of Attribute | |
metaTitle | Maps to ProductData.metaTitle. |
metaDescription | Maps to ProductData.metaDescription. |
metaKeywords | Maps to ProductData.metaKeywords. |
taxCategory | Maps to Product.taxCategory. If the referenced TaxCategory does not exist, the state of the ImportOperation will be set to unresolved until the referenced TaxCategory is created. |
searchKeywords | Maps to ProductData.searchKeywords. |
state | Maps to Product.state. If the referenced State does not exist, the state of the ImportOperation will be set to unresolved until the referenced State is created. |
publishBoolean | Determines the published status and current/staged projection of the Product. For more information, see Managing the published state of Products. Default: false |
priceMode | Maps to Product.priceMode. |
{
"key": "product-key",
"name": {
"en": "t-shirt"
},
"productType": {
"typeId": "product-type",
"key": "product-type-key"
},
"slug": {
"en": "t-shirt-slug"
},
"description": {
"en": "t-shirt-description"
},
"categories": [
{
"typeId": "category",
"key": "category-key"
}
],
"taxCategory": {
"typeId": "tax-category",
"key": "tax-category-key"
},
"state": {
"typeId": "state",
"key": "state-key"
}
}ProductDraftImport
The representation of a Product Draft for the import purpose.
keyString | User-defined unique identifier. If a Product with this MinLength: key exists, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
productType | Maps to Product.productType. If the referenced ProductType does not exist, the state of the ImportOperation will be set to unresolved until the referenced ProductType is created. |
name | Maps to ProductData.name. |
slug | Maps to ProductData.slug. |
description | Maps to ProductData.description. |
categoriesArray of CategoryKeyReference | Maps to ProductData.categories. If the referenced Categories do not exist, the state of the ImportOperation will be set to unresolved until the referenced Categories are created. |
attributesArray of Attribute | |
metaTitle | Maps to ProductData.metaTitle. |
metaDescription | Maps to ProductData.metaDescription. |
metaKeywords | Maps to ProductData.metaKeywords. |
masterVariant | The master ProductVariant.
Required if variants contains at least one ProductVariant. |
variantsArray of ProductVariantDraftImport | An array of related ProductVariants. |
taxCategory | Maps to Product.taxCategory. If the referenced TaxCategory does not exist, the state of the ImportOperation will be set to unresolved until the referenced TaxCategory is created. |
searchKeywords | Maps to ProductData.searchKeywords. |
state | Maps to Product.state. If the referenced State does not exist, the state of the ImportOperation will be set to unresolved until the referenced State is created. |
publishBoolean | Determines the published status and current/staged projection of the Product. For more information, see Managing the published state of Products. Default: false |
priceMode | Maps to Product.priceMode. If not provided, the existing Product.priceMode is not changed. |
{
"key": "product-draft-key",
"name": {
"en": "blue shirt"
},
"slug": {
"en": "blue-t-shirt"
},
"productType": {
"typeId": "product-type",
"key": "sample"
},
"masterVariant": {
"key": "master-variant-key",
"attributes": [
{
"type": "reference",
"name": "product-ref-attribute",
"value": {
"key": "category-key",
"typeId": "category"
}
},
{
"type": "reference",
"name": "product-custom-object-ref-attribute",
"value": {
"key": "custom-object-key",
"container": "custom-object-container-key",
"typeId": "key-value-document"
}
}
]
}
}ProductVariantDraftImport
The representation of a Product Variant Draft for the import purpose.
keyString | User-defined unique identifier for the ProductVariant. |
skuString | User-defined unique SKU of the Product Variant. |
pricesArray of PriceDraftImport | 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). |
attributesArray of Attribute | Attributes according to the respective AttributeDefinition. |
imagesArray of Image | Images for the Product Variant. |
assetsArray of Asset | Media assets for the Product Variant. |
EmbeddedPriceDraftImport
The representation of a Price Draft for the import purpose.
keyString | User-defined unique identifier for the Embedded Price. MinLength:2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
value | Money value of this Price. |
country | Set this field if this Price is only valid for the specified country. Pattern:^[A-Z]{2}$ |
customerGroup | Set this field if this Price is only valid for the referenced CustomerGroup. If the referenced CustomerGroup does not exist, the state of the ImportOperation will be set to unresolved until the referenced CustomerGroup is created. |
channel | Set this field if this Price is only valid for the referenced ProductDistribution Channel. If the referenced Channel does not exist, the state of the ImportOperation will be set to unresolved until the referenced Channel is created. |
validFrom | Set this field if this Price is only valid from the specified date and time. Must be at least 1 ms earlier than validUntil. |
validUntil | Set this field if this Price is only valid until the specified date and time. Must be at least 1 ms later than validFrom. |
discounted | Set this field to add a DiscountedPrice from an external service. |
tiersArray of PriceTier | The tiered prices for this price. |
custom | Custom Fields for the Embedded Price. |
for Product Variants
ProductVariantImport
keyString | User-defined unique identifier. If a ProductVariant with this key exists on the specified product, it is updated with the imported data. |
skuString | Maps to ProductVariant.sku. |
isMasterVariantBoolean |
|
attributesArray of Attribute | Maps to ProductVariant.attributes.
The referenced attribute must be defined in an already existing ProductType in the project, or the state of the ImportOperation will be unresolved. |
imagesArray of Image | Maps to ProductVariant.images. |
assetsArray of Asset | Maps to ProductVariant.assets. |
stagedBoolean |
true |
product | The Product containing this ProductVariant. If the referenced Product does not exist, the state of the ImportOperation will be set to unresolved until the referenced Product is created. |
{
"key": "red-t-shirt",
"sku": "red-t-shirt",
"product": {
"key": "t-shirt",
"typeId": "product"
},
"isMasterVariant": true,
"attributes": [
{
"name": "new",
"type": "boolean",
"value": true
},
{
"name": "weight",
"type": "number",
"value": 12.5
}
]
}Attribute
name- String - Optional
Required if used for ProductVariantImport. Must not be set when used for ProductVariantPatch. Must matchnameof an AttributeDefinition of the ProductType.type- String - Optional
Required if used for ProductVariantImport. Must not be set when used for ProductVariantPatch. Must matchtypeof an AttributeDefinition of the ProductType.value- Required
The actual value of the Attribute compliant to thetype, see specific Attribute types in this section.
type field and value should be an array of Attributes.
For an example, see the Handling Structured and Nested Product Data tutorial.BooleanAttribute
This type represents an attribute whose value is either "true" or "false".
typeString | "boolean"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueBoolean | true or false |
BooleanSetAttribute
This type represents an attribute whose value is set of boolean values.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "boolean-set"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueArray of Boolean | A set of boolean values. |
DateAttribute
This type represents an attribute whose value is a date.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "date"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueDate | A date in the format YYYY-MM-DD. |
DateSetAttribute
This type represents an attribute whose value is a set of dates.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "date-set"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueArray of Date | A set of dates in the format YYYY-MM-DD. |
DateTimeAttribute
This type represents an attribute whose value is a date with time.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "datetime"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
value | A date with time in the format YYYY-MM-DDTHH:mm:ss.SSSZ.
The time zone is optional and defaults to UTC if not specified.
If the time zone is specified, it must be in the format ±HH:mm or Z for UTC. |
DateTimeSetAttribute
This type represents an attribute whose value is a set of dates with time.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "datetime-set"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueArray of DateTime | A set of dates with time in the format YYYY-MM-DDTHH:mm:ss.SSSZ.
The time zone is optional and defaults to UTC if not specified.
If the time zone is specified, it must be in the format ±HH:mm or Z for UTC. |
EnumAttribute
This type represents an attribute whose value is an enum. The attribute value refers to the key of the enum value.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "enum"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueString | The key of the enum value.
Must match the key of an AttributePlainEnumValue in the Product Type. |
EnumSetAttribute
This type represents an attribute whose value is an enum. The attribute value refers to the key of the enum value.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "enum-set"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueArray of String | A set of enum values, each represented by its key.
Each key must match the key of an AttributePlainEnumValue in the Product Type. |
LocalizableEnumAttribute
This type represents an attribute whose value is a localized enum. The attribute value refers to the key of the enum value.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "lenum"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueString | The key of the localized enum value.
Must match the key of an AttributeLocalizedEnumValue in the Product Type. |
LocalizableEnumSetAttribute
This type represents an attribute whose value is a localized enum. The attribute value refers to the key of the enum value.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "lenum-set"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueArray of String | A set of localized enum values, each represented by its key.
Each key must match the key of an AttributeLocalizedEnumValue in the Product Type. |
LocalizableTextAttribute
This type represents an attribute whose value is a localized text.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "ltext"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
value | A localized string. |
LocalizableTextSetAttribute
This type represents an attribute whose value is a localized text.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "ltext-set"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueArray of LocalizedString | A set of localized strings. |
MoneyAttribute
This type represents an attribute whose value is a money object.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "money"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
value | A money value in cent precision format. |
MoneySetAttribute
This type represents an attribute whose value is a set of money objects.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "money-set"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueArray of TypedMoney | A set of money values in cent precision format. |
NumberAttribute
This type represents an attribute whose value is a number.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "number"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueFloat | A number value. Can be an integer or a floating-point number. |
NumberSetAttribute
This type represents an attribute whose value is a set of numbers.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "number-set"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueArray of Number | A set of number values. Each value can be an integer or a floating-point number. |
ReferenceAttribute
This type represents an attribute whose value is a key reference.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "reference"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
value | References a resource by key. |
{
"type": "reference",
"name": "product-custom-object-ref-attribute",
"value": {
"key": "custom-object-key",
"container": "custom-object-container",
"typeId": "key-value-document"
}
}ReferenceSetAttribute
This type represents an attribute whose value is a set of references.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "reference-set"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueArray of KeyReference | A set of references, each referencing a resource by key. Each reference must match the key of an existing resource in the project. |
TextAttribute
This type represents an attribute whose value is a string.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "text"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueString | A text value. |
TextSetAttribute
This type represents an attribute whose value is a set of strings.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "text-set"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueArray of String | A set of text values. |
TimeAttribute
This type represents an attribute whose value is a time.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "time"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueTime | A time value in the format HH:mm:ss.SSS.
The time zone is optional and defaults to UTC if not specified.
If the time zone is specified, it must be in the format ±HH:mm or Z for UTC. |
TimeSetAttribute
This type represents an attribute whose value is a set of times.
nameString | Required if used for ProductVariantImport.
Must not be set if used for ProductVariantPatch.
Must match name of an AttributeDefinition of the Product Type. |
typeString | "time-set"Must match type of an AttributeDefinition of the Product Type.
The type is required if this type is used in a product variant and must not be set when
used in a product variant patch. |
valueArray of Time-only | A set of time values in the format HH:mm:ss.SSS.
The time zone is optional and defaults to UTC if not specified.
If the time zone is specified, it must be in the format ±HH:mm or Z for UTC. |
ProductVariantPatch
productVariant | Reference to the ProductVariant to update. |
attributes | Maps to
ProductVariant.attributes.
|
stagedBoolean | If Default: false, the attribute changes are applied to both current and staged projected representations of the Product.true |
product | Reference to the Product that contains the ProductVariant.
We recommend to set this value to minimize concurrency errors.
If set, this field is required for every ProductVariantPatch in the ProductVariantPatchRequest.
If the referenced Product does not exist, the state of the ImportOperation will be set to unresolved until the referenced Product is created. |
{
"productVariant": {
"typeId": "product-variant",
"key": "red-t-shirt"
},
"attributes": {
"attribute-to-update": {
"type": "boolean",
"value": true
},
"name-of-attribute-to-delete": null,
"name-of-localized-attribute-to-update": {
"type": "ltext",
"value": {
"en": "Existing field",
"es": null,
"de": "Updating field"
}
},
"name-of-localized-attribute-set-to-update": {
"type": "ltext-set",
"value": [
{
"en": "Existing field",
"es": null,
"de": "Updating field",
"br": "New field"
},
{
"en": "Another Existing field",
"es": null,
"de": "Another Updating field",
"br": "Another New field"
}
]
}
},
"staged": false
}for Product Selections
ProductSelectionImport
keyString | User-defined unique identifier. If an ProductSelection with this key exists, it is updated with the imported data. |
name | Maps to ProductSelection.name. |
mode | Maps to Default: ProductSelection.mode.Individual |
assignmentsArray of ProductSelectionAssignment | List of product assignments. |
custom | Maps to ProductSelection.custom. |
ProductSelectionAssignment
An assignment of a product and either variantSelection or variantExclusion (not both).
product | Reference to the Product by key. |
variantSelectionVariantSelection | Variant selection specifying included SKUs. |
variantExclusionVariantExclusion | Variant exclusion specifying excluded SKUs. |
VariantSelectionType
Defines how variants are selected for the product.
includeOnlyOnly the specified SKUs are included.
includeAllExceptAll variants except the specified SKUs are included.
for Prices
EmbeddedPriceImport
keyString | User-defined unique identifier for the Embedded Price. If a Price with this MinLength: key exists on the specified productVariant, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
value | Maps to Price.value. |
country | Maps to Pattern: Price.county.^[A-Z]{2}$ |
validFrom | Maps to Price.validFrom. |
validUntil | Maps to Price.validUntil. |
customerGroup | Maps to Price.customerGroup. If the referenced CustomerGroup does not exist, the state of the ImportOperation will be set to unresolved until the referenced CustomerGroup is created. |
channel | Maps to Price.channel. If the referenced Channel does not exist, the state of the ImportOperation will be set to unresolved until the referenced Channel is created. |
discounted | Sets a discounted price from an external service. |
stagedBoolean |
true |
tiersArray of PriceTier | The tiered prices for this price. |
productVariant | The ProductVariant which contains this Embedded Price. If the referenced ProductVariant does not exist, the state of the ImportOperation will be set to unresolved until the referenced ProductVariant is created. |
product | The Product which contains the productVariant. If the referenced Product does not exist, the state of the ImportOperation will be set to unresolved until the referenced Product is created. |
custom | Maps to Price.custom. |
{
"key": "price-key",
"country": "DE",
"validFrom": "2021-04-11T14:00:00.000Z",
"validUntil": "2022-04-11T14:00:00.000Z",
"customerGroup": {
"typeId": "customer-group",
"key": "customer-group-key"
},
"channel": {
"typeId": "channel",
"key": "channel-key"
},
"productVariant": {
"typeId": "product-variant",
"key": "red-t-shirt"
},
"product": {
"typeId": "product",
"key": "t-shirt"
},
"value": {
"type": "centPrecision",
"currencyCode": "EUR",
"centAmount": 300
}
}StandalonePriceImport
keyString | User-defined unique identifier for the StandalonePrice. If a StandalonePrice) with this MinLength: key exists, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
skuString | Maps to StandalonePrice.sku. This value is not validated to exist in Product Variants. |
value | Maps to StandalonePrice.value. |
country | Maps to Pattern: StandalonePrice.country. This value cannot be updated. Attempting to update this value will result in an InvalidFieldsUpdate error.^[A-Z]{2}$ |
customerGroup | Maps to
StandalonePrice.customerGroup. If the referenced CustomerGroup does not exist, the state of the ImportOperation will be set to unresolved until the referenced CustomerGroup is created.This value cannot be updated. Attempting to update this value will result in an InvalidFieldsUpdate error. |
channel | Maps to
StandalonePrice.channel. If the referenced Channel does not exist, the state of the ImportOperation will be set to unresolved until the referenced Channel is created.This value cannot be updated. Attempting to update this value will result in an InvalidFieldsUpdate error. |
validFrom | Maps to StandalonePrice.validFrom. |
validUntil | Maps to StandalonePrice.validUntil. |
tiersArray of PriceTier | Maps to StandalonePrice.tiers. |
discounted | Sets a discounted price for this Price that is different from the base price with value. |
custom | Maps to StandalonePrice.custom. |
{
"key": "standalone-price-key",
"sku": "variantSku",
"value": {
"type": "centPrecision",
"currencyCode": "EUR",
"centAmount": 100
}
}for Orders
OrderImport
An OrderImport is a snapshot of an order at the time it was imported.
orderNumberString | Maps to Order.orderNumber, String that uniquely identifies an order. It should be unique across a project. Once it's set it cannot be changed. |
customer | key of the Customer that the Order belongs to. If the referenced Customer does not exist, the state of the ImportOperation will be set to unresolved until the referenced Customer is created. |
customerEmailString | Maps to Order.customerEmail. |
lineItemsArray of LineItemImportDraft | Maps to Order.lineItems. |
customLineItemsArray of CustomLineItemDraft | Maps to Order.customLineItems |
totalPrice | Maps to Order.totalPrice. |
taxedPriceTaxedPrice | Maps to Order.taxedPrice. |
shippingAddress | Maps to Order.shippingAddress. |
billingAddress | Maps to Order.billingAddress. |
customerGroup | Maps to Order.customerGroup. If the referenced CustomerGroup does not exist, the state of the ImportOperation will be set to unresolved until the referenced CustomerGroup is created. |
countryString | Maps to Order.country. |
orderState | Maps to Order.orderState. |
shipmentState | Maps to Order.shipmentState. |
paymentState | Maps to Order.paymentState. |
shippingInfo | Maps to Order.shippingInfo. |
completedAt | Maps to Order.completedAt. |
inventoryMode | Maps to Order.inventoryMode. |
taxRoundingMode | Maps to Order.taxRoundingMode. |
taxCalculationMode | Maps to Order.taxCalculationMode. |
origin | Maps to Order.origin. |
itemShippingAddressesArray of Address | Maps to Order.itemShippingAddresses. |
store | Maps to Order.store. If the referenced Store does not exist, the state of the ImportOperation will be set to unresolved until the referenced Store is created. |
state | Maps to Order.state. If the referenced State does not exist, the state of the ImportOperation will be set to unresolved until the referenced State is created. |
custom | Maps to Order.custom. |
{
"orderNumber": "order-number",
"customer": {
"typeId": "customer",
"key": "order-customer-key"
},
"lineItems": [
{
"name": {
"en": "abc"
},
"quantity": 10,
"price": {
"value": {
"type": "centPrecision",
"centAmount": 100,
"currencyCode": "EUR"
}
},
"supplyChannel": {
"typeId": "channel",
"key": "supplier-channel-key"
},
"variant": {
"productVariant": {
"typeId": "product-variant",
"key": "product-key"
},
"sku": "variant-sku"
}
}
],
"customerGroup": {
"typeId": "customer-group",
"key": "customer-group-key"
},
"totalPrice": {
"type": "centPrecision",
"currencyCode": "EUR",
"centAmount": 4200
}
}LineItemImportDraft
Represents an individual Line Item in an Order. A line item is a snapshot of a product at the time it was added to the order.
You cannot create an Order that includes line item operations that do not exist in the Project or have been deleted. Products and Product Variants referenced by a line item must already exist in the Project. Product Attributes are merged with Variant Attributes to ensure the full Attribute context of the Product Variant.
product | Maps to LineItem.productId. If the referenced Product does not exist, the state of the ImportOperation will be set to unresolved until the referenced Product is created. |
name | Maps to LineItem.name. |
variant | Maps to ProductVariantImportDraft. |
price | Maps to LineItem.price. |
quantityInt | Maps to LineItem.quantity. |
stateArray of ItemState | Maps to LineItem.state. |
supplyChannel | Maps to LineItem.supplyChannel. If the referenced Channel does not exist, the state of the ImportOperation will be set to unresolved until the referenced Channel is created. |
distributionChannel | Maps to LineItem.distributionChannel. If the referenced Channel does not exist, the state of the ImportOperation will be set to unresolved until the referenced Channel is created. |
taxRateTaxRate | Maps to LineItem.taxRate. |
shippingDetails | Maps to LineItem.shippingDetails. |
custom | Maps to LineItem.custom. |
CustomLineItemDraft
name | Maps to CustomLineItem.name. |
money | Maps to CustomLineItem.money. |
taxedPriceCustomLineItemTaxedPrice | Maps to CustomLineItem.taxedPrice. |
totalPrice | Maps to CustomLineItem.totalPrice. |
slugString | Maps to CustomLineItem.slug. |
quantityInt | Maps to CustomLineItem.quantity. |
stateArray of ItemState | Maps to CustomLineItem.state. |
taxCategory | Maps to CustomLineItem.taxCategory. References a tax category by key. If the referenced TaxCategory does not exist, the state of the ImportOperation will be set to unresolved until the referenced TaxCategory is created. |
taxRateTaxRate | Maps to CustomLineItem.taxRate. |
externalTaxRate | External Tax Rate for the Custom Line Item if the Cart has the External TaxMode. |
discountedPricePerQuantityArray of DiscountedLineItemPriceDraft | Maps to CustomLineItem.discountedPricePerQuantity. |
shippingDetails | Maps to CustomLineItem.shippingDetails. |
LineItemProductVariantImportDraft
productVariant | Maps to ProductVariant.product. If the referenced ProductVariant does not exist, the state of the ImportOperation will be set to unresolved until the referenced ProductVariant is created. |
skuString | Maps to ProductVariantImportDraft.sku. |
pricesArray of LineItemPrice | Maps to ProductVariantImportDraft.prices |
attributesArray of Attribute | Maps to ProductVariantImportDraft.attributes |
imagesArray of Image | Maps to ProductVariantImportDraft.images. |
LineItemPrice
value | Maps to Price.value. |
country | Maps to Pattern: Price.county.^[A-Z]{2}$ |
validFrom | Maps to Price.validFrom. |
validUntil | Maps to Price.validUntil. |
customerGroup | Maps to Price.customerGroup. References a customer group by key. If the referenced CustomerGroup does not exist, the state of the ImportOperation will be set to unresolved until the referenced CustomerGroup is created. |
channel | Maps to Price.channel. References a channel by key. If the referenced Channel does not exist, the state of the ImportOperation will be set to unresolved until the referenced Channel is created. |
discounted | Sets a discounted price from an external service. |
tiersArray of PriceTier | Maps to Price.tiers. |
custom | Maps to Price.custom. |
DiscountedPrice
value | Money value of the discounted price. |
discount | Reference to a ProductDiscount. If the referenced ProductDiscount does not exist, the state of the ImportOperation will be set to unresolved until the referenced ProductDiscount is created. |
DiscountedLineItemPriceDraft
value | Discounted money value. |
includedDiscountsArray of DiscountedLineItemPortion | Discounts to be applied. |
ShippingInfoImportDraft
shippingInfo property. This field is usually populated by the Cart associated with the Order, but when importing Orders you must provide a draft representation as a part of the OrderImport.shippingMethodNameString | Maps to shippingInfo.shippingMethodName. |
price | Maps to shippingInfo.price. |
shippingRate | Used to determine the price. |
taxRateTaxRate | Maps to shippingInfo.taxRate. |
taxCategory | Maps to shippingInfo.taxCategory. If the referenced TaxCategory does not exist, the state of the ImportOperation will be set to unresolved until the referenced TaxCategory is created. |
shippingMethod | Maps to shippingInfo.shippingMethod. If the referenced ShippingMethod does not exist, the state of the ImportOperation will be set to unresolved until the referenced ShippingMethod is created. |
deliveriesArray of Delivery | Maps to shippingInfo.deliveries. You cannot add a DeliveryItem on import, as LineItems and CustomLineItems are not yet referenceable by an id. |
discountedPrice | Maps to shippingInfo.discountedPrice. |
shippingMethodState | Maps to shippingInfo.shippingMethodState. |
OrderPatchImport
orderNumberString | User-defined unique identifier. If an Order with this orderNumber exists, it is updated with the imported data. |
fields | Each field referenced must be defined in an existing Order or the ImportOperationState is set to validationFailed. |
OrderField
Order fields that needs to be added or updated.
addReturnInfo | Maps to Order.returnInfo |
addParcelToDelivery | Maps to Order.delivery |
addDeliveriesArray of DeliveryDraft | Maps to Order.delivery |
removeDelivery | Maps to Order.removeDelivery |
removeParcelFromDelivery | Maps to Order.removeParcelFromDelivery |
setDeliveryAddress | Maps to Order.addressDraft |
setParcelMeasurements | Maps to Order.parcelMeasurements |
setParcelTrackingData | Maps to Order.parcelTrackingData |
setParcelItemsArray of ParcelItems | Maps to Order.parcelItems |
ReturnInfo
itemsArray of ReturnItemDraft | Information on the Line Items or Custom Line Items returned. |
returnTrackingIdString | User-defined identifier to track the return. |
returnDate | Date and time (UTC) the return is initiated. |
DeliveryParcel
deliveryIdString | Unique identifier of the Delivery. |
measurements | Information about the dimensions of the Parcel. |
trackingData | Shipment tracking information of the Parcel. |
itemsArray of DeliveryItem | Line Items or Custom Line Items delivered in this Parcel. |
DeliveryItem
idString | |
quantityInt | Number of Line Items or Custom Line Items delivered. |
DeliveryDraft
itemsArray of DeliveryItem | Line Items or Custom Line Items to deliver. It can also be specified individually for each Parcel. |
address | Address to which the Parcels are delivered. |
parcelsArray of DeliveryParcelDraft | Information regarding the appearance, content, and shipment of a parcel. |
DeliveryParcelDraft
measurements | Information about the dimensions for the Parcel. |
trackingData | Shipment tracking information for the Parcel. |
itemsArray of DeliveryItem | Line Items or Custom Line Items delivered in this Parcel. |
DeliveryAddressDraft
deliveryIdString | Unique identifier of the Delivery. |
address | Address to which Parcels are delivered. |
ParcelMeasurement
heightInMillimeterInt | Height of the Parcel. |
lengthInMillimeterInt | Length of the Parcel. |
widthInMillimeterInt | Width of the Parcel. |
weightInGramInt | Weight of the Parcel. |
ParcelMeasurementDraft
parcelIdString | id of an existing Parcel. |
measurements | Information about the dimensions of the Parcel. |
ParcelTrackingData
parcelIdString | id of an existing Parcel. |
trackingData | Information that helps track a Parcel. |
TrackingData
trackingIdString | Identifier to track the Parcel. |
carrierString | Name of the carrier that delivers the Parcel. |
providerString | Name of the provider that serves as facade to several carriers. |
providerTransactionString | Transaction identifier with the provider. |
isReturnBoolean |
|
ParcelItems
parcelIdString | id of an existing Parcel. |
itemsArray of DeliveryItem | Items in the Parcel. |
RemoveDeliveryDraft
idString |
RemoveParcelFromDeliveryDraft
parcelIdString | id of the Parcel to be removed from the Delivery. |
for Custom Types
TypeImport
keyString | User-defined unique identifier for the Type. If a Type with this MinLength: key exists, it is updated with the imported data.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
name | Maps to Type.name. |
description | Maps to Type.description. |
resourceTypeIdsArray of ResourceTypeId | Maps to MinItems: Type.resourceTypeIds. This value cannot be changed after the Type is imported.1 |
fieldDefinitionsArray of FieldDefinition | Maps to Type.fieldDefinitions. |
{
"key": "type-key",
"name": {
"en": "Name of type"
},
"description": {
"en": "Description of type"
},
"resourceTypeIds": [
"customer"
],
"fieldDefinitions": [
{
"type": {
"name": "String"
},
"name": "exampleStringField",
"label": {
"en": "Example string field."
},
"required": false,
"inputHint": "SingleLine"
}
]
}ResourceTypeId
Type.resourceTypeIds.addressassetbusiness-unitcart-discountcategorychannelcustomercustomer-groupcustom-line-itemdiscount-codeinventory-entryline-itemorder- Cart and Order. When a Cart is ordered, the CustomFields need to be copied to the Order. For this reason, the Types for Carts are also valid for Orders, and hence both have the same identifier:
order. order-editorder-deliveryorder-parcelorder-return-itempaymentpayment-interface-interactionproduct-priceproduct-selectionquote- Quote, QuoteRequest and StagedQuote. When a StagedQuote is created, the CustomFields will be copied from the QuoteRequest and when a Quote is created, the CustomFields will be copied from the StagedQuote. For this reason, the Types for Quotes are also valid for QuoteRequests and StagedQuotes, and hence all have the same identifier:
quote. reviewshippingshipping-methodshopping-listshopping-list-text-line-itemstandalone-pricestoretransaction
FieldDefinition
Type.FieldDefinition.type | Data type of the Custom Field to define. |
nameString | Name of the Custom Field to define. Must be unique for a given ResourceTypeId. In case there is a FieldDefinition with the same MinLength: name in another Type, both FieldDefinitions must have the same type. This value cannot be changed after the Type is imported.2MaxLength: 36Pattern: ^[A-Za-z0-9_-]+$ |
label | A human-readable label for the field. |
requiredBoolean | Defines whether the field is required to have a value. This value cannot be changed after the Type is imported. |
inputHint | Provides a visual representation type for this field. It is only relevant for string-based field types like CustomFieldStringType and CustomFieldLocalizedStringType. Default: SingleLine |
TypeTextInputHint
SingleLineHint for GUIs to display the field's content in a single line of text.
MultiLineHint for GUIs to display the field's content over multiple lines of text.
common to Import Resources
Custom Fields
The value representations of Custom Fields defined on Import Resources.
Custom
The representation to be sent to the server when creating a resource with Custom Fields.
type | The Type that provides the field definitions for this object. If the referenced Type does not exist, the state of the ImportOperation will be set to unresolved until the referenced Type is created. |
fields | The Custom Fields of this object. |
FieldContainer
JSON object containing key-value pairs with
- key being the
nameof the Custom Field as defined in the respective FieldDefinition - value - CustomField
{
"example-boolean-field": {
"type": "Boolean",
"value": true
},
"example-localized-string-field": {
"type": "LocalizedString",
"value": {
"en": "English text",
"es": "texto en español"
}
},
"example-datetime-field": {
"type": "DateTime",
"value": "2018-10-14T14:00:00.000Z"
}
}
CustomField
JSON object with two fields:
type: Thenameof the corresponding FieldType.value: The actual value of the Custom Field compliant to thetype, see specific types in this section.
BooleanField
A field with a boolean value.
typeString | "Boolean"The type of this field. |
valueBoolean | true or false |
StringField
A field with a string value.
typeString | "String"The type of this field. |
valueString | A text value. |
"example-string-field": {
"type": "String",
"value": "Some String value"
}
LocalizedStringField
A field with a localized string value.
typeString | "LocalizedString"The type of this field. |
value | A localized string. |
"example-localized-string-field": {
"type": "LocalizedString",
"value": {
"en": "English text",
"es": "texto en español"
}
}
EnumField
A field with an enum value.
typeString | "Enum"The type of this field. |
valueString | The key of the enum value.
Must be a key of one of the CustomFieldEnumValues defined in the CustomFieldEnumType. |
"example-enum-field": {
"type": "Enum",
"value": "key-of-the-enum-value"
}
LocalizedEnumField
A field with a localized enum value.
typeString | "LocalizedEnum"The type of this field. |
valueString | The key of the localized enum value.
Must match the key of a CustomFieldLocalizedEnumValue in the CustomFieldLocalizedEnumType. |
"example-localized-enum-field": {
"type": "LocalizedEnum",
"value": "key-of-the-localized-enum-value"
}
NumberField
A field with a number value.
typeString | "Number"The type of this field. |
valueFloat | A number value. Can be an integer or a floating-point number. |
"example-number-field": {
"type": "Number",
"value": 123
}
MoneyField
A field with a money value.
typeString | "Money"The type of this field. |
value | A money value in cent precision format. |
"example-money-field": {
"type": "Money",
"value": {
"type": "centPrecision",
"currencyCode": "USD",
"centAmount": 124500,
"fractionDigits": 2
}
}
DateField
A field with a date value.
typeString | "Date"The type of this field. |
valueDate | A date in the format YYYY-MM-DD. |
"example-date-field": {
"type": "Date",
"value": "2001-10-12"
}
TimeField
A field with a time value.
typeString | "Time"The type of this field. |
valueTime | A time value in the format HH:mm:ss.SSS.
The time zone is optional and defaults to UTC if not specified.
If the time zone is specified, it must be in the format ±HH:mm or Z for UTC. |
"example-time-field": {
"type": "Time",
"value": "14:00:00.000"
}
DateTimeField
A field with a date time value.
typeString | "DateTime"The type of this field. |
value | A date with time in the format YYYY-MM-DDTHH:mm:ss.SSSZ.
The time zone is optional and defaults to UTC if not specified.
If the time zone is specified, it must be in the format ±HH:mm or Z for UTC. |
"example-datetime-field": {
"type": "DateTime",
"value": "2018-10-14T14:00:00.000Z"
}
ReferenceField
A field with a reference value.
typeString | "Reference"The type of this field. |
value | References a resource by key |
"example-reference-field": {
"type": "Reference",
"value": {
"typeId": "product",
"key": "key-of-a-product"
}
}
BooleanSetField
A field with a boolean set value.
typeString | "BooleanSet"The type of this field. |
valueArray of Boolean | JSON array of boolean values without duplicates. The order of items in the array is not fixed. |
"example-set-of-boolean-field": {
"type": "BooleanSet",
"value": [true, false, true]
}
StringSetField
A field with a string set value.
typeString | "StringSet"The type of this field. |
valueArray of String | JSON array of strings. The order of items in the array is not fixed. |
"example-set-of-string-field": {
"type": "StringSet",
"value": ["Some String value 1", "Some String value 2"]
}
LocalizedStringSetField
A field with a localized string set value.
typeString | "LocalizedStringSet"The type of this field. |
valueArray of LocalizedString | JSON array of localized strings. The order of items in the array is not fixed. |
"example-set-of-localized-string-field": {
"type": "LocalizedStringSet",
"value": [
{
"en": "English text 1",
"es": "texto en español 1"
},
{
"en": "English text 2",
"es": "texto en español 2"
}
]
}
EnumSetField
A field with an enum set value.
typeString | "EnumSet"The type of this field. |
valueArray of String | JSON array of enum values, each represented by its key.
Each key must match the key of a CustomFieldLocalizedEnumValue in the CustomFieldEnumType.
The order of items in the array is not fixed. |
"example-set-of-enum-field": {
"type": "Enum",
"value": ["key-of-enum-value-1", "key-of-enum-value-2", "key-of-enum-value-3"]
}
LocalizedEnumSetField
A field with a localized enum set value.
typeString | "LocalizedEnumSet"The type of this field. |
valueArray of String | JSON array of localized enum values, each represented by its key.
Each key must match the key of an CustomFieldLocalizedEnumValue in the CustomFieldLocalizedEnumType.
The order of items in the array is not fixed. |
"example-set-of-localized-enum-field": {
"type": "Enum",
"value": ["key-of-localized-enum-value-1", "key-of-localized-enum-value-2"]
}
NumberSetField
A field with a number value.
typeString | "NumberSet"The type of this field. |
valueArray of Number | JSON array of integer or floating-point number values. The order of items in the array is not fixed. |
"example-set-of-number-field": {
"type": "NumberSet",
"value": [123, 456]
}
MoneySetField
A field with a money set value.
typeString | "MoneySet"The type of this field. |
valueArray of TypedMoney | JSON array of money values in cent precision format. The order of items in the array is not fixed. |
"example-set-of-money-field": {
"type": "MoneySet",
"value": [
{
"type": "centPrecision",
"currencyCode": "USD",
"centAmount": 124500,
"fractionDigits": 2
},
{
"type": "centPrecision",
"currencyCode": "USD",
"centAmount": 1000,
"fractionDigits": 2
}
]
}
DateSetField
A field with a date set value.
typeString | "DateSet"The type of this field. |
valueArray of Date | JSON array of date values in the format YYYY-MM-DD without duplicates.
The order of items in the array is not fixed. |
"example-set-of-date-field": {
"type": "DateSet",
"value": ["2001-10-12", "2001-10-13"]
}
TimeSetField
A field with a time set value.
typeString | "TimeSet"The type of this field. |
valueArray of Time-only | JSON array of time values in the format HH:mm:ss.SSS.
The time zone is optional and defaults to UTC if not specified.
If the time zone is specified, it must be in the format ±HH:mm or Z for UTC.
The order of items in the array is not fixed. |
"example-set-of-time-field": {
"type": "TimeSet",
"value": ["14:00:00.000", "15:00:00.000"]
}
DateTimeSetField
A field with a date time set value.
typeString | "DateTimeSet"The type of this field. |
valueArray of DateTime | JSON array of date time values in the format YYYY-MM-DDTHH:mm:ss.SSSZ without duplicates.
The time zone is optional and defaults to UTC if not specified.
If the time zone is specified, it must be in the format ±HH:mm or Z for UTC.
The order of items in the array is not fixed. |
"example-set-of-datetime-field": {
"type": "DateTimeSet",
"value": ["2018-10-14T14:00:00.000Z", "2018-10-14T15:00:00.000Z"]
}
ReferenceSetField
A field with a reference set value.
typeString | "ReferenceSet"The type of this field. |
valueArray of KeyReference | JSON array of references, each referencing an existing resource by key. The order of items in the array is not fixed. |
"example-set-of-reference-field": {
"type": "ReferenceSet",
"value": [
{
"typeId": "product",
"key": "key-of-a-product"
},
{
"typeId": "product",
"key": "key-of-a-product"
}
]
}
References
KeyReference
References a resource by key.
keyString | User-defined unique identifier of the referenced resource.
If the referenced resource does not exist, the MinLength: state of the ImportOperation will be set to unresolved until the referenced resource is created.2MaxLength: 256Pattern: ^[A-Za-z0-9_-]+$ |
typeId | Type of referenced resource. |
ReferenceType
Type of referenced resource.
associate-roleReferences an associate role.
business-unitReferences a business unit.
cartReferences a cart.
cart-discountReferences a cart discount.
categoryReferences a category.
channelReferences a channel.
customerReferences a customer.
customer-groupReferences a customer group.
discount-codeReferences a discount code.
key-value-documentReferences a custom object
orderReferences an order.
paymentReferences a payment
priceReferences a price.
productReferences a product.
product-discountReferences a product discount.
product-typeReferences a product type.
product-variantReferences a product variant.
shipping-methodReferences a shipping method.
stateReferences a state.
storeReferences a store.
tax-categoryReferences a tax-category.
typeReferences a type.