Last active
March 8, 2026 05:08
-
-
Save devprantoroy/80e430e2312f4f68c9366c09b86f5297 to your computer and use it in GitHub Desktop.
Google Android Management API policy
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 'applications' => [ | |
| new ApplicationPolicy([ | |
| 'packageName' => 'com.android.vending', | |
| 'installType' => 'FORCE_INSTALLED', | |
| ]), | |
| new ApplicationPolicy([ | |
| 'packageName' => 'com.google.android.apps.work.clouddpc', | |
| 'installType' => 'FORCE_INSTALLED', | |
| ]), | |
| new ApplicationPolicy([ | |
| 'packageName' => 'com.wealbeing.app', | |
| // 'installType' => 'KIOSK', //FORCE_INSTALLED or REQUIRED_FOR_SETUP | |
| 'installType' => 'FORCE_INSTALLED', //FORCE_INSTALLED or REQUIRED_FOR_SETUP | |
| 'lockTaskAllowed' => true, | |
| 'defaultPermissionPolicy' => 'GRANT', | |
| 'delegatedScopes' => [ | |
| 'MANAGED_CONFIGURATIONS', | |
| ], | |
| ]), | |
| ], | |
| /* ---------------- ACCOUNT ---------------- */ | |
| 'modifyAccountsDisabled' => null, // allow personal Gmail | |
| /* ---------------- SECURITY ---------------- */ | |
| 'factoryResetDisabled' => true, | |
| 'safeBootDisabled' => true, | |
| 'usbFileTransferDisabled' => true, | |
| /* ---------------- PERMISSIONS ---------------- */ | |
| 'defaultPermissionPolicy' => 'GRANT', | |
| 'permittedAccessibilityServices' => [ | |
| 'packageNames' => [ | |
| 'com.google.android.apps.work.clouddpc', | |
| 'com.wealbeing.app', | |
| ], | |
| ], | |
| /* ---------------- FRP ---------------- */ | |
| 'frpAdminEmails' => [ | |
| trim($settings->frp_email) ?? 'seasyemi@gmail.com' | |
| ], | |
| /* ---------------- PLAY STORE ---------------- */ | |
| 'playStoreMode' => 'BLACKLIST', | |
| 'installAppsDisabled' => false, | |
| /* ---------------- SUPPORT ---------------- */ | |
| 'shortSupportMessage' => [ | |
| 'defaultMessage' => 'Device managed by IT Admin (Team).', | |
| ], | |
| 'longSupportMessage' => [ | |
| 'defaultMessage' => 'For support, contact IT Admin (Team) for any issues.', | |
| ], | |
| // --- ADVANCED SECURITY (Allows your app to be installed) --- | |
| 'advancedSecurityOverrides' => [ | |
| 'untrustedAppsPolicy' => 'ALLOW_INSTALL_DEVICE_WIDE', // Allows apps from Play Store | |
| ], | |
| // lock device after 1 day and wipe device after 10 days | |
| 'policyEnforcementRules' => [ | |
| new PolicyEnforcementRule([ | |
| 'settingName' => 'applications', // any top-level setting name | |
| 'blockAction' => new BlockAction([ | |
| 'blockAfterDays' => 365, // 1 year | |
| 'blockScope' => 'BLOCK_SCOPE_DEVICE' | |
| ]), | |
| 'wipeAction' => new WipeAction([ | |
| 'wipeAfterDays' => 365, // 1 year | |
| 'preserveFrp' => true | |
| ]) | |
| ]) | |
| ], | |
| 'installUnknownSourcesAllowed' => true, | |
| 'debuggingFeaturesDisabled' => true, | |
| 'appAutoUpdatePolicy' => 'ALWAYS', | |
| 'mountPhysicalMediaDisabled' => true, | |
| 'uninstallAppsDisabled' => true, | |
| 'locationMode' => 'LOCATION_ENFORCED', | |
| 'wifiConfigDisabled' => false, | |
| 'debuggingFeaturesAllowed' => false, | |
| 'networkResetDisabled' => true, | |
| 'shareLocationDisabled' => false, | |
| 'advancedSecurityOverrides' => new AdvancedSecurityOverrides([ | |
| 'developerSettings' => 'DEVELOPER_SETTINGS_DISABLED' | |
| ]), | |
| 'kioskCustomization' => new KioskCustomization([ | |
| 'powerButtonActions' => 'POWER_BUTTON_BLOCKED' | |
| ]), | |
| // Disable USB after factory reset when FRP admin is applied | |
| 'deviceConnectivityManagement' => new DeviceConnectivityManagement([ | |
| 'usbDataAccess' => 'DISALLOW_USB_DATA_TRANSFER' | |
| ]), | |
| // /* ---------------- UI ---------------- */ | |
| 'statusBarDisabled' => false, | |
| 'keyguardDisabled' => false, | |
| 'screenCaptureDisabled' => false, | |
| // Enable kiosk mode | |
| 'kioskCustomLauncherEnabled' => false, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment