algosdk 3.0.0-beta.1 → 3.0.0-beta.2

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 (218) hide show
  1. package/README.md +4 -4
  2. package/dist/browser/algosdk.min.js +1 -1
  3. package/dist/browser/algosdk.min.js.map +1 -1
  4. package/dist/cjs/client/urlTokenBaseHTTPClient.js +1 -1
  5. package/dist/cjs/client/urlTokenBaseHTTPClient.js.map +1 -1
  6. package/dist/cjs/client/v2/algod/accountApplicationInformation.js +1 -1
  7. package/dist/cjs/client/v2/algod/accountApplicationInformation.js.map +1 -1
  8. package/dist/cjs/client/v2/algod/accountAssetInformation.js +1 -1
  9. package/dist/cjs/client/v2/algod/accountAssetInformation.js.map +1 -1
  10. package/dist/cjs/client/v2/algod/algod.js +2 -2
  11. package/dist/cjs/client/v2/algod/algod.js.map +1 -1
  12. package/dist/cjs/client/v2/algod/block.js +1 -1
  13. package/dist/cjs/client/v2/algod/block.js.map +1 -1
  14. package/dist/cjs/client/v2/algod/getApplicationBoxByName.js +1 -1
  15. package/dist/cjs/client/v2/algod/getApplicationBoxByName.js.map +1 -1
  16. package/dist/cjs/client/v2/algod/getApplicationBoxes.js +1 -1
  17. package/dist/cjs/client/v2/algod/getApplicationBoxes.js.map +1 -1
  18. package/dist/cjs/client/v2/algod/getApplicationByID.js +1 -1
  19. package/dist/cjs/client/v2/algod/getApplicationByID.js.map +1 -1
  20. package/dist/cjs/client/v2/algod/getAssetByID.js +1 -1
  21. package/dist/cjs/client/v2/algod/getAssetByID.js.map +1 -1
  22. package/dist/cjs/client/v2/algod/getBlockHash.js +1 -1
  23. package/dist/cjs/client/v2/algod/getBlockHash.js.map +1 -1
  24. package/dist/cjs/client/v2/algod/getBlockTxids.js +1 -3
  25. package/dist/cjs/client/v2/algod/getBlockTxids.js.map +1 -1
  26. package/dist/cjs/client/v2/algod/getLedgerStateDelta.js +1 -1
  27. package/dist/cjs/client/v2/algod/getLedgerStateDelta.js.map +1 -1
  28. package/dist/cjs/client/v2/algod/getTransactionGroupLedgerStateDeltasForRound.js +1 -1
  29. package/dist/cjs/client/v2/algod/getTransactionGroupLedgerStateDeltasForRound.js.map +1 -1
  30. package/dist/cjs/client/v2/algod/getTransactionProof.js +1 -1
  31. package/dist/cjs/client/v2/algod/getTransactionProof.js.map +1 -1
  32. package/dist/cjs/client/v2/algod/lightBlockHeaderProof.js +1 -1
  33. package/dist/cjs/client/v2/algod/lightBlockHeaderProof.js.map +1 -1
  34. package/dist/cjs/client/v2/algod/setBlockOffsetTimestamp.js +1 -1
  35. package/dist/cjs/client/v2/algod/setBlockOffsetTimestamp.js.map +1 -1
  36. package/dist/cjs/client/v2/algod/setSyncRound.js +1 -1
  37. package/dist/cjs/client/v2/algod/setSyncRound.js.map +1 -1
  38. package/dist/cjs/client/v2/algod/stateproof.js +1 -1
  39. package/dist/cjs/client/v2/algod/stateproof.js.map +1 -1
  40. package/dist/cjs/client/v2/algod/statusAfterBlock.js +1 -3
  41. package/dist/cjs/client/v2/algod/statusAfterBlock.js.map +1 -1
  42. package/dist/cjs/client/v2/indexer/indexer.js.map +1 -1
  43. package/dist/cjs/client/v2/indexer/lookupAccountAppLocalStates.js.map +1 -1
  44. package/dist/cjs/client/v2/indexer/lookupAccountAssets.js.map +1 -1
  45. package/dist/cjs/client/v2/indexer/lookupAccountByID.js.map +1 -1
  46. package/dist/cjs/client/v2/indexer/lookupAccountCreatedApplications.js.map +1 -1
  47. package/dist/cjs/client/v2/indexer/lookupAccountCreatedAssets.js.map +1 -1
  48. package/dist/cjs/client/v2/indexer/lookupAccountTransactions.js.map +1 -1
  49. package/dist/cjs/client/v2/indexer/lookupApplicationBoxByIDandName.js +1 -1
  50. package/dist/cjs/client/v2/indexer/lookupApplicationBoxByIDandName.js.map +1 -1
  51. package/dist/cjs/client/v2/indexer/lookupApplicationLogs.js +1 -1
  52. package/dist/cjs/client/v2/indexer/lookupApplicationLogs.js.map +1 -1
  53. package/dist/cjs/client/v2/indexer/lookupApplications.js +1 -1
  54. package/dist/cjs/client/v2/indexer/lookupApplications.js.map +1 -1
  55. package/dist/cjs/client/v2/indexer/lookupAssetBalances.js +1 -1
  56. package/dist/cjs/client/v2/indexer/lookupAssetBalances.js.map +1 -1
  57. package/dist/cjs/client/v2/indexer/lookupAssetByID.js +1 -1
  58. package/dist/cjs/client/v2/indexer/lookupAssetByID.js.map +1 -1
  59. package/dist/cjs/client/v2/indexer/lookupAssetTransactions.js +1 -1
  60. package/dist/cjs/client/v2/indexer/lookupAssetTransactions.js.map +1 -1
  61. package/dist/cjs/client/v2/indexer/lookupBlock.js +1 -1
  62. package/dist/cjs/client/v2/indexer/lookupBlock.js.map +1 -1
  63. package/dist/cjs/client/v2/indexer/searchAccounts.js.map +1 -1
  64. package/dist/cjs/client/v2/indexer/searchForApplicationBoxes.js +1 -1
  65. package/dist/cjs/client/v2/indexer/searchForApplicationBoxes.js.map +1 -1
  66. package/dist/cjs/client/v2/indexer/searchForApplications.js.map +1 -1
  67. package/dist/cjs/client/v2/indexer/searchForAssets.js.map +1 -1
  68. package/dist/cjs/client/v2/indexer/searchForTransactions.js.map +1 -1
  69. package/dist/cjs/composer.js +1 -1
  70. package/dist/cjs/composer.js.map +1 -1
  71. package/dist/cjs/wait.js +4 -3
  72. package/dist/cjs/wait.js.map +1 -1
  73. package/dist/esm/client/urlTokenBaseHTTPClient.js +1 -1
  74. package/dist/esm/client/urlTokenBaseHTTPClient.js.map +1 -1
  75. package/dist/esm/client/v2/algod/accountApplicationInformation.js +1 -1
  76. package/dist/esm/client/v2/algod/accountApplicationInformation.js.map +1 -1
  77. package/dist/esm/client/v2/algod/accountAssetInformation.js +1 -1
  78. package/dist/esm/client/v2/algod/accountAssetInformation.js.map +1 -1
  79. package/dist/esm/client/v2/algod/algod.js +2 -2
  80. package/dist/esm/client/v2/algod/algod.js.map +1 -1
  81. package/dist/esm/client/v2/algod/block.js +1 -1
  82. package/dist/esm/client/v2/algod/block.js.map +1 -1
  83. package/dist/esm/client/v2/algod/getApplicationBoxByName.js +1 -1
  84. package/dist/esm/client/v2/algod/getApplicationBoxByName.js.map +1 -1
  85. package/dist/esm/client/v2/algod/getApplicationBoxes.js +1 -1
  86. package/dist/esm/client/v2/algod/getApplicationBoxes.js.map +1 -1
  87. package/dist/esm/client/v2/algod/getApplicationByID.js +1 -1
  88. package/dist/esm/client/v2/algod/getApplicationByID.js.map +1 -1
  89. package/dist/esm/client/v2/algod/getAssetByID.js +1 -1
  90. package/dist/esm/client/v2/algod/getAssetByID.js.map +1 -1
  91. package/dist/esm/client/v2/algod/getBlockHash.js +1 -1
  92. package/dist/esm/client/v2/algod/getBlockHash.js.map +1 -1
  93. package/dist/esm/client/v2/algod/getBlockTxids.js +1 -3
  94. package/dist/esm/client/v2/algod/getBlockTxids.js.map +1 -1
  95. package/dist/esm/client/v2/algod/getLedgerStateDelta.js +1 -1
  96. package/dist/esm/client/v2/algod/getLedgerStateDelta.js.map +1 -1
  97. package/dist/esm/client/v2/algod/getTransactionGroupLedgerStateDeltasForRound.js +1 -1
  98. package/dist/esm/client/v2/algod/getTransactionGroupLedgerStateDeltasForRound.js.map +1 -1
  99. package/dist/esm/client/v2/algod/getTransactionProof.js +1 -1
  100. package/dist/esm/client/v2/algod/getTransactionProof.js.map +1 -1
  101. package/dist/esm/client/v2/algod/lightBlockHeaderProof.js +1 -1
  102. package/dist/esm/client/v2/algod/lightBlockHeaderProof.js.map +1 -1
  103. package/dist/esm/client/v2/algod/setBlockOffsetTimestamp.js +1 -1
  104. package/dist/esm/client/v2/algod/setBlockOffsetTimestamp.js.map +1 -1
  105. package/dist/esm/client/v2/algod/setSyncRound.js +1 -1
  106. package/dist/esm/client/v2/algod/setSyncRound.js.map +1 -1
  107. package/dist/esm/client/v2/algod/stateproof.js +1 -1
  108. package/dist/esm/client/v2/algod/stateproof.js.map +1 -1
  109. package/dist/esm/client/v2/algod/statusAfterBlock.js +1 -3
  110. package/dist/esm/client/v2/algod/statusAfterBlock.js.map +1 -1
  111. package/dist/esm/client/v2/indexer/indexer.js.map +1 -1
  112. package/dist/esm/client/v2/indexer/lookupAccountAppLocalStates.js.map +1 -1
  113. package/dist/esm/client/v2/indexer/lookupAccountAssets.js.map +1 -1
  114. package/dist/esm/client/v2/indexer/lookupAccountByID.js.map +1 -1
  115. package/dist/esm/client/v2/indexer/lookupAccountCreatedApplications.js.map +1 -1
  116. package/dist/esm/client/v2/indexer/lookupAccountCreatedAssets.js.map +1 -1
  117. package/dist/esm/client/v2/indexer/lookupAccountTransactions.js.map +1 -1
  118. package/dist/esm/client/v2/indexer/lookupApplicationBoxByIDandName.js +1 -1
  119. package/dist/esm/client/v2/indexer/lookupApplicationBoxByIDandName.js.map +1 -1
  120. package/dist/esm/client/v2/indexer/lookupApplicationLogs.js +1 -1
  121. package/dist/esm/client/v2/indexer/lookupApplicationLogs.js.map +1 -1
  122. package/dist/esm/client/v2/indexer/lookupApplications.js +1 -1
  123. package/dist/esm/client/v2/indexer/lookupApplications.js.map +1 -1
  124. package/dist/esm/client/v2/indexer/lookupAssetBalances.js +1 -1
  125. package/dist/esm/client/v2/indexer/lookupAssetBalances.js.map +1 -1
  126. package/dist/esm/client/v2/indexer/lookupAssetByID.js +1 -1
  127. package/dist/esm/client/v2/indexer/lookupAssetByID.js.map +1 -1
  128. package/dist/esm/client/v2/indexer/lookupAssetTransactions.js +1 -1
  129. package/dist/esm/client/v2/indexer/lookupAssetTransactions.js.map +1 -1
  130. package/dist/esm/client/v2/indexer/lookupBlock.js +1 -1
  131. package/dist/esm/client/v2/indexer/lookupBlock.js.map +1 -1
  132. package/dist/esm/client/v2/indexer/searchAccounts.js.map +1 -1
  133. package/dist/esm/client/v2/indexer/searchForApplicationBoxes.js +1 -1
  134. package/dist/esm/client/v2/indexer/searchForApplicationBoxes.js.map +1 -1
  135. package/dist/esm/client/v2/indexer/searchForApplications.js.map +1 -1
  136. package/dist/esm/client/v2/indexer/searchForAssets.js.map +1 -1
  137. package/dist/esm/client/v2/indexer/searchForTransactions.js.map +1 -1
  138. package/dist/esm/composer.js +1 -1
  139. package/dist/esm/composer.js.map +1 -1
  140. package/dist/esm/wait.js +4 -3
  141. package/dist/esm/wait.js.map +1 -1
  142. package/dist/types/client/v2/algod/accountApplicationInformation.d.ts +2 -2
  143. package/dist/types/client/v2/algod/accountAssetInformation.d.ts +2 -2
  144. package/dist/types/client/v2/algod/algod.d.ts +17 -17
  145. package/dist/types/client/v2/algod/block.d.ts +1 -1
  146. package/dist/types/client/v2/algod/getApplicationBoxByName.d.ts +1 -1
  147. package/dist/types/client/v2/algod/getApplicationBoxes.d.ts +1 -1
  148. package/dist/types/client/v2/algod/getBlockHash.d.ts +2 -2
  149. package/dist/types/client/v2/algod/getBlockTxids.d.ts +2 -2
  150. package/dist/types/client/v2/algod/getLedgerStateDelta.d.ts +1 -1
  151. package/dist/types/client/v2/algod/getTransactionGroupLedgerStateDeltasForRound.d.ts +1 -1
  152. package/dist/types/client/v2/algod/getTransactionProof.d.ts +2 -2
  153. package/dist/types/client/v2/algod/lightBlockHeaderProof.d.ts +1 -1
  154. package/dist/types/client/v2/algod/setBlockOffsetTimestamp.d.ts +1 -1
  155. package/dist/types/client/v2/algod/setSyncRound.d.ts +1 -1
  156. package/dist/types/client/v2/algod/stateproof.d.ts +1 -1
  157. package/dist/types/client/v2/algod/statusAfterBlock.d.ts +1 -1
  158. package/dist/types/client/v2/indexer/indexer.d.ts +8 -8
  159. package/dist/types/client/v2/indexer/lookupAccountAppLocalStates.d.ts +2 -2
  160. package/dist/types/client/v2/indexer/lookupAccountAssets.d.ts +2 -2
  161. package/dist/types/client/v2/indexer/lookupAccountByID.d.ts +1 -1
  162. package/dist/types/client/v2/indexer/lookupAccountCreatedApplications.d.ts +2 -2
  163. package/dist/types/client/v2/indexer/lookupAccountCreatedAssets.d.ts +2 -2
  164. package/dist/types/client/v2/indexer/lookupAccountTransactions.d.ts +6 -6
  165. package/dist/types/client/v2/indexer/lookupApplicationBoxByIDandName.d.ts +1 -1
  166. package/dist/types/client/v2/indexer/lookupApplicationLogs.d.ts +3 -3
  167. package/dist/types/client/v2/indexer/lookupApplications.d.ts +1 -1
  168. package/dist/types/client/v2/indexer/lookupAssetBalances.d.ts +3 -3
  169. package/dist/types/client/v2/indexer/lookupAssetByID.d.ts +1 -1
  170. package/dist/types/client/v2/indexer/lookupAssetTransactions.d.ts +6 -6
  171. package/dist/types/client/v2/indexer/lookupBlock.d.ts +1 -1
  172. package/dist/types/client/v2/indexer/searchAccounts.d.ts +5 -5
  173. package/dist/types/client/v2/indexer/searchForApplicationBoxes.d.ts +1 -1
  174. package/dist/types/client/v2/indexer/searchForApplications.d.ts +1 -1
  175. package/dist/types/client/v2/indexer/searchForAssets.d.ts +1 -1
  176. package/dist/types/client/v2/indexer/searchForTransactions.d.ts +7 -7
  177. package/dist/types/composer.d.ts +1 -1
  178. package/package.json +1 -1
  179. package/src/client/urlTokenBaseHTTPClient.ts +1 -1
  180. package/src/client/v2/algod/accountApplicationInformation.ts +3 -1
  181. package/src/client/v2/algod/accountAssetInformation.ts +3 -1
  182. package/src/client/v2/algod/algod.ts +20 -17
  183. package/src/client/v2/algod/block.ts +3 -3
  184. package/src/client/v2/algod/getApplicationBoxByName.ts +4 -5
  185. package/src/client/v2/algod/getApplicationBoxes.ts +4 -4
  186. package/src/client/v2/algod/getApplicationByID.ts +4 -4
  187. package/src/client/v2/algod/getAssetByID.ts +4 -4
  188. package/src/client/v2/algod/getBlockHash.ts +3 -3
  189. package/src/client/v2/algod/getBlockTxids.ts +3 -5
  190. package/src/client/v2/algod/getLedgerStateDelta.ts +4 -4
  191. package/src/client/v2/algod/getTransactionGroupLedgerStateDeltasForRound.ts +4 -4
  192. package/src/client/v2/algod/getTransactionProof.ts +4 -1
  193. package/src/client/v2/algod/lightBlockHeaderProof.ts +4 -4
  194. package/src/client/v2/algod/setBlockOffsetTimestamp.ts +4 -4
  195. package/src/client/v2/algod/setSyncRound.ts +4 -4
  196. package/src/client/v2/algod/stateproof.ts +4 -4
  197. package/src/client/v2/algod/statusAfterBlock.ts +4 -5
  198. package/src/client/v2/indexer/indexer.ts +8 -8
  199. package/src/client/v2/indexer/lookupAccountAppLocalStates.ts +2 -2
  200. package/src/client/v2/indexer/lookupAccountAssets.ts +2 -2
  201. package/src/client/v2/indexer/lookupAccountByID.ts +1 -1
  202. package/src/client/v2/indexer/lookupAccountCreatedApplications.ts +2 -2
  203. package/src/client/v2/indexer/lookupAccountCreatedAssets.ts +2 -2
  204. package/src/client/v2/indexer/lookupAccountTransactions.ts +6 -6
  205. package/src/client/v2/indexer/lookupApplicationBoxByIDandName.ts +4 -5
  206. package/src/client/v2/indexer/lookupApplicationLogs.ts +6 -6
  207. package/src/client/v2/indexer/lookupApplications.ts +4 -4
  208. package/src/client/v2/indexer/lookupAssetBalances.ts +6 -6
  209. package/src/client/v2/indexer/lookupAssetByID.ts +4 -4
  210. package/src/client/v2/indexer/lookupAssetTransactions.ts +9 -9
  211. package/src/client/v2/indexer/lookupBlock.ts +4 -4
  212. package/src/client/v2/indexer/searchAccounts.ts +5 -5
  213. package/src/client/v2/indexer/searchForApplicationBoxes.ts +4 -4
  214. package/src/client/v2/indexer/searchForApplications.ts +1 -1
  215. package/src/client/v2/indexer/searchForAssets.ts +1 -1
  216. package/src/client/v2/indexer/searchForTransactions.ts +7 -7
  217. package/src/composer.ts +2 -2
  218. package/src/wait.ts +4 -3
