Trip Directions API

The Trip Directions API offers efficient routing and detailed turn-by-turn directions for driving, cycling, walking, or using public transportation. It supports multimodal transportation and can help users plan their trips accurately, considering real-time traffic conditions, distance, and other factors. This API can be integrated into various applications to enhance user experience while navigating.

About the API:

The Trip Directions API is a powerful tool that provides routing and turn-by-turn directions for a variety of modes of transportation, including driving, cycling, walking, and public transportation. This API can help users plan their trips efficiently and accurately, taking into account real-time traffic conditions, distance, and other factors.

With the Trip Directions API, developers can easily integrate a routing and directions feature into their applications, making it easy for users to get directions and navigate to their destinations. The API is designed to support various types of transportation modes, including driving, cycling, and walking, and also supports multimodal public transportation, enabling users to find the most optimal route based on their mode of travel.

One of the key features of the Trip Directions API is its ability to provide turn-by-turn directions. This feature allows users to follow a detailed set of directions, including street names, landmarks, and other important information. This makes it easy for users to navigate to their destination, even in unfamiliar areas.

The Trip Directions API also offers a range of additional features that can enhance the user experience, such as real-time traffic updates, estimated travel times, and alternate routes. These features can help users avoid traffic congestion and find the fastest and most efficient route to their destination.

Another important aspect of the Trip Directions API is its flexibility. The API can be customized to meet the specific needs of developers and users, allowing for the integration of additional features and customization of the user interface.

Overall, the Trip Directions API is an essential tool for any developer looking to provide a comprehensive routing and directions feature in their application. With its ability to support various modes of transportation, provide turn-by-turn directions, and offer a range of additional features, the Trip Directions API is a reliable and efficient solution for navigating the world around us.

 

What this API receives and what your API provides (input/output)?

Pass the coordinates for the waypoints and receive the directions for your trip. 

 

What are the most common uses cases of this API?

  1. Transportation and Logistics Management: Companies in the transportation and logistics industry can integrate the Trip Directions API into their systems to optimize their routes and schedules, reducing transportation costs, and improving delivery times. With real-time traffic updates, estimated travel times, and alternate routes, companies can make data-driven decisions to ensure timely and efficient deliveries.

  2. Travel and Tourism: Travel and tourism applications can use the Trip Directions API to help travelers plan their trips, including finding the best routes for various modes of transportation, such as driving, cycling, or walking. With turn-by-turn directions and landmarks, travelers can navigate to their destinations with ease and discover new places along the way.

  3. Fitness and Wellness: Fitness and wellness applications can integrate the Trip Directions API to help users plan their workouts, including finding the best running, cycling, or hiking routes. The API can provide distance and elevation information, helping users to track their progress and achieve their fitness goals.

  4. Emergency Services: Emergency services, such as police, fire, and ambulance services, can use the Trip Directions API to navigate to emergency situations quickly and efficiently. The API can provide real-time traffic updates, estimated travel times, and alternate routes, enabling emergency services to respond to incidents as quickly as possible.

  5. Smart Cities: Cities can use the Trip Directions API to improve their transportation infrastructure and reduce traffic congestion. The API can provide real-time traffic updates, estimated travel times, and alternate routes, helping to optimize traffic flow and reduce carbon emissions. Additionally, cities can integrate the API into their public transportation systems, making it easier for commuters to navigate the city and reducing the number of cars on the road.

 

Are there any limitations to your plans?

Besides API call limitations per month, there are no other limitations. 

Documentación de la API

Endpoints


Calculate route between provided waypoints, including turn by turn directions

 


                                                                            
GET https://zylalabs.com/api/1922/trip+directions+api/1631/get+directions
                                                                            
                                                                        

Get Directions - Características del Endpoint

Objeto Descripción
waypoints [Requerido] List of two or more lat,lon coordinates, separated by the pipe symbol \"|\"
mode [Requerido] Routing mode - drive, truck, bicycle, walk or transit
Probar Endpoint

