-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Postal Code as a type of Area #39
Comments
To provide my feedback.... in France we have postalCode but another code is used for geographic purpose: the INSEE code (the postal code is more an administrative one).
GeoCode:
type: object
required:
- type
- code
- codeType
properties:
type:
type: string
enum:
- GeoCode
description: Type of this area
code:
type: string
description: Code (aka Zip code or Postcode), according to the code type.
codeType:
type: string
description: Type of code (could be Postcode, INSEE Code, etc...),
countryCode:
type: string
pattern: '^[A-Z]{2}$'
description: ISO 3166-1 alpha-2 code for the country. Uppercase. If not specified, each implementation may apply a default value. 2/ leverage the polymorphic model and provide explicit specialization. In this case we keep your proposal and for example I add a structure for inseeCode. I think that for a developer, option 2 is probably better as more explicit, but we need to find a way to expose by code the model managed by an implementation (If Telefonica managed Circle & postalCode while Orange manage Circle & insee code and then DT Circle & polygon ...developer should be able to get this information on the fly). |
There is no global standard for postal codes and it does not always point to a geographical area (and in cases it does point to a geographical area the size thereof can vary a lot depending on if it is a rural or urban area). As for user friendly. In which scenarios would you benefit from using a postal code? If it is an app on a device I assume it would retrieve the GPS data. If it is a person to enter the information is not the city/part of city/address more commonly known? |
For location verification, the idea is to provide the customer with options, and they will decide which area they want to verify. Postal codes are an option in addition to Circles, or other supported areas. The logic to match certain post code with certain geographic polygon must reside on the server, and there may be scenarios where the provided input is not a valid postal code and an error should be responded. In some countries the postal code is commonly used for localization purposes. For example, some companies serve only certain areas delimited by postal codes. As said, in the end it will be up to a customer to chose the type of area, among the available ones, that fits their needs better. |
Hi @jlurien @JoachimDahlgren |
@bigludo7 It makes sense that all implementations support at least the Circle, which is the simplest option. We can add that to the documentation. |
Proposal for new Area type: Postal Code, as discussed in #39
On the edge between two postal code areas the accuracy requirement will be meters - one side or another side of a street. |
Verification is always a matching between 2 areas, the one provided by the client and one known by the server. Postal codes are polygons instead of circles but the considerations are the same, as if you consider a very small circle vs a big circle as input . |
I had not noticed the new "partial" response. But there are still problems. Post number areas, at least in Sweden are for post delivery (like in France), other uses are not considered*. And "Postal codes are a common user friendly denominations for known areas", no they are not. The only use I see is when adding an object for sale on ebay if they want to verify the address given.
|
Postal codes are country dependent and the use cases are also country dependent. The API does not force clients to use certain type of area, so they will choose what fits better to their interest among the areas supported by the provider. Circles are the simplest type of area and it will be always supported. |
The API forces the provider to at least consider adding it (provider unique database with polygons is the possible implementation). Additions to APIs have costs. |
I echo the points above about this not being practical. Here's a document showing how difficult it would be to implement: You couldn't even use the 'centre of a postcode' because that may not even be inside the postcode when postcodes include non-contiguous areas. By all means any CSP could turn a postcode into a point reference and radius with some API, but I don't think it can be standardised in CAMARA. |
Reopen as issue #83, officially requested by GSMA Product Stream, moving discussion there |
Postal codes are a common user friendly denominations for known areas.
Proposal is to add a new type of Area
PostalCode
Optionally a country code may be needed in some global scenarios. Otherwise, each implementation may assume its own country.
There is no global pattern for postal codes. We could define some limits minLength , maxLength, apparently longest one is 10, but it may be better to leave all format verification to implementations.
The text was updated successfully, but these errors were encountered: