DocumentationBuild. Deploy. Operate.
DocsQSCSCore HTTP API

Browser Runtime & Static Files

On this page 5 sections

Runtime assets and local static files

Core serves two separate kinds of files: exact packaged runtime endpoints on registered origins, and configured local static files for unregistered hosts. Neither requires a JavaScript backend.

GET / HEAD packaged runtime endpoints

Authentication: none. Host: a registered origin. Query strings do not change the selected runtime file. These paths are served directly by Core; keep them routed through QSCS at your public proxy.

PathContent-TypePurpose
/.qscs/browser/config.jsonapplication/jsonCurrent origin navigation policy: {"enabled":true,"version":1} or enabled:false.
/.qscs/browser/loader.jsapplication/javascriptNavigation worker registration.
/.qscs/browser/navigation-worker.jsapplication/javascriptDocument navigation and reconstruction; emits Service-Worker-Allowed: /.
/.qscs/browser/qscs-substrate.wasmapplication/wasmMatching packaged WebAssembly runtime.
/.qscs/helpers/client.jsapplication/javascriptBrowser facade exposing qscs.ready, fetch, subscribe and createSession.
/.qscs/helpers/identity.jsapplication/javascriptBrowser identity implementation.
/.qscs/helpers/session.mjsapplication/javascriptBrowser session lifecycle controller.
/.qscs/helpers/api-delta.mjsapplication/javascriptBrowser API delta reconstruction.
/.qscs/helpers/api-stream.mjsapplication/javascriptSigned browser API streams.

Success returns HTTP 200, Cache-Control: no-store and X-Content-Type-Options: nosniff. HEAD returns headers without the file body. A recognised runtime file missing from the installation returns an empty HTTP 503 with no-store. Unknown paths are not a file-directory API; they continue through normal origin routing.

The apt package installs helpers under /opt/qscs/helpers. Eligible HTML receives the client automatically when Browser navigation is enabled. No source snapshot or separate file download is required. See Browser Substrate & WASM Bootstrap for configuration and CSP.

Shell / curl

curl -i 'https://app.example.com/.qscs/browser/config.json'
curl -I 'https://app.example.com/.qscs/helpers/client.js'

Local static resolution

Set [Static Pages] Path in qscs.conf and distribute files to each serving node. For a GET whose Host is not a configured origin, lookup uses <Path>/<Host>/<URI>.

Request targetRelative file
/<host>/index.html
/about<host>/about.html
/about/<host>/about/.html
/assets/app.js<host>/assets/app.js

A last component without an extension gains .html. The current unregistered-host resolver receives the URI including its query; use query-free URLs for predictable file mapping. If no file matches, Core tries the bootstrap cache, then returns 200 text/plain with body ok. It does not return a missing-file 404 on that fallback path.

Registered origins retain their origin/cache routing. A matching local file can mark a GET/HEAD path public at the identity gate, but does not override the origin’s content or create an outage copy. That gate lookup uses the path without the query.

Path and access rules

The resolver accepts hostname letters, digits, dots and hyphens; rejects literal null bytes and ..; requires a regular file; and checks the canonical result stays under the configured static root. Keep that directory limited to public files. Do not use a matching static file to exempt a private API path from authentication.

Local-file MIME mapping

ExtensionContent-Type
.html, .htmtext/html; charset=utf-8
.jsonapplication/json
.csstext/css
.jsapplication/javascript
Other extensionstext/plain; charset=utf-8

Use the origin or an appropriately configured static server for other MIME types. The packaged runtime routes use their explicit MIME mappings above, including application/wasm and JavaScript for .mjs.

Need a hand with your deployment?Contact support ↗Back to top ↑