@ledgerhq/coin-solana 0.7.0-nightly.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/.eslintrc.js +20 -0
- package/.turbo/turbo-build.log +4 -0
- package/.unimportedrc.json +16 -0
- package/CHANGELOG.md +13 -0
- package/LICENSE.txt +21 -0
- package/jest.config.js +9 -0
- package/lib/api/cached.d.ts +3 -0
- package/lib/api/cached.d.ts.map +1 -0
- package/lib/api/cached.js +40 -0
- package/lib/api/cached.js.map +1 -0
- package/lib/api/chain/account/index.d.ts +2 -0
- package/lib/api/chain/account/index.d.ts.map +1 -0
- package/lib/api/chain/account/index.js +8 -0
- package/lib/api/chain/account/index.js.map +1 -0
- package/lib/api/chain/account/parser.d.ts +10 -0
- package/lib/api/chain/account/parser.d.ts.map +1 -0
- package/lib/api/chain/account/parser.js +56 -0
- package/lib/api/chain/account/parser.js.map +1 -0
- package/lib/api/chain/account/stake.d.ts +237 -0
- package/lib/api/chain/account/stake.d.ts.map +1 -0
- package/lib/api/chain/account/stake.js +38 -0
- package/lib/api/chain/account/stake.js.map +1 -0
- package/lib/api/chain/account/token.d.ts +116 -0
- package/lib/api/chain/account/token.d.ts.map +1 -0
- package/lib/api/chain/account/token.js +42 -0
- package/lib/api/chain/account/token.js.map +1 -0
- package/lib/api/chain/account/vote.d.ts +252 -0
- package/lib/api/chain/account/vote.d.ts.map +1 -0
- package/lib/api/chain/account/vote.js +44 -0
- package/lib/api/chain/account/vote.js.map +1 -0
- package/lib/api/chain/index.d.ts +29 -0
- package/lib/api/chain/index.d.ts.map +1 -0
- package/lib/api/chain/index.js +99 -0
- package/lib/api/chain/index.js.map +1 -0
- package/lib/api/chain/instruction/associated-token-account/index.d.ts +15 -0
- package/lib/api/chain/instruction/associated-token-account/index.d.ts.map +1 -0
- package/lib/api/chain/instruction/associated-token-account/index.js +21 -0
- package/lib/api/chain/instruction/associated-token-account/index.js.map +1 -0
- package/lib/api/chain/instruction/associated-token-account/types.d.ts +30 -0
- package/lib/api/chain/instruction/associated-token-account/types.d.ts.map +1 -0
- package/lib/api/chain/instruction/associated-token-account/types.js +19 -0
- package/lib/api/chain/instruction/associated-token-account/types.js.map +1 -0
- package/lib/api/chain/instruction/memo/index.d.ts +15 -0
- package/lib/api/chain/instruction/memo/index.d.ts.map +1 -0
- package/lib/api/chain/instruction/memo/index.js +14 -0
- package/lib/api/chain/instruction/memo/index.js.map +1 -0
- package/lib/api/chain/instruction/memo/types.d.ts +21 -0
- package/lib/api/chain/instruction/memo/types.d.ts.map +1 -0
- package/lib/api/chain/instruction/memo/types.js +16 -0
- package/lib/api/chain/instruction/memo/types.js.map +1 -0
- package/lib/api/chain/instruction/stake/index.d.ts +15 -0
- package/lib/api/chain/instruction/stake/index.d.ts.map +1 -0
- package/lib/api/chain/instruction/stake/index.js +20 -0
- package/lib/api/chain/instruction/stake/index.js.map +1 -0
- package/lib/api/chain/instruction/stake/types.d.ts +215 -0
- package/lib/api/chain/instruction/stake/types.d.ts.map +1 -0
- package/lib/api/chain/instruction/stake/types.js +80 -0
- package/lib/api/chain/instruction/stake/types.js.map +1 -0
- package/lib/api/chain/instruction/system/index.d.ts +15 -0
- package/lib/api/chain/instruction/system/index.d.ts.map +1 -0
- package/lib/api/chain/instruction/system/index.js +20 -0
- package/lib/api/chain/instruction/system/index.js.map +1 -0
- package/lib/api/chain/instruction/system/types.d.ts +298 -0
- package/lib/api/chain/instruction/system/types.d.ts.map +1 -0
- package/lib/api/chain/instruction/system/types.js +117 -0
- package/lib/api/chain/instruction/system/types.js.map +1 -0
- package/lib/api/chain/instruction/token/index.d.ts +15 -0
- package/lib/api/chain/instruction/token/index.d.ts.map +1 -0
- package/lib/api/chain/instruction/token/index.js +20 -0
- package/lib/api/chain/instruction/token/index.js.map +1 -0
- package/lib/api/chain/instruction/token/types.d.ts +497 -0
- package/lib/api/chain/instruction/token/types.d.ts.map +1 -0
- package/lib/api/chain/instruction/token/types.js +200 -0
- package/lib/api/chain/instruction/token/types.js.map +1 -0
- package/lib/api/chain/program/constants.d.ts +11 -0
- package/lib/api/chain/program/constants.d.ts.map +1 -0
- package/lib/api/chain/program/constants.js +14 -0
- package/lib/api/chain/program/constants.js.map +1 -0
- package/lib/api/chain/program/index.d.ts +2 -0
- package/lib/api/chain/program/index.d.ts.map +1 -0
- package/lib/api/chain/program/index.js +7 -0
- package/lib/api/chain/program/index.js.map +1 -0
- package/lib/api/chain/program/parser.d.ts +35 -0
- package/lib/api/chain/program/parser.d.ts.map +1 -0
- package/lib/api/chain/program/parser.js +66 -0
- package/lib/api/chain/program/parser.js.map +1 -0
- package/lib/api/chain/validators/bignum.d.ts +3 -0
- package/lib/api/chain/validators/bignum.d.ts.map +1 -0
- package/lib/api/chain/validators/bignum.js +11 -0
- package/lib/api/chain/validators/bignum.js.map +1 -0
- package/lib/api/chain/validators/index.d.ts +10 -0
- package/lib/api/chain/validators/index.d.ts.map +1 -0
- package/lib/api/chain/validators/index.js +10 -0
- package/lib/api/chain/validators/index.js.map +1 -0
- package/lib/api/chain/validators/pubkey.d.ts +3 -0
- package/lib/api/chain/validators/pubkey.d.ts.map +1 -0
- package/lib/api/chain/validators/pubkey.js +7 -0
- package/lib/api/chain/validators/pubkey.js.map +1 -0
- package/lib/api/chain/web3.d.ts +43 -0
- package/lib/api/chain/web3.d.ts.map +1 -0
- package/lib/api/chain/web3.js +274 -0
- package/lib/api/chain/web3.js.map +1 -0
- package/lib/api/index.d.ts +5 -0
- package/lib/api/index.d.ts.map +1 -0
- package/lib/api/index.js +25 -0
- package/lib/api/index.js.map +1 -0
- package/lib/api/logged.d.ts +3 -0
- package/lib/api/logged.d.ts.map +1 -0
- package/lib/api/logged.js +69 -0
- package/lib/api/logged.js.map +1 -0
- package/lib/api/queued.d.ts +3 -0
- package/lib/api/queued.d.ts.map +1 -0
- package/lib/api/queued.js +27 -0
- package/lib/api/queued.js.map +1 -0
- package/lib/api/traced.d.ts +3 -0
- package/lib/api/traced.d.ts.map +1 -0
- package/lib/api/traced.js +80 -0
- package/lib/api/traced.js.map +1 -0
- package/lib/bridge/bridge.d.ts +15 -0
- package/lib/bridge/bridge.d.ts.map +1 -0
- package/lib/bridge/bridge.js +139 -0
- package/lib/bridge/bridge.js.map +1 -0
- package/lib/bridge/js.d.ts +7 -0
- package/lib/bridge/js.d.ts.map +1 -0
- package/lib/bridge/js.js +28 -0
- package/lib/bridge/js.js.map +1 -0
- package/lib/bridge.integration.test.d.ts +4 -0
- package/lib/bridge.integration.test.d.ts.map +1 -0
- package/lib/bridge.integration.test.js +990 -0
- package/lib/bridge.integration.test.js.map +1 -0
- package/lib/cli-transaction.d.ts +19 -0
- package/lib/cli-transaction.d.ts.map +1 -0
- package/lib/cli-transaction.js +196 -0
- package/lib/cli-transaction.js.map +1 -0
- package/lib/datasets/solana.scanAccounts.1.d.ts +6 -0
- package/lib/datasets/solana.scanAccounts.1.d.ts.map +1 -0
- package/lib/datasets/solana.scanAccounts.1.js +12 -0
- package/lib/datasets/solana.scanAccounts.1.js.map +1 -0
- package/lib/deviceTransactionConfig.d.ts +10 -0
- package/lib/deviceTransactionConfig.d.ts.map +1 -0
- package/lib/deviceTransactionConfig.js +228 -0
- package/lib/deviceTransactionConfig.js.map +1 -0
- package/lib/errors.d.ts +61 -0
- package/lib/errors.d.ts.map +1 -0
- package/lib/errors.js +25 -0
- package/lib/errors.js.map +1 -0
- package/lib/hw-getAddress.d.ts +6 -0
- package/lib/hw-getAddress.d.ts.map +1 -0
- package/lib/hw-getAddress.js +28 -0
- package/lib/hw-getAddress.js.map +1 -0
- package/lib/js-broadcast.d.ts +7 -0
- package/lib/js-broadcast.d.ts.map +1 -0
- package/lib/js-broadcast.js +37 -0
- package/lib/js-broadcast.js.map +1 -0
- package/lib/js-buildTransaction.d.ts +5 -0
- package/lib/js-buildTransaction.d.ts.map +1 -0
- package/lib/js-buildTransaction.js +67 -0
- package/lib/js-buildTransaction.js.map +1 -0
- package/lib/js-createTransaction.d.ts +5 -0
- package/lib/js-createTransaction.d.ts.map +1 -0
- package/lib/js-createTransaction.js +19 -0
- package/lib/js-createTransaction.js.map +1 -0
- package/lib/js-estimateMaxSpendable.d.ts +11 -0
- package/lib/js-estimateMaxSpendable.d.ts.map +1 -0
- package/lib/js-estimateMaxSpendable.js +62 -0
- package/lib/js-estimateMaxSpendable.js.map +1 -0
- package/lib/js-getTransactionStatus.d.ts +5 -0
- package/lib/js-getTransactionStatus.d.ts.map +1 -0
- package/lib/js-getTransactionStatus.js +71 -0
- package/lib/js-getTransactionStatus.js.map +1 -0
- package/lib/js-preload-data.d.ts +7 -0
- package/lib/js-preload-data.d.ts.map +1 -0
- package/lib/js-preload-data.js +45 -0
- package/lib/js-preload-data.js.map +1 -0
- package/lib/js-preload.d.ts +7 -0
- package/lib/js-preload.d.ts.map +1 -0
- package/lib/js-preload.js +67 -0
- package/lib/js-preload.js.map +1 -0
- package/lib/js-preload.test.d.ts +2 -0
- package/lib/js-preload.test.d.ts.map +1 -0
- package/lib/js-preload.test.js +9 -0
- package/lib/js-preload.test.js.map +1 -0
- package/lib/js-prepareTransaction.d.ts +5 -0
- package/lib/js-prepareTransaction.d.ts.map +1 -0
- package/lib/js-prepareTransaction.js +500 -0
- package/lib/js-prepareTransaction.js.map +1 -0
- package/lib/js-signOperation.d.ts +7 -0
- package/lib/js-signOperation.d.ts.map +1 -0
- package/lib/js-signOperation.js +153 -0
- package/lib/js-signOperation.js.map +1 -0
- package/lib/js-synchronization.d.ts +5 -0
- package/lib/js-synchronization.d.ts.map +1 -0
- package/lib/js-synchronization.js +464 -0
- package/lib/js-synchronization.js.map +1 -0
- package/lib/logic.d.ts +29 -0
- package/lib/logic.d.ts.map +1 -0
- package/lib/logic.js +102 -0
- package/lib/logic.js.map +1 -0
- package/lib/serialization.d.ts +9 -0
- package/lib/serialization.d.ts.map +1 -0
- package/lib/serialization.js +69 -0
- package/lib/serialization.js.map +1 -0
- package/lib/signer.d.ts +11 -0
- package/lib/signer.d.ts.map +1 -0
- package/lib/signer.js +3 -0
- package/lib/signer.js.map +1 -0
- package/lib/specs.d.ts +7 -0
- package/lib/specs.d.ts.map +1 -0
- package/lib/specs.js +409 -0
- package/lib/specs.js.map +1 -0
- package/lib/speculos-deviceActions.d.ts +8 -0
- package/lib/speculos-deviceActions.d.ts.map +1 -0
- package/lib/speculos-deviceActions.js +217 -0
- package/lib/speculos-deviceActions.js.map +1 -0
- package/lib/transaction.d.ts +15 -0
- package/lib/transaction.d.ts.map +1 -0
- package/lib/transaction.js +153 -0
- package/lib/transaction.js.map +1 -0
- package/lib/tx-fees.d.ts +4 -0
- package/lib/tx-fees.d.ts.map +1 -0
- package/lib/tx-fees.js +167 -0
- package/lib/tx-fees.js.map +1 -0
- package/lib/types.d.ts +222 -0
- package/lib/types.d.ts.map +1 -0
- package/lib/types.js +3 -0
- package/lib/types.js.map +1 -0
- package/lib/utils.d.ts +24 -0
- package/lib/utils.d.ts.map +1 -0
- package/lib/utils.js +172 -0
- package/lib/utils.js.map +1 -0
- package/lib/validator-app/index.d.ts +22 -0
- package/lib/validator-app/index.d.ts.map +1 -0
- package/lib/validator-app/index.js +62 -0
- package/lib/validator-app/index.js.map +1 -0
- package/lib-es/api/cached.d.ts +3 -0
- package/lib-es/api/cached.d.ts.map +1 -0
- package/lib-es/api/cached.js +33 -0
- package/lib-es/api/cached.js.map +1 -0
- package/lib-es/api/chain/account/index.d.ts +2 -0
- package/lib-es/api/chain/account/index.d.ts.map +1 -0
- package/lib-es/api/chain/account/index.js +2 -0
- package/lib-es/api/chain/account/index.js.map +1 -0
- package/lib-es/api/chain/account/parser.d.ts +10 -0
- package/lib-es/api/chain/account/parser.d.ts.map +1 -0
- package/lib-es/api/chain/account/parser.js +48 -0
- package/lib-es/api/chain/account/parser.js.map +1 -0
- package/lib-es/api/chain/account/stake.d.ts +237 -0
- package/lib-es/api/chain/account/stake.d.ts.map +1 -0
- package/lib-es/api/chain/account/stake.js +35 -0
- package/lib-es/api/chain/account/stake.js.map +1 -0
- package/lib-es/api/chain/account/token.d.ts +116 -0
- package/lib-es/api/chain/account/token.d.ts.map +1 -0
- package/lib-es/api/chain/account/token.js +39 -0
- package/lib-es/api/chain/account/token.js.map +1 -0
- package/lib-es/api/chain/account/vote.d.ts +252 -0
- package/lib-es/api/chain/account/vote.d.ts.map +1 -0
- package/lib-es/api/chain/account/vote.js +41 -0
- package/lib-es/api/chain/account/vote.js.map +1 -0
- package/lib-es/api/chain/index.d.ts +29 -0
- package/lib-es/api/chain/index.d.ts.map +1 -0
- package/lib-es/api/chain/index.js +95 -0
- package/lib-es/api/chain/index.js.map +1 -0
- package/lib-es/api/chain/instruction/associated-token-account/index.d.ts +15 -0
- package/lib-es/api/chain/instruction/associated-token-account/index.d.ts.map +1 -0
- package/lib-es/api/chain/instruction/associated-token-account/index.js +17 -0
- package/lib-es/api/chain/instruction/associated-token-account/index.js.map +1 -0
- package/lib-es/api/chain/instruction/associated-token-account/types.d.ts +30 -0
- package/lib-es/api/chain/instruction/associated-token-account/types.d.ts.map +1 -0
- package/lib-es/api/chain/instruction/associated-token-account/types.js +16 -0
- package/lib-es/api/chain/instruction/associated-token-account/types.js.map +1 -0
- package/lib-es/api/chain/instruction/memo/index.d.ts +15 -0
- package/lib-es/api/chain/instruction/memo/index.d.ts.map +1 -0
- package/lib-es/api/chain/instruction/memo/index.js +10 -0
- package/lib-es/api/chain/instruction/memo/index.js.map +1 -0
- package/lib-es/api/chain/instruction/memo/types.d.ts +21 -0
- package/lib-es/api/chain/instruction/memo/types.d.ts.map +1 -0
- package/lib-es/api/chain/instruction/memo/types.js +13 -0
- package/lib-es/api/chain/instruction/memo/types.js.map +1 -0
- package/lib-es/api/chain/instruction/stake/index.d.ts +15 -0
- package/lib-es/api/chain/instruction/stake/index.d.ts.map +1 -0
- package/lib-es/api/chain/instruction/stake/index.js +16 -0
- package/lib-es/api/chain/instruction/stake/index.js.map +1 -0
- package/lib-es/api/chain/instruction/stake/types.d.ts +215 -0
- package/lib-es/api/chain/instruction/stake/types.d.ts.map +1 -0
- package/lib-es/api/chain/instruction/stake/types.js +77 -0
- package/lib-es/api/chain/instruction/stake/types.js.map +1 -0
- package/lib-es/api/chain/instruction/system/index.d.ts +15 -0
- package/lib-es/api/chain/instruction/system/index.d.ts.map +1 -0
- package/lib-es/api/chain/instruction/system/index.js +16 -0
- package/lib-es/api/chain/instruction/system/index.js.map +1 -0
- package/lib-es/api/chain/instruction/system/types.d.ts +298 -0
- package/lib-es/api/chain/instruction/system/types.d.ts.map +1 -0
- package/lib-es/api/chain/instruction/system/types.js +114 -0
- package/lib-es/api/chain/instruction/system/types.js.map +1 -0
- package/lib-es/api/chain/instruction/token/index.d.ts +15 -0
- package/lib-es/api/chain/instruction/token/index.d.ts.map +1 -0
- package/lib-es/api/chain/instruction/token/index.js +16 -0
- package/lib-es/api/chain/instruction/token/index.js.map +1 -0
- package/lib-es/api/chain/instruction/token/types.d.ts +497 -0
- package/lib-es/api/chain/instruction/token/types.d.ts.map +1 -0
- package/lib-es/api/chain/instruction/token/types.js +197 -0
- package/lib-es/api/chain/instruction/token/types.js.map +1 -0
- package/lib-es/api/chain/program/constants.d.ts +11 -0
- package/lib-es/api/chain/program/constants.d.ts.map +1 -0
- package/lib-es/api/chain/program/constants.js +11 -0
- package/lib-es/api/chain/program/constants.js.map +1 -0
- package/lib-es/api/chain/program/index.d.ts +2 -0
- package/lib-es/api/chain/program/index.d.ts.map +1 -0
- package/lib-es/api/chain/program/index.js +2 -0
- package/lib-es/api/chain/program/index.js.map +1 -0
- package/lib-es/api/chain/program/parser.d.ts +35 -0
- package/lib-es/api/chain/program/parser.d.ts.map +1 -0
- package/lib-es/api/chain/program/parser.js +61 -0
- package/lib-es/api/chain/program/parser.js.map +1 -0
- package/lib-es/api/chain/validators/bignum.d.ts +3 -0
- package/lib-es/api/chain/validators/bignum.d.ts.map +1 -0
- package/lib-es/api/chain/validators/bignum.js +8 -0
- package/lib-es/api/chain/validators/bignum.js.map +1 -0
- package/lib-es/api/chain/validators/index.d.ts +10 -0
- package/lib-es/api/chain/validators/index.d.ts.map +1 -0
- package/lib-es/api/chain/validators/index.js +7 -0
- package/lib-es/api/chain/validators/index.js.map +1 -0
- package/lib-es/api/chain/validators/pubkey.d.ts +3 -0
- package/lib-es/api/chain/validators/pubkey.d.ts.map +1 -0
- package/lib-es/api/chain/validators/pubkey.js +4 -0
- package/lib-es/api/chain/validators/pubkey.js.map +1 -0
- package/lib-es/api/chain/web3.d.ts +43 -0
- package/lib-es/api/chain/web3.d.ts.map +1 -0
- package/lib-es/api/chain/web3.js +251 -0
- package/lib-es/api/chain/web3.js.map +1 -0
- package/lib-es/api/index.d.ts +5 -0
- package/lib-es/api/index.d.ts.map +1 -0
- package/lib-es/api/index.js +5 -0
- package/lib-es/api/index.js.map +1 -0
- package/lib-es/api/logged.d.ts +3 -0
- package/lib-es/api/logged.d.ts.map +1 -0
- package/lib-es/api/logged.js +65 -0
- package/lib-es/api/logged.js.map +1 -0
- package/lib-es/api/queued.d.ts +3 -0
- package/lib-es/api/queued.d.ts.map +1 -0
- package/lib-es/api/queued.js +23 -0
- package/lib-es/api/queued.js.map +1 -0
- package/lib-es/api/traced.d.ts +3 -0
- package/lib-es/api/traced.d.ts.map +1 -0
- package/lib-es/api/traced.js +76 -0
- package/lib-es/api/traced.js.map +1 -0
- package/lib-es/bridge/bridge.d.ts +15 -0
- package/lib-es/bridge/bridge.d.ts.map +1 -0
- package/lib-es/bridge/bridge.js +132 -0
- package/lib-es/bridge/bridge.js.map +1 -0
- package/lib-es/bridge/js.d.ts +7 -0
- package/lib-es/bridge/js.d.ts.map +1 -0
- package/lib-es/bridge/js.js +24 -0
- package/lib-es/bridge/js.js.map +1 -0
- package/lib-es/bridge.integration.test.d.ts +4 -0
- package/lib-es/bridge.integration.test.d.ts.map +1 -0
- package/lib-es/bridge.integration.test.js +988 -0
- package/lib-es/bridge.integration.test.js.map +1 -0
- package/lib-es/cli-transaction.d.ts +19 -0
- package/lib-es/cli-transaction.d.ts.map +1 -0
- package/lib-es/cli-transaction.js +190 -0
- package/lib-es/cli-transaction.js.map +1 -0
- package/lib-es/datasets/solana.scanAccounts.1.d.ts +6 -0
- package/lib-es/datasets/solana.scanAccounts.1.d.ts.map +1 -0
- package/lib-es/datasets/solana.scanAccounts.1.js +10 -0
- package/lib-es/datasets/solana.scanAccounts.1.js.map +1 -0
- package/lib-es/deviceTransactionConfig.d.ts +10 -0
- package/lib-es/deviceTransactionConfig.d.ts.map +1 -0
- package/lib-es/deviceTransactionConfig.js +223 -0
- package/lib-es/deviceTransactionConfig.js.map +1 -0
- package/lib-es/errors.d.ts +61 -0
- package/lib-es/errors.d.ts.map +1 -0
- package/lib-es/errors.js +22 -0
- package/lib-es/errors.js.map +1 -0
- package/lib-es/hw-getAddress.d.ts +6 -0
- package/lib-es/hw-getAddress.d.ts.map +1 -0
- package/lib-es/hw-getAddress.js +23 -0
- package/lib-es/hw-getAddress.js.map +1 -0
- package/lib-es/js-broadcast.d.ts +7 -0
- package/lib-es/js-broadcast.d.ts.map +1 -0
- package/lib-es/js-broadcast.js +33 -0
- package/lib-es/js-broadcast.js.map +1 -0
- package/lib-es/js-buildTransaction.d.ts +5 -0
- package/lib-es/js-buildTransaction.d.ts.map +1 -0
- package/lib-es/js-buildTransaction.js +63 -0
- package/lib-es/js-buildTransaction.js.map +1 -0
- package/lib-es/js-createTransaction.d.ts +5 -0
- package/lib-es/js-createTransaction.d.ts.map +1 -0
- package/lib-es/js-createTransaction.js +17 -0
- package/lib-es/js-createTransaction.js.map +1 -0
- package/lib-es/js-estimateMaxSpendable.d.ts +11 -0
- package/lib-es/js-estimateMaxSpendable.d.ts.map +1 -0
- package/lib-es/js-estimateMaxSpendable.js +55 -0
- package/lib-es/js-estimateMaxSpendable.js.map +1 -0
- package/lib-es/js-getTransactionStatus.d.ts +5 -0
- package/lib-es/js-getTransactionStatus.d.ts.map +1 -0
- package/lib-es/js-getTransactionStatus.js +69 -0
- package/lib-es/js-getTransactionStatus.js.map +1 -0
- package/lib-es/js-preload-data.d.ts +7 -0
- package/lib-es/js-preload-data.d.ts.map +1 -0
- package/lib-es/js-preload-data.js +39 -0
- package/lib-es/js-preload-data.js.map +1 -0
- package/lib-es/js-preload.d.ts +7 -0
- package/lib-es/js-preload.d.ts.map +1 -0
- package/lib-es/js-preload.js +62 -0
- package/lib-es/js-preload.js.map +1 -0
- package/lib-es/js-preload.test.d.ts +2 -0
- package/lib-es/js-preload.test.d.ts.map +1 -0
- package/lib-es/js-preload.test.js +7 -0
- package/lib-es/js-preload.test.js.map +1 -0
- package/lib-es/js-prepareTransaction.d.ts +5 -0
- package/lib-es/js-prepareTransaction.d.ts.map +1 -0
- package/lib-es/js-prepareTransaction.js +497 -0
- package/lib-es/js-prepareTransaction.js.map +1 -0
- package/lib-es/js-signOperation.d.ts +7 -0
- package/lib-es/js-signOperation.d.ts.map +1 -0
- package/lib-es/js-signOperation.js +146 -0
- package/lib-es/js-signOperation.js.map +1 -0
- package/lib-es/js-synchronization.d.ts +5 -0
- package/lib-es/js-synchronization.d.ts.map +1 -0
- package/lib-es/js-synchronization.js +457 -0
- package/lib-es/js-synchronization.js.map +1 -0
- package/lib-es/logic.d.ts +29 -0
- package/lib-es/logic.d.ts.map +1 -0
- package/lib-es/logic.js +87 -0
- package/lib-es/logic.js.map +1 -0
- package/lib-es/serialization.d.ts +9 -0
- package/lib-es/serialization.d.ts.map +1 -0
- package/lib-es/serialization.js +60 -0
- package/lib-es/serialization.js.map +1 -0
- package/lib-es/signer.d.ts +11 -0
- package/lib-es/signer.d.ts.map +1 -0
- package/lib-es/signer.js +2 -0
- package/lib-es/signer.js.map +1 -0
- package/lib-es/specs.d.ts +7 -0
- package/lib-es/specs.d.ts.map +1 -0
- package/lib-es/specs.js +404 -0
- package/lib-es/specs.js.map +1 -0
- package/lib-es/speculos-deviceActions.d.ts +8 -0
- package/lib-es/speculos-deviceActions.d.ts.map +1 -0
- package/lib-es/speculos-deviceActions.js +211 -0
- package/lib-es/speculos-deviceActions.js.map +1 -0
- package/lib-es/transaction.d.ts +15 -0
- package/lib-es/transaction.d.ts.map +1 -0
- package/lib-es/transaction.js +147 -0
- package/lib-es/transaction.js.map +1 -0
- package/lib-es/tx-fees.d.ts +4 -0
- package/lib-es/tx-fees.d.ts.map +1 -0
- package/lib-es/tx-fees.js +160 -0
- package/lib-es/tx-fees.js.map +1 -0
- package/lib-es/types.d.ts +222 -0
- package/lib-es/types.d.ts.map +1 -0
- package/lib-es/types.js +2 -0
- package/lib-es/types.js.map +1 -0
- package/lib-es/utils.d.ts +24 -0
- package/lib-es/utils.d.ts.map +1 -0
- package/lib-es/utils.js +157 -0
- package/lib-es/utils.js.map +1 -0
- package/lib-es/validator-app/index.d.ts +22 -0
- package/lib-es/validator-app/index.d.ts.map +1 -0
- package/lib-es/validator-app/index.js +55 -0
- package/lib-es/validator-app/index.js.map +1 -0
- package/package.json +89 -0
- package/src/api/cached.ts +87 -0
- package/src/api/chain/account/index.ts +1 -0
- package/src/api/chain/account/parser.ts +63 -0
- package/src/api/chain/account/stake.ts +45 -0
- package/src/api/chain/account/token.ts +63 -0
- package/src/api/chain/account/vote.ts +55 -0
- package/src/api/chain/index.ts +203 -0
- package/src/api/chain/instruction/associated-token-account/index.ts +33 -0
- package/src/api/chain/instruction/associated-token-account/types.ts +23 -0
- package/src/api/chain/instruction/memo/index.ts +24 -0
- package/src/api/chain/instruction/memo/types.ts +18 -0
- package/src/api/chain/instruction/stake/index.ts +29 -0
- package/src/api/chain/instruction/stake/types.ts +95 -0
- package/src/api/chain/instruction/system/index.ts +30 -0
- package/src/api/chain/instruction/system/types.ts +141 -0
- package/src/api/chain/instruction/token/index.ts +30 -0
- package/src/api/chain/instruction/token/types.ts +222 -0
- package/src/api/chain/program/constants.ts +10 -0
- package/src/api/chain/program/index.ts +1 -0
- package/src/api/chain/program/parser.ts +120 -0
- package/src/api/chain/validators/bignum.ts +7 -0
- package/src/api/chain/validators/index.ts +9 -0
- package/src/api/chain/validators/pubkey.ts +8 -0
- package/src/api/chain/web3.ts +399 -0
- package/src/api/index.ts +4 -0
- package/src/api/logged.ts +70 -0
- package/src/api/queued.ts +25 -0
- package/src/api/traced.ts +89 -0
- package/src/bridge/bridge.ts +195 -0
- package/src/bridge/js.ts +44 -0
- package/src/bridge.integration.test.ts +1106 -0
- package/src/cli-transaction.ts +246 -0
- package/src/datasets/solana.scanAccounts.1.ts +9 -0
- package/src/deviceTransactionConfig.ts +302 -0
- package/src/errors.ts +61 -0
- package/src/hw-getAddress.ts +26 -0
- package/src/js-broadcast.ts +38 -0
- package/src/js-buildTransaction.ts +81 -0
- package/src/js-createTransaction.ts +20 -0
- package/src/js-estimateMaxSpendable.ts +72 -0
- package/src/js-getTransactionStatus.ts +72 -0
- package/src/js-preload-data.ts +46 -0
- package/src/js-preload.test.ts +14 -0
- package/src/js-preload.ts +74 -0
- package/src/js-prepareTransaction.ts +686 -0
- package/src/js-signOperation.ts +329 -0
- package/src/js-synchronization.ts +729 -0
- package/src/logic.ts +123 -0
- package/src/serialization.ts +81 -0
- package/src/signer.ts +21 -0
- package/src/specs.ts +514 -0
- package/src/speculos-deviceActions.ts +229 -0
- package/src/transaction.ts +194 -0
- package/src/tx-fees.ts +206 -0
- package/src/types.ts +284 -0
- package/src/utils.ts +176 -0
- package/src/validator-app/index.ts +79 -0
- package/tsconfig.json +12 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"token.d.ts","sourceRoot":"","sources":["../../../../src/api/chain/account/token.ts"],"names":[],"mappings":";AAEA,OAAO,EACL,KAAK,EAUN,MAAM,aAAa,CAAC;AAGrB,MAAM,MAAM,gBAAgB,GAAG,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAC9D,eAAO,MAAM,gBAAgB;;;;EAAyC,CAAC;AAEvE,MAAM,MAAM,iBAAiB,GAAG,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AAC3D,QAAA,MAAM,YAAY;;;;EAAoD,CAAC;AAQvE,MAAM,MAAM,gBAAgB,GAAG,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAC9D,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAU3B,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAC5D,eAAO,MAAM,eAAe;;;;;;;;;;;;EAM1B,CAAC;AAEH,MAAM,MAAM,mBAAmB,GAAG,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AACpE,eAAO,MAAM,mBAAmB;;;;;;;;;;EAK9B,CAAC;AAEH,MAAM,MAAM,YAAY,GAAG,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AACtD,eAAO,MAAM,YAAY;;;;;;;;;;EAGvB,CAAC"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable @typescript-eslint/no-redeclare */
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.TokenAccount = exports.MultisigAccountInfo = exports.MintAccountInfo = exports.TokenAccountInfo = exports.TokenAccountType = void 0;
|
|
5
|
+
const superstruct_1 = require("superstruct");
|
|
6
|
+
const pubkey_1 = require("../validators/pubkey");
|
|
7
|
+
exports.TokenAccountType = (0, superstruct_1.enums)(["mint", "account", "multisig"]);
|
|
8
|
+
const AccountState = (0, superstruct_1.enums)(["initialized", "uninitialized", "frozen"]);
|
|
9
|
+
const TokenAmount = (0, superstruct_1.type)({
|
|
10
|
+
decimals: (0, superstruct_1.number)(),
|
|
11
|
+
uiAmountString: (0, superstruct_1.string)(),
|
|
12
|
+
amount: (0, superstruct_1.string)(),
|
|
13
|
+
});
|
|
14
|
+
exports.TokenAccountInfo = (0, superstruct_1.type)({
|
|
15
|
+
mint: pubkey_1.PublicKeyFromString,
|
|
16
|
+
owner: pubkey_1.PublicKeyFromString,
|
|
17
|
+
tokenAmount: TokenAmount,
|
|
18
|
+
delegate: (0, superstruct_1.optional)(pubkey_1.PublicKeyFromString),
|
|
19
|
+
state: AccountState,
|
|
20
|
+
isNative: (0, superstruct_1.boolean)(),
|
|
21
|
+
rentExemptReserve: (0, superstruct_1.optional)(TokenAmount),
|
|
22
|
+
delegatedAmount: (0, superstruct_1.optional)(TokenAmount),
|
|
23
|
+
closeAuthority: (0, superstruct_1.optional)(pubkey_1.PublicKeyFromString),
|
|
24
|
+
});
|
|
25
|
+
exports.MintAccountInfo = (0, superstruct_1.type)({
|
|
26
|
+
mintAuthority: (0, superstruct_1.nullable)(pubkey_1.PublicKeyFromString),
|
|
27
|
+
supply: (0, superstruct_1.string)(),
|
|
28
|
+
decimals: (0, superstruct_1.number)(),
|
|
29
|
+
isInitialized: (0, superstruct_1.boolean)(),
|
|
30
|
+
freezeAuthority: (0, superstruct_1.nullable)(pubkey_1.PublicKeyFromString),
|
|
31
|
+
});
|
|
32
|
+
exports.MultisigAccountInfo = (0, superstruct_1.type)({
|
|
33
|
+
numRequiredSigners: (0, superstruct_1.number)(),
|
|
34
|
+
numValidSigners: (0, superstruct_1.number)(),
|
|
35
|
+
isInitialized: (0, superstruct_1.boolean)(),
|
|
36
|
+
signers: (0, superstruct_1.array)(pubkey_1.PublicKeyFromString),
|
|
37
|
+
});
|
|
38
|
+
exports.TokenAccount = (0, superstruct_1.type)({
|
|
39
|
+
type: exports.TokenAccountType,
|
|
40
|
+
info: (0, superstruct_1.any)(),
|
|
41
|
+
});
|
|
42
|
+
//# sourceMappingURL=token.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"token.js","sourceRoot":"","sources":["../../../../src/api/chain/account/token.ts"],"names":[],"mappings":";AAAA,oDAAoD;;;AAEpD,6CAWqB;AACrB,iDAA2D;AAG9C,QAAA,gBAAgB,GAAG,IAAA,mBAAK,EAAC,CAAC,MAAM,EAAE,SAAS,EAAE,UAAU,CAAC,CAAC,CAAC;AAGvE,MA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,EAAC;IAC/B,IAAI,EAAE,wBAAgB;IACtB,IAAI,EAAE,IAAA,iBAAG,GAAE;CACZ,CAAC,CAAC"}
|
|
@@ -0,0 +1,252 @@
|
|
|
1
|
+
/// <reference types="@solana/web3.js" />
|
|
2
|
+
import { Infer } from "superstruct";
|
|
3
|
+
export type VoteAccountType = Infer<typeof VoteAccountType>;
|
|
4
|
+
export declare const VoteAccountType: import("superstruct").Struct<"vote", {
|
|
5
|
+
vote: "vote";
|
|
6
|
+
}>;
|
|
7
|
+
export type AuthorizedVoter = Infer<typeof AuthorizedVoter>;
|
|
8
|
+
export declare const AuthorizedVoter: import("superstruct").Struct<{
|
|
9
|
+
epoch: number;
|
|
10
|
+
authorizedVoter: import("@solana/web3.js").PublicKey;
|
|
11
|
+
}, {
|
|
12
|
+
authorizedVoter: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
13
|
+
epoch: import("superstruct").Struct<number, null>;
|
|
14
|
+
}>;
|
|
15
|
+
export type PriorVoter = Infer<typeof PriorVoter>;
|
|
16
|
+
export declare const PriorVoter: import("superstruct").Struct<{
|
|
17
|
+
authorizedPubkey: import("@solana/web3.js").PublicKey;
|
|
18
|
+
epochOfLastAuthorizedSwitch: number;
|
|
19
|
+
targetEpoch: number;
|
|
20
|
+
}, {
|
|
21
|
+
authorizedPubkey: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
22
|
+
epochOfLastAuthorizedSwitch: import("superstruct").Struct<number, null>;
|
|
23
|
+
targetEpoch: import("superstruct").Struct<number, null>;
|
|
24
|
+
}>;
|
|
25
|
+
export type EpochCredits = Infer<typeof EpochCredits>;
|
|
26
|
+
export declare const EpochCredits: import("superstruct").Struct<{
|
|
27
|
+
epoch: number;
|
|
28
|
+
credits: string;
|
|
29
|
+
previousCredits: string;
|
|
30
|
+
}, {
|
|
31
|
+
epoch: import("superstruct").Struct<number, null>;
|
|
32
|
+
credits: import("superstruct").Struct<string, null>;
|
|
33
|
+
previousCredits: import("superstruct").Struct<string, null>;
|
|
34
|
+
}>;
|
|
35
|
+
export type Vote = Infer<typeof Vote>;
|
|
36
|
+
export declare const Vote: import("superstruct").Struct<{
|
|
37
|
+
slot: number;
|
|
38
|
+
confirmationCount: number;
|
|
39
|
+
}, {
|
|
40
|
+
slot: import("superstruct").Struct<number, null>;
|
|
41
|
+
confirmationCount: import("superstruct").Struct<number, null>;
|
|
42
|
+
}>;
|
|
43
|
+
export type VoteAccountInfo = Infer<typeof VoteAccountInfo>;
|
|
44
|
+
export declare const VoteAccountInfo: import("superstruct").Struct<{
|
|
45
|
+
commission: number;
|
|
46
|
+
authorizedVoters: {
|
|
47
|
+
epoch: number;
|
|
48
|
+
authorizedVoter: import("@solana/web3.js").PublicKey;
|
|
49
|
+
}[];
|
|
50
|
+
authorizedWithdrawer: import("@solana/web3.js").PublicKey;
|
|
51
|
+
epochCredits: {
|
|
52
|
+
epoch: number;
|
|
53
|
+
credits: string;
|
|
54
|
+
previousCredits: string;
|
|
55
|
+
}[];
|
|
56
|
+
lastTimestamp: {
|
|
57
|
+
slot: number;
|
|
58
|
+
timestamp: number;
|
|
59
|
+
};
|
|
60
|
+
nodePubkey: import("@solana/web3.js").PublicKey;
|
|
61
|
+
priorVoters: {
|
|
62
|
+
authorizedPubkey: import("@solana/web3.js").PublicKey;
|
|
63
|
+
epochOfLastAuthorizedSwitch: number;
|
|
64
|
+
targetEpoch: number;
|
|
65
|
+
}[];
|
|
66
|
+
rootSlot: number | null;
|
|
67
|
+
votes: {
|
|
68
|
+
slot: number;
|
|
69
|
+
confirmationCount: number;
|
|
70
|
+
}[];
|
|
71
|
+
}, {
|
|
72
|
+
authorizedVoters: import("superstruct").Struct<{
|
|
73
|
+
epoch: number;
|
|
74
|
+
authorizedVoter: import("@solana/web3.js").PublicKey;
|
|
75
|
+
}[], import("superstruct").Struct<{
|
|
76
|
+
epoch: number;
|
|
77
|
+
authorizedVoter: import("@solana/web3.js").PublicKey;
|
|
78
|
+
}, {
|
|
79
|
+
authorizedVoter: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
80
|
+
epoch: import("superstruct").Struct<number, null>;
|
|
81
|
+
}>>;
|
|
82
|
+
authorizedWithdrawer: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
83
|
+
commission: import("superstruct").Struct<number, null>;
|
|
84
|
+
epochCredits: import("superstruct").Struct<{
|
|
85
|
+
epoch: number;
|
|
86
|
+
credits: string;
|
|
87
|
+
previousCredits: string;
|
|
88
|
+
}[], import("superstruct").Struct<{
|
|
89
|
+
epoch: number;
|
|
90
|
+
credits: string;
|
|
91
|
+
previousCredits: string;
|
|
92
|
+
}, {
|
|
93
|
+
epoch: import("superstruct").Struct<number, null>;
|
|
94
|
+
credits: import("superstruct").Struct<string, null>;
|
|
95
|
+
previousCredits: import("superstruct").Struct<string, null>;
|
|
96
|
+
}>>;
|
|
97
|
+
lastTimestamp: import("superstruct").Struct<{
|
|
98
|
+
slot: number;
|
|
99
|
+
timestamp: number;
|
|
100
|
+
}, {
|
|
101
|
+
slot: import("superstruct").Struct<number, null>;
|
|
102
|
+
timestamp: import("superstruct").Struct<number, null>;
|
|
103
|
+
}>;
|
|
104
|
+
nodePubkey: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
105
|
+
priorVoters: import("superstruct").Struct<{
|
|
106
|
+
authorizedPubkey: import("@solana/web3.js").PublicKey;
|
|
107
|
+
epochOfLastAuthorizedSwitch: number;
|
|
108
|
+
targetEpoch: number;
|
|
109
|
+
}[], import("superstruct").Struct<{
|
|
110
|
+
authorizedPubkey: import("@solana/web3.js").PublicKey;
|
|
111
|
+
epochOfLastAuthorizedSwitch: number;
|
|
112
|
+
targetEpoch: number;
|
|
113
|
+
}, {
|
|
114
|
+
authorizedPubkey: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
115
|
+
epochOfLastAuthorizedSwitch: import("superstruct").Struct<number, null>;
|
|
116
|
+
targetEpoch: import("superstruct").Struct<number, null>;
|
|
117
|
+
}>>;
|
|
118
|
+
rootSlot: import("superstruct").Struct<number | null, null>;
|
|
119
|
+
votes: import("superstruct").Struct<{
|
|
120
|
+
slot: number;
|
|
121
|
+
confirmationCount: number;
|
|
122
|
+
}[], import("superstruct").Struct<{
|
|
123
|
+
slot: number;
|
|
124
|
+
confirmationCount: number;
|
|
125
|
+
}, {
|
|
126
|
+
slot: import("superstruct").Struct<number, null>;
|
|
127
|
+
confirmationCount: import("superstruct").Struct<number, null>;
|
|
128
|
+
}>>;
|
|
129
|
+
}>;
|
|
130
|
+
export type VoteAccount = Infer<typeof VoteAccount>;
|
|
131
|
+
export declare const VoteAccount: import("superstruct").Struct<{
|
|
132
|
+
type: "vote";
|
|
133
|
+
info: {
|
|
134
|
+
commission: number;
|
|
135
|
+
authorizedVoters: {
|
|
136
|
+
epoch: number;
|
|
137
|
+
authorizedVoter: import("@solana/web3.js").PublicKey;
|
|
138
|
+
}[];
|
|
139
|
+
authorizedWithdrawer: import("@solana/web3.js").PublicKey;
|
|
140
|
+
epochCredits: {
|
|
141
|
+
epoch: number;
|
|
142
|
+
credits: string;
|
|
143
|
+
previousCredits: string;
|
|
144
|
+
}[];
|
|
145
|
+
lastTimestamp: {
|
|
146
|
+
slot: number;
|
|
147
|
+
timestamp: number;
|
|
148
|
+
};
|
|
149
|
+
nodePubkey: import("@solana/web3.js").PublicKey;
|
|
150
|
+
priorVoters: {
|
|
151
|
+
authorizedPubkey: import("@solana/web3.js").PublicKey;
|
|
152
|
+
epochOfLastAuthorizedSwitch: number;
|
|
153
|
+
targetEpoch: number;
|
|
154
|
+
}[];
|
|
155
|
+
rootSlot: number | null;
|
|
156
|
+
votes: {
|
|
157
|
+
slot: number;
|
|
158
|
+
confirmationCount: number;
|
|
159
|
+
}[];
|
|
160
|
+
};
|
|
161
|
+
}, {
|
|
162
|
+
type: import("superstruct").Struct<"vote", {
|
|
163
|
+
vote: "vote";
|
|
164
|
+
}>;
|
|
165
|
+
info: import("superstruct").Struct<{
|
|
166
|
+
commission: number;
|
|
167
|
+
authorizedVoters: {
|
|
168
|
+
epoch: number;
|
|
169
|
+
authorizedVoter: import("@solana/web3.js").PublicKey;
|
|
170
|
+
}[];
|
|
171
|
+
authorizedWithdrawer: import("@solana/web3.js").PublicKey;
|
|
172
|
+
epochCredits: {
|
|
173
|
+
epoch: number;
|
|
174
|
+
credits: string;
|
|
175
|
+
previousCredits: string;
|
|
176
|
+
}[];
|
|
177
|
+
lastTimestamp: {
|
|
178
|
+
slot: number;
|
|
179
|
+
timestamp: number;
|
|
180
|
+
};
|
|
181
|
+
nodePubkey: import("@solana/web3.js").PublicKey;
|
|
182
|
+
priorVoters: {
|
|
183
|
+
authorizedPubkey: import("@solana/web3.js").PublicKey;
|
|
184
|
+
epochOfLastAuthorizedSwitch: number;
|
|
185
|
+
targetEpoch: number;
|
|
186
|
+
}[];
|
|
187
|
+
rootSlot: number | null;
|
|
188
|
+
votes: {
|
|
189
|
+
slot: number;
|
|
190
|
+
confirmationCount: number;
|
|
191
|
+
}[];
|
|
192
|
+
}, {
|
|
193
|
+
authorizedVoters: import("superstruct").Struct<{
|
|
194
|
+
epoch: number;
|
|
195
|
+
authorizedVoter: import("@solana/web3.js").PublicKey;
|
|
196
|
+
}[], import("superstruct").Struct<{
|
|
197
|
+
epoch: number;
|
|
198
|
+
authorizedVoter: import("@solana/web3.js").PublicKey;
|
|
199
|
+
}, {
|
|
200
|
+
authorizedVoter: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
201
|
+
epoch: import("superstruct").Struct<number, null>;
|
|
202
|
+
}>>;
|
|
203
|
+
authorizedWithdrawer: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
204
|
+
commission: import("superstruct").Struct<number, null>;
|
|
205
|
+
epochCredits: import("superstruct").Struct<{
|
|
206
|
+
epoch: number;
|
|
207
|
+
credits: string;
|
|
208
|
+
previousCredits: string;
|
|
209
|
+
}[], import("superstruct").Struct<{
|
|
210
|
+
epoch: number;
|
|
211
|
+
credits: string;
|
|
212
|
+
previousCredits: string;
|
|
213
|
+
}, {
|
|
214
|
+
epoch: import("superstruct").Struct<number, null>;
|
|
215
|
+
credits: import("superstruct").Struct<string, null>;
|
|
216
|
+
previousCredits: import("superstruct").Struct<string, null>;
|
|
217
|
+
}>>;
|
|
218
|
+
lastTimestamp: import("superstruct").Struct<{
|
|
219
|
+
slot: number;
|
|
220
|
+
timestamp: number;
|
|
221
|
+
}, {
|
|
222
|
+
slot: import("superstruct").Struct<number, null>;
|
|
223
|
+
timestamp: import("superstruct").Struct<number, null>;
|
|
224
|
+
}>;
|
|
225
|
+
nodePubkey: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
226
|
+
priorVoters: import("superstruct").Struct<{
|
|
227
|
+
authorizedPubkey: import("@solana/web3.js").PublicKey;
|
|
228
|
+
epochOfLastAuthorizedSwitch: number;
|
|
229
|
+
targetEpoch: number;
|
|
230
|
+
}[], import("superstruct").Struct<{
|
|
231
|
+
authorizedPubkey: import("@solana/web3.js").PublicKey;
|
|
232
|
+
epochOfLastAuthorizedSwitch: number;
|
|
233
|
+
targetEpoch: number;
|
|
234
|
+
}, {
|
|
235
|
+
authorizedPubkey: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
236
|
+
epochOfLastAuthorizedSwitch: import("superstruct").Struct<number, null>;
|
|
237
|
+
targetEpoch: import("superstruct").Struct<number, null>;
|
|
238
|
+
}>>;
|
|
239
|
+
rootSlot: import("superstruct").Struct<number | null, null>;
|
|
240
|
+
votes: import("superstruct").Struct<{
|
|
241
|
+
slot: number;
|
|
242
|
+
confirmationCount: number;
|
|
243
|
+
}[], import("superstruct").Struct<{
|
|
244
|
+
slot: number;
|
|
245
|
+
confirmationCount: number;
|
|
246
|
+
}, {
|
|
247
|
+
slot: import("superstruct").Struct<number, null>;
|
|
248
|
+
confirmationCount: import("superstruct").Struct<number, null>;
|
|
249
|
+
}>>;
|
|
250
|
+
}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-0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable @typescript-eslint/no-redeclare */
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.VoteAccount = exports.VoteAccountInfo = exports.Vote = exports.EpochCredits = exports.PriorVoter = exports.AuthorizedVoter = exports.VoteAccountType = void 0;
|
|
5
|
+
const superstruct_1 = require("superstruct");
|
|
6
|
+
const pubkey_1 = require("../validators/pubkey");
|
|
7
|
+
exports.VoteAccountType = (0, superstruct_1.enums)(["vote"]);
|
|
8
|
+
exports.AuthorizedVoter = (0, superstruct_1.type)({
|
|
9
|
+
authorizedVoter: pubkey_1.PublicKeyFromString,
|
|
10
|
+
epoch: (0, superstruct_1.number)(),
|
|
11
|
+
});
|
|
12
|
+
exports.PriorVoter = (0, superstruct_1.type)({
|
|
13
|
+
authorizedPubkey: pubkey_1.PublicKeyFromString,
|
|
14
|
+
epochOfLastAuthorizedSwitch: (0, superstruct_1.number)(),
|
|
15
|
+
targetEpoch: (0, superstruct_1.number)(),
|
|
16
|
+
});
|
|
17
|
+
exports.EpochCredits = (0, superstruct_1.type)({
|
|
18
|
+
epoch: (0, superstruct_1.number)(),
|
|
19
|
+
credits: (0, superstruct_1.string)(),
|
|
20
|
+
previousCredits: (0, superstruct_1.string)(),
|
|
21
|
+
});
|
|
22
|
+
exports.Vote = (0, superstruct_1.type)({
|
|
23
|
+
slot: (0, superstruct_1.number)(),
|
|
24
|
+
confirmationCount: (0, superstruct_1.number)(),
|
|
25
|
+
});
|
|
26
|
+
exports.VoteAccountInfo = (0, superstruct_1.type)({
|
|
27
|
+
authorizedVoters: (0, superstruct_1.array)(exports.AuthorizedVoter),
|
|
28
|
+
authorizedWithdrawer: pubkey_1.PublicKeyFromString,
|
|
29
|
+
commission: (0, superstruct_1.number)(),
|
|
30
|
+
epochCredits: (0, superstruct_1.array)(exports.EpochCredits),
|
|
31
|
+
lastTimestamp: (0, superstruct_1.type)({
|
|
32
|
+
slot: (0, superstruct_1.number)(),
|
|
33
|
+
timestamp: (0, superstruct_1.number)(),
|
|
34
|
+
}),
|
|
35
|
+
nodePubkey: pubkey_1.PublicKeyFromString,
|
|
36
|
+
priorVoters: (0, superstruct_1.array)(exports.PriorVoter),
|
|
37
|
+
rootSlot: (0, superstruct_1.nullable)((0, superstruct_1.number)()),
|
|
38
|
+
votes: (0, superstruct_1.array)(exports.Vote),
|
|
39
|
+
});
|
|
40
|
+
exports.VoteAccount = (0, superstruct_1.type)({
|
|
41
|
+
type: exports.VoteAccountType,
|
|
42
|
+
info: exports.VoteAccountInfo,
|
|
43
|
+
});
|
|
44
|
+
//# sourceMappingURL=vote.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"vote.js","sourceRoot":"","sources":["../../../../src/api/chain/account/vote.ts"],"names":[],"mappings":";AAAA,oDAAoD;;;AAEpD,6CAAkF;AAClF,iDAA2D;AAG9C,QAAA,eAAe,GAAG,IAAA,mBAAK,EAAC,CAAC,MAAM,CAAC,CAAC,CAAC;AAGlC,QAAA,eAAe,GAAG,IAAA,kBAAI,EAAC;IAClC,eAAe,EAAE,4BAAmB;IACpC,KAAK,EAAE,IAAA,oBAAM,GAAE;CAChB,CAAC,CAAC;AAGU,QAAA,UAAU,GAAG,IAAA,kBAAI,EAAC;IAC7B,gBAAgB,EAAE,4BAAmB;IACrC,2BAA2B,EAAE,IAAA,oBAAM,GAAE;IACrC,WAAW,EAAE,IAAA,oBAAM,GAAE;CACtB,CAAC,CAAC;AAGU,QAAA,YAAY,GAAG,IAAA,kBAAI,EAAC;IAC/B,KAAK,EAAE,IAAA,oBAAM,GAAE;IACf,OAAO,EAAE,IAAA,oBAAM,GAAE;IACjB,eAAe,EAAE,IAAA,oBAAM,GAAE;CAC1B,CAAC,CAAC;AAGU,QAAA,IAAI,GAAG,IAAA,kBAAI,EAAC;IACvB,IAAI,EAAE,IAAA,oBAAM,GAAE;IACd,iBAAiB,EAAE,IAAA,oBAAM,GAAE;CAC5B,CAAC,CAAC;AAGU,QAAA,eAAe,GAAG,IAAA,kBAAI,EAAC;IAClC,gBAAgB,EAAE,IAAA,mBAAK,EAAC,uBAAe,CAAC;IACxC,oBAAoB,EAAE,4BAAmB;IACzC,UAAU,EAAE,IAAA,oBAAM,GAAE;IACpB,YAAY,EAAE,IAAA,mBAAK,EAAC,oBAAY,CAAC;IACjC,aAAa,EAAE,IAAA,kBAAI,EAAC;QAClB,IAAI,EAAE,IAAA,oBAAM,GAAE;QACd,SAAS,EAAE,IAAA,oBAAM,GAAE;KACpB,CAAC;IACF,UAAU,EAAE,4BAAmB;IAC/B,WAAW,EAAE,IAAA,mBAAK,EAAC,kBAAU,CAAC;IAC9B,QAAQ,EAAE,IAAA,sBAAQ,EAAC,IAAA,oBAAM,GAAE,CAAC;IAC5B,KAAK,EAAE,IAAA,mBAAK,EAAC,YAAI,CAAC;CACnB,CAAC,CAAC;AAGU,QAAA,WAAW,GAAG,IAAA,kBAAI,EAAC;IAC9B,IAAI,EAAE,uBAAe;IACrB,IAAI,EAAE,uBAAe;CACtB,CAAC,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Connection, VersionedMessage, SignaturesForAddressOptions } from "@solana/web3.js";
|
|
2
|
+
import { Awaited } from "../../logic";
|
|
3
|
+
export declare const LATEST_BLOCKHASH_MOCK = "EEbZs6DmDyDjucyYbo3LwVJU7pQYuVopYcYTSEZXskW3";
|
|
4
|
+
export type Config = {
|
|
5
|
+
readonly endpoint: string;
|
|
6
|
+
};
|
|
7
|
+
export type ChainAPI = Readonly<{
|
|
8
|
+
getBalance: (address: string) => Promise<number>;
|
|
9
|
+
getLatestBlockhash: () => Promise<string>;
|
|
10
|
+
getFeeForMessage: (message: VersionedMessage) => Promise<number | null>;
|
|
11
|
+
getBalanceAndContext: (address: string) => ReturnType<Connection["getBalanceAndContext"]>;
|
|
12
|
+
getParsedTokenAccountsByOwner: (address: string) => ReturnType<Connection["getParsedTokenAccountsByOwner"]>;
|
|
13
|
+
getStakeAccountsByStakeAuth: (authAddr: string) => ReturnType<Connection["getParsedProgramAccounts"]>;
|
|
14
|
+
getStakeAccountsByWithdrawAuth: (authAddr: string) => ReturnType<Connection["getParsedProgramAccounts"]>;
|
|
15
|
+
getStakeActivation: (stakeAccAddr: string) => ReturnType<Connection["getStakeActivation"]>;
|
|
16
|
+
getInflationReward: (addresses: string[]) => ReturnType<Connection["getInflationReward"]>;
|
|
17
|
+
getVoteAccounts: () => ReturnType<Connection["getVoteAccounts"]>;
|
|
18
|
+
getSignaturesForAddress: (address: string, opts?: SignaturesForAddressOptions) => ReturnType<Connection["getSignaturesForAddress"]>;
|
|
19
|
+
getParsedTransactions: (signatures: string[]) => ReturnType<Connection["getParsedTransactions"]>;
|
|
20
|
+
getAccountInfo: (address: string) => Promise<Awaited<ReturnType<Connection["getParsedAccountInfo"]>>["value"]>;
|
|
21
|
+
sendRawTransaction: (buffer: Buffer) => ReturnType<Connection["sendRawTransaction"]>;
|
|
22
|
+
findAssocTokenAccAddress: (owner: string, mint: string) => Promise<string>;
|
|
23
|
+
getAssocTokenAccMinNativeBalance: () => Promise<number>;
|
|
24
|
+
getMinimumBalanceForRentExemption: (dataLength: number) => Promise<number>;
|
|
25
|
+
getEpochInfo: () => ReturnType<Connection["getEpochInfo"]>;
|
|
26
|
+
config: Config;
|
|
27
|
+
}>;
|
|
28
|
+
export declare function getChainAPI(config: Config, logger?: (url: string, options: any) => void): ChainAPI;
|
|
29
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/api/chain/index.ts"],"names":[],"mappings":"AAKA,OAAO,EACL,UAAU,EAEV,gBAAgB,EAGhB,2BAA2B,EAE5B,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAGtC,eAAO,MAAM,qBAAqB,iDAAiD,CA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U,EAAE,MAAM,EAAE,KAAK,UAAU,CAAC,UAAU,CAAC,uBAAuB,CAAC,CAAC,CAAC;IAEjG,cAAc,EAAE,CACd,OAAO,EAAE,MAAM,KACZ,OAAO,CAAC,OAAO,CAAC,UAAU,CAAC,UAAU,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC;IAE/E,kBAAkB,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,UAAU,CAAC,UAAU,CAAC,oBAAoB,CAAC,CAAC,CAAC;IAErF,wBAAwB,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,MAAM,CAAC,CAAC;IAE3E,gCAAgC,EAAE,MAAM,OAAO,CAAC,MAAM,CAAC,CAAC;IAExD,iCAAiC,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,OAAO,CAAC,MAAM,CAAC,CAAC;IAE3E,YAAY,EAAE,MAAM,UAAU,CAAC,UAAU,CAAC,cAAc,CAAC,CAAC,CAAC;IAE3D,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC,CAAC;AAOH,wBAAgB,WAAW,CACzB,MAAM,EAAE,MAAM,EACd,MAAM,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE,GAAG,KAAK,IAAI,GAC3C,QAAQ,CAuHV"}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getChainAPI = exports.LATEST_BLOCKHASH_MOCK = void 0;
|
|
4
|
+
const spl_token_1 = require("@solana/spl-token");
|
|
5
|
+
const web3_js_1 = require("@solana/web3.js");
|
|
6
|
+
const live_env_1 = require("@ledgerhq/live-env");
|
|
7
|
+
const errors_1 = require("@ledgerhq/errors");
|
|
8
|
+
exports.LATEST_BLOCKHASH_MOCK = "EEbZs6DmDyDjucyYbo3LwVJU7pQYuVopYcYTSEZXskW3";
|
|
9
|
+
// Naive mode, allow us to filter in sentry all this error comming from Sol RPC node
|
|
10
|
+
const remapErrors = (e) => {
|
|
11
|
+
throw new errors_1.NetworkError(e === null || e === void 0 ? void 0 : e.message);
|
|
12
|
+
};
|
|
13
|
+
function getChainAPI(config, logger) {
|
|
14
|
+
const fetchMiddleware = logger === undefined
|
|
15
|
+
? undefined
|
|
16
|
+
: (url, options, fetch) => {
|
|
17
|
+
logger(url, options);
|
|
18
|
+
fetch(url, options);
|
|
19
|
+
};
|
|
20
|
+
const connection = () => {
|
|
21
|
+
return new web3_js_1.Connection(config.endpoint, {
|
|
22
|
+
commitment: "finalized",
|
|
23
|
+
fetchMiddleware,
|
|
24
|
+
confirmTransactionInitialTimeout: (0, live_env_1.getEnv)("SOLANA_TX_CONFIRMATION_TIMEOUT"),
|
|
25
|
+
});
|
|
26
|
+
};
|
|
27
|
+
return {
|
|
28
|
+
getBalance: (address) => connection().getBalance(new web3_js_1.PublicKey(address)).catch(remapErrors),
|
|
29
|
+
getLatestBlockhash: () => connection()
|
|
30
|
+
.getLatestBlockhash()
|
|
31
|
+
.then(r => r.blockhash)
|
|
32
|
+
.catch(remapErrors),
|
|
33
|
+
getFeeForMessage: (msg) => connection()
|
|
34
|
+
.getFeeForMessage(msg)
|
|
35
|
+
.then(r => r.value)
|
|
36
|
+
.catch(remapErrors),
|
|
37
|
+
getBalanceAndContext: (address) => connection().getBalanceAndContext(new web3_js_1.PublicKey(address)).catch(remapErrors),
|
|
38
|
+
getParsedTokenAccountsByOwner: (address) => connection()
|
|
39
|
+
.getParsedTokenAccountsByOwner(new web3_js_1.PublicKey(address), {
|
|
40
|
+
programId: spl_token_1.TOKEN_PROGRAM_ID,
|
|
41
|
+
})
|
|
42
|
+
.catch(remapErrors),
|
|
43
|
+
getStakeAccountsByStakeAuth: (authAddr) => connection()
|
|
44
|
+
.getParsedProgramAccounts(web3_js_1.StakeProgram.programId, {
|
|
45
|
+
filters: [
|
|
46
|
+
{
|
|
47
|
+
memcmp: {
|
|
48
|
+
offset: 12,
|
|
49
|
+
bytes: authAddr,
|
|
50
|
+
},
|
|
51
|
+
},
|
|
52
|
+
],
|
|
53
|
+
})
|
|
54
|
+
.catch(remapErrors),
|
|
55
|
+
getStakeAccountsByWithdrawAuth: (authAddr) => connection()
|
|
56
|
+
.getParsedProgramAccounts(web3_js_1.StakeProgram.programId, {
|
|
57
|
+
filters: [
|
|
58
|
+
{
|
|
59
|
+
memcmp: {
|
|
60
|
+
offset: 44,
|
|
61
|
+
bytes: authAddr,
|
|
62
|
+
},
|
|
63
|
+
},
|
|
64
|
+
],
|
|
65
|
+
})
|
|
66
|
+
.catch(remapErrors),
|
|
67
|
+
getStakeActivation: (stakeAccAddr) => connection().getStakeActivation(new web3_js_1.PublicKey(stakeAccAddr)).catch(remapErrors),
|
|
68
|
+
getInflationReward: (addresses) => connection()
|
|
69
|
+
.getInflationReward(addresses.map(addr => new web3_js_1.PublicKey(addr)))
|
|
70
|
+
.catch(remapErrors),
|
|
71
|
+
getVoteAccounts: () => connection().getVoteAccounts().catch(remapErrors),
|
|
72
|
+
getSignaturesForAddress: (address, opts) => connection().getSignaturesForAddress(new web3_js_1.PublicKey(address), opts).catch(remapErrors),
|
|
73
|
+
getParsedTransactions: (signatures) => connection()
|
|
74
|
+
.getParsedTransactions(signatures, {
|
|
75
|
+
maxSupportedTransactionVersion: 0,
|
|
76
|
+
})
|
|
77
|
+
.catch(remapErrors),
|
|
78
|
+
getAccountInfo: (address) => connection()
|
|
79
|
+
.getParsedAccountInfo(new web3_js_1.PublicKey(address))
|
|
80
|
+
.then(r => r.value)
|
|
81
|
+
.catch(remapErrors),
|
|
82
|
+
sendRawTransaction: (buffer) => {
|
|
83
|
+
return (0, web3_js_1.sendAndConfirmRawTransaction)(connection(), buffer, {
|
|
84
|
+
commitment: "confirmed",
|
|
85
|
+
}).catch(remapErrors);
|
|
86
|
+
},
|
|
87
|
+
findAssocTokenAccAddress: (owner, mint) => {
|
|
88
|
+
return (0, spl_token_1.getAssociatedTokenAddress)(new web3_js_1.PublicKey(mint), new web3_js_1.PublicKey(owner))
|
|
89
|
+
.then(r => r.toBase58())
|
|
90
|
+
.catch(remapErrors);
|
|
91
|
+
},
|
|
92
|
+
getAssocTokenAccMinNativeBalance: () => (0, spl_token_1.getMinimumBalanceForRentExemptAccount)(connection()).catch(remapErrors),
|
|
93
|
+
getMinimumBalanceForRentExemption: (dataLength) => connection().getMinimumBalanceForRentExemption(dataLength).catch(remapErrors),
|
|
94
|
+
getEpochInfo: () => connection().getEpochInfo().catch(remapErrors),
|
|
95
|
+
config,
|
|
96
|
+
};
|
|
97
|
+
}
|
|
98
|
+
exports.getChainAPI = getChainAPI;
|
|
99
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/api/chain/index.ts"],"names":[],"mappings":";;;AAAA,iDAI2B;AAC3B,6CAQyB;AACzB,iDAA4C;AAE5C,6CAAgD;AAEnC,QAAA,qBAAqB,GAAG,8CAA8C,CAAC;AAyDpF,oFAAoF;AACpF,MAAM,WAAW,GAAG,CAAC,CAAQ,EAAE,EAAE;IAC/B,MAAM,IAAI,qBAAY,CAAC,CAAC,aAAD,CAAC,uBAAD,CAAC,CAAE,OAAO,CAAC,CAAC;AACrC,CAAC,CAAC;AAEF,SAAgB,WAAW,CACzB,MAAc,EACd,MAA4C;IAE5C,MAAM,eAAe,GACnB,MAAM,KAAK,SAAS;QAClB,CAAC,CAAC,SAAS;QACX,CAAC,CAAC,CAAC,GAAG,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE;YACtB,MAAM,CAAC,GAAG,EAAE,OAAO,CAAC,CAAC;YACrB,KAAK,CAAC,GAAG,EAAE,OAAO,CAAC,CAAC;QACtB,CAAC,CAAC;IAER,MAAM,UAAU,GAAG,GAAG,EAAE;QACtB,OAAO,IAAI,oBAAU,CAAC,MAAM,CAAC,QAAQ,EAAE;YACrC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,CAAC,KAAK,CAAC;aAClB,KAAK,CAAC,WAAW,CAAC;QAEvB,kBAAkB,EAAE,CAAC,MAAc,EAAE,EAAE;YACrC,OAAO,IAAA,sCAA4B,EAAC,UAAU,EAAE,EAAE,MAAM,EAAE;gBACxD,UAAU,EAAE,WAAW;aACxB,CAAC,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC;QACxB,CAAC;QAED,wBAAwB,EAAE,CAAC,KAAa,EAAE,IAAY,EAAE,EAAE;YACxD,OAAO,IAAA,qCAAyB,EAAC,IAAI,mBAAS,CAAC,IAAI,CAAC,EAAE,IAAI,mBAAS,CAAC,KAAK,CAAC,CAAC;iBACxE,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC;iBACvB,KAAK,CAAC,WAAW,CAAC,CAAC;QACxB,CAAC;QAED,gCAAgC,EAAE,GAAG,EAAE,CACrC,IAAA,iDAAqC,EAAC,UAAU,EAAE,CAAC,CAAC,KAAK,CAAC,WAAW,CAAC;QAExE,iCAAiC,EAAE,CAAC,UAAkB,EAAE,EAAE,CACxD,UAAU,EAAE,CAAC,iCAAiC,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,WAAW,CAAC;QAE/E,YAAY,EAAE,GAAG,EAAE,CAAC,UAAU,EAAE,CAAC,YAAY,EAAE,CAAC,KAAK,CAAC,WAAW,CAAC;QAElE,MAAM;KACP,CAAC;AACJ,CAAC;AA1HD,kCA0HC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { Infer } from "superstruct";
|
|
2
|
+
import { ParsedInstruction } from "@solana/web3.js";
|
|
3
|
+
import { AssociatedTokenAccountInstructionType, IX_STRUCTS, IX_TITLES } from "./types";
|
|
4
|
+
import { PARSED_PROGRAMS } from "../../program/constants";
|
|
5
|
+
export declare function parseAssociatedTokenAccountInstruction(ix: ParsedInstruction & {
|
|
6
|
+
program: typeof PARSED_PROGRAMS.SPL_ASSOCIATED_TOKEN_ACCOUNT;
|
|
7
|
+
}): AssociatedTokenAccountInstructionDescriptor;
|
|
8
|
+
export type AssociatedTokenAccountInstructionDescriptor = {
|
|
9
|
+
[K in AssociatedTokenAccountInstructionType]: {
|
|
10
|
+
title: (typeof IX_TITLES)[K];
|
|
11
|
+
type: K;
|
|
12
|
+
info: Infer<(typeof IX_STRUCTS)[K]>;
|
|
13
|
+
};
|
|
14
|
+
}[AssociatedTokenAccountInstructionType];
|
|
15
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/api/chain/instruction/associated-token-account/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAU,KAAK,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,qCAAqC,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAEvF,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAE1D,wBAAgB,sCAAsC,CACpD,EAAE,EAAE,iBAAiB,GAAG;IACtB,OAAO,EAAE,OAAO,eAAe,CAAC,4BAA4B,CAAC;CAC9D,GACA,2CAA2C,CAa7C;AAED,MAAM,MAAM,2CAA2C,GAAG;KACvD,CAAC,IAAI,qCAAqC,GAAG;QAC5C,KAAK,EAAE,CAAC,OAAO,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;QAC7B,IAAI,EAAE,CAAC,CAAC;QACR,IAAI,EAAE,KAAK,CAAC,CAAC,OAAO,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;KACrC;CACF,CAAC,qCAAqC,CAAC,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.parseAssociatedTokenAccountInstruction = void 0;
|
|
4
|
+
const validators_1 = require("../../validators");
|
|
5
|
+
const superstruct_1 = require("superstruct");
|
|
6
|
+
const types_1 = require("./types");
|
|
7
|
+
function parseAssociatedTokenAccountInstruction(ix) {
|
|
8
|
+
// TODO: check this
|
|
9
|
+
const parsed = (0, superstruct_1.create)(ix.parsed, validators_1.ParsedInfo);
|
|
10
|
+
//const { type: rawType, info } = parsed;
|
|
11
|
+
const type = "associate";
|
|
12
|
+
const title = types_1.IX_TITLES[type];
|
|
13
|
+
const struct = types_1.IX_STRUCTS[type];
|
|
14
|
+
return {
|
|
15
|
+
type: "associate",
|
|
16
|
+
title: title,
|
|
17
|
+
info: (0, superstruct_1.create)(parsed.info, struct),
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
exports.parseAssociatedTokenAccountInstruction = parseAssociatedTokenAccountInstruction;
|
|
21
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/api/chain/instruction/associated-token-account/index.ts"],"names":[],"mappings":";;;AAAA,iDAA8C;AAC9C,6CAA4C;AAE5C,mCAAuF;AAIvF,SAAgB,sCAAsC,CACpD,EAEC;IAED,mBAAmB;IACnB,MAAM,MAAM,GAAG,IAAA,oBAAM,EAAC,EAAE,CAAC,MAAM,EAAE,uBAAU,CAAC,CAAC;IAC7C,yCAAyC;IACzC,MAAM,IAAI,GAA0C,WAAW,CAAC;IAChE,MAAM,KAAK,GAAG,iBAAS,CAAC,IAAI,CAAC,CAAC;IAC9B,MAAM,MAAM,GAAG,kBAAU,CAAC,IAAI,CAAC,CAAC;IAEhC,OAAO;QACL,IAAI,EAAE,WAAW;QACjB,KAAK,EAAE,KAAK;QACZ,IAAI,EAAE,IAAA,oBAAM,EAAC,MAAM,CAAC,IAAI,EAAE,MAAa,CAAQ;KAChD,CAAC;AACJ,CAAC;AAjBD,wFAiBC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/// <reference types="@solana/web3.js" />
|
|
2
|
+
import { Infer } from "superstruct";
|
|
3
|
+
export declare const AssociateInfo: import("superstruct").Struct<{
|
|
4
|
+
mint: import("@solana/web3.js").PublicKey;
|
|
5
|
+
account: import("@solana/web3.js").PublicKey;
|
|
6
|
+
wallet: import("@solana/web3.js").PublicKey;
|
|
7
|
+
}, {
|
|
8
|
+
account: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
9
|
+
mint: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
10
|
+
wallet: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
11
|
+
}>;
|
|
12
|
+
export type AssociatedTokenAccountInstructionType = Infer<typeof AssociatedTokenAccountInstructionType>;
|
|
13
|
+
export declare const AssociatedTokenAccountInstructionType: import("superstruct").Struct<"associate", {
|
|
14
|
+
associate: "associate";
|
|
15
|
+
}>;
|
|
16
|
+
export declare const IX_STRUCTS: {
|
|
17
|
+
readonly associate: import("superstruct").Struct<{
|
|
18
|
+
mint: import("@solana/web3.js").PublicKey;
|
|
19
|
+
account: import("@solana/web3.js").PublicKey;
|
|
20
|
+
wallet: import("@solana/web3.js").PublicKey;
|
|
21
|
+
}, {
|
|
22
|
+
account: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
23
|
+
mint: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
24
|
+
wallet: import("superstruct").Struct<import("@solana/web3.js").PublicKey, null>;
|
|
25
|
+
}>;
|
|
26
|
+
};
|
|
27
|
+
export declare const IX_TITLES: {
|
|
28
|
+
readonly associate: "Associate";
|
|
29
|
+
};
|
|
30
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../src/api/chain/instruction/associated-token-account/types.ts"],"names":[],"mappings":";AAAA,OAAO,EAAe,KAAK,EAAE,MAAM,aAAa,CAAC;AAIjD,eAAO,MAAM,aAAa;;;;;;;;EAIxB,CAAC;AAEH,MAAM,MAAM,qCAAqC,GAAG,KAAK,CACvD,OAAO,qCAAqC,CAC7C,CAAC;AAEF,eAAO,MAAM,qCAAqC;;EAAuB,CAAC;AAE1E,eAAO,MAAM,UAAU;;;;;;;;;;CAEb,CAAC;AAEX,eAAO,MAAM,SAAS;;CAEZ,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.IX_TITLES = exports.IX_STRUCTS = exports.AssociatedTokenAccountInstructionType = exports.AssociateInfo = void 0;
|
|
4
|
+
const superstruct_1 = require("superstruct");
|
|
5
|
+
const pubkey_1 = require("../../validators/pubkey");
|
|
6
|
+
exports.AssociateInfo = (0, superstruct_1.type)({
|
|
7
|
+
account: pubkey_1.PublicKeyFromString,
|
|
8
|
+
mint: pubkey_1.PublicKeyFromString,
|
|
9
|
+
wallet: pubkey_1.PublicKeyFromString,
|
|
10
|
+
});
|
|
11
|
+
// not a real instruction type, added for structure
|
|
12
|
+
exports.AssociatedTokenAccountInstructionType = (0, superstruct_1.enums)(["associate"]);
|
|
13
|
+
exports.IX_STRUCTS = {
|
|
14
|
+
associate: exports.AssociateInfo,
|
|
15
|
+
};
|
|
16
|
+
exports.IX_TITLES = {
|
|
17
|
+
associate: "Associate",
|
|
18
|
+
};
|
|
19
|
+
//# sourceMappingURL=types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../../src/api/chain/instruction/associated-token-account/types.ts"],"names":[],"mappings":";;;AAAA,6CAAiD;AACjD,oDAA8D;AAGjD,QAAA,aAAa,GAAG,IAAA,kBAAI,EAAC;IAChC,OAAO,EAAE,4BAAmB;IAC5B,IAAI,EAAE,4BAAmB;IACzB,MAAM,EAAE,4BAAmB;CAC5B,CAAC,CAAC;AAKH,mDAAmD;AACtC,QAAA,qCAAqC,GAAG,IAAA,mBAAK,EAAC,CAAC,WAAW,CAAC,CAAC,CAAC;AAE7D,QAAA,UAAU,GAAG;IACxB,SAAS,EAAE,qBAAa;CAChB,CAAC;AAEE,QAAA,SAAS,GAAG;IACvB,SAAS,EAAE,WAAW;CACd,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ParsedInstruction } from "@solana/web3.js";
|
|
2
|
+
import { IX_STRUCTS, IX_TITLES, MemoInstructionType } from "./types";
|
|
3
|
+
import { Infer } from "superstruct";
|
|
4
|
+
import { PARSED_PROGRAMS } from "../../program/constants";
|
|
5
|
+
export declare function parseSplMemoInstruction(ix: ParsedInstruction & {
|
|
6
|
+
program: typeof PARSED_PROGRAMS.SPL_MEMO;
|
|
7
|
+
}): MemoInstructionDescriptor;
|
|
8
|
+
export type MemoInstructionDescriptor = {
|
|
9
|
+
[K in MemoInstructionType]: {
|
|
10
|
+
title: (typeof IX_TITLES)[K];
|
|
11
|
+
type: K;
|
|
12
|
+
info: Infer<(typeof IX_STRUCTS)[K]>;
|
|
13
|
+
};
|
|
14
|
+
}[MemoInstructionType];
|
|
15
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/api/chain/instruction/memo/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AACrE,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AACpC,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAE1D,wBAAgB,uBAAuB,CACrC,EAAE,EAAE,iBAAiB,GAAG;IAAE,OAAO,EAAE,OAAO,eAAe,CAAC,QAAQ,CAAA;CAAE,GACnE,yBAAyB,CAQ3B;AAED,MAAM,MAAM,yBAAyB,GAAG;KACrC,CAAC,IAAI,mBAAmB,GAAG;QAC1B,KAAK,EAAE,CAAC,OAAO,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;QAC7B,IAAI,EAAE,CAAC,CAAC;QACR,IAAI,EAAE,KAAK,CAAC,CAAC,OAAO,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;KACrC;CACF,CAAC,mBAAmB,CAAC,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.parseSplMemoInstruction = void 0;
|
|
4
|
+
function parseSplMemoInstruction(ix) {
|
|
5
|
+
return {
|
|
6
|
+
title: "Save",
|
|
7
|
+
type: "save",
|
|
8
|
+
info: {
|
|
9
|
+
data: ix.parsed,
|
|
10
|
+
},
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
exports.parseSplMemoInstruction = parseSplMemoInstruction;
|
|
14
|
+
//# sourceMappingURL=index.js.map
|