Address abbreviation

Basic principles

The query takes as input an address (broken down into an address line, post code, town) and the size of the required standardised abreviation (32 or 38).

The service returns as output an abbreviation of the address line part following the rules expressed in the corresponding AFNOR standards (32 character standard and 38 character standard).

Concerning the restitution function of the 38-character address line, only the AFNOR NF Z10-011 standard dating from January 2013 (in 38 characters) will be applicable.

Concerning the restitution function of the 32-character address line;

  • In the first place the AFNOR NF Z10-011 standard from January 2013 (in 38 characters) will be aplicable:

    • with regard to the rules for reduction, but up to the target of 32 characters,
    • with regard to the abbreviation of words, including those that have not been defined in Appendix B of the standard NF Z10-011 dating from August 1989 (in 32 characters).
  • The state of play currently is that, following the application of AFNOR standard NF Z10-011 in January 2013, the NF Z10-011 standard dating from August 1989 (in 32 characters) will be applicable in relation to abbreviations of words, but only if the maximum length requested is 32 and if the resulting length remains higher than 32 characters. In this case, it will be limited to application of abbreviations from Appendix B of the NF Z10-011 standard dating from August 1989 (in 32 characters) for which the AFNOR standard NF Z10-011 of January 2013 in its various appendices does not suggest any abbreviation.

This service interrogates files of abbreviations, copying the appendices of the AFNOR standards cited.

Address abbreviation example

{
        "url":"https://api.geoconcept.com/EU/GCW/geoconcept-web/api/lbs/normalizer.json",
        "type":"GET",
        "params": {
                "addressLine": {
                        "sample":"25 Boulevard du Maréchal de Lattre de Tassigny"
                },
                "postCode": {
                        "sample":"77140"
                },
                "city": {
                        "type":"string",
                        "sample":"Nemours"
                },
                "maxLength": {
                        "sample":"32"
                }
        }
}

Parameters / properties

Input

parameter description optional default

maxLength

maxLength defines, in the form of an integer, the reference size to attain for the abbreviation of the address line. Values accepted are exclusivement 32 or 38.

yes

38

addressLine

The address line receiving, EITHER the street in the form number, repetition index, type of street and street name, OR the place name (in France this is the LIEU-DIT). The accuracy of the address abbreviation as output from the WS can only be ensured on condition that an address line parameter resulting from a validated address using an Address repository is supplied.

no

city

Town corresponding to the address line entered. No treatment will be applied to this parameter.

yes

postCode

Post code corresponding to the address line supplied. No treatment will be applied to this parameter.

yes

Output

parameter type min/max description

id

long

1/1

Automated increment of the response identifier.

status

string

0/1

Indicates the success or failure of the abbreviation process «OK» or «ERROR».

statusDetails

string

0/1

Empty, in the case of a succesful abbreviation process. With the corresponding error message, in the event of failure,
"Invalid maxLength parameter. It needs to be either 32 or 38".
"The address contraction can’t reach the expected maxLength".
"The supplied addressline was above 100 characters".

maxLength

int

1/1

Takes the value supplied in input «32» or «38».

address

array (normalizedAddress)

0/1

Standardised address.

normedAddressLineLength

int

1/1

Length of the address line obtained, following the operations of abbreviation applied by the service.

Standardised address (normalizedAddress)

parameter type min/max description

normedAddressLine

string

0/1

Final result of the contraction of the address line applied by the service.

city

string

0/1

Returns the town supplied as input, without modification, (otherwise empty).

postCode

string

0/1

Returns the post code supplied as input, without modification, (otherwise empty).

Possible returns

case of a standardised address (status is OK) 

{
  "id": 1,
  "status": "OK",
  "statusDetails": "",
  "maxLength": 32,
  "address": {
    "normedAddressLine": "25 BD MAL DE LATTRE DE TASSIGNY",
    "city": "Nemours",
    "postCode": "77140"
  },
  "normedAddressLineLength": 31
}

Case of setting the reduction size to a value other than «32» or «38» (status is ERROR) 

{
  "id": 2,
  "status": "ERROR",
  "statusDetails": "Invalid maxLength parameter. It needs to be either 32 or 38",
  "maxLength": 0,
  "address": {
    "normedAddressLine": "",
    "city": "",
    "postCode": ""
  },
  "normedAddressLineLength": 0
}

Case of an address of more than 100 characters (status is ERROR) 

{
  "id": 3,
  "status": "ERROR",
  "statusDetails": "The supplied addressline was above 100 characters",
  "maxLength": 0,
  "address": {
    "normedAddressLine": "",
    "city": "",
    "postCode": ""
  },
  "normedAddressLineLength": 0
}

Case of failure in contraction of the address line in terms of the expected size (status is ERROR) 

{
  "id": 4,
  "status": "ERROR",
  "statusDetails": "The address contraction can't reach the expected maxLength",
  "maxLength": 0,
  "address": {
    "normedAddressLine": "125 B BD MAL J B F X L TASSIGNY INF",
    "city": "Nemours",
    "postCode": "77140"
  },
  "normedAddressLineLength": 35
}