helium / blockchain-http

An http API for the helium blockchain database
https://helium.com
Apache License 2.0
47 stars 18 forks source link

Different longitude variable names #368

Closed alex-bellon closed 2 years ago

alex-bellon commented 2 years ago

In the response for api.helium.io/v1/hotspots/location/distance, api.helium.io/v1/hotspots/:address, etc. the longitude variable is named lng, but in the request for api.helium.io/v1/hotspots/location/distance it uses the variable name lon.

Maybe the request for api.helium.io/v1/hotspots/location/distance could also support lng as not to break anything.

madninja commented 2 years ago

Definitely annoying that we missed that naming inconsistency. Is this request for a fix just for consistency reasons or do you have a specific library/use in mind that relies on the name being the same? If the former I'd rather not add more logic

alex-bellon commented 2 years ago

The request was for consistency, I had just come across the discrepancy when writing a script that was using the API and was getting errors when I tried using lng. I understand not wanting to add more logic though so feel free to close the issue.