fetchOrders

Navigation:  WebService Calls > Basic Integration >

fetchOrders

Previous pageReturn to chapter overviewNext page

Texte ein-/ausblenden

Description

Request orders according a pre-defined workflow adapted for your external system.

 

For additional Growth options see also the full fetchOrders and the related platform specific calls.

 

Request - Sample

Code

Request - Basic Field List

Name

Description

Occ.

Type

Value Info

request

Root-Element of request

1

Element


method

Attribute of request. Name of Webservice-Method.

1

string

fixed value:

„fetchOrders“

version

Attribute of request. Version control of request.

1

integer

fixed value:

„1.0.0“

filter

With filters you define a set of parameters to reduce the number of results. Multiple filters are a OR-Relation. Element with a filter are treated as AND-relations.

1..N

Element


mandator_id

Reduces the results of orders related to a specific mandator ID.

1

Element


filter_method

Attribute of mandator_id. Controls the behavior of the mandator filter.

1

string

fixed value:

„=“

filter_value

Attribute of mandator_id. Defines the value for the filter.

1

integer


export_date

Reduces the results of orders related to the export date.

0..1

Element


filter_method

Attribute of export_date. Reduces results solely by NULL/NOT NULL-values. Controls the behavior of the client filter.

0..1

string

fixed values:

„IS“ |

„IS NOT“

filter_value

Attribute of export_date. Defines the value for the filter.

0..1

string

fixed value:

„NULL“

allow_null

Attribute of export_date. Defines whether zero-values should be considered in the results as well.

0..1

boolean


order_status_id

Reduces the results of orders related to a specific order status. See also notes.

0..1

Element


filter_method

Attribute of order_status_id. Controls the behavior of the order status filter.

1

string

fixed values:

„=“

filter_value

Attribute of order_status_id. Defines the value for the filter.

1

integer

fixed values

payment_method_id

Reduces the results of orders related to a payment method.

0..1

string

length:

0 - 100 characters

filter_method

Attribute of payment_method_id. Controls the behavior of the payment method filter.

1

string

fixed values::

„=“, „like“, „IS“, „IS NOT“

filter_value

Attribute of payment_method_id. Defines the value for the filter.

1

integer

If filter_

method = „IS“ oder „IS NOT“:„NULL“

otherwise as you like.

allow_null

Attribute of payment_method_id. Defines whether NULL values should also be considered in result. Standard value is "false".

0..1

boolean

If filter_

method = "=" oder "like".

complete_status

Reduces the results of orders related to the checkout status.

0..1

Element


filter_method

Attribute of complete_status. Controls the behavior of the complete status filter.

1

string

fixed value:

„=“

filter_value

Attribute of complete_status. Defines the value for the filter. Please see additional Information for each of the values in the notes.

1

integer

fixed values:

1 (=complete)

2 (=pending)

3 (=incomplete)

order_number

Reduces the results of orders related to a specific order number.

Motivation: Error handling, known orders can be requested again.

1

Element

fixed values:

"=", "<>"

filter_method

Attribute of order_number. Controls the behavior of the order number filter.

1

string


filter_value

Attribute of order_number. Defines the value for the filter.

1

integer


order_number_prefix

Reduces the results of orders related to an order_number_prefix.

Motivation: Error handling, known orders can be requested again.

0..1

Element

notes

filter_method

Attribute of order_number_prefix. Controls the behavior of the order number prefix filter.

1

string

fixed value:

„=“

filter_value

Attribute of order_number_prefix.Defines the value for the filter.

1

string


orders_per_page

Number of orders returned per page.

0..1

integer

used in combination with „page“ .

page

Number of page, the orders shall be returned. Omitting „orders_per_page“ and „page“ will return all orders.

0..1

integer

Used in combination with „orders_per_

page“ .

Response - Sample

Code

Response - Basic Field List

Name

Description

Occ.

Type

Value Info

response

Root-Element of request

1

Element


method

Attribute of request. Name of Webservice-Method.

1

string

fixed value:

„fetchOrders“

version

Attribute of request. Version control of request.

1

integer

fixed value:

„1.0.0“

report

Information about the processed operation. Report contains error messages or successful returned orders.

1

Element


return_code

Attribute of report. Contains success or error codes.

1

integer

Return-Codes

total_number_of_pages

Pagination: contains the total number of pages the response contains.

1

integer


total_number_of_entries

Contains the total number of orders.

1

integer


