Description
Using filters we want to receive the orders of a customer. These orders will come directly from the ERP system and can contain our web orders but also orders placed in the shop or by phone.
Note that the orders should be returned in reversed order. The order history is shown on the shop in a paged manner. The first page contains the most recent orders with the latest order on top of the list.
The default number of orders on a page can be set to 20. Note that the the shop's design may define a different number so it is wise to make this parameter configurable.
Action
http://shoxl.com/ShoxlService/GetOrderHistory
Please note: this is not a working url, but a combination of namespace and method. Do not expect the url to return a result.
Style
Document
The input of this method is the document element tns:GetOrderHistory having the structure defined by the following table.
Description
The GetOrderHistoryRequest contains all the information to get the orders of the
customer.
Possible values for filtertype “by order status code” (2)
Geleverd
Deels geleverd
Niet geleverd
tns:GetOrderHistoryResponse
The output of this method is the document element tns:GetOrderHistoryResponse having the structure defined by the following table.
Description
The GetOrderHistoryResult contains the orders of the customer using the given
filter.
A OrderHistoryItem contains all the main information of an Order. To show on the order history overview page.
URL: /Shoxl/v1/GetOrderHistory Method: POST
A new field "context" is introduced in the request body. When configured this object contains key value pairs (e.g. divisionCode).
Request body:
}
Response body:
}
}
Element
Type
Occurs
Description
Sequence
1..1
request
tns:GetOrderHistoryRequest
0..1
Component
Type
Occurs
Description
Sequence
1..1
AccountNumber
s:string
1..1
This is the (project) account number of the customer.
FilterType
s:int
0..1
The type of the filter: 1 = by OrderDate (yyyy/mm/dd), 2 = by order status code, 3 = customer order reference
FilterValue
s:string
0..1
The value for the given filter type
PageNumber
s:int
0..1
The number of the page. The page numbering is 1-based: first page has number 1.
Element
Type
Occurs
Description
Sequence
1..1
GetOrderHistoryResult
tns:GetOrderHistoryResult
0..1
Component
Type
Occurs
Description
Sequence
1..1
ErrorCode
s:string
0..1
An error code returned by the ERP system
ErrorDescription
s:string
0..1
The error description related to the error code returned by the ERP system
Orders
tns:ArrayOfOrderHistoryItem
0..1
A list of OrderHistoryItems, the ComplexType OrderHistoryItem contains some order details like; order date and order number. For the complete description check the OrderHistoryItem section in the documentation. The ERP will return 25 results as a maximum.
Request
tns:GetOrderHistoryRequest
1..1
The sent request by Shoxl Shop.
PageNumber
s:int
0..1
The number of the page.
TotalPages
s:int
0..1
Total number of pages with results
Component
Type
Occurs
Description
Sequence
1..1
OrderHistoryItem
tns:OrderHistoryItem
0..*
Component
Type
Occurs
Description
Sequence
1..1
JobNumber
s:string
0..1
The Jobnumber, given by the customer
OrderDate
s:dateTime
0..1
The order date
OrderState
s:int
0..1
Orderstate: 1 = open, 2 = closed. State should be derived form orderlinestates: 1 means 1 or more lines have state open or backorder, 2 means all lines have status shipped or cancelled.
OrderNumber
s:string
0..1
This the Shoxl Shop unique order number
TotalPriceExclVat
s:decimal
0..1
The total price of the order excluding VAT
TotalPriceInclVat
s:decimal
0..1
The total price of the order including VAT
Reference
s:string
0..1
This is the customer order reference
parameter
type
accountNumber
string required
filterType
integer($int32)
nullable: true
filterValue
string nullable: true
pageNumber
integer($int32)
context
object nullable: true
parameter
type
errorCode
string nullable: true
errorDescription
string nullable: true
orders
[OrderHistoryItem]
request
GetOrderHistoryRequest
totalPages
integer($int32)
pageNumber
integer($int32)
parameter
type
jobNumber
string nullable: true
orderDate
string($date-time)
orderNumber
string nullable: true
deliveryDate
string($date-time) nullable: true
orderState
integer($int32)
nullable: true
reference
string nullable: true
totalPriceExclVat
number($double)
nullable: true
totalPriceInclVat
number($double)
nullable: true