algosdk 3.0.0-beta.1 → 3.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.
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
@@ -104,7 +104,7 @@ export class IndexerClient extends ServiceClient {
104
104
  * @param index - The asset ID to look up.
105
105
  * @category GET
106
106
  */
107
- lookupAssetBalances(index: number) {
107
+ lookupAssetBalances(index: number | bigint) {
108
108
  return new LookupAssetBalances(this.c, index);
109
109
  }
110
110
 
@@ -121,7 +121,7 @@ export class IndexerClient extends ServiceClient {
121
121
  * @param index - The asset ID to look up.
122
122
  * @category GET
123
123
  */
124
- lookupAssetTransactions(index: number) {
124
+ lookupAssetTransactions(index: number | bigint) {
125
125
  return new LookupAssetTransactions(this.c, index);
126
126
  }
127
127
 
@@ -155,7 +155,7 @@ export class IndexerClient extends ServiceClient {
155
155
  * @param round - The number of the round to look up.
156
156
  * @category GET
157
157
  */
158
- lookupBlock(round: number) {
158
+ lookupBlock(round: number | bigint) {
159
159
  return new LookupBlock(this.c, round);
160
160
  }
161
161
 
@@ -274,7 +274,7 @@ export class IndexerClient extends ServiceClient {
274
274
  * @param index - The ID of the asset ot look up.
275
275
  * @category GET
276
276
  */
277
- lookupAssetByID(index: number) {
277
+ lookupAssetByID(index: number | bigint) {
278
278
  return new LookupAssetByID(this.c, index);
279
279
  }
280
280
 
@@ -291,7 +291,7 @@ export class IndexerClient extends ServiceClient {
291
291
  * @param index - The ID of the application to look up.
292
292
  * @category GET
293
293
  */
294
- lookupApplications(index: number) {
294
+ lookupApplications(index: number | bigint) {
295
295
  return new LookupApplications(this.c, index);
296
296
  }
297
297
 
@@ -308,7 +308,7 @@ export class IndexerClient extends ServiceClient {
308
308
  * @param appID - The ID of the application which generated the logs.
309
309
  * @category GET
310
310
  */
311
- lookupApplicationLogs(appID: number) {
311
+ lookupApplicationLogs(appID: number | bigint) {
312
312
  return new LookupApplicationLogs(this.c, appID);
313
313
  }
314
314
 
@@ -398,7 +398,7 @@ export class IndexerClient extends ServiceClient {
398
398
  * @param appID - The ID of the application with boxes.
399
399
  * @category GET
400
400
  */
401
- searchForApplicationBoxes(appID: number) {
401
+ searchForApplicationBoxes(appID: number | bigint) {
402
402
  return new SearchForApplicationBoxes(this.c, appID);
403
403
  }
404
404
 
@@ -418,7 +418,7 @@ export class IndexerClient extends ServiceClient {
418
418
  * @param appID - The ID of the application with boxes.
419
419
  * @category GET
420
420
  */
421
- lookupApplicationBoxByIDandName(appID: number, boxName: Uint8Array) {
421
+ lookupApplicationBoxByIDandName(appID: number | bigint, boxName: Uint8Array) {
422
422
  return new LookupApplicationBoxByIDandName(this.c, appID, boxName);
423
423
  }
424
424
  }
@@ -68,7 +68,7 @@ export default class LookupAccountAppLocalStates extends JSONRequest<Application
68
68
  * @param round
69
69
  * @category query
70
70
  */
71
- round(round: number) {
71
+ round(round: number | bigint) {
72
72
  this.query.round = round;
73
73
  return this;
74
74
  }
@@ -133,7 +133,7 @@ export default class LookupAccountAppLocalStates extends JSONRequest<Application
133
133
  * @param index - the applicationID
134
134
  * @category query
135
135
  */
136
- applicationID(index: number) {
136
+ applicationID(index: number | bigint) {
137
137
  this.query['application-id'] = index;
138
138
  return this;
139
139
  }
@@ -68,7 +68,7 @@ export default class LookupAccountAssets extends JSONRequest<AssetHoldingsRespon
68
68
  * @param round
69
69
  * @category query
70
70
  */
71
- round(round: number) {
71
+ round(round: number | bigint) {
72
72
  this.query.round = round;
73
73
  return this;
74
74
  }
@@ -134,7 +134,7 @@ export default class LookupAccountAssets extends JSONRequest<AssetHoldingsRespon
134
134
  * @param index - the assetID
135
135
  * @category query
136
136
  */
137
- assetId(index: number) {
137
+ assetId(index: number | bigint) {
138
138
  this.query['asset-id'] = index;
139
139
  return this;
140
140
  }
@@ -46,7 +46,7 @@ export default class LookupAccountByID extends JSONRequest<AccountResponse> {
46
46
  * ```
47
47
  * @param round
48
48
  */
49
- round(round: number) {
49
+ round(round: number | bigint) {
50
50
  this.query.round = round;
51
51
  return this;
52
52
  }
@@ -68,7 +68,7 @@ export default class LookupAccountCreatedApplications extends JSONRequest<Applic
68
68
  * @param round
69
69
  * @category query
70
70
  */
71
- round(round: number) {
71
+ round(round: number | bigint) {
72
72
  this.query.round = round;
73
73
  return this;
74
74
  }
@@ -134,7 +134,7 @@ export default class LookupAccountCreatedApplications extends JSONRequest<Applic
134
134
  * @param index - the applicationID
135
135
  * @category query
136
136
  */
137
- applicationID(index: number) {
137
+ applicationID(index: number | bigint) {
138
138
  this.query['application-id'] = index;
139
139
  return this;
140
140
  }
@@ -68,7 +68,7 @@ export default class LookupAccountCreatedAssets extends JSONRequest<AssetsRespon
68
68
  * @param round
69
69
  * @category query
70
70
  */
71
- round(round: number) {
71
+ round(round: number | bigint) {
72
72
  this.query.round = round;
73
73
  return this;
74
74
  }
@@ -135,7 +135,7 @@ export default class LookupAccountCreatedAssets extends JSONRequest<AssetsRespon
135
135
  * @param index - the assetID
136
136
  * @category query
137
137
  */
138
- assetID(index: number) {
138
+ assetID(index: number | bigint) {
139
139
  this.query['asset-id'] = index;
140
140
  return this;
141
141
  }
@@ -145,7 +145,7 @@ export default class LookupAccountTransactions extends JSONRequest<TransactionsR
145
145
  * @param round
146
146
  * @category query
147
147
  */
148
- round(round: number) {
148
+ round(round: number | bigint) {
149
149
  this.query.round = round;
150
150
  return this;
151
151
  }
@@ -166,7 +166,7 @@ export default class LookupAccountTransactions extends JSONRequest<TransactionsR
166
166
  * @param round
167
167
  * @category query
168
168
  */
169
- minRound(round: number) {
169
+ minRound(round: number | bigint) {
170
170
  this.query['min-round'] = round;
171
171
  return this;
172
172
  }
@@ -187,7 +187,7 @@ export default class LookupAccountTransactions extends JSONRequest<TransactionsR
187
187
  * @param round
188
188
  * @category query
189
189
  */
190
- maxRound(round: number) {
190
+ maxRound(round: number | bigint) {
191
191
  this.query['max-round'] = round;
192
192
  return this;
193
193
  }
@@ -208,7 +208,7 @@ export default class LookupAccountTransactions extends JSONRequest<TransactionsR
208
208
  * @param id
209
209
  * @category query
210
210
  */
211
- assetID(id: number) {
211
+ assetID(id: number | bigint) {
212
212
  this.query['asset-id'] = id;
213
213
  return this;
214
214
  }
@@ -306,7 +306,7 @@ export default class LookupAccountTransactions extends JSONRequest<TransactionsR
306
306
  * @param greater
307
307
  * @category query
308
308
  */
309
- currencyGreaterThan(greater: number) {
309
+ currencyGreaterThan(greater: number | bigint) {
310
310
  // We convert the following to a string for now to correctly include zero values in request parameters.
311
311
  this.query['currency-greater-than'] = greater.toString();
312
312
  return this;
@@ -340,7 +340,7 @@ export default class LookupAccountTransactions extends JSONRequest<TransactionsR
340
340
  * @param lesser
341
341
  * @category query
342
342
  */
343
- currencyLessThan(lesser: number) {
343
+ currencyLessThan(lesser: number | bigint) {
344
344
  this.query['currency-less-than'] = lesser;
345
345
  return this;
346
346
  }
@@ -5,6 +5,8 @@ import JSONRequest from '../jsonrequest.js';
5
5
  import { Box } from './models/types.js';
6
6
 
7
7
  export default class LookupApplicationBoxByIDandName extends JSONRequest<Box> {
8
+ private index: bigint;
9
+
8
10
  /**
9
11
  * Returns information about indexed application boxes.
10
12
  *
@@ -21,12 +23,9 @@ export default class LookupApplicationBoxByIDandName extends JSONRequest<Box> {
21
23
  * @oaram index - application index.
22
24
  * @category GET
23
25
  */
24
- constructor(
25
- c: HTTPClient,
26
- private index: number,
27
- boxName: Uint8Array
28
- ) {
26
+ constructor(c: HTTPClient, index: number | bigint, boxName: Uint8Array) {
29
27
  super(c);
28
+ this.index = BigInt(index);
30
29
  // Encode query in base64 format and append the encoding prefix.
31
30
  const encodedName = bytesToBase64(boxName);
32
31
  this.query.name = encodeURI(`b64:${encodedName}`);
@@ -4,6 +4,8 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { ApplicationLogsResponse } from './models/types.js';
5
5
 
6
6
  export default class LookupApplicationLogs extends JSONRequest<ApplicationLogsResponse> {
7
+ private appID: bigint;
8
+
7
9
  /**
8
10
  * Returns log messages generated by the passed in application.
9
11
  *
@@ -17,11 +19,9 @@ export default class LookupApplicationLogs extends JSONRequest<ApplicationLogsRe
17
19
  * @param appID - The ID of the application which generated the logs.
18
20
  * @category GET
19
21
  */
20
- constructor(
21
- c: HTTPClient,
22
- private appID: number
23
- ) {
22
+ constructor(c: HTTPClient, appID: number | bigint) {
24
23
  super(c);
24
+ this.appID = BigInt(appID);
25
25
  }
26
26
 
27
27
  /**
@@ -65,7 +65,7 @@ export default class LookupApplicationLogs extends JSONRequest<ApplicationLogsRe
65
65
  * @param round
66
66
  * @category query
67
67
  */
68
- minRound(round: number) {
68
+ minRound(round: number | bigint) {
69
69
  this.query['min-round'] = round;
70
70
  return this;
71
71
  }
@@ -85,7 +85,7 @@ export default class LookupApplicationLogs extends JSONRequest<ApplicationLogsRe
85
85
  * @param round
86
86
  * @category query
87
87
  */
88
- maxRound(round: number) {
88
+ maxRound(round: number | bigint) {
89
89
  this.query['max-round'] = round;
90
90
  return this;
91
91
  }
@@ -4,6 +4,8 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { ApplicationResponse } from './models/types.js';
5
5
 
6
6
  export default class LookupApplications extends JSONRequest<ApplicationResponse> {
7
+ private index: bigint;
8
+
7
9
  /**
8
10
  * Returns information about the passed application.
9
11
  *
@@ -17,11 +19,9 @@ export default class LookupApplications extends JSONRequest<ApplicationResponse>
17
19
  * @param index - The ID of the application to look up.
18
20
  * @category GET
19
21
  */
20
- constructor(
21
- c: HTTPClient,
22
- private index: number
23
- ) {
22
+ constructor(c: HTTPClient, index: number | bigint) {
24
23
  super(c);
24
+ this.index = BigInt(index);
25
25
  }
26
26
 
27
27
  /**
@@ -4,6 +4,8 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { AssetBalancesResponse } from './models/types.js';
5
5
 
6
6
  export default class LookupAssetBalances extends JSONRequest<AssetBalancesResponse> {
7
+ private index: bigint;
8
+
7
9
  /**
8
10
  * Returns the list of accounts which hold the given asset and their balance.
9
11
  *
@@ -16,11 +18,9 @@ export default class LookupAssetBalances extends JSONRequest<AssetBalancesRespon
16
18
  * [Response data schema details](https://developer.algorand.org/docs/rest-apis/indexer/#get-v2assetsasset-idbalances)
17
19
  * @param index - The asset ID to look up.
18
20
  */
19
- constructor(
20
- c: HTTPClient,
21
- private index: number
22
- ) {
21
+ constructor(c: HTTPClient, index: number | bigint) {
23
22
  super(c);
23
+ this.index = BigInt(index);
24
24
  }
25
25
 
26
26
  /**
@@ -66,7 +66,7 @@ export default class LookupAssetBalances extends JSONRequest<AssetBalancesRespon
66
66
  * @param greater
67
67
  * @category query
68
68
  */
69
- currencyGreaterThan(greater: number) {
69
+ currencyGreaterThan(greater: number | bigint) {
70
70
  // We convert the following to a string for now to correctly include zero values in request parameters.
71
71
  this.query['currency-greater-than'] = greater.toString();
72
72
  return this;
@@ -87,7 +87,7 @@ export default class LookupAssetBalances extends JSONRequest<AssetBalancesRespon
87
87
  * @param lesser
88
88
  * @category query
89
89
  */
90
- currencyLessThan(lesser: number) {
90
+ currencyLessThan(lesser: number | bigint) {
91
91
  this.query['currency-less-than'] = lesser;
92
92
  return this;
93
93
  }
@@ -4,6 +4,8 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { AssetResponse } from './models/types.js';
5
5
 
6
6
  export default class LookupAssetByID extends JSONRequest<AssetResponse> {
7
+ private index: bigint;
8
+
7
9
  /**
8
10
  * Returns asset information of the queried asset.
9
11
  *
@@ -16,11 +18,9 @@ export default class LookupAssetByID extends JSONRequest<AssetResponse> {
16
18
  * [Response data schema details](https://developer.algorand.org/docs/rest-apis/indexer/#get-v2assetsasset-id)
17
19
  * @param index - The asset ID to look up.
18
20
  */
19
- constructor(
20
- c: HTTPClient,
21
- private index: number
22
- ) {
21
+ constructor(c: HTTPClient, index: number | bigint) {
23
22
  super(c);
23
+ this.index = BigInt(index);
24
24
  }
25
25
 
26
26
  /**
@@ -6,6 +6,8 @@ import { Address } from '../../../encoding/address.js';
6
6
  import { TransactionsResponse } from './models/types.js';
7
7
 
8
8
  export default class LookupAssetTransactions extends JSONRequest<TransactionsResponse> {
9
+ private index: bigint;
10
+
9
11
  /**
10
12
  * Returns transactions relating to the given asset.
11
13
  *
@@ -18,11 +20,9 @@ export default class LookupAssetTransactions extends JSONRequest<TransactionsRes
18
20
  * [Response data schema details](https://developer.algorand.org/docs/rest-apis/indexer/#get-v2assetsasset-idtransactions)
19
21
  * @param index - The asset ID to look up.
20
22
  */
21
- constructor(
22
- c: HTTPClient,
23
- private index: number
24
- ) {
23
+ constructor(c: HTTPClient, index: number | bigint) {
25
24
  super(c);
25
+ this.index = BigInt(index);
26
26
  }
27
27
 
28
28
  /**
@@ -133,7 +133,7 @@ export default class LookupAssetTransactions extends JSONRequest<TransactionsRes
133
133
  * @param round
134
134
  * @category query
135
135
  */
136
- round(round: number) {
136
+ round(round: number | bigint) {
137
137
  this.query.round = round;
138
138
  return this;
139
139
  }
@@ -154,7 +154,7 @@ export default class LookupAssetTransactions extends JSONRequest<TransactionsRes
154
154
  * @param round
155
155
  * @category query
156
156
  */
157
- minRound(round: number) {
157
+ minRound(round: number | bigint) {
158
158
  this.query['min-round'] = round;
159
159
  return this;
160
160
  }
@@ -175,7 +175,7 @@ export default class LookupAssetTransactions extends JSONRequest<TransactionsRes
175
175
  * @param round
176
176
  * @category query
177
177
  */
178
- maxRound(round: number) {
178
+ maxRound(round: number | bigint) {
179
179
  this.query['max-round'] = round;
180
180
  return this;
181
181
  }
@@ -261,7 +261,7 @@ export default class LookupAssetTransactions extends JSONRequest<TransactionsRes
261
261
  * @param greater
262
262
  * @category query
263
263
  */
264
- currencyGreaterThan(greater: number) {
264
+ currencyGreaterThan(greater: number | bigint) {
265
265
  // We convert the following to a string for now to correctly include zero values in request parameters.
266
266
  this.query['currency-greater-than'] = greater.toString();
267
267
  return this;
@@ -283,7 +283,7 @@ export default class LookupAssetTransactions extends JSONRequest<TransactionsRes
283
283
  * @param lesser
284
284
  * @category query
285
285
  */
286
- currencyLessThan(lesser: number) {
286
+ currencyLessThan(lesser: number | bigint) {
287
287
  this.query['currency-less-than'] = lesser;
288
288
  return this;
289
289
  }
@@ -4,6 +4,8 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { Block } from './models/types.js';
5
5
 
6
6
  export default class LookupBlock extends JSONRequest<Block> {
7
+ private round: bigint;
8
+
7
9
  /**
8
10
  * Returns the block for the passed round.
9
11
  *
@@ -17,11 +19,9 @@ export default class LookupBlock extends JSONRequest<Block> {
17
19
  * @param round - The number of the round to look up.
18
20
  * @category GET
19
21
  */
20
- constructor(
21
- c: HTTPClient,
22
- private round: number
23
- ) {
22
+ constructor(c: HTTPClient, round: number | bigint) {
24
23
  super(c);
24
+ this.round = BigInt(round);
25
25
  }
26
26
 
27
27
  /**
@@ -52,7 +52,7 @@ export default class SearchAccounts extends JSONRequest<AccountsResponse> {
52
52
  * @param greater
53
53
  * @category query
54
54
  */
55
- currencyGreaterThan(greater: number) {
55
+ currencyGreaterThan(greater: number | bigint) {
56
56
  // We convert the following to a string for now to correctly include zero values in request parameters.
57
57
  this.query['currency-greater-than'] = greater.toString();
58
58
  return this;
@@ -84,7 +84,7 @@ export default class SearchAccounts extends JSONRequest<AccountsResponse> {
84
84
  * @param lesser
85
85
  * @category query
86
86
  */
87
- currencyLessThan(lesser: number) {
87
+ currencyLessThan(lesser: number | bigint) {
88
88
  this.query['currency-less-than'] = lesser;
89
89
  return this;
90
90
  }
@@ -124,7 +124,7 @@ export default class SearchAccounts extends JSONRequest<AccountsResponse> {
124
124
  * @param id
125
125
  * @category query
126
126
  */
127
- assetID(id: number) {
127
+ assetID(id: number | bigint) {
128
128
  this.query['asset-id'] = id;
129
129
  return this;
130
130
  }
@@ -171,7 +171,7 @@ export default class SearchAccounts extends JSONRequest<AccountsResponse> {
171
171
  * @param round
172
172
  * @category query
173
173
  */
174
- round(round: number) {
174
+ round(round: number | bigint) {
175
175
  this.query.round = round;
176
176
  return this;
177
177
  }
@@ -210,7 +210,7 @@ export default class SearchAccounts extends JSONRequest<AccountsResponse> {
210
210
  * @param applicationID
211
211
  * @category query
212
212
  */
213
- applicationID(applicationID: number) {
213
+ applicationID(applicationID: number | bigint) {
214
214
  this.query['application-id'] = applicationID;
215
215
  return this;
216
216
  }
@@ -4,6 +4,8 @@ import { decodeJSON } from '../../../encoding/encoding.js';
4
4
  import { BoxesResponse } from './models/types.js';
5
5
 
6
6
  export default class SearchForApplicationBoxes extends JSONRequest<BoxesResponse> {
7
+ private index: bigint;
8
+
7
9
  /**
8
10
  * Returns information about indexed application boxes.
9
11
  *
@@ -30,11 +32,9 @@ export default class SearchForApplicationBoxes extends JSONRequest<BoxesResponse
30
32
  * @oaram index - application index.
31
33
  * @category GET
32
34
  */
33
- constructor(
34
- c: HTTPClient,
35
- private index: number
36
- ) {
35
+ constructor(c: HTTPClient, index: number | bigint) {
37
36
  super(c);
37
+ this.index = BigInt(index);
38
38
  }
39
39
 
40
40
  /**
@@ -39,7 +39,7 @@ export default class SearchForApplications extends JSONRequest<ApplicationsRespo
39
39
  * @param index
40
40
  * @category query
41
41
  */
42
- index(index: number) {
42
+ index(index: number | bigint) {
43
43
  this.query['application-id'] = index;
44
44
  return this;
45
45
  }
@@ -119,7 +119,7 @@ export default class SearchForAssets extends JSONRequest<AssetsResponse> {
119
119
  * @param index
120
120
  * @category query
121
121
  */
122
- index(index: number) {
122
+ index(index: number | bigint) {
123
123
  this.query['asset-id'] = index;
124
124
  return this;
125
125
  }
@@ -121,7 +121,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
121
121
  * @param round
122
122
  * @category query
123
123
  */
124
- round(round: number) {
124
+ round(round: number | bigint) {
125
125
  this.query.round = round;
126
126
  return this;
127
127
  }
@@ -141,7 +141,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
141
141
  * @param round
142
142
  * @category query
143
143
  */
144
- minRound(round: number) {
144
+ minRound(round: number | bigint) {
145
145
  this.query['min-round'] = round;
146
146
  return this;
147
147
  }
@@ -161,7 +161,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
161
161
  * @param round
162
162
  * @category query
163
163
  */
164
- maxRound(round: number) {
164
+ maxRound(round: number | bigint) {
165
165
  this.query['max-round'] = round;
166
166
  return this;
167
167
  }
@@ -181,7 +181,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
181
181
  * @param id
182
182
  * @category query
183
183
  */
184
- assetID(id: number) {
184
+ assetID(id: number | bigint) {
185
185
  this.query['asset-id'] = id;
186
186
  return this;
187
187
  }
@@ -370,7 +370,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
370
370
  * @param applicationID
371
371
  * @category query
372
372
  */
373
- applicationID(applicationID: number) {
373
+ applicationID(applicationID: number | bigint) {
374
374
  this.query['application-id'] = applicationID;
375
375
  return this;
376
376
  }
@@ -401,7 +401,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
401
401
  * @param greater
402
402
  * @category query
403
403
  */
404
- currencyGreaterThan(greater: number) {
404
+ currencyGreaterThan(greater: number | bigint) {
405
405
  // We convert the following to a string for now to correctly include zero values in request parameters.
406
406
  this.query['currency-greater-than'] = greater.toString();
407
407
  return this;
@@ -433,7 +433,7 @@ export default class SearchForTransactions extends JSONRequest<TransactionsRespo
433
433
  * @param lesser
434
434
  * @category query
435
435
  */
436
- currencyLessThan(lesser: number) {
436
+ currencyLessThan(lesser: number | bigint) {
437
437
  this.query['currency-less-than'] = lesser;
438
438
  return this;
439
439
  }
package/src/composer.ts CHANGED
@@ -716,7 +716,7 @@ export class AtomicTransactionComposer {
716
716
  client: AlgodClient,
717
717
  waitRounds: number
718
718
  ): Promise<{
719
- confirmedRound: number;
719
+ confirmedRound: bigint;
720
720
  txIDs: string[];
721
721
  methodResults: ABIResult[];
722
722
  }> {
@@ -741,7 +741,7 @@ export class AtomicTransactionComposer {
741
741
  );
742
742
  this.status = AtomicTransactionComposerStatus.COMMITTED;
743
743
 
744
- const confirmedRound = Number(confirmedTxnInfo.confirmedRound);
744
+ const confirmedRound = confirmedTxnInfo.confirmedRound!;
745
745
 
746
746
  const methodResults: ABIResult[] = [];
747
747
 
package/src/wait.ts CHANGED
@@ -22,11 +22,12 @@ export async function waitForConfirmation(
22
22
  if (typeof status === 'undefined') {
23
23
  throw new Error('Unable to get node status');
24
24
  }
25
- const startRound = Number(status.lastRound) + 1;
25
+ const startRound = status.lastRound + BigInt(1);
26
+ const stopRound = startRound + BigInt(waitRounds);
26
27
  let currentRound = startRound;
27
28
 
28
29
  /* eslint-disable no-await-in-loop */
29
- while (currentRound < startRound + waitRounds) {
30
+ while (currentRound < stopRound) {
30
31
  let poolError = false;
31
32
  try {
32
33
  const pendingInfo = await client.pendingTransactionInformation(txid).do();
@@ -52,7 +53,7 @@ export async function waitForConfirmation(
52
53
  }
53
54
 
54
55
  await client.statusAfterBlock(currentRound).do();
55
- currentRound += 1;
56
+ currentRound += BigInt(1);
56
57
  }
57
58
  /* eslint-enable no-await-in-loop */
58
59
  throw new Error(`Transaction not confirmed after ${waitRounds} rounds`);