Skip to main content

Public API map

The public contract is defined by the package export map and source barrels. Import from @ovok/native or a documented @ovok/native/<module> subpath. Do not import from src/ or generated lib/ paths.

Root and subpath imports​

The entry-point table below is generated from package.json, src/index.tsx, and the module barrels under src/modules. Run yarn docs:generate after changing package exports or adding a module. The module feature guides remain hand-written: see App UI and Reusable flows for the UI surfaces.

SurfaceImport pathAlso exported from rootSource entry
SDK root@ovok/native—src/index.tsx
auth@ovok/native/authYessrc/modules/auth/index.tsx
background-sync@ovok/native/background-syncNosrc/modules/background-sync/index.ts
breathing-exercise@ovok/native/breathing-exerciseNosrc/modules/breathing-exercise/index.ts
bt-device@ovok/native/bt-deviceNosrc/modules/bt-device/index.ts
bt-device-instructions@ovok/native/bt-device-instructionsNosrc/modules/bt-device-instructions/index.ts
bt-management@ovok/native/bt-managementYessrc/modules/bt-management/index.ts
cms@ovok/native/cmsYessrc/modules/cms/index.ts
content@ovok/native/contentYessrc/modules/content/index.ts
data-sync@ovok/native/data-syncNosrc/modules/data-sync/index.ts
diary@ovok/native/diaryYessrc/modules/diary/index.ts
helpers@ovok/native/helpersYessrc/modules/helpers/index.tsx
image@ovok/native/imageNosrc/modules/image/index.ts
journal@ovok/native/journalYessrc/modules/journal/index.ts
language-switcher@ovok/native/language-switcherYessrc/modules/language-switcher/index.ts
measurement@ovok/native/measurementYessrc/modules/measurement/index.ts
observation-detail@ovok/native/observation-detailYessrc/modules/observation-detail/index.ts
patient@ovok/native/patientYessrc/modules/patient/index.ts
pdf@ovok/native/pdfNosrc/modules/pdf/index.ts
picker-sheet@ovok/native/picker-sheetNosrc/modules/picker-sheet/index.ts
progress-bar@ovok/native/progress-barYessrc/modules/progress-bar/index.ts
progress-ring@ovok/native/progress-ringYessrc/modules/progress-ring/index.ts
questionnaire-response-form@ovok/native/questionnaire-response-formYessrc/modules/questionnaire-response-form/index.ts
setting@ovok/native/settingYessrc/modules/setting/index.ts
socket@ovok/native/socketNosrc/modules/socket/index.ts
tab@ovok/native/tabYessrc/modules/tab/index.ts
theme@ovok/native/themeYessrc/modules/theme/index.ts
tile@ovok/native/tileYessrc/modules/tile/index.ts
ui@ovok/native/uiNosrc/modules/ui/index.ts
polyfills (root exports)@ovok/nativeYessrc/polyfills/index.ts
polyfills@ovok/native/polyfillsYessrc/polyfills/index.ts
Package metadata@ovok/native/package.jsonNopackage.json

The package root also exports runtime helpers from polyfills, including polyfillOvokWebAPIs, ExpoClientStorage, ExtendedExpoCrypto, cleanupOvokNativeRuntime, and initWebSocketManager. The dedicated @ovok/native/polyfills subpath loads only this module, so app entry code can initialize the runtime before importing the app or other SDK modules. See Polyfills and runtime setup for the Expo Router entry pattern.

Root examples​

import {
BTProvider,
SignIn,
ThemeProvider,
polyfillOvokWebAPIs,
} from "@ovok/native";

The root import is appropriate when the app uses the shared UI and Bluetooth management surface together. Install the peer dependencies for the imports in the application bundle.

Subpath examples​

import { DataSync } from "@ovok/native/data-sync";
import { SUPPORTED_DEVICES } from "@ovok/native/bt-device";
import { ManualEntryForm } from "@ovok/native/ui";
import { PDFViewer } from "@ovok/native/pdf";

Use subpaths for optional native features, especially when the app does not use HealthKit, Health Connect, PDF rendering, background services, or the integration-flow components.

Protocol API​

The bt-management index also exports lower-level protocol types and factories. They are useful for custom integrations and tests, but are more coupled to device wire formats than the UI APIs:

  • defineCustomDevice and custom declaration types;
  • BTManagedDevice, BTManager, and background BLE helpers;
  • standard GATT factories;
  • boso, Visomat, Veroval, AOJ, Lepu, and Viatom declarations;
  • measurement field, device status, error, and result-policy types;
  • fake managers and recorded-frame helpers for tests.

Prefer the catalog and integrated-device values for normal application code. Pin and test the exact SDK version when using protocol factories.