From 8de5493ee3008cd99acf494ee55a506ac7cc5268 Mon Sep 17 00:00:00 2001 From: Pascal Vizeli Date: Thu, 4 May 2017 16:20:25 +0200 Subject: [PATCH] Update create_hassio_addon.markdown --- source/hassio/create_hassio_addon.markdown | 35 ++++++++++++++++++++-- 1 file changed, 33 insertions(+), 2 deletions(-) diff --git a/source/hassio/create_hassio_addon.markdown b/source/hassio/create_hassio_addon.markdown index bfb4e68885e..7a4cc06c43f 100644 --- a/source/hassio/create_hassio_addon.markdown +++ b/source/hassio/create_hassio_addon.markdown @@ -51,9 +51,40 @@ As a user might run many add-ons, it is encouraged to try to stick to Bash scrip ### {% linkable_title Options / Schema %} -The `options` dict have all available options with default value. If you want to set a value to requered and need to be set from user before it start the addon, set it to null. +The `options` dict have all available options with default value. If you want to set a value to requered and need to be set from user before it start the addon, set it to null. We support arrays for single deeps. -The `schmema` look like the `options` but describe how we should validate the user input. +```json +{ + "message": "custom things", + "logins": [ + { "username": "beer", "password": "123456" }, + { "username": "cheep", "password": "654321" } + ], + "random": ["haha", "hihi", "huhu", "hghg"], + "link": "http://blebla.com/" +} +``` + +The `schmema` look like the `options` but describe how we should validate the user input. For example above: + +```json +{ + "message": "str", + "logins": [ + { "username": "str", "password": "str" } + ], + "random": ["str"], + "link": "url" +} +``` + +We support: +- str +- bool +- int +- float +- email +- url ### {% linkable_title SSL %}