@@ -46,7 +46,7 @@ export default class SearchAccounts extends JSONRequest<AccountsResponse> {
46
46
  * @param greater
47
47
  * @category query
48
48
  */
49
- currencyGreaterThan(greater: number): this;
49
+ currencyGreaterThan(greater: number | bigint): this;
50
50
  /**
51
51
  * Filtered results should have an amount less than this value, as int, representing microAlgos, unless an asset-id is provided, in which case units are in the asset's units.
52
52
  *
@@ -73,7 +73,7 @@ export default class SearchAccounts extends JSONRequest<AccountsResponse> {
73
73
  * @param lesser
74
74
  * @category query
75
75
  */
76
- currencyLessThan(lesser: number): this;
76
+ currencyLessThan(lesser: number | bigint): this;
77
77
  /**
78
78
  * Maximum number of results to return.
79
79
  *
@@ -105,7 +105,7 @@ export default class SearchAccounts extends JSONRequest<AccountsResponse> {
105
105
  * @param id
106
106
  * @category query
107
107
  */
108
- assetID(id: number): this;
108
+ assetID(id: number | bigint): this;
109
109
  /**
110
110
  * The next page of results.
111
111
  *
@@ -144,7 +144,7 @@ export default class SearchAccounts extends JSONRequest<AccountsResponse> {
144
144
  * @param round
145
145
  * @category query
146
146
  */
147
- round(round: number): this;
147
+ round(round: number | bigint): this;
148
148
  /**
149
149
  * Include accounts that use this spending key.
150
150
  *
@@ -175,7 +175,7 @@ export default class SearchAccounts extends JSONRequest<AccountsResponse> {
175
175
  * @param applicationID
176
176
  * @category query
177
177
  */
178
- applicationID(applicationID: number): this;
178
+ applicationID(applicationID: number | bigint): this;
179
179
  /**
180
180
  * Includes all items including closed accounts, deleted applications, destroyed assets, opted-out asset holdings, and closed-out application localstates
181
181
  *
@@ -29,7 +29,7 @@ export default class SearchForApplicationBoxes extends JSONRequest<BoxesResponse
29
29
  * @oaram index - application index.
30
30
  * @category GET
31
31
  */
32
- constructor(c: HTTPClient, index: number);
32
+ constructor(c: HTTPClient, index: number | bigint);
33
33
  /**
34
34
  * @returns `/v2/applications/${index}/boxes`
35
35
  */
@@ -33,7 +33,7 @@ export default class SearchForApplications extends JSONRequest<ApplicationsRespo
33
33
  * @param index
34
34
  * @category query
35
35
  */
36
- index(index: number): this;
36
+ index(index: number | bigint): this;
37
37
  /**
38
38
  * Creator for filter, as string
39
39
  *
@@ -97,7 +97,7 @@ export default class SearchForAssets extends JSONRequest<AssetsResponse> {
97
97
  * @param index
98
98
  * @category query
99
99
  */
100
- index(index: number): this;
100
+ index(index: number | bigint): this;
101
101
  /**
102
102
  * Specify the next page of results.
103
103
  *
@@ -98,7 +98,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
98
98
  * @param round
99
99
  * @category query
100
100
  */
101
- round(round: number): this;
101
+ round(round: number | bigint): this;
102
102
  /**
103
103
  * Include results at or after the specified min-round.
104
104
  *
@@ -114,7 +114,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
114
114
  * @param round
115
115
  * @category query
116
116
  */
117
- minRound(round: number): this;
117
+ minRound(round: number | bigint): this;
118
118
  /**
119
119
  * Include results at or before the specified max-round.
120
120
  *
@@ -130,7 +130,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
130
130
  * @param round
131
131
  * @category query
132
132
  */
133
- maxRound(round: number): this;
133
+ maxRound(round: number | bigint): this;
134
134
  /**
135
135
  * Asset ID to filter with.
136
136
  *
@@ -146,7 +146,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
146
146
  * @param id
147
147
  * @category query
148
148
  */
149
- assetID(id: number): this;
149
+ assetID(id: number | bigint): this;
150
150
  /**
151
151
  * Maximum number of results to return.
152
152
  *
@@ -297,7 +297,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
297
297
  * @param applicationID
298
298
  * @category query
299
299
  */
300
- applicationID(applicationID: number): this;
300
+ applicationID(applicationID: number | bigint): this;
301
301
  /**
302
302
  * Filtered results should have an amount greater than this value, as int, representing microAlgos, unless an asset-id is provided, in which case units are in the asset's units.
303
303
  *
@@ -324,7 +324,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
324
324
  * @param greater
325
325
  * @category query
326
326
  */
327
- currencyGreaterThan(greater: number): this;
327
+ currencyGreaterThan(greater: number | bigint): this;
328
328
  /**
329
329
  * Filtered results should have an amount less than this value, as int, representing microAlgos, unless an asset-id is provided, in which case units are in the asset's units.
330
330
  *
@@ -351,6 +351,6 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
351
351
  * @param lesser
352
352
  * @category query
353
353
  */
354
- currencyLessThan(lesser: number): this;
354
+ currencyLessThan(lesser: number | bigint): this;
355
355
  prepare(response: HTTPClientResponse): TransactionsResponse;
356
356
  }