RESPUESTA DE EJEMPLO DE LA API

       
                                                                                                        
                                                                                                                                                                                                                            {
  "features": [
    {
      "type": "Feature",
      "properties": {
        "mode": "drive",
        "waypoints": [
          {
            "location": [
              10.87474,
              48.34364
            ],
            "original_index": 0
          },
          {
            "location": [
              10.90925,
              48.37073
            ],
            "original_index": 1
          }
        ],
        "units": "metric",
        "distance": 7774,
        "distance_units": "meters",
        "time": 627.658,
        "legs": [
          {
            "distance": 7774,
            "time": 627.658,
            "steps": [
              {
                "from_index": 0,
                "to_index": 91,
                "distance": 1581,
                "time": 114.761,
                "instruction": {
                  "text": "Drive north on Gögginger Straße."
                }
              },
              {
                "from_index": 91,
                "to_index": 171,
                "distance": 1312,
                "time": 140.345,
                "instruction": {
                  "text": "Turn right onto Schertlinstraße."
                }
              },
              {
                "from_index": 171,
                "to_index": 187,
                "distance": 189,
                "time": 14.709,
                "instruction": {
                  "text": "Turn right onto Haunstetter Straße."
                }
              },
              {
                "from_index": 187,
                "to_index": 327,
                "distance": 2960,
                "time": 220.233,
                "instruction": {
                  "text": "Turn left onto Inverness-Allee/B 300."
                }
              },
              {
                "from_index": 327,
                "to_index": 352,
                "distance": 1034,
                "time": 78.82,
                "instruction": {
                  "text": "Turn left onto Berliner Allee/B 2."
                }
              },
              {
                "from_index": 352,
                "to_index": 371,
                "distance": 246,
                "time": 23.478,
                "instruction": {
                  "text": "Turn left to take the ramp."
                }
              },
              {
                "from_index": 371,
                "to_index": 388,
                "distance": 435,
                "time": 31.514,
                "instruction": {
                  "text": "Bear right onto Lechhauser Straße."
                }
              },
              {
                "from_index": 388,
                "to_index": 391,
                "distance": 13,
                "time": 3.795,
                "instruction": {
                  "text": "Turn right onto Oblatterwallstraße."
                }
              },
              {
                "from_index": 391,
                "to_index": 391,
                "distance": 0,
                "time": 0,
                "instruction": {
                  "text": "Your destination is on the left."
                }
              }
            ]
          }
        ]
      },
      "geometry": {
        "type": "MultiLineString",
        "coordinates": [
          [
            [
              10.874805,
              48.343631
            ],
            [
              10.874852,
              48.343782
            ],
            [
              10.874924,
              48.344021
            ],
            [
              10.874952,
              48.34411
            ],
            [
              10.87499,
              48.344258
            ],
            [
              10.875009,
              48.344339
            ],
            [
              10.875011,
              48.344449
            ],
            [
              10.875012,
              48.344492
            ],
            [
              10.875087,
              48.344734
            ],
            [
              10.875108,
              48.344801
            ],
            [
              10.875168,
              48.344975
            ],
            [
              10.875213,
              48.345085
            ],
            [
              10.875268,
              48.345217
            ],
            [
              10.875287,
              48.345257
            ],
            [
              10.875318,
              48.345318
            ],
            [
              10.875337,
              48.345356
            ],
            [
              10.87538,
              48.345428
            ],
            [
              10.875401,
              48.345462
            ],
            [
              10.875493,
              48.345611
            ],
            [
              10.875527,
              48.345665
            ],
            [
              10.875643,
              48.345853
            ],
            [
              10.875669,
              48.345889
            ],
            [
              10.875678,
              48.345903
            ],
            [
              10.875736,
              48.345949
            ],
            [
              10.875891,
              48.346057
            ],
            [
              10.876002,
              48.346198
            ],
            [
              10.876047,
              48.346254
            ],
            [
              10.876196,
              48.346467
            ],
            [
              10.876206,
              48.346481
            ],
            [
              10.876255,
              48.346558
            ],
            [
              10.876314,
              48.34666
            ],
            [
              10.876352,
              48.346725
            ],
            [
              10.876409,
              48.346823
            ],
            [
              10.876531,
              48.347054
            ],
            [
              10.876735,
              48.347464
            ],
            [
              10.877069,
              48.348229
            ],
            [
              10.877082,
              48.348258
            ],
            [
              10.877058,
              48.348339
            ],
            [
              10.87705,
              48.348366
            ],
            [
              10.87711,
              48.348499
            ],
            [
              10.877172,
              48.348635
            ],
            [
              10.877244,
              48.348796
            ],
            [
              10.877251,
              48.348809
            ],
            [
              10.877357,
              48.349011
            ],
            [
              10.877454,
              48.34916
            ],
            [
              10.877571,
              48.349303
            ],
            [
              10.877771,
              48.349529
            ],
            [
              10.87779,
              48.34955
            ],
            [
              10.877845,
              48.349586
            ],
            [
              10.877906,
              48.349627
            ],
            [
              10.877935,
              48.349646
            ],
            [
              10.878042,
              48.349732
            ],
            [
              10.878156,
              48.349847
            ],
            [
              10.878293,
              48.350011
            ],
            [
              10.878498,
              48.350257
            ],
            [
              10.878568,
              48.350342
            ],
            [
              10.878661,
              48.350479
            ],
            [
              10.87875,
              48.350609
            ],
            [
              10.878738,
              48.35067
            ],
            [
              10.878732,
              48.350702
            ],
            [
              10.878934,
              48.350931
            ],
            [
              10.879319,
              48.351371
            ],
            [
              10.879521,
              48.351599
            ],
            [
              10.879955,
              48.352082
            ],
            [
              10.879992,
              48.352123
            ],
            [
              10.88022,
              48.352375
            ],
                                                                                                                                                                                                                    
                                                                                                    

Get Directions - CÓDIGOS DE EJEMPLO


curl --location --request GET 'https://zylalabs.com/api/1922/trip+directions+api/1631/get+directions?waypoints=Required&mode=Required' --header 'Authorization: Bearer YOUR_API_KEY' 


    

Clave de Acceso a la API y Autenticación

Después de registrarte, a cada desarrollador se le asigna una clave de acceso a la API personal, una combinación única de letras y dígitos proporcionada para acceder a nuestro endpoint de la API. Para autenticarte con el Trip Directions API simplemente incluye tu token de portador en el encabezado de Autorización.
Encabezados
Encabezado Descripción
Autorización [Requerido] Debería ser Bearer access_key. Consulta "Tu Clave de Acceso a la API" arriba cuando estés suscrito.

Precios Simples y Transparentes

Sin compromiso a largo plazo. Mejora, reduce o cancela en cualquier momento. La Prueba Gratuita incluye hasta 50 solicitudes.

🚀 PLAN CORPORATIVO A MEDIDA

Comienza en
$ 10.000/Año


  • Volumen Personalizado
  • Límite de solicitudes personalizado
  • Soporte al Cliente Especializado
  • Monitoreo de API en Tiempo Real

Funciones favoritas de los clientes

  • ✔︎ Paga Solo por Solicitudes Exitosas
  • ✔︎ Prueba Gratuita de 7 Días
  • ✔︎ Soporte Multilenguaje
  • ✔︎ Una Clave API, Todas las APIs.
  • ✔︎ Panel de Control Intuitivo
  • ✔︎ Manejo de Errores Integral
  • ✔︎ Documentación Amigable para Desarrolladores
  • ✔︎ Integración con Postman
  • ✔︎ Conexiones HTTPS Seguras
  • ✔︎ Tiempo de Actividad Fiable

Trip Directions API FAQs

The Get Directions endpoint returns detailed routing information, including turn-by-turn directions, estimated travel times, distance, and real-time traffic conditions for the specified waypoints.

Key fields in the response data include "route", which contains the path taken, "legs" for individual segments of the journey, "duration" for travel time, and "steps" for detailed turn-by-turn instructions.

The response data is structured in a JSON format, organized into hierarchical sections such as "routes", "legs", and "steps", allowing users to easily navigate through the information.

Users can customize requests with parameters such as "waypoints" (coordinates), "mode" (driving, cycling, walking, public transport), and "avoid" (tolls, highways) to tailor the routing experience.

The endpoint provides information on routes, estimated travel times, distances, turn-by-turn directions, traffic conditions, and alternative routes based on user-selected transportation modes.

Data accuracy is maintained through continuous updates from reliable sources, including traffic data providers and mapping services, ensuring users receive the most current routing information.

Typical use cases include route optimization for logistics, trip planning for travelers, fitness route mapping, and emergency response navigation, leveraging real-time traffic and distance data.

Users can utilize the returned data by parsing the JSON response to extract relevant fields, such as "steps" for navigation instructions, and integrating this information into their applications for enhanced user experiences.

General FAQs

Zyla API Hub es como una gran tienda de APIs, donde puedes encontrar miles de ellas en un solo lugar. También ofrecemos soporte dedicado y monitoreo en tiempo real de todas las APIs. Una vez que te registres, puedes elegir qué APIs quieres usar. Solo recuerda que cada API necesita su propia suscripción. Pero si te suscribes a varias, usarás la misma clave para todas, lo que hace todo más fácil para ti.

Los precios se muestran en USD (dólar estadounidense), EUR (euro), CAD (dólar canadiense), AUD (dólar australiano) y GBP (libra esterlina). Aceptamos todas las principales tarjetas de débito y crédito. Nuestro sistema de pago utiliza la última tecnología de seguridad y está respaldado por Stripe, una de las compañías de pago más confiables del mundo. Si tienes algún problema para pagar con tarjeta, contáctanos en [email protected]


Además, si ya tienes una suscripción activa en cualquiera de estas monedas (USD, EUR, CAD, AUD, GBP), esa moneda se mantendrá para suscripciones posteriores. Puedes cambiar la moneda en cualquier momento siempre que no tengas suscripciones activas.

La moneda local que aparece en la página de precios se basa en el país de tu dirección IP y se proporciona solo como referencia. Los precios reales están en USD (dólar estadounidense). Cuando realices un pago, el cargo aparecerá en tu estado de cuenta en USD, incluso si ves el monto equivalente en tu moneda local en nuestro sitio web. Esto significa que no puedes pagar directamente en tu moneda local.

Ocasionalmente, un banco puede rechazar el cargo debido a sus configuraciones de protección contra fraude. Te sugerimos comunicarte con tu banco primero para verificar si están bloqueando nuestros cargos. También puedes acceder al Portal de Facturación y cambiar la tarjeta asociada para realizar el pago. Si esto no funciona y necesitas más ayuda, por favor contacta a nuestro equipo en [email protected]

Los precios se determinan mediante una suscripción recurrente mensual o anual, dependiendo del plan elegido.

Las llamadas a la API se descuentan de tu plan en base a solicitudes exitosas. Cada plan incluye una cantidad específica de llamadas que puedes realizar por mes. Solo las llamadas exitosas, indicadas por una respuesta con estado 200, se contarán en tu total. Esto asegura que las solicitudes fallidas o incompletas no afecten tu cuota mensual.

Zyla API Hub funciona con un sistema de suscripción mensual recurrente. Tu ciclo de facturación comenzará el día en que compres uno de los planes de pago, y se renovará el mismo día del mes siguiente. Así que recuerda cancelar tu suscripción antes si quieres evitar futuros cargos.

Para actualizar tu plan de suscripción actual, simplemente ve a la página de precios de la API y selecciona el plan al que deseas actualizarte. La actualización será instantánea, permitiéndote disfrutar inmediatamente de las funciones del nuevo plan. Ten en cuenta que las llamadas restantes de tu plan anterior no se transferirán al nuevo plan, por lo que debes considerar esto al actualizar. Se te cobrará el monto total del nuevo plan.

Para verificar cuántas llamadas a la API te quedan en el mes actual, revisa el campo 'X-Zyla-API-Calls-Monthly-Remaining' en el encabezado de la respuesta. Por ejemplo, si tu plan permite 1,000 solicitudes por mes y has usado 100, este campo mostrará 900 llamadas restantes.

Para ver el número máximo de solicitudes a la API que permite tu plan, revisa el encabezado de la respuesta 'X-Zyla-RateLimit-Limit'. Por ejemplo, si tu plan incluye 1,000 solicitudes por mes, este encabezado mostrará 1,000.

El encabezado 'X-Zyla-RateLimit-Reset' muestra el número de segundos hasta que tu límite se restablezca. Esto te indica cuándo tu conteo de solicitudes se reiniciará. Por ejemplo, si muestra 3,600, significa que faltan 3,600 segundos para que el límite se restablezca.

Sí, puedes cancelar tu plan en cualquier momento desde tu cuenta, seleccionando la opción de cancelación en la página de Facturación. Ten en cuenta que las actualizaciones, degradaciones y cancelaciones tienen efecto inmediato. Además, al cancelar ya no tendrás acceso al servicio, incluso si te quedaban llamadas en tu cuota.

Puedes contactarnos a través de nuestro canal de chat para recibir asistencia inmediata. Siempre estamos en línea de 8 a. m. a 5 p. m. (EST). Si nos contactas fuera de ese horario, te responderemos lo antes posible. Además, puedes escribirnos por correo electrónico a [email protected]

Para darte la oportunidad de probar nuestras APIs sin compromiso, ofrecemos una prueba gratuita de 7 días que te permite realizar hasta 50 llamadas a la API sin costo. Esta prueba solo se puede usar una vez, por lo que recomendamos aplicarla a la API que más te interese. Aunque la mayoría de nuestras APIs ofrecen prueba gratuita, algunas pueden no hacerlo. La prueba finaliza después de 7 días o cuando realices 50 solicitudes, lo que ocurra primero. Si alcanzas el límite de 50 solicitudes durante la prueba, deberás "Iniciar tu Plan de Pago" para continuar haciendo solicitudes. Puedes encontrar el botón "Iniciar tu Plan de Pago" en tu perfil bajo Suscripción -> Elige la API a la que estás suscrito -> Pestaña de Precios. Alternativamente, si no cancelas tu suscripción antes del día 7, tu prueba gratuita finalizará y tu plan se cobrará automáticamente, otorgándote acceso a todas las llamadas a la API especificadas en tu plan. Ten esto en cuenta para evitar cargos no deseados.

Después de 7 días, se te cobrará el monto total del plan al que estabas suscrito durante la prueba. Por lo tanto, es importante cancelar antes de que finalice el periodo de prueba. No se aceptan solicitudes de reembolso por olvidar cancelar a tiempo.

Cuando te suscribes a una prueba gratuita de una API, puedes realizar hasta 50 llamadas. Si deseas realizar más llamadas después de este límite, la API te pedirá que "Inicies tu Plan de Pago". Puedes encontrar el botón "Iniciar tu Plan de Pago" en tu perfil bajo Suscripción -> Elige la API a la que estás suscrito -> Pestaña de Precios.

Las Órdenes de Pago se procesan entre el día 20 y el 30 de cada mes. Si envías tu solicitud antes del día 20, tu pago será procesado dentro de ese período.


APIs Relacionadas


También te puede interesar