GasPay SDK
1. Initialization
1.1 install
// npm
npm install @aabank/sdk
// yarn
yarn add @aabank/sdk
// pnpm
pnpm add @aabank/sdk1.2 init
import AAbankSDK from '@aabank/sdk';
type extraConfig {
isDebug: Boolean;
...
}
const appId = "000000";
const initSdk = async () => {
const provider = await connector?.getProvider()
// window.etherum.sendAsync or wagmi getProvider
const sdk = new AABank(provider, appId, { isDebug: true })
const { caAddress, publicKeyDerived } = await sdk.init()
...
}
2. Methods (API)
2.1 init()
2.2 isCaAddress()
2.3 getBalance()
2.4 getTransferInfo()
2.5 getTransactionInfo()
2.6 sendTransaction()
2.7 getTransactionStatus()
2.8 getTradeHistory()
2.9 getDepositHistory()
2.10 withdraw()
3. Business Scene
3.1 Transfer
Transfer Timeline

3.2 Withdraw
3.3 Transaction
4. Error
Code
Message
Desc
5. React
5.1 Hooks (Child Component)
Last updated