TMaps - Mapping API Tunisia
đŸ„ Healthcare & Medical Emergency Use case · MedRoute TN

Optimize Medical and Emergency Routes with TMaps

Every minute counts. TMaps helps your medical teams arrive faster.

Endpoints used

GET /distance-matrix POST /routing/optimized GET /routing/direction
Connected facilities
5

clinics & hospitals Tunis

Avg. response time
4 min

nearest ambulance

Arrival time reduction
28%

vs manual dispatching

Interactive Demo

Click markers to view details · Map powered by TMaps

MedRoute TN

MedRoute TN equips emergency services at several Tunisian clinics. The TMaps Routing API calculates in real time the fastest path to the patient, accounting for traffic. The distance matrix helps automatically assign the nearest ambulance.

Code Example
// Ambulance la plus proche — API TMaps
const matrix = await fetch(
  'https://api.tmaps.tn/distance-matrix',
  {
    method: 'POST',
    headers: { 'Authorization': 'Bearer YOUR_KEY' },
    body: JSON.stringify({
      origins: ambulances.map(a => ({ lat: a.lat, lng: a.lng })),
      destinations: [{ lat: 36.8000, lng: 10.1815 }], // patient
      profile: 'driving',
    }),
  }
);
const { durations } = await matrix.json();
// Trouver l'ambulance la plus proche
const nearest = ambulances[
  durations.indexOf(Math.min(...durations))
];

How It Works

1

📞 Emergency call location

The patient's address is instantly geocoded for precise GPS coordinates, even for rural or incomplete addresses.

GET /geocoding/forward
2

🚑 Nearest ambulance assignment

The distance matrix calculates travel time from each available ambulance to the patient to designate the nearest one.

GET /distance-matrix
3

đŸ—ș Real-time navigation

The ambulance receives the optimal route with turn-by-turn navigation, updated in real time if traffic changes.

POST /routing/optimized

Ready to integrate TMaps into your project?

Start free with 50,000 requests offered every month. No credit card required.

Read the documentation →