Licence
MIT
Version
0.1.0
Deps
0
Size
15 kB
Vulns
0
Weekly
0
@iamgame/wallet-types
TypeScript types for the IAMGame Wallet SDK and API — auth, wallet, balance, signing, withdrawal, export, and webhook wire types.
These are the request/response shapes used by @iamgame/wallet-sdk and the wallet REST API. Install this package directly if you call the API from your own backend (e.g. for webhook handling or server-side signing) and want typed payloads.
Install
npm install -D @iamgame/wallet-typesUsage
import type {
IUser,
IWallet,
IWalletBalance,
ISignActionRequest,
ISignActionResponse,
IWithdrawRequest,
IWebhookEnvelope,
WebhookEventType,
} from "@iamgame/wallet-types";
function handleWebhook(event: IWebhookEnvelope) {
switch (event.type) {
case "wallet.created":
case "withdrawal.completed":
// ...
}
}Notes
- Money is integer base units as strings. Amounts (lamports for SOL, micro-units for USDC, etc.) are stringified BigInts — never floats.
- Timestamps are ISO 8601 strings.
Documentation
License
MIT