Guides
Importing orders
Pull marketplace orders into your ERP or accounting software on a schedule. This guide shows how to import them without missing orders or importing the same order twice.
1. Get your stores and status codes
Getreturns the stores in your account with theirStores StoreIdand marketplace (IntegrationId). Orders are pulled per store.Getreturns each store's order status codes (for exampleIntegration Order Listing Status Created,Shipped,Cancelled). Codes differ per marketplace, so do not rely on a fixed list. Statuses withErp: 1are the ones suitable for ERP/accounting import.
2. Pull orders
Get orders with Get. StoreId and OrderStatus are always required. Select orders with one of three methods:
| Method | Fields | Use |
|---|---|---|
| Incremental recommended | BiggestOrderDetailId |
For new orders. Store the largest OrderDetailId you have seen and send it in the next call. |
| Changes | LastModificationTimeFrom |
To track lines whose status changed (cancelled, shipped and so on). |
| Date range | StartDate, EndDate |
For back-fills and checks. The range is at most 7 days. |
Incremental example:
{
"ApiCode": "API_CODE",
"StoreId": 12345,
"OrderStatus": "Created",
"BiggestOrderDetailId": 9876543,
"PageIndex": 1,
"RowsByPage": 200
}Date range example (orders from 1 to 3 November):
{
"ApiCode": "API_CODE",
"StoreId": 12345,
"OrderStatus": "Created",
"StartDate": "2026-11-01T00:00:00",
"EndDate": "2026-11-03T00:00:00",
"PageIndex": 1,
"RowsByPage": 200
}Mind the date range: the server adds 1 day to EndDate, so the request above also covers 3 November. If you pull consecutive ranges, expect to receive some orders twice and de-duplicate them by OrderId.
3. Paging
PageIndexstarts at 1.RowsByPageis the number of orders per page (not lines); the default is 20 and the maximum is 200.TotalOrderCountin the response is the total number of matching orders. IncreasePageIndexuntil you have received that many.- Orders are always sorted by order date, newest first.
4. Statuses are per line
Each line (item) of an order has its own status. GetSales applies the status filter to lines: an order comes back with only its lines in the requested status. So:
- Make a separate request for each status code you import.
- Use
Getto see all lines of an order.Order - Check the current status of specific lines with
Get.Order Detail Status
5. Dates and times
- Send request dates in Turkey time without an offset:
2026-11-05T14:30:00. Do not use local formats such as05.11.2026. - In responses,
OrderDate,CargoDate,InvoiceTime,PackageTimeandWayBillTimeare UTC (with aZ).LastModificationTimeis Turkey time without an offset. - Empty dates come back as
1899-12-31T22:03:00Z, notnull. Treat any date before 1900 as empty.
Recommended flow
- At start-up, get the status codes for each store and choose the statuses you import.
- Every few minutes, call
GetSaleswithBiggestOrderDetailIdfor each store and status, and read every page. - Store orders by
OrderIdand lines byOrderDetailId; if an ID arrives again, update it instead of creating a new record. - Save the largest
OrderDetailIdonly after the orders are written to your own system. - To catch cancellations and returns, also pull changed lines with
LastModificationTimeFrom. - After invoicing, send the invoice details back: Shipping and invoices.
Other order operations
Set: writes a note on the order inside StockMount; it is not sent to the marketplace.Order Notes SetandOrder Set: create orders and change line statuses in StockMount-type (your own) stores only. Marketplace order statuses come from the marketplace.Order Detail Status Confirm: confirms or rejects N11 order items.Or Reject Order Item