API

LocationBox API

Il Info (with Geometry)

Il Info Service gives needed geographical information about citys.

GetIlInfo request must look like this:

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetIlInfo&Typ=output_format&Geometry=geometry&IlId=ilid&Encode=encode

Request Parameters


Key: LocationBox user key. (Register for user key)
Cmd: LocationBox service name. (GetIlInfo)
Typ: Response format. (XML or JSON)
IlId: (Check out for IlList)
Geometry: 1:With Geometry - 0:No Geometry.
Encode: 1: Geometry Encoding.
Keyword (optional): Add a keyword to narrow down Cmd results.

Response Parameters


XML Response

GetIlInfo response returns in XML format when the Typ parameter is set as "XML".

Below is an example for a GetIlInfo request which is expected to return a response in XML format .

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetIlInfo&Typ=XML&Geometry=1&IlId=1&Encode=0

The response will be as following:

<response>
 <transactionid> LBS_37538710 </transactionid>
 <status> 0 </status>
 <errno />
 <errdesc />
  <il>
   <id> 1 </id>
   <name> Adana </name>
   <latitude> 39.80039 </latitude>
   <longitude> 27.5208 </longitude>
  <extent>
   <minlatitude> 39.80039 </minlatitude>...
   <geometry>
  <ordinates> 29.81985408,40.76798202,29.82039696,40.76806896,29.82143304,40.76820603,29.82174588,40.76824401 </ordinates>
  </geometry>
  </il>
</response>

JSON Response

GetIlInfo response returns in JSON format when the Typ parameter is set as "JSON".

Below is an example for a GetIlInfo request which is expected to return a response in JSON format .

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetIlInfo&Typ=JSON&Geometry=1&IlId=1&Encode=0

The response will be as following:

{ "transactionid": "LBS_53386412", "status": 0, "id": 1, "name": "Adana", "latitude": 38.69039, "longitude": 33.30411, "extent": { "minlatitude": 36.53888499, "minlongitude": 34.76786904, "maxlatitude": 38.37851496, "maxlongitude": 36.40534884 } , "geometry": [ "39.40534884,37.25248202,32.386586,30.27663298,39.32301612,36.34234504,36.19096,38.311401,36.1234024292,..." ]}

transactionid: The id of response given by LocationBox Service. Every response can be tracked using transactionid when necessary.
status: Response format. (XML or JSON)

Status Codes
0 -- Success
1 -- Fail

errno: Error code
errdesc: Error definition

Error Codes
10001 Error processing your request. Please try again soon.
Cmd parameter is misspelled/not found.
10011 Error processing your request. Please check the Cmd parameter.
Cmd is not specified.
10012 Error processing your request. Please check the Key parameter.
Key is not specified.
10013 Error processing your request. Please check the Key parameter.
Key is invalid.
20012 No data found.

Ilce Info (with Geometry)

Ilce Info Service gives needed geographical information about towns.

GetIlceInfo request must look like this:

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetIlceInfo&Typ=output_format&Geometry=geometry&IlceId=ilceid&Encode=encode


Request Parameters


Key: LocationBox user key. (Register for user key)
Cmd: LocationBox service name. (GetIlInfo)
Typ: Response format. (XML or JSON)
IlceId: (Check out for IlceList)
Geometry: 1:With Geometry - 0:No Geometry.
Encode: 1: Geometry Encoding.
Keyword (optional): Add a keyword to narrow down Cmd results.

Response Parameters


XML Response

GetIlceInfo response returns in XML format when the Typ parameter is set as "XML".

Below is an example for a GetIlceInfo request which is expected to return a response in XML format .

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetIlceInfo&Typ=XML&Geometry=1&IlceId=10000441000&Encode=0

The response will be as following:

<response>
 <transactionid> LBS_37538710 </transactionid>
 <status> 0 </status>
 <errno />
 <errdesc />
  <ilce>
   <id> 10000441000 </id>
   <name> Balya </name>
   <latitude> 39.80039 </latitude>
   <longitude> 27.5208 </longitude>
  <extent>
   <minlatitude> 39.80039 </minlatitude>...
   <geometry>
  <ordinates> 29.81985408,40.76798202,29.82039696,40.76806896,29.82143304,40.76820603,29.82174588,40.76824401 </ordinates>
  </geometry>
  </ilce>
</response>

JSON Response

GetIlceInfo response returns in JSON format when the Typ parameter is set as "JSON".

Below is an example for a GetIlceInfo request which is expected to return a response in JSON format .

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetIlceInfo&Typ=JSON&Geometry=1&IlceId=10000441000&Encode=0

The response will be as following:

