{"id":22363931,"url":"https://github.com/tonychouteau/openwebdeck","last_synced_at":"2025-03-26T15:19:36.128Z","repository":{"id":218619729,"uuid":"746931531","full_name":"TonyChouteau/OpenWebDeck","owner":"TonyChouteau","description":"OpenWebDeck - Like a stream deck but remote with a simple python client and a websocket server ","archived":false,"fork":false,"pushed_at":"2024-01-31T21:42:05.000Z","size":29,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-31T16:35:36.848Z","etag":null,"topics":["python3","remote-control","server","websocket"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TonyChouteau.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-01-22T23:35:39.000Z","updated_at":"2024-02-06T15:48:01.000Z","dependencies_parsed_at":"2025-01-31T16:34:10.212Z","dependency_job_id":null,"html_url":"https://github.com/TonyChouteau/OpenWebDeck","commit_stats":null,"previous_names":["tonychouteau/openwebdeck"],"tags_count":0,"template":true,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TonyChouteau%2FOpenWebDeck","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TonyChouteau%2FOpenWebDeck/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TonyChouteau%2FOpenWebDeck/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TonyChouteau%2FOpenWebDeck/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TonyChouteau","download_url":"https://codeload.github.com/TonyChouteau/OpenWebDeck/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245678902,"owners_count":20654738,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["python3","remote-control","server","websocket"],"created_at":"2024-12-04T17:17:41.800Z","updated_at":"2025-03-26T15:19:36.103Z","avatar_url":"https://github.com/TonyChouteau.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# OpenWebDeck\n\n## Project Description\n\nOnline Python Script Executor is like an online version of a stream deck, enabling the execution of Python scripts remotely on a client machine from a web application. Users can add as many scripts (handlers) as desired to the client. The client generates a UUID necessary for the web app to connect.\n\n## Operation\n```\n+---------------------+      +---------------------+      +---------------------+\n|     Web App         |      |       Server        |      |       Client        |\n|                     |      |                     1\u003c-----+   Send the handler  |\n|   Request UUID      +-----\u003e2    Receive UUID     |      |       config        |\n|                     |      |  and Handler Config |      |                     |\n| if UUID get config  3\u003c-----+    from Client      |      |                     |\n|   Display Handlers  |      |                     |      |                     |\n|     as Buttons      |      |                     |      |                     |\n|                     |      |                     |      |                     |\n|      onClick        +-----\u003e4   proxy to client   +-----\u003e5       Execute       |\n|   display output    7\u003c-----+   proxy to client   6\u003c-----+    return output    |\n+---------------------+      +---------------------+      +---------------------+\n```\n\n## Personalizing the Client\n\nPersonalize the client by creating new scripts inheriting from the `client/handlers/Base.py` class with the following methods:\n\n- `.get_config()`: Return a configuration (JSON) with the \"id\", default \"value\", and list of possible values, \"sub-cells\" (\"name\" and \"value\") of the handler.\n- `.execute(value)`: The function that modifies the handler's value, executes the script/action, and returns the value after execution.\n\nThe `client/handlers/handlers.py` file contains a list called \"config\" of instances of all handlers. Simply add your handlers to include them in the web app.\n\nFor example, imagine launching a script and receiving a value \"OK\" or \"ERROR.\"\n\nCheck the example of the already defined handler: `client/handlers/HandlerPong.py`. This handler, for example purposes, allows sending two values from the web app: ping or pong. \nThe execution of the handler modifies the value on the client with the value sent by the web app, displays it in the client's console, and returns the opposite value.\n\n# Installation\n\n## Install the Server (Locally or on a Distant Server)\n\nInstall Python 3.8+, pip and pythons modules : Flask\u003e=3.0, flask_session, websockets, asyncio\n```bash\npython3 -m pip install flask flask_session websockets asyncio\n```\nRun the server:\n```bash\npython3 server/server.py # Webapp\npython3 server/websocket.py # Server\n```\n\n## Install the Client\n\nAdd new handlers in `client/handlers/` and edit the config list in `handlers.py` to add the new handler.\n\nInstall Python 3.8+, pip and pythons modules : websockets, asyncio, uuid\n```bash\npython3 -m pip install websockets asyncio uuid\n```\nRun the client:\n```bash\npython3 client.py\n```\n\n## Using the Web App\n\nOn the web app, enter the UUID generated by the client, then click on the desired buttons to perform actions on the client.\n\n# License \n\nApache2\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftonychouteau%2Fopenwebdeck","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftonychouteau%2Fopenwebdeck","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftonychouteau%2Fopenwebdeck/lists"}