{% macro ConfigReadme() %}
[Settings]
theme = dark
accent = orange
background = static/images/backgrounds/background.png
Variable | Required | Description | Options |
---|---|---|---|
[Settings] | Yes | Config section name. | string |
theme | Yes | UI theme | light, dark |
accent | Yes | UI accent color | orange, red, pink, purple, deepPurple, indigo, blue, lightBlue, cyan, teal, green, lightGreen, lime, yellow, amber, deepOrange, brown, grey, blueGrey |
background | Yes | Background image for the UI | /static/images/backgrounds/yourpicture.png, external link to image, None, random |
roles | No | User roles for access groups. | string, if not defined, this is set to 'admin,user,public_user'. Note: admin, user, public_user roles are required and will be added automatically if omitted. |
home_access_groups | No | Define which access groups can access the /home page | Roles defined in your config. If not defined, default is admin_only |
settings_access_groups | No | Define which access groups can access the /settings page | Roles defined in your config. If not defined, default is admin_only |
[App Name]
prefix = https://
url = your-website.com
icon = static/images/apps/default.png
sidebar_icon = static/images/apps/default.png
description = Example description
open_in = iframe
data_template = None
Variable | Required | Description | Options |
---|---|---|---|
[App Name] | Yes | The name of your app. | string |
prefix | Yes | The prefix for the app's url. | web prefix, e.g. http:// or https:// |
url | Yes | The url for your app. | web url, e.g. myapp.com |
icon | No | Icon for the dashboard. | /static/images/icons/yourpicture.png, external link to image |
sidebar_icon | No | Icon for the sidenav. | /static/images/icons/yourpicture.png, external link to image |
description | No | A short description for the app. | string |
open_in | Yes | open the app in the current tab, an iframe or a new tab | iframe, new_tab, this_tab |
data_template | No | Template for displaying variable(s) from rest data *Note: you must have a rest data variable set up in the config | example: Data: {{ '{{ your_variable }}' }} |
[public]
roles = admin, user, public_user
Variable | Required | Description | Options |
---|---|---|---|
[Group Name] | Yes | Name for access group | string |
roles | Yes | A comma separated list of user roles allowed to view apps in this access group | Roles defined in your config. If not defined, defaults are admin and public_user |
[variable_name]
platform = rest
resource = your-website.com
value_template = variable_name
Variable | Required | Description | Options |
---|---|---|---|
[variable_name] | Yes | The variable to be made available to apps. | variable (python syntax) |
platform | Yes | Platform for data source | rest |
resource | Yes | The url for the api call. | myapp.com/api/hello |
value_template | No | Tranform the data returned by the api call (python syntax) | variable_name[0]['info'] |
method | NOT IMPLEMENTED | NOT IMPLEMENTED | NOT IMPLEMENTED |
payload | NOT IMPLEMENTED | NOT IMPLEMENTED | NOT IMPLEMENTED |
authentication | NOT IMPLEMENTED | NOT IMPLEMENTED | NOT IMPLEMENTED |
username | NOT IMPLEMENTED | NOT IMPLEMENTED | NOT IMPLEMENTED |
password | NOT IMPLEMENTED | NOT IMPLEMENTED | NOT IMPLEMENTED |
Say we wanted to display how many Pokemon there are using the PokeAPI, we would add the following to the config:
[num_pokemon]
platform = rest
resource = https://pokeapi.co/api/v2/pokemon
value_template = num_pokemon['count']
Then in the config entry for the app you want to add this to, you would add:
data_template = Pokemon: {{ '{{ num_pokemon }}' }}