HotupdaterHot Updater
React Native API

getActiveUpdateState

Inspect the selected Release, its artifact, and native verification state.

Usage

Use hotUpdater.getActiveUpdateState() for support diagnostics that need both the Console update ID and the underlying artifact ID.

import { hotUpdater } from "./hotUpdater";

const state = await hotUpdater.getActiveUpdateState();

console.log({
  updateId: state.activeSelection?.releaseId,
  artifactId: state.activeSelection?.bundleId,
  verificationPending: state.verificationPending,
});

Return value

type Selection = {
  readonly kind: "BUNDLE" | "BUILTIN";
  readonly releaseId: string | null;
  readonly bundleId: string;
  readonly channel: string;
};

type ActiveUpdateState = {
  readonly activeSelection: Selection | null;
  readonly stableSelection: Selection | null;
  readonly verificationPending: boolean;
};

getActiveUpdateState(): Promise<ActiveUpdateState>
FieldMeaning
activeSelectionThe selected transition, including an update staged for a later runtime start. It may be null before a selection is recorded.
stableSelectionThe retained stable selection used by native recovery, when present. It may be null even when the app is healthy.
verificationPendingWhether native state marks a transition as awaiting verification.

A selection's releaseId identifies delivery policy and matches the Console's update ID when present. For kind: "BUNDLE", bundleId is the artifact ID. BUILTIN selects the native app's built-in bundle as a fallback without a Release; its bundleId is the native build's bundle identifier.

This method reads local state and does not make a network request. It does not reload, acknowledge readiness, or subscribe to changes. Read it again when you need a fresh snapshot.

activeSelection and getBundleId() can change after staging and before reload. They do not prove that the selected code is already running. Use the app-ready result and Insights reports when verifying an applied update.

On this page