Getting shortest direction for 3 latlong

Hello to everyone ,

I am new to using openrouteservice. The question I asked might be unprofessional but I could not understand.

I want to send a few (for example 3) Latlong values from my android project and get the shortest direction. Before submitting a request within the project, you can use this link (https://openrouteservice.org/dev/#/api-docs/directions/get)

I’m trying to use the “Directions Service (POST)” header on this link.

I enter 3 latlong values in the coordinates section. and I say call action. But I am encountering an error. I looked at past issues. Someone said that you are confusing x and y, but I am sure that I did not.

getting this error :

{

“error”
:
{

“code”
:
2010
,

“message”
:
“Could not find point 0: 39.9292071 32.8218843 within a radius of 350.0 meters.; Could not find point 1: 39.9296081 32.8212684 within a radius of 350.0 meters.”

}
,

“info”
:
{

“engine”
:
{

“version”
:
“6.3.0”
,

“build_date”
:
“2020-09-21T01:00:26Z”

}
,

“timestamp”
:
1605375526078

}

}

Hi @mertct11,

first of all, with the link you sent, you can’t use POST, as that endpoint only takes GET requests.
Use this one:
https://openrouteservice.org/dev/#/api-docs/v2/directions/{profile}/post

Looking at the error i’m most defenitely sure you confused Lat and Long

Please check the info fields next to the parameters (questionmark buttons ‘?’).
For coordinates it says you should input long/lat :slight_smile:

grafik

Best regards