@aztec/aztec.js 0.0.1-commit.c7c42ec → 0.0.1-commit.cd76b27

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 (197) hide show
  1. package/dest/account/account.d.ts +25 -40
  2. package/dest/account/account.d.ts.map +1 -1
  3. package/dest/account/account.js +19 -47
  4. package/dest/account/account_contract.d.ts +8 -9
  5. package/dest/account/account_contract.d.ts.map +1 -1
  6. package/dest/account/account_with_secret_key.d.ts +19 -7
  7. package/dest/account/account_with_secret_key.d.ts.map +1 -1
  8. package/dest/account/account_with_secret_key.js +21 -4
  9. package/dest/account/index.d.ts +3 -2
  10. package/dest/account/index.d.ts.map +1 -1
  11. package/dest/account/index.js +2 -0
  12. package/dest/account/signerless_account.d.ts +5 -6
  13. package/dest/account/signerless_account.d.ts.map +1 -1
  14. package/dest/account/signerless_account.js +8 -11
  15. package/dest/api/account.d.ts +2 -4
  16. package/dest/api/account.d.ts.map +1 -1
  17. package/dest/api/account.js +1 -3
  18. package/dest/api/authorization.d.ts +2 -2
  19. package/dest/api/authorization.d.ts.map +1 -1
  20. package/dest/api/authorization.js +1 -1
  21. package/dest/api/contract.d.ts +18 -12
  22. package/dest/api/contract.d.ts.map +1 -1
  23. package/dest/api/contract.js +16 -10
  24. package/dest/api/deployment.d.ts +1 -2
  25. package/dest/api/deployment.d.ts.map +1 -1
  26. package/dest/api/deployment.js +0 -1
  27. package/dest/api/events.d.ts +10 -6
  28. package/dest/api/events.d.ts.map +1 -1
  29. package/dest/api/events.js +30 -20
  30. package/dest/api/fields.d.ts +2 -1
  31. package/dest/api/fields.d.ts.map +1 -1
  32. package/dest/api/fields.js +1 -0
  33. package/dest/api/keys.d.ts +1 -1
  34. package/dest/api/keys.js +1 -1
  35. package/dest/api/node.d.ts +8 -4
  36. package/dest/api/node.d.ts.map +1 -1
  37. package/dest/api/node.js +7 -3
  38. package/dest/api/protocol.d.ts +7 -1
  39. package/dest/api/protocol.d.ts.map +1 -1
  40. package/dest/api/protocol.js +6 -0
  41. package/dest/api/tx.d.ts +2 -2
  42. package/dest/api/tx.d.ts.map +1 -1
  43. package/dest/api/tx.js +1 -1
  44. package/dest/api/wallet.d.ts +3 -2
  45. package/dest/api/wallet.d.ts.map +1 -1
  46. package/dest/api/wallet.js +2 -1
  47. package/dest/authorization/call_authorization_request.d.ts +22 -1
  48. package/dest/authorization/call_authorization_request.d.ts.map +1 -1
  49. package/dest/contract/base_contract_interaction.d.ts +8 -10
  50. package/dest/contract/base_contract_interaction.d.ts.map +1 -1
  51. package/dest/contract/base_contract_interaction.js +5 -17
  52. package/dest/contract/batch_call.d.ts +3 -3
  53. package/dest/contract/batch_call.d.ts.map +1 -1
  54. package/dest/contract/batch_call.js +11 -6
  55. package/dest/contract/contract_base.d.ts +4 -1
  56. package/dest/contract/contract_base.d.ts.map +1 -1
  57. package/dest/contract/contract_function_interaction.d.ts +3 -12
  58. package/dest/contract/contract_function_interaction.d.ts.map +1 -1
  59. package/dest/contract/contract_function_interaction.js +10 -7
  60. package/dest/contract/deploy_method.d.ts +63 -16
  61. package/dest/contract/deploy_method.d.ts.map +1 -1
  62. package/dest/contract/deploy_method.js +41 -23
  63. package/dest/contract/interaction_options.d.ts +42 -5
  64. package/dest/contract/interaction_options.d.ts.map +1 -1
  65. package/dest/contract/interaction_options.js +8 -1
  66. package/dest/contract/protocol_contracts/auth-registry.d.ts +36 -0
  67. package/dest/contract/protocol_contracts/auth-registry.d.ts.map +1 -0
  68. package/dest/contract/protocol_contracts/auth-registry.js +989 -0
  69. package/dest/contract/protocol_contracts/contract-class-registry.d.ts +15 -0
  70. package/dest/contract/protocol_contracts/contract-class-registry.d.ts.map +1 -0
  71. package/dest/contract/protocol_contracts/contract-class-registry.js +139 -0
  72. package/dest/contract/protocol_contracts/contract-instance-registry.d.ts +22 -0
  73. package/dest/contract/protocol_contracts/contract-instance-registry.d.ts.map +1 -0
  74. package/dest/contract/protocol_contracts/contract-instance-registry.js +465 -0
  75. package/dest/contract/protocol_contracts/fee-juice.d.ts +21 -0
  76. package/dest/contract/protocol_contracts/fee-juice.d.ts.map +1 -0
  77. package/dest/contract/protocol_contracts/fee-juice.js +426 -0
  78. package/dest/contract/protocol_contracts/multi-call-entrypoint.d.ts +34 -0
  79. package/dest/contract/protocol_contracts/multi-call-entrypoint.d.ts.map +1 -0
  80. package/dest/contract/protocol_contracts/multi-call-entrypoint.js +585 -0
  81. package/dest/contract/protocol_contracts/public-checks.d.ts +26 -0
  82. package/dest/contract/protocol_contracts/public-checks.d.ts.map +1 -0
  83. package/dest/contract/protocol_contracts/public-checks.js +593 -0
  84. package/dest/contract/wait_for_proven.d.ts +2 -2
  85. package/dest/contract/wait_for_proven.d.ts.map +1 -1
  86. package/dest/contract/wait_for_proven.js +1 -1
  87. package/dest/contract/wait_opts.d.ts +16 -0
  88. package/dest/contract/wait_opts.d.ts.map +1 -0
  89. package/dest/contract/wait_opts.js +5 -0
  90. package/dest/deployment/publish_class.js +2 -2
  91. package/dest/deployment/publish_instance.d.ts +2 -2
  92. package/dest/deployment/publish_instance.d.ts.map +1 -1
  93. package/dest/deployment/publish_instance.js +3 -3
  94. package/dest/ethereum/portal_manager.d.ts +6 -3
  95. package/dest/ethereum/portal_manager.d.ts.map +1 -1
  96. package/dest/ethereum/portal_manager.js +10 -10
  97. package/dest/fee/fee_juice_payment_method_with_claim.js +6 -6
  98. package/dest/fee/private_fee_payment_method.js +10 -10
  99. package/dest/fee/public_fee_payment_method.js +10 -10
  100. package/dest/fee/sponsored_fee_payment.js +3 -3
  101. package/dest/scripts/generate_protocol_contract_types.d.ts +2 -0
  102. package/dest/scripts/generate_protocol_contract_types.d.ts.map +1 -0
  103. package/dest/scripts/generate_protocol_contract_types.js +120 -0
  104. package/dest/utils/authwit.d.ts +8 -6
  105. package/dest/utils/authwit.d.ts.map +1 -1
  106. package/dest/utils/authwit.js +5 -9
  107. package/dest/utils/node.d.ts +12 -1
  108. package/dest/utils/node.d.ts.map +1 -1
  109. package/dest/utils/node.js +46 -0
  110. package/dest/wallet/account_entrypoint_meta_payment_method.d.ts +5 -8
  111. package/dest/wallet/account_entrypoint_meta_payment_method.d.ts.map +1 -1
  112. package/dest/wallet/account_entrypoint_meta_payment_method.js +28 -43
  113. package/dest/wallet/account_manager.d.ts +5 -8
  114. package/dest/wallet/account_manager.d.ts.map +1 -1
  115. package/dest/wallet/account_manager.js +5 -11
  116. package/dest/wallet/capabilities.d.ts +444 -0
  117. package/dest/wallet/capabilities.d.ts.map +1 -0
  118. package/dest/wallet/capabilities.js +3 -0
  119. package/dest/wallet/deploy_account_method.d.ts +34 -6
  120. package/dest/wallet/deploy_account_method.d.ts.map +1 -1
  121. package/dest/wallet/deploy_account_method.js +7 -5
  122. package/dest/wallet/index.d.ts +2 -1
  123. package/dest/wallet/index.d.ts.map +1 -1
  124. package/dest/wallet/index.js +1 -0
  125. package/dest/wallet/wallet.d.ts +1602 -2496
  126. package/dest/wallet/wallet.d.ts.map +1 -1
  127. package/dest/wallet/wallet.js +204 -107
  128. package/package.json +24 -13
  129. package/src/account/account.ts +34 -58
  130. package/src/account/account_contract.ts +6 -7
  131. package/src/account/account_with_secret_key.ts +33 -8
  132. package/src/account/index.ts +2 -1
  133. package/src/account/signerless_account.ts +13 -12
  134. package/src/api/account.ts +9 -3
  135. package/src/api/authorization.ts +1 -0
  136. package/src/api/contract.ts +24 -9
  137. package/src/api/deployment.ts +0 -1
  138. package/src/api/events.ts +35 -27
  139. package/src/api/fields.ts +1 -0
  140. package/src/api/keys.ts +2 -2
  141. package/src/api/node.ts +7 -3
  142. package/src/api/protocol.ts +7 -0
  143. package/src/api/tx.ts +2 -0
  144. package/src/api/wallet.ts +48 -3
  145. package/src/contract/base_contract_interaction.ts +27 -15
  146. package/src/contract/batch_call.ts +10 -13
  147. package/src/contract/contract_function_interaction.ts +17 -7
  148. package/src/contract/deploy_method.ts +122 -29
  149. package/src/contract/interaction_options.ts +49 -4
  150. package/src/contract/protocol_contracts/auth-registry.ts +549 -0
  151. package/src/contract/protocol_contracts/contract-class-registry.ts +99 -0
  152. package/src/contract/protocol_contracts/contract-instance-registry.ts +302 -0
  153. package/src/contract/protocol_contracts/fee-juice.ts +264 -0
  154. package/src/contract/protocol_contracts/multi-call-entrypoint.ts +332 -0
  155. package/src/contract/protocol_contracts/public-checks.ts +316 -0
  156. package/src/contract/wait_for_proven.ts +1 -1
  157. package/src/contract/wait_opts.ts +21 -0
  158. package/src/deployment/publish_class.ts +2 -2
  159. package/src/deployment/publish_instance.ts +3 -6
  160. package/src/ethereum/portal_manager.ts +9 -8
  161. package/src/fee/fee_juice_payment_method_with_claim.ts +5 -5
  162. package/src/fee/private_fee_payment_method.ts +7 -7
  163. package/src/fee/public_fee_payment_method.ts +8 -8
  164. package/src/fee/sponsored_fee_payment.ts +3 -3
  165. package/src/scripts/generate_protocol_contract_types.ts +150 -0
  166. package/src/utils/authwit.ts +19 -7
  167. package/src/utils/node.ts +62 -0
  168. package/src/wallet/account_entrypoint_meta_payment_method.ts +28 -60
  169. package/src/wallet/account_manager.ts +5 -13
  170. package/src/wallet/capabilities.ts +491 -0
  171. package/src/wallet/deploy_account_method.ts +37 -13
  172. package/src/wallet/index.ts +1 -0
  173. package/src/wallet/wallet.ts +341 -130
  174. package/dest/account/interface.d.ts +0 -19
  175. package/dest/account/interface.d.ts.map +0 -1
  176. package/dest/account/interface.js +0 -5
  177. package/dest/contract/deploy_sent_tx.d.ts +0 -48
  178. package/dest/contract/deploy_sent_tx.d.ts.map +0 -1
  179. package/dest/contract/deploy_sent_tx.js +0 -46
  180. package/dest/contract/protocol_contracts.d.ts +0 -9
  181. package/dest/contract/protocol_contracts.d.ts.map +0 -1
  182. package/dest/contract/protocol_contracts.js +0 -26
  183. package/dest/contract/sent_tx.d.ts +0 -50
  184. package/dest/contract/sent_tx.d.ts.map +0 -1
  185. package/dest/contract/sent_tx.js +0 -90
  186. package/dest/contract/unsafe_contract.d.ts +0 -15
  187. package/dest/contract/unsafe_contract.d.ts.map +0 -1
  188. package/dest/contract/unsafe_contract.js +0 -6
  189. package/dest/deployment/broadcast_function.d.ts +0 -24
  190. package/dest/deployment/broadcast_function.d.ts.map +0 -1
  191. package/dest/deployment/broadcast_function.js +0 -74
  192. package/src/account/interface.ts +0 -25
  193. package/src/contract/deploy_sent_tx.ts +0 -75
  194. package/src/contract/protocol_contracts.ts +0 -35
  195. package/src/contract/sent_tx.ts +0 -129
  196. package/src/contract/unsafe_contract.ts +0 -19
  197. package/src/deployment/broadcast_function.ts +0 -148
