wooden-umbrella-84098
09/14/2026, 6:37 PM<http://canvas.rbren.io|canvas.rbren.io>
• Apps currently serve their SPAs in an iframe, served on a different port
• Apps currently serve their backends also on a different port
The problem is that agent-server credentials are stored in localStorage, so the iframe window can't access them. I also disallow traffic to arbitrary ports on <http://canvas.rbren.io|canvas.rbren.io>, so everything has to be proxied through OpenHands, or a special nginx route has to be set up for each app.
Here's my suggestion:
• When an app is installed, the backend sets up a proxy for /apps/$app-name, pointing to localhost:$app-port
• This serves both frontend and backend
• OpenHands decides the port (so we can avoid conflicts, e.g. two different apps trying to claim 3000). App must respect some env var like $OPENHANDS_PORT during setup
• If the app wants to set up both a frontend and a backend, it can start a proxy serverlimited-student-10747
09/14/2026, 6:45 PMlimited-student-10747
09/14/2026, 6:46 PMhundreds-twilight-32833
09/14/2026, 6:56 PMcalm-artist-7206
09/14/2026, 7:05 PMhundreds-twilight-32833
09/14/2026, 7:05 PMloadCanvasExtensionModule().
It turns the fetched ESM bundle into a Blob URL and dynamically imports it:
await import(/* @vite-ignore */ moduleUrl);
Then the app calls the bundle’s required activate(host) export. Pages are injected into their route container through the extension’s registered mount({ container, ... }) callback.wooden-umbrella-84098
09/14/2026, 7:33 PMwooden-umbrella-84098
09/14/2026, 7:34 PMlocalhost:3456 to serve the app backend, there are a few issues:
• requests are cross-origin
• App developer is responsible for authentication
• anyone running on a custom domain will need to add custom routingwooden-umbrella-84098
09/14/2026, 7:35 PMlimited-student-10747
09/14/2026, 7:37 PMwooden-umbrella-84098
09/14/2026, 7:38 PM/app/$app-name to a specific portwooden-umbrella-84098
09/14/2026, 7:39 PMlimited-student-10747
09/14/2026, 7:40 PMlimited-student-10747
09/14/2026, 7:40 PMcalm-artist-7206
09/14/2026, 7:43 PM