pixi

Order Import

After the order has been imported directly from plentyONE, the values are stored in an XML to be shown in pixi Control Center > Import and Export tab. In case order import did not work, values can be changed in the XML and a re-import can be triggered to import the corrected order into pixi.


Structure of the XML

<Order xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<OrderItems>
...
</OrderItems>
<Properties>
...
</Properties>
<AddressRelations>
...
</AddressRelations>
<Addresses>
...
</Addresses>
<Relations>
...
</Relations>
<Amounts>
...
</Amounts>
<EventDates>
...
</EventDates>
<TypeId>1</TypeId>
<PlentyId>26748</PlentyId>
<StatusId>5</StatusId>
<OwnerId>0</OwnerId>
<CreatedAt>2018-03-21T09:20:06+01:00</CreatedAt>
<UpdatedAt>2018-03-21T11:20:11+01:00</UpdatedAt>
<Id>6163</Id>
</Order>


Name of XML tag

pixi Value

Description

OrderItems

Properties

AddressRelations

Addresses

Relations

Amounts

EventDates

TypeId

-

The type ID of the order. pixi imports orders with all types, in case the Support Split Orders channel setting is disabled (0). If enabled, only Delivery orders get imported.

PlentyId

Customer details > General > Cust. Nr.

The plenty ID of the client that the order belongs to

If the channel setting PlentyCustomerNrExternal contains "PlentyID", this value is used for the Cust. Nr. field in pixi Customer Service. Customer ID is mandatory for import when the channel setting is set to "PlentyID".

Id

Orders > Orders > Order External Nr.

Contains the plenty Order ID (Order > Overview)

If there is a value in <Properties><OrderProperty><Value> (for TypeId = 7), then both values are linked with "_" and imported as external order number, e.g.

  • 6163

  • 6163_487-4507687431-848

The maximum length to import is 50 characters.


Back to top

OrderItems

This contains the order items, such as the ordered items, shipping costs, discount voucher.

<OrderItems>
<OrderItem>
<Amounts>
<OrderItemAmount>
...
</OrderItemAmount>
</Amounts>
<Properties>
<OrderItemProperty>
...
</OrderItemProperty>
...
</Properties>
<OrderId>6163</OrderId>
<TypeId>Variation</TypeId>
<ReferrerId>4.01</ReferrerId>
<ItemVariationId>1134</ItemVariationId>
<Quantity>1</Quantity>
<OrderItemName>Profi Nagel-Fräser</OrderItemName>
<ShippingProfileId>0</ShippingProfileId>
<VatField>0</VatField>
<VatRate>19</VatRate>
<Id>10829</Id>
<CreatedAt>2018-03-21T10:32:22+01:00</CreatedAt>
<UpdatedAt>2018-03-21T11:20:10+01:00</UpdatedAt>
</OrderItem>
...
</OrderItem>


Name of XML tag

pixi Value

Description

Amounts

Properties

TypeId

TypeId = 4 or 5: Value is taken from <PriceGross> or <PriceNet>;
Orders > Details > General > Order Header > Voucher amount

TypeId = 6: Value is taken from <PriceGross> or <PriceNet>;
Orders > Details > General > Order Header > Shipping costs

The ID of the order item type

  • VARIATION = 1

  • ITEM_BUNDLE = 2

  • PROMOTIONAL_COUPON = 4

  • GIFT_CARD = 5

  • SHIPPING_COSTS = 6

Other TypIds are not considered on order import.

ReferrerId

Customer details > General > Shop

Based on the channel setting Order Shop ID the order's shop ID is taken from the channel's matching table.

Example:

  • Channel setting "Order Shop ID" is set to "0";
    ShopID is used as referrer

  • Matching table for ShopID contains:
    Original Value (plenty) = "4.01"
    Match Value (pixi) = "MAD"

  • Value "MAD" is used as shop ID for the order

ItemVariationId

-

The ID of the item variation

Usage based on the channel setting InternalItemNumber

Quantity

Orders > Details > Items > Q (quantity)

The quantity.

Based on the channel setting Multiply order qty with order unit the quantity is either mutliplied with the item's packing unit saved in pixi or only the plentyONE quantity is used.

OrderItemName

