@airgap/tezos 0.13.7-beta.11

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.
Files changed (370) hide show
  1. package/LICENSE.md +7 -0
  2. package/actions/GetKtAccountsAction.d.ts +8 -0
  3. package/actions/GetKtAccountsAction.js +85 -0
  4. package/actions/GetKtAccountsAction.js.map +1 -0
  5. package/airgap-coinlib-tezos.min.js +103587 -0
  6. package/constants.d.ts +18 -0
  7. package/constants.js +28 -0
  8. package/constants.js.map +1 -0
  9. package/index.d.ts +46 -0
  10. package/index.js +103 -0
  11. package/index.js.map +1 -0
  12. package/package.json +70 -0
  13. package/protocol/TezosAddress.d.ts +11 -0
  14. package/protocol/TezosAddress.js +102 -0
  15. package/protocol/TezosAddress.js.map +1 -0
  16. package/protocol/TezosCryptoClient.d.ts +15 -0
  17. package/protocol/TezosCryptoClient.js +152 -0
  18. package/protocol/TezosCryptoClient.js.map +1 -0
  19. package/protocol/TezosProtocol.d.ts +349 -0
  20. package/protocol/TezosProtocol.js +1853 -0
  21. package/protocol/TezosProtocol.js.map +1 -0
  22. package/protocol/TezosProtocolOptions.d.ts +29 -0
  23. package/protocol/TezosProtocolOptions.js +114 -0
  24. package/protocol/TezosProtocolOptions.js.map +1 -0
  25. package/protocol/TezosUtils.d.ts +40 -0
  26. package/protocol/TezosUtils.js +296 -0
  27. package/protocol/TezosUtils.js.map +1 -0
  28. package/protocol/contract/TezosContract.d.ts +52 -0
  29. package/protocol/contract/TezosContract.js +509 -0
  30. package/protocol/contract/TezosContract.js.map +1 -0
  31. package/protocol/contract/TezosContractCall.d.ts +10 -0
  32. package/protocol/contract/TezosContractCall.js +23 -0
  33. package/protocol/contract/TezosContractCall.js.map +1 -0
  34. package/protocol/contract/TezosContractEntrypoint.d.ts +8 -0
  35. package/protocol/contract/TezosContractEntrypoint.js +27 -0
  36. package/protocol/contract/TezosContractEntrypoint.js.map +1 -0
  37. package/protocol/contract/TezosContractStorage.d.ts +7 -0
  38. package/protocol/contract/TezosContractStorage.js +16 -0
  39. package/protocol/contract/TezosContractStorage.js.map +1 -0
  40. package/protocol/contract/remote-data/TezosContractRemoteDataFactory.d.ts +11 -0
  41. package/protocol/contract/remote-data/TezosContractRemoteDataFactory.js +34 -0
  42. package/protocol/contract/remote-data/TezosContractRemoteDataFactory.js.map +1 -0
  43. package/protocol/contract/remote-data/TezosStorageRemoteData.d.ts +12 -0
  44. package/protocol/contract/remote-data/TezosStorageRemoteData.js +151 -0
  45. package/protocol/contract/remote-data/TezosStorageRemoteData.js.map +1 -0
  46. package/protocol/domains/TezosDomains.d.ts +20 -0
  47. package/protocol/domains/TezosDomains.js +306 -0
  48. package/protocol/domains/TezosDomains.js.map +1 -0
  49. package/protocol/fa/TezosBTC.d.ts +12 -0
  50. package/protocol/fa/TezosBTC.js +107 -0
  51. package/protocol/fa/TezosBTC.js.map +1 -0
  52. package/protocol/fa/TezosBTCtez.d.ts +10 -0
  53. package/protocol/fa/TezosBTCtez.js +54 -0
  54. package/protocol/fa/TezosBTCtez.js.map +1 -0
  55. package/protocol/fa/TezosCTez.d.ts +10 -0
  56. package/protocol/fa/TezosCTez.js +51 -0
  57. package/protocol/fa/TezosCTez.js.map +1 -0
  58. package/protocol/fa/TezosDOGA.d.ts +10 -0
  59. package/protocol/fa/TezosDOGA.js +51 -0
  60. package/protocol/fa/TezosDOGA.js.map +1 -0
  61. package/protocol/fa/TezosETHtz.d.ts +9 -0
  62. package/protocol/fa/TezosETHtz.js +72 -0
  63. package/protocol/fa/TezosETHtz.js.map +1 -0
  64. package/protocol/fa/TezosFA1Protocol.d.ts +27 -0
  65. package/protocol/fa/TezosFA1Protocol.js +310 -0
  66. package/protocol/fa/TezosFA1Protocol.js.map +1 -0
  67. package/protocol/fa/TezosFA1p2Protocol.d.ts +8 -0
  68. package/protocol/fa/TezosFA1p2Protocol.js +117 -0
  69. package/protocol/fa/TezosFA1p2Protocol.js.map +1 -0
  70. package/protocol/fa/TezosFA2Protocol.d.ts +58 -0
  71. package/protocol/fa/TezosFA2Protocol.js +449 -0
  72. package/protocol/fa/TezosFA2Protocol.js.map +1 -0
  73. package/protocol/fa/TezosFAProtocol.d.ts +65 -0
  74. package/protocol/fa/TezosFAProtocol.js +510 -0
  75. package/protocol/fa/TezosFAProtocol.js.map +1 -0
  76. package/protocol/fa/TezosFAProtocolOptions.d.ts +54 -0
  77. package/protocol/fa/TezosFAProtocolOptions.js +228 -0
  78. package/protocol/fa/TezosFAProtocolOptions.js.map +1 -0
  79. package/protocol/fa/TezosKolibriUSD.d.ts +10 -0
  80. package/protocol/fa/TezosKolibriUSD.js +74 -0
  81. package/protocol/fa/TezosKolibriUSD.js.map +1 -0
  82. package/protocol/fa/TezosPlanty.d.ts +10 -0
  83. package/protocol/fa/TezosPlanty.js +51 -0
  84. package/protocol/fa/TezosPlanty.js.map +1 -0
  85. package/protocol/fa/TezosQUIPU.d.ts +10 -0
  86. package/protocol/fa/TezosQUIPU.js +54 -0
  87. package/protocol/fa/TezosQUIPU.js.map +1 -0
  88. package/protocol/fa/TezosSIRS.d.ts +10 -0
  89. package/protocol/fa/TezosSIRS.js +51 -0
  90. package/protocol/fa/TezosSIRS.js.map +1 -0
  91. package/protocol/fa/TezosStaker.d.ts +10 -0
  92. package/protocol/fa/TezosStaker.js +74 -0
  93. package/protocol/fa/TezosStaker.js.map +1 -0
  94. package/protocol/fa/TezosUBTC.d.ts +10 -0
  95. package/protocol/fa/TezosUBTC.js +54 -0
  96. package/protocol/fa/TezosUBTC.js.map +1 -0
  97. package/protocol/fa/TezosUDEFI.d.ts +10 -0
  98. package/protocol/fa/TezosUDEFI.js +54 -0
  99. package/protocol/fa/TezosUDEFI.js.map +1 -0
  100. package/protocol/fa/TezosUSD.d.ts +10 -0
  101. package/protocol/fa/TezosUSD.js +74 -0
  102. package/protocol/fa/TezosUSD.js.map +1 -0
  103. package/protocol/fa/TezosUSDT.d.ts +10 -0
  104. package/protocol/fa/TezosUSDT.js +54 -0
  105. package/protocol/fa/TezosUSDT.js.map +1 -0
  106. package/protocol/fa/TezosUUSD.d.ts +6 -0
  107. package/protocol/fa/TezosUUSD.js +31 -0
  108. package/protocol/fa/TezosUUSD.js.map +1 -0
  109. package/protocol/fa/TezosWRAP.d.ts +10 -0
  110. package/protocol/fa/TezosWRAP.js +54 -0
  111. package/protocol/fa/TezosWRAP.js.map +1 -0
  112. package/protocol/fa/TezosWrapped.d.ts +10 -0
  113. package/protocol/fa/TezosWrapped.js +74 -0
  114. package/protocol/fa/TezosWrapped.js.map +1 -0
  115. package/protocol/fa/TezosYOU.d.ts +6 -0
  116. package/protocol/fa/TezosYOU.js +31 -0
  117. package/protocol/fa/TezosYOU.js.map +1 -0
  118. package/protocol/indexerClient/TezosIndexerClient.d.ts +25 -0
  119. package/protocol/indexerClient/TezosIndexerClient.js +251 -0
  120. package/protocol/indexerClient/TezosIndexerClient.js.map +1 -0
  121. package/protocol/indexerClient/TezosProtocolIndexerClient.d.ts +26 -0
  122. package/protocol/indexerClient/TezosProtocolIndexerClient.js +3 -0
  123. package/protocol/indexerClient/TezosProtocolIndexerClient.js.map +1 -0
  124. package/protocol/kt/TezosKtAddress.d.ts +5 -0
  125. package/protocol/kt/TezosKtAddress.js +72 -0
  126. package/protocol/kt/TezosKtAddress.js.map +1 -0
  127. package/protocol/kt/TezosKtProtocol.d.ts +30 -0
  128. package/protocol/kt/TezosKtProtocol.js +317 -0
  129. package/protocol/kt/TezosKtProtocol.js.map +1 -0
  130. package/protocol/sapling/TezosSaplingAddress.d.ts +12 -0
  131. package/protocol/sapling/TezosSaplingAddress.js +134 -0
  132. package/protocol/sapling/TezosSaplingAddress.js.map +1 -0
  133. package/protocol/sapling/TezosSaplingCryptoClient.d.ts +34 -0
  134. package/protocol/sapling/TezosSaplingCryptoClient.js +241 -0
  135. package/protocol/sapling/TezosSaplingCryptoClient.js.map +1 -0
  136. package/protocol/sapling/TezosSaplingProtocol.d.ts +130 -0
  137. package/protocol/sapling/TezosSaplingProtocol.js +1101 -0
  138. package/protocol/sapling/TezosSaplingProtocol.js.map +1 -0
  139. package/protocol/sapling/TezosSaplingProtocolOptions.d.ts +43 -0
  140. package/protocol/sapling/TezosSaplingProtocolOptions.js +78 -0
  141. package/protocol/sapling/TezosSaplingProtocolOptions.js.map +1 -0
  142. package/protocol/sapling/TezosShieldedTezProtocol.d.ts +9 -0
  143. package/protocol/sapling/TezosShieldedTezProtocol.js +109 -0
  144. package/protocol/sapling/TezosShieldedTezProtocol.js.map +1 -0
  145. package/protocol/sapling/node/TezosSaplingNodeClient.d.ts +8 -0
  146. package/protocol/sapling/node/TezosSaplingNodeClient.js +78 -0
  147. package/protocol/sapling/node/TezosSaplingNodeClient.js.map +1 -0
  148. package/protocol/sapling/utils/TezosSaplingBookkeeper.d.ts +34 -0
  149. package/protocol/sapling/utils/TezosSaplingBookkeeper.js +586 -0
  150. package/protocol/sapling/utils/TezosSaplingBookkeeper.js.map +1 -0
  151. package/protocol/sapling/utils/TezosSaplingEncoder.d.ts +22 -0
  152. package/protocol/sapling/utils/TezosSaplingEncoder.js +158 -0
  153. package/protocol/sapling/utils/TezosSaplingEncoder.js.map +1 -0
  154. package/protocol/sapling/utils/TezosSaplingForger.d.ts +26 -0
  155. package/protocol/sapling/utils/TezosSaplingForger.js +278 -0
  156. package/protocol/sapling/utils/TezosSaplingForger.js.map +1 -0
  157. package/protocol/sapling/utils/TezosSaplingState.d.ts +17 -0
  158. package/protocol/sapling/utils/TezosSaplingState.js +260 -0
  159. package/protocol/sapling/utils/TezosSaplingState.js.map +1 -0
  160. package/protocol/types/TezosAddressCursor.d.ts +3 -0
  161. package/protocol/types/TezosAddressCursor.js +3 -0
  162. package/protocol/types/TezosAddressCursor.js.map +1 -0
  163. package/protocol/types/TezosAddressResult.d.ts +4 -0
  164. package/protocol/types/TezosAddressResult.js +3 -0
  165. package/protocol/types/TezosAddressResult.js.map +1 -0
  166. package/protocol/types/TezosBlockHeader.d.ts +13 -0
  167. package/protocol/types/TezosBlockHeader.js +3 -0
  168. package/protocol/types/TezosBlockHeader.js.map +1 -0
  169. package/protocol/types/TezosBlockMetadata.d.ts +7 -0
  170. package/protocol/types/TezosBlockMetadata.js +3 -0
  171. package/protocol/types/TezosBlockMetadata.js.map +1 -0
  172. package/protocol/types/TezosContractCode.d.ts +5 -0
  173. package/protocol/types/TezosContractCode.js +3 -0
  174. package/protocol/types/TezosContractCode.js.map +1 -0
  175. package/protocol/types/TezosOperationType.d.ts +13 -0
  176. package/protocol/types/TezosOperationType.js +18 -0
  177. package/protocol/types/TezosOperationType.js.map +1 -0
  178. package/protocol/types/TezosTransactionCursor.d.ts +3 -0
  179. package/protocol/types/TezosTransactionCursor.js +3 -0
  180. package/protocol/types/TezosTransactionCursor.js.map +1 -0
  181. package/protocol/types/TezosTransactionResult.d.ts +6 -0
  182. package/protocol/types/TezosTransactionResult.js +3 -0
  183. package/protocol/types/TezosTransactionResult.js.map +1 -0
  184. package/protocol/types/TezosWrappedOperation.d.ts +5 -0
  185. package/protocol/types/TezosWrappedOperation.js +3 -0
  186. package/protocol/types/TezosWrappedOperation.js.map +1 -0
  187. package/protocol/types/contract/BigMap.d.ts +7 -0
  188. package/protocol/types/contract/BigMap.js +3 -0
  189. package/protocol/types/contract/BigMap.js.map +1 -0
  190. package/protocol/types/contract/BigMapEnrtyFilter.d.ts +5 -0
  191. package/protocol/types/contract/BigMapEnrtyFilter.js +3 -0
  192. package/protocol/types/contract/BigMapEnrtyFilter.js.map +1 -0
  193. package/protocol/types/contract/BigMapEntry.d.ts +7 -0
  194. package/protocol/types/contract/BigMapEntry.js +3 -0
  195. package/protocol/types/contract/BigMapEntry.js.map +1 -0
  196. package/protocol/types/contract/BigMapRequest.d.ts +8 -0
  197. package/protocol/types/contract/BigMapRequest.js +3 -0
  198. package/protocol/types/contract/BigMapRequest.js.map +1 -0
  199. package/protocol/types/contract/TezosContractMetadata.d.ts +61 -0
  200. package/protocol/types/contract/TezosContractMetadata.js +3 -0
  201. package/protocol/types/contract/TezosContractMetadata.js.map +1 -0
  202. package/protocol/types/domains/TezosDomainsRecord.d.ts +8 -0
  203. package/protocol/types/domains/TezosDomainsRecord.js +3 -0
  204. package/protocol/types/domains/TezosDomainsRecord.js.map +1 -0
  205. package/protocol/types/domains/TezosDomainsReverseRecord.d.ts +5 -0
  206. package/protocol/types/domains/TezosDomainsReverseRecord.js +3 -0
  207. package/protocol/types/domains/TezosDomainsReverseRecord.js.map +1 -0
  208. package/protocol/types/fa/TezosFA2BalanceOfRequest.d.ts +4 -0
  209. package/protocol/types/fa/TezosFA2BalanceOfRequest.js +3 -0
  210. package/protocol/types/fa/TezosFA2BalanceOfRequest.js.map +1 -0
  211. package/protocol/types/fa/TezosFA2BalanceOfResponse.d.ts +5 -0
  212. package/protocol/types/fa/TezosFA2BalanceOfResponse.js +3 -0
  213. package/protocol/types/fa/TezosFA2BalanceOfResponse.js.map +1 -0
  214. package/protocol/types/fa/TezosFA2TransferRequest.d.ts +8 -0
  215. package/protocol/types/fa/TezosFA2TransferRequest.js +3 -0
  216. package/protocol/types/fa/TezosFA2TransferRequest.js.map +1 -0
  217. package/protocol/types/fa/TezosFA2UpdateOperatorRequest.d.ts +6 -0
  218. package/protocol/types/fa/TezosFA2UpdateOperatorRequest.js +3 -0
  219. package/protocol/types/fa/TezosFA2UpdateOperatorRequest.js.map +1 -0
  220. package/protocol/types/fa/TezosFATokenMetadata.d.ts +6 -0
  221. package/protocol/types/fa/TezosFATokenMetadata.js +3 -0
  222. package/protocol/types/fa/TezosFATokenMetadata.js.map +1 -0
  223. package/protocol/types/kt/TezosKtAddressCursor.d.ts +4 -0
  224. package/protocol/types/kt/TezosKtAddressCursor.js +3 -0
  225. package/protocol/types/kt/TezosKtAddressCursor.js.map +1 -0
  226. package/protocol/types/kt/TezosKtAddressResult.d.ts +5 -0
  227. package/protocol/types/kt/TezosKtAddressResult.js +3 -0
  228. package/protocol/types/kt/TezosKtAddressResult.js.map +1 -0
  229. package/protocol/types/micheline/MichelineNode.d.ts +15 -0
  230. package/protocol/types/micheline/MichelineNode.js +5 -0
  231. package/protocol/types/micheline/MichelineNode.js.map +1 -0
  232. package/protocol/types/micheline/MichelineNodeUtils.d.ts +6 -0
  233. package/protocol/types/micheline/MichelineNodeUtils.js +40 -0
  234. package/protocol/types/micheline/MichelineNodeUtils.js.map +1 -0
  235. package/protocol/types/michelson/MichelsonType.d.ts +11 -0
  236. package/protocol/types/michelson/MichelsonType.js +22 -0
  237. package/protocol/types/michelson/MichelsonType.js.map +1 -0
  238. package/protocol/types/michelson/MichelsonTypeMeta.d.ts +33 -0
  239. package/protocol/types/michelson/MichelsonTypeMeta.js +132 -0
  240. package/protocol/types/michelson/MichelsonTypeMeta.js.map +1 -0
  241. package/protocol/types/michelson/MichelsonTypeUtils.d.ts +19 -0
  242. package/protocol/types/michelson/MichelsonTypeUtils.js +249 -0
  243. package/protocol/types/michelson/MichelsonTypeUtils.js.map +1 -0
  244. package/protocol/types/michelson/generics/MichelsonList.d.ts +11 -0
  245. package/protocol/types/michelson/generics/MichelsonList.js +68 -0
  246. package/protocol/types/michelson/generics/MichelsonList.js.map +1 -0
  247. package/protocol/types/michelson/generics/MichelsonMap.d.ts +14 -0
  248. package/protocol/types/michelson/generics/MichelsonMap.js +118 -0
  249. package/protocol/types/michelson/generics/MichelsonMap.js.map +1 -0
  250. package/protocol/types/michelson/generics/MichelsonOption.d.ts +25 -0
  251. package/protocol/types/michelson/generics/MichelsonOption.js +119 -0
  252. package/protocol/types/michelson/generics/MichelsonOption.js.map +1 -0
  253. package/protocol/types/michelson/generics/MichelsonOr.d.ts +25 -0
  254. package/protocol/types/michelson/generics/MichelsonOr.js +132 -0
  255. package/protocol/types/michelson/generics/MichelsonOr.js.map +1 -0
  256. package/protocol/types/michelson/generics/MichelsonPair.d.ts +17 -0
  257. package/protocol/types/michelson/generics/MichelsonPair.js +135 -0
  258. package/protocol/types/michelson/generics/MichelsonPair.js.map +1 -0
  259. package/protocol/types/michelson/grammar/MichelsonGrammarData.d.ts +2 -0
  260. package/protocol/types/michelson/grammar/MichelsonGrammarData.js +4 -0
  261. package/protocol/types/michelson/grammar/MichelsonGrammarData.js.map +1 -0
  262. package/protocol/types/michelson/grammar/MichelsonGrammarInstruction.d.ts +1 -0
  263. package/protocol/types/michelson/grammar/MichelsonGrammarInstruction.js +4 -0
  264. package/protocol/types/michelson/grammar/MichelsonGrammarInstruction.js.map +1 -0
  265. package/protocol/types/michelson/grammar/MichelsonGrammarType.d.ts +1 -0
  266. package/protocol/types/michelson/grammar/MichelsonGrammarType.js +4 -0
  267. package/protocol/types/michelson/grammar/MichelsonGrammarType.js.map +1 -0
  268. package/protocol/types/michelson/primitives/MichelsonAddress.d.ts +15 -0
  269. package/protocol/types/michelson/primitives/MichelsonAddress.js +72 -0
  270. package/protocol/types/michelson/primitives/MichelsonAddress.js.map +1 -0
  271. package/protocol/types/michelson/primitives/MichelsonBool.d.ts +12 -0
  272. package/protocol/types/michelson/primitives/MichelsonBool.js +57 -0
  273. package/protocol/types/michelson/primitives/MichelsonBool.js.map +1 -0
  274. package/protocol/types/michelson/primitives/MichelsonBytes.d.ts +14 -0
  275. package/protocol/types/michelson/primitives/MichelsonBytes.js +75 -0
  276. package/protocol/types/michelson/primitives/MichelsonBytes.js.map +1 -0
  277. package/protocol/types/michelson/primitives/MichelsonInt.d.ts +14 -0
  278. package/protocol/types/michelson/primitives/MichelsonInt.js +72 -0
  279. package/protocol/types/michelson/primitives/MichelsonInt.js.map +1 -0
  280. package/protocol/types/michelson/primitives/MichelsonString.d.ts +14 -0
  281. package/protocol/types/michelson/primitives/MichelsonString.js +74 -0
  282. package/protocol/types/michelson/primitives/MichelsonString.js.map +1 -0
  283. package/protocol/types/michelson/primitives/MichelsonUnit.d.ts +9 -0
  284. package/protocol/types/michelson/primitives/MichelsonUnit.js +53 -0
  285. package/protocol/types/michelson/primitives/MichelsonUnit.js.map +1 -0
  286. package/protocol/types/operations/ActivateAccount.d.ts +7 -0
  287. package/protocol/types/operations/ActivateAccount.js +3 -0
  288. package/protocol/types/operations/ActivateAccount.js.map +1 -0
  289. package/protocol/types/operations/Ballot.d.ts +9 -0
  290. package/protocol/types/operations/Ballot.js +3 -0
  291. package/protocol/types/operations/Ballot.js.map +1 -0
  292. package/protocol/types/operations/Delegation.d.ts +11 -0
  293. package/protocol/types/operations/Delegation.js +3 -0
  294. package/protocol/types/operations/Delegation.js.map +1 -0
  295. package/protocol/types/operations/DoubleBakingEvidence.d.ts +8 -0
  296. package/protocol/types/operations/DoubleBakingEvidence.js +3 -0
  297. package/protocol/types/operations/DoubleBakingEvidence.js.map +1 -0
  298. package/protocol/types/operations/DoubleEndorsementEvidence.d.ts +16 -0
  299. package/protocol/types/operations/DoubleEndorsementEvidence.js +3 -0
  300. package/protocol/types/operations/DoubleEndorsementEvidence.js.map +1 -0
  301. package/protocol/types/operations/Endorsement.d.ts +6 -0
  302. package/protocol/types/operations/Endorsement.js +3 -0
  303. package/protocol/types/operations/Endorsement.js.map +1 -0
  304. package/protocol/types/operations/Origination.d.ts +13 -0
  305. package/protocol/types/operations/Origination.js +3 -0
  306. package/protocol/types/operations/Origination.js.map +1 -0
  307. package/protocol/types/operations/Proposal.d.ts +7 -0
  308. package/protocol/types/operations/Proposal.js +3 -0
  309. package/protocol/types/operations/Proposal.js.map +1 -0
  310. package/protocol/types/operations/Reveal.d.ts +11 -0
  311. package/protocol/types/operations/Reveal.js +3 -0
  312. package/protocol/types/operations/Reveal.js.map +1 -0
  313. package/protocol/types/operations/SeedNonceRevelation.d.ts +7 -0
  314. package/protocol/types/operations/SeedNonceRevelation.js +3 -0
  315. package/protocol/types/operations/SeedNonceRevelation.js.map +1 -0
  316. package/protocol/types/operations/TezosOperation.d.ts +4 -0
  317. package/protocol/types/operations/TezosOperation.js +3 -0
  318. package/protocol/types/operations/TezosOperation.js.map +1 -0
  319. package/protocol/types/operations/Transaction.d.ts +23 -0
  320. package/protocol/types/operations/Transaction.js +3 -0
  321. package/protocol/types/operations/Transaction.js.map +1 -0
  322. package/protocol/types/sapling/TezosSaplingAddressCursor.d.ts +4 -0
  323. package/protocol/types/sapling/TezosSaplingAddressCursor.js +3 -0
  324. package/protocol/types/sapling/TezosSaplingAddressCursor.js.map +1 -0
  325. package/protocol/types/sapling/TezosSaplingAddressResult.d.ts +4 -0
  326. package/protocol/types/sapling/TezosSaplingAddressResult.js +3 -0
  327. package/protocol/types/sapling/TezosSaplingAddressResult.js.map +1 -0
  328. package/protocol/types/sapling/TezosSaplingCiphertext.d.ts +8 -0
  329. package/protocol/types/sapling/TezosSaplingCiphertext.js +3 -0
  330. package/protocol/types/sapling/TezosSaplingCiphertext.js.map +1 -0
  331. package/protocol/types/sapling/TezosSaplingInput.d.ts +6 -0
  332. package/protocol/types/sapling/TezosSaplingInput.js +3 -0
  333. package/protocol/types/sapling/TezosSaplingInput.js.map +1 -0
  334. package/protocol/types/sapling/TezosSaplingOutput.d.ts +6 -0
  335. package/protocol/types/sapling/TezosSaplingOutput.js +3 -0
  336. package/protocol/types/sapling/TezosSaplingOutput.js.map +1 -0
  337. package/protocol/types/sapling/TezosSaplingStateDiff.d.ts +6 -0
  338. package/protocol/types/sapling/TezosSaplingStateDiff.js +3 -0
  339. package/protocol/types/sapling/TezosSaplingStateDiff.js.map +1 -0
  340. package/protocol/types/sapling/TezosSaplingStateTree.d.ts +7 -0
  341. package/protocol/types/sapling/TezosSaplingStateTree.js +3 -0
  342. package/protocol/types/sapling/TezosSaplingStateTree.js.map +1 -0
  343. package/protocol/types/sapling/TezosSaplingTransaction.d.ts +23 -0
  344. package/protocol/types/sapling/TezosSaplingTransaction.js +3 -0
  345. package/protocol/types/sapling/TezosSaplingTransaction.js.map +1 -0
  346. package/protocol/types/sapling/TezosSaplingTransactionCursor.d.ts +3 -0
  347. package/protocol/types/sapling/TezosSaplingTransactionCursor.js +3 -0
  348. package/protocol/types/sapling/TezosSaplingTransactionCursor.js.map +1 -0
  349. package/protocol/types/sapling/TezosSaplingTransactionResult.d.ts +6 -0
  350. package/protocol/types/sapling/TezosSaplingTransactionResult.js +3 -0
  351. package/protocol/types/sapling/TezosSaplingTransactionResult.js.map +1 -0
  352. package/protocol/types/utils.d.ts +8 -0
  353. package/protocol/types/utils.js +41 -0
  354. package/protocol/types/utils.js.map +1 -0
  355. package/readme.md +121 -0
  356. package/types/signed-transaction-tezos-sapling.d.ts +3 -0
  357. package/types/signed-transaction-tezos-sapling.js +3 -0
  358. package/types/signed-transaction-tezos-sapling.js.map +1 -0
  359. package/types/signed-transaction-tezos.d.ts +5 -0
  360. package/types/signed-transaction-tezos.js +3 -0
  361. package/types/signed-transaction-tezos.js.map +1 -0
  362. package/types/transaction-tezos.d.ts +14 -0
  363. package/types/transaction-tezos.js +3 -0
  364. package/types/transaction-tezos.js.map +1 -0
  365. package/types/unsigned-transaction-tezos-sapling.d.ts +38 -0
  366. package/types/unsigned-transaction-tezos-sapling.js +3 -0
  367. package/types/unsigned-transaction-tezos-sapling.js.map +1 -0
  368. package/types/unsigned-transaction-tezos.d.ts +8 -0
  369. package/types/unsigned-transaction-tezos.js +3 -0
  370. package/types/unsigned-transaction-tezos.js.map +1 -0
