cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Retrieving orders filtered by status returns error

Hi,

I am trying to use the fulfillment API to retrieve orders from an ebay account follwoing this article:

Discovering unfulfilled orders | eBay Developers Program

I am passing a minimum date and an order status to filter for certain values only. However I can not get the  orderfullfillmentstatus filter to work, I am always getting error 30800. Without this filter in place I can retrieve orders just fine - but of course not correctly filtered. Here is what I am sending:

GET https://api.ebay.com/sell/fulfillment/v1/order?filter=creationdate%3a%5b2024-03-20T09%3a10%3a48.1900000Z..%5d%2corderfulfillmentstatus%3a%7BNOT_STARTED%7D&limit=5 

This is the response:

{
    "errors": [
        {
            "errorId": 30800,
            "domain": "API_FULFILLMENT",
            "category": "REQUEST",
            "message": "Invalid filter value '{NOT_STARTED}' for filter 'orderfulfillmentstatus'",
            "parameters": [
                {
                    "name": "filterName",
                    "value": "orderfulfillmentstatus"
                },
                {
                    "name": "filterValue",
                    "value": "{NOT_STARTED}"
                }
            ]
        }
    ]
}
In my eyes I am doing everything correctly according to the article linked above but there has got to be something (potentially stupid) mistake on my end that I just can't see, any help is greatly appreciated.
Kai
Message 1 of 4
latest reply
3 REPLIES 3

Retrieving orders filtered by status returns error

This worked for me

 

https://api.ebay.com/sell/fulfillment/v1/order?filter=orderfulfillmentstatus:{NOT_STARTED|IN_PROGRESS}&limit=50

 

with date

 

https://api.ebay.com/sell/fulfillment/v1/order?filter=creationdate:%5B2024-04-16T08%3A10%3A56.000Z..2024-04-19T08%3A10%3A56.000Z%5D&limit=0&offset=0

 

If you encode, it would look like this

 

https://api.ebay.com/sell/fulfillment/v1/order?filter=creationdate:[2024-04-16T08:10:56.000Z..2024-04-19T08:10:56.000Z]&limit=0&offset=0

 

Your is encoded like this

 

https://api.ebay.com/sell/fulfillment/v1/order?filter=creationdate:[2024-03-20T09:10:48.1900000Z..],orderfulfillmentstatus:{NOT_STARTED}&limit=5

Creation date needs start and end datetime.

C# wrapper for eBay REST API
https://github.com/CMS365-PTY-LTD/EbaySharp
Message 2 of 4
latest reply

Retrieving orders filtered by status returns error

Hi,

Thanks for your answer. 

1. When you say creation date needs a start and end date time - what makes you say that? According to getOrders: eBay Fulfillment API | eBay Developers Program it says quote: 

creationdateThe time period during which qualifying orders were created (the orders.creationDate field). In the URI, this is expressed as a starting timestamp, with or without an ending timestamp (in brackets). The timestamps are in ISO 8601 format, which uses the 24-hour Universal Coordinated Time (UTC)

2. For testing purposes I removed the creationdate filter for now so we can focus on the orderfulfillmentstatus issue. 

Reading through the documentation for the 100th time or so I found this

The values NOT_STARTED, IN_PROGRESS, and FULFILLED can be used in various combinations, but only the combinations shown here are currently supported.

So does that mean that it is not possible to filter for orders in state NOT_STARTED only as only the combinations NOT_STARTED|IN_PROGRESS and FULLFILLED|IN_PROGRESS are valid?? That would suck big time...

 

Message 3 of 4
latest reply

Retrieving orders filtered by status returns error

1 - I thought you can pass the end date but you can just pass the start datetime as well

https://api.ebay.com/sell/fulfillment/v1/order?filter=creationdate:%5B2024-04-17T09%3A00%3A52.000Z.....

 

https://api.ebay.com/sell/fulfillment/v1/order?filter=creationdate:[2024-04-17T09:00:52.000Z..]&limit=0&offset=0

 

2 - There are limited combinations possible but hopefully they will add more.

C# wrapper for eBay REST API
https://github.com/CMS365-PTY-LTD/EbaySharp
Message 4 of 4
latest reply