@aptos-labs/ts-sdk 6.3.1 → 7.0.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 +125 -24
- package/dist/account/AbstractKeylessAccount.d.ts +326 -0
- package/dist/account/AbstractKeylessAccount.d.ts.map +1 -0
- package/dist/account/AbstractKeylessAccount.js +440 -0
- package/dist/account/AbstractKeylessAccount.js.map +1 -0
- package/dist/account/AbstractedAccount.d.ts +61 -0
- package/dist/account/AbstractedAccount.d.ts.map +1 -0
- package/dist/account/AbstractedAccount.js +71 -0
- package/dist/account/AbstractedAccount.js.map +1 -0
- package/dist/account/Account.d.ts +302 -0
- package/dist/account/Account.d.ts.map +1 -0
- package/dist/account/Account.js +104 -0
- package/dist/account/Account.js.map +1 -0
- package/dist/account/AccountUtils.d.ts +25 -0
- package/dist/account/AccountUtils.d.ts.map +1 -0
- package/dist/account/AccountUtils.js +202 -0
- package/dist/account/AccountUtils.js.map +1 -0
- package/dist/account/DerivableAbstractedAccount.d.ts +51 -0
- package/dist/account/DerivableAbstractedAccount.d.ts.map +1 -0
- package/dist/account/DerivableAbstractedAccount.js +61 -0
- package/dist/account/DerivableAbstractedAccount.js.map +1 -0
- package/dist/account/Ed25519Account.d.ts +161 -0
- package/dist/account/Ed25519Account.d.ts.map +1 -0
- package/dist/account/Ed25519Account.js +149 -0
- package/dist/account/Ed25519Account.js.map +1 -0
- package/dist/account/EphemeralKeyPair.d.ts +159 -0
- package/dist/account/EphemeralKeyPair.d.ts.map +1 -0
- package/dist/account/EphemeralKeyPair.js +246 -0
- package/dist/account/EphemeralKeyPair.js.map +1 -0
- package/dist/account/FederatedKeylessAccount.d.ts +107 -0
- package/dist/account/FederatedKeylessAccount.d.ts.map +1 -0
- package/dist/account/FederatedKeylessAccount.js +129 -0
- package/dist/account/FederatedKeylessAccount.js.map +1 -0
- package/dist/account/KeylessAccount.d.ts +112 -0
- package/dist/account/KeylessAccount.d.ts.map +1 -0
- package/dist/account/KeylessAccount.js +133 -0
- package/dist/account/KeylessAccount.js.map +1 -0
- package/dist/account/MultiEd25519Account.d.ts +100 -0
- package/dist/account/MultiEd25519Account.d.ts.map +1 -0
- package/dist/account/MultiEd25519Account.js +134 -0
- package/dist/account/MultiEd25519Account.js.map +1 -0
- package/dist/account/MultiKeyAccount.d.ts +197 -0
- package/dist/account/MultiKeyAccount.d.ts.map +1 -0
- package/dist/account/MultiKeyAccount.js +233 -0
- package/dist/account/MultiKeyAccount.js.map +1 -0
- package/dist/account/SingleKeyAccount.d.ts +189 -0
- package/dist/account/SingleKeyAccount.d.ts.map +1 -0
- package/dist/account/SingleKeyAccount.js +182 -0
- package/dist/account/SingleKeyAccount.js.map +1 -0
- package/dist/account/index.d.ts +9 -0
- package/dist/account/index.d.ts.map +1 -0
- package/dist/account/index.js +17 -0
- package/dist/account/index.js.map +1 -0
- package/dist/account/keylessSigner.d.ts +22 -0
- package/dist/account/keylessSigner.d.ts.map +1 -0
- package/dist/account/keylessSigner.js +9 -0
- package/dist/account/keylessSigner.js.map +1 -0
- package/dist/account/utils.d.ts +8 -0
- package/dist/account/utils.d.ts.map +1 -0
- package/dist/account/utils.js +12 -0
- package/dist/account/utils.js.map +1 -0
- package/dist/api/account/abstraction.d.ts +176 -0
- package/dist/api/account/abstraction.d.ts.map +1 -0
- package/dist/api/account/abstraction.js +203 -0
- package/dist/api/account/abstraction.js.map +1 -0
- package/dist/api/account.d.ts +845 -0
- package/dist/api/account.d.ts.map +1 -0
- package/dist/api/account.js +965 -0
- package/dist/api/account.js.map +1 -0
- package/dist/api/ans.d.ts +565 -0
- package/dist/api/ans.d.ts.map +1 -0
- package/dist/api/ans.js +537 -0
- package/dist/api/ans.js.map +1 -0
- package/dist/api/aptos.d.ts +73 -0
- package/dist/api/aptos.d.ts.map +1 -0
- package/dist/api/aptos.js +162 -0
- package/dist/api/aptos.js.map +1 -0
- package/dist/api/aptosConfig.d.ts +215 -0
- package/dist/api/aptosConfig.d.ts.map +1 -0
- package/dist/api/aptosConfig.js +316 -0
- package/dist/api/aptosConfig.js.map +1 -0
- package/dist/api/coin.d.ts +77 -0
- package/dist/api/coin.d.ts.map +1 -0
- package/dist/api/coin.js +73 -0
- package/dist/api/coin.js.map +1 -0
- package/dist/api/digitalAsset.d.ts +1026 -0
- package/dist/api/digitalAsset.d.ts.map +1 -0
- package/dist/api/digitalAsset.js +987 -0
- package/dist/api/digitalAsset.js.map +1 -0
- package/dist/api/faucet.d.ts +74 -0
- package/dist/api/faucet.d.ts.map +1 -0
- package/dist/api/faucet.js +86 -0
- package/dist/api/faucet.js.map +1 -0
- package/dist/api/fungibleAsset.d.ts +285 -0
- package/dist/api/fungibleAsset.d.ts.map +1 -0
- package/dist/api/fungibleAsset.js +314 -0
- package/dist/api/fungibleAsset.js.map +1 -0
- package/dist/api/general.d.ts +298 -0
- package/dist/api/general.d.ts.map +1 -0
- package/dist/api/general.js +311 -0
- package/dist/api/general.js.map +1 -0
- package/dist/api/index.d.ts +3 -0
- package/dist/api/index.d.ts.map +1 -0
- package/dist/api/index.js +5 -0
- package/dist/api/index.js.map +1 -0
- package/dist/api/keyless.d.ts +160 -0
- package/dist/api/keyless.d.ts.map +1 -0
- package/dist/api/keyless.js +176 -0
- package/dist/api/keyless.js.map +1 -0
- package/dist/api/object.d.ts +74 -0
- package/dist/api/object.d.ts.map +1 -0
- package/dist/api/object.js +84 -0
- package/dist/api/object.js.map +1 -0
- package/dist/api/staking.d.ts +128 -0
- package/dist/api/staking.d.ts.map +1 -0
- package/dist/api/staking.js +143 -0
- package/dist/api/staking.js.map +1 -0
- package/dist/api/table.d.ts +163 -0
- package/dist/api/table.d.ts.map +1 -0
- package/dist/api/table.js +171 -0
- package/dist/api/table.js.map +1 -0
- package/dist/api/transaction.d.ts +672 -0
- package/dist/api/transaction.d.ts.map +1 -0
- package/dist/api/transaction.js +694 -0
- package/dist/api/transaction.js.map +1 -0
- package/dist/api/transactionSubmission/build.d.ts +137 -0
- package/dist/api/transactionSubmission/build.d.ts.map +1 -0
- package/dist/api/transactionSubmission/build.js +130 -0
- package/dist/api/transactionSubmission/build.js.map +1 -0
- package/dist/api/transactionSubmission/helpers.d.ts +91 -0
- package/dist/api/transactionSubmission/helpers.d.ts.map +1 -0
- package/dist/api/transactionSubmission/helpers.js +99 -0
- package/dist/api/transactionSubmission/helpers.js.map +1 -0
- package/dist/api/transactionSubmission/management.d.ts +159 -0
- package/dist/api/transactionSubmission/management.d.ts.map +1 -0
- package/dist/api/transactionSubmission/management.js +192 -0
- package/dist/api/transactionSubmission/management.js.map +1 -0
- package/dist/api/transactionSubmission/sign.d.ts +117 -0
- package/dist/api/transactionSubmission/sign.d.ts.map +1 -0
- package/dist/api/transactionSubmission/sign.js +130 -0
- package/dist/api/transactionSubmission/sign.js.map +1 -0
- package/dist/api/transactionSubmission/simulate.d.ts +176 -0
- package/dist/api/transactionSubmission/simulate.d.ts.map +1 -0
- package/dist/api/transactionSubmission/simulate.js +183 -0
- package/dist/api/transactionSubmission/simulate.js.map +1 -0
- package/dist/api/transactionSubmission/submit.d.ts +136 -0
- package/dist/api/transactionSubmission/submit.d.ts.map +1 -0
- package/dist/api/transactionSubmission/submit.js +136 -0
- package/dist/api/transactionSubmission/submit.js.map +1 -0
- package/dist/api/utils.d.ts +39 -0
- package/dist/api/utils.d.ts.map +1 -0
- package/dist/api/utils.js +41 -0
- package/dist/api/utils.js.map +1 -0
- package/dist/bcs/consts.d.ts +20 -0
- package/dist/bcs/consts.d.ts.map +1 -0
- package/dist/bcs/consts.js +24 -0
- package/dist/bcs/consts.js.map +1 -0
- package/dist/bcs/deserializer.d.ts +365 -0
- package/dist/bcs/deserializer.d.ts.map +1 -0
- package/dist/bcs/deserializer.js +470 -0
- package/dist/bcs/deserializer.js.map +1 -0
- package/dist/bcs/index.d.ts +7 -0
- package/dist/bcs/index.d.ts.map +1 -0
- package/dist/bcs/index.js +9 -0
- package/dist/bcs/index.js.map +1 -0
- package/dist/bcs/serializable/entryFunctionBytes.d.ts +60 -0
- package/dist/bcs/serializable/entryFunctionBytes.d.ts.map +1 -0
- package/dist/bcs/serializable/entryFunctionBytes.js +82 -0
- package/dist/bcs/serializable/entryFunctionBytes.js.map +1 -0
- package/dist/bcs/serializable/fixedBytes.d.ts +86 -0
- package/dist/bcs/serializable/fixedBytes.d.ts.map +1 -0
- package/dist/bcs/serializable/fixedBytes.js +98 -0
- package/dist/bcs/serializable/fixedBytes.js.map +1 -0
- package/dist/bcs/serializable/movePrimitives.d.ts +267 -0
- package/dist/bcs/serializable/movePrimitives.d.ts.map +1 -0
- package/dist/bcs/serializable/movePrimitives.js +448 -0
- package/dist/bcs/serializable/movePrimitives.js.map +1 -0
- package/dist/bcs/serializable/moveStructs.d.ts +596 -0
- package/dist/bcs/serializable/moveStructs.d.ts.map +1 -0
- package/dist/bcs/serializable/moveStructs.js +748 -0
- package/dist/bcs/serializable/moveStructs.js.map +1 -0
- package/dist/bcs/serializer.d.ts +442 -0
- package/dist/bcs/serializer.d.ts.map +1 -0
- package/dist/bcs/serializer.js +747 -0
- package/dist/bcs/serializer.js.map +1 -0
- package/dist/cli/index.d.ts +3 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/index.js +3 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/cli/localNode.d.ts +65 -0
- package/dist/cli/localNode.d.ts.map +1 -0
- package/dist/cli/localNode.js +149 -0
- package/dist/cli/localNode.js.map +1 -0
- package/dist/cli/move.d.ts +250 -0
- package/dist/cli/move.d.ts.map +1 -0
- package/dist/cli/move.js +364 -0
- package/dist/cli/move.js.map +1 -0
- package/dist/client/core.d.ts +37 -0
- package/dist/client/core.d.ts.map +1 -0
- package/dist/client/core.js +116 -0
- package/dist/client/core.js.map +1 -0
- package/dist/client/get.d.ts +119 -0
- package/dist/client/get.d.ts.map +1 -0
- package/dist/client/get.js +165 -0
- package/dist/client/get.js.map +1 -0
- package/dist/client/index.d.ts +4 -0
- package/dist/client/index.d.ts.map +1 -0
- package/dist/client/index.js +6 -0
- package/dist/client/index.js.map +1 -0
- package/dist/client/post.d.ts +155 -0
- package/dist/client/post.d.ts.map +1 -0
- package/dist/client/post.js +151 -0
- package/dist/client/post.js.map +1 -0
- package/dist/core/account/index.d.ts +2 -0
- package/dist/core/account/index.d.ts.map +1 -0
- package/dist/core/account/index.js +2 -0
- package/dist/core/account/index.js.map +1 -0
- package/dist/core/account/utils/address.d.ts +47 -0
- package/dist/core/account/utils/address.d.ts.map +1 -0
- package/dist/core/account/utils/address.js +68 -0
- package/dist/core/account/utils/address.js.map +1 -0
- package/dist/core/account/utils/index.d.ts +2 -0
- package/dist/core/account/utils/index.d.ts.map +1 -0
- package/dist/core/account/utils/index.js +2 -0
- package/dist/core/account/utils/index.js.map +1 -0
- package/dist/core/accountAddress.d.ts +327 -0
- package/dist/core/accountAddress.d.ts.map +1 -0
- package/dist/core/accountAddress.js +457 -0
- package/dist/core/accountAddress.js.map +1 -0
- package/dist/core/authenticationKey.d.ts +129 -0
- package/dist/core/authenticationKey.d.ts.map +1 -0
- package/dist/core/authenticationKey.js +155 -0
- package/dist/core/authenticationKey.js.map +1 -0
- package/dist/core/common.d.ts +51 -0
- package/dist/core/common.d.ts.map +1 -0
- package/dist/core/common.js +30 -0
- package/dist/core/common.js.map +1 -0
- package/dist/core/crypto/abstraction.d.ts +21 -0
- package/dist/core/crypto/abstraction.d.ts.map +1 -0
- package/dist/core/crypto/abstraction.js +37 -0
- package/dist/core/crypto/abstraction.js.map +1 -0
- package/dist/core/crypto/anyKeyRegistry.d.ts +45 -0
- package/dist/core/crypto/anyKeyRegistry.d.ts.map +1 -0
- package/dist/core/crypto/anyKeyRegistry.js +59 -0
- package/dist/core/crypto/anyKeyRegistry.js.map +1 -0
- package/dist/core/crypto/deserializationUtils.d.ts +22 -0
- package/dist/core/crypto/deserializationUtils.d.ts.map +1 -0
- package/dist/core/crypto/deserializationUtils.js +89 -0
- package/dist/core/crypto/deserializationUtils.js.map +1 -0
- package/dist/core/crypto/ed25519.d.ts +330 -0
- package/dist/core/crypto/ed25519.d.ts.map +1 -0
- package/dist/core/crypto/ed25519.js +502 -0
- package/dist/core/crypto/ed25519.js.map +1 -0
- package/dist/core/crypto/encryption/ciphertext.d.ts +49 -0
- package/dist/core/crypto/encryption/ciphertext.d.ts.map +1 -0
- package/dist/core/crypto/encryption/ciphertext.js +166 -0
- package/dist/core/crypto/encryption/ciphertext.js.map +1 -0
- package/dist/core/crypto/encryption/curveSerialization.d.ts +17 -0
- package/dist/core/crypto/encryption/curveSerialization.d.ts.map +1 -0
- package/dist/core/crypto/encryption/curveSerialization.js +38 -0
- package/dist/core/crypto/encryption/curveSerialization.js.map +1 -0
- package/dist/core/crypto/encryption/fieldSerialization.d.ts +12 -0
- package/dist/core/crypto/encryption/fieldSerialization.d.ts.map +1 -0
- package/dist/core/crypto/encryption/fieldSerialization.js +70 -0
- package/dist/core/crypto/encryption/fieldSerialization.js.map +1 -0
- package/dist/core/crypto/encryption/index.d.ts +11 -0
- package/dist/core/crypto/encryption/index.d.ts.map +1 -0
- package/dist/core/crypto/encryption/index.js +13 -0
- package/dist/core/crypto/encryption/index.js.map +1 -0
- package/dist/core/crypto/encryption/symmetric.d.ts +38 -0
- package/dist/core/crypto/encryption/symmetric.d.ts.map +1 -0
- package/dist/core/crypto/encryption/symmetric.js +124 -0
- package/dist/core/crypto/encryption/symmetric.js.map +1 -0
- package/dist/core/crypto/ephemeral.d.ts +112 -0
- package/dist/core/crypto/ephemeral.d.ts.map +1 -0
- package/dist/core/crypto/ephemeral.js +170 -0
- package/dist/core/crypto/ephemeral.js.map +1 -0
- package/dist/core/crypto/federatedKeyless.d.ts +106 -0
- package/dist/core/crypto/federatedKeyless.d.ts.map +1 -0
- package/dist/core/crypto/federatedKeyless.js +125 -0
- package/dist/core/crypto/federatedKeyless.js.map +1 -0
- package/dist/core/crypto/hdKey.d.ts +90 -0
- package/dist/core/crypto/hdKey.d.ts.map +1 -0
- package/dist/core/crypto/hdKey.js +118 -0
- package/dist/core/crypto/hdKey.js.map +1 -0
- package/dist/core/crypto/index.d.ts +13 -0
- package/dist/core/crypto/index.d.ts.map +1 -0
- package/dist/core/crypto/index.js +26 -0
- package/dist/core/crypto/index.js.map +1 -0
- package/dist/core/crypto/keyless.d.ts +788 -0
- package/dist/core/crypto/keyless.d.ts.map +1 -0
- package/dist/core/crypto/keyless.js +1482 -0
- package/dist/core/crypto/keyless.js.map +1 -0
- package/dist/core/crypto/keylessRegistration.d.ts +2 -0
- package/dist/core/crypto/keylessRegistration.d.ts.map +1 -0
- package/dist/core/crypto/keylessRegistration.js +16 -0
- package/dist/core/crypto/keylessRegistration.js.map +1 -0
- package/dist/core/crypto/multiEd25519.d.ts +228 -0
- package/dist/core/crypto/multiEd25519.d.ts.map +1 -0
- package/dist/core/crypto/multiEd25519.js +361 -0
- package/dist/core/crypto/multiEd25519.js.map +1 -0
- package/dist/core/crypto/multiKey.d.ts +248 -0
- package/dist/core/crypto/multiKey.d.ts.map +1 -0
- package/dist/core/crypto/multiKey.js +417 -0
- package/dist/core/crypto/multiKey.js.map +1 -0
- package/dist/core/crypto/poseidon.d.ts +58 -0
- package/dist/core/crypto/poseidon.d.ts.map +1 -0
- package/dist/core/crypto/poseidon.js +196 -0
- package/dist/core/crypto/poseidon.js.map +1 -0
- package/dist/core/crypto/privateKey.d.ts +64 -0
- package/dist/core/crypto/privateKey.d.ts.map +1 -0
- package/dist/core/crypto/privateKey.js +74 -0
- package/dist/core/crypto/privateKey.js.map +1 -0
- package/dist/core/crypto/proof.d.ts +10 -0
- package/dist/core/crypto/proof.d.ts.map +1 -0
- package/dist/core/crypto/proof.js +10 -0
- package/dist/core/crypto/proof.js.map +1 -0
- package/dist/core/crypto/publicKey.d.ts +92 -0
- package/dist/core/crypto/publicKey.d.ts.map +1 -0
- package/dist/core/crypto/publicKey.js +54 -0
- package/dist/core/crypto/publicKey.js.map +1 -0
- package/dist/core/crypto/secp256k1.d.ts +303 -0
- package/dist/core/crypto/secp256k1.d.ts.map +1 -0
- package/dist/core/crypto/secp256k1.js +455 -0
- package/dist/core/crypto/secp256k1.js.map +1 -0
- package/dist/core/crypto/secp256r1.d.ts +304 -0
- package/dist/core/crypto/secp256r1.d.ts.map +1 -0
- package/dist/core/crypto/secp256r1.js +444 -0
- package/dist/core/crypto/secp256r1.js.map +1 -0
- package/dist/core/crypto/signature.d.ts +35 -0
- package/dist/core/crypto/signature.d.ts.map +1 -0
- package/dist/core/crypto/signature.js +55 -0
- package/dist/core/crypto/signature.js.map +1 -0
- package/dist/core/crypto/singleKey.d.ts +175 -0
- package/dist/core/crypto/singleKey.d.ts.map +1 -0
- package/dist/core/crypto/singleKey.js +324 -0
- package/dist/core/crypto/singleKey.js.map +1 -0
- package/dist/core/crypto/types.d.ts +6 -0
- package/dist/core/crypto/types.d.ts.map +1 -0
- package/dist/core/crypto/types.js +2 -0
- package/dist/core/crypto/types.js.map +1 -0
- package/dist/core/crypto/utils.d.ts +16 -0
- package/dist/core/crypto/utils.d.ts.map +1 -0
- package/dist/core/crypto/utils.js +64 -0
- package/dist/core/crypto/utils.js.map +1 -0
- package/dist/core/hex.d.ts +154 -0
- package/dist/core/hex.d.ts.map +1 -0
- package/dist/core/hex.js +219 -0
- package/dist/core/hex.js.map +1 -0
- package/dist/core/index.d.ts +7 -0
- package/dist/core/index.d.ts.map +1 -0
- package/dist/core/index.js +9 -0
- package/dist/core/index.js.map +1 -0
- package/dist/errors/index.d.ts +125 -0
- package/dist/errors/index.d.ts.map +1 -0
- package/dist/errors/index.js +367 -0
- package/dist/errors/index.js.map +1 -0
- package/dist/functions/abstraction.d.ts +4 -0
- package/dist/functions/abstraction.d.ts.map +1 -0
- package/dist/functions/abstraction.js +6 -0
- package/dist/functions/abstraction.js.map +1 -0
- package/dist/functions/account.d.ts +8 -0
- package/dist/functions/account.d.ts.map +1 -0
- package/dist/functions/account.js +10 -0
- package/dist/functions/account.js.map +1 -0
- package/dist/functions/ans.d.ts +4 -0
- package/dist/functions/ans.d.ts.map +1 -0
- package/dist/functions/ans.js +6 -0
- package/dist/functions/ans.js.map +1 -0
- package/dist/functions/coin.d.ts +4 -0
- package/dist/functions/coin.d.ts.map +1 -0
- package/dist/functions/coin.js +6 -0
- package/dist/functions/coin.js.map +1 -0
- package/dist/functions/digitalAsset.d.ts +4 -0
- package/dist/functions/digitalAsset.d.ts.map +1 -0
- package/dist/functions/digitalAsset.js +6 -0
- package/dist/functions/digitalAsset.js.map +1 -0
- package/dist/functions/faucet.d.ts +4 -0
- package/dist/functions/faucet.d.ts.map +1 -0
- package/dist/functions/faucet.js +6 -0
- package/dist/functions/faucet.js.map +1 -0
- package/dist/functions/fungibleAsset.d.ts +4 -0
- package/dist/functions/fungibleAsset.d.ts.map +1 -0
- package/dist/functions/fungibleAsset.js +6 -0
- package/dist/functions/fungibleAsset.js.map +1 -0
- package/dist/functions/general.d.ts +4 -0
- package/dist/functions/general.d.ts.map +1 -0
- package/dist/functions/general.js +6 -0
- package/dist/functions/general.js.map +1 -0
- package/dist/functions/index.d.ts +18 -0
- package/dist/functions/index.d.ts.map +1 -0
- package/dist/functions/index.js +20 -0
- package/dist/functions/index.js.map +1 -0
- package/dist/functions/keyless.d.ts +16 -0
- package/dist/functions/keyless.d.ts.map +1 -0
- package/dist/functions/keyless.js +23 -0
- package/dist/functions/keyless.js.map +1 -0
- package/dist/functions/object.d.ts +4 -0
- package/dist/functions/object.d.ts.map +1 -0
- package/dist/functions/object.js +6 -0
- package/dist/functions/object.js.map +1 -0
- package/dist/functions/staking.d.ts +4 -0
- package/dist/functions/staking.d.ts.map +1 -0
- package/dist/functions/staking.js +6 -0
- package/dist/functions/staking.js.map +1 -0
- package/dist/functions/table.d.ts +4 -0
- package/dist/functions/table.d.ts.map +1 -0
- package/dist/functions/table.js +6 -0
- package/dist/functions/table.js.map +1 -0
- package/dist/functions/transaction.d.ts +5 -0
- package/dist/functions/transaction.d.ts.map +1 -0
- package/dist/functions/transaction.js +7 -0
- package/dist/functions/transaction.js.map +1 -0
- package/dist/functions/view.d.ts +3 -0
- package/dist/functions/view.d.ts.map +1 -0
- package/dist/functions/view.js +5 -0
- package/dist/functions/view.js.map +1 -0
- package/dist/index.d.ts +12 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +29 -0
- package/dist/index.js.map +1 -0
- package/dist/internal/abstraction.d.ts +22 -0
- package/dist/internal/abstraction.d.ts.map +1 -0
- package/dist/internal/abstraction.js +54 -0
- package/dist/internal/abstraction.js.map +1 -0
- package/dist/internal/account.d.ts +457 -0
- package/dist/internal/account.d.ts.map +1 -0
- package/dist/internal/account.js +1164 -0
- package/dist/internal/account.js.map +1 -0
- package/dist/internal/ans.d.ts +414 -0
- package/dist/internal/ans.d.ts.map +1 -0
- package/dist/internal/ans.js +769 -0
- package/dist/internal/ans.js.map +1 -0
- package/dist/internal/coin.d.ts +27 -0
- package/dist/internal/coin.d.ts.map +1 -0
- package/dist/internal/coin.js +36 -0
- package/dist/internal/coin.js.map +1 -0
- package/dist/internal/digitalAsset.d.ts +577 -0
- package/dist/internal/digitalAsset.d.ts.map +1 -0
- package/dist/internal/digitalAsset.js +900 -0
- package/dist/internal/digitalAsset.js.map +1 -0
- package/dist/internal/encryptionKey.d.ts +20 -0
- package/dist/internal/encryptionKey.d.ts.map +1 -0
- package/dist/internal/encryptionKey.js +33 -0
- package/dist/internal/encryptionKey.js.map +1 -0
- package/dist/internal/faucet.d.ts +35 -0
- package/dist/internal/faucet.d.ts.map +1 -0
- package/dist/internal/faucet.js +53 -0
- package/dist/internal/faucet.js.map +1 -0
- package/dist/internal/fungibleAsset.d.ts +108 -0
- package/dist/internal/fungibleAsset.d.ts.map +1 -0
- package/dist/internal/fungibleAsset.js +155 -0
- package/dist/internal/fungibleAsset.js.map +1 -0
- package/dist/internal/general.d.ts +87 -0
- package/dist/internal/general.d.ts.map +1 -0
- package/dist/internal/general.js +136 -0
- package/dist/internal/general.js.map +1 -0
- package/dist/internal/keyless.d.ts +101 -0
- package/dist/internal/keyless.d.ts.map +1 -0
- package/dist/internal/keyless.js +191 -0
- package/dist/internal/keyless.js.map +1 -0
- package/dist/internal/object.d.ts +37 -0
- package/dist/internal/object.d.ts.map +1 -0
- package/dist/internal/object.js +53 -0
- package/dist/internal/object.js.map +1 -0
- package/dist/internal/staking.d.ts +53 -0
- package/dist/internal/staking.d.ts.map +1 -0
- package/dist/internal/staking.js +71 -0
- package/dist/internal/staking.js.map +1 -0
- package/dist/internal/table.d.ts +60 -0
- package/dist/internal/table.d.ts.map +1 -0
- package/dist/internal/table.js +86 -0
- package/dist/internal/table.js.map +1 -0
- package/dist/internal/transaction.d.ts +192 -0
- package/dist/internal/transaction.d.ts.map +1 -0
- package/dist/internal/transaction.js +399 -0
- package/dist/internal/transaction.js.map +1 -0
- package/dist/internal/transactionSubmission.d.ts +177 -0
- package/dist/internal/transactionSubmission.d.ts.map +1 -0
- package/dist/internal/transactionSubmission.js +411 -0
- package/dist/internal/transactionSubmission.js.map +1 -0
- package/dist/internal/utils/index.d.ts +2 -0
- package/dist/internal/utils/index.d.ts.map +1 -0
- package/dist/internal/utils/index.js +4 -0
- package/dist/internal/utils/index.js.map +1 -0
- package/dist/internal/utils/utils.d.ts +35 -0
- package/dist/internal/utils/utils.d.ts.map +1 -0
- package/dist/internal/utils/utils.js +63 -0
- package/dist/internal/utils/utils.js.map +1 -0
- package/dist/internal/view.d.ts +14 -0
- package/dist/internal/view.d.ts.map +1 -0
- package/dist/internal/view.js +41 -0
- package/dist/internal/view.js.map +1 -0
- package/dist/transactions/authenticator/account.d.ts +193 -0
- package/dist/transactions/authenticator/account.d.ts.map +1 -0
- package/dist/transactions/authenticator/account.js +346 -0
- package/dist/transactions/authenticator/account.js.map +1 -0
- package/dist/transactions/authenticator/index.d.ts +3 -0
- package/dist/transactions/authenticator/index.d.ts.map +1 -0
- package/dist/transactions/authenticator/index.js +5 -0
- package/dist/transactions/authenticator/index.js.map +1 -0
- package/dist/transactions/authenticator/transaction.d.ts +148 -0
- package/dist/transactions/authenticator/transaction.d.ts.map +1 -0
- package/dist/transactions/authenticator/transaction.js +239 -0
- package/dist/transactions/authenticator/transaction.js.map +1 -0
- package/dist/transactions/index.d.ts +7 -0
- package/dist/transactions/index.d.ts.map +1 -0
- package/dist/transactions/index.js +9 -0
- package/dist/transactions/index.js.map +1 -0
- package/dist/transactions/instances/chainId.d.ts +39 -0
- package/dist/transactions/instances/chainId.d.ts.map +1 -0
- package/dist/transactions/instances/chainId.js +48 -0
- package/dist/transactions/instances/chainId.js.map +1 -0
- package/dist/transactions/instances/encryptedPayload.d.ts +65 -0
- package/dist/transactions/instances/encryptedPayload.d.ts.map +1 -0
- package/dist/transactions/instances/encryptedPayload.js +122 -0
- package/dist/transactions/instances/encryptedPayload.js.map +1 -0
- package/dist/transactions/instances/identifier.d.ts +40 -0
- package/dist/transactions/instances/identifier.d.ts.map +1 -0
- package/dist/transactions/instances/identifier.js +49 -0
- package/dist/transactions/instances/identifier.js.map +1 -0
- package/dist/transactions/instances/index.d.ts +12 -0
- package/dist/transactions/instances/index.d.ts.map +1 -0
- package/dist/transactions/instances/index.js +14 -0
- package/dist/transactions/instances/index.js.map +1 -0
- package/dist/transactions/instances/moduleId.d.ts +52 -0
- package/dist/transactions/instances/moduleId.d.ts.map +1 -0
- package/dist/transactions/instances/moduleId.js +69 -0
- package/dist/transactions/instances/moduleId.js.map +1 -0
- package/dist/transactions/instances/multiAgentTransaction.d.ts +50 -0
- package/dist/transactions/instances/multiAgentTransaction.d.ts.map +1 -0
- package/dist/transactions/instances/multiAgentTransaction.js +75 -0
- package/dist/transactions/instances/multiAgentTransaction.js.map +1 -0
- package/dist/transactions/instances/rawTransaction.d.ts +142 -0
- package/dist/transactions/instances/rawTransaction.d.ts.map +1 -0
- package/dist/transactions/instances/rawTransaction.js +202 -0
- package/dist/transactions/instances/rawTransaction.js.map +1 -0
- package/dist/transactions/instances/rotationProofChallenge.d.ts +54 -0
- package/dist/transactions/instances/rotationProofChallenge.d.ts.map +1 -0
- package/dist/transactions/instances/rotationProofChallenge.js +70 -0
- package/dist/transactions/instances/rotationProofChallenge.js.map +1 -0
- package/dist/transactions/instances/signedTransaction.d.ts +53 -0
- package/dist/transactions/instances/signedTransaction.d.ts.map +1 -0
- package/dist/transactions/instances/signedTransaction.js +65 -0
- package/dist/transactions/instances/signedTransaction.js.map +1 -0
- package/dist/transactions/instances/simpleTransaction.d.ts +49 -0
- package/dist/transactions/instances/simpleTransaction.d.ts.map +1 -0
- package/dist/transactions/instances/simpleTransaction.js +73 -0
- package/dist/transactions/instances/simpleTransaction.js.map +1 -0
- package/dist/transactions/instances/transactionArgument.d.ts +71 -0
- package/dist/transactions/instances/transactionArgument.d.ts.map +1 -0
- package/dist/transactions/instances/transactionArgument.js +4 -0
- package/dist/transactions/instances/transactionArgument.js.map +1 -0
- package/dist/transactions/instances/transactionPayload.d.ts +369 -0
- package/dist/transactions/instances/transactionPayload.d.ts.map +1 -0
- package/dist/transactions/instances/transactionPayload.js +668 -0
- package/dist/transactions/instances/transactionPayload.js.map +1 -0
- package/dist/transactions/management/accountSequenceNumber.d.ts +114 -0
- package/dist/transactions/management/accountSequenceNumber.d.ts.map +1 -0
- package/dist/transactions/management/accountSequenceNumber.js +197 -0
- package/dist/transactions/management/accountSequenceNumber.js.map +1 -0
- package/dist/transactions/management/asyncQueue.d.ts +76 -0
- package/dist/transactions/management/asyncQueue.d.ts.map +1 -0
- package/dist/transactions/management/asyncQueue.js +105 -0
- package/dist/transactions/management/asyncQueue.js.map +1 -0
- package/dist/transactions/management/index.d.ts +3 -0
- package/dist/transactions/management/index.d.ts.map +1 -0
- package/dist/transactions/management/index.js +3 -0
- package/dist/transactions/management/index.js.map +1 -0
- package/dist/transactions/management/transactionWorker.d.ts +213 -0
- package/dist/transactions/management/transactionWorker.d.ts.map +1 -0
- package/dist/transactions/management/transactionWorker.js +347 -0
- package/dist/transactions/management/transactionWorker.js.map +1 -0
- package/dist/transactions/transactionBuilder/encryptPayload.d.ts +21 -0
- package/dist/transactions/transactionBuilder/encryptPayload.d.ts.map +1 -0
- package/dist/transactions/transactionBuilder/encryptPayload.js +157 -0
- package/dist/transactions/transactionBuilder/encryptPayload.js.map +1 -0
- package/dist/transactions/transactionBuilder/helpers.d.ts +184 -0
- package/dist/transactions/transactionBuilder/helpers.d.ts.map +1 -0
- package/dist/transactions/transactionBuilder/helpers.js +344 -0
- package/dist/transactions/transactionBuilder/helpers.js.map +1 -0
- package/dist/transactions/transactionBuilder/index.d.ts +6 -0
- package/dist/transactions/transactionBuilder/index.d.ts.map +1 -0
- package/dist/transactions/transactionBuilder/index.js +8 -0
- package/dist/transactions/transactionBuilder/index.js.map +1 -0
- package/dist/transactions/transactionBuilder/remoteAbi.d.ts +167 -0
- package/dist/transactions/transactionBuilder/remoteAbi.d.ts.map +1 -0
- package/dist/transactions/transactionBuilder/remoteAbi.js +1088 -0
- package/dist/transactions/transactionBuilder/remoteAbi.js.map +1 -0
- package/dist/transactions/transactionBuilder/signingMessage.d.ts +55 -0
- package/dist/transactions/transactionBuilder/signingMessage.d.ts.map +1 -0
- package/dist/transactions/transactionBuilder/signingMessage.js +94 -0
- package/dist/transactions/transactionBuilder/signingMessage.js.map +1 -0
- package/dist/transactions/transactionBuilder/structEnumParser.d.ts +225 -0
- package/dist/transactions/transactionBuilder/structEnumParser.d.ts.map +1 -0
- package/dist/transactions/transactionBuilder/structEnumParser.js +690 -0
- package/dist/transactions/transactionBuilder/structEnumParser.js.map +1 -0
- package/dist/transactions/transactionBuilder/transactionBuilder.d.ts +198 -0
- package/dist/transactions/transactionBuilder/transactionBuilder.d.ts.map +1 -0
- package/dist/transactions/transactionBuilder/transactionBuilder.js +586 -0
- package/dist/transactions/transactionBuilder/transactionBuilder.js.map +1 -0
- package/dist/transactions/typeTag/index.d.ts +544 -0
- package/dist/transactions/typeTag/index.d.ts.map +1 -0
- package/dist/transactions/typeTag/index.js +826 -0
- package/dist/transactions/typeTag/index.js.map +1 -0
- package/dist/transactions/typeTag/parser.d.ts +73 -0
- package/dist/transactions/typeTag/parser.d.ts.map +1 -0
- package/dist/transactions/typeTag/parser.js +368 -0
- package/dist/transactions/typeTag/parser.js.map +1 -0
- package/dist/transactions/types.d.ts +477 -0
- package/dist/transactions/types.d.ts.map +1 -0
- package/dist/transactions/types.js +4 -0
- package/dist/transactions/types.js.map +1 -0
- package/dist/types/abstraction.d.ts +14 -0
- package/dist/types/abstraction.d.ts.map +1 -0
- package/dist/types/abstraction.js +16 -0
- package/dist/types/abstraction.js.map +1 -0
- package/dist/types/ans.d.ts +113 -0
- package/dist/types/ans.d.ts.map +1 -0
- package/dist/types/ans.js +36 -0
- package/dist/types/ans.js.map +1 -0
- package/dist/types/generated/operations.d.ts +702 -0
- package/dist/types/generated/operations.d.ts.map +1 -0
- package/dist/types/generated/operations.js +2 -0
- package/dist/types/generated/operations.js.map +1 -0
- package/dist/types/generated/queries.d.ts +64 -0
- package/dist/types/generated/queries.d.ts.map +1 -0
- package/dist/types/generated/queries.js +729 -0
- package/dist/types/generated/queries.js.map +1 -0
- package/dist/types/generated/types.d.ts +9678 -0
- package/dist/types/generated/types.d.ts.map +1 -0
- package/dist/types/generated/types.js +1265 -0
- package/dist/types/generated/types.js.map +1 -0
- package/dist/types/index.d.ts +4 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +4 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/indexer.d.ts +182 -0
- package/dist/types/indexer.d.ts.map +1 -0
- package/dist/types/indexer.js +4 -0
- package/dist/types/indexer.js.map +1 -0
- package/dist/types/keyless.d.ts +101 -0
- package/dist/types/keyless.d.ts.map +1 -0
- package/dist/types/keyless.js +2 -0
- package/dist/types/keyless.js.map +1 -0
- package/dist/types/types.d.ts +1572 -0
- package/dist/types/types.d.ts.map +1 -0
- package/dist/types/types.js +464 -0
- package/dist/types/types.js.map +1 -0
- package/dist/utils/apiEndpoints.d.ts +50 -0
- package/dist/utils/apiEndpoints.d.ts.map +1 -0
- package/dist/utils/apiEndpoints.js +100 -0
- package/dist/utils/apiEndpoints.js.map +1 -0
- package/dist/utils/const.d.ts +117 -0
- package/dist/utils/const.d.ts.map +1 -0
- package/dist/utils/const.js +121 -0
- package/dist/utils/const.js.map +1 -0
- package/dist/utils/helpers.d.ts +203 -0
- package/dist/utils/helpers.d.ts.map +1 -0
- package/dist/utils/helpers.js +330 -0
- package/dist/utils/helpers.js.map +1 -0
- package/dist/utils/index.d.ts +5 -0
- package/dist/utils/index.d.ts.map +1 -0
- package/dist/utils/index.js +5 -0
- package/dist/utils/index.js.map +1 -0
- package/dist/utils/memoize.d.ts +47 -0
- package/dist/utils/memoize.d.ts.map +1 -0
- package/dist/utils/memoize.js +195 -0
- package/dist/utils/memoize.js.map +1 -0
- package/dist/utils/normalizeBundle.d.ts +27 -0
- package/dist/utils/normalizeBundle.d.ts.map +1 -0
- package/dist/utils/normalizeBundle.js +18 -0
- package/dist/utils/normalizeBundle.js.map +1 -0
- package/dist/utils/runtime.d.ts +44 -0
- package/dist/utils/runtime.d.ts.map +1 -0
- package/dist/utils/runtime.js +71 -0
- package/dist/utils/runtime.js.map +1 -0
- package/dist/version.d.ts +7 -0
- package/dist/version.d.ts.map +1 -0
- package/dist/version.js +9 -0
- package/dist/version.js.map +1 -0
- package/package.json +107 -47
- package/src/account/AbstractKeylessAccount.ts +24 -30
- package/src/account/AbstractedAccount.ts +18 -16
- package/src/account/Account.ts +12 -9
- package/src/account/AccountUtils.ts +17 -20
- package/src/account/DerivableAbstractedAccount.ts +12 -10
- package/src/account/Ed25519Account.ts +8 -8
- package/src/account/EphemeralKeyPair.ts +9 -14
- package/src/account/FederatedKeylessAccount.ts +7 -7
- package/src/account/KeylessAccount.ts +12 -7
- package/src/account/MultiEd25519Account.ts +9 -9
- package/src/account/MultiKeyAccount.ts +15 -16
- package/src/account/SingleKeyAccount.ts +10 -13
- package/src/account/index.ts +17 -12
- package/src/account/keylessSigner.ts +34 -0
- package/src/account/utils.ts +3 -3
- package/src/api/account/abstraction.ts +12 -12
- package/src/api/account.ts +12 -12
- package/src/api/ans.ts +6 -6
- package/src/api/aptos.ts +115 -88
- package/src/api/aptosConfig.ts +6 -4
- package/src/api/coin.ts +6 -6
- package/src/api/digitalAsset.ts +9 -9
- package/src/api/faucet.ts +6 -6
- package/src/api/fungibleAsset.ts +10 -10
- package/src/api/general.ts +7 -7
- package/src/api/index.ts +2 -2
- package/src/api/keyless.ts +11 -7
- package/src/api/object.ts +6 -6
- package/src/api/staking.ts +11 -6
- package/src/api/table.ts +6 -6
- package/src/api/transaction.ts +13 -13
- package/src/api/transactionSubmission/build.ts +6 -6
- package/src/api/transactionSubmission/helpers.ts +2 -2
- package/src/api/transactionSubmission/management.ts +9 -5
- package/src/api/transactionSubmission/sign.ts +4 -4
- package/src/api/transactionSubmission/simulate.ts +6 -6
- package/src/api/transactionSubmission/submit.ts +5 -5
- package/src/api/utils.ts +4 -4
- package/src/bcs/consts.ts +14 -1
- package/src/bcs/deserializer.ts +3 -3
- package/src/bcs/index.ts +6 -6
- package/src/bcs/serializable/entryFunctionBytes.ts +5 -5
- package/src/bcs/serializable/fixedBytes.ts +5 -5
- package/src/bcs/serializable/movePrimitives.ts +14 -5
- package/src/bcs/serializable/moveStructs.ts +8 -8
- package/src/bcs/serializer.ts +6 -6
- package/src/cli/index.ts +2 -2
- package/src/cli/localNode.ts +1 -1
- package/src/cli/move.ts +6 -10
- package/src/client/core.ts +30 -15
- package/src/client/get.ts +6 -8
- package/src/client/index.ts +3 -3
- package/src/client/post.ts +4 -4
- package/src/core/account/index.ts +1 -1
- package/src/core/account/utils/address.ts +4 -4
- package/src/core/account/utils/index.ts +1 -1
- package/src/core/accountAddress.ts +6 -6
- package/src/core/authenticationKey.ts +22 -10
- package/src/core/crypto/abstraction.ts +7 -7
- package/src/core/crypto/anyKeyRegistry.ts +90 -0
- package/src/core/crypto/deserializationUtils.ts +11 -19
- package/src/core/crypto/ed25519.ts +22 -13
- package/src/core/crypto/encryption/ciphertext.ts +210 -0
- package/src/core/crypto/encryption/curveSerialization.ts +46 -0
- package/src/core/crypto/encryption/fieldSerialization.ts +82 -0
- package/src/core/crypto/encryption/index.ts +14 -0
- package/src/core/crypto/encryption/symmetric.ts +148 -0
- package/src/core/crypto/ephemeral.ts +7 -7
- package/src/core/crypto/federatedKeyless.ts +8 -8
- package/src/core/crypto/hdKey.ts +7 -3
- package/src/core/crypto/index.ts +24 -17
- package/src/core/crypto/keyless.ts +33 -33
- package/src/core/crypto/keylessRegistration.ts +34 -0
- package/src/core/crypto/multiEd25519.ts +7 -7
- package/src/core/crypto/multiKey.ts +8 -8
- package/src/core/crypto/poseidon.ts +2 -2
- package/src/core/crypto/privateKey.ts +5 -5
- package/src/core/crypto/proof.ts +1 -1
- package/src/core/crypto/publicKey.ts +6 -6
- package/src/core/crypto/secp256k1.ts +26 -19
- package/src/core/crypto/secp256r1.ts +26 -19
- package/src/core/crypto/signature.ts +2 -2
- package/src/core/crypto/singleKey.ts +58 -39
- package/src/core/crypto/types.ts +4 -4
- package/src/core/crypto/utils.ts +16 -12
- package/src/core/hex.ts +3 -3
- package/src/core/index.ts +6 -6
- package/src/errors/index.ts +3 -3
- package/src/functions/abstraction.ts +11 -0
- package/src/functions/account.ts +38 -0
- package/src/functions/ans.ts +26 -0
- package/src/functions/coin.ts +7 -0
- package/src/functions/digitalAsset.ts +32 -0
- package/src/functions/faucet.ts +7 -0
- package/src/functions/fungibleAsset.ts +13 -0
- package/src/functions/general.ts +14 -0
- package/src/functions/index.ts +21 -0
- package/src/functions/keyless.ts +42 -0
- package/src/functions/object.ts +10 -0
- package/src/functions/staking.ts +11 -0
- package/src/functions/table.ts +11 -0
- package/src/functions/transaction.ts +32 -0
- package/src/functions/view.ts +6 -0
- package/src/index.ts +36 -10
- package/src/internal/abstraction.ts +10 -10
- package/src/internal/account.ts +79 -51
- package/src/internal/ans.ts +31 -24
- package/src/internal/coin.ts +8 -8
- package/src/internal/digitalAsset.ts +14 -15
- package/src/internal/encryptionKey.ts +53 -0
- package/src/internal/faucet.ts +6 -6
- package/src/internal/fungibleAsset.ts +11 -11
- package/src/internal/general.ts +12 -7
- package/src/internal/keyless.ts +21 -18
- package/src/internal/object.ts +7 -7
- package/src/internal/staking.ts +6 -6
- package/src/internal/table.ts +7 -7
- package/src/internal/transaction.ts +11 -10
- package/src/internal/transactionSubmission.ts +92 -32
- package/src/internal/utils/index.ts +1 -1
- package/src/internal/utils/utils.ts +5 -5
- package/src/internal/view.ts +5 -5
- package/src/transactions/authenticator/account.ts +12 -12
- package/src/transactions/authenticator/index.ts +2 -2
- package/src/transactions/authenticator/transaction.ts +6 -6
- package/src/transactions/index.ts +6 -6
- package/src/transactions/instances/chainId.ts +2 -2
- package/src/transactions/instances/encryptedPayload.ts +149 -0
- package/src/transactions/instances/identifier.ts +2 -2
- package/src/transactions/instances/index.ts +11 -10
- package/src/transactions/instances/moduleId.ts +5 -5
- package/src/transactions/instances/multiAgentTransaction.ts +4 -4
- package/src/transactions/instances/rawTransaction.ts +6 -6
- package/src/transactions/instances/rotationProofChallenge.ts +5 -5
- package/src/transactions/instances/signedTransaction.ts +4 -4
- package/src/transactions/instances/simpleTransaction.ts +4 -4
- package/src/transactions/instances/transactionArgument.ts +2 -2
- package/src/transactions/instances/transactionPayload.ts +127 -28
- package/src/transactions/management/accountSequenceNumber.ts +13 -14
- package/src/transactions/management/index.ts +2 -2
- package/src/transactions/management/transactionWorker.ts +10 -10
- package/src/transactions/transactionBuilder/encryptPayload.ts +235 -0
- package/src/transactions/transactionBuilder/helpers.ts +8 -5
- package/src/transactions/transactionBuilder/index.ts +5 -4
- package/src/transactions/transactionBuilder/remoteAbi.ts +664 -25
- package/src/transactions/transactionBuilder/signingMessage.ts +6 -6
- package/src/transactions/transactionBuilder/structEnumParser.ts +848 -0
- package/src/transactions/transactionBuilder/transactionBuilder.ts +130 -72
- package/src/transactions/typeTag/index.ts +5 -5
- package/src/transactions/typeTag/parser.ts +3 -3
- package/src/transactions/types.ts +103 -19
- package/src/types/ans.ts +13 -5
- package/src/types/generated/operations.ts +4 -3
- package/src/types/generated/queries.ts +1 -1
- package/src/types/index.ts +3 -3
- package/src/types/indexer.ts +1 -1
- package/src/types/types.ts +74 -6
- package/src/utils/const.ts +14 -1
- package/src/utils/helpers.ts +58 -18
- package/src/utils/index.ts +4 -4
- package/src/utils/normalizeBundle.ts +1 -1
- package/src/utils/runtime.ts +86 -0
- package/src/version.ts +1 -1
- package/dist/common/account-2FUAPVPW.d.ts +0 -8167
- package/dist/common/chunk-L5DUJTE3.js +0 -4
- package/dist/common/chunk-L5DUJTE3.js.map +0 -1
- package/dist/common/cli/index.d.ts +0 -316
- package/dist/common/cli/index.js +0 -2
- package/dist/common/cli/index.js.map +0 -1
- package/dist/common/index.d.ts +0 -10912
- package/dist/common/index.js +0 -476
- package/dist/common/index.js.map +0 -1
- package/dist/esm/Ed25519Account-DpZh3fRy.d.mts +0 -628
- package/dist/esm/account/AbstractKeylessAccount.d.mts +0 -336
- package/dist/esm/account/AbstractKeylessAccount.mjs +0 -2
- package/dist/esm/account/AbstractKeylessAccount.mjs.map +0 -1
- package/dist/esm/account/AbstractedAccount.d.mts +0 -64
- package/dist/esm/account/AbstractedAccount.mjs +0 -2
- package/dist/esm/account/AbstractedAccount.mjs.map +0 -1
- package/dist/esm/account/Account.d.mts +0 -8
- package/dist/esm/account/Account.mjs +0 -2
- package/dist/esm/account/Account.mjs.map +0 -1
- package/dist/esm/account/AccountUtils.d.mts +0 -38
- package/dist/esm/account/AccountUtils.mjs +0 -2
- package/dist/esm/account/AccountUtils.mjs.map +0 -1
- package/dist/esm/account/DerivableAbstractedAccount.d.mts +0 -59
- package/dist/esm/account/DerivableAbstractedAccount.mjs +0 -2
- package/dist/esm/account/DerivableAbstractedAccount.mjs.map +0 -1
- package/dist/esm/account/Ed25519Account.d.mts +0 -8
- package/dist/esm/account/Ed25519Account.mjs +0 -2
- package/dist/esm/account/Ed25519Account.mjs.map +0 -1
- package/dist/esm/account/EphemeralKeyPair.d.mts +0 -165
- package/dist/esm/account/EphemeralKeyPair.mjs +0 -2
- package/dist/esm/account/EphemeralKeyPair.mjs.map +0 -1
- package/dist/esm/account/FederatedKeylessAccount.d.mts +0 -118
- package/dist/esm/account/FederatedKeylessAccount.mjs +0 -2
- package/dist/esm/account/FederatedKeylessAccount.mjs.map +0 -1
- package/dist/esm/account/KeylessAccount.d.mts +0 -124
- package/dist/esm/account/KeylessAccount.mjs +0 -2
- package/dist/esm/account/KeylessAccount.mjs.map +0 -1
- package/dist/esm/account/MultiEd25519Account.d.mts +0 -102
- package/dist/esm/account/MultiEd25519Account.mjs +0 -2
- package/dist/esm/account/MultiEd25519Account.mjs.map +0 -1
- package/dist/esm/account/MultiKeyAccount.d.mts +0 -206
- package/dist/esm/account/MultiKeyAccount.mjs +0 -2
- package/dist/esm/account/MultiKeyAccount.mjs.map +0 -1
- package/dist/esm/account/SingleKeyAccount.d.mts +0 -8
- package/dist/esm/account/SingleKeyAccount.mjs +0 -2
- package/dist/esm/account/SingleKeyAccount.mjs.map +0 -1
- package/dist/esm/account/index.d.mts +0 -24
- package/dist/esm/account/index.mjs +0 -2
- package/dist/esm/account/index.mjs.map +0 -1
- package/dist/esm/account/utils.d.mts +0 -14
- package/dist/esm/account/utils.mjs +0 -2
- package/dist/esm/account/utils.mjs.map +0 -1
- package/dist/esm/account-sIOs_9XJ.d.mts +0 -7369
- package/dist/esm/api/account/abstraction.d.mts +0 -181
- package/dist/esm/api/account/abstraction.mjs +0 -2
- package/dist/esm/api/account/abstraction.mjs.map +0 -1
- package/dist/esm/api/account.d.mts +0 -852
- package/dist/esm/api/account.mjs +0 -2
- package/dist/esm/api/account.mjs.map +0 -1
- package/dist/esm/api/ans.d.mts +0 -570
- package/dist/esm/api/ans.mjs +0 -2
- package/dist/esm/api/ans.mjs.map +0 -1
- package/dist/esm/api/aptos.d.mts +0 -114
- package/dist/esm/api/aptos.mjs +0 -2
- package/dist/esm/api/aptos.mjs.map +0 -1
- package/dist/esm/api/aptosConfig.d.mts +0 -7
- package/dist/esm/api/aptosConfig.mjs +0 -2
- package/dist/esm/api/aptosConfig.mjs.map +0 -1
- package/dist/esm/api/coin.d.mts +0 -81
- package/dist/esm/api/coin.mjs +0 -2
- package/dist/esm/api/coin.mjs.map +0 -1
- package/dist/esm/api/digitalAsset.d.mts +0 -1030
- package/dist/esm/api/digitalAsset.mjs +0 -2
- package/dist/esm/api/digitalAsset.mjs.map +0 -1
- package/dist/esm/api/faucet.d.mts +0 -80
- package/dist/esm/api/faucet.mjs +0 -2
- package/dist/esm/api/faucet.mjs.map +0 -1
- package/dist/esm/api/fungibleAsset.d.mts +0 -288
- package/dist/esm/api/fungibleAsset.mjs +0 -2
- package/dist/esm/api/fungibleAsset.mjs.map +0 -1
- package/dist/esm/api/general.d.mts +0 -303
- package/dist/esm/api/general.mjs +0 -2
- package/dist/esm/api/general.mjs.map +0 -1
- package/dist/esm/api/index.d.mts +0 -47
- package/dist/esm/api/index.mjs +0 -2
- package/dist/esm/api/index.mjs.map +0 -1
- package/dist/esm/api/keyless.d.mts +0 -170
- package/dist/esm/api/keyless.mjs +0 -2
- package/dist/esm/api/keyless.mjs.map +0 -1
- package/dist/esm/api/object.d.mts +0 -80
- package/dist/esm/api/object.mjs +0 -2
- package/dist/esm/api/object.mjs.map +0 -1
- package/dist/esm/api/staking.d.mts +0 -134
- package/dist/esm/api/staking.mjs +0 -2
- package/dist/esm/api/staking.mjs.map +0 -1
- package/dist/esm/api/table.d.mts +0 -169
- package/dist/esm/api/table.mjs +0 -2
- package/dist/esm/api/table.mjs.map +0 -1
- package/dist/esm/api/transaction.d.mts +0 -681
- package/dist/esm/api/transaction.mjs +0 -2
- package/dist/esm/api/transaction.mjs.map +0 -1
- package/dist/esm/api/transactionSubmission/build.d.mts +0 -141
- package/dist/esm/api/transactionSubmission/build.mjs +0 -2
- package/dist/esm/api/transactionSubmission/build.mjs.map +0 -1
- package/dist/esm/api/transactionSubmission/helpers.d.mts +0 -98
- package/dist/esm/api/transactionSubmission/helpers.mjs +0 -2
- package/dist/esm/api/transactionSubmission/helpers.mjs.map +0 -1
- package/dist/esm/api/transactionSubmission/management.d.mts +0 -168
- package/dist/esm/api/transactionSubmission/management.mjs +0 -2
- package/dist/esm/api/transactionSubmission/management.mjs.map +0 -1
- package/dist/esm/api/transactionSubmission/sign.d.mts +0 -124
- package/dist/esm/api/transactionSubmission/sign.mjs +0 -2
- package/dist/esm/api/transactionSubmission/sign.mjs.map +0 -1
- package/dist/esm/api/transactionSubmission/simulate.d.mts +0 -181
- package/dist/esm/api/transactionSubmission/simulate.mjs +0 -2
- package/dist/esm/api/transactionSubmission/simulate.mjs.map +0 -1
- package/dist/esm/api/transactionSubmission/submit.d.mts +0 -142
- package/dist/esm/api/transactionSubmission/submit.mjs +0 -2
- package/dist/esm/api/transactionSubmission/submit.mjs.map +0 -1
- package/dist/esm/api/utils.d.mts +0 -45
- package/dist/esm/api/utils.mjs +0 -2
- package/dist/esm/api/utils.mjs.map +0 -1
- package/dist/esm/bcs/consts.d.mts +0 -28
- package/dist/esm/bcs/consts.mjs +0 -2
- package/dist/esm/bcs/consts.mjs.map +0 -1
- package/dist/esm/bcs/deserializer.d.mts +0 -7
- package/dist/esm/bcs/deserializer.mjs +0 -2
- package/dist/esm/bcs/deserializer.mjs.map +0 -1
- package/dist/esm/bcs/index.d.mts +0 -8
- package/dist/esm/bcs/index.mjs +0 -2
- package/dist/esm/bcs/index.mjs.map +0 -1
- package/dist/esm/bcs/serializable/entryFunctionBytes.d.mts +0 -65
- package/dist/esm/bcs/serializable/entryFunctionBytes.mjs +0 -2
- package/dist/esm/bcs/serializable/entryFunctionBytes.mjs.map +0 -1
- package/dist/esm/bcs/serializable/fixedBytes.d.mts +0 -7
- package/dist/esm/bcs/serializable/fixedBytes.mjs +0 -2
- package/dist/esm/bcs/serializable/fixedBytes.mjs.map +0 -1
- package/dist/esm/bcs/serializable/movePrimitives.d.mts +0 -7
- package/dist/esm/bcs/serializable/movePrimitives.mjs +0 -2
- package/dist/esm/bcs/serializable/movePrimitives.mjs.map +0 -1
- package/dist/esm/bcs/serializable/moveStructs.d.mts +0 -7
- package/dist/esm/bcs/serializable/moveStructs.mjs +0 -2
- package/dist/esm/bcs/serializable/moveStructs.mjs.map +0 -1
- package/dist/esm/bcs/serializer.d.mts +0 -7
- package/dist/esm/bcs/serializer.mjs +0 -2
- package/dist/esm/bcs/serializer.mjs.map +0 -1
- package/dist/esm/chunk-226FBOWQ.mjs +0 -2
- package/dist/esm/chunk-226FBOWQ.mjs.map +0 -1
- package/dist/esm/chunk-2DQRUJUC.mjs +0 -2
- package/dist/esm/chunk-2DQRUJUC.mjs.map +0 -1
- package/dist/esm/chunk-2EBXCCLB.mjs +0 -2
- package/dist/esm/chunk-2EBXCCLB.mjs.map +0 -1
- package/dist/esm/chunk-2YA4KQUV.mjs +0 -2
- package/dist/esm/chunk-2YA4KQUV.mjs.map +0 -1
- package/dist/esm/chunk-3ZC6F5SJ.mjs +0 -2
- package/dist/esm/chunk-3ZC6F5SJ.mjs.map +0 -1
- package/dist/esm/chunk-44MMFX5F.mjs +0 -2
- package/dist/esm/chunk-44MMFX5F.mjs.map +0 -1
- package/dist/esm/chunk-4KEZEYCV.mjs +0 -2
- package/dist/esm/chunk-4KEZEYCV.mjs.map +0 -1
- package/dist/esm/chunk-4QMXOWHP.mjs +0 -1
- package/dist/esm/chunk-4QMXOWHP.mjs.map +0 -1
- package/dist/esm/chunk-4WPQQPUF.mjs +0 -1
- package/dist/esm/chunk-4WPQQPUF.mjs.map +0 -1
- package/dist/esm/chunk-5HXLZHDW.mjs +0 -1
- package/dist/esm/chunk-5HXLZHDW.mjs.map +0 -1
- package/dist/esm/chunk-6T2OBPIF.mjs +0 -4
- package/dist/esm/chunk-6T2OBPIF.mjs.map +0 -1
- package/dist/esm/chunk-7ECCT6PK.mjs +0 -1
- package/dist/esm/chunk-7ECCT6PK.mjs.map +0 -1
- package/dist/esm/chunk-A5H5VKUI.mjs +0 -2
- package/dist/esm/chunk-A5H5VKUI.mjs.map +0 -1
- package/dist/esm/chunk-A5L76YP7.mjs +0 -2
- package/dist/esm/chunk-A5L76YP7.mjs.map +0 -1
- package/dist/esm/chunk-C3Q23D22.mjs +0 -2
- package/dist/esm/chunk-C3Q23D22.mjs.map +0 -1
- package/dist/esm/chunk-DE5K76I2.mjs +0 -1
- package/dist/esm/chunk-DE5K76I2.mjs.map +0 -1
- package/dist/esm/chunk-DPHBSAZQ.mjs +0 -2
- package/dist/esm/chunk-DPHBSAZQ.mjs.map +0 -1
- package/dist/esm/chunk-F45HI7LU.mjs +0 -2
- package/dist/esm/chunk-F45HI7LU.mjs.map +0 -1
- package/dist/esm/chunk-F4RJMSAW.mjs +0 -2
- package/dist/esm/chunk-F4RJMSAW.mjs.map +0 -1
- package/dist/esm/chunk-FAOLAKLJ.mjs +0 -2
- package/dist/esm/chunk-FAOLAKLJ.mjs.map +0 -1
- package/dist/esm/chunk-FZY4PMEE.mjs +0 -1
- package/dist/esm/chunk-FZY4PMEE.mjs.map +0 -1
- package/dist/esm/chunk-G3MHXDYA.mjs +0 -1
- package/dist/esm/chunk-G3MHXDYA.mjs.map +0 -1
- package/dist/esm/chunk-G5OONGWS.mjs +0 -488
- package/dist/esm/chunk-G5OONGWS.mjs.map +0 -1
- package/dist/esm/chunk-GJYLYE6R.mjs +0 -2
- package/dist/esm/chunk-GJYLYE6R.mjs.map +0 -1
- package/dist/esm/chunk-GYYSHYO5.mjs +0 -2
- package/dist/esm/chunk-GYYSHYO5.mjs.map +0 -1
- package/dist/esm/chunk-HGLO5LDS.mjs +0 -1
- package/dist/esm/chunk-HGLO5LDS.mjs.map +0 -1
- package/dist/esm/chunk-IEW452EO.mjs +0 -7
- package/dist/esm/chunk-IEW452EO.mjs.map +0 -1
- package/dist/esm/chunk-IF4UU2MT.mjs +0 -2
- package/dist/esm/chunk-IF4UU2MT.mjs.map +0 -1
- package/dist/esm/chunk-ITZN23GU.mjs +0 -2
- package/dist/esm/chunk-ITZN23GU.mjs.map +0 -1
- package/dist/esm/chunk-IZF6POVR.mjs +0 -4
- package/dist/esm/chunk-IZF6POVR.mjs.map +0 -1
- package/dist/esm/chunk-KDMSOCZY.mjs +0 -2
- package/dist/esm/chunk-KDMSOCZY.mjs.map +0 -1
- package/dist/esm/chunk-KKPH2JUV.mjs +0 -2
- package/dist/esm/chunk-KKPH2JUV.mjs.map +0 -1
- package/dist/esm/chunk-LVZ7QMUH.mjs +0 -2
- package/dist/esm/chunk-LVZ7QMUH.mjs.map +0 -1
- package/dist/esm/chunk-M65PXVDO.mjs +0 -2
- package/dist/esm/chunk-M65PXVDO.mjs.map +0 -1
- package/dist/esm/chunk-MKTR4U2R.mjs +0 -2
- package/dist/esm/chunk-MKTR4U2R.mjs.map +0 -1
- package/dist/esm/chunk-NECL5FCQ.mjs +0 -1
- package/dist/esm/chunk-NECL5FCQ.mjs.map +0 -1
- package/dist/esm/chunk-NHRPXEUE.mjs +0 -2
- package/dist/esm/chunk-NHRPXEUE.mjs.map +0 -1
- package/dist/esm/chunk-NNXTS2GB.mjs +0 -2
- package/dist/esm/chunk-NNXTS2GB.mjs.map +0 -1
- package/dist/esm/chunk-NP2IAUME.mjs +0 -2
- package/dist/esm/chunk-NP2IAUME.mjs.map +0 -1
- package/dist/esm/chunk-NPWYZVHE.mjs +0 -2
- package/dist/esm/chunk-NPWYZVHE.mjs.map +0 -1
- package/dist/esm/chunk-NTMFADQ7.mjs +0 -2
- package/dist/esm/chunk-NTMFADQ7.mjs.map +0 -1
- package/dist/esm/chunk-ODNZJSOC.mjs +0 -2
- package/dist/esm/chunk-ODNZJSOC.mjs.map +0 -1
- package/dist/esm/chunk-P5HCJN3A.mjs +0 -2
- package/dist/esm/chunk-P5HCJN3A.mjs.map +0 -1
- package/dist/esm/chunk-Q5ESW36C.mjs +0 -2
- package/dist/esm/chunk-Q5ESW36C.mjs.map +0 -1
- package/dist/esm/chunk-QE5MOGUI.mjs +0 -2
- package/dist/esm/chunk-QE5MOGUI.mjs.map +0 -1
- package/dist/esm/chunk-RB2GC7FW.mjs +0 -2
- package/dist/esm/chunk-RB2GC7FW.mjs.map +0 -1
- package/dist/esm/chunk-RUKFK3OC.mjs +0 -2
- package/dist/esm/chunk-RUKFK3OC.mjs.map +0 -1
- package/dist/esm/chunk-RYCI4VKO.mjs +0 -2
- package/dist/esm/chunk-RYCI4VKO.mjs.map +0 -1
- package/dist/esm/chunk-RZNP3WG4.mjs +0 -2
- package/dist/esm/chunk-RZNP3WG4.mjs.map +0 -1
- package/dist/esm/chunk-STY74NUA.mjs +0 -2
- package/dist/esm/chunk-STY74NUA.mjs.map +0 -1
- package/dist/esm/chunk-TAHLOBRG.mjs +0 -2
- package/dist/esm/chunk-TAHLOBRG.mjs.map +0 -1
- package/dist/esm/chunk-TBIK7DML.mjs +0 -2
- package/dist/esm/chunk-TBIK7DML.mjs.map +0 -1
- package/dist/esm/chunk-UVJW4DPP.mjs +0 -2
- package/dist/esm/chunk-UVJW4DPP.mjs.map +0 -1
- package/dist/esm/chunk-UVNAHETD.mjs +0 -2
- package/dist/esm/chunk-UVNAHETD.mjs.map +0 -1
- package/dist/esm/chunk-UYVPNUH3.mjs +0 -1
- package/dist/esm/chunk-UYVPNUH3.mjs.map +0 -1
- package/dist/esm/chunk-V3MBJJTL.mjs +0 -1
- package/dist/esm/chunk-V3MBJJTL.mjs.map +0 -1
- package/dist/esm/chunk-WOPHK7LB.mjs +0 -2
- package/dist/esm/chunk-WOPHK7LB.mjs.map +0 -1
- package/dist/esm/chunk-WZZ7PJ3X.mjs +0 -2
- package/dist/esm/chunk-WZZ7PJ3X.mjs.map +0 -1
- package/dist/esm/chunk-X2TPNKLV.mjs +0 -2
- package/dist/esm/chunk-X2TPNKLV.mjs.map +0 -1
- package/dist/esm/chunk-ZOSOF6ST.mjs +0 -2
- package/dist/esm/chunk-ZOSOF6ST.mjs.map +0 -1
- package/dist/esm/chunk-ZP4DWSQA.mjs +0 -2
- package/dist/esm/chunk-ZP4DWSQA.mjs.map +0 -1
- package/dist/esm/cli/index.d.mts +0 -10
- package/dist/esm/cli/index.mjs +0 -2
- package/dist/esm/cli/index.mjs.map +0 -1
- package/dist/esm/cli/localNode.d.mts +0 -67
- package/dist/esm/cli/localNode.mjs +0 -2
- package/dist/esm/cli/localNode.mjs.map +0 -1
- package/dist/esm/cli/move.d.mts +0 -257
- package/dist/esm/cli/move.mjs +0 -2
- package/dist/esm/cli/move.mjs.map +0 -1
- package/dist/esm/client/core.d.mts +0 -43
- package/dist/esm/client/core.mjs +0 -2
- package/dist/esm/client/core.mjs.map +0 -1
- package/dist/esm/client/get.d.mts +0 -125
- package/dist/esm/client/get.mjs +0 -2
- package/dist/esm/client/get.mjs.map +0 -1
- package/dist/esm/client/index.d.mts +0 -10
- package/dist/esm/client/index.mjs +0 -2
- package/dist/esm/client/index.mjs.map +0 -1
- package/dist/esm/client/post.d.mts +0 -161
- package/dist/esm/client/post.mjs +0 -2
- package/dist/esm/client/post.mjs.map +0 -1
- package/dist/esm/core/account/index.d.mts +0 -8
- package/dist/esm/core/account/index.mjs +0 -2
- package/dist/esm/core/account/index.mjs.map +0 -1
- package/dist/esm/core/account/utils/address.d.mts +0 -55
- package/dist/esm/core/account/utils/address.mjs +0 -2
- package/dist/esm/core/account/utils/address.mjs.map +0 -1
- package/dist/esm/core/account/utils/index.d.mts +0 -8
- package/dist/esm/core/account/utils/index.mjs +0 -2
- package/dist/esm/core/account/utils/index.mjs.map +0 -1
- package/dist/esm/core/accountAddress.d.mts +0 -7
- package/dist/esm/core/accountAddress.mjs +0 -2
- package/dist/esm/core/accountAddress.mjs.map +0 -1
- package/dist/esm/core/authenticationKey.d.mts +0 -7
- package/dist/esm/core/authenticationKey.mjs +0 -2
- package/dist/esm/core/authenticationKey.mjs.map +0 -1
- package/dist/esm/core/common.d.mts +0 -52
- package/dist/esm/core/common.mjs +0 -2
- package/dist/esm/core/common.mjs.map +0 -1
- package/dist/esm/core/crypto/abstraction.d.mts +0 -24
- package/dist/esm/core/crypto/abstraction.mjs +0 -2
- package/dist/esm/core/crypto/abstraction.mjs.map +0 -1
- package/dist/esm/core/crypto/deserializationUtils.d.mts +0 -28
- package/dist/esm/core/crypto/deserializationUtils.mjs +0 -2
- package/dist/esm/core/crypto/deserializationUtils.mjs.map +0 -1
- package/dist/esm/core/crypto/ed25519.d.mts +0 -7
- package/dist/esm/core/crypto/ed25519.mjs +0 -2
- package/dist/esm/core/crypto/ed25519.mjs.map +0 -1
- package/dist/esm/core/crypto/ephemeral.d.mts +0 -116
- package/dist/esm/core/crypto/ephemeral.mjs +0 -2
- package/dist/esm/core/crypto/ephemeral.mjs.map +0 -1
- package/dist/esm/core/crypto/federatedKeyless.d.mts +0 -13
- package/dist/esm/core/crypto/federatedKeyless.mjs +0 -2
- package/dist/esm/core/crypto/federatedKeyless.mjs.map +0 -1
- package/dist/esm/core/crypto/hdKey.d.mts +0 -95
- package/dist/esm/core/crypto/hdKey.mjs +0 -2
- package/dist/esm/core/crypto/hdKey.mjs.map +0 -1
- package/dist/esm/core/crypto/index.d.mts +0 -19
- package/dist/esm/core/crypto/index.mjs +0 -2
- package/dist/esm/core/crypto/index.mjs.map +0 -1
- package/dist/esm/core/crypto/keyless.d.mts +0 -13
- package/dist/esm/core/crypto/keyless.mjs +0 -2
- package/dist/esm/core/crypto/keyless.mjs.map +0 -1
- package/dist/esm/core/crypto/multiEd25519.d.mts +0 -7
- package/dist/esm/core/crypto/multiEd25519.mjs +0 -2
- package/dist/esm/core/crypto/multiEd25519.mjs.map +0 -1
- package/dist/esm/core/crypto/multiKey.d.mts +0 -7
- package/dist/esm/core/crypto/multiKey.mjs +0 -2
- package/dist/esm/core/crypto/multiKey.mjs.map +0 -1
- package/dist/esm/core/crypto/poseidon.d.mts +0 -59
- package/dist/esm/core/crypto/poseidon.mjs +0 -2
- package/dist/esm/core/crypto/poseidon.mjs.map +0 -1
- package/dist/esm/core/crypto/privateKey.d.mts +0 -7
- package/dist/esm/core/crypto/privateKey.mjs +0 -2
- package/dist/esm/core/crypto/privateKey.mjs.map +0 -1
- package/dist/esm/core/crypto/proof.d.mts +0 -18
- package/dist/esm/core/crypto/proof.mjs +0 -2
- package/dist/esm/core/crypto/proof.mjs.map +0 -1
- package/dist/esm/core/crypto/publicKey.d.mts +0 -7
- package/dist/esm/core/crypto/publicKey.mjs +0 -2
- package/dist/esm/core/crypto/publicKey.mjs.map +0 -1
- package/dist/esm/core/crypto/secp256k1.d.mts +0 -7
- package/dist/esm/core/crypto/secp256k1.mjs +0 -2
- package/dist/esm/core/crypto/secp256k1.mjs.map +0 -1
- package/dist/esm/core/crypto/secp256r1.d.mts +0 -306
- package/dist/esm/core/crypto/secp256r1.mjs +0 -2
- package/dist/esm/core/crypto/secp256r1.mjs.map +0 -1
- package/dist/esm/core/crypto/signature.d.mts +0 -7
- package/dist/esm/core/crypto/signature.mjs +0 -2
- package/dist/esm/core/crypto/signature.mjs.map +0 -1
- package/dist/esm/core/crypto/singleKey.d.mts +0 -7
- package/dist/esm/core/crypto/singleKey.mjs +0 -2
- package/dist/esm/core/crypto/singleKey.mjs.map +0 -1
- package/dist/esm/core/crypto/types.d.mts +0 -11
- package/dist/esm/core/crypto/types.mjs +0 -2
- package/dist/esm/core/crypto/types.mjs.map +0 -1
- package/dist/esm/core/crypto/utils.d.mts +0 -23
- package/dist/esm/core/crypto/utils.mjs +0 -2
- package/dist/esm/core/crypto/utils.mjs.map +0 -1
- package/dist/esm/core/hex.d.mts +0 -7
- package/dist/esm/core/hex.mjs +0 -2
- package/dist/esm/core/hex.mjs.map +0 -1
- package/dist/esm/core/index.d.mts +0 -20
- package/dist/esm/core/index.mjs +0 -2
- package/dist/esm/core/index.mjs.map +0 -1
- package/dist/esm/errors/index.d.mts +0 -131
- package/dist/esm/errors/index.mjs +0 -2
- package/dist/esm/errors/index.mjs.map +0 -1
- package/dist/esm/federatedKeyless-Cuo0IGJ6.d.mts +0 -880
- package/dist/esm/index.d.mts +0 -72
- package/dist/esm/index.mjs +0 -2
- package/dist/esm/index.mjs.map +0 -1
- package/dist/esm/internal/abstraction.d.mts +0 -27
- package/dist/esm/internal/abstraction.mjs +0 -2
- package/dist/esm/internal/abstraction.mjs.map +0 -1
- package/dist/esm/internal/account.d.mts +0 -453
- package/dist/esm/internal/account.mjs +0 -2
- package/dist/esm/internal/account.mjs.map +0 -1
- package/dist/esm/internal/ans.d.mts +0 -417
- package/dist/esm/internal/ans.mjs +0 -2
- package/dist/esm/internal/ans.mjs.map +0 -1
- package/dist/esm/internal/coin.d.mts +0 -31
- package/dist/esm/internal/coin.mjs +0 -2
- package/dist/esm/internal/coin.mjs.map +0 -1
- package/dist/esm/internal/digitalAsset.d.mts +0 -580
- package/dist/esm/internal/digitalAsset.mjs +0 -2
- package/dist/esm/internal/digitalAsset.mjs.map +0 -1
- package/dist/esm/internal/faucet.d.mts +0 -42
- package/dist/esm/internal/faucet.mjs +0 -2
- package/dist/esm/internal/faucet.mjs.map +0 -1
- package/dist/esm/internal/fungibleAsset.d.mts +0 -112
- package/dist/esm/internal/fungibleAsset.mjs +0 -2
- package/dist/esm/internal/fungibleAsset.mjs.map +0 -1
- package/dist/esm/internal/general.d.mts +0 -94
- package/dist/esm/internal/general.mjs +0 -2
- package/dist/esm/internal/general.mjs.map +0 -1
- package/dist/esm/internal/keyless.d.mts +0 -111
- package/dist/esm/internal/keyless.mjs +0 -2
- package/dist/esm/internal/keyless.mjs.map +0 -1
- package/dist/esm/internal/object.d.mts +0 -42
- package/dist/esm/internal/object.mjs +0 -2
- package/dist/esm/internal/object.mjs.map +0 -1
- package/dist/esm/internal/staking.d.mts +0 -60
- package/dist/esm/internal/staking.mjs +0 -2
- package/dist/esm/internal/staking.mjs.map +0 -1
- package/dist/esm/internal/table.d.mts +0 -66
- package/dist/esm/internal/table.mjs +0 -2
- package/dist/esm/internal/table.mjs.map +0 -1
- package/dist/esm/internal/transaction.d.mts +0 -199
- package/dist/esm/internal/transaction.mjs +0 -2
- package/dist/esm/internal/transaction.mjs.map +0 -1
- package/dist/esm/internal/transactionSubmission.d.mts +0 -165
- package/dist/esm/internal/transactionSubmission.mjs +0 -2
- package/dist/esm/internal/transactionSubmission.mjs.map +0 -1
- package/dist/esm/internal/utils/index.d.mts +0 -8
- package/dist/esm/internal/utils/index.mjs +0 -2
- package/dist/esm/internal/utils/index.mjs.map +0 -1
- package/dist/esm/internal/utils/utils.d.mts +0 -41
- package/dist/esm/internal/utils/utils.mjs +0 -2
- package/dist/esm/internal/utils/utils.mjs.map +0 -1
- package/dist/esm/internal/view.d.mts +0 -20
- package/dist/esm/internal/view.mjs +0 -2
- package/dist/esm/internal/view.mjs.map +0 -1
- package/dist/esm/transactions/authenticator/account.d.mts +0 -7
- package/dist/esm/transactions/authenticator/account.mjs +0 -2
- package/dist/esm/transactions/authenticator/account.mjs.map +0 -1
- package/dist/esm/transactions/authenticator/index.d.mts +0 -8
- package/dist/esm/transactions/authenticator/index.mjs +0 -2
- package/dist/esm/transactions/authenticator/index.mjs.map +0 -1
- package/dist/esm/transactions/authenticator/transaction.d.mts +0 -152
- package/dist/esm/transactions/authenticator/transaction.mjs +0 -2
- package/dist/esm/transactions/authenticator/transaction.mjs.map +0 -1
- package/dist/esm/transactions/index.d.mts +0 -15
- package/dist/esm/transactions/index.mjs +0 -2
- package/dist/esm/transactions/index.mjs.map +0 -1
- package/dist/esm/transactions/instances/chainId.d.mts +0 -7
- package/dist/esm/transactions/instances/chainId.mjs +0 -2
- package/dist/esm/transactions/instances/chainId.mjs.map +0 -1
- package/dist/esm/transactions/instances/identifier.d.mts +0 -7
- package/dist/esm/transactions/instances/identifier.mjs +0 -2
- package/dist/esm/transactions/instances/identifier.mjs.map +0 -1
- package/dist/esm/transactions/instances/index.d.mts +0 -10
- package/dist/esm/transactions/instances/index.mjs +0 -2
- package/dist/esm/transactions/instances/index.mjs.map +0 -1
- package/dist/esm/transactions/instances/moduleId.d.mts +0 -7
- package/dist/esm/transactions/instances/moduleId.mjs +0 -2
- package/dist/esm/transactions/instances/moduleId.mjs.map +0 -1
- package/dist/esm/transactions/instances/multiAgentTransaction.d.mts +0 -7
- package/dist/esm/transactions/instances/multiAgentTransaction.mjs +0 -2
- package/dist/esm/transactions/instances/multiAgentTransaction.mjs.map +0 -1
- package/dist/esm/transactions/instances/rawTransaction.d.mts +0 -7
- package/dist/esm/transactions/instances/rawTransaction.mjs +0 -2
- package/dist/esm/transactions/instances/rawTransaction.mjs.map +0 -1
- package/dist/esm/transactions/instances/rotationProofChallenge.d.mts +0 -58
- package/dist/esm/transactions/instances/rotationProofChallenge.mjs +0 -2
- package/dist/esm/transactions/instances/rotationProofChallenge.mjs.map +0 -1
- package/dist/esm/transactions/instances/signedTransaction.d.mts +0 -59
- package/dist/esm/transactions/instances/signedTransaction.mjs +0 -2
- package/dist/esm/transactions/instances/signedTransaction.mjs.map +0 -1
- package/dist/esm/transactions/instances/simpleTransaction.d.mts +0 -7
- package/dist/esm/transactions/instances/simpleTransaction.mjs +0 -2
- package/dist/esm/transactions/instances/simpleTransaction.mjs.map +0 -1
- package/dist/esm/transactions/instances/transactionArgument.d.mts +0 -7
- package/dist/esm/transactions/instances/transactionArgument.mjs +0 -2
- package/dist/esm/transactions/instances/transactionArgument.mjs.map +0 -1
- package/dist/esm/transactions/instances/transactionPayload.d.mts +0 -7
- package/dist/esm/transactions/instances/transactionPayload.mjs +0 -2
- package/dist/esm/transactions/instances/transactionPayload.mjs.map +0 -1
- package/dist/esm/transactions/management/accountSequenceNumber.d.mts +0 -123
- package/dist/esm/transactions/management/accountSequenceNumber.mjs +0 -2
- package/dist/esm/transactions/management/accountSequenceNumber.mjs.map +0 -1
- package/dist/esm/transactions/management/asyncQueue.d.mts +0 -77
- package/dist/esm/transactions/management/asyncQueue.mjs +0 -2
- package/dist/esm/transactions/management/asyncQueue.mjs.map +0 -1
- package/dist/esm/transactions/management/index.d.mts +0 -12
- package/dist/esm/transactions/management/index.mjs +0 -2
- package/dist/esm/transactions/management/index.mjs.map +0 -1
- package/dist/esm/transactions/management/transactionWorker.d.mts +0 -218
- package/dist/esm/transactions/management/transactionWorker.mjs +0 -2
- package/dist/esm/transactions/management/transactionWorker.mjs.map +0 -1
- package/dist/esm/transactions/transactionBuilder/helpers.d.mts +0 -189
- package/dist/esm/transactions/transactionBuilder/helpers.mjs +0 -2
- package/dist/esm/transactions/transactionBuilder/helpers.mjs.map +0 -1
- package/dist/esm/transactions/transactionBuilder/index.d.mts +0 -11
- package/dist/esm/transactions/transactionBuilder/index.mjs +0 -2
- package/dist/esm/transactions/transactionBuilder/index.mjs.map +0 -1
- package/dist/esm/transactions/transactionBuilder/remoteAbi.d.mts +0 -105
- package/dist/esm/transactions/transactionBuilder/remoteAbi.mjs +0 -2
- package/dist/esm/transactions/transactionBuilder/remoteAbi.mjs.map +0 -1
- package/dist/esm/transactions/transactionBuilder/signingMessage.d.mts +0 -62
- package/dist/esm/transactions/transactionBuilder/signingMessage.mjs +0 -2
- package/dist/esm/transactions/transactionBuilder/signingMessage.mjs.map +0 -1
- package/dist/esm/transactions/transactionBuilder/transactionBuilder.d.mts +0 -192
- package/dist/esm/transactions/transactionBuilder/transactionBuilder.mjs +0 -2
- package/dist/esm/transactions/transactionBuilder/transactionBuilder.mjs.map +0 -1
- package/dist/esm/transactions/typeTag/index.d.mts +0 -7
- package/dist/esm/transactions/typeTag/index.mjs +0 -2
- package/dist/esm/transactions/typeTag/index.mjs.map +0 -1
- package/dist/esm/transactions/typeTag/parser.d.mts +0 -81
- package/dist/esm/transactions/typeTag/parser.mjs +0 -2
- package/dist/esm/transactions/typeTag/parser.mjs.map +0 -1
- package/dist/esm/transactions/types.d.mts +0 -7
- package/dist/esm/transactions/types.mjs +0 -2
- package/dist/esm/transactions/types.mjs.map +0 -1
- package/dist/esm/types/abstraction.d.mts +0 -15
- package/dist/esm/types/abstraction.mjs +0 -2
- package/dist/esm/types/abstraction.mjs.map +0 -1
- package/dist/esm/types/ans.d.mts +0 -109
- package/dist/esm/types/ans.mjs +0 -2
- package/dist/esm/types/ans.mjs.map +0 -1
- package/dist/esm/types/generated/operations.d.mts +0 -703
- package/dist/esm/types/generated/operations.mjs +0 -1
- package/dist/esm/types/generated/operations.mjs.map +0 -1
- package/dist/esm/types/generated/queries.d.mts +0 -66
- package/dist/esm/types/generated/queries.mjs +0 -2
- package/dist/esm/types/generated/queries.mjs.map +0 -1
- package/dist/esm/types/generated/types.d.mts +0 -9679
- package/dist/esm/types/generated/types.mjs +0 -2
- package/dist/esm/types/generated/types.mjs.map +0 -1
- package/dist/esm/types/index.d.mts +0 -8
- package/dist/esm/types/index.mjs +0 -2
- package/dist/esm/types/index.mjs.map +0 -1
- package/dist/esm/types/indexer.d.mts +0 -186
- package/dist/esm/types/indexer.mjs +0 -2
- package/dist/esm/types/indexer.mjs.map +0 -1
- package/dist/esm/types/keyless.d.mts +0 -102
- package/dist/esm/types/keyless.mjs +0 -1
- package/dist/esm/types/keyless.mjs.map +0 -1
- package/dist/esm/types/types.d.mts +0 -7
- package/dist/esm/types/types.mjs +0 -2
- package/dist/esm/types/types.mjs.map +0 -1
- package/dist/esm/utils/apiEndpoints.d.mts +0 -51
- package/dist/esm/utils/apiEndpoints.mjs +0 -2
- package/dist/esm/utils/apiEndpoints.mjs.map +0 -1
- package/dist/esm/utils/const.d.mts +0 -104
- package/dist/esm/utils/const.mjs +0 -2
- package/dist/esm/utils/const.mjs.map +0 -1
- package/dist/esm/utils/helpers.d.mts +0 -193
- package/dist/esm/utils/helpers.mjs +0 -2
- package/dist/esm/utils/helpers.mjs.map +0 -1
- package/dist/esm/utils/index.d.mts +0 -9
- package/dist/esm/utils/index.mjs +0 -2
- package/dist/esm/utils/index.mjs.map +0 -1
- package/dist/esm/utils/memoize.d.mts +0 -48
- package/dist/esm/utils/memoize.mjs +0 -2
- package/dist/esm/utils/memoize.mjs.map +0 -1
- package/dist/esm/utils/normalizeBundle.d.mts +0 -35
- package/dist/esm/utils/normalizeBundle.mjs +0 -2
- package/dist/esm/utils/normalizeBundle.mjs.map +0 -1
- package/dist/esm/version.d.mts +0 -8
- package/dist/esm/version.mjs +0 -2
- package/dist/esm/version.mjs.map +0 -1
|
@@ -0,0 +1,311 @@
|
|
|
1
|
+
// Copyright © Aptos Foundation
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
import { getChainTopUserTransactions, getIndexerLastSuccessVersion, getLedgerInfo, getProcessorStatus, queryIndexer, } from "../internal/general.js";
|
|
4
|
+
import { getBlockByHeight, getBlockByVersion } from "../internal/transaction.js";
|
|
5
|
+
import { view, viewJson } from "../internal/view.js";
|
|
6
|
+
/**
|
|
7
|
+
* A class to query various Aptos-related information and perform operations on the Aptos blockchain.
|
|
8
|
+
* @group General
|
|
9
|
+
*/
|
|
10
|
+
export class General {
|
|
11
|
+
config;
|
|
12
|
+
/**
|
|
13
|
+
* Initializes a new instance of the Aptos client with the specified configuration.
|
|
14
|
+
* This allows users to interact with the Aptos blockchain using the provided settings.
|
|
15
|
+
*
|
|
16
|
+
* @param config - The configuration settings for the Aptos client.
|
|
17
|
+
* @param config.network - The network to connect to (e.g., TESTNET, MAINNET).
|
|
18
|
+
* @param config.nodeUrl - The URL of the Aptos node to connect to.
|
|
19
|
+
*
|
|
20
|
+
* @example
|
|
21
|
+
* ```typescript
|
|
22
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
23
|
+
*
|
|
24
|
+
* async function runExample() {
|
|
25
|
+
* // Create a configuration for the Aptos client
|
|
26
|
+
* const config = new AptosConfig({
|
|
27
|
+
* network: Network.TESTNET, // specify the network
|
|
28
|
+
* nodeUrl: "https://testnet.aptos.dev" // specify the node URL
|
|
29
|
+
* });
|
|
30
|
+
*
|
|
31
|
+
* // Initialize the Aptos client with the configuration
|
|
32
|
+
* const aptos = new Aptos(config);
|
|
33
|
+
*
|
|
34
|
+
* console.log("Aptos client initialized:", aptos);
|
|
35
|
+
* }
|
|
36
|
+
* runExample().catch(console.error);
|
|
37
|
+
* ```
|
|
38
|
+
* @group General
|
|
39
|
+
*/
|
|
40
|
+
constructor(config) {
|
|
41
|
+
this.config = config;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Queries for the Aptos ledger information.
|
|
45
|
+
*
|
|
46
|
+
* @returns The Aptos Ledger Info, which includes details such as chain ID, epoch, and ledger version.
|
|
47
|
+
*
|
|
48
|
+
* @example
|
|
49
|
+
* ```typescript
|
|
50
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
51
|
+
*
|
|
52
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
53
|
+
* const aptos = new Aptos(config);
|
|
54
|
+
*
|
|
55
|
+
* async function runExample() {
|
|
56
|
+
* // Fetching the ledger information
|
|
57
|
+
* const ledgerInfo = await aptos.getLedgerInfo();
|
|
58
|
+
*
|
|
59
|
+
* console.log(ledgerInfo);
|
|
60
|
+
* }
|
|
61
|
+
* runExample().catch(console.error);
|
|
62
|
+
* ```
|
|
63
|
+
* @group General
|
|
64
|
+
*/
|
|
65
|
+
async getLedgerInfo() {
|
|
66
|
+
return getLedgerInfo({ aptosConfig: this.config });
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Retrieves the chain ID of the Aptos blockchain.
|
|
70
|
+
*
|
|
71
|
+
* @example
|
|
72
|
+
* ```typescript
|
|
73
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
74
|
+
*
|
|
75
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
76
|
+
* const aptos = new Aptos(config);
|
|
77
|
+
*
|
|
78
|
+
* async function runExample() {
|
|
79
|
+
* // Fetching the chain ID
|
|
80
|
+
* const chainId = await aptos.getChainId();
|
|
81
|
+
* console.log("Chain ID:", chainId);
|
|
82
|
+
* }
|
|
83
|
+
* runExample().catch(console.error);
|
|
84
|
+
*
|
|
85
|
+
* @returns The chain ID of the Aptos blockchain.
|
|
86
|
+
* ```
|
|
87
|
+
* @group General
|
|
88
|
+
*/
|
|
89
|
+
async getChainId() {
|
|
90
|
+
const result = await this.getLedgerInfo();
|
|
91
|
+
return result.chain_id;
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* Retrieves block information by the specified ledger version.
|
|
95
|
+
*
|
|
96
|
+
* @param args - The arguments for retrieving the block.
|
|
97
|
+
* @param args.ledgerVersion - The ledger version to lookup block information for.
|
|
98
|
+
* @param args.options - Optional parameters for the request.
|
|
99
|
+
* @param args.options.withTransactions - If set to true, include all transactions in the block.
|
|
100
|
+
*
|
|
101
|
+
* @returns Block information with optional transactions.
|
|
102
|
+
*
|
|
103
|
+
* @example
|
|
104
|
+
* ```typescript
|
|
105
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
106
|
+
*
|
|
107
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
108
|
+
* const aptos = new Aptos(config);
|
|
109
|
+
*
|
|
110
|
+
* async function runExample() {
|
|
111
|
+
* // Retrieve block information for a specific ledger version
|
|
112
|
+
* const block = await aptos.getBlockByVersion({ ledgerVersion: 5 });
|
|
113
|
+
* console.log(block);
|
|
114
|
+
* }
|
|
115
|
+
* runExample().catch(console.error);
|
|
116
|
+
* ```
|
|
117
|
+
* @group General
|
|
118
|
+
*/
|
|
119
|
+
async getBlockByVersion(args) {
|
|
120
|
+
return getBlockByVersion({
|
|
121
|
+
aptosConfig: this.config,
|
|
122
|
+
...args,
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
/**
|
|
126
|
+
* Retrieve a block by its height, allowing for the inclusion of transactions if specified.
|
|
127
|
+
*
|
|
128
|
+
* @param args - The parameters for the block retrieval.
|
|
129
|
+
* @param args.blockHeight - The block height to look up, starting at 0.
|
|
130
|
+
* @param args.options - Optional settings for the retrieval.
|
|
131
|
+
* @param args.options.withTransactions - If set to true, includes all transactions in the block.
|
|
132
|
+
*
|
|
133
|
+
* @returns The block with optional transactions included.
|
|
134
|
+
*
|
|
135
|
+
* @example
|
|
136
|
+
* ```typescript
|
|
137
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
138
|
+
*
|
|
139
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
140
|
+
* const aptos = new Aptos(config);
|
|
141
|
+
*
|
|
142
|
+
* async function runExample() {
|
|
143
|
+
* // Retrieve the block at height 5, including transactions
|
|
144
|
+
* const block = await aptos.getBlockByHeight({ blockHeight: 5, options: { withTransactions: true } });
|
|
145
|
+
* console.log(block);
|
|
146
|
+
* }
|
|
147
|
+
* runExample().catch(console.error);
|
|
148
|
+
* ```
|
|
149
|
+
* @group General
|
|
150
|
+
*/
|
|
151
|
+
async getBlockByHeight(args) {
|
|
152
|
+
return getBlockByHeight({ aptosConfig: this.config, ...args });
|
|
153
|
+
}
|
|
154
|
+
/**
|
|
155
|
+
* Queries for a Move view function
|
|
156
|
+
* @param args.payload Payload for the view function
|
|
157
|
+
* @param args.options.ledgerVersion The ledger version to query, if not provided it will get the latest version
|
|
158
|
+
*
|
|
159
|
+
* @example
|
|
160
|
+
* const data = await aptos.view({
|
|
161
|
+
* payload: {
|
|
162
|
+
* function: "0x1::coin::balance",
|
|
163
|
+
* typeArguments: ["0x1::aptos_coin::AptosCoin"],
|
|
164
|
+
* functionArguments: [accountAddress],
|
|
165
|
+
* }
|
|
166
|
+
* })
|
|
167
|
+
*
|
|
168
|
+
* @returns an array of Move values
|
|
169
|
+
* @group General
|
|
170
|
+
*/
|
|
171
|
+
async view(args) {
|
|
172
|
+
return view({ aptosConfig: this.config, ...args });
|
|
173
|
+
}
|
|
174
|
+
/**
|
|
175
|
+
* Queries for a Move view function with JSON, this provides compatability with the old `aptos` package
|
|
176
|
+
* @param args.payload Payload for the view function
|
|
177
|
+
* @param args.options.ledgerVersion The ledger version to query, if not provided it will get the latest version
|
|
178
|
+
*
|
|
179
|
+
* @example
|
|
180
|
+
* const data = await aptos.view({
|
|
181
|
+
* payload: {
|
|
182
|
+
* function: "0x1::coin::balance",
|
|
183
|
+
* typeArguments: ["0x1::aptos_coin::AptosCoin"],
|
|
184
|
+
* functionArguments: [accountAddress.toString()],
|
|
185
|
+
* }
|
|
186
|
+
* })
|
|
187
|
+
*
|
|
188
|
+
* @returns an array of Move values
|
|
189
|
+
* @group General
|
|
190
|
+
*/
|
|
191
|
+
async viewJson(args) {
|
|
192
|
+
return viewJson({ aptosConfig: this.config, ...args });
|
|
193
|
+
}
|
|
194
|
+
/**
|
|
195
|
+
* Queries the top user transactions based on the specified limit.
|
|
196
|
+
*
|
|
197
|
+
* @param args - The arguments for querying top user transactions.
|
|
198
|
+
* @param args.limit - The number of transactions to return.
|
|
199
|
+
* @returns GetChainTopUserTransactionsResponse
|
|
200
|
+
*
|
|
201
|
+
* @example
|
|
202
|
+
* ```typescript
|
|
203
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
204
|
+
*
|
|
205
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
206
|
+
* const aptos = new Aptos(config);
|
|
207
|
+
*
|
|
208
|
+
* async function runExample() {
|
|
209
|
+
* // Fetch the top user transactions with a limit of 5
|
|
210
|
+
* const topUserTransactions = await aptos.getChainTopUserTransactions({ limit: 5 });
|
|
211
|
+
*
|
|
212
|
+
* console.log(topUserTransactions);
|
|
213
|
+
* }
|
|
214
|
+
* runExample().catch(console.error);
|
|
215
|
+
* ```
|
|
216
|
+
* @group General
|
|
217
|
+
*/
|
|
218
|
+
async getChainTopUserTransactions(args) {
|
|
219
|
+
return getChainTopUserTransactions({
|
|
220
|
+
aptosConfig: this.config,
|
|
221
|
+
...args,
|
|
222
|
+
});
|
|
223
|
+
}
|
|
224
|
+
/**
|
|
225
|
+
* Retrieves data from the Aptos Indexer using a GraphQL query.
|
|
226
|
+
* This function allows you to execute complex queries to fetch specific data from the Aptos blockchain.
|
|
227
|
+
*
|
|
228
|
+
* @param args.query.query - A GraphQL query string.
|
|
229
|
+
* @param args.query.variables - The variables for the query (optional).
|
|
230
|
+
*
|
|
231
|
+
* @return The provided T type.
|
|
232
|
+
*
|
|
233
|
+
* @example
|
|
234
|
+
* ```typescript
|
|
235
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
236
|
+
*
|
|
237
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
238
|
+
* const aptos = new Aptos(config);
|
|
239
|
+
*
|
|
240
|
+
* async function runExample() {
|
|
241
|
+
* // Querying the Aptos Indexer for ledger information
|
|
242
|
+
* const topUserTransactions = await aptos.queryIndexer({
|
|
243
|
+
* query: { query: `query MyQuery {
|
|
244
|
+
* ledger_infos {
|
|
245
|
+
* chain_id
|
|
246
|
+
* }
|
|
247
|
+
* }`}
|
|
248
|
+
* });
|
|
249
|
+
*
|
|
250
|
+
* console.log(topUserTransactions);
|
|
251
|
+
* }
|
|
252
|
+
* runExample().catch(console.error);
|
|
253
|
+
* ```
|
|
254
|
+
* @group General
|
|
255
|
+
*/
|
|
256
|
+
async queryIndexer(args) {
|
|
257
|
+
return queryIndexer({
|
|
258
|
+
aptosConfig: this.config,
|
|
259
|
+
...args,
|
|
260
|
+
});
|
|
261
|
+
}
|
|
262
|
+
/**
|
|
263
|
+
* Queries for the last successful indexer version, providing insight into the ledger version the indexer is updated to, which
|
|
264
|
+
* may lag behind the full nodes.
|
|
265
|
+
*
|
|
266
|
+
* @example
|
|
267
|
+
* ```typescript
|
|
268
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
269
|
+
*
|
|
270
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
271
|
+
* const aptos = new Aptos(config);
|
|
272
|
+
*
|
|
273
|
+
* async function runExample() {
|
|
274
|
+
* // Get the last successful indexer version
|
|
275
|
+
* const version = await aptos.getIndexerLastSuccessVersion();
|
|
276
|
+
* console.log(`Last successful indexer version: ${version}`);
|
|
277
|
+
* }
|
|
278
|
+
* runExample().catch(console.error);
|
|
279
|
+
* ```
|
|
280
|
+
* @group General
|
|
281
|
+
*/
|
|
282
|
+
async getIndexerLastSuccessVersion() {
|
|
283
|
+
return getIndexerLastSuccessVersion({ aptosConfig: this.config });
|
|
284
|
+
}
|
|
285
|
+
/**
|
|
286
|
+
* Query the processor status for a specific processor type.
|
|
287
|
+
*
|
|
288
|
+
* @param processorType The processor type to query.
|
|
289
|
+
* @returns The status of the specified processor type.
|
|
290
|
+
*
|
|
291
|
+
* @example
|
|
292
|
+
* ```typescript
|
|
293
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
294
|
+
*
|
|
295
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
296
|
+
* const aptos = new Aptos(config);
|
|
297
|
+
*
|
|
298
|
+
* async function runExample() {
|
|
299
|
+
* // Get the processor status for the account transactions processor
|
|
300
|
+
* const status = await aptos.getProcessorStatus("account_transactions_processor");
|
|
301
|
+
* console.log(status);
|
|
302
|
+
* }
|
|
303
|
+
* runExample().catch(console.error);
|
|
304
|
+
* ```
|
|
305
|
+
* @group General
|
|
306
|
+
*/
|
|
307
|
+
async getProcessorStatus(processorType) {
|
|
308
|
+
return getProcessorStatus({ aptosConfig: this.config, processorType });
|
|
309
|
+
}
|
|
310
|
+
}
|
|
311
|
+
//# sourceMappingURL=general.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"general.js","sourceRoot":"","sources":["../../src/api/general.ts"],"names":[],"mappings":"AAAA,+BAA+B;AAC/B,sCAAsC;AAGtC,OAAO,EACL,2BAA2B,EAC3B,4BAA4B,EAC5B,aAAa,EACb,kBAAkB,EAClB,YAAY,GACb,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AACjF,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAcrD;;;GAGG;AACH,MAAM,OAAO,OAAO;IACT,MAAM,CAAc;IAE7B;;;;;;;;;;;;;;;;;;;;;;;;;;;OA2BG;IACH,YAAY,MAAmB;QAC7B,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;OAqBG;IACH,KAAK,CAAC,aAAa;QACjB,OAAO,aAAa,CAAC,EAAE,WAAW,EAAE,IAAI,CAAC,MAAM,EAAE,CAAC,CAAC;IACrD,CAAC;IAED;;;;;;;;;;;;;;;;;;;;OAoBG;IACH,KAAK,CAAC,UAAU;QACd,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,aAAa,EAAE,CAAC;QAC1C,OAAO,MAAM,CAAC,QAAQ,CAAC;IACzB,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;;;OAyBG;IACH,KAAK,CAAC,iBAAiB,CAAC,IAGvB;QACC,OAAO,iBAAiB,CAAC;YACvB,WAAW,EAAE,IAAI,CAAC,MAAM;YACxB,GAAG,IAAI;SACR,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;;;OAyBG;IACH,KAAK,CAAC,gBAAgB,CAAC,IAA0E;QAC/F,OAAO,gBAAgB,CAAC,EAAE,WAAW,EAAE,IAAI,CAAC,MAAM,EAAE,GAAG,IAAI,EAAE,CAAC,CAAC;IACjE,CAAC;IAED;;;;;;;;;;;;;;;;OAgBG;IACH,KAAK,CAAC,IAAI,CAA6B,IAGtC;QACC,OAAO,IAAI,CAAI,EAAE,WAAW,EAAE,IAAI,CAAC,MAAM,EAAE,GAAG,IAAI,EAAE,CAAC,CAAC;IACxD,CAAC;IAED;;;;;;;;;;;;;;;;OAgBG;IACH,KAAK,CAAC,QAAQ,CAA6B,IAG1C;QACC,OAAO,QAAQ,CAAI,EAAE,WAAW,EAAE,IAAI,CAAC,MAAM,EAAE,GAAG,IAAI,EAAE,CAAC,CAAC;IAC5D,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;OAuBG;IACH,KAAK,CAAC,2BAA2B,CAAC,IAAuB;QACvD,OAAO,2BAA2B,CAAC;YACjC,WAAW,EAAE,IAAI,CAAC,MAAM;YACxB,GAAG,IAAI;SACR,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA+BG;IACH,KAAK,CAAC,YAAY,CAAe,IAA6B;QAC5D,OAAO,YAAY,CAAI;YACrB,WAAW,EAAE,IAAI,CAAC,MAAM;YACxB,GAAG,IAAI;SACR,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;;;;;;;;;OAmBG;IACH,KAAK,CAAC,4BAA4B;QAChC,OAAO,4BAA4B,CAAC,EAAE,WAAW,EAAE,IAAI,CAAC,MAAM,EAAE,CAAC,CAAC;IACpE,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;OAqBG;IACH,KAAK,CAAC,kBAAkB,CAAC,aAA4B;QACnD,OAAO,kBAAkB,CAAC,EAAE,WAAW,EAAE,IAAI,CAAC,MAAM,EAAE,aAAa,EAAE,CAAC,CAAC;IACzE,CAAC;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/api/index.ts"],"names":[],"mappings":"AAGA,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/api/index.ts"],"names":[],"mappings":"AAAA,+BAA+B;AAC/B,sCAAsC;AAEtC,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC"}
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
import { Account } from "../account/index.js";
|
|
2
|
+
import { EphemeralKeyPair } from "../account/EphemeralKeyPair.js";
|
|
3
|
+
import { KeylessAccount } from "../account/KeylessAccount.js";
|
|
4
|
+
import { ProofFetchCallback } from "../account/AbstractKeylessAccount.js";
|
|
5
|
+
import { FederatedKeylessAccount } from "../account/FederatedKeylessAccount.js";
|
|
6
|
+
import { AccountAddressInput } from "../core/accountAddress.js";
|
|
7
|
+
import { ZeroKnowledgeSig } from "../core/crypto/keyless.js";
|
|
8
|
+
import { InputGenerateTransactionOptions, SimpleTransaction } from "../transactions/index.js";
|
|
9
|
+
import { HexInput } from "../types/index.js";
|
|
10
|
+
import { AptosConfig } from "./aptosConfig.js";
|
|
11
|
+
/**
|
|
12
|
+
* A class to query all `Keyless` related queries on Aptos.
|
|
13
|
+
*
|
|
14
|
+
* More documentation on how to integrate Keyless Accounts see the below
|
|
15
|
+
* [Aptos Keyless Integration Guide](https://aptos.dev/guides/keyless-accounts/#aptos-keyless-integration-guide).
|
|
16
|
+
* @group Keyless
|
|
17
|
+
*/
|
|
18
|
+
export declare class Keyless {
|
|
19
|
+
readonly config: AptosConfig;
|
|
20
|
+
/**
|
|
21
|
+
* Initializes a new instance of the Aptos class with the provided configuration.
|
|
22
|
+
* This allows you to interact with the Aptos blockchain using the specified network settings.
|
|
23
|
+
*
|
|
24
|
+
* @param config - The configuration settings for connecting to the Aptos network.
|
|
25
|
+
*
|
|
26
|
+
* @example
|
|
27
|
+
* ```typescript
|
|
28
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
29
|
+
*
|
|
30
|
+
* async function runExample() {
|
|
31
|
+
* // Create a new configuration for the Aptos client
|
|
32
|
+
* const config = new AptosConfig({ network: Network.TESTNET }); // Specify your desired network
|
|
33
|
+
*
|
|
34
|
+
* // Initialize the Aptos client with the configuration
|
|
35
|
+
* const aptos = new Aptos(config);
|
|
36
|
+
*
|
|
37
|
+
* console.log("Aptos client initialized:", aptos);
|
|
38
|
+
* }
|
|
39
|
+
* runExample().catch(console.error);
|
|
40
|
+
* ```
|
|
41
|
+
* @group Keyless
|
|
42
|
+
*/
|
|
43
|
+
constructor(config: AptosConfig);
|
|
44
|
+
/**
|
|
45
|
+
* Fetches the pepper from the Aptos pepper service API.
|
|
46
|
+
*
|
|
47
|
+
* @param args - The arguments for fetching the pepper.
|
|
48
|
+
* @param args.jwt - JWT token.
|
|
49
|
+
* @param args.ephemeralKeyPair - The EphemeralKeyPair used to generate the nonce in the JWT token.
|
|
50
|
+
* @param args.derivationPath - A derivation path used for creating multiple accounts per user via the BIP-44 standard. Defaults
|
|
51
|
+
* to "m/44'/637'/0'/0'/0".
|
|
52
|
+
* @returns The pepper which is a Uint8Array of length 31.
|
|
53
|
+
*
|
|
54
|
+
* @example
|
|
55
|
+
* ```typescript
|
|
56
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
57
|
+
*
|
|
58
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
59
|
+
* const aptos = new Aptos(config);
|
|
60
|
+
*
|
|
61
|
+
* async function runExample() {
|
|
62
|
+
* const ephemeralKeyPair = new EphemeralKeyPair(); // create a new ephemeral key pair
|
|
63
|
+
* const jwt = "your_jwt_token"; // replace with a real JWT token
|
|
64
|
+
*
|
|
65
|
+
* // Fetching the pepper using the provided JWT and ephemeral key pair
|
|
66
|
+
* const pepper = await aptos.getPepper({
|
|
67
|
+
* jwt,
|
|
68
|
+
* ephemeralKeyPair,
|
|
69
|
+
* // derivationPath: "m/44'/637'/0'/0'/0" // specify your own if needed
|
|
70
|
+
* });
|
|
71
|
+
*
|
|
72
|
+
* console.log("Fetched pepper:", pepper);
|
|
73
|
+
* }
|
|
74
|
+
* runExample().catch(console.error);
|
|
75
|
+
* ```
|
|
76
|
+
* @group Keyless
|
|
77
|
+
*/
|
|
78
|
+
getPepper(args: {
|
|
79
|
+
jwt: string;
|
|
80
|
+
ephemeralKeyPair: EphemeralKeyPair;
|
|
81
|
+
derivationPath?: string;
|
|
82
|
+
}): Promise<Uint8Array>;
|
|
83
|
+
/**
|
|
84
|
+
* Fetches a proof from the Aptos prover service API.
|
|
85
|
+
*
|
|
86
|
+
* @param args - The arguments for fetching the proof.
|
|
87
|
+
* @param args.jwt - JWT token.
|
|
88
|
+
* @param args.ephemeralKeyPair - The EphemeralKeyPair used to generate the nonce in the JWT token.
|
|
89
|
+
* @param args.pepper - The pepper used for the account. If not provided, it will be fetched from the Aptos pepper service.
|
|
90
|
+
* @param args.uidKey - A key in the JWT token to use to set the uidVal in the IdCommitment.
|
|
91
|
+
*
|
|
92
|
+
* @returns The proof which is represented by a ZeroKnowledgeSig.
|
|
93
|
+
*
|
|
94
|
+
* @example
|
|
95
|
+
* ```typescript
|
|
96
|
+
* import { Aptos, AptosConfig, Network, EphemeralKeyPair, getPepper } from "@aptos-labs/ts-sdk";
|
|
97
|
+
*
|
|
98
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
99
|
+
* const aptos = new Aptos(config);
|
|
100
|
+
*
|
|
101
|
+
* async function runExample() {
|
|
102
|
+
* const jwt = "your_jwt_token"; // replace with a real JWT token
|
|
103
|
+
* const ephemeralKeyPair = new EphemeralKeyPair(); // create a new ephemeral key pair
|
|
104
|
+
*
|
|
105
|
+
* // Fetch the proof using the getProof function
|
|
106
|
+
* const proof = await aptos.getProof({
|
|
107
|
+
* jwt,
|
|
108
|
+
* ephemeralKeyPair,
|
|
109
|
+
* pepper: await getPepper({}), // fetch the pepper if not provided
|
|
110
|
+
* uidKey: "sub", // specify the uid key
|
|
111
|
+
* });
|
|
112
|
+
*
|
|
113
|
+
* console.log("Fetched proof:", proof);
|
|
114
|
+
* }
|
|
115
|
+
* runExample().catch(console.error);
|
|
116
|
+
* ```
|
|
117
|
+
* @group Keyless
|
|
118
|
+
*/
|
|
119
|
+
getProof(args: {
|
|
120
|
+
jwt: string;
|
|
121
|
+
ephemeralKeyPair: EphemeralKeyPair;
|
|
122
|
+
pepper?: HexInput;
|
|
123
|
+
uidKey?: string;
|
|
124
|
+
}): Promise<ZeroKnowledgeSig>;
|
|
125
|
+
deriveKeylessAccount(args: {
|
|
126
|
+
jwt: string;
|
|
127
|
+
ephemeralKeyPair: EphemeralKeyPair;
|
|
128
|
+
uidKey?: string;
|
|
129
|
+
pepper?: HexInput;
|
|
130
|
+
proofFetchCallback?: ProofFetchCallback;
|
|
131
|
+
}): Promise<KeylessAccount>;
|
|
132
|
+
deriveKeylessAccount(args: {
|
|
133
|
+
jwt: string;
|
|
134
|
+
ephemeralKeyPair: EphemeralKeyPair;
|
|
135
|
+
jwkAddress: AccountAddressInput;
|
|
136
|
+
uidKey?: string;
|
|
137
|
+
pepper?: HexInput;
|
|
138
|
+
proofFetchCallback?: ProofFetchCallback;
|
|
139
|
+
}): Promise<FederatedKeylessAccount>;
|
|
140
|
+
/**
|
|
141
|
+
* This installs a set of FederatedJWKs at an address for a given iss.
|
|
142
|
+
*
|
|
143
|
+
* It will fetch the JSON Web Keyset (JWK) set from the well-known endpoint and update the FederatedJWKs at the sender's address
|
|
144
|
+
* to reflect it.
|
|
145
|
+
*
|
|
146
|
+
* @param args.sender The account that will install the JWKs
|
|
147
|
+
* @param args.iss the iss claim of the federated OIDC provider.
|
|
148
|
+
* @param args.jwksUrl the URL to find the corresponding JWKs. For supported IDP providers this parameter in not necessary.
|
|
149
|
+
*
|
|
150
|
+
* @returns The pending transaction that results from submission.
|
|
151
|
+
* @group Keyless
|
|
152
|
+
*/
|
|
153
|
+
updateFederatedKeylessJwkSetTransaction(args: {
|
|
154
|
+
sender: Account;
|
|
155
|
+
iss: string;
|
|
156
|
+
jwksUrl?: string;
|
|
157
|
+
options?: InputGenerateTransactionOptions;
|
|
158
|
+
}): Promise<SimpleTransaction>;
|
|
159
|
+
}
|
|
160
|
+
//# sourceMappingURL=keyless.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"keyless.d.ts","sourceRoot":"","sources":["../../src/api/keyless.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAC;AAClE,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,sCAAsC,CAAC;AAC1E,OAAO,EAAE,uBAAuB,EAAE,MAAM,uCAAuC,CAAC;AAChF,OAAO,EAAE,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAO7D,OAAO,EAAE,+BAA+B,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAC9F,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAE/C;;;;;;GAMG;AACH,qBAAa,OAAO;IAwBN,QAAQ,CAAC,MAAM,EAAE,WAAW;IAvBxC;;;;;;;;;;;;;;;;;;;;;;OAsBG;gBACkB,MAAM,EAAE,WAAW;IAExC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAiCG;IACG,SAAS,CAAC,IAAI,EAAE;QACpB,GAAG,EAAE,MAAM,CAAC;QACZ,gBAAgB,EAAE,gBAAgB,CAAC;QACnC,cAAc,CAAC,EAAE,MAAM,CAAC;KACzB,GAAG,OAAO,CAAC,UAAU,CAAC;IAIvB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAmCG;IACG,QAAQ,CAAC,IAAI,EAAE;QACnB,GAAG,EAAE,MAAM,CAAC;QACZ,gBAAgB,EAAE,gBAAgB,CAAC;QACnC,MAAM,CAAC,EAAE,QAAQ,CAAC;QAClB,MAAM,CAAC,EAAE,MAAM,CAAC;KACjB,GAAG,OAAO,CAAC,gBAAgB,CAAC;IAIvB,oBAAoB,CAAC,IAAI,EAAE;QAC/B,GAAG,EAAE,MAAM,CAAC;QACZ,gBAAgB,EAAE,gBAAgB,CAAC;QACnC,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,MAAM,CAAC,EAAE,QAAQ,CAAC;QAClB,kBAAkB,CAAC,EAAE,kBAAkB,CAAC;KACzC,GAAG,OAAO,CAAC,cAAc,CAAC;IAErB,oBAAoB,CAAC,IAAI,EAAE;QAC/B,GAAG,EAAE,MAAM,CAAC;QACZ,gBAAgB,EAAE,gBAAgB,CAAC;QACnC,UAAU,EAAE,mBAAmB,CAAC;QAChC,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,MAAM,CAAC,EAAE,QAAQ,CAAC;QAClB,kBAAkB,CAAC,EAAE,kBAAkB,CAAC;KACzC,GAAG,OAAO,CAAC,uBAAuB,CAAC;IAsDpC;;;;;;;;;;;;OAYG;IACG,uCAAuC,CAAC,IAAI,EAAE;QAClD,MAAM,EAAE,OAAO,CAAC;QAChB,GAAG,EAAE,MAAM,CAAC;QACZ,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,OAAO,CAAC,EAAE,+BAA+B,CAAC;KAC3C,GAAG,OAAO,CAAC,iBAAiB,CAAC;CAG/B"}
|
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
// Copyright © Aptos Foundation
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
import { deriveKeylessAccount, getPepper, getProof, updateFederatedKeylessJwkSetTransaction, } from "../internal/keyless.js";
|
|
4
|
+
/**
|
|
5
|
+
* A class to query all `Keyless` related queries on Aptos.
|
|
6
|
+
*
|
|
7
|
+
* More documentation on how to integrate Keyless Accounts see the below
|
|
8
|
+
* [Aptos Keyless Integration Guide](https://aptos.dev/guides/keyless-accounts/#aptos-keyless-integration-guide).
|
|
9
|
+
* @group Keyless
|
|
10
|
+
*/
|
|
11
|
+
export class Keyless {
|
|
12
|
+
config;
|
|
13
|
+
/**
|
|
14
|
+
* Initializes a new instance of the Aptos class with the provided configuration.
|
|
15
|
+
* This allows you to interact with the Aptos blockchain using the specified network settings.
|
|
16
|
+
*
|
|
17
|
+
* @param config - The configuration settings for connecting to the Aptos network.
|
|
18
|
+
*
|
|
19
|
+
* @example
|
|
20
|
+
* ```typescript
|
|
21
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
22
|
+
*
|
|
23
|
+
* async function runExample() {
|
|
24
|
+
* // Create a new configuration for the Aptos client
|
|
25
|
+
* const config = new AptosConfig({ network: Network.TESTNET }); // Specify your desired network
|
|
26
|
+
*
|
|
27
|
+
* // Initialize the Aptos client with the configuration
|
|
28
|
+
* const aptos = new Aptos(config);
|
|
29
|
+
*
|
|
30
|
+
* console.log("Aptos client initialized:", aptos);
|
|
31
|
+
* }
|
|
32
|
+
* runExample().catch(console.error);
|
|
33
|
+
* ```
|
|
34
|
+
* @group Keyless
|
|
35
|
+
*/
|
|
36
|
+
constructor(config) {
|
|
37
|
+
this.config = config;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Fetches the pepper from the Aptos pepper service API.
|
|
41
|
+
*
|
|
42
|
+
* @param args - The arguments for fetching the pepper.
|
|
43
|
+
* @param args.jwt - JWT token.
|
|
44
|
+
* @param args.ephemeralKeyPair - The EphemeralKeyPair used to generate the nonce in the JWT token.
|
|
45
|
+
* @param args.derivationPath - A derivation path used for creating multiple accounts per user via the BIP-44 standard. Defaults
|
|
46
|
+
* to "m/44'/637'/0'/0'/0".
|
|
47
|
+
* @returns The pepper which is a Uint8Array of length 31.
|
|
48
|
+
*
|
|
49
|
+
* @example
|
|
50
|
+
* ```typescript
|
|
51
|
+
* import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
|
|
52
|
+
*
|
|
53
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
54
|
+
* const aptos = new Aptos(config);
|
|
55
|
+
*
|
|
56
|
+
* async function runExample() {
|
|
57
|
+
* const ephemeralKeyPair = new EphemeralKeyPair(); // create a new ephemeral key pair
|
|
58
|
+
* const jwt = "your_jwt_token"; // replace with a real JWT token
|
|
59
|
+
*
|
|
60
|
+
* // Fetching the pepper using the provided JWT and ephemeral key pair
|
|
61
|
+
* const pepper = await aptos.getPepper({
|
|
62
|
+
* jwt,
|
|
63
|
+
* ephemeralKeyPair,
|
|
64
|
+
* // derivationPath: "m/44'/637'/0'/0'/0" // specify your own if needed
|
|
65
|
+
* });
|
|
66
|
+
*
|
|
67
|
+
* console.log("Fetched pepper:", pepper);
|
|
68
|
+
* }
|
|
69
|
+
* runExample().catch(console.error);
|
|
70
|
+
* ```
|
|
71
|
+
* @group Keyless
|
|
72
|
+
*/
|
|
73
|
+
async getPepper(args) {
|
|
74
|
+
return getPepper({ aptosConfig: this.config, ...args });
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* Fetches a proof from the Aptos prover service API.
|
|
78
|
+
*
|
|
79
|
+
* @param args - The arguments for fetching the proof.
|
|
80
|
+
* @param args.jwt - JWT token.
|
|
81
|
+
* @param args.ephemeralKeyPair - The EphemeralKeyPair used to generate the nonce in the JWT token.
|
|
82
|
+
* @param args.pepper - The pepper used for the account. If not provided, it will be fetched from the Aptos pepper service.
|
|
83
|
+
* @param args.uidKey - A key in the JWT token to use to set the uidVal in the IdCommitment.
|
|
84
|
+
*
|
|
85
|
+
* @returns The proof which is represented by a ZeroKnowledgeSig.
|
|
86
|
+
*
|
|
87
|
+
* @example
|
|
88
|
+
* ```typescript
|
|
89
|
+
* import { Aptos, AptosConfig, Network, EphemeralKeyPair, getPepper } from "@aptos-labs/ts-sdk";
|
|
90
|
+
*
|
|
91
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
92
|
+
* const aptos = new Aptos(config);
|
|
93
|
+
*
|
|
94
|
+
* async function runExample() {
|
|
95
|
+
* const jwt = "your_jwt_token"; // replace with a real JWT token
|
|
96
|
+
* const ephemeralKeyPair = new EphemeralKeyPair(); // create a new ephemeral key pair
|
|
97
|
+
*
|
|
98
|
+
* // Fetch the proof using the getProof function
|
|
99
|
+
* const proof = await aptos.getProof({
|
|
100
|
+
* jwt,
|
|
101
|
+
* ephemeralKeyPair,
|
|
102
|
+
* pepper: await getPepper({}), // fetch the pepper if not provided
|
|
103
|
+
* uidKey: "sub", // specify the uid key
|
|
104
|
+
* });
|
|
105
|
+
*
|
|
106
|
+
* console.log("Fetched proof:", proof);
|
|
107
|
+
* }
|
|
108
|
+
* runExample().catch(console.error);
|
|
109
|
+
* ```
|
|
110
|
+
* @group Keyless
|
|
111
|
+
*/
|
|
112
|
+
async getProof(args) {
|
|
113
|
+
return getProof({ aptosConfig: this.config, ...args });
|
|
114
|
+
}
|
|
115
|
+
/**
|
|
116
|
+
* Derives a Keyless Account from the provided JWT token and corresponding EphemeralKeyPair. This function computes the proof
|
|
117
|
+
* via the proving service and can fetch the pepper from the pepper service if not explicitly provided.
|
|
118
|
+
*
|
|
119
|
+
* @param args - The arguments required to derive the Keyless Account.
|
|
120
|
+
* @param args.jwt - The JWT token used for deriving the account.
|
|
121
|
+
* @param args.ephemeralKeyPair - The EphemeralKeyPair used to generate the nonce in the JWT token.
|
|
122
|
+
* @param args.jwkAddress - The address the where the JWKs used to verify signatures are found. Setting the value derives a
|
|
123
|
+
* FederatedKeylessAccount.
|
|
124
|
+
* @param args.uidKey - An optional key in the JWT token to set the uidVal in the IdCommitment.
|
|
125
|
+
* @param args.pepper - An optional pepper value.
|
|
126
|
+
* @param args.proofFetchCallback - An optional callback function for fetching the proof in the background, allowing for a more
|
|
127
|
+
* responsive user experience.
|
|
128
|
+
*
|
|
129
|
+
* @returns A KeylessAccount that can be used to sign transactions.
|
|
130
|
+
*
|
|
131
|
+
* @example
|
|
132
|
+
* ```typescript
|
|
133
|
+
* import { Aptos, AptosConfig, Network, deriveKeylessAccount } from "@aptos-labs/ts-sdk";
|
|
134
|
+
*
|
|
135
|
+
* const config = new AptosConfig({ network: Network.TESTNET });
|
|
136
|
+
* const aptos = new Aptos(config);
|
|
137
|
+
*
|
|
138
|
+
* async function runExample() {
|
|
139
|
+
* const jwt = "your_jwt_token"; // replace with a real JWT token
|
|
140
|
+
* const ephemeralKeyPair = new EphemeralKeyPair(); // create a new ephemeral key pair
|
|
141
|
+
*
|
|
142
|
+
* // Deriving the Keyless Account
|
|
143
|
+
* const keylessAccount = await deriveKeylessAccount({
|
|
144
|
+
* jwt,
|
|
145
|
+
* ephemeralKeyPair,
|
|
146
|
+
* uidKey: "your_uid_key", // optional
|
|
147
|
+
* pepper: "your_pepper", // optional
|
|
148
|
+
* });
|
|
149
|
+
*
|
|
150
|
+
* console.log("Keyless Account derived:", keylessAccount);
|
|
151
|
+
* }
|
|
152
|
+
* runExample().catch(console.error);
|
|
153
|
+
* ```
|
|
154
|
+
* @group Keyless
|
|
155
|
+
*/
|
|
156
|
+
async deriveKeylessAccount(args) {
|
|
157
|
+
return deriveKeylessAccount({ aptosConfig: this.config, ...args });
|
|
158
|
+
}
|
|
159
|
+
/**
|
|
160
|
+
* This installs a set of FederatedJWKs at an address for a given iss.
|
|
161
|
+
*
|
|
162
|
+
* It will fetch the JSON Web Keyset (JWK) set from the well-known endpoint and update the FederatedJWKs at the sender's address
|
|
163
|
+
* to reflect it.
|
|
164
|
+
*
|
|
165
|
+
* @param args.sender The account that will install the JWKs
|
|
166
|
+
* @param args.iss the iss claim of the federated OIDC provider.
|
|
167
|
+
* @param args.jwksUrl the URL to find the corresponding JWKs. For supported IDP providers this parameter in not necessary.
|
|
168
|
+
*
|
|
169
|
+
* @returns The pending transaction that results from submission.
|
|
170
|
+
* @group Keyless
|
|
171
|
+
*/
|
|
172
|
+
async updateFederatedKeylessJwkSetTransaction(args) {
|
|
173
|
+
return updateFederatedKeylessJwkSetTransaction({ aptosConfig: this.config, ...args });
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
//# sourceMappingURL=keyless.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"keyless.js","sourceRoot":"","sources":["../../src/api/keyless.ts"],"names":[],"mappings":"AAAA,+BAA+B;AAC/B,sCAAsC;AAStC,OAAO,EACL,oBAAoB,EACpB,SAAS,EACT,QAAQ,EACR,uCAAuC,GACxC,MAAM,wBAAwB,CAAC;AAKhC;;;;;;GAMG;AACH,MAAM,OAAO,OAAO;IAwBG;IAvBrB;;;;;;;;;;;;;;;;;;;;;;OAsBG;IACH,YAAqB,MAAmB;QAAnB,WAAM,GAAN,MAAM,CAAa;IAAG,CAAC;IAE5C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAiCG;IACH,KAAK,CAAC,SAAS,CAAC,IAIf;QACC,OAAO,SAAS,CAAC,EAAE,WAAW,EAAE,IAAI,CAAC,MAAM,EAAE,GAAG,IAAI,EAAE,CAAC,CAAC;IAC1D,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAmCG;IACH,KAAK,CAAC,QAAQ,CAAC,IAKd;QACC,OAAO,QAAQ,CAAC,EAAE,WAAW,EAAE,IAAI,CAAC,MAAM,EAAE,GAAG,IAAI,EAAE,CAAC,CAAC;IACzD,CAAC;IAmBD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAwCG;IACH,KAAK,CAAC,oBAAoB,CAAC,IAO1B;QACC,OAAO,oBAAoB,CAAC,EAAE,WAAW,EAAE,IAAI,CAAC,MAAM,EAAE,GAAG,IAAI,EAAE,CAAC,CAAC;IACrE,CAAC;IAED;;;;;;;;;;;;OAYG;IACH,KAAK,CAAC,uCAAuC,CAAC,IAK7C;QACC,OAAO,uCAAuC,CAAC,EAAE,WAAW,EAAE,IAAI,CAAC,MAAM,EAAE,GAAG,IAAI,EAAE,CAAC,CAAC;IACxF,CAAC;CACF"}
|