Orders > Details > Items > Item name

Item name provided by plenty.

If the channel setting Use Item Name from Plenty Order is set to "0", the item name from pixi is used for the order.
If the setting is set to "1", the item name is taken form the order import XML.

VatRate

Orders > Details > Items > VAT %

The vat amount, e.g. 19.0 for 19% VAT.

Id

Item Number External saved to the orderline (not shown in GUI)

OrderItem Id which identifies the item

<Order><Id> and this value are linked with "_" and imported as Item Number External, e.g. 6163_10829

CreatedAt

Orders > Orders > Order Date

Orderline Order Date saved to the orderline (not shown in GUI)

The date at which the order item was created.


Back to top

Amounts

This contains the amounts of the different order items.

<Amounts>
<OrderItemAmount>
<OrderItemId>10829</OrderItemId>
<Currency>EUR</Currency>
<ExchangeRate>1</ExchangeRate>
<IsSystemCurrency>true</IsSystemCurrency>
<PriceOriginalGross>69.99</PriceOriginalGross>
<PriceOriginalNet>58.8151</PriceOriginalNet>
<Surcharge>0</Surcharge>
<Discount>0</Discount>
<IsPercentage>true</IsPercentage>
<PurchasePrice>21.8</PurchasePrice>
<PriceGross>69.99</PriceGross>
<PriceNet>58.8151</PriceNet>
</OrderItemAmount>
</Amounts>


Name of XML tag

pixi Value

Description

OrderItemId

-

OrderItem Id which identifies the item

Currency

-

The currency of the amounts.

ExchangeRate

-

The exchange rate for converting the current currency into the system currency.

IsSystemCurrency

-

Flag that indicates if the current currency is the same as the system currency or not.

PriceOriginalGross

Orders > Details > Items > Gross Price

The original gross price without any surcharges or discounts.

PriceOriginalNet

Orders > Details > Items > Net Price

The original net price without any surcharges or discounts.

Discount

Orders > Details > Items > Discount

The discount can be a percentage or a fixed value.

IsPercentage

Orders > Details > Items > Discount %

Flag that indicates if a discount is given as a percentage or as a fixed value.

PurchasePrice

Supplier Price saved to the orderline (not shown in GUI)

The purchase price of the variation.

PriceGross

Orders > Details > Items > Final Gross Price

Orders > Details > General > Order Header > Voucher amount

Orders > Details > General > Order Header > Shipping costs

The total gross price including surcharges and discount.

Also used for shipping costs and voucher amount if the order type is B2C.

If a voucher code is imported, pixi cuts the voucher code to 50 characters and appends the order ID at the end:

"Summer sale - newsletter coupon for 10 EUR discount on all items“ becomses "Summer sale - newsletter coupon for 10 E..._123456"

PriceNet

Orders > Details > Items > Final Net Price

Orders > Details > General > Order Header > Voucher amount

Orders > Details > General > Order Header > Shipping costs

The total net price including surcharges and discounts

Also used for shipping costs and voucher amount if the order type is B2B.


Back to top

Properties

Values from this are are not used at all when importing the order.

<Properties>
<OrderItemProperty>
<TypeId>1</TypeId>
<Value>1</Value>
<OrderItemId>10829</OrderItemId>
</OrderItemProperty>
<OrderItemProperty>
<TypeId>11</TypeId>
<Value>1000</Value>
<OrderItemId>10829</OrderItemId>
</OrderItemProperty>
...
</Properties>

Back to top

Properties

This part contains general order information, such as shipping vendor, payment type, etc.

<Properties>
<OrderProperty>
<TypeId>3</TypeId>
<Value>9</Value>
<OrderId>6163</OrderId>
</OrderProperty>
<OrderProperty>
<TypeId>4</TypeId>
<Value>fullyPaid</Value>
<OrderId>6163</OrderId>
</OrderProperty>
...
</Properties>


Name of XML tag

pixi Value

Description

TypeId

-

The ID of the property type. The following types are available:

  • WAREHOUSE = 1

  • SHIPPING_PROFILE = 2

  • PAYMENT_METHOD = 3

  • XTERNAL_ORDER_ID = 7

Other TypIds are not considered on order import.

