Files
NetSpeaker/API_DOC.txt

37 lines
1.9 KiB
Plaintext
Executable File

API Location Method Returns Redirects to Description
---------------------------------------------------------------------------------------------------------------------
/api/ API root
----------------
/api/v1/playback/ Playback functions
----------------
/api/v1/playback/toggle GET JSON object Toggle Playback
/api/v1/playback/play GET JSON object Start playback
/api/v1/playback/pause GET JSON object Pause playback
/api/v1/playback/next GET JSON object Play next audio
/api/v1/playback/previous GET JSON object Play previous audio
/api/v1/playback/info GET JSON object Get the title, artist, album, path, type, ... of the current played resource
/api/v1/playlist/
----------------
/api/v1/playlist/get GET JSON object Returns the whole current playlist
/api/v1/playlist/create POST JSON object Creates a playlist of the given directory
/api/v1/playlist/play POST JSON object Plays a playlist from the SD card
/api/v1/volume/
----------------
/api/v1/volume/up GET JSON object Higher the volume (max. 20)
/api/v1/volume/down GET JSON object Lower the volume (min. 0)
/api/v1/volume/mute GET JSON object Mute (does not affect volume)
/api/v1/volume/unmute GET JSON object Unmute (set volume to current volume)
/api/v1/volume/get GET JSON object Do nothing, just get the volume
/api/v1/volume/<0-20> GET JSON object Set volume to a specific value between 0 and 20
/api/v1/settings/
----------------
/api/v1/settings/restart GET JSON object Performs a reboot of the microcontroller (after waiting 5000ms)