Closed hexrw closed 1 month ago
Hello @hexrw ,
The getOrders api allows multiple query parameters to apply the filtering criteria.
Currently it does not allow sorting feature, as an immediate fix one can use a programming language to iterate through the data in-memory ( such as lists in python ) and traverse it in reverse order after getting all the details.
We have noted your feedback and shared with the concerned team.
Regards
I'm submitting a...
SP-API Name and Version or Report/Feed Type
Orders v0 getOrders
GET /orders/v0/orders
Expected Behavior
I request orders and I get the newest/latest order first. Then as I download more and more pages I get older and older orders. It's the natural intuitive reasonable way to do sort orders.
Either make the default behavior retrieve orders from latest to oldest or add an option for changing the order used.
Current Behavior
Orders get returned ordered from oldest to latest. So for example if I request yesterday's orders and there's a lot of them, I have to download multiple pages just to get to the latest ones...
Context/Screenshots
Example:
Your Environment
Node 20 LTS