{ "transactionid": "LBS_53389802", "status": 0, "id": 10000441000, "name": "Balya", "latitude": 33.74996, "longitude": 26.57882, "extent": { "minlatitude": 38.66982304, "minlongitude": 22.280638, "maxlatitude": 35.95955, "maxlongitude": 25.83661084 } , "geometry": [ "27.83661084,39.91693698,27.83224908,39.92113899,27.83027304," ]}

transactionid: The id of response given by LocationBox Service. Every response can be tracked using transactionid when necessary.
status: Response format. (XML or JSON)

Status Codes
0 -- Success
1 -- Fail

errno: Error code
errdesc: Error definition

Error Codes
10001 Error processing your request. Please try again soon.
Cmd parameter is misspelled/not found.
10011 Error processing your request. Please check the Cmd parameter.
Cmd is not specified.
10012 Error processing your request. Please check the Key parameter.
Key is not specified.
10013 Error processing your request. Please check the Key parameter.
Key is invalid.
20012 No data found.

Mahalle Info (with Geometry)

Mahalle Info Service gives needed geographical information about districts.

GetMahalleInfo request must look like this:

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetMahalleInfo&Typ=output_format&Geometry=geometry&MahalleId=mahalleid&Encode=encode

Request Parameters


Key: LocationBox user key. (Register for user key)
Cmd: LocationBox service name. (GetIlInfo)
Typ: Response format. (XML or JSON)
MahalleId: (Check out for MahalleList)
Geometry: 1:With Geometry - 0:No Geometry.
Encode: 1: Geometry Encoding.
Keyword (optional): Add a keyword to narrow down Cmd results.

Response Parameters


XML Response

GetMahalleInfo response returns in XML format when the Typ parameter is set as "XML".

Below is an example for a GetMahalleInfo request which is expected to return a response in XML format .

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetMahalleInfo&Typ=XML&Geometry=1&MahalleId=10000441003&Encode=0

The response will be as following:

<response>
 <transactionid> LBS_37538710 </transactionid>
 <status> 0 </status>
 <errno />
 <errdesc />
  <mahalle>
   <id> 10000441003 </id>
   <adreskodu> 10382 </adreskodu>
   <postakodu> 10840 </postakodu>
   <name> EnverPaþa </name>
   <latitude> 39.80039 </latitude>
   <longitude> 27.5208 </longitude>
  <extent>
   <minlatitude> 39.80039 </minlatitude>...
   <geometry>
  <ordinates> 29.81985408,40.76798202,29.82039696,40.76806896,29.82143304,40.76820603,29.82174588,40.76824401 </ordinates>
  </geometry>
  </mahalle>
</response>

JSON Response

GetMahalleInfo response returns in JSON format when the Typ parameter is set as "JSON".

Below is an example for a GetMahalleInfo request which is expected to return a response in JSON format .

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetMahalleInfo&Typ=JSON&Geometry=1&MahalleId=10000441003&Encode=0

The response will be as following:


{ "transactionid": "LBS_53400076", "status": 0, "id": 10000441003, "adreskodu": "10382", "postakodu": "10840", "name": "Enverpaþa", "latitude": 39.74948, "longitude": 27.57802, "extent": { "minlatitude": 39.74239503, "minlongitude": 27.563481, "maxlatitude": 39.761766, "maxlongitude": 27.58464612 } , "geometry": [ "27.56442204,39.76036704,27.56366892,39.75983703,27.563481,39.75728004,27.58464612,39.74358798,27.583056,..." ]}

transactionid: The id of response given by LocationBox Service. Every response can be tracked using transactionid when necessary.
status: Response format. (XML or JSON)

Status Codes
0 -- Success
1 -- Fail

errno: Error code
errdesc: Error definition

Error Codes
10001 Error processing your request. Please try again soon.
Cmd parameter is misspelled/not found.
10011 Error processing your request. Please check the Cmd parameter.
Cmd is not specified.
10012 Error processing your request. Please check the Key parameter.
Key is not specified.
10013 Error processing your request. Please check the Key parameter.
Key is invalid.
20012 No data found.

Yol Info (with Geometry)

Yol Info Service gives needed geographical information about roads.

GetYolInfo request must look like this:

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetYolInfo&Typ=output_format&Geometry=geometry&YolId=yolid&Encode=encode


Request Parameters


Key: LocationBox user key. (Register for user key)
Cmd: LocationBox service name. (GetYolInfo)
Typ: Response format. (XML or JSON)
YolId: (Check out for YolList)
Geometry: 1:With Geometry - 0:No Geometry.
Encode: 1: Geometry Encoding.
Keyword (optional): Add a keyword to narrow down Cmd results.

Response Parameters


XML Response

