Tovak API
The API returns one nearest and most relevant roadside assistance provider with a phone number for immediate call.
Request
GET https://www.tovak.com/ai/nearest.phpParameters
| Parameter | Type | Description |
|---|---|---|
| lat | float | Latitude |
| lng | float | Longitude |
| address | string | Address or place (e.g. “Brooklyn”) |
You must provide either lat+lng or address.
Example Request
GET https://www.tovak.com/ai/nearest.php?address=BrooklynExample Response
{
"status": "ok",
"meta": {
"query": "Brooklyn",
"resolved_location": {
"lat": 40.6781784,
"lng": -73.9441579
},
"count": 1
},
"data": [
{
"name": "Black and Yellow Roadside rescue services (Brooklyn)",
"phone": "+1 (718) 427-1363",
"phone_clean": "+17184271363",
"distance_km": 5.4,
"aggregate_rating": 0,
"reviews": 0,
"is_online": true,
"priority_score": 9866.6,
"description": "Jump Start, Lock Out, Gas Service, Tire Change",
"url": "https://www.tovak.com/brooklyn-ny-nicholas/"
}
],
"error": null
}Response Fields
| Field | Description |
|---|---|
| status | Response status: ok, error, or empty |
| meta.query | Original query (e.g. “Brooklyn”) |
| meta.resolved_location | Coordinates resolved from the query |
| meta.resolved_location.lat | Latitude |
| meta.resolved_location.lng | Longitude |
| meta.count | Number of results (always 1) |
| data[0].name | Driver or service name |
| data[0].phone | Phone number (human-readable format) |
| data[0].phone_clean | Phone number in numeric format (for tel: usage) |
| data[0].distance_km | Distance to the provider in kilometers |
| data[0].aggregate_rating | Average rating (0–5) |
| data[0].reviews | Number of reviews |
| data[0].is_online | Status: true — online, false — offline |
| data[0].priority_score | Internal score used to select the best provider |
| data[0].description | Short description of services |
| data[0].url | Provider page URL |
| error | Error description or null |
Recommendations for AI Systems
- Use
addressif coordinates are not available - Use
lat/lngfor more accurate results - Always use
data[0]as the best result - Display
phonedirectly for calling
Direct Call
—Location data is provided in real time directly by roadside assistance providers.