error_description

In case of errors this contains the error description.

0..1

string


order

Wrapper-Element summarizing the data of a single order

0..N

Element


order_id

ID of order

1

integer


mandator_id

ID of client this order belongs to

1

integer


order_number_prefix

Prefix of order

0..1

string


order_number

order number

1

integer


order_date

date of order

1

dateTime


shipping_charge

shipping charge for buyer

0..1

decimal


cash_on_delivery_charge

buyers cost for cash on delivery option

0..1

decimal


payment_method_charge

buyer fee for the payment type selection by buyer | this is the fee the seller can define as a "on top" fee

0..1

decimal


dispatch_type

Wrapper-Element, summarizing shipping type information

0..1

Element


dispatch_type_id

ID of shipping type

1

integer


identifier

identifier of shipping type

1

string


external_id

external ID

1

string


price_type

Wrapper-Element, summarizing the price type information.

1

Element


price_type_id

Element of price_type. ID of price type

1

integer

fixed values:

0 (= net price)

1 (= gross price)

price_type_identifier

Element of price_type. Identifier of price type.

1

string

fixed values:

„net“ |

„gross“

currency_code_iso

currency

0..1

string

ISO CODE z.B. „EUR“

order_notices

Wrapper-Element, summarizing all order notices.

0..1

Element


order_notice

Wrapper-Element, containing an order notice information.

1..N

Element


created_by

user name

1

string


text

notice text

1

string


notice_type

Type of notice.

1

integer

fixed values:

10 (=internal)

20 (=external)

sub_channel

Wrapper-Element, summarizing the Subchannel information.

0..1

Element


sub_channel_identifier

Element of sub_channel. Identifier of subchannel.

1

string

length:

0-50 characters

account

Wrapper-Element, summarizing account information.

0..1

Element


account_identifier

Element of account. Identifier of Account.

1

string

length:

0-50 characters

order_status

Wrapper-Element, summarizing information of the order status.

0..1

Element


order_status_id

Element of order_status. ID of order status.

1

integer

fixed values

 

order_status_identifier

Element of order_status. Identifier of order status

1

string

fixed values

 

payment_method

Wrapper-Element, summarizing information of payment method

0..1

Element


payment_method_id

Element of payment_method. ID of payment method.

1

integer

fixed values

 

payment_method_identifier

Element of payment_method. Identifier of payment method.

1

string

fixed values

 

hold_reason_id

Reason ID of a deferment to temporarily interrupt /pause the order workflow.

0..1

integer


hold_reason

Reason description of a deferment to temporarily interrupt /pause the order workflow

0..1

string


customer_type

Wrapper-Element, summarizing the customer Type information.

0..1

Element


customer_type_id

Element of customer_type. ID of customer type.

1

integer

fixed values:

1 = private

2 =  business

customer_type_identifier

Element of customer_type. Identifier of customer type.

1

string

fixed values:

„business“|

„private“

invoice_address

Wrapper-Element, summarizing the billing address information.

1

Element

For a detailed list of contained fields see Address Field List

shipping_address

Wrapper-Element, summarizing the delivery address information

1

Element

For a detailed list of contained fields see Address Field List

email_address

Email-Address related to billing address

0..1

string

length:

0-100 characters

created_by

user who created the order

0..1

string


transaction_id_1

Payment transaction number to identify payment

0..1

string

length:

0-50 characters

transaction_id_2

A second payment transaction number to identify payment

0..1

string

length:

0-50 characters

tax_id

VAT tax id

0..1

string

length:

0-50 characters

export_date

date, the external system has acknowledged the successful export of this order. It will be set via the call updateOrderStatus

0..1

dateTime


complete_status

Informs about the current "checkout status" of the order. See explanatory notes on each status.

1

integer

fixed values:

1 (=complete)

2 (=pending)

3 (=incomplete)

order_items

Wrapper-Element summarizing information of all order positions of an order.

1

Element


order_item

Wrapper Element, summarizing information of a single order position.

0..N

Element


order_item_identifier

Identifier of order item. For some marketplaces the same order identifier can occur repeatedly. See also the related notes and order_item_position.

1

string

length:

0-200 characters

order_item_position

Order position sequence in order.

1

integer


order_date

Order date of item for this of this order position.

1

dateTime


internal_item_number

internal item number of item related to this order position.

Same internal item number can occur in multiple order positions repeatedly for some marketplaces. See also notes.

0..1

