Mode
Use this object to change the max search distance, and the search mode
The mode
object controls how InBe searches for venues based on your specified locations and their weights. It determines whether to search in a radius around a central point or along a path between multiple locations.
Basic structure
Properties
mode (required)
Search behavior type. Either "POINT" for radius-based search or "PATH" for route-following search.
maxDistance (required)
Maximum search distance in meters. Controls how far from the search centre to look for venues.
Search modes
POINT mode
Traditional radius-based search around a central location. Perfect for:
- Single user searches
- Group meetups (finds venues near a calculated midpoint)
- General area exploration
This searches for venues within 750m of the specified location.
PATH mode
Route-following search that finds venues along a path between multiple locations. Ideal for:
- Travel planning
- Journey-based discovery
- Finding stops along a route
This finds venues within a 50m width of the route between the three points. Do not include weights in the locations
array when using the PATH mode as they have no effect.
Distance considerations
POINT mode distances
- Small (100-500m): Very local search, great for immediate needs
- Medium (500m-2km): Neighborhood search -
Caution for cities with limited travel options
- Large (2km-5km): City area search, suitable for special occasions
- Very large (5km+): Regional search -
use sparingly
PATH mode distances
- Small (10-50m): Venues very close to the route
- Medium (50m-500m): Venues within walking distance of the route
- Large (500m-1km): Venues that will require a detour
- Very large (1km+): Venues that may require a long detour -
use sparingly
Real-world examples
Coffee shop meetup (POINT mode)
Road trip planning (PATH mode)
Urban exploration (POINT mode)
This is an example of a user searching for a restaurant between their current location and an attraction they are visiting, perfering the attraction.
Default values
You are required to specify a mode object in your search request. If you don't specify a mode object, a 400
error will be returned.
Best practice
- Start with smaller distances and increase if you need more results
- Consider user travel preferences - in cities users prefer walking distance up to 1km
- Use PATH mode sparingly - for most, it will not provide desired results
- Balance distance with result quality - smaller distances return more relevant venues
- Tailor distances based on context - how are your users travelling, walking, public transport, car, etc
Distance conversion guide
Distance | Walking time | Use case | Travel method |
---|---|---|---|
100m | 1-2 minutes | Immediate needs, very local | Walking |
500m | 5-7 minutes | Quick meetups, coffee runs | Walking |
1km | 10-15 minutes | Casual meetups, lunch | Walking, Public transport |
2km | 20-30 minutes | Planned meetups, dinner | Public transport, Car |
5km | 45-60 minutes | Special occasions, events | Public transport, Car |