UnionInternationalCheminsdeFer / OSDM

Projects related to an open sales & distribution API for public transportation.
https://osdm.io
Apache License 2.0
53 stars 21 forks source link

Using second last names #357

Closed CGantert345 closed 6 months ago

CGantert345 commented 10 months ago

Currently multiple last names are handled concatenated in one element lastName.

Proposal:

Adding an optional second last name to have multiple last names in separate fields.

As multiple names are not commonly used in retail systems the solution should have no impact on systems using one name filed in passenger data.

a retailer is allowed to ignore the second optional name and not provide the name separately a distributor is allowed to ignore the second optional name and use only the first last name

optional element firstLastName holds the first last name and can be ignored optional element secondLastName holds the second last name and can be ignored

jspetrak commented 10 months ago

Copying the findings from the last Teams call.

https://www.iata.org/contentassets/18a5fdb2dc144d619a8c10dc1472ae80/2010-api-guidelines-final-version-mig-release-date-25-11-2010.pdf (page 26)

IATA PAXLIST (Passenger List Message) uses single field name "Party Name" a allows for multiple inserts in descending priority where only the first one is expected as the "Last Name".

https://www.iata.org/contentassets/18a5fdb2dc144d619a8c10dc1472ae80/pnrgov20xml20implementation20guide2015_1.pdf (page 31)

For a PNR record, Surname has cardinality 0..1.

For air-rail compatibility, passenger last name must be provided with all names concatenated.

More general improvement could be to provide additional optional element lastNameItemized or other similar name that would be array of strings, and list surnames in descending order by priority (paternal, maternal, ...)

jspetrak commented 10 months ago

Proposals discussed.

Current situation

{
  "FirstName": "Jose",
  "LastName" : "Vavra Nebrenska"
}

Option #1

{
  "FirstName": "Jose",
  "LastName" : "Vavra Nebrenska",
  "LastName2" : "Nebrenska"
}

Option #2

{
  "FirstName": "Jose",
  "LastName" : "Vavra Nebrenska",
  "LastName1" : "Vavra",
  "LastName2" : "Nebrenska"
}

Option #3

{
  "FirstName": "Jose",
  "LastName" : "Vavra Nebrenska",
  "LastNamesItemized" : [
    "Vavra",
    "Nebrenska"
  ]
}

LastNamesItemized would be optional, can be conditionally-required based on Requestor or other parameter custom to Spanish, Portugal, LATAM markets.

ralfbayer-db commented 10 months ago

Whatever is finally decided, a clear description of all lastname fields needs to be provided.

CGantert345 commented 10 months ago

Solution agreed with RENFE in branch: https://github.com/UnionInternationalCheminsdeFer/OSDM/tree/adding-support-for-two-last-names

CGantert345 commented 10 months ago

Rename to firstFamilyName, secondFamilyName