Issue
I've defined a multi page Dash app:
app.py:
import dash
import dash_bootstrap_components as dbc
from dash import html
app = dash.Dash(__name__, use_pages=True, suppress_callback_exceptions=True)
...
app.layout = dbc.Container(
[navbar, nav, dash.page_container]
)
if __name__ == "__main__":
app.run_server(debug=True, host='0.0.0.0')
page.py:
import dash
import json
import yaml
from dash import html, dcc, Input, Output, State, ALL, callback
from dash.exceptions import PreventUpdate
import dash_bootstrap_components as dbc
from filelock import FileLock
dash.register_page(__name__, order=1, title='🗃️ My page')
...
def layout(**other_unknown_query_strings):
....
The page handles some resources which the user can reserve or release. However, except the dash GUI in the web browser I would like to be able to reserve and unreserve via curl
and return a static response such as {"result": "ok"}.
Is this possible?
Solution
My first assumption was bad design.
I solved this by having an external Flask
driven server handle the resources.
Answered By - Henrik Answer Checked By - Mildred Charles (WPSolving Admin)