GetYolInfo response returns in XML format when the Typ parameter is set as "XML".

Below is an example for a GetYolInfo request which is expected to return a response in XML format .

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetYolInfo&Typ=XML&Geometry=1&YolId=15895532&Encode=0

The response will be as following:

<response>
 <transactionid> LBS_37538710 </transactionid>
 <status> 0 </status>
 <errno />
 <errdesc />
 <suggestions>
  <suggestion>
   <id> 9519479 </id>
   <name> Sümeyye Sokak </name>
   <latitude> 40.76812 </latitude>
   <longitude> 29.8208 </longitude>
   <zoomlevel> 0 </name>
   <geometry>
  <ordinates> 29.81985408,40.76798202,29.82039696,40.76806896,29.82143304,40.76820603,29.82174588,40.76824401 </ordinates>
  </geometry>
  </yol>
</response>

JSON Response

GetYolInfo response returns in JSON format when the Typ parameter is set as "JSON".

Below is an example for a GetYolInfo request which is expected to return a response in JSON format .

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetYolInfo&Typ=JSON&Geometry=1&YolId=15895532&Encode=0

The response will be as following:


{ "transactionid": "LBS_37538729", "status": 0, "yol": { "id": 9519479, "name": "Sümeyye Sokak", "latitude": 40.76812, "longitude": 29.8208, "zoomlevel": 0, "geometry": [ "29.81985408,40.76798202,29.82039696,40.76806896,29.82143304,40.76820603,29.82174588,40.76824401,..." ] } }

transactionid: The id of response given by LocationBox Service. Every response can be tracked using transactionid when necessary.
status: Response format. (XML or JSON)

Status Codes
0 -- Success
1 -- Fail

errno: Error code
errdesc: Error definition

Error Codes
10001 Error processing your request. Please try again soon.
Cmd parameter is misspelled/not found.
10011 Error processing your request. Please check the Cmd parameter.
Cmd is not specified.
10012 Error processing your request. Please check the Key parameter.
Key is not specified.
10013 Error processing your request. Please check the Key parameter.
Key is invalid.
20012 No data found.

Kapý Info (with Geometry)

Kapý Info Service gives needed geographical information about doors.

GetKapiInfo request must look like this:

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetKapiInfo&Typ=output_format&Geometry=geometry&KapiId=kapiId&Encode=encode


Request Parameters


Key: LocationBox user key. (Register for user key)
Cmd: LocationBox service name. (GetYolInfo)
Typ: Response format. (XML or JSON)
KapiId Or AdresKodu : (Check out for KapiList)
Geometry: 1:With Geometry - 0:No Geometry.
Encode: 1: Geometry Encoding.
Keyword (optional): Add a keyword to narrow down Cmd results.

Response Parameters


XML Response

GetYolInfo response returns in XML format when the Typ parameter is set as "XML".

Below is an example for a GetYolInfo request which is expected to return a response in XML format .

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetKapiInfo&Typ=XML&Geometry=1&KapiId=255119051&Encode=0

The response will be as following:

<response>
 <transactionid> LBS_547515518 </transactionid>
 <status> 0 </status>
 <errno />
 <errdesc />
 <kapi>
   <id> 255119051 </id>
   <adreskodu> 27006517 </adreskodu>
   <postakodu> 34275 </postakodu>
  </name>
   <no> 161 </no>
   <geometry>
  <ordinates> 28.74061296,41.21193699 </ordinates>
  </geometry>
  </kapi>
</response>

JSON Response

GetKapiInfo response returns in JSON format when the Typ parameter is set as "JSON".

Below is an example for a GetKapiInfo request which is expected to return a response in JSON format .

http://www.locationbox.com.tr/locationbox/services?Key=key&Cmd=GetKapiInfo&Typ=JSON&Geometry=1&KapiId=255119051&Encode=0

The response will be as following:


{ "transactionid": "LBS_547514368", "status": 0, "kapi": { "id": 255119051, "adreskodu": 27006517, "postakodu": "34275", "name": "", "no": "161", "geometry": ["28.74061296,41.21193699" ]} }

transactionid: The id of response given by LocationBox Service. Every response can be tracked using transactionid when necessary.
status: Response format. (XML or JSON)

Status Codes
0 -- Success
1 -- Fail

errno: Error code
errdesc: Error definition

Error Codes
10001 Error processing your request. Please try again soon.
Cmd parameter is misspelled/not found.
10011 Error processing your request. Please check the Cmd parameter.
Cmd is not specified.
10012 Error processing your request. Please check the Key parameter.
Key is not specified.
10013 Error processing your request. Please check the Key parameter.
Key is invalid.
20012 No data found.