•   over 3 years ago

History in reverse order

Is there a way to get the users history in ascending order? i.e. their first uber trip would be the first returned when offset is 0.

  • 1 comment

  • Moderator   •   over 3 years ago

    No, at this time, the history endpoint always returns the most recent activity and there isn't a way to flip the order. You can be a bit clever however and make one call to get the `count` of all activity, divide that by your desired limit (up to 50) and use that as your offset. You can then work backwards from there.

    Obviously not as elegant as being able to get the first trip with one call, but with this method, you can get it with just two.

Comments are closed.