Skip to Content
🚀 Orga AI is in open beta.
ReferenceClient SDKsReact SDK

React SDK Reference

This is the definitive source for everything exposed by @orga-ai/react—hooks, components, and exported types. Use it when you need prop names, return signatures, or version requirements; tutorials and walkthroughs live elsewhere.


Sections

  • Hooks — useOrgaAI() contract for session control, media, and configuration.
  • Components — <OrgaAIProvider>, <OrgaAudio>, <OrgaVideo> primitives for context and media rendering.
  • Types — TypeScript interfaces and enums exported from @orga-ai/react.

đź’ˇ Tip:
The React SDK mirrors the design of the React Native SDK. If you plan to target both web and mobile, your app logic can often be shared directly between @orga‑ai/react and @orga‑ai/react‑native.


Structure

Each reference page includes:

  1. Concise descriptions of the API surface.
  2. Code examples using TypeScript / JSX.
  3. Detailed tables describing props, return values, and parameters.
  4. Implementation notes around lifecycle, state, and performance.

Runtime requirements

RequirementDescription
React ≥18.2Required for concurrent‑safe context and hooks.
Browser supportUses WebRTC (RTCPeerConnection, MediaStream) and the Permissions API.
BundlersWorks with Vite, Next.js, CRA, and custom Webpack setups. Make sure your bundler resolves exports maps.
Backend integrationA backend service (Server SDK or REST proxy) must issue ephemeral tokens for every session.

Never expose your Orga API key in browser code. Issue tokens via a backend built with the Node Server SDK.


Versioning

All Orga SDKs follow semantic versioning (SemVer).
Breaking API changes correspond to major version bumps (e.g., 1.x → 2.x).

The React SDK’s current stable version is v1.0.5 (open beta).


Next Steps

Last updated on