@sudobility/contracts 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +353 -0
- package/artifacts/contracts/Mailer.sol/Mailer.d.ts +1146 -0
- package/artifacts/contracts/Mailer.sol/Mailer.dbg.json +4 -0
- package/artifacts/contracts/Mailer.sol/Mailer.json +1096 -0
- package/artifacts/contracts/Mailer.sol/artifacts.d.ts +21 -0
- package/artifacts/contracts/MockUSDC.sol/MockUSDC.d.ts +284 -0
- package/artifacts/contracts/MockUSDC.sol/MockUSDC.dbg.json +4 -0
- package/artifacts/contracts/MockUSDC.sol/MockUSDC.json +234 -0
- package/artifacts/contracts/MockUSDC.sol/artifacts.d.ts +21 -0
- package/artifacts/contracts/interfaces/IERC20.sol/IERC20.d.ts +157 -0
- package/artifacts/contracts/interfaces/IERC20.sol/IERC20.dbg.json +4 -0
- package/artifacts/contracts/interfaces/IERC20.sol/IERC20.json +107 -0
- package/artifacts/contracts/interfaces/IERC20.sol/artifacts.d.ts +21 -0
- package/dist/evm/src/evm/index.d.ts +4 -0
- package/dist/evm/src/evm/index.d.ts.map +1 -0
- package/dist/evm/src/evm/index.js +10 -0
- package/dist/evm/src/evm/index.js.map +1 -0
- package/dist/evm/src/evm/mailer-client.d.ts +966 -0
- package/dist/evm/src/evm/mailer-client.d.ts.map +1 -0
- package/dist/evm/src/evm/mailer-client.js +619 -0
- package/dist/evm/src/evm/mailer-client.js.map +1 -0
- package/dist/evm/typechain-types/Mailer.d.ts +698 -0
- package/dist/evm/typechain-types/Mailer.d.ts.map +1 -0
- package/dist/evm/typechain-types/Mailer.js +3 -0
- package/dist/evm/typechain-types/Mailer.js.map +1 -0
- package/dist/evm/typechain-types/MockUSDC.d.ts +118 -0
- package/dist/evm/typechain-types/MockUSDC.d.ts.map +1 -0
- package/dist/evm/typechain-types/MockUSDC.js +3 -0
- package/dist/evm/typechain-types/MockUSDC.js.map +1 -0
- package/dist/evm/typechain-types/common.d.ts +51 -0
- package/dist/evm/typechain-types/common.d.ts.map +1 -0
- package/dist/evm/typechain-types/common.js +3 -0
- package/dist/evm/typechain-types/common.js.map +1 -0
- package/dist/evm/typechain-types/factories/Mailer__factory.d.ts +875 -0
- package/dist/evm/typechain-types/factories/Mailer__factory.d.ts.map +1 -0
- package/dist/evm/typechain-types/factories/Mailer__factory.js +1125 -0
- package/dist/evm/typechain-types/factories/Mailer__factory.js.map +1 -0
- package/dist/evm/typechain-types/factories/MockUSDC__factory.d.ts +193 -0
- package/dist/evm/typechain-types/factories/MockUSDC__factory.d.ts.map +1 -0
- package/dist/evm/typechain-types/factories/MockUSDC__factory.js +263 -0
- package/dist/evm/typechain-types/factories/MockUSDC__factory.js.map +1 -0
- package/dist/evm/typechain-types/factories/index.d.ts +4 -0
- package/dist/evm/typechain-types/factories/index.d.ts.map +1 -0
- package/dist/evm/typechain-types/factories/index.js +45 -0
- package/dist/evm/typechain-types/factories/index.js.map +1 -0
- package/dist/evm/typechain-types/factories/interfaces/IERC20__factory.d.ts +80 -0
- package/dist/evm/typechain-types/factories/interfaces/IERC20__factory.d.ts.map +1 -0
- package/dist/evm/typechain-types/factories/interfaces/IERC20__factory.js +116 -0
- package/dist/evm/typechain-types/factories/interfaces/IERC20__factory.js.map +1 -0
- package/dist/evm/typechain-types/factories/interfaces/index.d.ts +2 -0
- package/dist/evm/typechain-types/factories/interfaces/index.d.ts.map +1 -0
- package/dist/evm/typechain-types/factories/interfaces/index.js +9 -0
- package/dist/evm/typechain-types/factories/interfaces/index.js.map +1 -0
- package/dist/evm/typechain-types/index.d.ts +10 -0
- package/dist/evm/typechain-types/index.d.ts.map +1 -0
- package/dist/evm/typechain-types/index.js +44 -0
- package/dist/evm/typechain-types/index.js.map +1 -0
- package/dist/evm/typechain-types/interfaces/IERC20.d.ts +70 -0
- package/dist/evm/typechain-types/interfaces/IERC20.d.ts.map +1 -0
- package/dist/evm/typechain-types/interfaces/IERC20.js +3 -0
- package/dist/evm/typechain-types/interfaces/IERC20.js.map +1 -0
- package/dist/evm/typechain-types/interfaces/index.d.ts +2 -0
- package/dist/evm/typechain-types/interfaces/index.d.ts.map +1 -0
- package/dist/evm/typechain-types/interfaces/index.js +3 -0
- package/dist/evm/typechain-types/interfaces/index.js.map +1 -0
- package/dist/solana/solana/index.d.ts +3 -0
- package/dist/solana/solana/index.d.ts.map +1 -0
- package/dist/solana/solana/index.js +21 -0
- package/dist/solana/solana/index.js.map +1 -0
- package/dist/solana/solana/mailer-client.d.ts +282 -0
- package/dist/solana/solana/mailer-client.d.ts.map +1 -0
- package/dist/solana/solana/mailer-client.js +989 -0
- package/dist/solana/solana/mailer-client.js.map +1 -0
- package/dist/solana/solana/types.d.ts +28 -0
- package/dist/solana/solana/types.d.ts.map +1 -0
- package/dist/solana/solana/types.js +23 -0
- package/dist/solana/solana/types.js.map +1 -0
- package/dist/solana/utils/currency.d.ts +26 -0
- package/dist/solana/utils/currency.d.ts.map +1 -0
- package/dist/solana/utils/currency.js +36 -0
- package/dist/solana/utils/currency.js.map +1 -0
- package/dist/unified/package.json +3 -0
- package/dist/unified/src/evm/index.d.ts +4 -0
- package/dist/unified/src/evm/index.d.ts.map +1 -0
- package/dist/unified/src/evm/index.js +10 -0
- package/dist/unified/src/evm/index.js.map +1 -0
- package/dist/unified/src/evm/mailer-client.d.ts +966 -0
- package/dist/unified/src/evm/mailer-client.d.ts.map +1 -0
- package/dist/unified/src/evm/mailer-client.js +619 -0
- package/dist/unified/src/evm/mailer-client.js.map +1 -0
- package/dist/unified/src/react/context/MailerProvider.d.ts +102 -0
- package/dist/unified/src/react/context/MailerProvider.d.ts.map +1 -0
- package/dist/unified/src/react/context/MailerProvider.js +160 -0
- package/dist/unified/src/react/context/MailerProvider.js.map +1 -0
- package/dist/unified/src/react/hooks/useMailerMutations.d.ts +301 -0
- package/dist/unified/src/react/hooks/useMailerMutations.d.ts.map +1 -0
- package/dist/unified/src/react/hooks/useMailerMutations.js +417 -0
- package/dist/unified/src/react/hooks/useMailerMutations.js.map +1 -0
- package/dist/unified/src/react/hooks/useMailerQueries.d.ts +130 -0
- package/dist/unified/src/react/hooks/useMailerQueries.d.ts.map +1 -0
- package/dist/unified/src/react/hooks/useMailerQueries.js +197 -0
- package/dist/unified/src/react/hooks/useMailerQueries.js.map +1 -0
- package/dist/unified/src/react/index.d.ts +37 -0
- package/dist/unified/src/react/index.d.ts.map +1 -0
- package/dist/unified/src/react/index.js +70 -0
- package/dist/unified/src/react/index.js.map +1 -0
- package/dist/unified/src/solana/index.d.ts +3 -0
- package/dist/unified/src/solana/index.d.ts.map +1 -0
- package/dist/unified/src/solana/index.js +21 -0
- package/dist/unified/src/solana/index.js.map +1 -0
- package/dist/unified/src/solana/mailer-client.d.ts +282 -0
- package/dist/unified/src/solana/mailer-client.d.ts.map +1 -0
- package/dist/unified/src/solana/mailer-client.js +989 -0
- package/dist/unified/src/solana/mailer-client.js.map +1 -0
- package/dist/unified/src/solana/types.d.ts +28 -0
- package/dist/unified/src/solana/types.d.ts.map +1 -0
- package/dist/unified/src/solana/types.js +23 -0
- package/dist/unified/src/solana/types.js.map +1 -0
- package/dist/unified/src/unified/index.d.ts +4 -0
- package/dist/unified/src/unified/index.d.ts.map +1 -0
- package/dist/unified/src/unified/index.js +9 -0
- package/dist/unified/src/unified/index.js.map +1 -0
- package/dist/unified/src/unified/onchain-mailer-client.d.ts +173 -0
- package/dist/unified/src/unified/onchain-mailer-client.d.ts.map +1 -0
- package/dist/unified/src/unified/onchain-mailer-client.js +1048 -0
- package/dist/unified/src/unified/onchain-mailer-client.js.map +1 -0
- package/dist/unified/src/unified/types.d.ts +47 -0
- package/dist/unified/src/unified/types.d.ts.map +1 -0
- package/dist/unified/src/unified/types.js +3 -0
- package/dist/unified/src/unified/types.js.map +1 -0
- package/dist/unified/src/unified/wallet-detector.d.ts +28 -0
- package/dist/unified/src/unified/wallet-detector.d.ts.map +1 -0
- package/dist/unified/src/unified/wallet-detector.js +63 -0
- package/dist/unified/src/unified/wallet-detector.js.map +1 -0
- package/dist/unified/src/utils/chain-config.d.ts +75 -0
- package/dist/unified/src/utils/chain-config.d.ts.map +1 -0
- package/dist/unified/src/utils/chain-config.js +203 -0
- package/dist/unified/src/utils/chain-config.js.map +1 -0
- package/dist/unified/src/utils/currency.d.ts +26 -0
- package/dist/unified/src/utils/currency.d.ts.map +1 -0
- package/dist/unified/src/utils/currency.js +36 -0
- package/dist/unified/src/utils/currency.js.map +1 -0
- package/dist/unified/src/utils/index.d.ts +4 -0
- package/dist/unified/src/utils/index.d.ts.map +1 -0
- package/dist/unified/src/utils/index.js +20 -0
- package/dist/unified/src/utils/index.js.map +1 -0
- package/dist/unified/src/utils/validation.d.ts +10 -0
- package/dist/unified/src/utils/validation.d.ts.map +1 -0
- package/dist/unified/src/utils/validation.js +102 -0
- package/dist/unified/src/utils/validation.js.map +1 -0
- package/dist/unified/typechain-types/Mailer.d.ts +698 -0
- package/dist/unified/typechain-types/Mailer.d.ts.map +1 -0
- package/dist/unified/typechain-types/Mailer.js +3 -0
- package/dist/unified/typechain-types/Mailer.js.map +1 -0
- package/dist/unified/typechain-types/MockUSDC.d.ts +118 -0
- package/dist/unified/typechain-types/MockUSDC.d.ts.map +1 -0
- package/dist/unified/typechain-types/MockUSDC.js +3 -0
- package/dist/unified/typechain-types/MockUSDC.js.map +1 -0
- package/dist/unified/typechain-types/common.d.ts +51 -0
- package/dist/unified/typechain-types/common.d.ts.map +1 -0
- package/dist/unified/typechain-types/common.js +3 -0
- package/dist/unified/typechain-types/common.js.map +1 -0
- package/dist/unified/typechain-types/factories/Mailer__factory.d.ts +875 -0
- package/dist/unified/typechain-types/factories/Mailer__factory.d.ts.map +1 -0
- package/dist/unified/typechain-types/factories/Mailer__factory.js +1125 -0
- package/dist/unified/typechain-types/factories/Mailer__factory.js.map +1 -0
- package/dist/unified/typechain-types/factories/MockUSDC__factory.d.ts +193 -0
- package/dist/unified/typechain-types/factories/MockUSDC__factory.d.ts.map +1 -0
- package/dist/unified/typechain-types/factories/MockUSDC__factory.js +263 -0
- package/dist/unified/typechain-types/factories/MockUSDC__factory.js.map +1 -0
- package/dist/unified/typechain-types/factories/index.d.ts +4 -0
- package/dist/unified/typechain-types/factories/index.d.ts.map +1 -0
- package/dist/unified/typechain-types/factories/index.js +45 -0
- package/dist/unified/typechain-types/factories/index.js.map +1 -0
- package/dist/unified/typechain-types/factories/interfaces/IERC20__factory.d.ts +80 -0
- package/dist/unified/typechain-types/factories/interfaces/IERC20__factory.d.ts.map +1 -0
- package/dist/unified/typechain-types/factories/interfaces/IERC20__factory.js +116 -0
- package/dist/unified/typechain-types/factories/interfaces/IERC20__factory.js.map +1 -0
- package/dist/unified/typechain-types/factories/interfaces/index.d.ts +2 -0
- package/dist/unified/typechain-types/factories/interfaces/index.d.ts.map +1 -0
- package/dist/unified/typechain-types/factories/interfaces/index.js +9 -0
- package/dist/unified/typechain-types/factories/interfaces/index.js.map +1 -0
- package/dist/unified/typechain-types/index.d.ts +10 -0
- package/dist/unified/typechain-types/index.d.ts.map +1 -0
- package/dist/unified/typechain-types/index.js +44 -0
- package/dist/unified/typechain-types/index.js.map +1 -0
- package/dist/unified/typechain-types/interfaces/IERC20.d.ts +70 -0
- package/dist/unified/typechain-types/interfaces/IERC20.d.ts.map +1 -0
- package/dist/unified/typechain-types/interfaces/IERC20.js +3 -0
- package/dist/unified/typechain-types/interfaces/IERC20.js.map +1 -0
- package/dist/unified/typechain-types/interfaces/index.d.ts +2 -0
- package/dist/unified/typechain-types/interfaces/index.d.ts.map +1 -0
- package/dist/unified/typechain-types/interfaces/index.js +3 -0
- package/dist/unified/typechain-types/interfaces/index.js.map +1 -0
- package/dist/unified-esm/src/evm/index.d.ts +4 -0
- package/dist/unified-esm/src/evm/index.d.ts.map +1 -0
- package/dist/unified-esm/src/evm/index.js +5 -0
- package/dist/unified-esm/src/evm/index.js.map +1 -0
- package/dist/unified-esm/src/evm/mailer-client.d.ts +966 -0
- package/dist/unified-esm/src/evm/mailer-client.d.ts.map +1 -0
- package/dist/unified-esm/src/evm/mailer-client.js +615 -0
- package/dist/unified-esm/src/evm/mailer-client.js.map +1 -0
- package/dist/unified-esm/src/react/context/MailerProvider.d.ts +102 -0
- package/dist/unified-esm/src/react/context/MailerProvider.d.ts.map +1 -0
- package/dist/unified-esm/src/react/context/MailerProvider.js +120 -0
- package/dist/unified-esm/src/react/context/MailerProvider.js.map +1 -0
- package/dist/unified-esm/src/react/hooks/useMailerMutations.d.ts +301 -0
- package/dist/unified-esm/src/react/hooks/useMailerMutations.d.ts.map +1 -0
- package/dist/unified-esm/src/react/hooks/useMailerMutations.js +400 -0
- package/dist/unified-esm/src/react/hooks/useMailerMutations.js.map +1 -0
- package/dist/unified-esm/src/react/hooks/useMailerQueries.d.ts +130 -0
- package/dist/unified-esm/src/react/hooks/useMailerQueries.d.ts.map +1 -0
- package/dist/unified-esm/src/react/hooks/useMailerQueries.js +186 -0
- package/dist/unified-esm/src/react/hooks/useMailerQueries.js.map +1 -0
- package/dist/unified-esm/src/react/index.d.ts +37 -0
- package/dist/unified-esm/src/react/index.d.ts.map +1 -0
- package/dist/unified-esm/src/react/index.js +39 -0
- package/dist/unified-esm/src/react/index.js.map +1 -0
- package/dist/unified-esm/src/solana/index.d.ts +3 -0
- package/dist/unified-esm/src/solana/index.d.ts.map +1 -0
- package/dist/unified-esm/src/solana/index.js +3 -0
- package/dist/unified-esm/src/solana/index.js.map +1 -0
- package/dist/unified-esm/src/solana/mailer-client.d.ts +282 -0
- package/dist/unified-esm/src/solana/mailer-client.d.ts.map +1 -0
- package/dist/unified-esm/src/solana/mailer-client.js +985 -0
- package/dist/unified-esm/src/solana/mailer-client.js.map +1 -0
- package/dist/unified-esm/src/solana/types.d.ts +28 -0
- package/dist/unified-esm/src/solana/types.d.ts.map +1 -0
- package/dist/unified-esm/src/solana/types.js +16 -0
- package/dist/unified-esm/src/solana/types.js.map +1 -0
- package/dist/unified-esm/src/unified/index.d.ts +4 -0
- package/dist/unified-esm/src/unified/index.d.ts.map +1 -0
- package/dist/unified-esm/src/unified/index.js +4 -0
- package/dist/unified-esm/src/unified/index.js.map +1 -0
- package/dist/unified-esm/src/unified/onchain-mailer-client.d.ts +173 -0
- package/dist/unified-esm/src/unified/onchain-mailer-client.d.ts.map +1 -0
- package/dist/unified-esm/src/unified/onchain-mailer-client.js +1011 -0
- package/dist/unified-esm/src/unified/onchain-mailer-client.js.map +1 -0
- package/dist/unified-esm/src/unified/types.d.ts +47 -0
- package/dist/unified-esm/src/unified/types.d.ts.map +1 -0
- package/dist/unified-esm/src/unified/types.js +2 -0
- package/dist/unified-esm/src/unified/types.js.map +1 -0
- package/dist/unified-esm/src/unified/wallet-detector.d.ts +28 -0
- package/dist/unified-esm/src/unified/wallet-detector.d.ts.map +1 -0
- package/dist/unified-esm/src/unified/wallet-detector.js +59 -0
- package/dist/unified-esm/src/unified/wallet-detector.js.map +1 -0
- package/dist/unified-esm/src/utils/chain-config.d.ts +75 -0
- package/dist/unified-esm/src/utils/chain-config.d.ts.map +1 -0
- package/dist/unified-esm/src/utils/chain-config.js +199 -0
- package/dist/unified-esm/src/utils/chain-config.js.map +1 -0
- package/dist/unified-esm/src/utils/currency.d.ts +26 -0
- package/dist/unified-esm/src/utils/currency.d.ts.map +1 -0
- package/dist/unified-esm/src/utils/currency.js +31 -0
- package/dist/unified-esm/src/utils/currency.js.map +1 -0
- package/dist/unified-esm/src/utils/index.d.ts +4 -0
- package/dist/unified-esm/src/utils/index.d.ts.map +1 -0
- package/dist/unified-esm/src/utils/index.js +4 -0
- package/dist/unified-esm/src/utils/index.js.map +1 -0
- package/dist/unified-esm/src/utils/validation.d.ts +10 -0
- package/dist/unified-esm/src/utils/validation.d.ts.map +1 -0
- package/dist/unified-esm/src/utils/validation.js +96 -0
- package/dist/unified-esm/src/utils/validation.js.map +1 -0
- package/dist/unified-esm/typechain-types/Mailer.d.ts +698 -0
- package/dist/unified-esm/typechain-types/Mailer.d.ts.map +1 -0
- package/dist/unified-esm/typechain-types/Mailer.js +2 -0
- package/dist/unified-esm/typechain-types/Mailer.js.map +1 -0
- package/dist/unified-esm/typechain-types/MockUSDC.d.ts +118 -0
- package/dist/unified-esm/typechain-types/MockUSDC.d.ts.map +1 -0
- package/dist/unified-esm/typechain-types/MockUSDC.js +2 -0
- package/dist/unified-esm/typechain-types/MockUSDC.js.map +1 -0
- package/dist/unified-esm/typechain-types/common.d.ts +51 -0
- package/dist/unified-esm/typechain-types/common.d.ts.map +1 -0
- package/dist/unified-esm/typechain-types/common.js +2 -0
- package/dist/unified-esm/typechain-types/common.js.map +1 -0
- package/dist/unified-esm/typechain-types/factories/Mailer__factory.d.ts +875 -0
- package/dist/unified-esm/typechain-types/factories/Mailer__factory.d.ts.map +1 -0
- package/dist/unified-esm/typechain-types/factories/Mailer__factory.js +1121 -0
- package/dist/unified-esm/typechain-types/factories/Mailer__factory.js.map +1 -0
- package/dist/unified-esm/typechain-types/factories/MockUSDC__factory.d.ts +193 -0
- package/dist/unified-esm/typechain-types/factories/MockUSDC__factory.d.ts.map +1 -0
- package/dist/unified-esm/typechain-types/factories/MockUSDC__factory.js +259 -0
- package/dist/unified-esm/typechain-types/factories/MockUSDC__factory.js.map +1 -0
- package/dist/unified-esm/typechain-types/factories/index.d.ts +4 -0
- package/dist/unified-esm/typechain-types/factories/index.d.ts.map +1 -0
- package/dist/unified-esm/typechain-types/factories/index.js +7 -0
- package/dist/unified-esm/typechain-types/factories/index.js.map +1 -0
- package/dist/unified-esm/typechain-types/factories/interfaces/IERC20__factory.d.ts +80 -0
- package/dist/unified-esm/typechain-types/factories/interfaces/IERC20__factory.d.ts.map +1 -0
- package/dist/unified-esm/typechain-types/factories/interfaces/IERC20__factory.js +112 -0
- package/dist/unified-esm/typechain-types/factories/interfaces/IERC20__factory.js.map +1 -0
- package/dist/unified-esm/typechain-types/factories/interfaces/index.d.ts +2 -0
- package/dist/unified-esm/typechain-types/factories/interfaces/index.d.ts.map +1 -0
- package/dist/unified-esm/typechain-types/factories/interfaces/index.js +5 -0
- package/dist/unified-esm/typechain-types/factories/interfaces/index.js.map +1 -0
- package/dist/unified-esm/typechain-types/index.d.ts +10 -0
- package/dist/unified-esm/typechain-types/index.d.ts.map +1 -0
- package/dist/unified-esm/typechain-types/index.js +5 -0
- package/dist/unified-esm/typechain-types/index.js.map +1 -0
- package/dist/unified-esm/typechain-types/interfaces/IERC20.d.ts +70 -0
- package/dist/unified-esm/typechain-types/interfaces/IERC20.d.ts.map +1 -0
- package/dist/unified-esm/typechain-types/interfaces/IERC20.js +2 -0
- package/dist/unified-esm/typechain-types/interfaces/IERC20.js.map +1 -0
- package/dist/unified-esm/typechain-types/interfaces/index.d.ts +2 -0
- package/dist/unified-esm/typechain-types/interfaces/index.d.ts.map +1 -0
- package/dist/unified-esm/typechain-types/interfaces/index.js +2 -0
- package/dist/unified-esm/typechain-types/interfaces/index.js.map +1 -0
- package/package.json +250 -0
- package/programs/mailer/Cargo.toml +29 -0
- package/programs/mailer/src/lib.rs +2034 -0
- package/programs/mailer/tests/integration_tests.rs +1236 -0
- package/typechain-types/Mailer.ts +1393 -0
- package/typechain-types/MockUSDC.ts +236 -0
- package/typechain-types/common.ts +131 -0
- package/typechain-types/factories/Mailer__factory.ts +1157 -0
- package/typechain-types/factories/MockUSDC__factory.ts +284 -0
- package/typechain-types/factories/index.ts +6 -0
- package/typechain-types/factories/interfaces/IERC20__factory.ts +115 -0
- package/typechain-types/factories/interfaces/index.ts +4 -0
- package/typechain-types/hardhat.d.ts +99 -0
- package/typechain-types/index.ts +12 -0
- package/typechain-types/interfaces/IERC20.ts +148 -0
- package/typechain-types/interfaces/index.ts +4 -0
|
@@ -0,0 +1,186 @@
|
|
|
1
|
+
import { useQuery } from '@tanstack/react-query';
|
|
2
|
+
import { useMailerClient } from '../context/MailerProvider.js';
|
|
3
|
+
/**
|
|
4
|
+
* Query keys for React Query cache management
|
|
5
|
+
*/
|
|
6
|
+
export const mailerQueryKeys = {
|
|
7
|
+
all: ['mailer'],
|
|
8
|
+
sendFee: () => [...mailerQueryKeys.all, 'sendFee'],
|
|
9
|
+
delegationFee: () => [...mailerQueryKeys.all, 'delegationFee'],
|
|
10
|
+
claimableAmount: (address) => [...mailerQueryKeys.all, 'claimableAmount', address],
|
|
11
|
+
ownerClaimable: () => [...mailerQueryKeys.all, 'ownerClaimable'],
|
|
12
|
+
delegation: (address) => [...mailerQueryKeys.all, 'delegation', address],
|
|
13
|
+
isPaused: () => [...mailerQueryKeys.all, 'isPaused'],
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Hook to get the current send fee
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* ```tsx
|
|
20
|
+
* function FeeDisplay() {
|
|
21
|
+
* const { data: fee, isLoading } = useGetSendFee();
|
|
22
|
+
*
|
|
23
|
+
* if (isLoading) return <div>Loading...</div>;
|
|
24
|
+
* return <div>Send Fee: {Number(fee) / 1_000_000} USDC</div>;
|
|
25
|
+
* }
|
|
26
|
+
* ```
|
|
27
|
+
*/
|
|
28
|
+
export function useGetSendFee(options) {
|
|
29
|
+
const client = useMailerClient();
|
|
30
|
+
return useQuery({
|
|
31
|
+
queryKey: mailerQueryKeys.sendFee(),
|
|
32
|
+
queryFn: () => client.getSendFee(),
|
|
33
|
+
staleTime: 5 * 60 * 1000, // 5 minutes - fees don't change often
|
|
34
|
+
...options,
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Hook to get the current delegation fee
|
|
39
|
+
*
|
|
40
|
+
* @example
|
|
41
|
+
* ```tsx
|
|
42
|
+
* function DelegationFeeDisplay() {
|
|
43
|
+
* const { data: fee, isLoading } = useGetDelegationFee();
|
|
44
|
+
*
|
|
45
|
+
* if (isLoading) return <div>Loading...</div>;
|
|
46
|
+
* return <div>Delegation Fee: {Number(fee) / 1_000_000} USDC</div>;
|
|
47
|
+
* }
|
|
48
|
+
* ```
|
|
49
|
+
*/
|
|
50
|
+
export function useGetDelegationFee(options) {
|
|
51
|
+
const client = useMailerClient();
|
|
52
|
+
return useQuery({
|
|
53
|
+
queryKey: mailerQueryKeys.delegationFee(),
|
|
54
|
+
queryFn: () => client.getDelegationFee(),
|
|
55
|
+
staleTime: 5 * 60 * 1000, // 5 minutes
|
|
56
|
+
...options,
|
|
57
|
+
});
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Hook to get claimable amount for an address
|
|
61
|
+
*
|
|
62
|
+
* @param address - Address to check (defaults to connected wallet)
|
|
63
|
+
* @example
|
|
64
|
+
* ```tsx
|
|
65
|
+
* function ClaimableBalance() {
|
|
66
|
+
* const { data: amount, isLoading } = useGetClaimableAmount();
|
|
67
|
+
*
|
|
68
|
+
* if (isLoading) return <div>Loading...</div>;
|
|
69
|
+
* if (!amount || amount === 0n) return <div>No claimable balance</div>;
|
|
70
|
+
* return <div>Claimable: {Number(amount) / 1_000_000} USDC</div>;
|
|
71
|
+
* }
|
|
72
|
+
* ```
|
|
73
|
+
*/
|
|
74
|
+
export function useGetClaimableAmount(address, options) {
|
|
75
|
+
const client = useMailerClient();
|
|
76
|
+
return useQuery({
|
|
77
|
+
queryKey: mailerQueryKeys.claimableAmount(address),
|
|
78
|
+
queryFn: () => client.getClaimableAmount(address),
|
|
79
|
+
staleTime: 30 * 1000, // 30 seconds - balances change more frequently
|
|
80
|
+
...options,
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Hook to get owner's claimable fee balance
|
|
85
|
+
*
|
|
86
|
+
* @example
|
|
87
|
+
* ```tsx
|
|
88
|
+
* function OwnerDashboard() {
|
|
89
|
+
* const { data: amount, isLoading } = useGetOwnerClaimable();
|
|
90
|
+
*
|
|
91
|
+
* if (isLoading) return <div>Loading...</div>;
|
|
92
|
+
* return <div>Owner Fees: {Number(amount) / 1_000_000} USDC</div>;
|
|
93
|
+
* }
|
|
94
|
+
* ```
|
|
95
|
+
*/
|
|
96
|
+
export function useGetOwnerClaimable(options) {
|
|
97
|
+
const client = useMailerClient();
|
|
98
|
+
return useQuery({
|
|
99
|
+
queryKey: mailerQueryKeys.ownerClaimable(),
|
|
100
|
+
queryFn: () => client.getOwnerClaimable(),
|
|
101
|
+
staleTime: 30 * 1000, // 30 seconds
|
|
102
|
+
...options,
|
|
103
|
+
});
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* Hook to get delegation information for an address
|
|
107
|
+
*
|
|
108
|
+
* @param address - Address to check delegation for (defaults to connected wallet)
|
|
109
|
+
* @example
|
|
110
|
+
* ```tsx
|
|
111
|
+
* function DelegationStatus() {
|
|
112
|
+
* const { data: delegate, isLoading } = useGetDelegation();
|
|
113
|
+
*
|
|
114
|
+
* if (isLoading) return <div>Loading...</div>;
|
|
115
|
+
* if (!delegate) return <div>No delegation set</div>;
|
|
116
|
+
* return <div>Delegated to: {delegate}</div>;
|
|
117
|
+
* }
|
|
118
|
+
* ```
|
|
119
|
+
*/
|
|
120
|
+
export function useGetDelegation(address, options) {
|
|
121
|
+
const client = useMailerClient();
|
|
122
|
+
return useQuery({
|
|
123
|
+
queryKey: mailerQueryKeys.delegation(address),
|
|
124
|
+
queryFn: () => client.getDelegation(address),
|
|
125
|
+
staleTime: 1 * 60 * 1000, // 1 minute
|
|
126
|
+
...options,
|
|
127
|
+
});
|
|
128
|
+
}
|
|
129
|
+
/**
|
|
130
|
+
* Hook to check if contract is currently paused
|
|
131
|
+
*
|
|
132
|
+
* @example
|
|
133
|
+
* ```tsx
|
|
134
|
+
* function PauseStatus() {
|
|
135
|
+
* const { data: isPaused, isLoading } = useIsPaused();
|
|
136
|
+
*
|
|
137
|
+
* if (isLoading) return <div>Loading...</div>;
|
|
138
|
+
* return (
|
|
139
|
+
* <div>
|
|
140
|
+
* Contract Status: {isPaused ? '⏸️ Paused' : '✅ Active'}
|
|
141
|
+
* </div>
|
|
142
|
+
* );
|
|
143
|
+
* }
|
|
144
|
+
* ```
|
|
145
|
+
*/
|
|
146
|
+
export function useIsPaused(options) {
|
|
147
|
+
const client = useMailerClient();
|
|
148
|
+
return useQuery({
|
|
149
|
+
queryKey: mailerQueryKeys.isPaused(),
|
|
150
|
+
queryFn: () => client.isPaused(),
|
|
151
|
+
staleTime: 10 * 1000, // 10 seconds - pause status is critical
|
|
152
|
+
refetchInterval: 30 * 1000, // Refetch every 30 seconds
|
|
153
|
+
...options,
|
|
154
|
+
});
|
|
155
|
+
}
|
|
156
|
+
/**
|
|
157
|
+
* Hook to get wallet address from the client
|
|
158
|
+
*
|
|
159
|
+
* @example
|
|
160
|
+
* ```tsx
|
|
161
|
+
* function WalletAddress() {
|
|
162
|
+
* const address = useWalletAddress();
|
|
163
|
+
* return <div>Connected: {address}</div>;
|
|
164
|
+
* }
|
|
165
|
+
* ```
|
|
166
|
+
*/
|
|
167
|
+
export function useWalletAddress() {
|
|
168
|
+
const client = useMailerClient();
|
|
169
|
+
return client.getWalletAddress();
|
|
170
|
+
}
|
|
171
|
+
/**
|
|
172
|
+
* Hook to get chain type (EVM or Solana)
|
|
173
|
+
*
|
|
174
|
+
* @example
|
|
175
|
+
* ```tsx
|
|
176
|
+
* function ChainBadge() {
|
|
177
|
+
* const chainType = useChainType();
|
|
178
|
+
* return <div>Chain: {chainType}</div>;
|
|
179
|
+
* }
|
|
180
|
+
* ```
|
|
181
|
+
*/
|
|
182
|
+
export function useChainType() {
|
|
183
|
+
const client = useMailerClient();
|
|
184
|
+
return client.getChainType();
|
|
185
|
+
}
|
|
186
|
+
//# sourceMappingURL=useMailerQueries.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useMailerQueries.js","sourceRoot":"","sources":["../../../../../src/react/hooks/useMailerQueries.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAmC,MAAM,uBAAuB,CAAC;AAClF,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAE5D;;GAEG;AACH,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,GAAG,EAAE,CAAC,Q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AE,CAAC;IAEjC,OAAO,QAAQ,CAAC;QACd,QAAQ,EAAE,eAAe,CAAC,QAAQ,EAAE;QACpC,OAAO,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,QAAQ,EAAE;QAChC,SAAS,EAAE,EAAE,GAAG,IAAI,EAAE,wCAAwC;QAC9D,eAAe,EAAE,EAAE,GAAG,IAAI,EAAE,2BAA2B;QACvD,GAAG,OAAO;KACX,CAAC,CAAC;AACL,CAAC;AAED;;;;;;;;;;GAUG;AACH,MAAM,UAAU,gBAAgB;IAC9B,MAAM,MAAM,GAAG,eAAe,EAAE,CAAC;IACjC,OAAO,MAAM,CAAC,gBAAgB,EAAE,CAAC;AACnC,CAAC;AAED;;;;;;;;;;GAUG;AACH,MAAM,UAAU,YAAY;IAC1B,MAAM,MAAM,GAAG,eAAe,EAAE,CAAC;IACjC,OAAO,MAAM,CAAC,YAAY,EAAE,CAAC;AAC/B,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* React integration for @johnqh/mail_box_contracts
|
|
3
|
+
*
|
|
4
|
+
* Provides React Query hooks and context for interacting with the
|
|
5
|
+
* OnchainMailerClient across EVM and Solana chains.
|
|
6
|
+
*
|
|
7
|
+
* @module @johnqh/mail_box_contracts/react
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```tsx
|
|
11
|
+
* import { MailerProvider, useGetSendFee, useSendMessage } from '@johnqh/mail_box_contracts/react';
|
|
12
|
+
*
|
|
13
|
+
* function App() {
|
|
14
|
+
* return (
|
|
15
|
+
* <MailerProvider wallet={wallet} config={config}>
|
|
16
|
+
* <MessageSender />
|
|
17
|
+
* </MailerProvider>
|
|
18
|
+
* );
|
|
19
|
+
* }
|
|
20
|
+
*
|
|
21
|
+
* function MessageSender() {
|
|
22
|
+
* const { data: fee } = useGetSendFee();
|
|
23
|
+
* const sendMessage = useSendMessage();
|
|
24
|
+
*
|
|
25
|
+
* return (
|
|
26
|
+
* <button onClick={() => sendMessage.mutate({ subject: 'Hi', body: 'Hello!' })}>
|
|
27
|
+
* Send (Fee: {Number(fee) / 1_000_000} USDC)
|
|
28
|
+
* </button>
|
|
29
|
+
* );
|
|
30
|
+
* }
|
|
31
|
+
* ```
|
|
32
|
+
*/
|
|
33
|
+
export { MailerProvider, useMailerClient, QueryClient, QueryClientProvider } from './context/MailerProvider';
|
|
34
|
+
export { useGetSendFee, useGetDelegationFee, useGetClaimableAmount, useGetOwnerClaimable, useGetDelegation, useIsPaused, useWalletAddress, useChainType, mailerQueryKeys, } from './hooks/useMailerQueries';
|
|
35
|
+
export { useSendMessage, useSendPrepared, useSendToEmail, useSendPreparedToEmail, useClaimRevenue, useClaimOwnerShare, useClaimExpiredShares, useDelegateTo, useRejectDelegation, useSetFee, useSetDelegationFee, usePause, useUnpause, useEmergencyUnpause, useDistributeClaimableFunds, } from './hooks/useMailerMutations';
|
|
36
|
+
export type { ChainConfig, MessageResult, UnifiedTransaction } from '../unified/types';
|
|
37
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/react/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAGH,OAAO,EAAE,cAAc,EAAE,eAAe,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAG7G,OAAO,EACL,aAAa,EACb,mBAAmB,EACnB,qBAAqB,EACrB,oBAAoB,EACpB,gBAAgB,EAChB,WAAW,EACX,gBAAgB,EAChB,YAAY,EACZ,eAAe,GAChB,MAAM,0BAA0B,CAAC;AAGlC,OAAO,EACL,cAAc,EACd,eAAe,EACf,cAAc,EACd,sBAAsB,EACtB,eAAe,EACf,kBAAkB,EAClB,qBAAqB,EACrB,aAAa,EACb,mBAAmB,EACnB,SAAS,EACT,mBAAmB,EACnB,QAAQ,EACR,UAAU,EACV,mBAAmB,EACnB,2BAA2B,GAC5B,MAAM,4BAA4B,CAAC;AAGpC,YAAY,EAAE,WAAW,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* React integration for @johnqh/mail_box_contracts
|
|
3
|
+
*
|
|
4
|
+
* Provides React Query hooks and context for interacting with the
|
|
5
|
+
* OnchainMailerClient across EVM and Solana chains.
|
|
6
|
+
*
|
|
7
|
+
* @module @johnqh/mail_box_contracts/react
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```tsx
|
|
11
|
+
* import { MailerProvider, useGetSendFee, useSendMessage } from '@johnqh/mail_box_contracts/react';
|
|
12
|
+
*
|
|
13
|
+
* function App() {
|
|
14
|
+
* return (
|
|
15
|
+
* <MailerProvider wallet={wallet} config={config}>
|
|
16
|
+
* <MessageSender />
|
|
17
|
+
* </MailerProvider>
|
|
18
|
+
* );
|
|
19
|
+
* }
|
|
20
|
+
*
|
|
21
|
+
* function MessageSender() {
|
|
22
|
+
* const { data: fee } = useGetSendFee();
|
|
23
|
+
* const sendMessage = useSendMessage();
|
|
24
|
+
*
|
|
25
|
+
* return (
|
|
26
|
+
* <button onClick={() => sendMessage.mutate({ subject: 'Hi', body: 'Hello!' })}>
|
|
27
|
+
* Send (Fee: {Number(fee) / 1_000_000} USDC)
|
|
28
|
+
* </button>
|
|
29
|
+
* );
|
|
30
|
+
* }
|
|
31
|
+
* ```
|
|
32
|
+
*/
|
|
33
|
+
// Context and Provider
|
|
34
|
+
export { MailerProvider, useMailerClient, QueryClient, QueryClientProvider } from './context/MailerProvider.js';
|
|
35
|
+
// Query Hooks (Read Operations)
|
|
36
|
+
export { useGetSendFee, useGetDelegationFee, useGetClaimableAmount, useGetOwnerClaimable, useGetDelegation, useIsPaused, useWalletAddress, useChainType, mailerQueryKeys, } from './hooks/useMailerQueries.js';
|
|
37
|
+
// Mutation Hooks (Write Operations)
|
|
38
|
+
export { useSendMessage, useSendPrepared, useSendToEmail, useSendPreparedToEmail, useClaimRevenue, useClaimOwnerShare, useClaimExpiredShares, useDelegateTo, useRejectDelegation, useSetFee, useSetDelegationFee, usePause, useUnpause, useEmergencyUnpause, useDistributeClaimableFunds, } from './hooks/useMailerMutations.js';
|
|
39
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/react/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,uBAAuB;AACvB,OAAO,EAAE,cAAc,EAAE,eAAe,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAE7G,gCAAgC;AAChC,OAAO,EACL,aAAa,EACb,mBAAmB,EACnB,qBAAqB,EACrB,oBAAoB,EACpB,gBAAgB,EAChB,WAAW,EACX,gBAAgB,EAChB,YAAY,EACZ,eAAe,GAChB,MAAM,0BAA0B,CAAC;AAElC,oCAAoC;AACpC,OAAO,EACL,cAAc,EACd,eAAe,EACf,cAAc,EACd,sBAAsB,EACtB,eAAe,EACf,kBAAkB,EAClB,qBAAqB,EACrB,aAAa,EACb,mBAAmB,EACnB,SAAS,EACT,mBAAmB,EACnB,QAAQ,EACR,UAAU,EACV,mBAAmB,EACnB,2BAA2B,GAC5B,MAAM,4BAA4B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/solana/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,YAAY,EACZ,KAAK,MAAM,EACX,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACvB,MAAM,oBAAoB,CAAC;AAC5B,cAAc,YAAY,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/solana/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,YAAY,EAIb,MAAM,oBAAoB,CAAC;AAC5B,cAAc,YAAY,CAAC"}
|
|
@@ -0,0 +1,282 @@
|
|
|
1
|
+
import { Connection, PublicKey, Transaction, Keypair, ConfirmOptions } from '@solana/web3.js';
|
|
2
|
+
import { Optional } from '@sudobility/types';
|
|
3
|
+
import { ClaimableInfo, MailerFees } from './types.js';
|
|
4
|
+
/**
|
|
5
|
+
* Interface for wallet adapter pattern
|
|
6
|
+
*/
|
|
7
|
+
export interface Wallet {
|
|
8
|
+
publicKey: PublicKey;
|
|
9
|
+
signTransaction<T extends Transaction>(transaction: T): Promise<T>;
|
|
10
|
+
signAllTransactions<T extends Transaction>(transactions: T[]): Promise<T[]>;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Compute unit optimization options for Solana transactions
|
|
14
|
+
*/
|
|
15
|
+
export interface ComputeUnitOptions {
|
|
16
|
+
/**
|
|
17
|
+
* Compute unit limit for the transaction (default: 200,000)
|
|
18
|
+
* Max: 1,400,000
|
|
19
|
+
*/
|
|
20
|
+
computeUnitLimit?: number;
|
|
21
|
+
/**
|
|
22
|
+
* Priority fee in micro-lamports per compute unit
|
|
23
|
+
* Higher values = faster inclusion during congestion
|
|
24
|
+
*/
|
|
25
|
+
computeUnitPrice?: number;
|
|
26
|
+
/**
|
|
27
|
+
* Automatically simulate and optimize compute units
|
|
28
|
+
* @default false
|
|
29
|
+
*/
|
|
30
|
+
autoOptimize?: boolean;
|
|
31
|
+
/**
|
|
32
|
+
* Multiplier for compute unit buffer when auto-optimizing
|
|
33
|
+
* @default 1.2 (20% buffer)
|
|
34
|
+
*/
|
|
35
|
+
computeUnitMultiplier?: number;
|
|
36
|
+
/**
|
|
37
|
+
* Skip compute unit settings entirely
|
|
38
|
+
* @default false
|
|
39
|
+
*/
|
|
40
|
+
skipComputeUnits?: boolean;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Transaction result with compute unit details
|
|
44
|
+
*/
|
|
45
|
+
export interface TransactionResult {
|
|
46
|
+
/**
|
|
47
|
+
* Transaction signature
|
|
48
|
+
*/
|
|
49
|
+
signature: string;
|
|
50
|
+
/**
|
|
51
|
+
* Simulated compute units (if auto-optimized)
|
|
52
|
+
*/
|
|
53
|
+
simulatedUnits?: number;
|
|
54
|
+
/**
|
|
55
|
+
* Actual compute unit limit set
|
|
56
|
+
*/
|
|
57
|
+
computeUnitLimit?: number;
|
|
58
|
+
/**
|
|
59
|
+
* Priority fee per compute unit (if set)
|
|
60
|
+
*/
|
|
61
|
+
computeUnitPrice?: number;
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* @class MailerClient
|
|
65
|
+
* @description Native Solana program client for the Mailer program
|
|
66
|
+
* @notice Provides easy-to-use methods for sending messages with USDC fees and revenue sharing
|
|
67
|
+
*
|
|
68
|
+
* ## Key Features:
|
|
69
|
+
* - **Priority Messages**: Full fee (0.1 USDC) with 90% revenue share to recipient
|
|
70
|
+
* - **Standard Messages**: 10% fee only (0.01 USDC) with no revenue share
|
|
71
|
+
* - **Revenue Claims**: 60-day claim period for priority message revenue shares
|
|
72
|
+
* - **Delegation Management**: Delegate message handling with rejection capability
|
|
73
|
+
*
|
|
74
|
+
* ## Usage Examples:
|
|
75
|
+
* ```typescript
|
|
76
|
+
* // Connect to existing deployed program
|
|
77
|
+
* const connection = new Connection('https://api.devnet.solana.com');
|
|
78
|
+
* const wallet = new WalletAdapter(keypair);
|
|
79
|
+
* const programId = new PublicKey('9FLkBDGpZBcR8LMsQ7MwwV6X9P4TDFgN3DeRh5qYyHJF');
|
|
80
|
+
* const usdcMint = new PublicKey('EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v');
|
|
81
|
+
* const client = new MailerClient(connection, wallet, programId, usdcMint);
|
|
82
|
+
*
|
|
83
|
+
* // Send message with revenue sharing to recipient
|
|
84
|
+
* await client.send('recipient-address', 'Subject', 'Message body', true);
|
|
85
|
+
*
|
|
86
|
+
* // Claim your revenue share within 60 days (as recipient)
|
|
87
|
+
* await client.claimRecipientShare();
|
|
88
|
+
*
|
|
89
|
+
* // Check claimable amount
|
|
90
|
+
* const info = await client.getRecipientClaimable();
|
|
91
|
+
* if (info) console.log(`Claimable: ${formatUSDC(info.amount)} USDC`);
|
|
92
|
+
* ```
|
|
93
|
+
*
|
|
94
|
+
* @author Mailer Team
|
|
95
|
+
* @version 2.0.0 - Native Solana Program (no Anchor)
|
|
96
|
+
*/
|
|
97
|
+
export declare class MailerClient {
|
|
98
|
+
private connection;
|
|
99
|
+
private wallet;
|
|
100
|
+
private programId;
|
|
101
|
+
private usdcMint;
|
|
102
|
+
private mailerStatePda;
|
|
103
|
+
private mailerBump;
|
|
104
|
+
private defaultComputeUnitMultiplier;
|
|
105
|
+
constructor(connection: Connection, wallet: Wallet, programId: PublicKey, usdcMint: PublicKey);
|
|
106
|
+
/**
|
|
107
|
+
* Optimize compute units for a transaction
|
|
108
|
+
* @param transaction Transaction to optimize
|
|
109
|
+
* @param options Compute unit options
|
|
110
|
+
* @returns Optimized transaction with compute budget instructions
|
|
111
|
+
*/
|
|
112
|
+
private optimizeComputeUnits;
|
|
113
|
+
/**
|
|
114
|
+
* Initialize the mailer program (owner only)
|
|
115
|
+
* @param computeOptions Compute unit optimization options
|
|
116
|
+
*/
|
|
117
|
+
initialize(computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
118
|
+
/**
|
|
119
|
+
* Send a message with optional revenue sharing
|
|
120
|
+
* @param to Recipient's public key or address string who receives message and potential revenue share
|
|
121
|
+
* @param subject Message subject
|
|
122
|
+
* @param body Message body
|
|
123
|
+
* @param revenueShareToReceiver If true, recipient gets 90% revenue share; if false, no revenue share
|
|
124
|
+
* @param resolveSenderToName If true, resolve sender address to name via off-chain service
|
|
125
|
+
* @param computeOptions Compute unit optimization options
|
|
126
|
+
* @returns Transaction result with signature and compute details
|
|
127
|
+
*/
|
|
128
|
+
send(to: string | PublicKey, subject: string, body: string, revenueShareToReceiver?: boolean, resolveSenderToName?: boolean, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
129
|
+
/**
|
|
130
|
+
* Claim recipient share of revenue
|
|
131
|
+
* @returns Transaction result
|
|
132
|
+
*/
|
|
133
|
+
claimRecipientShare(computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
134
|
+
/**
|
|
135
|
+
* Claim owner share of fees (owner only)
|
|
136
|
+
* @returns Transaction result
|
|
137
|
+
*/
|
|
138
|
+
claimOwnerShare(computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
139
|
+
/**
|
|
140
|
+
* Claim expired recipient shares and move them under owner control
|
|
141
|
+
* @param recipient Recipient whose expired shares to reclaim
|
|
142
|
+
* @param options Transaction confirm options
|
|
143
|
+
* @returns Transaction signature
|
|
144
|
+
*/
|
|
145
|
+
claimExpiredShares(recipient: string | PublicKey, options?: ConfirmOptions, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
146
|
+
/**
|
|
147
|
+
* Delegate message handling to another address
|
|
148
|
+
* @param delegate Address to delegate to, or null to clear delegation
|
|
149
|
+
* @returns Transaction signature
|
|
150
|
+
*/
|
|
151
|
+
delegateTo(delegate?: Optional<string | PublicKey>, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
152
|
+
/**
|
|
153
|
+
* Reject a delegation made to you
|
|
154
|
+
* @param delegator Address that delegated to you
|
|
155
|
+
* @returns Transaction signature
|
|
156
|
+
*/
|
|
157
|
+
rejectDelegation(delegator: string | PublicKey, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
158
|
+
/**
|
|
159
|
+
* Set the send fee (owner only)
|
|
160
|
+
* @param newFee New fee in USDC micro-units (6 decimals)
|
|
161
|
+
* @param computeOptions Compute unit optimization options
|
|
162
|
+
* @returns Transaction result
|
|
163
|
+
*/
|
|
164
|
+
setFee(newFee: number | bigint, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
165
|
+
/**
|
|
166
|
+
* Set the delegation fee (owner only)
|
|
167
|
+
* @param newFee New delegation fee in USDC micro-units (6 decimals)
|
|
168
|
+
* @returns Transaction signature
|
|
169
|
+
*/
|
|
170
|
+
setDelegationFee(newFee: number | bigint, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
171
|
+
setCustomFeePercentage(account: string | PublicKey, percentage: number, payer?: Optional<string | PublicKey>, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
172
|
+
clearCustomFeePercentage(account: string | PublicKey, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
173
|
+
getCustomFeePercentage(account: string | PublicKey): Promise<number>;
|
|
174
|
+
/**
|
|
175
|
+
* Get current fees from the mailer state
|
|
176
|
+
* @returns MailerFees object with current fees
|
|
177
|
+
*/
|
|
178
|
+
getFees(): Promise<MailerFees>;
|
|
179
|
+
/**
|
|
180
|
+
* Get recipient claimable information
|
|
181
|
+
* @param recipient Optional recipient address, defaults to wallet address
|
|
182
|
+
* @returns ClaimableInfo or null if no claimable amount
|
|
183
|
+
*/
|
|
184
|
+
getRecipientClaimable(recipient?: Optional<PublicKey>): Promise<Optional<ClaimableInfo>>;
|
|
185
|
+
/**
|
|
186
|
+
* Get owner claimable amount
|
|
187
|
+
* @returns Owner claimable amount in USDC micro-units
|
|
188
|
+
*/
|
|
189
|
+
getOwnerClaimable(): Promise<number>;
|
|
190
|
+
/**
|
|
191
|
+
* Get delegation information for an address
|
|
192
|
+
* @param delegator Address to check delegation for, defaults to wallet address
|
|
193
|
+
* @returns Delegation info or null if no delegation
|
|
194
|
+
*/
|
|
195
|
+
getDelegation(delegator?: Optional<PublicKey>): Promise<Optional<{
|
|
196
|
+
delegator: string;
|
|
197
|
+
delegate?: Optional<string>;
|
|
198
|
+
}>>;
|
|
199
|
+
/**
|
|
200
|
+
* Get the mailer state PDA address
|
|
201
|
+
* @returns PublicKey of the mailer state PDA
|
|
202
|
+
*/
|
|
203
|
+
getMailerStatePda(): PublicKey;
|
|
204
|
+
/**
|
|
205
|
+
* Send a message to an email address (no wallet known)
|
|
206
|
+
* Charges only 10% owner fee since recipient wallet is unknown
|
|
207
|
+
* @param toEmail Email address of the recipient
|
|
208
|
+
* @param subject Message subject
|
|
209
|
+
* @param body Message body
|
|
210
|
+
* @param options Transaction confirm options
|
|
211
|
+
* @returns Transaction signature
|
|
212
|
+
*/
|
|
213
|
+
sendToEmail(toEmail: string, subject: string, body: string, options?: ConfirmOptions, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
214
|
+
/**
|
|
215
|
+
* Send a prepared message to an email address (no wallet known)
|
|
216
|
+
* Charges only 10% owner fee since recipient wallet is unknown
|
|
217
|
+
* @param toEmail Email address of the recipient
|
|
218
|
+
* @param mailId Pre-prepared message ID
|
|
219
|
+
* @param options Transaction confirm options
|
|
220
|
+
* @returns Transaction signature
|
|
221
|
+
*/
|
|
222
|
+
sendPreparedToEmail(toEmail: string, mailId: string, options?: ConfirmOptions, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
223
|
+
/**
|
|
224
|
+
* Send a prepared message using a mailId (to match EVM behavior)
|
|
225
|
+
* @param to Recipient's public key or address string
|
|
226
|
+
* @param mailId Pre-prepared message identifier
|
|
227
|
+
* @param revenueShareToReceiver If true, recipient gets 90% revenue share
|
|
228
|
+
* @param resolveSenderToName If true, resolve sender address to name
|
|
229
|
+
* @returns Transaction signature
|
|
230
|
+
*/
|
|
231
|
+
sendPrepared(to: string | PublicKey, mailId: string, revenueShareToReceiver?: boolean, resolveSenderToName?: boolean, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
232
|
+
sendThroughWebhook(to: string | PublicKey, webhookId: string, revenueShareToReceiver?: boolean, resolveSenderToName?: boolean, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
233
|
+
/**
|
|
234
|
+
* Pause the contract and distribute owner claimable funds (owner only)
|
|
235
|
+
* @param options Transaction confirm options
|
|
236
|
+
* @returns Transaction signature
|
|
237
|
+
*/
|
|
238
|
+
pause(options?: ConfirmOptions, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
239
|
+
/**
|
|
240
|
+
* Unpause the contract (owner only)
|
|
241
|
+
* @param options Transaction confirm options
|
|
242
|
+
* @returns Transaction signature
|
|
243
|
+
*/
|
|
244
|
+
unpause(options?: ConfirmOptions, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
245
|
+
/**
|
|
246
|
+
* Emergency unpause without fund distribution (owner only)
|
|
247
|
+
* @param options Transaction confirm options
|
|
248
|
+
* @returns Transaction signature
|
|
249
|
+
*/
|
|
250
|
+
emergencyUnpause(options?: ConfirmOptions, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
251
|
+
/**
|
|
252
|
+
* Distribute claimable funds to a recipient when contract is paused
|
|
253
|
+
* @param recipient Recipient address to distribute funds for
|
|
254
|
+
* @param options Transaction confirm options
|
|
255
|
+
* @returns Transaction signature
|
|
256
|
+
*/
|
|
257
|
+
distributeClaimableFunds(recipient: string | PublicKey, options?: ConfirmOptions, computeOptions?: ComputeUnitOptions): Promise<TransactionResult>;
|
|
258
|
+
/**
|
|
259
|
+
* Get the current send fee
|
|
260
|
+
* @returns Send fee in USDC micro-units (6 decimals)
|
|
261
|
+
*/
|
|
262
|
+
getSendFee(): Promise<bigint>;
|
|
263
|
+
/**
|
|
264
|
+
* Check if contract is currently paused
|
|
265
|
+
* @returns True if contract is paused, false otherwise
|
|
266
|
+
*/
|
|
267
|
+
isPaused(): Promise<boolean>;
|
|
268
|
+
/**
|
|
269
|
+
* Send and confirm a transaction
|
|
270
|
+
* @param transaction Transaction to send
|
|
271
|
+
* @param options Confirm options
|
|
272
|
+
* @returns Transaction signature
|
|
273
|
+
*/
|
|
274
|
+
private sendTransaction;
|
|
275
|
+
/**
|
|
276
|
+
* Create a simple wallet from a keypair for testing
|
|
277
|
+
* @param keypair Solana keypair
|
|
278
|
+
* @returns Wallet interface implementation
|
|
279
|
+
*/
|
|
280
|
+
static createWallet(keypair: Keypair): Wallet;
|
|
281
|
+
}
|
|
282
|
+
//# sourceMappingURL=mailer-client.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mailer-client.d.ts","sourceRoot":"","sources":["../../../../src/solana/mailer-client.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,SAAS,EACT,WAAW,EAEX,OAAO,EAEP,cAAc,EAEf,MAAM,iBAAiB,CAAC;AAMzB,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAE7C,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAEvD;;GAEG;AACH,MAAM,WAAW,MAAM;IACrB,SAAS,EAAE,SAAS,CAAC;IACrB,eAAe,CAAC,CAAC,SAAS,WAAW,EAAE,WAAW,EAAE,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC;IACnE,mBAAmB,CAAC,CAAC,SAAS,WAAW,EAAE,YAAY,EAAE,CAAC,EAAE,GAAG,OAAO,CAAC,CAAC,EAAE,CAAC,CAAC;CAC7E;AAED;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC;;;OAGG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE1B;;;OAGG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE1B;;;OAGG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;IAEvB;;;OAGG;IACH,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAE/B;;;OAGG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;OAEG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE1B;;OAEG;IACH,gBAAgB,CAAC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