string

length:

0-50 characters

quantity

item quantity of this item position

1

integer


price

sales price per quantity =1

1

decimal


tax_rate

VAT rate for this order position

1

decimal


note

order note

1

string


cancel_date

order cancellation date

0..1

dateTime


tax_collected_by_marketplace

was vat already remitted by the marketplace

1

boolean


tax_collected_by_marketplace_amount

amount of vat remitted by the marketplace

0..1

decimal


discount_value

The discount value of one ordered item.

0..1

decimal

No percentage

initial_order

Wrapper-Element, summarizing the order data of initial order, which is now included in this order (e.g. relevant for regrouping of ebay orders)

0..1

Element


order_id

ID of order

1

integer


mandator_id

client ID this order belongs to

1

integer


order_number_prefix

order number prefix. Builds together with the order number the significant key, when setting used separate order numbers for each channel.

0..1

string


order_number

order number. Significant key to request a specific order again, e.g. for error handling purposes.

1

integer


external_order_number_1

e.g. marketplace order number 1, might be used to identify ebay regrouped orders or for support reasons

0..1

string


external_order_number_2

e.g. marketplace order number 2, might be used to identify ebay regrouped orders or for support reasons

0..1

string


marketplace_order_id

marketplace order ID. Might be used for support reasons

0..1

string


additional_order_item_data

Wrapper-Element for additional order positions information. They will not be processed by Speed4Trade CONNECT and can be passed through from a connected shop to the external system (ERP).

0..1

Element


keyvalueitem

Wrapper-Element, containing addition order information (list) to an order position.

1..N

Element


key

key of information.

1

string


value

value of information.

1

string


order_tags

Wrapper-Element, summarizing the special order codes of an order.

0..1

Element

see note.

order_tag

Wrapper-Element, summarizing a special order code information of an order.

1..64

Element


tag_id

ID of a special order code.

1

integer


tag_identifier

Description of an order code.

1

string


additional_order_data

Wrapper-Element for an additional order position information. They will not be processed by Speed4Trade CONNECT and can be passed through from a connected shop to the external system (e.g. the ERP).

0..1

Element


keyvalueitem

Wrapper-Element of an additional order information.

1..N

Element


key

key of information.

1

string


value

value of information.

1

string


payment_instructions

Wrapper-Element, summarizing all payment instructions and notes.

0..1

Element


payment_instruction

Wrapper-Element, summarizing the information of a single payment instruction or note.

1..N

Element


payment_instruction_id

ID required to update or delete an existing payment instruction or note.

1

integer


order_id

ID of order this payment instruction belongs to.

1

integer


external_id

External ID of payment instruction.

1

string


recipient

Payment recipient (e.g. for purchase on account) , needs to be printed on an invoice

1

string


iban

bank account number

1

string


bic

bank code

1

string


bank_name

name of bank

1

string


payment_reason

payment reason

1

string


note_to_buyer

note to buyer

1

string


url

contains link

1

string


transaction_number

transaction number

1

string


receipt_printing

Document (e.g. invoice) printing required?

1

boolean


read_only

Flag to indicate whether payment instruction can be updated or deleted.

Only manually created Payment instructions can be updated.

1

boolean


amount

amount

1

decimal


currency_code_iso

currency

1

string

ISO CODE e.g. „EUR“

due_date

due date of payment

1

date


marketplace_user_name

User (buyer) name on marketplace at the time of purchase.

0..1

string

see notes.

anonymizations

Wrapper-Element, summarizing every anonymization process the order was part of.

0..1

Element


anonymization

Wrapper-Element, summarizing one anonymization process.

1

Element


date

Date of the anonymization

1

dateTime


configuration

Identifier of the active and assigned configuration

1

string


Value Tables

Value Table - for Field: order_status

order_status_id

order_status_identifier

note

10

new

new order | Neuer Auftrag

120

outstanding payment

order confirmed - waiting for payment | Auftrag bestätigt. Wartet auf Bezahlung.

130

paid shipping

order payed - ship now | Bezahlt. Versenden.

140

shipped complete

shipped - order completed | Versendet. Abgeschlossen.

220

confirmed shipping

ship now | Bestätigt Versenden

230

shipped outstanding

shipped - waiting for incoming payment | Versendet. Wartet auf Bezahlung

240

paid complete

paid - order completed | Bezahlt. Abgeschlossen.

320

confirmed pickup

