aboutsummaryrefslogtreecommitdiffstats
path: root/README.md
diff options
context:
space:
mode:
authorMatt Ranostay <matt.ranostay@konsulko.com>2018-01-11 11:37:44 -0800
committerMatt Ranostay <matt.ranostay@konsulko.com>2018-01-11 11:40:49 -0800
commit1e0ded400565dadfb62487258c25a0ea62b409de (patch)
tree5a0bfedc1addf040a7b52e85bf9404e65b95d9b7 /README.md
parent68314a658d919a06b270340f06c162f56147c7b1 (diff)
binding: mediascanner: add binding documentation
Add initial documentation for agl-service-mediascanner service Bug-AGL: SPEC-1245 Change-Id: I04130aacf1a2ad50d0c3e57a1ace5b1750f3c163 Signed-off-by: Matt Ranostay <matt.ranostay@konsulko.com>
Diffstat (limited to 'README.md')
-rw-r--r--README.md44
1 files changed, 44 insertions, 0 deletions
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..05b6cb2
--- /dev/null
+++ b/README.md
@@ -0,0 +1,44 @@
+# MediaScanner Service
+
+## Overview
+
+MediaScanner service use the database from respective *lightmediascanner* media scan, and also
+triggers playlist updates when storage media changes.
+
+## Verbs
+
+| Name | Description | JSON Parameters |
+|:---------------|:---------------------------|:---------------------------------------|
+| subscribe | subscribe to media events | *Request:* {"value":"media_added"} |
+| unsubscribe | unsubcribe to media events | *Request:* {"value":"media_added"} |
+| media_result | get current media playlist | See **media_result Reporting** section |
+
+### media_result Reporting
+
+JSON response for *media_result* request parameters is an array of dictionary entries
+with the following fields.
+
+| Name | Description |
+|:------------|---------------------------------------------|
+| duration | length of track in milliseconds |
+| path | path to media on filesystem |
+| title | title for media entey |
+| album | album name for media entry |
+| artist | artist name for media entry |
+| genre | genre type for media entry |
+| type | media entry data type *(e.g audio, video)* |
+
+## Events
+
+| Name | Description |
+|:---------------|:---------------------------------------------------|
+| media_added | event that reports storage media insertion |
+| media_removed | event that reports storage media removal |
+
+### media_added Event JSON Response
+
+JSON response for this event has the same results as documented in **media_result Reporting ** sections.
+
+### media_removed Event JSON Response
+
+JSON response has a single field **Path** that is the location of media that has been removed.