API to easyJOB - "invalid-filter-or-order"

Hi dear support team,
Since Friday 3:00 p.m. UTC we have no longer received times from awork via our interface. We still query the times with the same query:

https://thjnk.awork.com/api/v1/timeentries?page=1&pageSize=1000&filterby=startDateUtc ge datetime’2024-03-04T00:00’ and duration gt 0.0

But we now get the following error message: „code“:„invalid-filter-or-order“,„description“:„Something is wrong with the given ‚filterby‘ expression.“}

Can you please check where this problem lies?
thanks in advance!
Olaf

Hi @olaf.heinrich ,

do you have a trace id from the response header for us to check the request?

Best

Nils

Hi @Nils
unfortunately we don´t have a trace ID.
I just can give you the recent error message.
we did not change any Settings or script in the API.
Can you find out if there were any changes on Awork last Friday?

Greetings Olaf

Hi @olaf.heinrich,

i was able to repro the issue, but it seems the query to the api is wrong. You filter for duration gt 0.0 but duration is an integer field. Can you please change the filter to duration gt 0 then everything should work.

Best

Nils

Hi Nils,
thanks for the tip, If t is an Integer-field - how can we represent minutes?
Until friday everything worked fine, were there maybe a change?

Hi @olaf.heinrich ,

the duration is in seconds, so a minute is a duration of 60.

We haven’t been able to identify a reason why it worked before, but we updated one of our major libraries and i might have impacted this case. The filter expression was always wrong, but maybe we allowed this wrong value before and now the parser is more strict.

Can you change the filter on your side?

Best

Nils

ok, thanks!
that sounds logical :slight_smile:
We will try it to change in seconds…

Hi Nils, it seems to working now :slight_smile:
Thx!

1 „Gefällt mir“