@@ -0,0 +1,989 @@
1
+ /* Autogenerated file, do not edit! */ /* eslint-disable */ import { ProtocolContractAddress } from '@aztec/protocol-contracts';
2
+ import { FunctionType } from '@aztec/stdlib/abi';
3
+ import { ContractBase } from '../contract_base.js';
4
+ const AuthRegistryContractArtifact = {
5
+ name: 'AuthRegistry',
6
+ functions: [
7
+ {
8
+ ...{
9
+ functionType: FunctionType.PRIVATE,
10
+ name: 'set_authorized_private',
11
+ isOnlySelf: false,
12
+ isStatic: false,
13
+ isInitializer: false,
14
+ parameters: [
15
+ {
16
+ name: 'approver',
17
+ type: {
18
+ kind: 'struct',
19
+ fields: [
20
+ {
21
+ name: 'inner',
22
+ type: {
23
+ kind: 'field'
24
+ }
25
+ }
26
+ ],
27
+ path: 'aztec::protocol_types::address::aztec_address::AztecAddress'
28
+ },
29
+ visibility: 'private'
30
+ },
31
+ {
32
+ name: 'message_hash',
33
+ type: {
34
+ kind: 'field'
35
+ },
36
+ visibility: 'private'
37
+ },
38
+ {
39
+ name: 'authorize',
40
+ type: {
41
+ kind: 'boolean'
42
+ },
43
+ visibility: 'private'
44
+ }
45
+ ],
46
+ returnTypes: [],
47
+ errorTypes: {
48
+ '7555607922535724711': {
49
+ error_kind: 'string',
50
+ string: 'Preimage mismatch'
51
+ },
52
+ '9530675838293881722': {
53
+ error_kind: 'string',
54
+ string: 'Writer did not write all data'
55
+ },
56
+ '9894212961085021188': {
57
+ error_kind: 'string',
58
+ string: 'Message not authorized by account'
59
+ },
60
+ '12327971061804302172': {
61
+ error_kind: 'fmtstring',
62
+ length: 98,
63
+ item_types: []
64
+ },
65
+ '14990209321349310352': {
66
+ error_kind: 'string',
67
+ string: 'attempt to add with overflow'
68
+ },
69
+ '15764276373176857197': {
70
+ error_kind: 'string',
71
+ string: 'Stack too deep'
72
+ },
73
+ '16431471497789672479': {
74
+ error_kind: 'string',
75
+ string: 'Index out of bounds'
76
+ }
77
+ }
78
+ },
79
+ bytecode: Buffer.from([]),
80
+ debugSymbols: ''
81
+ },
82
+ {
83
+ ...{
84
+ functionType: FunctionType.UTILITY,
85
+ name: 'utility_is_consumable',
86
+ isOnlySelf: false,
87
+ isStatic: false,
88
+ isInitializer: false,
89
+ parameters: [
90
+ {
91
+ name: 'on_behalf_of',
92
+ type: {
93
+ kind: 'struct',
94
+ fields: [
95
+ {
96
+ name: 'inner',
97
+ type: {
98
+ kind: 'field'
99
+ }
100
+ }
101
+ ],
102
+ path: 'aztec::protocol_types::address::aztec_address::AztecAddress'
103
+ },
104
+ visibility: 'private'
105
+ },
106
+ {
107
+ name: 'message_hash',
108
+ type: {
109
+ kind: 'field'
110
+ },
111
+ visibility: 'private'
112
+ }
113
+ ],
114
+ returnTypes: [
115
+ {
116
+ kind: 'boolean'
117
+ }
118
+ ],
119
+ errorTypes: {
120
+ '361444214588792908': {
121
+ error_kind: 'string',
122
+ string: 'attempt to multiply with overflow'
123
+ },
124
+ '1998584279744703196': {
125
+ error_kind: 'string',
126
+ string: 'attempt to subtract with overflow'
127
+ },
128
+ '13455385521185560676': {
129
+ error_kind: 'string',
130
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.'
131
+ },
132
+ '14990209321349310352': {
133
+ error_kind: 'string',
134
+ string: 'attempt to add with overflow'
135
+ },
136
+ '15764276373176857197': {
137
+ error_kind: 'string',
138
+ string: 'Stack too deep'
139
+ },
140
+ '16431471497789672479': {
141
+ error_kind: 'string',
142
+ string: 'Index out of bounds'
143
+ }
144
+ }
145
+ },
146
+ bytecode: Buffer.from([]),
147
+ debugSymbols: ''
148
+ },
149
+ {
150
+ ...{
151
+ functionType: FunctionType.UTILITY,
152
+ name: 'process_message',
153
+ isOnlySelf: false,
154
+ isStatic: false,
155
+ isInitializer: false,
156
+ parameters: [
157
+ {
158
+ name: 'message_ciphertext',
159
+ type: {
160
+ kind: 'struct',
161
+ fields: [
162
+ {
163
+ name: 'storage',
164
+ type: {
165
+ kind: 'array',
166
+ length: 15,
167
+ type: {
168
+ kind: 'field'
169
+ }
170
+ }
171
+ },
172
+ {
173
+ name: 'len',
174
+ type: {
175
+ kind: 'integer',
176
+ sign: 'unsigned',
177
+ width: 32
178
+ }
179
+ }
180
+ ],
181
+ path: 'std::collections::bounded_vec::BoundedVec'
182
+ },
183
+ visibility: 'private'
184
+ },
185
+ {
186
+ name: 'message_context',
187
+ type: {
188
+ kind: 'struct',
189
+ fields: [
190
+ {
191
+ name: 'tx_hash',
192
+ type: {
193
+ kind: 'field'
194
+ }
195
+ },
196
+ {
197
+ name: 'unique_note_hashes_in_tx',
198
+ type: {
199
+ kind: 'struct',
200
+ fields: [
201
+ {
202
+ name: 'storage',
203
+ type: {
204
+ kind: 'array',
205
+ length: 64,
206
+ type: {
207
+ kind: 'field'
208
+ }
209
+ }
210
+ },
211
+ {
212
+ name: 'len',
213
+ type: {
214
+ kind: 'integer',
215
+ sign: 'unsigned',
216
+ width: 32
217
+ }
218
+ }
219
+ ],
220
+ path: 'std::collections::bounded_vec::BoundedVec'
221
+ }
222
+ },
223
+ {
224
+ name: 'first_nullifier_in_tx',
225
+ type: {
226
+ kind: 'field'
227
+ }
228
+ },
229
+ {
230
+ name: 'recipient',
231
+ type: {
232
+ kind: 'struct',
233
+ fields: [
234
+ {
235
+ name: 'inner',
236
+ type: {
237
+ kind: 'field'
238
+ }
239
+ }
240
+ ],
241
+ path: 'aztec::protocol_types::address::aztec_address::AztecAddress'
242
+ }
243
+ }
244
+ ],
245
+ path: 'aztec::messages::processing::message_context::MessageContext'
246
+ },
247
+ visibility: 'private'
248
+ }
249
+ ],
250
+ returnTypes: [],
251
+ errorTypes: {
252
+ '361444214588792908': {
253
+ error_kind: 'string',
254
+ string: 'attempt to multiply with overflow'
255
+ },
256
+ '992401946138144806': {
257
+ error_kind: 'string',
258
+ string: 'Attempted to read past end of BoundedVec'
259
+ },
260
+ '1998584279744703196': {
261
+ error_kind: 'string',
262
+ string: 'attempt to subtract with overflow'
263
+ },
264
+ '2967937905572420042': {
265
+ error_kind: 'fmtstring',
266
+ length: 61,
267
+ item_types: [
268
+ {
269
+ kind: 'field'
270
+ },
271
+ {
272
+ kind: 'field'
273
+ }
274
+ ]
275
+ },
276
+ '3330370348214585450': {
277
+ error_kind: 'fmtstring',
278
+ length: 48,
279
+ item_types: [
280
+ {
281
+ kind: 'field'
282
+ },
283
+ {
284
+ kind: 'field'
285
+ }
286
+ ]
287
+ },
288
+ '3670003311596808700': {
289
+ error_kind: 'fmtstring',
290
+ length: 77,
291
+ item_types: [
292
+ {
293
+ kind: 'integer',
294
+ sign: 'unsigned',
295
+ width: 32
296
+ }
297
+ ]
298
+ },
299
+ '4261968856572588300': {
300
+ error_kind: 'string',
301
+ string: 'Value does not fit in field'
302
+ },
303
+ '4440399188109668273': {
304
+ error_kind: 'string',
305
+ string: 'Input length must be a multiple of 32'
306
+ },
307
+ '5417577161503694006': {
308
+ error_kind: 'fmtstring',
309
+ length: 56,
310
+ item_types: [
311
+ {
312
+ kind: 'field'
313
+ }
314
+ ]
315
+ },
316
+ '9791669845391776238': {
317
+ error_kind: 'string',
318
+ string: '0 has a square root; you cannot claim it is not square'
319
+ },
320
+ '10135509984888824963': {
321
+ error_kind: 'fmtstring',
322
+ length: 58,
323
+ item_types: [
324
+ {
325
+ kind: 'field'
326
+ }
327
+ ]
328
+ },
329
+ '10791800398362570014': {
330
+ error_kind: 'string',
331
+ string: 'extend_from_bounded_vec out of bounds'
332
+ },
333
+ '11692359521570349358': {
334
+ error_kind: 'fmtstring',
335
+ length: 40,
336
+ item_types: []
337
+ },
338
+ '12469291177396340830': {
339
+ error_kind: 'string',
340
+ string: 'call to assert_max_bit_size'
341
+ },
342
+ '12913276134398371456': {
343
+ error_kind: 'string',
344
+ string: 'push out of bounds'
345
+ },
346
+ '13557316507370296400': {
347
+ error_kind: 'fmtstring',
348
+ length: 130,
349
+ item_types: [
350
+ {
351
+ kind: 'integer',
352
+ sign: 'unsigned',
353
+ width: 32
354
+ }
355
+ ]
356
+ },
357
+ '14938672389828944159': {
358
+ error_kind: 'fmtstring',
359
+ length: 146,
360
+ item_types: [
361
+ {
362
+ kind: 'integer',
363
+ sign: 'unsigned',
364
+ width: 32
365
+ }
366
+ ]
367
+ },
368
+ '14990209321349310352': {
369
+ error_kind: 'string',
370
+ string: 'attempt to add with overflow'
371
+ },
372
+ '15764276373176857197': {
373
+ error_kind: 'string',
374
+ string: 'Stack too deep'
375
+ },
376
+ '16431471497789672479': {
377
+ error_kind: 'string',
378
+ string: 'Index out of bounds'
379
+ },
380
+ '17531474008201752295': {
381
+ error_kind: 'fmtstring',
382
+ length: 133,
383
+ item_types: [
384
+ {
385
+ kind: 'integer',
386
+ sign: 'unsigned',
387
+ width: 32
388
+ }
389
+ ]
390
+ }
391
+ }
392
+ },
393
+ bytecode: Buffer.from([]),
394
+ debugSymbols: ''
395
+ },
396
+ {
397
+ ...{
398
+ functionType: FunctionType.PUBLIC,
399
+ name: 'public_dispatch',
400
+ isOnlySelf: false,
401
+ isStatic: false,
402
+ isInitializer: false,
403
+ parameters: [
404
+ {
405
+ name: 'selector',
406
+ type: {
407
+ kind: 'field'
408
+ },
409
+ visibility: 'private'
410
+ }
411
+ ],
412
+ returnTypes: [],
413
+ errorTypes: {
414
+ '361444214588792908': {
415
+ error_kind: 'string',
416
+ string: 'attempt to multiply with overflow'
417
+ },
418
+ '1998584279744703196': {
419
+ error_kind: 'string',
420
+ string: 'attempt to subtract with overflow'
421
+ },
422
+ '5525725861591553972': {
423
+ error_kind: 'string',
424
+ string: 'rejecting all'
425
+ },
426
+ '11691217184967371519': {
427
+ error_kind: 'string',
428
+ string: 'Function is_reject_all can only be called statically'
429
+ },
430
+ '12511970388699677811': {
431
+ error_kind: 'fmtstring',
432
+ length: 27,
433
+ item_types: [
434
+ {
435
+ kind: 'field'
436
+ }
437
+ ]
438
+ },
439
+ '13455385521185560676': {
440
+ error_kind: 'string',
441
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.'
442
+ },
443
+ '13929691561421487185': {
444
+ error_kind: 'string',
445
+ string: 'Function _set_authorized can only be called by the same contract'
446
+ },
447
+ '14990209321349310352': {
448
+ error_kind: 'string',
449
+ string: 'attempt to add with overflow'
450
+ },
451
+ '15764276373176857197': {
452
+ error_kind: 'string',
453
+ string: 'Stack too deep'
454
+ },
455
+ '16431471497789672479': {
456
+ error_kind: 'string',
457
+ string: 'Index out of bounds'
458
+ },
459
+ '17089945683942782951': {
460
+ error_kind: 'string',
461
+ string: 'unauthorized'
462
+ },
463
+ '17312933876399746100': {
464
+ error_kind: 'string',
465
+ string: 'Function is_consumable can only be called statically'
466
+ }
467
+ }
468
+ },
469
+ bytecode: Buffer.from([]),
470
+ debugSymbols: ''
471
+ },
472
+ {
473
+ ...{
474
+ functionType: FunctionType.UTILITY,
475
+ name: 'sync_state',
476
+ isOnlySelf: false,
477
+ isStatic: false,
478
+ isInitializer: false,
479
+ parameters: [],
480
+ returnTypes: [],
481
+ errorTypes: {
482
+ '361444214588792908': {
483
+ error_kind: 'string',
484
+ string: 'attempt to multiply with overflow'
485
+ },
486
+ '992401946138144806': {
487
+ error_kind: 'string',
488
+ string: 'Attempted to read past end of BoundedVec'
489
+ },
490
+ '1998584279744703196': {
491
+ error_kind: 'string',
492
+ string: 'attempt to subtract with overflow'
493
+ },
494
+ '2967937905572420042': {
495
+ error_kind: 'fmtstring',
496
+ length: 61,
497
+ item_types: [
498
+ {
499
+ kind: 'field'
500
+ },
501
+ {
502
+ kind: 'field'
503
+ }
504
+ ]
505
+ },
506
+ '3330370348214585450': {
507
+ error_kind: 'fmtstring',
508
+ length: 48,
509
+ item_types: [
510
+ {
511
+ kind: 'field'
512
+ },
513
+ {
514
+ kind: 'field'
515
+ }
516
+ ]
517
+ },
518
+ '3670003311596808700': {
519
+ error_kind: 'fmtstring',
520
+ length: 77,
521
+ item_types: [
522
+ {
523
+ kind: 'integer',
524
+ sign: 'unsigned',
525
+ width: 32
526
+ }
527
+ ]
528
+ },
529
+ '4261968856572588300': {
530
+ error_kind: 'string',
531
+ string: 'Value does not fit in field'
532
+ },
533
+ '4440399188109668273': {
534
+ error_kind: 'string',
535
+ string: 'Input length must be a multiple of 32'
536
+ },
537
+ '5417577161503694006': {
538
+ error_kind: 'fmtstring',
539
+ length: 56,
540
+ item_types: [
541
+ {
542
+ kind: 'field'
543
+ }
544
+ ]
545
+ },
546
+ '9791669845391776238': {
547
+ error_kind: 'string',
548
+ string: '0 has a square root; you cannot claim it is not square'
549
+ },
550
+ '9885968605480832328': {
551
+ error_kind: 'string',
552
+ string: 'Attempted to read past the length of a CapsuleArray'
553
+ },
554
+ '10135509984888824963': {
555
+ error_kind: 'fmtstring',
556
+ length: 58,
557
+ item_types: [
558
+ {
559
+ kind: 'field'
560
+ }
561
+ ]
562
+ },
563
+ '10791800398362570014': {
564
+ error_kind: 'string',
565
+ string: 'extend_from_bounded_vec out of bounds'
566
+ },
567
+ '11021520179822076911': {
568
+ error_kind: 'string',
569
+ string: 'Attempted to delete past the length of a CapsuleArray'
570
+ },
571
+ '11692359521570349358': {
572
+ error_kind: 'fmtstring',
573
+ length: 40,
574
+ item_types: []
575
+ },
576
+ '12327971061804302172': {
577
+ error_kind: 'fmtstring',
578
+ length: 98,
579
+ item_types: []
580
+ },
581
+ '12469291177396340830': {
582
+ error_kind: 'string',
583
+ string: 'call to assert_max_bit_size'
584
+ },
585
+ '12913276134398371456': {
586
+ error_kind: 'string',
587
+ string: 'push out of bounds'
588
+ },
589
+ '13557316507370296400': {
590
+ error_kind: 'fmtstring',
591
+ length: 130,
592
+ item_types: [
593
+ {
594
+ kind: 'integer',
595
+ sign: 'unsigned',
596
+ width: 32
597
+ }
598
+ ]
599
+ },
600
+ '14938672389828944159': {
601
+ error_kind: 'fmtstring',
602
+ length: 146,
603
+ item_types: [
604
+ {
605
+ kind: 'integer',
606
+ sign: 'unsigned',
607
+ width: 32
608
+ }
609
+ ]
610
+ },
611
+ '14990209321349310352': {
612
+ error_kind: 'string',
613
+ string: 'attempt to add with overflow'
614
+ },
615
+ '15764276373176857197': {
616
+ error_kind: 'string',
617
+ string: 'Stack too deep'
618
+ },
619
+ '16431471497789672479': {
620
+ error_kind: 'string',
621
+ string: 'Index out of bounds'
622
+ },
623
+ '17531474008201752295': {
624
+ error_kind: 'fmtstring',
625
+ length: 133,
626
+ item_types: [
627
+ {
628
+ kind: 'integer',
629
+ sign: 'unsigned',
630
+ width: 32
631
+ }
632
+ ]
633
+ },
634
+ '17655676068928457687': {
635
+ error_kind: 'string',
636
+ string: 'Reader did not read all data'
637
+ }
638
+ }
639
+ },
640
+ bytecode: Buffer.from([]),
641
+ debugSymbols: ''
642
+ }
643
+ ],
644
+ nonDispatchPublicFunctions: [
645
+ {
646
+ functionType: FunctionType.PUBLIC,
647
+ name: '_set_authorized',
648
+ isOnlySelf: true,
649
+ isStatic: false,
650
+ isInitializer: false,
651
+ parameters: [
652
+ {
653
+ name: 'approver',
654
+ type: {
655
+ kind: 'struct',
656
+ fields: [
657
+ {
658
+ name: 'inner',
659
+ type: {
660
+ kind: 'field'
661
+ }
662
+ }
663
+ ],
664
+ path: 'aztec::protocol_types::address::aztec_address::AztecAddress'
665
+ },
666
+ visibility: 'private'
667
+ },
668
+ {
669
+ name: 'message_hash',
670
+ type: {
671
+ kind: 'field'
672
+ },
673
+ visibility: 'private'
674
+ },
675
+ {
676
+ name: 'authorize',
677
+ type: {
678
+ kind: 'boolean'
679
+ },
680
+ visibility: 'private'
681
+ }
682
+ ],
683
+ returnTypes: [],
684
+ errorTypes: {
685
+ '361444214588792908': {
686
+ error_kind: 'string',
687
+ string: 'attempt to multiply with overflow'
688
+ },
689
+ '1998584279744703196': {
690
+ error_kind: 'string',
691
+ string: 'attempt to subtract with overflow'
692
+ },
693
+ '13455385521185560676': {
694
+ error_kind: 'string',
695
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.'
696
+ },
697
+ '13929691561421487185': {
698
+ error_kind: 'string',
699
+ string: 'Function _set_authorized can only be called by the same contract'
700
+ },
701
+ '14990209321349310352': {
702
+ error_kind: 'string',
703
+ string: 'attempt to add with overflow'
704
+ },
705
+ '15764276373176857197': {
706
+ error_kind: 'string',
707
+ string: 'Stack too deep'
708
+ },
709
+ '16431471497789672479': {
710
+ error_kind: 'string',
711
+ string: 'Index out of bounds'
712
+ }
713
+ }
714
+ },
715
+ {
716
+ functionType: FunctionType.PUBLIC,
717
+ name: 'consume',
718
+ isOnlySelf: false,
719
+ isStatic: false,
720
+ isInitializer: false,
721
+ parameters: [
722
+ {
723
+ name: 'on_behalf_of',
724
+ type: {
725
+ kind: 'struct',
726
+ fields: [
727
+ {
728
+ name: 'inner',
729
+ type: {
730
+ kind: 'field'
731
+ }
732
+ }
733
+ ],
734
+ path: 'aztec::protocol_types::address::aztec_address::AztecAddress'
735
+ },
736
+ visibility: 'private'
737
+ },
738
+ {
739
+ name: 'inner_hash',
740
+ type: {
741
+ kind: 'field'
742
+ },
743
+ visibility: 'private'
744
+ }
745
+ ],
746
+ returnTypes: [
747
+ {
748
+ kind: 'field'
749
+ }
750
+ ],
751
+ errorTypes: {
752
+ '361444214588792908': {
753
+ error_kind: 'string',
754
+ string: 'attempt to multiply with overflow'
755
+ },
756
+ '1998584279744703196': {
757
+ error_kind: 'string',
758
+ string: 'attempt to subtract with overflow'
759
+ },
760
+ '5525725861591553972': {
761
+ error_kind: 'string',
762
+ string: 'rejecting all'
763
+ },
764
+ '13455385521185560676': {
765
+ error_kind: 'string',
766
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.'
767
+ },
768
+ '14990209321349310352': {
769
+ error_kind: 'string',
770
+ string: 'attempt to add with overflow'
771
+ },
772
+ '15764276373176857197': {
773
+ error_kind: 'string',
774
+ string: 'Stack too deep'
775
+ },
776
+ '16431471497789672479': {
777
+ error_kind: 'string',
778
+ string: 'Index out of bounds'
779
+ },
780
+ '17089945683942782951': {
781
+ error_kind: 'string',
782
+ string: 'unauthorized'
783
+ }
784
+ }
785
+ },
786
+ {
787
+ functionType: FunctionType.PUBLIC,
788
+ name: 'is_consumable',
789
+ isOnlySelf: false,
790
+ isStatic: true,
791
+ isInitializer: false,
792
+ parameters: [
793
+ {
794
+ name: 'on_behalf_of',
795
+ type: {
796
+ kind: 'struct',
797
+ fields: [
798
+ {
799
+ name: 'inner',
800
+ type: {
801
+ kind: 'field'
802
+ }
803
+ }
804
+ ],
805
+ path: 'aztec::protocol_types::address::aztec_address::AztecAddress'
806
+ },
807
+ visibility: 'private'
808
+ },
809
+ {
810
+ name: 'message_hash',
811
+ type: {
812
+ kind: 'field'
813
+ },
814
+ visibility: 'private'
815
+ }
816
+ ],
817
+ returnTypes: [
818
+ {
819
+ kind: 'boolean'
820
+ }
821
+ ],
822
+ errorTypes: {
823
+ '361444214588792908': {
824
+ error_kind: 'string',
825
+ string: 'attempt to multiply with overflow'
826
+ },
827
+ '1998584279744703196': {
828
+ error_kind: 'string',
829
+ string: 'attempt to subtract with overflow'
830
+ },
831
+ '13455385521185560676': {
832
+ error_kind: 'string',
833
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.'
834
+ },
835
+ '14990209321349310352': {
836
+ error_kind: 'string',
837
+ string: 'attempt to add with overflow'
838
+ },
839
+ '15764276373176857197': {
840
+ error_kind: 'string',
841
+ string: 'Stack too deep'
842
+ },
843
+ '16431471497789672479': {
844
+ error_kind: 'string',
845
+ string: 'Index out of bounds'
846
+ },
847
+ '17312933876399746100': {
848
+ error_kind: 'string',
849
+ string: 'Function is_consumable can only be called statically'
850
+ }
851
+ }
852
+ },
853
+ {
854
+ functionType: FunctionType.PUBLIC,
855
+ name: 'is_reject_all',
856
+ isOnlySelf: false,
857
+ isStatic: true,
858
+ isInitializer: false,
859
+ parameters: [
860
+ {
861
+ name: 'on_behalf_of',
862
+ type: {
863
+ kind: 'struct',
864
+ fields: [
865
+ {
866
+ name: 'inner',
867
+ type: {
868
+ kind: 'field'
869
+ }
870
+ }
871
+ ],
872
+ path: 'aztec::protocol_types::address::aztec_address::AztecAddress'
873
+ },
874
+ visibility: 'private'
875
+ }
876
+ ],
877
+ returnTypes: [
878
+ {
879
+ kind: 'boolean'
880
+ }
881
+ ],
882
+ errorTypes: {
883
+ '11691217184967371519': {
884
+ error_kind: 'string',
885
+ string: 'Function is_reject_all can only be called statically'
886
+ },
887
+ '13455385521185560676': {
888
+ error_kind: 'string',
889
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.'
890
+ },
891
+ '15764276373176857197': {
892
+ error_kind: 'string',
893
+ string: 'Stack too deep'
894
+ }
895
+ }
896
+ },
897
+ {
898
+ functionType: FunctionType.PUBLIC,
899
+ name: 'set_authorized',
900
+ isOnlySelf: false,
901
+ isStatic: false,
902
+ isInitializer: false,
903
+ parameters: [
904
+ {
905
+ name: 'message_hash',
906
+ type: {
907
+ kind: 'field'
908
+ },
909
+ visibility: 'private'
910
+ },
911
+ {
912
+ name: 'authorize',
913
+ type: {
914
+ kind: 'boolean'
915
+ },
916
+ visibility: 'private'
917
+ }
918
+ ],
919
+ returnTypes: [],
920
+ errorTypes: {
921
+ '361444214588792908': {
922
+ error_kind: 'string',
923
+ string: 'attempt to multiply with overflow'
924
+ },
925
+ '1998584279744703196': {
926
+ error_kind: 'string',
927
+ string: 'attempt to subtract with overflow'
928
+ },
929
+ '13455385521185560676': {
930
+ error_kind: 'string',
931
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.'
932
+ },
933
+ '14990209321349310352': {
934
+ error_kind: 'string',
935
+ string: 'attempt to add with overflow'
936
+ },
937
+ '15764276373176857197': {
938
+ error_kind: 'string',
939
+ string: 'Stack too deep'
940
+ },
941
+ '16431471497789672479': {
942
+ error_kind: 'string',
943
+ string: 'Index out of bounds'
944
+ }
945
+ }
946
+ },
947
+ {
948
+ functionType: FunctionType.PUBLIC,
949
+ name: 'set_reject_all',
950
+ isOnlySelf: false,
951
+ isStatic: false,
952
+ isInitializer: false,
953
+ parameters: [
954
+ {
955
+ name: 'reject',
956
+ type: {
957
+ kind: 'boolean'
958
+ },
959
+ visibility: 'private'
960
+ }
961
+ ],
962
+ returnTypes: [],
963
+ errorTypes: {
964
+ '13455385521185560676': {
965
+ error_kind: 'string',
966
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.'
967
+ },
968
+ '15764276373176857197': {
969
+ error_kind: 'string',
970
+ string: 'Stack too deep'
971
+ }
972
+ }
973
+ }
974
+ ],
975
+ outputs: {
976
+ structs: {},
977
+ globals: {}
978
+ },
979
+ storageLayout: {},
980
+ fileMap: {}
981
+ };
982
+ export class AuthRegistryContract extends ContractBase {
983
+ constructor(wallet){
984
+ super(ProtocolContractAddress.AuthRegistry, AuthRegistryContractArtifact, wallet);
985
+ }
986
+ static at(wallet) {
987
+ return new AuthRegistryContract(wallet);
988
+ }
989
+ }