order confirmed - waiting for order collection | Bestätigt. Wartet auf Abholung.

330

pickedup completed

collected by buyer - order completed | Abgeholt. Abgeschlossen.

985

regrouped

regrouped order | Umgruppiert

990

canceled

canceled order | Storniert

995

back order

temporary backordered | Auftragsrückstand

Value Table - for field: payment_method.

payment_method_id

identifier

note

Workflow

1

prepay

advance payment | Vorkasse

1

2

credit card

Kreditkarte

1

3

cash on delivery

Nachnahme

2

4

invoice

Rechnung

2

5

cash

Bar

3

6

debit

Bankeinzug

2

7

giropay

Giropay

1

8

paypal

Pay Pal

1

9

finance

Finanzierung

1

10

sofortueberweisung

pay now | Sofortüberweisung

1

11

marketplace payment

payment by marketplace | Zahlabwicklung über Marktplatz

2

12

billsafe (deprecated)

BillSAFE (deprecated)

2

13

klarna invoice

Klarna Rechnung

2

14

klarna account

hire-purchase | Klarna Ratenkauf

2

15

amazon pay

Amazon Pay

2

16

RatePAY

RatePAY

2

20

eBay Payment

eBay Payment

1

60

Mollie

mollie

1

Address Fieldlist

Address Field List used for several address occurances.

Name

Beschreibung

Anz.

Typ

sonstiges

address_id

ID of Address

0..1

integer


salutation_id

Element of salutation. ID of salutation.

1

integer

fixed values:

1 (= Mr | Herr)

2 (= Mrs |Frau)

3 (= Business | Firma)

salutation_identifier

Element of salutation. Identifier of salutation.

1

string

fixed values:

„mr“ | „ms“ | „business“

firm

Company name of buyer.

0..1

string

Length:

0 – 200 characters

title

Titel of Customer

0..1

string

Length:

0 – 100 characters

first_name

first name

0..1

string

Length:

0 – 100 characters

last_name

last name

0..1

string

Length:

0 – 200 characters

street

street name

0..1

string

Length:

0 – 200 characters

house_number

street number

0..1

string

Length:

0 – 50 characters

street_addition

Additional address information (e.g. c/o Mrs Miller)

0..1

string

Length:

0 – 200 characters

postal_code

posal code

0..1

string

Length:

0 – 50 characters

city

city

0..1

string

Length:

0 – 200 characters

country_code_iso

country code

0..1

string

ISO 3166 ALPHA-2 Codes (e.g. „DE“ for Germany)

phone_number

phone number

0..1

string

Length:

0 – 50 characters

(*)If no salutation is known (field is empty) we recommend to use a gender-neutral form of address.

Value Table - for Field sub_channel_id

sub_channel_id

sub_channel_identifier

channel_identifier

1001

Speed4Trade COMMERCE

Onlineshops

1100

modified Shop

Onlineshops

1400

Gambio (Deprecated)

Onlineshops (Deprecated)

1500

Shopgate (Deprecated)

Onlineshops (Deprecated)

1600

MagentoCommerce

Onlineshops

1700

OXID

Onlineshops

1900

Shopware

Onlineshops

2100

eBay.de

eBay

2200

eBay.co.uk

eBay

2250

eBay.ie

eBay

2300

eBay.com

eBay

2310

eBay Motors

eBay

2350

eBay.ca

eBay

2400

eBay.fr

eBay

2500

eBay.it

eBay

2600

eBay.at

eBay

2650

eBay.ch

eBay

2700

eBay.es

eBay

2750

eBay.com.au

eBay

2800

eBay.nl

eBay

2850

eBay.be

eBay

2900

eBay.pl

eBay

3100

amazon.de

Amazon

3200

amazon.co.uk

Amazon

3300

amazon.fr

Amazon

3350

amazon.nl

Amazon

3400

amazon.com

Amazon

3500

amazon.it

Amazon

3550

amazon.ae

Amazon

3600

amazon.es

Amazon

3700

amazon.ca

Amazon

3750

amazon.com.au

Amazon

3800

amazon.com.mx

Amazon

3820

amazon.eg

Amazon

3830

amazon.sa

Amazon

3840

amazon.tr

Amazon

3850

amazon.se

Amazon

3860

amazon.pl

Amazon

4100

Telefonverkauf

manual sales / telesales

5100

Allyouneed.de (Deprecated)

Allyouneed (Deprecated)

6100

Yatego

Yatego

