QueryMyRegion
The queryMyRegion
API is used to query a player's region or country information based on their IP address.
Request Sample
accountApi.queryMyRegion().then(
(res) => {
console.log(res);
}
);
Response Parameter
Parameter | Type | Description |
---|---|---|
ret | number | Return code 0: Request success, parse related returned field information. !=0: Request failure, check msg for the detailed return message. |
msg | string | Return message |
alpha2 | string | ISO 3166-1 Alpha 2 code for country or region. For example, CN for China, AT for Austria. |
region | string | ISO 3166-1 numeric code for country or region For example 156 for China, 040 for Austria |
timestamp | number | Unix timestamp |
seq | string | Sequence number of the message in the data stream |
Response Sample
{
ret: 0,
msg: "success",
alpha2: "HK",
region: "344",
seq: "1639128374-0343981578-017512-0000925611",
timestamp: 1639128374,
}