Activity Starter: data uri with specific app

Can I start activity to a specified app or package name
Action=android.intent.action.VIEW
uri=…

How to start this activity with a specified app/package

I do not understand the question, but you might find an answer to your question here
Using the Activity Starter
Taifun

@Taifun
I have an uri data
I want to show user all available apps for that uri
https://appinventor.mit.edu/explore/ai2/activity-starter.html

Figuring out how to set the properties

If you can’t find documentation for the activities you want to start, one way to figure out how to set the properties is to start up the activity manually and look at what appears in the Android System Log. For example, if you use YouTube to play a video, you’ll see in the log:

I/ActivityManager( 86): Starting activity: Intent { act=android.intent.action.VIEW cat=[android.intent.category.BROWSABLE] dat=http://www.youtube.com/watch?v=8ADwPLSFeY8 flg=0x3800000 cmp=com.google.android.youtube/.PlayerActivity }

If you can find the “cmp=” string, then the ActivityPackage is the part before the slash, and the ActivityClass is is the entire “cmp=” part, without the slash character. As in the YouTube example, there may also be “dat=” information that can specify with the DataUri property.

I do not understand the question, but maybe this can help you:

@Taifun
@pepocero
I want to accept Upi payments in my app
I want to get get list of Activity Packages and Activity Classes
So I can show user available apps and when user selects an app, my app will start an activity with a package and class

See my previous reply, See that paragraph in that page
https://appinventor.mit.edu/explore/ai2/activity-starter.html
It says that we can get package and class if we don’t know

the packagemanager extension can provide a list
https://puravidaapps.com/packagemanager.php
Taifun

2 Likes

How do I get ActivityClass for a package that makes upi payment
You may to suggest me to install an app to get list of activities. But do I know the class for UPI payment even if I find, class may differ according to version of upi apps
I started an activity with action and uri for upi payment, system showed apps to select and asked to open it just once or always(set default) I selected Shareit app and selected always after I closed app.
I set label.text to Resolve activity
Next time when I started activity it label text shows class of Shareit app which makes upi payment
But here is a problem I noticed that shareit old and versions use different class

@pepocero
@Taifun
I am asking that like android systems shows app list starting activity from my app, in the same way I want show that apps list in my own app’s interface and start activity when user chooses app in my app’s interface then my app redirect user to selected app

For this:
1.My app gives action and uri
2.My app gets a list of apps for that action with packages and classes list
Question: How can I do this?

1 Like

well, I do not know
the packagemanager extension can give you the properties of all installed apps of the device
the challenge now is to find out, which of these apps are able to make upi payments

Taifun

I don’t know either.

But if you want to accept UPI payments, why not use the API they provide?
https://www.unionpayintl.com/api/en/

https://www.indiastack.org/upi/

1 Like

Use Deep Host Extension I think Name Of That Extension is app launcher extension

This might help you accept UPI payments: