For the complete documentation index, see llms.txt. This page is also available as Markdown.

Overview

MOSS is MegaETH's embedded wallet SDK — connect, sign, transact, and delegate through a hosted iframe model.

MOSS embeds a wallet UI in a hosted iframe (https://account.megaeth.com) and exposes wallet actions to your app over a Penpal message bridge. Your app controls when to initialise, when to prompt the user, and how wallet state drives product UX. Private keys never touch your app code.

Two integration paths share one runtime:

  • Core SDK (@megaeth-labs/wallet-sdk) — framework-agnostic, minimal dependency surface. Use for vanilla TS, Vue, Svelte, custom shells.

  • React SDK (@megaeth-labs/wallet-sdk-react) — provider + hooks built on TanStack Query semantics. Use for React 19 products.

For React apps already on wagmi, the Wagmi Connector drops MOSS in as a wagmi connector instead.

Architecture

  1. App calls mega.initialise(config).

  2. SDK creates a hidden iframe pointed at the wallet host (production: https://account.megaeth.com; dev: local host).

  3. Penpal establishes a parent/iframe bridge scoped to the expected origin.

  4. Wallet iframe signals ready after status check.

  5. App calls connect, signMessage, transfer, callContract, etc.

Network enum is currently 'mainnet' | 'testnet'. Sponsorship config (sponsorUrl, mode, fee token) passes during initialisation — see Paymaster Guide.

What MOSS is — and is Not

Model
MOSS today

Embedded wallet SDK

Yes — the primary integration model.

Injected browser wallet

No — MOSS is SDK-first, not extension-first.

WalletConnect wallet

Planned (roadmap).

Session-key smart accounts

Yes — Smart Approvals (Policy Engine) powers app permissions and delegated execution.

Where to Go Next

Published packages: wallet-sdk on npm · wallet-sdk-react on npm.

Roadmap

These are direction signals, not shipped behavior:

Area
Planned

Social login onboarding

Google, Apple, email-based flows aligned to MOSS auth UX.

WalletConnect v2

Session management for WalletConnect-compatible dapps.

EIP-6963 / EIP-1193 discovery

Compatibility layer for broader wallet discoverability.

Last updated