my.getSiteInfo
Use this API to obtain the site information assigned by Alipay+ which is used in Alipay+ business, such as the site name.
Note:
Please make sure you use the Appx with 1.24.6 or higher versions in order to use this API.
Sample code
copy
my.getSiteInfo({
success: (res) => {
my.alert({
content: JSON.stringify(res),
});
},
fail: (res) => {
my.alert({
content: JSON.stringify(res),
});
}
});
Input Parameters
Property | Type | Required | Description |
success | Function | No | Callback function upon call success. |
fail | Function | No | Callback function upon call failure. |
complete | Function | No | Callback function upon call completion (to be executed upon either call success or failure). |
Success Callback Function
Property | Type | Description |
siteName | String | The site name assigned by Alipay+ which can be used in Alipay+ business. Following values are supported: EASYPAISA DANA GCASH TRUEMONEY TNG BKASH KAKAOPAY ALIPAY_CN ALIPAY_HKÂ |
An example of a successfully returned message is as follows:
copy
{
"siteName":"EASYPAISA"
}