Skip to main content
AomiWidget adds Aomi chat, threads, wallet connection, and transaction approval to your React application. Your application chooses the App and the user-facing wallet provider. Aomi resolves the App’s tools and execution settings from the Application ID. The widget runs on your application’s origin. It does not reuse cookies from chat.aomi.dev. Instead, it creates a widget session for the signed-in user and binds that session to the exact origin that created it. There is no origin registration or allowlist: any HTTPS origin can mint a session, and the session is only valid when presented from that same origin.

Understand the boundary

Your host application and Aomi have distinct responsibilities:
Provider choice belongs to your application. Switching from browser wallets to Para or Privy changes how users sign in and access wallets. It does not change which Aomi App handles the conversation.

Before you start

You need:
  • An activated Aomi App and its numeric Application ID.
  • React 18 or 19 running in the browser.
  • A browser-wallet, Para, or Privy integration choice.
Hosted integrations must use HTTPS. HTTP is accepted only on loopback hosts (localhost, 127.0.0.1, [::1]) for local development. If you use Para or Privy, also allow your host origin in that provider’s project settings when the provider requires it.

1. Install the widget

Import the default stylesheet once in your client application:

2. Add public configuration

Keep the Application ID and provider’s public browser identifier in your host application. Add only the provider you use.
These values are safe to expose to the browser. Do not add an App key, provider secret, paymaster credential, gas-policy credential, treasury configuration, or private key to frontend code.

3. Mount AomiWidget

Choose one authentication mode. Import the matching provider entry point for Para or Privy so the widget can register that provider.
Use this mode when users connect an existing wallet.
For Vite, replace each process.env.NEXT_PUBLIC_* read with the matching import.meta.env.VITE_* value.

4. Pass optional host state

You can keep thread selection and wallet presentation in your application:
The Application ID selects the App. It is not a user credential and does not grant wallet signing. The active user and wallet must still complete the configured authentication and approval flow.

5. Verify the integration

  1. Open the widget from the origin your application is served from.
  2. Sign in or connect a browser wallet. Browser-wallet sign-in uses a SIWE or SIWS signature from an externally owned account; smart-contract wallets (Safe, Coinbase Smart Wallet, Base Account) cannot sign in through the widget.
  3. Confirm the thread list and composer load without an App-key prompt.
  4. Send a message and confirm your selected App responds.
  5. If the App creates transactions, confirm the widget shows the request before the wallet asks for a signature.
  6. Repeat the check from the production HTTPS origin before launch.
If the origin is rejected, check that it is HTTPS (or a loopback host over HTTP) and that the session is presented from the same scheme, host, and port that created it. If an embedded provider does not open, check its public identifier, environment, provider import, and allowed origins.

Installation details

Review framework setup and environment configuration.

Customize the widget

Configure layout, themes, wallet controls, or a headless interface.

Troubleshooting

Resolve origin, provider, wallet, and transaction issues.
Last modified on September 1, 2026