About keys and values
To specify what information macsig should send to ampsig, use the key-value table. A key is a short description of its corresponding value. Keys should be lowercase words without whitespace, but values may include any combination of text and variables.
macsig automatically sends certain keys that ampsig requires. These do not appear in the key-value table. You must specify all nonessential keys in the key-value table, although the recommended ones appear by default.
The "live representation" column shows what macsig sends to ampsig, including the corresponding values of variables. You cannot edit this column since it is calculated from the "value" column.
To add a new key-value pair, click the + button underneath the key-value box on the left.
To remove a key-value pair, select it and click the - button underneath the key-value box on the left.
To edit a key or value, double-click it in the table.
Note: Your ampsig scheme must support the key in order for it to appear. See the ampsig scheme creation guidelines for more information.
Note: If you specify an automatic key in the table, you will override the one macsig sends automatically.
key | description/values | auto |
---|---|---|
user |
username to authenticate |
Yes |
pass |
password to authenticate |
Yes |
playing |
one of "playing", "paused", or "stopped" |
Yes |
status |
arbitrary string; varies depending on "playing" |
Yes |
pos |
the current play position withing the song, in seconds |
Yes |
length |
duration of the song, in seconds |
Yes |
uptime |
how long your computer has remained on, in seconds |
No |
title |
the name of the playing track, or a combination of name and artist |
No |
artist |
who performs the track |
No |