Documentation

TypeScript runtime context

Read scoped runtime context for org, workspace, environment, and request identity.

Beta Updated 2026-06-11 Raw Markdown
Docs tree

Runtime context tells app code which organization, workspace, environment, and request scope it is handling.

Read context

import { getContext } from '@app-builder-platform/relpin-sdk/runtime'

const context = getContext()

The context can include:

  • env
  • orgId
  • workspaceId
  • capsuleId
  • deploymentId
  • requestId
  • containerMode

Prefer request scope

For request handlers, pass or resolve context per request. Avoid relying on process-wide assumptions when the route can receive multiple tenants or environments over time.

Environment fallback

The SDK can read scoped values from environment bindings when no request context is available. That is a fallback for controlled runtime wrappers, not a browser contract.