7100

Rakuten.de (Deprecated)

Rakuten (Deprecated)

9100

DAPARTO.de

DAPARTO

10100

otto.de

OTTO

10200

otto.at

OTTO

10300

otto.ch

OTTO

10400

otto.nl

OTTO

10500

otto.ru

OTTO

11100

Locafox.de (Deprecated)

Locafox (Deprecated)

12100

WEBSALE (Deprecated)

WEBSALE (Deprecated)

13100

Kaufland.de

Kaufland.de

14001-14999

individual channel name (see notes below)

Multi-Channel-Plugin (MCP)

15100

OTTO Market DE

OTTO Market

 

Note for value table and field : sub_channel_id:

The sub channels for the Multi-Channel-Plugin (MCP) can be configured via the Speed4Trade CONNECT UI. This doesn't allow for a standardized definition across all customer systems. The required subchannel_ids can be retrieved by using the call fetchSubChannels which could be executed after the initial configuration of a new subchannel using a tool like SoapUI. Setup of this tool is described in the Partnerportal.

 

Potential Return-Codes

Code

Description

0

Successful request

-1

Error. Please see error description.

-3

Orders could not be returned properly because of licensing issues. The max. number of orders in your licence was exceeded (for this client/mandator).

Special Order Tags

Value Table - for Field: order_tags.

ID

Identifier

Description

1

PRIORITY

Order priority flag, e.g. for eBay Plus, Amazon SFP

2

ISPU

In Store Pickup, e.g. for eBay Click and Collect orders.

3

B2B

Business to Business, e.g. for Amazon Business orders.

4

EXTERNAL_INVOICING

External invoicing, e.g. for Amazon Business orders, if Amazon VCS is used (Amazon VAT Calculation Service).

5

EXTERNAL_STATUSUPDATE_PENDING

For some marketplaces the shipping status of shipped orders will be collected and transmitted in a bulk using the job "OrderStatusUpdateJob". Currently available for  Daparto, Amazon, and magentocommerce.

Once an order gets the status "shipped" it will be added to a queue and marked with this order tag flag. Once the job processed the order status transmission successfully to the marketplace the flag will be removed again. This ensures that the marketplace will definitely successfully receive the shipped status.

6

NEXT_DAY_DELIVERY

Currently only in use for Amazon orders. If this tag and the priority tag are present at the same time, the seller has to buy a shipping label from amazon. If only one of them is present, the order still has priority but the seller is allowed to use his preferred shipping service provider.

7

LABEL_ERROR

Used for shipcloud. If an error occurs while generating a shipment-label, this tag will be used.

8

SHIPMENT_ERROR

If setting the sipped state for an order fails, the order will be marked with the shipment-error tag. Only used for plugins that complete orders via order status update job.

9

WEEEPICKUP

Marks orders where the customers requires a takeback for old electrical equipment. (OTTO Market)

Notes

Best Practice and standard configurations only transfer orders, not having the order status „Re-grouped“ (order_status_id = 985). If re-grouped orders shall be requested, the order status filter needs to be adapted accordingly.

Checkout-Status:

o1 = complete: The checkout process is complete

o2 = pending: For orders with payment method paypal, Speed4Trade CONNECT waits for payment confirmation. For other payment methods, this status will be set by  Speed4Trade CONNECT , when the ebay purchase process was interrupted / forced to be completed  (completeCheckout). In the latter case, ebay prevents to set to the complete status (=1).

o3 = incomplete: The ebay purchase process was not completed yet.

Some marketplaces multiple order positions might reference the same item. Speed4Trade CONNECT does not consolidate those order positions and also does not sum up order volumes with identical items. In case of returns this allows the external system to identify the return using the order_item_id or order_id in combination with the order_item_position. Do not use the Do not used the  internal_item_number, item_id or order_item_identifier to transfer the information about the returned items.E.g. this is relevant for Amazon, eBay, and Kaufland.de.

order_tags can be predefined fixed values or user defined tags.

If the client configuration in Speed4Trade CONNECT defined its own number range per sales account instead of a client wide number range, the field order_number_prefix will be used together with the order_number as a significant key. We recommend that your implementation does allow for both models.

Changelog

Version

Change Description

4.8.46

Introduction of a Basic "Simplified" Integration

4.11.18

Extension of the response with information about anonymization

4.11.24

Extension of the response by tax_collected_by_marketplace and tax_collected_by_marketplace_amount.