final Uri packageURI = Uri.parse("package:" + "package:com.example.mypackage");
final Intent uninstallIntent = new Intent(Intent.ACTION_UNINSTALL_PACKAGE, packageURI);
uninstallIntent.putExtra("android.intent.extra.UNINSTALL_ALL_USERS", false or true);
startActivity(uninstallIntent);
You can check out this answer from where I've taken reference - Is there an intent for uninstallation of an app for ALL users?
What is mean by multiple user?
If you have a used laptop or machine, then you may already be familiar with the concept here: Where you can create multiple accounts with different roles. It’s like having multiple machines wrapped into one.
Android has a very similar feature built in called User Profiles. It will create a separate profiles where one can make changes and keep multiple settings. But yeah when users installs app it will automatically will be installed in all profiles so end user need manually uninstall it in the profile where it is not required.
I tried using this in my device but performance is bit slow after I added multiple profile.