@rentaltide/app-sdk is the official client for embedded apps. It's framework -agnostic (plain postMessage under the hood) with zero runtime dependencies.
createApp()
createApp() resolves once the handshake completes and the initial context is available. It throws if not running inside a host iframe — handle that to show a friendly "open this from RentalTide" state.
Context
resource depends on the embed location — see scopes & embed locations.
Scoped API
Calls are proxied through the host and checked against the granted scopes. Your app never sees a token.
A call your app lacks a scope for returns { ok: false, status: 403, data: { error: 'insufficient_scope', requiredScope } }.
Theming
Keep your iframe background transparent so it blends into the host surface.
Host UI
Lifecycle
Full method reference
| Member | Description |
|---|---|
app.context | Latest HostContext. |
app.ready() | Signal initial render complete. |
app.onContextChange(cb) | Subscribe to context changes → unsubscribe fn. |
app.onThemeChange(cb) | Subscribe to theme changes → unsubscribe fn. |
app.api.get/post/put/patch/delete() | Scoped API calls. |
app.api.request(req) | Low-level call with a full ApiRequest. |
app.toast(message, severity?) | Host snackbar. |
app.navigate(path) | Navigate the host. |
app.resize(height?) | Report height (auto by default). |
app.refreshContext() | Re-fetch context. |
app.destroy() | Tear down the bridge. |