@@ -189,7 +189,7 @@ export declare class AtomicTransactionComposer {
189
189
  * one element for each method call transaction in this group.
190
190
  */
191
191
  execute(client: AlgodClient, waitRounds: number): Promise<{
192
- confirmedRound: number;
192
+ confirmedRound: bigint;
193
193
  txIDs: string[];
194
194
  methodResults: ABIResult[];
195
195
  }>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "algosdk",
3
- "version": "3.0.0-beta.1",
3
+ "version": "3.0.0-beta.2",
4
4
  "description": "The official JavaScript SDK for Algorand",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -95,7 +95,7 @@ export class URLTokenBaseHTTPClient implements BaseHTTPClient {
95
95
  const address = new URL(fixedRelativePath, this.baseURL);
96
96
  if (query) {
97
97
  for (const [key, value] of Object.entries(query)) {
98
- address.searchParams.set(key, value);
98
+ address.searchParams.set(key, value.toString());
99
99
  }
100
100
  }
101
101
  return address.toString();
@@ -6,14 +6,16 @@ import { Address } from '../../../encoding/address.js';
6
6
 
7
7
  export default class AccountApplicationInformation extends JSONRequest<AccountApplicationResponse> {
8
8
  private account: string;
9
+ private applicationID: bigint;
9
10
 
10
11
  constructor(
11
12
  c: HTTPClient,
12
13
  account: string | Address,
13
- private applicationID: number
14
+ applicationID: number | bigint
14
15
  ) {
15
16
  super(c);
16
17
  this.account = account.toString();
18
+ this.applicationID = BigInt(applicationID);
17
19
  }
18
20
 
19
21
  path() {
@@ -6,14 +6,16 @@ import { Address } from '../../../encoding/address.js';
6
6
 
7
7
  export default class AccountAssetInformation extends JSONRequest<AccountAssetResponse> {
8
8
  private account: string;
9
+ private assetID: bigint;
9
10
 
10
11
  constructor(
11
12
  c: HTTPClient,
12
13
  account: string | Address,
13
- private assetID: number
14
+ assetID: number | bigint
14
15
  ) {
15
16
  super(c);
16
17
  this.account = account.toString();
18
+ this.assetID = BigInt(assetID);
17
19
  }
18
20
 
19
21
  path() {
@@ -96,7 +96,7 @@ export class AlgodClient extends ServiceClient {
96
96
  *
97
97
  * #### Example
98
98
  * ```typescript
99
- * const health = await algodClient.healthCheck().do();
99
+ * await algodClient.healthCheck().do();
100
100
  * ```
101
101
  *
102
102
  * [Response data schema details](https://developer.algorand.org/docs/rest-apis/algod/#get-health)
@@ -126,7 +126,7 @@ export class AlgodClient extends ServiceClient {
126
126
  *
127
127
  * #### Example
128
128
  * ```typescript
129
- * const { txId } = await algodClient.sendRawTransaction(signedTxns).do();
129
+ * const { txid } = await algodClient.sendRawTransaction(signedTxns).do();
130
130
  * const result = await waitForConfirmation(algodClient, txid, 3);
131
131
  * ```
132
132
  *
@@ -173,7 +173,7 @@ export class AlgodClient extends ServiceClient {
173
173
  * @param index - The asset ID to look up.
174
174
  * @category GET
175
175
  */
176
- accountAssetInformation(account: string | Address, index: number) {
176
+ accountAssetInformation(account: string | Address, index: number | bigint) {
177
177
  return new AccountAssetInformation(this.c, account, index);
178
178
  }
179
179
 
@@ -192,7 +192,10 @@ export class AlgodClient extends ServiceClient {
192
192
  * @param index - The application ID to look up.
193
193
  * @category GET
194
194
  */
195
- accountApplicationInformation(account: string | Address, index: number) {
195
+ accountApplicationInformation(
196
+ account: string | Address,
197
+ index: number | bigint
198
+ ) {
196
199
  return new AccountApplicationInformation(this.c, account, index);
197
200
  }
198
201
 
@@ -209,7 +212,7 @@ export class AlgodClient extends ServiceClient {
209
212
  * @param roundNumber - The round number of the block to get.
210
213
  * @category GET
211
214
  */
212
- block(roundNumber: number) {
215
+ block(roundNumber: number | bigint) {
213
216
  return new Block(this.c, roundNumber);
214
217
  }
215
218
 
@@ -226,7 +229,7 @@ export class AlgodClient extends ServiceClient {
226
229
  * @param roundNumber - The round number of the block to get.
227
230
  * @category GET
228
231
  */
229
- getBlockHash(roundNumber: number) {
232
+ getBlockHash(roundNumber: number | bigint) {
230
233
  return new GetBlockHash(this.c, roundNumber);
231
234
  }
232
235
 
@@ -243,7 +246,7 @@ export class AlgodClient extends ServiceClient {
243
246
  * @param roundNumber - The round number of the block to get.
244
247
  * @category GET
245
248
  */
246
- getBlockTxids(roundNumber: number) {
249
+ getBlockTxids(roundNumber: number | bigint) {
247
250
  return new GetBlockTxids(this.c, roundNumber);
248
251
  }
249
252
 
@@ -355,7 +358,7 @@ export class AlgodClient extends ServiceClient {
355
358
  * @param round - The number of the round to wait for.
356
359
  * @category GET
357
360
  */
358
- statusAfterBlock(round: number) {
361
+ statusAfterBlock(round: number | bigint) {
359
362
  return new StatusAfterBlock(this.c, round);
360
363
  }
361
364
 
@@ -504,7 +507,7 @@ export class AlgodClient extends ServiceClient {
504
507
  * @param index - The application ID to look up.
505
508
  * @category GET
506
509
  */
507
- getApplicationBoxByName(index: number, boxName: Uint8Array) {
510
+ getApplicationBoxByName(index: number | bigint, boxName: Uint8Array) {
508
511
  return new GetApplicationBoxByName(this.c, index, boxName);
509
512
  }
510
513
 
@@ -522,7 +525,7 @@ export class AlgodClient extends ServiceClient {
522
525
  * @param index - The application ID to look up.
523
526
  * @category GET
524
527
  */
525
- getApplicationBoxes(index: number) {
528
+ getApplicationBoxes(index: number | bigint) {
526
529
  return new GetApplicationBoxes(this.c, index);
527
530
  }
528
531
 
@@ -556,7 +559,7 @@ export class AlgodClient extends ServiceClient {
556
559
  * @param txID - The transaction ID for which to generate a proof.
557
560
  * @category GET
558
561
  */
559
- getTransactionProof(round: number, txID: string) {
562
+ getTransactionProof(round: number | bigint, txID: string) {
560
563
  return new GetTransactionProof(this.c, round, txID);
561
564
  }
562
565
 
@@ -572,7 +575,7 @@ export class AlgodClient extends ServiceClient {
572
575
  * [Response data schema details](https://developer.algorand.org/docs/rest-apis/algod/v2#get-v2blocksroundlightheaderproof)
573
576
  * @param round
574
577
  */
575
- getLightBlockHeaderProof(round: number) {
578
+ getLightBlockHeaderProof(round: number | bigint) {
576
579
  return new LightBlockHeaderProof(this.c, round);
577
580
  }
578
581
 
@@ -588,7 +591,7 @@ export class AlgodClient extends ServiceClient {
588
591
  * [Response data schema details](https://developer.algorand.org/docs/rest-apis/algod/v2#get-v2stateproofsround)
589
592
  * @param round
590
593
  */
591
- getStateProof(round: number) {
594
+ getStateProof(round: number | bigint) {
592
595
  return new StateProof(this.c, round);
593
596
  }
594
597
 
@@ -678,7 +681,7 @@ export class AlgodClient extends ServiceClient {
678
681
  * @param offset
679
682
  * @category POST
680
683
  */
681
- setBlockOffsetTimestamp(offset: number) {
684
+ setBlockOffsetTimestamp(offset: number | bigint) {
682
685
  return new SetBlockOffsetTimestamp(this.c, offset);
683
686
  }
684
687
 
@@ -710,7 +713,7 @@ export class AlgodClient extends ServiceClient {
710
713
  * @param round
711
714
  * @category POST
712
715
  */
713
- setSyncRound(round: number) {
716
+ setSyncRound(round: number | bigint) {
714
717
  return new SetSyncRound(this.c, round);
715
718
  }
716
719
 
@@ -789,7 +792,7 @@ export class AlgodClient extends ServiceClient {
789
792
  * @param round the round number to be searched for
790
793
  * @category GET
791
794
  */
792
- getLedgerStateDelta(round: number) {
795
+ getLedgerStateDelta(round: number | bigint) {
793
796
  return new GetLedgerStateDelta(this.c, round);
794
797
  }
795
798
 
@@ -806,7 +809,7 @@ export class AlgodClient extends ServiceClient {
806
809
  * @param round the round number to be searched for
807
810
  * @category GET
808
811
  */
809
- getTransactionGroupLedgerStateDeltasForRound(round: number) {
812
+ getTransactionGroupLedgerStateDeltasForRound(round: number | bigint) {
810
813
  return new GetTransactionGroupLedgerStateDeltasForRound(this.c, round);
811
814
  }
812
815
  }
@@ -7,11 +7,11 @@ import { BlockResponse } from './models/types.js';
7
7
  * block gets the block info for the given round. this call may block
8
8
  */
9
9
  export default class Block extends JSONRequest<BlockResponse> {
10
- private round: number;
10
+ private round: bigint;
11
11
 
12
- constructor(c: HTTPClient, roundNumber: number) {
12
+ constructor(c: HTTPClient, roundNumber: number | bigint) {
13
13
  super(c);
14
- this.round = roundNumber;
14
+ this.round = BigInt(roundNumber);
15
15
  this.query = { format: 'msgpack' };
16
16
  }
17
17
 
@@ -20,12 +20,11 @@ import { Box } from './models/types.js';
20
20
  * @category GET
21
21
  */
22
22
  export default class GetApplicationBoxByName extends JSONRequest<Box> {
23
- constructor(
24
- c: HTTPClient,
25
- private index: number,
26
- name: Uint8Array
27
- ) {
23
+ private index: bigint;
24
+
25
+ constructor(c: HTTPClient, index: number | bigint, name: Uint8Array) {
28
26
  super(c);
27
+ this.index = BigInt(index);
29
28
  // Encode name in base64 format and append the encoding prefix.
30
29
  const encodedName = bytesToBase64(name);
31
30
  this.query.name = encodeURI(`b64:${encodedName}`);
@@ -18,11 +18,11 @@ import { BoxesResponse } from './models/types.js';
18
18
  * @category GET
19
19
  */
20
20
  export default class GetApplicationBoxes extends JSONRequest<BoxesResponse> {
21
- constructor(
22
- c: HTTPClient,
23
- private index: number
24
- ) {
21
+ private index: bigint;
22
+
23
+ constructor(c: HTTPClient, index: number | bigint) {
25
24
  super(c);
25
+ this.index = BigInt(index);
26
26
  this.query.max = 0;
27
27
  }
28
28
 
@@ -4,11 +4,11 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { Application } from './models/types.js';
5
5
 
6
6
  export default class GetApplicationByID extends JSONRequest<Application> {
7
- constructor(
8
- c: HTTPClient,
9
- private index: number | bigint
10
- ) {
7
+ private index: bigint;
8
+
9
+ constructor(c: HTTPClient, index: number | bigint) {
11
10
  super(c);
11
+ this.index = BigInt(index);
12
12
  }
13
13
 
14
14
  path() {
@@ -4,11 +4,11 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { Asset } from './models/types.js';
5
5
 
6
6
  export default class GetAssetByID extends JSONRequest<Asset> {
7
- constructor(
8
- c: HTTPClient,
9
- private index: number | bigint
10
- ) {
7
+ private index: bigint;
8
+
9
+ constructor(c: HTTPClient, index: number | bigint) {
11
10
  super(c);
11
+ this.index = BigInt(index);
12
12
  }
13
13
 
14
14
  path() {
@@ -4,11 +4,11 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { BlockHashResponse } from './models/types.js';
5
5
 
6
6
  export default class GetBlockHash extends JSONRequest<BlockHashResponse> {
7
- round: number | bigint;
7
+ private round: bigint;
8
8
 
9
- constructor(c: HTTPClient, roundNumber: number) {
9
+ constructor(c: HTTPClient, roundNumber: number | bigint) {
10
10
  super(c);
11
- this.round = roundNumber;
11
+ this.round = BigInt(roundNumber);
12
12
  }
13
13
 
14
14
  path() {
@@ -4,13 +4,11 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { BlockTxidsResponse } from './models/types.js';
5
5
 
6
6
  export default class GetBlockTxids extends JSONRequest<BlockTxidsResponse> {
7
- round: number;
7
+ private round: bigint;
8
8
 
9
- constructor(c: HTTPClient, roundNumber: number) {
9
+ constructor(c: HTTPClient, roundNumber: number | bigint) {
10
10
  super(c);
11
- if (!Number.isInteger(roundNumber))
12
- throw Error('roundNumber should be an integer');
13
- this.round = roundNumber;
11
+ this.round = BigInt(roundNumber);
14
12
  }
15
13
 
16
14
  path() {
@@ -4,11 +4,11 @@ import { decodeMsgpack } from '../../../encoding/encoding.js';
4
4
  import { LedgerStateDelta } from '../../../types/statedelta.js';
5
5
 
6
6
  export default class GetLedgerStateDelta extends JSONRequest<LedgerStateDelta> {
7
- constructor(
8
- c: HTTPClient,
9
- private round: number
10
- ) {
7
+ private round: bigint;
8
+
9
+ constructor(c: HTTPClient, round: number | bigint) {
11
10
  super(c);
11
+ this.round = BigInt(round);
12
12
  this.query = { format: 'msgpack' };
13
13
  }
14
14
 
@@ -4,11 +4,11 @@ import { HTTPClient, HTTPClientResponse } from '../../client.js';
4
4
  import { decodeMsgpack } from '../../../encoding/encoding.js';
5
5
 
6
6
  export default class GetTransactionGroupLedgerStateDeltasForRound extends JSONRequest<TransactionGroupLedgerStateDeltasForRoundResponse> {
7
- constructor(
8
- c: HTTPClient,
9
- private round: number
10
- ) {
7
+ private round: bigint;
8
+
9
+ constructor(c: HTTPClient, round: number | bigint) {
11
10
  super(c);
11
+ this.round = BigInt(round);
12
12
  this.query = { format: 'msgpack' };
13
13
  }
14
14
 
@@ -4,12 +4,15 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { TransactionProofResponse } from './models/types.js';
5
5
 
6
6
  export default class GetTransactionProof extends JSONRequest<TransactionProofResponse> {
7
+ private round: bigint;
8
+
7
9
  constructor(
8
10
  c: HTTPClient,
9
- private round: number,
11
+ round: number | bigint,
10
12
  private txID: string
11
13
  ) {
12
14
  super(c);
15
+ this.round = BigInt(round);
13
16
  }
14
17
 
15
18
  path() {
@@ -4,11 +4,11 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { LightBlockHeaderProof as LBHP } from './models/types.js';
5
5
 
6
6
  export default class LightBlockHeaderProof extends JSONRequest<LBHP> {
7
- constructor(
8
- c: HTTPClient,
9
- private round: number
10
- ) {
7
+ private round: bigint;
8
+
9
+ constructor(c: HTTPClient, round: number | bigint) {
11
10
  super(c);
11
+ this.round = BigInt(round);
12
12
  }
13
13
 
14
14
  path() {
@@ -2,11 +2,11 @@ import JSONRequest from '../jsonrequest.js';
2
2
  import { HTTPClient, HTTPClientResponse } from '../../client.js';
3
3
 
4
4
  export default class SetBlockOffsetTimestamp extends JSONRequest<void> {
5
- constructor(
6
- c: HTTPClient,
7
- private offset: number
8
- ) {
5
+ private offset: bigint;
6
+
7
+ constructor(c: HTTPClient, offset: number | bigint) {
9
8
  super(c);
9
+ this.offset = BigInt(offset);
10
10
  }
11
11
 
12
12
  path() {
@@ -2,11 +2,11 @@ import JSONRequest from '../jsonrequest.js';
2
2
  import { HTTPClient, HTTPClientResponse } from '../../client.js';
3
3
 
4
4
  export default class SetSyncRound extends JSONRequest<void> {
5
- constructor(
6
- c: HTTPClient,
7
- private round: number
8
- ) {
5
+ private round: bigint;
6
+
7
+ constructor(c: HTTPClient, round: number | bigint) {
9
8
  super(c);
9
+ this.round = BigInt(round);
10
10
  }
11
11
 
12
12
  path() {
@@ -4,11 +4,11 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { StateProof as SP } from './models/types.js';
5
5
 
6
6
  export default class StateProof extends JSONRequest<SP> {
7
- constructor(
8
- c: HTTPClient,
9
- private round: number
10
- ) {
7
+ private round: bigint;
8
+
9
+ constructor(c: HTTPClient, round: number | bigint) {
11
10
  super(c);
11
+ this.round = BigInt(round);
12
12
  }
13
13
 
14
14
  path() {
@@ -4,12 +4,11 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { NodeStatusResponse } from './models/types.js';
5
5
 
6
6
  export default class StatusAfterBlock extends JSONRequest<NodeStatusResponse> {
7
- constructor(
8
- c: HTTPClient,
9
- private round: number
10
- ) {
7
+ private round: bigint;
8
+
9
+ constructor(c: HTTPClient, round: number | bigint) {
11
10
  super(c);
12
- if (!Number.isInteger(round)) throw Error('round should be an integer');
11
+ this.round = BigInt(round);
13
12
  }
14
13
 
15
14
  path() {