-
Notifications
You must be signed in to change notification settings - Fork 33
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 new return parameters Country Code and Country Name #21
Add new return parameters Country Code and Country Name #21
Conversation
* Add new return parameters Country Code and Name More Details for Roaming Status camaraproject#18 :- With reference to this issue on CAMARA we added new return parameter 1. Country Code 2. Country Name * Added description and e.g. for Country Code & Name * YAML Update version number
CountryCode: | ||
description: The country calling code as an identifier for the country and the dependent areas. | ||
type: string | ||
example: "49" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The API should return the mobile country code (MCC) rather than country calling code. Some mobile networks do not have an associated country calling code. MCC for Germany is 262.
Return type should be integer, not a string.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for feedback we updated YAML and pushed commit in this PR.
YAML: We updated YAML to change the country calling code to Mobile country code and data type from string to integer
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do these new fields always return value? What happens if "eventStatus" is "ROAMING_OFF"? It returns the country information where the mobile belongs to?
type: integer | ||
example: 262 | ||
CountryName: | ||
description: The ISO Code of the country. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't it better to say "Alpha‑2 code" for example or mention it's a two character code? Don't you think ISO Code can be ambiguous?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Another thing is that, it seems that in some cases there isn't a 1:1 relationship between: MCC and ISO Country code:
340 | BL/GF/GP/MF/MQ |
---|---|
647 | YT/RE |
What we expect to happen in those cases?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your feedback. I will update the same with Alpha-2-code
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with @monamok: Please rename it to:
CountryName:
description: The ISO 3166 ALPHA-2 code of the country. It can also include a list of codes, if more than one country have the same MCC.
@@ -8,7 +8,7 @@ info: | |||
license: | |||
name: Apache 2.0 | |||
url: https://www.apache.org/licenses/LICENSE-2.0.html | |||
version: 0.2.0 | |||
version: 0.2.1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we add it as a fix or should we start with 0.3.0?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes I also agree that this is big change so instead of fixing we should go with 0.3.0
- countryCode | ||
- countryName |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
countryCode
and countryName
should not be required
. Even if we agree that the home countryCode
and countryName
can be returned when the device is not roaming (this information can probably be deduced from ueId
anyway), we need to consider user consent.
The user may consent to their roaming status being made available to the API caller, but not the country in which they are roaming. Providing the roaming country provides much more information on the device location than just knowing that the device is not in the home country.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we need to consider user consent.
The user may consent to their roaming status being made available to the API caller, but not the country in which they are roaming. Providing the roaming country provides much more information on the device location than just knowing that the device is not in the home country.
You're right about user consent. How are we going to manage and seperate these cases? By having different scopes?
YAML Update:- With reference to review comments we updated the API version and description of Country Name and removed countryName and countryCode from required
Hello |
Also, for some MCC (principally 901), there is no associated country. So we need to decide whether a device roaming on an international network should return no countryName field at all, a blank countryName ( |
Maybe for such 9xx we can go with "worldwide"? |
With reference to comment:- list of country for one MCC probably cleaner to have an array of countryName instead of one string. We have updated country name data type to array.
We updated data type of country name from string to array for multiple country name. |
type: array | ||
items: | ||
type: string | ||
example: [BL,GF,GP,MF,MQ] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd like to see multiple examples here (using keyword examples
rather than example
):
- No associated country
[]
- Single associated country e.g.
["DE"]
- Multiple associated countries e.g.
["BL","GF","GP","MP","MQ"]
The current example with multiple countries would be rare in practice. The usual response would be a single country, so the description should be extended to explain why multiple countries or no country may be returned.
My current preference for no associated country is an empty array, but an alternative would be ["XX"]
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We Updated YAML with all three Examples with extended description.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello @ravindrapalaskar17
I agree with @eric-murray about "No associated country" case. I think an empty array [] is a better choice. Is there any reason why you prefer to return ["XX"]?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ravindrapalaskar17 let's go with an empty array for an undefined countryName.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for feedback we updated YAML with empty array.
We added three examples of (no-countrycode, single-countrycode --multiple-cc) with some extended description.
value: | ||
ueId: | ||
msisdn: 123456789 | ||
uePort: 5090 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A minor point, but parameter uePort
is superfluous here. This parameter is only required if the UE is identified by IPv4 address. But as all three example use msisdn
, then uePort
is not required. It's not incorrect to include it, but the examples would be cleaner if this was removed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update YAML:- Removed uePort from examples
@NoelWirzius |
@eric-murray yes we can go merge this |
Now merged |
More Details for Roaming Status #18 :- With reference to this issue on CAMARA we added new return parameter