TL;DR: it is HTTP redirect based on User-Agent header
Just have a branded link (like https://slyp.app/Slyp or https://slyp.app/SlypBusiness) to the official web page and have the js in that page auto-redirect and open the original Playstore/Appstore page.
And yes, we used userAgent for identifying the platform.
If anyone is interested, here is the code
window.addEventListener('DOMContentLoaded', (event) => {
let app = 'Slyp'
var userAgent = navigator.userAgent.toLowerCase();
if (userAgent.indexOf('android') > -1) {
window.location.href = `https://play.google.com/store/apps/details?id=com.ndcurve.${app}`;
} else if (userAgent.indexOf('iphone') > -1 || userAgent.indexOf('ipod') > -1 || userAgent.indexOf('ipad') > -1 || userAgent.indexOf('mac') > -1) {
if (app === "Slyp")
window.location.href = 'https://apps.apple.com/app/<app_id>';
else if (app === "SlypBusiness")
window.location.href = 'https://apps.apple.com/app/<app_id>';
else
window.location.href = 'https://slyp.app';
} else {
window.location.href = `https://play.google.com/store/apps/details?id=com.ndcurve.${app}`;
}
});
Tiberium•44m ago
ericpauley•42m ago
matthuggins•21m ago