← API Index


TourDistance (v2)

A delivery tour that can serve a given location, with how close it already comes to it. Emitted by the tour lookup for a new customer's address and by the depot lookup.

Change Note: same fields as the hand-rolled v2 of findtour/findtour1, now a typed response

# Field Type Description
0 tourid int unique tour id
1 cnt int number of existing customers of this tour that were considered nearby
2 distance double average distance in km from the requested location to the customers counted in cnt. For a depot lookup this is the distance to the depot address.
3 center_lat double latitude of the center of the counted customers (0 if not calculated)
4 center_lng double longitude of the center of the counted customers (0 if not calculated)
5 next_date date next delivery date on this tour
6 name string tour name (legacy identifier, tours.id)
7 note string tour description or note
8 isfull int 1 if the tour has reached its capacity and cannot take new customers
9 code string invitation code of the tour, if it is only reachable by code

Used in endpoints

Referenced in skills

Other versions