@@ -0,0 +1,349 @@
1
+ import { ICoinSubProtocol } from '@airgap/coinlib-core';
2
+ import BigNumber from '@airgap/coinlib-core/dependencies/src/bignumber.js-9.0.0/bignumber';
3
+ import { IAirGapSignedTransaction } from '@airgap/coinlib-core/interfaces/IAirGapSignedTransaction';
4
+ import { AirGapTransactionStatus, IAirGapTransaction } from '@airgap/coinlib-core/interfaces/IAirGapTransaction';
5
+ import { DelegateeDetails, DelegationDetails, DelegatorDetails, ICoinDelegateProtocol } from '@airgap/coinlib-core/protocols/ICoinDelegateProtocol';
6
+ import { CurrencyUnit, FeeDefaults } from '@airgap/coinlib-core/protocols/ICoinProtocol';
7
+ import { NonExtendedProtocol } from '@airgap/coinlib-core/protocols/NonExtendedProtocol';
8
+ import { ProtocolSymbols } from '@airgap/coinlib-core/utils/ProtocolSymbols';
9
+ import { SignedTezosTransaction } from '../types/signed-transaction-tezos';
10
+ import { RawTezosTransaction } from '../types/transaction-tezos';
11
+ import { UnsignedTezosTransaction } from '../types/unsigned-transaction-tezos';
12
+ import { TezosCryptoClient } from './TezosCryptoClient';
13
+ import { TezosProtocolOptions } from './TezosProtocolOptions';
14
+ import { TezosRevealOperation } from './types/operations/Reveal';
15
+ import { TezosOperation } from './types/operations/TezosOperation';
16
+ import { TezosTransactionOperation } from './types/operations/Transaction';
17
+ import { TezosAddressCursor } from './types/TezosAddressCursor';
18
+ import { TezosAddressResult } from './types/TezosAddressResult';
19
+ import { TezosTransactionCursor } from './types/TezosTransactionCursor';
20
+ import { TezosTransactionResult } from './types/TezosTransactionResult';
21
+ import { TezosWrappedOperation } from './types/TezosWrappedOperation';
22
+ export interface TezosVotingInfo {
23
+ pkh: string;
24
+ rolls: number;
25
+ }
26
+ export interface BakerInfo {
27
+ balance: BigNumber;
28
+ delegatedBalance: BigNumber;
29
+ stakingBalance: BigNumber;
30
+ selfBond: BigNumber;
31
+ bakerCapacity: BigNumber;
32
+ bakerUsage: BigNumber;
33
+ }
34
+ export interface DelegationRewardInfo {
35
+ cycle: number;
36
+ reward: BigNumber;
37
+ deposit: BigNumber;
38
+ delegatedBalance: BigNumber;
39
+ stakingBalance: BigNumber;
40
+ totalRewards: BigNumber;
41
+ totalFees: BigNumber;
42
+ payout: Date;
43
+ }
44
+ export interface DelegationInfo {
45
+ isDelegated: boolean;
46
+ value?: string;
47
+ delegatedOpLevel?: number;
48
+ delegatedDate?: Date;
49
+ }
50
+ export declare enum TezosDelegatorAction {
51
+ DELEGATE = "delegate",
52
+ UNDELEGATE = "undelegate",
53
+ CHANGE_BAKER = "change_baker"
54
+ }
55
+ export interface TezosPayoutInfo {
56
+ delegator: string;
57
+ share: string;
58
+ payout: string;
59
+ balance: string;
60
+ }
61
+ export interface RunOperationBalanceUpdate {
62
+ kind: string;
63
+ contract: string;
64
+ change: string;
65
+ category: string;
66
+ delegate: string;
67
+ cycle?: number;
68
+ }
69
+ export interface RunOperationOperationBalanceUpdate {
70
+ kind: string;
71
+ contract: string;
72
+ change: string;
73
+ }
74
+ export interface RunOperationOperationResult {
75
+ status: string;
76
+ errors?: unknown;
77
+ balance_updates: RunOperationOperationBalanceUpdate[];
78
+ consumed_milligas: string;
79
+ paid_storage_size_diff?: string;
80
+ originated_contracts?: string[];
81
+ allocated_destination_contract?: boolean;
82
+ }
83
+ interface RunOperationInternalOperationResult {
84
+ result?: {
85
+ errors?: unknown;
86
+ consumed_milligas: string;
87
+ paid_storage_size_diff?: string;
88
+ originated_contracts?: string[];
89
+ allocated_destination_contract?: boolean;
90
+ };
91
+ parameters?: {
92
+ entrypoint: string;
93
+ value: unknown;
94
+ };
95
+ }
96
+ export interface RunOperationMetadata {
97
+ balance_updates: RunOperationBalanceUpdate[];
98
+ operation_result: RunOperationOperationResult;
99
+ internal_operation_results?: RunOperationInternalOperationResult[];
100
+ }
101
+ export declare enum TezosNetwork {
102
+ MAINNET = "mainnet",
103
+ GHOSTNET = "ghostnet"
104
+ }
105
+ export declare class TezosProtocol extends NonExtendedProtocol implements ICoinDelegateProtocol {
106
+ readonly options: TezosProtocolOptions;
107
+ symbol: string;
108
+ name: string;
109
+ marketSymbol: string;
110
+ feeSymbol: string;
111
+ decimals: number;
112
+ feeDecimals: number;
113
+ identifier: ProtocolSymbols;
114
+ feeDefaults: FeeDefaults;
115
+ units: CurrencyUnit[];
116
+ supportsHD: boolean;
117
+ standardDerivationPath: string;
118
+ addressIsCaseSensitive: boolean;
119
+ addressValidationPattern: string;
120
+ addressPlaceholder: string;
121
+ minCycleDuration: number;
122
+ protected readonly transactionFee: BigNumber;
123
+ protected readonly originationSize: BigNumber;
124
+ protected readonly storageCostPerByte: BigNumber;
125
+ protected readonly revealFee: BigNumber;
126
+ protected readonly activationBurn: BigNumber;
127
+ protected readonly originationBurn: BigNumber;
128
+ readonly cryptoClient: TezosCryptoClient;
129
+ get jsonRPCAPI(): string;
130
+ constructor(options?: TezosProtocolOptions);
131
+ getSymbol(): Promise<string>;
132
+ getName(): Promise<string>;
133
+ getMarketSymbol(): Promise<string>;
134
+ getFeeSymbol(): Promise<string>;
135
+ getDecimals(): Promise<number>;
136
+ getFeeDecimals(): Promise<number>;
137
+ getIdentifier(): Promise<ProtocolSymbols>;
138
+ getFeeDefaults(): Promise<FeeDefaults>;
139
+ getUnits(): Promise<CurrencyUnit[]>;
140
+ getSupportsHD(): Promise<boolean>;
141
+ getStandardDerivationPath(): Promise<string>;
142
+ getAddressIsCaseSensitive(): Promise<boolean>;
143
+ getAddressValidationPattern(): Promise<string>;
144
+ getAddressPlaceholder(): Promise<string>;
145
+ getOptions(): Promise<TezosProtocolOptions>;
146
+ getBlockExplorerLinkForAddress(address: string): Promise<string>;
147
+ getBlockExplorerLinkForTxId(txId: string): Promise<string>;
148
+ getPublicKeyFromMnemonic(mnemonic: string, derivationPath: string, password?: string): Promise<string>;
149
+ getPrivateKeyFromMnemonic(mnemonic: string, derivationPath: string, password?: string): Promise<string>;
150
+ /**
151
+ * Returns the PublicKey as String, derived from a supplied hex-string
152
+ * @param secret HEX-Secret from BIP39
153
+ * @param derivationPath DerivationPath for Key
154
+ */
155
+ getPublicKeyFromHexSecret(secret: string, derivationPath: string): Promise<string>;
156
+ /**
157
+ * Returns the PrivateKey as Buffer, derived from a supplied hex-string
158
+ * @param secret HEX-Secret from BIP39
159
+ * @param derivationPath DerivationPath for Key
160
+ */
161
+ getPrivateKeyFromHexSecret(secret: string, derivationPath: string): Promise<string>;
162
+ getAddressFromPublicKey(publicKey: string, cursor?: TezosAddressCursor): Promise<TezosAddressResult>;
163
+ getAddressesFromPublicKey(publicKey: string, cursor?: TezosAddressCursor): Promise<TezosAddressResult[]>;
164
+ getTransactionsFromPublicKey(publicKey: string, limit: number, cursor?: TezosTransactionCursor): Promise<TezosTransactionResult>;
165
+ getTransactionsFromAddresses(addresses: string[], limit: number, cursor?: TezosTransactionCursor): Promise<TezosTransactionResult>;
166
+ signWithPrivateKey(privateKey: string, transaction: RawTezosTransaction): Promise<IAirGapSignedTransaction>;
167
+ getTransactionDetails(unsignedTx: UnsignedTezosTransaction): Promise<IAirGapTransaction[]>;
168
+ getTransactionDetailsFromSigned(signedTx: SignedTezosTransaction): Promise<IAirGapTransaction[]>;
169
+ getAirGapTxFromWrappedOperations(wrappedOperations: TezosWrappedOperation): Promise<IAirGapTransaction[]>;
170
+ getBalanceOfAddresses(addresses: string[], _data?: any): Promise<string>;
171
+ getBalanceOfPublicKey(publicKey: string, data?: any): Promise<string>;
172
+ getBalanceOfPublicKeyForSubProtocols(publicKey: string, subProtocols: ICoinSubProtocol[]): Promise<string[]>;
173
+ getAvailableBalanceOfAddresses(addresses: string[], data?: any): Promise<string>;
174
+ estimateMaxTransactionValueFromPublicKey(publicKey: string, recipients: string[], fee?: string): Promise<string>;
175
+ private estimateMaxTansactionValueWithBalance;
176
+ estimateFeeDefaultsFromPublicKey(publicKey: string, recipients: string[], values: string[], _data?: any): Promise<FeeDefaults>;
177
+ estimateFeeDefaultsForOperations(publicKey: string, operations: TezosOperation[]): Promise<FeeDefaults>;
178
+ prepareTransactionFromPublicKey(publicKey: string, recipients: string[], values: string[], fee: string, data?: {
179
+ addressIndex: number;
180
+ }): Promise<RawTezosTransaction>;
181
+ prepareTransactionsFromPublicKey(publicKey: string, recipients: string[], values: string[], fee: string, data?: {
182
+ addressIndex: number;
183
+ }, operationsPerGroup?: number): Promise<RawTezosTransaction[]>;
184
+ protected getTransactionOperationDetails(transactionOperation: TezosTransactionOperation): Promise<Partial<IAirGapTransaction>[]>;
185
+ private createTransactionOperations;
186
+ forgeAndWrapOperations(tezosWrappedOperation: TezosWrappedOperation): Promise<RawTezosTransaction>;
187
+ getDefaultDelegatee(): Promise<string>;
188
+ getCurrentDelegateesForPublicKey(publicKey: string): Promise<string[]>;
189
+ getCurrentDelegateesForAddress(address: string): Promise<string[]>;
190
+ getDelegateeDetails(address: string): Promise<DelegateeDetails>;
191
+ isPublicKeyDelegating(publicKey: string): Promise<boolean>;
192
+ isAddressDelegating(address: string): Promise<boolean>;
193
+ getDelegatorDetailsFromPublicKey(publicKey: string): Promise<DelegatorDetails>;
194
+ getDelegatorDetailsFromAddress(address: string): Promise<DelegatorDetails>;
195
+ getDelegationDetailsFromPublicKey(publicKey: string, delegatees: string[]): Promise<DelegationDetails>;
196
+ getDelegationDetailsFromAddress(address: string, delegatees: string[]): Promise<DelegationDetails>;
197
+ private getDelegatorDetails;
198
+ prepareDelegatorActionFromPublicKey(publicKey: string, type: TezosDelegatorAction, data?: any): Promise<RawTezosTransaction[]>;
199
+ prepareOperations(publicKey: string, operationRequests: TezosOperation[], overrideParameters?: boolean): Promise<TezosWrappedOperation>;
200
+ estimateAndReplaceLimitsAndFee(tezosWrappedOperation: TezosWrappedOperation, overrideParameters?: boolean, startingCounter?: BigNumber): Promise<TezosWrappedOperation>;
201
+ getDelegationInfo(delegatedAddress: string, fetchExtraInfo?: boolean): Promise<DelegationInfo>;
202
+ bakerInfo(tzAddress: string | undefined): Promise<BakerInfo>;
203
+ getDelegationRewardsForAddress(address: string): Promise<DelegationRewardInfo[]>;
204
+ getDelegationRewards(bakerAddress: string, delegatorAddress?: string): Promise<DelegationRewardInfo[]>;
205
+ undelegate(publicKey: string): Promise<RawTezosTransaction>;
206
+ delegate(publicKey: string, delegate?: string | string[]): Promise<RawTezosTransaction>;
207
+ private getAmountUsedByPreviousOperations;
208
+ broadcastTransaction(rawTransaction: IAirGapSignedTransaction): Promise<string>;
209
+ protected checkAndRemovePrefixToHex(base58CheckEncodedPayload: string, tezosPrefix: Uint8Array): string;
210
+ unforgeSignedTezosWrappedOperation(hexString: string): Promise<TezosWrappedOperation>;
211
+ unforgeUnsignedTezosWrappedOperation(hexString: string): Promise<TezosWrappedOperation>;
212
+ forgeTezosOperation(tezosWrappedOperation: TezosWrappedOperation): Promise<string>;
213
+ createRevealOperation(counter: BigNumber, publicKey: string, address: string, fee?: string): Promise<TezosRevealOperation>;
214
+ getTezosVotingInfo(blockHash: string): Promise<TezosVotingInfo[]>;
215
+ fetchCurrentCycle(): Promise<number>;
216
+ private static readonly FIRST_010_CYCLE;
217
+ private static readonly BLOCKS_PER_CYCLE;
218
+ private static readonly TIME_BETWEEN_BLOCKS;
219
+ timeIntervalBetweenCycles(fromCycle: number, toCycle: number): number;
220
+ cycleToBlockLevel(cycle: number): number;
221
+ blockLevelToCycle(blockLevel: number): number;
222
+ private fetchBlockMetadata;
223
+ signMessage(message: string, keypair: {
224
+ privateKey: string;
225
+ }): Promise<string>;
226
+ verifyMessage(message: string, signature: string, publicKey: string): Promise<boolean>;
227
+ encryptAsymmetric(message: string, publicKey: string): Promise<string>;
228
+ decryptAsymmetric(message: string, keypair: {
229
+ publicKey: string;
230
+ privateKey: string;
231
+ }): Promise<string>;
232
+ encryptAES(message: string, privateKey: string): Promise<string>;
233
+ decryptAES(message: string, privateKey: string): Promise<string>;
234
+ getTransactionStatuses(transactionHashes: string[]): Promise<AirGapTransactionStatus[]>;
235
+ }
236
+ export interface TezosBakingRight {
237
+ level: number;
238
+ delegate: string;
239
+ priority: number;
240
+ }
241
+ export interface TezosBakingRewards {
242
+ totalBakingRewards: string;
243
+ rewardsDetails: {
244
+ level: number;
245
+ amount: string;
246
+ deposit: string;
247
+ fees?: string;
248
+ }[];
249
+ }
250
+ export interface TezosEndorsingRewards {
251
+ totalEndorsingRewards: string;
252
+ rewardsDetails: {
253
+ level: number;
254
+ amount: string;
255
+ deposit: string;
256
+ }[];
257
+ }
258
+ export interface TezosEndorsingRight {
259
+ level: number;
260
+ block_level?: number;
261
+ delegate: string;
262
+ number_of_slots: number;
263
+ }
264
+ export interface TezosRewardsCalculations {
265
+ calculateRewards(bakerAddress: string, cycle: number, breakDownRewards: boolean, currentCycleIn?: number): Promise<TezosRewards>;
266
+ }
267
+ export interface TezosRewards {
268
+ baker: string;
269
+ stakingBalance: string;
270
+ bakingRewards: string;
271
+ bakingDeposits: string;
272
+ endorsingDeposits: string;
273
+ endorsingRewards: string;
274
+ fees: string;
275
+ deposit: string;
276
+ totalRewards: string;
277
+ cycle: number;
278
+ snapshotBlockLevel: number;
279
+ delegatedContracts: string[];
280
+ bakingRewardsDetails: {
281
+ level: number;
282
+ amount: string;
283
+ deposit: string;
284
+ fees?: string;
285
+ }[];
286
+ endorsingRewardsDetails: {
287
+ level: number;
288
+ amount: string;
289
+ deposit: string;
290
+ }[];
291
+ endorsingRightsCount: number;
292
+ }
293
+ export interface TezosBakerInfo {
294
+ balance: string;
295
+ frozen_balance: string;
296
+ frozen_balance_by_cycle: TezosFrozenBalance[];
297
+ staking_balance: string;
298
+ delegated_contracts: string[];
299
+ delegated_balance: string;
300
+ deactivated: boolean;
301
+ grace_period: number;
302
+ }
303
+ export interface TezosFrozenBalance {
304
+ cycle: number;
305
+ deposit?: string;
306
+ deposits: string;
307
+ fees: string;
308
+ rewards: string;
309
+ }
310
+ export interface TezosNodeConstants {
311
+ proof_of_work_nonce_size: number;
312
+ nonce_length: number;
313
+ max_revelations_per_block: number;
314
+ max_operation_data_length: number;
315
+ max_proposals_per_delegate: number;
316
+ preserved_cycles: number;
317
+ blocks_per_cycle: number;
318
+ blocks_per_commitment: number;
319
+ blocks_per_roll_snapshot: number;
320
+ blocks_per_voting_period: number;
321
+ time_between_blocks: number[];
322
+ endorsers_per_block: number;
323
+ hard_gas_limit_per_operation: string;
324
+ hard_gas_limit_per_block: string;
325
+ proof_of_work_threshold: number;
326
+ tokens_per_roll: string;
327
+ michelson_maximum_type_size: number;
328
+ seed_nonce_revelation_tip: string;
329
+ origination_size: number;
330
+ block_security_deposit: string;
331
+ endorsement_security_deposit: string;
332
+ cost_per_byte: string;
333
+ hard_storage_limit_per_operation: string;
334
+ test_chain_duration: string;
335
+ quorum_min: number;
336
+ quorum_max: number;
337
+ min_proposal_quorum: number;
338
+ initial_endorsers: number;
339
+ delay_per_missing_endorsement: string;
340
+ }
341
+ export interface TezosNodeConstantsV1 extends TezosNodeConstants {
342
+ block_reward: string;
343
+ endorsement_reward: string;
344
+ }
345
+ export interface TezosNodeConstantsV2 extends TezosNodeConstants {
346
+ baking_reward_per_endorsement: string[];
347
+ endorsement_reward: string[];
348
+ }
349
+ export {};