Queue item through API

Hi,

I’m working on something where I’ll need to queue an item (in this case an uri, http://127.0.0.1:11111, to interface with some other stuff running on my HTPC) from within Tasker.

What I want to achieve is that a Tasker task can queue this item, preferably through Yatse, so that it will play after whatever is playing, or (preferably) instantly if nothing is playing. Much like the ‘Play next on media center’ share option that shows up in Androids share menu. I have found ways to directly play items through the Yatse plugin exposed to Tasker, but I can’t find a way to queue.

I have tried several things:
A custom JSON-RPC action. I figured I’d need Playlist.Add as a custom action for this, but I can not get this to work. I think this might be because I can’t seem to get the Playlist ID right to work for the current queue. Kodi basically does nothing, and nothing shows up in the logs so unfortunately I can’t be more specific than ‘it doesn’t work’.

I have found that the ‘Play next on mediacenter’ option is related to the yatsefreewidget.ui.queuetoactivity intent. However, I can not figure out what data this needs. Simply sending the URL I want to play, does nothing.

Can anyone point me in the right direction? I don’t mind doing some coding if neccesary, but I’ve been at this for hours and it’s driving me nuts. Mostly because all the other Tasker - Yatse - Kodi stuff seems to be working fine.

Thanks in advance
Martijn

Currently the queue actions are not opened to Tasker :wink:

To use the QueueToActivity you just need to start the activity with an intent and the url as Data it will do what you want.

But I’m not an Tasker expert about how to do that :stuck_out_tongue:

Anyway you can open an feature requests here so that I add the queue option in tasker plugin at some point.