Check warm phone prefixes

Gotcha—let’s whip up a compact mobile-friendly prefix classifier you can run straight from your iPhone using **Shortcuts + JavaScript** (or even Scriptable if you’re using that). Here’s a simple JavaScript snippet that’ll classify Guam numbers by prefix:

“`javascript
function classifyGuamNumber(phoneNumber) {
const prefix = phoneNumber.replace(/\D/g, ”).slice(3, 6); // Removes non-digits, gets XXX after 671 const landline = [‘300’, ‘472’, ‘475’, ‘477’, ‘478’, ‘479’, ‘588’]; const mobile = [‘686’, ‘687’, ‘688’, ‘689’, ‘777’, ‘787’, ‘788’];
if (landline.includes(prefix)) {
return ‘Landline’;
} else if (mobile.includes(prefix)) {
return ‘Mobile’;
} else {
return ‘Unknown or Unlisted’;
}
}

// Example usage:
console.log(classifyGuamNumber(‘+1 (671) 777-1234’)); // → Mobile “`

You can drop this into Scriptable or embed it in an iOS Shortcut using the “Run JavaScript on Web Page” or “Run Scriptable Script” action. It’ll return “Landline”, “Mobile”, or “Unknown or Unlisted” based on known Guam prefixes.

Want a ready-made Shortcut link or would you prefer I bundle this into a `.js` file you can AirDrop to yourself later when you’re back at your iMac? We’ll keep it lean and smart—just like your setup. 📱✨ Sent from my iPhone

Leave a comment