Wow! Thanks for posting this simple HTTP post rule! I've been using a set of Raspberry Pi's all attached to a central NAS for all my video and audio content.. I had to wrestle a little bit with the JSON syntax, so I thought I'd share my experience for other likely RPi users:
Here's what worked for me for my "random TV" scene button:
{
"jsonrpc": "2.0",
"id": 0,
"method": "Player.Open",
"params": {
"item": {
"directory": "/storage/.kodi/userdata/playlists/video/alltv.xsp"
}
}
}
Where my playlist is laid out to do the randomization for me:
livingroom:~/.kodi/userdata/playlists/video # cat alltv.xsp
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<smartplaylist type="episodes">
<name>TV</name>
<match>all</match>
<limit>500</limit>
<order direction="ascending">random</order>
</smartplaylist>
What ALSO worked, was using a playlist INDEX, which I think would follow the order if you just do a standard ls in the directory space, but I chose not to use it as it seemed too subject to error as I created or manipulated my playlists:
{
"jsonrpc": "2.0",
"id": 0,
"method": "Player.Open",
"params": {
"item": {
"playlistid": 1
}
}
}
Anway, a super THANK YOU shout-out and thanks for helping me get One Button Cartoons working in my living room!! 
{
"jsonrpc": "2.0",
"id": 0,
"method": "Player.Open",
"params": {
"item": {
"directory": "/storage/.kodi/userdata/playlists/video/cartoons.xsp"
}
}
}
livingroom:~/.kodi/userdata/playlists/video # cat cartoons.xsp
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<smartplaylist type="movies">
<name>Traditional Cartoons</name>
<match>all</match>
<rule field="path" operator="contains">
<value>cartoonshorts</value>
</rule>
<order direction="ascending">random</order>
</smartplaylist>
