Intent from Android Studio to Tasker

51 views
Skip to first unread message

Le- Ze

unread,
Sep 1, 2025, 2:15:41 AM (5 days ago) Sep 1
to Tasker
Hi.
I try to get the intent on Tasker and I don't know.
They need Android Studio and Tasker communication.
https://android.stackexchange.com/questions/174440/sending-an-intent-to-tasker-from-tasker
Event → System → Intent Received
I don't have extra: [Task Name], Target: Broadcast receiver
Where to enter extra: [Wakeword] ????

My Android Studio Java Code

private void sendTaskerIntent() {
        try {
            Intent taskerIntent = new Intent();
            taskerIntent.setAction("net.dinglisch.android.tasker.ACTION_TASK");
            taskerIntent.setPackage("net.dinglisch.android.tasker");
            taskerIntent.putExtra("task_name", "WakeWord");
            taskerIntent.putExtra("var1", "Hello from testIntent!"); 
            sendBroadcast(taskerIntent);

        } catch (Exception e) {
            e.printStackTrace();
            Toast.makeText(this, "Chyba: " + e.getMessage(), Toast.LENGTH_LONG).show();
        }


RSF

unread,
Sep 1, 2025, 11:48:42 PM (4 days ago) Sep 1
to Tasker
Check out this Tasker documentation page on intents. Looks like you'll need to inspect the extras in the task attached to the event profile, vs. specifying the extras in the Intent Received profile itself. According to that page, each extra gets put into a variable, and thus can be inspected like this:
Screenshot_20250901-204531.png

aa6vh

unread,
Sep 2, 2025, 10:46:38 AM (4 days ago) Sep 2
to Tasker
Screenshot_20250902_073607_Tasker.jpg

I just started playing with this yesterday. It seems that I needed to set the "Cat" 1 to "Alt" and the second "Cat" to "None" in the Intent receive profile. Then Tasker started to receive the intents.

I put a simple "Beep" action in the profile's enter task, so I knew when Tasker read the intent.

I will be playing more with it today.

Le- Ze

unread,
Sep 2, 2025, 11:25:52 PM (3 days ago) Sep 2
to Tasker
Thank you.
I installed Macrodroid and had to send an intent.
In Tasker I continue to accept the intent.
It works.
So the problem is in Android studio.
Dne úterý 2. září 2025 v 16:46:38 UTC+2 uživatel aa6vh napsal:

aa6vh

unread,
Sep 3, 2025, 11:12:39 AM (2 days ago) Sep 3
to Tasker
I did get around to playing more with Intents. I discovered that I had to omit the "package name" to make it function.

Unfortunately, it won't work for what I wanted to do. Tasker only accepts broadcast intents (as per Tasker documentation and my experiments), where the application I was sending the Intent from (Memento Database) cannot sent broadcast intents (only application intents).

Fortunately there are many other ways to send things to Tasker, so I am good.

Reply all
Reply to author
Forward
0 new messages