Hope
Hope Wallet SDK

Docs

Connect

connect() and VerifyWalletPanel — get a hope1 address without collecting a mnemonic.

import { connect, createHttpTransport } from '@hopenetwork/wallet';
import { VerifyWalletPanel } from '@hopenetwork/wallet/react';

const origin = { name: 'My App', url: window.location.origin };
const transport = createHttpTransport({
  baseUrl: `${origin.url}/api/hope-wallet`,
});

const { address, pubkeyBase64 } = await connect({
  origin,
  chainId: 'hope-testnet-2',
  transport,
  relayUrl: true,
});

React: <VerifyWalletPanel origin={…} chainId="hope-testnet-2" transport={transport} relayUrl={true} onVerified={…} />

relayUrl: true → Hope Wallet POSTs proof to {origin}/api/hope-wallet/sessions/{id}/confirm. That origin must be HTTPS (http only on localhost) and the same origin as the page.

Apps already on Explorer Supabase can use createSupabaseTransport and omit relayUrl (hope_wallet_link_* RPCs).

Confirm body — validate with parseWalletProof:

{ "session_id": "cs_…", "address": "hope1…", "pubkey_base64": "…" }

In-app (Hope Wallet WebView) uses a native overlay instead of the camera. Deep link: hopewallet://connect?p=…

See sessions and try Wallet lab.