[Tasker Tips & Tricks] hotsync100:
I woud like to share the task I created to send commands to Allo.

The concept is very simple.

1) Insert a record on Allo's database and call the app to trigger the query.

2) Set a profile that get the notification and read the answer directly from the database.

3) Use the result to do anything you want: TTS, set a widget (Zooper, Minimalistic, etc)

It requires ROOT and Sqlite binary installed to read the database. In this case, I'm using sqlite's binary that comes with Titanium Backup (/data/data/com.keramidas.TitaniumBackup/files/sqlite3)

Before you run this task you need to set %sqlite variable with sqlite full path, also you will need enable the accessibility settings to Tasker in order to intercept the system notifications.

This task has to be called with the command as a parameter, or you can edit %text variable with your command directly

Allo - Send (152)
A1: Stop [ With Error:eek:ff Task: ] If [ %par1 !Set ]
A2: Variable Set [ Name:%text To:%par1 Do Maths:eek:ff Append:eek:ff ]
<Set SQLITE path>
A3: Variable Set [ Name:%sqlite To:/data/data/com.keramidas.TitaniumBackup/files/sqlite3 Do Maths:eek:ff Append:eek:ff ]
<Insert command into Allo database table>
A4: Run Shell [ Command:%sqlite /data/data/com.google.android.apps.fireball/databases/fireball.db "insert into messages (message_id, conversation_id, sender_id, received_timestamp, server_timestamp, message_status, seen, read_status, text, initial_insert_timestamp,type) VALUES (lower(hex(randomblob(4))) || '-' || lower(hex(randomblob(2))) || '-' || lower(hex(randomblob(2))) || '-' || lower(hex(randomblob(2))) || '-' || lower(hex(randomblob(6))), (SELECT _id FROM conversations WHERE participant_normalized_destination = 'google' limit 1), 1, strftime('%s000', 'now'), strftime('%s000000', 'now'), 3, 1, 1, '%text', strftime('%s000', 'now'), 2);

select last_insert_rowid() ;" Timeout (Seconds):0 Use Root:eek:n Store Output In:%out Store Errors In: Store Result In: Continue Task After Error:eek:n ]
<Store the inserted record ID into a global variable>
A5: Variable Set [ Name:%ALLO_ID To:%out Do Maths:eek:ff Append:eek:ff ]
<Launch Allo to process the command>
A6: Launch App [ App:Allo Data: Exclude From Recent Apps:eek:ff Always Start New Copy:eek:ff ]
A7: Wait [ MS:0 Seconds:1 Minutes:0 Hours:0 Days:0 ]
<This is necessary in order to receive an Allo notification with the answer>
A8: Go Home [ Page:0 ]

You will notice the global variable %ALLO_ID used to set the _id of the inserted record. You will need it later in order to recover Allo's answers.

This is a Task example to read the answer and say it by "text to speech". But you can do other automation tasks as you need.

Allo - Say (154)
A1: Wait [ MS:0 Seconds:1 Minutes:0 Hours:0 Days:0 ]
A2: Variable Set [ Name:%sqlite To:/data/data/com.keramidas.TitaniumBackup/files/sqlite3 Do Maths:eek:ff Append:eek:ff ]
A3: Run Shell [ Command:%sqlite /data/data/com.google.android.apps.fireball/databases/fireball.db "select text from messages where message_id like 'R:google%' and text is not null and _id > '%ALLO_ID' ;" Timeout (Seconds):0 Use Root:eek:n Store Output In:%out Store Errors In: Store Result In: Continue Task After Error:eek:n ]
A4: If [ %out !Set ]
A5: Wait [ MS:0 Seconds:2 Minutes:0 Hours:0 Days:0 ]
A6: Run Shell [ Command:%sqlite3 /data/data/com.google.android.apps.fireball/databases/fireball.db "select text from messages where message_id like 'R:google%' and text is not null and _id > '%ALLO_ID' ;" Timeout (Seconds):0 Use Root:eek:n Store Output In:%out Store Errors In: Store Result In: Continue Task After Error:eek:n ]
A7: End If
A8: Flash [ Text:%out Long:eek:ff ]
A9: Say [ Text:%out Engine:Voice:default:default Stream:3 Pitch:4 Speed:4 Respect Audio Focus:eek:n Network:eek:ff Continue Task Immediately:eek:ff ]

Sample Project with the Tasks:

View attachment 3901705

Share yours Allo's commands here. What would you automate with this ?