Value

TypeId = 1: Orders > Orders > Location

TypeId = 2: Orders > Details > General > Order Header > Shipping vendor

TypeId = 3: Orders > Details > General > Billing details > Payment

TypeId = 7: Orders > Orders > Order External Nr.

The value of the property. The value depends on the type.

TypeId = 1: If the database setting openTRANS - Use Location from XML is ON, then the location is taken from the channel's matching table.
If it is disabled, use the location ID that is assigned to the country of the shipping address.

TypeId = 2: The shipping vendor is taken from the channel's matching table.

TypeId = 3: The payment type is taken from the channel's matching table.

TypeId = 7: Contains the value from Ext. Order number (Order > Settings) in plenty.
If there is a value, then the value from <Order><Id> and this value are linked with "_" and imported as external order number, e.g.

  • 6163

  • 6163_487-4507687431-848


Back to top

AddressRelations

This contains the customer order's addresses IDs - billing and shipping.

<AddressRelations>
<OrderAddressRelation>
<OrderId>6163</OrderId>
<AddressId>67933</AddressId>
<TypeId>BillingAddress</TypeId>
</OrderAddressRelation>
<OrderAddressRelation>
<OrderId>6163</OrderId>
<AddressId>67933</AddressId>
<TypeId>DeliveryAddress</TypeId>
</OrderAddressRelation>
</AddressRelations>


Name of XML tag

pixi Value

Description

AddressId

-

The ID of the address. Used later on to distinguish between billing and shipping address.

TypeId

-

The type of the address; BillingAddress or DeliveryAddress


Back to top

Addresses

The actual addresses are contained in this part.

<Addresses>
<Address>
<Id>67933</Id>
<Name1/>
<Name2>John</Name2>
<Name3>Doe</Name3>
<Address1>Sunshine Avenue</Address1>
<Address2>1</Address2>
<Address3/>
<PostalCode>8523810025</PostalCode>
<Town>New York</Town>
<CountryId>1</CountryId>
<StateId xsi:type="xsd:long">2</StateId>
<ReadOnly>false</ReadOnly>
<CreatedAt>2018-03-21T11:20:09+01:00</CreatedAt>
<UpdatedAt>2018-03-21T11:20:09+01:00</UpdatedAt>
<Options>
...
</Options>
</Address>
</Addresses>


Name of XML tag

pixi Value

Description

Id

-

The ID of the address. Used later on to distinguish between billing and shipping address.

Name1

Orders > Details > General > Billing / Shipping details > Company

The name 1 field (default: company name)

Name2

Orders > Details > General > Billing / Shipping details > Mr/Mrs > 2nd field (first name)

The name 2 field (default: first name)

Name3

Orders > Details > General > Billing / Shipping details > Mr/Mrs > 3rd field (last name)

The name 3 field (default: last name)

Address1

Orders > Details > General > Billing / Shipping details > Street/Nr. > 1st field (street)

The address 1 field (street|packstation|post office)

Address2

Orders > Details > General > Billing / Shipping details > Street/Nr. > 2nd field (house number)

The address 2 field (house no|packstation id), max. 12 characters

Address3

Orders > Details > General > Order Header > Address remarks

The address 3 field (additional)

PostalCode

Details > Billing / Shipping details > ZIP

The postcode

Town

Details > Billing / Shipping details > City

The town

CountryId

Details > Billing / Shipping details > Country

The ID of the country

Options


Back to top

Options

Additional address information such as e-mail address and phone number are stored here.

<Options>
<AddressOption>
<Id>371780</Id>
<AddressId>67933</AddressId>
<TypeId>4</TypeId>
<Value>PhoneNumber</Value>
<Position>0</Position>
<CreatedAt>2018-03-21T11:20:09+01:00</CreatedAt>
<UpdatedAt>2018-03-21T11:20:09+01:00</UpdatedAt>
</AddressOption>
<AddressOption>
<Id>371781</Id>
<AddressId>67933</AddressId>
<TypeId>5</TypeId>
<Value>E-mailAddress</Value>
<Position>0</Position>
<CreatedAt>2018-03-21T11:20:09+01:00</CreatedAt>
<UpdatedAt>2018-03-21T11:20:09+01:00</UpdatedAt>
</AddressOption>
</Options>


