Skip to main content
An App is a published web page with its own custom interface — a gallery, a form, a game, a client-facing tool — that runs your workflows behind the scenes. Apps live at runchat.com/p/<handle>/<slug>, anyone with the link can open them, and visitors who sign in run your workflows using their own credits. For an overview of how Apps fit alongside Tools and Libraries, see Tools, Apps, and Libraries.

How apps work

An app is an HTML page published as an artifact. The page runs in a sandboxed frame with a window.runchat bridge pre-injected, which lets it:
  • Run your published Tools with runchat.run(toolId, inputs) — the workflow executes on the server and returns its outputs
  • Remember things per visitor with runchat.state — a small per-app database for preferences, saved results, or galleries
  • Read who’s viewing with runchat.user()
Your workflows are the backend. There is no server code in an app — anything heavy (API calls, secrets, model runs) belongs in the workflow, published as a Tool. The app is only a UI.

Building an app

  1. Publish the workflows first. An app can only run workflows that have been published as Tools.
  2. Ask the agent to build the interface. Describe the app in chat — the agent writes the HTML into a Code node on the canvas. The canvas preview runs the same window.runchat bridge as the published page, so you can run tools and test the full experience before publishing anything.
  3. Publish via an Artifact node. Connect the Code node’s result to an Artifact node and run it. HTML that uses window.runchat is automatically published as an app.
  4. Share the URL. To iterate, edit the HTML (or ask the agent to) and re-run the Artifact node.

Accounts and billing

Visitors can open an app without a Runchat account, but need to sign in to run its workflows or save state. When a signed-in visitor runs the app, the run is billed to their account using their own credits and linked accounts — you don’t pay for other people’s runs. Each app shows a “Powered by” banner listing the Tools it runs, linking back to each Tool’s editor. Note that a visitor’s runs use the visitor’s own account: API keys and integrations attached to your account are not available to their runs.

State

runchat.state gives every visitor their own private key-value store scoped to the app — use it for chat history, saved images, game scores, preferences. A shared scope is readable by all visitors and writable only by you (the app owner), useful for leaderboards or curated content. Generated media URLs saved into state are automatically copied to permanent storage, so a saved gallery keeps working after the provider’s temporary URLs expire. On the canvas preview, state is browser-local test state — it doesn’t carry over when the app is published.

Embedding apps

Apps embed cleanly in third-party sites like Notion. Most platforms accept a paste of the app URL and embed it as an iframe.

Next steps