This page describes the responses returned by the CityDate APIs.
Related CityDate documentation:
CPFRA response
Success response
The JSON response is a dictionary containing one or more elements. Each element contains the following keys:
| Key | Possible values | Description | Type |
|---|---|---|---|
| Insee | 75113 |
INSEE code of the city. | STRING(10) |
| Localite | Paris |
City name. | STRING(50) |
| Pays | FR |
ISO 2 country code. | STRING(2) |
| CodePostal | 75013 |
Postal code of the city. | STRING(10) |
| Status |
OK / KO
|
Indicates whether the city is valid for the given birthdate. | STRING(2) |
Example:
{
"1": {
"Localite": "EVRY",
"Pays": "FR",
"Insee": "89162",
"CodePostal": "89140",
"Status": "OK"
},
"3": {
"Localite": "EVRY",
"Pays": "FR",
"Insee": "91228",
"CodePostal": "91080",
"Status": "KO"
},
"2": {
"Localite": "EVRY",
"Pays": "FR",
"Insee": "91228",
"CodePostal": "91000",
"Status": "KO"
}
}
BirthLocality response
Success response
The JSON response contains the total number of results found and an array of returned localities.
| Key | Description | Type |
|---|---|---|
| Found | Total number of results found. | INTEGER |
| Results | List of returned localities. | ARRAY |
| Results.City | Locality name. | STRING(50) |
| Results.CountyCode | County or department code. | STRING(2) |
| Results.CountyLabel | County or department label. | STRING(50) |
| Results.CountryCode | Country or DROM code. | STRING(2) |
| Results.CountryLabel | Country or DROM label. | STRING(50) |
| Results.CodeInsee | Locality INSEE code. | STRING(5) |
| Results.ValidityStartDate | Start date of INSEE code validity. | DATE (YYYY-MM-DD) |
| Results.ValidityEndDate | End date of INSEE code validity. Empty if the code is still valid. | DATE (YYYY-MM-DD) / NULL |
Country and DROM codes
| Label | Code |
|---|---|
| FRANCE | FR |
| GUADELOUPE | GP |
| MARTINIQUE | MQ |
| GUYANE | GF |
| LA REUNION | RE |
| MAYOTTE | YT |
| SAINT PIERRE ET MIQUELON | PM |
| SAINT BARTHELEMY | BL |
| SAINT MARTIN | MF |
| POLYNESIE FRANCAISE | PF |
| NOUVELLE CALEDONIE | NC |
| WALLIS ET FUTUNA | WF |
| LES TERRES AUSTRALES ET ANTARTIQUES FRANCAISES | TF |
Example:
{
"Found": 3,
"Results": [
{
"City": "AAST",
"CountyCode": "64",
"CountyLabel": "PYRENEES-ATLANTIQUES",
"CodeInsee": "64001",
"ValidityStartDate": "1943-01-01",
"ValidityEndDate": ""
},
{
"City": "ABAINVILLE",
"CountyCode": "55",
"CountyLabel": "MEUSE",
"CodeInsee": "55001",
"ValidityStartDate": "1943-01-01",
"ValidityEndDate": ""
},
{
"City": "ABANCOURT",
"CountyCode": "59",
"CountyLabel": "NORD",
"CodeInsee": "59001",
"ValidityStartDate": "1943-01-01",
"ValidityEndDate": ""
}
]
}
Related to