Name of XML tag

pixi Value

Description

Id


The ID of the address option

AddressId

-

The ID of the address. Depending on this ID, the values will be put to the billing and/or shipping address.

TypeId

-

The ID of the address option type. The following types are available:

  • VAT Number = 1

  • Phone = 4

  • Email = 5

Value

TypeId = 1: Orders > Details > General > Billing / Shipping details > VAT ID

TypeId = 5: Orders > Details > General > Billing / Shipping details > Phone

TypeId = 4: Orders > Details > General > Billing / Shipping details > E-Mail

The option value.

If the channel setting PlentyCustomerNrExternal contains "CustomerNrExternal", the system does not check for CustomerID values, allowing Plenty 7 customers to import orders without a Customer ID.

E-Mail addresses can be max. 60 characters long.


Back to top

Relations

This part is used to define if the order has the type B2C or B2B.

<Relations>
<OrderRelation>
<OrderId>6163</OrderId>
<ReferenceType>warehouse</ReferenceType>
<ReferenceId>1</ReferenceId>
<RelationName>sender</RelationName>
</OrderRelation>
<OrderRelation>
<OrderId>6163</OrderId>
<ReferenceType>contact</ReferenceType>
<ReferenceId>34742</ReferenceId>
<RelationName>receiver</RelationName>
</OrderRelation>
</Relations>


Name of XML tag

pixi Value

Description

ReferenceId

Orders > Details > General > Order Header > Order type

The reference id.

If this value matches one of the values entered for channel setting B2B Customer Classes IDs, then the order is imported with order type B2B. Otherwise the order type is set to B2C.

RelationName

-

The relation between a reference and an order. The relation types available are the following:

  • sender

  • receiver

If the RelationName is "receiver", check the ReferenceId to determine the order type.


Back to top

Amounts

We use the values from this part to define the order currency and the exchange rate.

<Amounts>
<OrderAmount>
<IsSystemCurrency>true</IsSystemCurrency>
<Currency>EUR</Currency>
<ExchangeRate>1</ExchangeRate>
<IsNet>false</IsNet>
<NetTotal>58.82</NetTotal>
<GrossTotal>69.99</GrossTotal>
<VatTotal>11.17</VatTotal>
<InvoiceTotal>69.99</InvoiceTotal>
<PaidAmount>69.99</PaidAmount>
<Vats>
<OrderVat>
...
</OrderVat>
</Vats>
</OrderAmount>
</Amounts>


Name of XML tag

pixi Value

Description

IsSystemCurrency

-

Flag that states if the current currency is the same as system currency or not.

Currency

Orders > Details > General > Order Header > Currency

The currency of the amounts.

ExchangeRate

Orders > Details > General > Order Header > Exchange rate

The exchange rate for converting the current currency into the system currency.

Vats


Back to top

Vats

Values from this are are not used at all when importing the order.

<Vats>
<OrderVat>
<VatField>0</VatField>
<VatRate>19</VatRate>
<Value>11.17</Value>
</OrderVat>
</Vats>

Back to top

EventDates

Values from this are are not used at all when importing the order.

<EventDates>
<OrderDate>
<OrderId>6163</OrderId>
<TypeId>CreatedOn</TypeId>
<EventDate>2018-03-21T09:20:06+01:00</EventDate>
</OrderDate>
<OrderDate>
<OrderId>6163</OrderId>
<TypeId>PaidDate</TypeId>
<EventDate>2018-03-21T11:20:10+01:00</EventDate>
</OrderDate>
<OrderDate>
<OrderId>6163</OrderId>
<TypeId>LastUpdate</TypeId>
<EventDate>2018-03-21T11:20:11+01:00</EventDate>
</OrderDate>
</EventDates


Back to top

Data Transfer directly through REST API Methods

Besides the above shown data there is some that is not put into XMLs first before they get imported into pixi.
This includes:

  • Order Comments: All comments that have been added to the order in the shop are retrieved using plentyONE REST API GET method /rest/comments/order/{orderId}.
    All comments are put into the Shop Note field in pixi Customer Service > Orders > Details > General > Order Header.


Back to top