GeoNames Home | Postal Codes | Download / Webservice | About 

GeoNames Forum
  [Search] Search   [Recent Topics] Recent Topics   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
'get' and 'getJSON' API calls not returning isHistoric and from/to on alternatenames  XML
Forum Index -> General
Author Message
jbonevich



Joined: 09/06/2021 05:14:55
Messages: 3
Offline

Hello! Wonderful data and service APIs! However, I may have found a bug, in that the 'get' API call does not return an 'isHistorical' attribute or element on <alternatename>s, nor does it return the from and to dates. Example:
curl -s 'http://api.geonames.org/get?geonameId=2940132&username=xxxx' for Chemnitz which has an historic alternate name of Karl-Marx-Stadt from 1953 to 1990 on the web page.

[code]
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<geoname>
<toponymName>Chemnitz</toponymName>
<name>Chemnitz</name>
...
<alternateName lang="hsb">Kamjenica</alternateName>
<alternateName>Karl-Marx-Stadt</alternateName>
<alternateName lang="wkdt">Q2795</alternateName>
...
[code]

Similarly, getJSON API does not return the from/to, but does include isHistoric: curl -s 'http://api.geonames.org/getJSON?geonameId=2940132&username=xxxx':

[code]
{
"timezone": {
"gmtOffset": 1,
"timeZoneId": "Europe/Berlin",
"dstOffset": 2
},
"bbox": {
"east": 12.935455008545484,
"south": 50.82300147294829,
"north": 50.85798587982261,
"west": 12.89368993723815,
"accuracyLevel": 0
},
"asciiName": "Chemnitz",
...
"alternateNames": [
...
{
"name": "Karl-Marx-Stadt",
"isHistoric": true
},
...
[code]

jeff
marc



Joined: 08/12/2005 07:39:47
Messages: 4282
Offline

You are right the isHistoric came later and the from/to is even younger.

We could add it like this:

Code:
  <alternateName isHistoric=true from=1953 to=1990 >Karl-Marx-Stadt</alternateName> 
 


similar for the json format.

What do you think?

Marc

[WWW]
jbonevich



Joined: 09/06/2021 05:14:55
Messages: 3
Offline

That makes perfect sense to me!
 
Forum Index -> General
Go to:   
Powered by JForum 2.1.5 © JForum Team