API Documentation¶
- class dashboard.api.ChannelBridgeAPI(channel_layer, channel_name, request_id=-1, identity=None, scope=None, plugin_variables={})¶
A translation layer between the plugin API and the channel layer
Picks up calls that should not go to the consumer (e.g. log calls). The instantiated objects of this class usually do not reside in the same process as the websocket consumer.
- async show_message(*args, **kwargs)¶
Display a message to the user.
Will show a box that needs to be acknowledged before the website can be used again. There is always just one message box, so if a new message is shown, the old one will be replaced. :param message: Message to display :param message_type:
- class dashboard.api.ConsumerAPI(consumer=None, chat_modes=None)¶
- async show_message(message, theme='info', timeout=5000)¶
Display a message to the user.
Will show a box that needs to be acknowledged before the website can be used again. There is always just one message box, so if a new message is shown, the old one will be replaced. :param message: Message to display :param message_type:
- async sync_session_storage_db()¶
Sync the session storage with the database. Use sparingly!