~/luna-atlas/examples
$ luna-send --examples

Common luna-send examples.

Copy-and-paste luna-send commands for everyday things on an LG webOS TV: toasts, apps, volume, the screen, system info and settings.

Before you start

You need a shell on the TV: a rooted TV with SSH from the Homebrew Channel (see SSH into a rooted LG TV), or Developer Mode. Every command below uses -n 1 to wait for one reply and -f to print it formatted. Methods marked private need root.

Show a toast message public

luna://com.webos.notification/createToast Creates a toast notification.

$ luna-send -n 1 -f luna://com.webos.notification/createToast '{"message":"Hello from luna-send"}'
Show an alert with a button public

luna://com.webos.notification/createAlert Creates a system alert notification.

$ luna-send -n 1 -f luna://com.webos.notification/createAlert '{"message":"Dinner is ready","buttons":[{"label":"OK"}]}'
See which app is on screen ssap

luna://com.webos.applicationManager/getForegroundAppInfo Get (or subscribe to) the foreground app

$ luna-send -n 1 -f luna://com.webos.applicationManager/getForegroundAppInfo '{}'
Close an app ssap

luna://com.webos.applicationManager/close Close an app by id (SSAP)

$ luna-send -n 1 -f luna://com.webos.applicationManager/close '{"id":"com.webos.app.browser"}'
Mute the sound public

luna://com.webos.audio/setMuted Mutes or unmutes the volume.

$ luna-send -n 1 -f luna://com.webos.audio/setMuted '{"muted":true}'
Turn the volume up a step public

luna://com.webos.audio/volumeUp Increases the volume by 1.

$ luna-send -n 1 -f luna://com.webos.audio/volumeUp '{}'
Set the volume private

luna://com.webos.audio/setVolume Sets volume

$ luna-send -n 1 -f luna://com.webos.audio/setVolume '{"volume":15}'
Turn the picture off (sound keeps playing) ssap

luna://com.webos.service.tvpower/power/turnOffScreen Blank the panel (screen off) while keeping the TV powered

$ luna-send -n 1 -f luna://com.webos.service.tvpower/power/turnOffScreen '{}'
Turn the picture back on ssap

luna://com.webos.service.tvpower/power/turnOnScreen Unblank the panel

$ luna-send -n 1 -f luna://com.webos.service.tvpower/power/turnOnScreen '{}'
Read the power state ssap

luna://com.webos.service.tvpower/power/getPowerState Get (or subscribe to) TV power state

$ luna-send -n 1 -f luna://com.webos.service.tvpower/power/getPowerState '{}'
Get the model and firmware public

luna://com.webos.service.tv.systemproperty/getSystemInfo Retrieves system information by keys: boardType, firmwareVersion, modelName, sdkVersion, UHD, _3d.

$ luna-send -n 1 -f luna://com.webos.service.tv.systemproperty/getSystemInfo '{"keys":["modelName","firmwareVersion","sdkVersion"]}'
Get the software version private

luna://com.webos.service.update/getCurrentSWInformation Returns current software/firmware info

$ luna-send -n 1 -f luna://com.webos.service.update/getCurrentSWInformation '{}'
Check the network connection public

luna://com.webos.service.connectionmanager/getStatus Provides the current status of Wi-Fi and wired network connections on the system.

$ luna-send -n 1 -f luna://com.webos.service.connectionmanager/getStatus '{}'
Read the picture mode public

luna://com.webos.settingsservice/getSystemSettings Retrieves system setting values by key (localeInfo, country, smartServiceCountryCode2, audioGuidance, caption* keys).

$ luna-send -n 1 -f luna://com.webos.settingsservice/getSystemSettings '{"category":"picture","keys":["pictureMode"]}'
List the inputs and what's connected public

luna://com.webos.service.eim/getAllInputStatus Lists all inputs (HDMI 1-4 with labels, CEC sub-devices, ARC) with connection state

$ luna-send -n 1 -f luna://com.webos.service.eim/getAllInputStatus '{}'
Read the system time public

luna://com.palm.systemservice/time/getSystemTime Returns the system time; subscribable for timezone or >5 min time changes.

$ luna-send -n 1 -f luna://com.palm.systemservice/time/getSystemTime '{}'

Find more

These are a handful of 8,125. Search the full catalog, or browse by category. Methods that support subscriptions keep reporting changes if you add "subscribe": true and drop -n 1.