@aztec/aztec.js 0.0.1-commit.24de95ac → 0.0.1-commit.27d773e65

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 (261) hide show
  1. package/dest/account/account.d.ts +26 -42
  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 +9 -10
  5. package/dest/account/account_contract.d.ts.map +1 -1
  6. package/dest/account/account_with_secret_key.d.ts +20 -9
  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 +4 -3
  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 +7 -9
  13. package/dest/account/signerless_account.d.ts.map +1 -1
  14. package/dest/account/signerless_account.js +8 -11
  15. package/dest/api/abi.d.ts +1 -1
  16. package/dest/api/account.d.ts +3 -4
  17. package/dest/api/account.d.ts.map +1 -1
  18. package/dest/api/account.js +2 -3
  19. package/dest/api/addresses.d.ts +1 -1
  20. package/dest/api/authorization.d.ts +2 -2
  21. package/dest/api/authorization.d.ts.map +1 -1
  22. package/dest/api/authorization.js +1 -1
  23. package/dest/api/block.d.ts +1 -1
  24. package/dest/api/contract.d.ts +19 -13
  25. package/dest/api/contract.d.ts.map +1 -1
  26. package/dest/api/contract.js +17 -11
  27. package/dest/api/crypto.d.ts +1 -1
  28. package/dest/api/deployment.d.ts +1 -2
  29. package/dest/api/deployment.d.ts.map +1 -1
  30. package/dest/api/deployment.js +0 -1
  31. package/dest/api/eth_address.d.ts +1 -1
  32. package/dest/api/ethereum.d.ts +1 -1
  33. package/dest/api/events.d.ts +10 -6
  34. package/dest/api/events.d.ts.map +1 -1
  35. package/dest/api/events.js +30 -20
  36. package/dest/api/fee.d.ts +1 -1
  37. package/dest/api/fee_testing.d.ts +1 -1
  38. package/dest/api/fields.d.ts +4 -2
  39. package/dest/api/fields.d.ts.map +1 -1
  40. package/dest/api/fields.js +3 -1
  41. package/dest/api/keys.d.ts +2 -2
  42. package/dest/api/keys.js +1 -1
  43. package/dest/api/log.d.ts +1 -1
  44. package/dest/api/messaging.d.ts +1 -1
  45. package/dest/api/node.d.ts +8 -4
  46. package/dest/api/node.d.ts.map +1 -1
  47. package/dest/api/node.js +7 -3
  48. package/dest/api/note.d.ts +2 -2
  49. package/dest/api/note.d.ts.map +1 -1
  50. package/dest/api/note.js +1 -1
  51. package/dest/api/protocol.d.ts +7 -1
  52. package/dest/api/protocol.d.ts.map +1 -1
  53. package/dest/api/protocol.js +6 -0
  54. package/dest/api/trees.d.ts +1 -1
  55. package/dest/api/tx.d.ts +2 -2
  56. package/dest/api/tx.d.ts.map +1 -1
  57. package/dest/api/tx.js +1 -1
  58. package/dest/api/utils.d.ts +1 -1
  59. package/dest/api/wallet.d.ts +3 -3
  60. package/dest/api/wallet.d.ts.map +1 -1
  61. package/dest/api/wallet.js +2 -2
  62. package/dest/authorization/call_authorization_request.d.ts +2 -2
  63. package/dest/authorization/call_authorization_request.d.ts.map +1 -1
  64. package/dest/contract/base_contract_interaction.d.ts +8 -11
  65. package/dest/contract/base_contract_interaction.d.ts.map +1 -1
  66. package/dest/contract/base_contract_interaction.js +5 -17
  67. package/dest/contract/batch_call.d.ts +8 -9
  68. package/dest/contract/batch_call.d.ts.map +1 -1
  69. package/dest/contract/batch_call.js +59 -36
  70. package/dest/contract/checker.d.ts +1 -1
  71. package/dest/contract/contract.d.ts +2 -2
  72. package/dest/contract/contract.d.ts.map +1 -1
  73. package/dest/contract/contract.js +4 -5
  74. package/dest/contract/contract_base.d.ts +6 -10
  75. package/dest/contract/contract_base.d.ts.map +1 -1
  76. package/dest/contract/contract_base.js +5 -12
  77. package/dest/contract/contract_function_interaction.d.ts +5 -14
  78. package/dest/contract/contract_function_interaction.d.ts.map +1 -1
  79. package/dest/contract/contract_function_interaction.js +18 -12
  80. package/dest/contract/deploy_method.d.ts +85 -24
  81. package/dest/contract/deploy_method.d.ts.map +1 -1
  82. package/dest/contract/deploy_method.js +71 -36
  83. package/dest/contract/get_gas_limits.d.ts +1 -1
  84. package/dest/contract/get_gas_limits.js +3 -3
  85. package/dest/contract/interaction_options.d.ts +51 -7
  86. package/dest/contract/interaction_options.d.ts.map +1 -1
  87. package/dest/contract/interaction_options.js +12 -11
  88. package/dest/contract/protocol_contracts/auth-registry.d.ts +36 -0
  89. package/dest/contract/protocol_contracts/auth-registry.d.ts.map +1 -0
  90. package/dest/contract/protocol_contracts/auth-registry.js +997 -0
  91. package/dest/contract/protocol_contracts/contract-class-registry.d.ts +15 -0
  92. package/dest/contract/protocol_contracts/contract-class-registry.d.ts.map +1 -0
  93. package/dest/contract/protocol_contracts/contract-class-registry.js +139 -0
  94. package/dest/contract/protocol_contracts/contract-instance-registry.d.ts +22 -0
  95. package/dest/contract/protocol_contracts/contract-instance-registry.d.ts.map +1 -0
  96. package/dest/contract/protocol_contracts/contract-instance-registry.js +465 -0
  97. package/dest/contract/protocol_contracts/fee-juice.d.ts +21 -0
  98. package/dest/contract/protocol_contracts/fee-juice.d.ts.map +1 -0
  99. package/dest/contract/protocol_contracts/fee-juice.js +426 -0
  100. package/dest/contract/protocol_contracts/multi-call-entrypoint.d.ts +34 -0
  101. package/dest/contract/protocol_contracts/multi-call-entrypoint.d.ts.map +1 -0
  102. package/dest/contract/protocol_contracts/multi-call-entrypoint.js +593 -0
  103. package/dest/contract/protocol_contracts/public-checks.d.ts +26 -0
  104. package/dest/contract/protocol_contracts/public-checks.d.ts.map +1 -0
  105. package/dest/contract/protocol_contracts/public-checks.js +601 -0
  106. package/dest/contract/wait_for_proven.d.ts +2 -2
  107. package/dest/contract/wait_for_proven.d.ts.map +1 -1
  108. package/dest/contract/wait_for_proven.js +1 -1
  109. package/dest/contract/wait_opts.d.ts +16 -0
  110. package/dest/contract/wait_opts.d.ts.map +1 -0
  111. package/dest/contract/wait_opts.js +5 -0
  112. package/dest/deployment/contract_deployer.d.ts +1 -1
  113. package/dest/deployment/contract_deployer.d.ts.map +1 -1
  114. package/dest/deployment/contract_deployer.js +1 -1
  115. package/dest/deployment/publish_class.d.ts +1 -1
  116. package/dest/deployment/publish_class.js +3 -3
  117. package/dest/deployment/publish_instance.d.ts +2 -2
  118. package/dest/deployment/publish_instance.d.ts.map +1 -1
  119. package/dest/deployment/publish_instance.js +3 -3
  120. package/dest/ethereum/portal_manager.d.ts +7 -6
  121. package/dest/ethereum/portal_manager.d.ts.map +1 -1
  122. package/dest/ethereum/portal_manager.js +48 -22
  123. package/dest/fee/fee_juice_payment_method_with_claim.d.ts +2 -2
  124. package/dest/fee/fee_juice_payment_method_with_claim.d.ts.map +1 -1
  125. package/dest/fee/fee_juice_payment_method_with_claim.js +9 -9
  126. package/dest/fee/fee_payment_method.d.ts +2 -2
  127. package/dest/fee/fee_payment_method.d.ts.map +1 -1
  128. package/dest/fee/private_fee_payment_method.d.ts +2 -2
  129. package/dest/fee/private_fee_payment_method.d.ts.map +1 -1
  130. package/dest/fee/private_fee_payment_method.js +14 -14
  131. package/dest/fee/public_fee_payment_method.d.ts +2 -2
  132. package/dest/fee/public_fee_payment_method.d.ts.map +1 -1
  133. package/dest/fee/public_fee_payment_method.js +14 -14
  134. package/dest/fee/sponsored_fee_payment.d.ts +2 -2
  135. package/dest/fee/sponsored_fee_payment.d.ts.map +1 -1
  136. package/dest/fee/sponsored_fee_payment.js +5 -5
  137. package/dest/scripts/generate_protocol_contract_types.d.ts +2 -0
  138. package/dest/scripts/generate_protocol_contract_types.d.ts.map +1 -0
  139. package/dest/scripts/generate_protocol_contract_types.js +120 -0
  140. package/dest/utils/abi_types.d.ts +2 -2
  141. package/dest/utils/abi_types.d.ts.map +1 -1
  142. package/dest/utils/authwit.d.ts +14 -12
  143. package/dest/utils/authwit.d.ts.map +1 -1
  144. package/dest/utils/authwit.js +27 -20
  145. package/dest/utils/cross_chain.d.ts +2 -2
  146. package/dest/utils/cross_chain.d.ts.map +1 -1
  147. package/dest/utils/fee_juice.d.ts +2 -2
  148. package/dest/utils/fee_juice.js +2 -2
  149. package/dest/utils/field_compressed_string.d.ts +1 -1
  150. package/dest/utils/field_compressed_string.d.ts.map +1 -1
  151. package/dest/utils/field_compressed_string.js +1 -1
  152. package/dest/utils/node.d.ts +13 -2
  153. package/dest/utils/node.d.ts.map +1 -1
  154. package/dest/utils/node.js +46 -0
  155. package/dest/utils/pub_key.d.ts +2 -2
  156. package/dest/utils/pub_key.d.ts.map +1 -1
  157. package/dest/utils/pub_key.js +1 -1
  158. package/dest/wallet/account_entrypoint_meta_payment_method.d.ts +6 -9
  159. package/dest/wallet/account_entrypoint_meta_payment_method.d.ts.map +1 -1
  160. package/dest/wallet/account_entrypoint_meta_payment_method.js +29 -44
  161. package/dest/wallet/account_manager.d.ts +3 -9
  162. package/dest/wallet/account_manager.d.ts.map +1 -1
  163. package/dest/wallet/account_manager.js +6 -12
  164. package/dest/wallet/capabilities.d.ts +452 -0
  165. package/dest/wallet/capabilities.d.ts.map +1 -0
  166. package/dest/wallet/capabilities.js +3 -0
  167. package/dest/wallet/deploy_account_method.d.ts +49 -10
  168. package/dest/wallet/deploy_account_method.d.ts.map +1 -1
  169. package/dest/wallet/deploy_account_method.js +35 -7
  170. package/dest/wallet/index.d.ts +2 -2
  171. package/dest/wallet/index.d.ts.map +1 -1
  172. package/dest/wallet/index.js +1 -1
  173. package/dest/wallet/wallet.d.ts +1853 -1533
  174. package/dest/wallet/wallet.d.ts.map +1 -1
  175. package/dest/wallet/wallet.js +223 -124
  176. package/package.json +27 -15
  177. package/src/account/account.ts +35 -60
  178. package/src/account/account_contract.ts +7 -8
  179. package/src/account/account_with_secret_key.ts +34 -9
  180. package/src/account/index.ts +3 -2
  181. package/src/account/signerless_account.ts +15 -15
  182. package/src/api/account.ts +10 -3
  183. package/src/api/authorization.ts +1 -0
  184. package/src/api/contract.ts +26 -10
  185. package/src/api/deployment.ts +0 -1
  186. package/src/api/events.ts +35 -27
  187. package/src/api/fields.ts +3 -1
  188. package/src/api/keys.ts +2 -2
  189. package/src/api/node.ts +7 -3
  190. package/src/api/note.ts +1 -1
  191. package/src/api/protocol.ts +7 -0
  192. package/src/api/tx.ts +4 -0
  193. package/src/api/wallet.ts +52 -9
  194. package/src/authorization/call_authorization_request.ts +1 -1
  195. package/src/contract/base_contract_interaction.ts +27 -16
  196. package/src/contract/batch_call.ts +62 -48
  197. package/src/contract/contract.ts +7 -5
  198. package/src/contract/contract_base.ts +5 -15
  199. package/src/contract/contract_function_interaction.ts +26 -17
  200. package/src/contract/deploy_method.ts +175 -47
  201. package/src/contract/get_gas_limits.ts +3 -3
  202. package/src/contract/interaction_options.ts +59 -13
  203. package/src/contract/protocol_contracts/auth-registry.ts +551 -0
  204. package/src/contract/protocol_contracts/contract-class-registry.ts +99 -0
  205. package/src/contract/protocol_contracts/contract-instance-registry.ts +302 -0
  206. package/src/contract/protocol_contracts/fee-juice.ts +264 -0
  207. package/src/contract/protocol_contracts/multi-call-entrypoint.ts +334 -0
  208. package/src/contract/protocol_contracts/public-checks.ts +318 -0
  209. package/src/contract/wait_for_proven.ts +1 -1
  210. package/src/contract/wait_opts.ts +21 -0
  211. package/src/deployment/contract_deployer.ts +3 -2
  212. package/src/deployment/publish_class.ts +3 -3
  213. package/src/deployment/publish_instance.ts +3 -6
  214. package/src/ethereum/portal_manager.ts +65 -34
  215. package/src/fee/fee_juice_payment_method_with_claim.ts +9 -7
  216. package/src/fee/fee_payment_method.ts +1 -1
  217. package/src/fee/private_fee_payment_method.ts +12 -10
  218. package/src/fee/public_fee_payment_method.ts +13 -11
  219. package/src/fee/sponsored_fee_payment.ts +6 -4
  220. package/src/scripts/generate_protocol_contract_types.ts +150 -0
  221. package/src/utils/abi_types.ts +1 -1
  222. package/src/utils/authwit.ts +40 -22
  223. package/src/utils/cross_chain.ts +1 -1
  224. package/src/utils/fee_juice.ts +2 -2
  225. package/src/utils/field_compressed_string.ts +1 -1
  226. package/src/utils/node.ts +62 -0
  227. package/src/utils/pub_key.ts +2 -2
  228. package/src/wallet/account_entrypoint_meta_payment_method.ts +29 -60
  229. package/src/wallet/account_manager.ts +7 -15
  230. package/src/wallet/capabilities.ts +500 -0
  231. package/src/wallet/deploy_account_method.ts +78 -16
  232. package/src/wallet/index.ts +1 -1
  233. package/src/wallet/wallet.ts +387 -166
  234. package/dest/account/interface.d.ts +0 -19
  235. package/dest/account/interface.d.ts.map +0 -1
  236. package/dest/account/interface.js +0 -5
  237. package/dest/contract/deploy_sent_tx.d.ts +0 -43
  238. package/dest/contract/deploy_sent_tx.d.ts.map +0 -1
  239. package/dest/contract/deploy_sent_tx.js +0 -40
  240. package/dest/contract/protocol_contracts.d.ts +0 -9
  241. package/dest/contract/protocol_contracts.d.ts.map +0 -1
  242. package/dest/contract/protocol_contracts.js +0 -26
  243. package/dest/contract/sent_tx.d.ts +0 -51
  244. package/dest/contract/sent_tx.d.ts.map +0 -1
  245. package/dest/contract/sent_tx.js +0 -90
  246. package/dest/contract/unsafe_contract.d.ts +0 -15
  247. package/dest/contract/unsafe_contract.d.ts.map +0 -1
  248. package/dest/contract/unsafe_contract.js +0 -6
  249. package/dest/deployment/broadcast_function.d.ts +0 -24
  250. package/dest/deployment/broadcast_function.d.ts.map +0 -1
  251. package/dest/deployment/broadcast_function.js +0 -74
  252. package/dest/wallet/base_wallet.d.ts +0 -91
  253. package/dest/wallet/base_wallet.d.ts.map +0 -1
  254. package/dest/wallet/base_wallet.js +0 -238
  255. package/src/account/interface.ts +0 -25
  256. package/src/contract/deploy_sent_tx.ts +0 -68
  257. package/src/contract/protocol_contracts.ts +0 -35
  258. package/src/contract/sent_tx.ts +0 -130
  259. package/src/contract/unsafe_contract.ts +0 -19
  260. package/src/deployment/broadcast_function.ts +0 -148
  261. package/src/wallet/base_wallet.ts +0 -350
@@ -0,0 +1,302 @@
1
+ /* Autogenerated file, do not edit! */
2
+ /* eslint-disable */
3
+ import { ProtocolContractAddress } from '@aztec/protocol-contracts';
4
+ import { FunctionType } from '@aztec/stdlib/abi';
5
+
6
+ import type { ContractArtifact } from '../../api/abi.js';
7
+ import { PublicKeys } from '../../api/keys.js';
8
+ import type {
9
+ AztecAddressLike,
10
+ EthAddressLike,
11
+ FieldLike,
12
+ FunctionSelectorLike,
13
+ WrappedFieldLike,
14
+ } from '../../utils/abi_types.js';
15
+ import type { Wallet } from '../../wallet/wallet.js';
16
+ import { ContractBase, type ContractMethod } from '../contract_base.js';
17
+ import { ContractFunctionInteraction } from '../contract_function_interaction.js';
18
+
19
+ const ContractInstanceRegistryContractArtifact: ContractArtifact = {
20
+ name: 'ContractInstanceRegistry',
21
+ functions: [
22
+ {
23
+ ...{
24
+ functionType: FunctionType.PUBLIC,
25
+ name: 'public_dispatch',
26
+ isOnlySelf: false,
27
+ isStatic: false,
28
+ isInitializer: false,
29
+ parameters: [{ name: 'selector', type: { kind: 'field' }, visibility: 'private' }],
30
+ returnTypes: [],
31
+ errorTypes: {
32
+ '361444214588792908': { error_kind: 'string', string: 'attempt to multiply with overflow' },
33
+ '1998584279744703196': { error_kind: 'string', string: 'attempt to subtract with overflow' },
34
+ '5755400808989454547': {
35
+ error_kind: 'string',
36
+ string: 'Function get_update_delay can only be called statically',
37
+ },
38
+ '6804164082532189961': { error_kind: 'string', string: 'New update delay is too low' },
39
+ '12511970388699677811': { error_kind: 'fmtstring', length: 27, item_types: [{ kind: 'field' }] },
40
+ '12579274401768182412': { error_kind: 'string', string: 'New contract class is not registered' },
41
+ '13455385521185560676': {
42
+ error_kind: 'string',
43
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.',
44
+ },
45
+ '14990209321349310352': { error_kind: 'string', string: 'attempt to add with overflow' },
46
+ '15353471697975175405': { error_kind: 'string', string: 'msg.sender is not deployed' },
47
+ '15764276373176857197': { error_kind: 'string', string: 'Stack too deep' },
48
+ '16431471497789672479': { error_kind: 'string', string: 'Index out of bounds' },
49
+ },
50
+ },
51
+ bytecode: Buffer.from([]),
52
+ debugSymbols: '',
53
+ },
54
+ {
55
+ ...{
56
+ functionType: FunctionType.PRIVATE,
57
+ name: 'publish_for_public_execution',
58
+ isOnlySelf: false,
59
+ isStatic: false,
60
+ isInitializer: false,
61
+ parameters: [
62
+ { name: 'salt', type: { kind: 'field' }, visibility: 'private' },
63
+ {
64
+ name: 'contract_class_id',
65
+ type: {
66
+ kind: 'struct',
67
+ fields: [{ name: 'inner', type: { kind: 'field' } }],
68
+ path: 'aztec::protocol_types::contract_class_id::ContractClassId',
69
+ },
70
+ visibility: 'private',
71
+ },
72
+ { name: 'initialization_hash', type: { kind: 'field' }, visibility: 'private' },
73
+ {
74
+ name: 'public_keys',
75
+ type: {
76
+ kind: 'struct',
77
+ fields: [
78
+ {
79
+ name: 'npk_m',
80
+ type: {
81
+ kind: 'struct',
82
+ fields: [
83
+ {
84
+ name: 'inner',
85
+ type: {
86
+ kind: 'struct',
87
+ fields: [
88
+ { name: 'x', type: { kind: 'field' } },
89
+ { name: 'y', type: { kind: 'field' } },
90
+ { name: 'is_infinite', type: { kind: 'boolean' } },
91
+ ],
92
+ path: 'std::embedded_curve_ops::EmbeddedCurvePoint',
93
+ },
94
+ },
95
+ ],
96
+ path: 'aztec::protocol_types::public_keys::NpkM',
97
+ },
98
+ },
99
+ {
100
+ name: 'ivpk_m',
101
+ type: {
102
+ kind: 'struct',
103
+ fields: [
104
+ {
105
+ name: 'inner',
106
+ type: {
107
+ kind: 'struct',
108
+ fields: [
109
+ { name: 'x', type: { kind: 'field' } },
110
+ { name: 'y', type: { kind: 'field' } },
111
+ { name: 'is_infinite', type: { kind: 'boolean' } },
112
+ ],
113
+ path: 'std::embedded_curve_ops::EmbeddedCurvePoint',
114
+ },
115
+ },
116
+ ],
117
+ path: 'aztec::protocol_types::public_keys::IvpkM',
118
+ },
119
+ },
120
+ {
121
+ name: 'ovpk_m',
122
+ type: {
123
+ kind: 'struct',
124
+ fields: [
125
+ {
126
+ name: 'inner',
127
+ type: {
128
+ kind: 'struct',
129
+ fields: [
130
+ { name: 'x', type: { kind: 'field' } },
131
+ { name: 'y', type: { kind: 'field' } },
132
+ { name: 'is_infinite', type: { kind: 'boolean' } },
133
+ ],
134
+ path: 'std::embedded_curve_ops::EmbeddedCurvePoint',
135
+ },
136
+ },
137
+ ],
138
+ path: 'aztec::protocol_types::public_keys::OvpkM',
139
+ },
140
+ },
141
+ {
142
+ name: 'tpk_m',
143
+ type: {
144
+ kind: 'struct',
145
+ fields: [
146
+ {
147
+ name: 'inner',
148
+ type: {
149
+ kind: 'struct',
150
+ fields: [
151
+ { name: 'x', type: { kind: 'field' } },
152
+ { name: 'y', type: { kind: 'field' } },
153
+ { name: 'is_infinite', type: { kind: 'boolean' } },
154
+ ],
155
+ path: 'std::embedded_curve_ops::EmbeddedCurvePoint',
156
+ },
157
+ },
158
+ ],
159
+ path: 'aztec::protocol_types::public_keys::TpkM',
160
+ },
161
+ },
162
+ ],
163
+ path: 'aztec::protocol_types::public_keys::PublicKeys',
164
+ },
165
+ visibility: 'private',
166
+ },
167
+ { name: 'universal_deploy', type: { kind: 'boolean' }, visibility: 'private' },
168
+ ],
169
+ returnTypes: [],
170
+ errorTypes: {
171
+ '718532354304118388': { error_kind: 'string', string: 'Point not on curve' },
172
+ '4135474769840782447': {
173
+ error_kind: 'string',
174
+ string: 'Point at infinity should have canonical representation (0 0)',
175
+ },
176
+ '12469291177396340830': { error_kind: 'string', string: 'call to assert_max_bit_size' },
177
+ '14990209321349310352': { error_kind: 'string', string: 'attempt to add with overflow' },
178
+ '15764276373176857197': { error_kind: 'string', string: 'Stack too deep' },
179
+ },
180
+ },
181
+ bytecode: Buffer.from([]),
182
+ debugSymbols: '',
183
+ },
184
+ ],
185
+ nonDispatchPublicFunctions: [
186
+ {
187
+ functionType: FunctionType.PUBLIC,
188
+ name: 'get_update_delay',
189
+ isOnlySelf: false,
190
+ isStatic: true,
191
+ isInitializer: false,
192
+ parameters: [],
193
+ returnTypes: [{ kind: 'integer', sign: 'unsigned', width: 64 }],
194
+ errorTypes: {
195
+ '5755400808989454547': {
196
+ error_kind: 'string',
197
+ string: 'Function get_update_delay can only be called statically',
198
+ },
199
+ '13455385521185560676': {
200
+ error_kind: 'string',
201
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.',
202
+ },
203
+ '15764276373176857197': { error_kind: 'string', string: 'Stack too deep' },
204
+ },
205
+ },
206
+ {
207
+ functionType: FunctionType.PUBLIC,
208
+ name: 'set_update_delay',
209
+ isOnlySelf: false,
210
+ isStatic: false,
211
+ isInitializer: false,
212
+ parameters: [
213
+ { name: 'new_update_delay', type: { kind: 'integer', sign: 'unsigned', width: 64 }, visibility: 'private' },
214
+ ],
215
+ returnTypes: [],
216
+ errorTypes: {
217
+ '361444214588792908': { error_kind: 'string', string: 'attempt to multiply with overflow' },
218
+ '1998584279744703196': { error_kind: 'string', string: 'attempt to subtract with overflow' },
219
+ '6804164082532189961': { error_kind: 'string', string: 'New update delay is too low' },
220
+ '13455385521185560676': {
221
+ error_kind: 'string',
222
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.',
223
+ },
224
+ '14990209321349310352': { error_kind: 'string', string: 'attempt to add with overflow' },
225
+ '15353471697975175405': { error_kind: 'string', string: 'msg.sender is not deployed' },
226
+ '15764276373176857197': { error_kind: 'string', string: 'Stack too deep' },
227
+ '16431471497789672479': { error_kind: 'string', string: 'Index out of bounds' },
228
+ },
229
+ },
230
+ {
231
+ functionType: FunctionType.PUBLIC,
232
+ name: 'update',
233
+ isOnlySelf: false,
234
+ isStatic: false,
235
+ isInitializer: false,
236
+ parameters: [
237
+ {
238
+ name: 'new_contract_class_id',
239
+ type: {
240
+ kind: 'struct',
241
+ fields: [{ name: 'inner', type: { kind: 'field' } }],
242
+ path: 'aztec::protocol_types::contract_class_id::ContractClassId',
243
+ },
244
+ visibility: 'private',
245
+ },
246
+ ],
247
+ returnTypes: [],
248
+ errorTypes: {
249
+ '361444214588792908': { error_kind: 'string', string: 'attempt to multiply with overflow' },
250
+ '1998584279744703196': { error_kind: 'string', string: 'attempt to subtract with overflow' },
251
+ '12579274401768182412': { error_kind: 'string', string: 'New contract class is not registered' },
252
+ '13455385521185560676': {
253
+ error_kind: 'string',
254
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.',
255
+ },
256
+ '14990209321349310352': { error_kind: 'string', string: 'attempt to add with overflow' },
257
+ '15353471697975175405': { error_kind: 'string', string: 'msg.sender is not deployed' },
258
+ '15764276373176857197': { error_kind: 'string', string: 'Stack too deep' },
259
+ '16431471497789672479': { error_kind: 'string', string: 'Index out of bounds' },
260
+ },
261
+ },
262
+ ],
263
+ outputs: { structs: {}, globals: {} },
264
+ storageLayout: {},
265
+ fileMap: {},
266
+ };
267
+
268
+ export class ContractInstanceRegistryContract extends ContractBase {
269
+ private constructor(wallet: Wallet) {
270
+ super(ProtocolContractAddress.ContractInstanceRegistry, ContractInstanceRegistryContractArtifact, wallet);
271
+ }
272
+
273
+ public static at(wallet: Wallet): ContractInstanceRegistryContract {
274
+ return new ContractInstanceRegistryContract(wallet);
275
+ }
276
+
277
+ declare public methods: {
278
+ /** get_update_delay() */
279
+ get_update_delay: (() => ContractFunctionInteraction) & Pick<ContractMethod, 'selector'>;
280
+
281
+ /** public_dispatch(selector: field) */
282
+ public_dispatch: ((selector: FieldLike) => ContractFunctionInteraction) & Pick<ContractMethod, 'selector'>;
283
+
284
+ /** publish_for_public_execution(salt: field, contract_class_id: struct, initialization_hash: field, public_keys: struct, universal_deploy: boolean) */
285
+ publish_for_public_execution: ((
286
+ salt: FieldLike,
287
+ contract_class_id: WrappedFieldLike,
288
+ initialization_hash: FieldLike,
289
+ public_keys: PublicKeys,
290
+ universal_deploy: boolean,
291
+ ) => ContractFunctionInteraction) &
292
+ Pick<ContractMethod, 'selector'>;
293
+
294
+ /** set_update_delay(new_update_delay: integer) */
295
+ set_update_delay: ((new_update_delay: bigint | number) => ContractFunctionInteraction) &
296
+ Pick<ContractMethod, 'selector'>;
297
+
298
+ /** update(new_contract_class_id: struct) */
299
+ update: ((new_contract_class_id: WrappedFieldLike) => ContractFunctionInteraction) &
300
+ Pick<ContractMethod, 'selector'>;
301
+ };
302
+ }
@@ -0,0 +1,264 @@
1
+ /* Autogenerated file, do not edit! */
2
+ /* eslint-disable */
3
+ import { ProtocolContractAddress } from '@aztec/protocol-contracts';
4
+ import { FunctionType } from '@aztec/stdlib/abi';
5
+
6
+ import type { ContractArtifact } from '../../api/abi.js';
7
+ import { PublicKeys } from '../../api/keys.js';
8
+ import type {
9
+ AztecAddressLike,
10
+ EthAddressLike,
11
+ FieldLike,
12
+ FunctionSelectorLike,
13
+ WrappedFieldLike,
14
+ } from '../../utils/abi_types.js';
15
+ import type { Wallet } from '../../wallet/wallet.js';
16
+ import { ContractBase, type ContractMethod } from '../contract_base.js';
17
+ import { ContractFunctionInteraction } from '../contract_function_interaction.js';
18
+
19
+ const FeeJuiceContractArtifact: ContractArtifact = {
20
+ name: 'FeeJuice',
21
+ functions: [
22
+ {
23
+ ...{
24
+ functionType: FunctionType.PRIVATE,
25
+ name: 'claim',
26
+ isOnlySelf: false,
27
+ isStatic: false,
28
+ isInitializer: false,
29
+ parameters: [
30
+ {
31
+ name: 'to',
32
+ type: {
33
+ kind: 'struct',
34
+ fields: [{ name: 'inner', type: { kind: 'field' } }],
35
+ path: 'aztec::protocol_types::address::aztec_address::AztecAddress',
36
+ },
37
+ visibility: 'private',
38
+ },
39
+ { name: 'amount', type: { kind: 'integer', sign: 'unsigned', width: 128 }, visibility: 'private' },
40
+ { name: 'secret', type: { kind: 'field' }, visibility: 'private' },
41
+ { name: 'message_leaf_index', type: { kind: 'field' }, visibility: 'private' },
42
+ ],
43
+ returnTypes: [],
44
+ errorTypes: {
45
+ '361444214588792908': { error_kind: 'string', string: 'attempt to multiply with overflow' },
46
+ '1998584279744703196': { error_kind: 'string', string: 'attempt to subtract with overflow' },
47
+ '6609888949476313245': { error_kind: 'string', string: 'Message not in state' },
48
+ '11019205087382408538': { error_kind: 'string', string: 'Field failed to decompose into specified 4 limbs' },
49
+ '12370419938245003393': { error_kind: 'string', string: 'Field failed to decompose into specified 36 limbs' },
50
+ '14990209321349310352': { error_kind: 'string', string: 'attempt to add with overflow' },
51
+ '15764276373176857197': { error_kind: 'string', string: 'Stack too deep' },
52
+ '15835548349546956319': { error_kind: 'string', string: 'Field failed to decompose into specified 32 limbs' },
53
+ '16431471497789672479': { error_kind: 'string', string: 'Index out of bounds' },
54
+ },
55
+ },
56
+ bytecode: Buffer.from([]),
57
+ debugSymbols: '',
58
+ },
59
+ {
60
+ ...{
61
+ functionType: FunctionType.PRIVATE,
62
+ name: 'claim_and_end_setup',
63
+ isOnlySelf: false,
64
+ isStatic: false,
65
+ isInitializer: false,
66
+ parameters: [
67
+ {
68
+ name: 'to',
69
+ type: {
70
+ kind: 'struct',
71
+ fields: [{ name: 'inner', type: { kind: 'field' } }],
72
+ path: 'aztec::protocol_types::address::aztec_address::AztecAddress',
73
+ },
74
+ visibility: 'private',
75
+ },
76
+ { name: 'amount', type: { kind: 'integer', sign: 'unsigned', width: 128 }, visibility: 'private' },
77
+ { name: 'secret', type: { kind: 'field' }, visibility: 'private' },
78
+ { name: 'message_leaf_index', type: { kind: 'field' }, visibility: 'private' },
79
+ ],
80
+ returnTypes: [],
81
+ errorTypes: {
82
+ '361444214588792908': { error_kind: 'string', string: 'attempt to multiply with overflow' },
83
+ '1998584279744703196': { error_kind: 'string', string: 'attempt to subtract with overflow' },
84
+ '6609888949476313245': { error_kind: 'string', string: 'Message not in state' },
85
+ '11019205087382408538': { error_kind: 'string', string: 'Field failed to decompose into specified 4 limbs' },
86
+ '12370419938245003393': { error_kind: 'string', string: 'Field failed to decompose into specified 36 limbs' },
87
+ '14990209321349310352': { error_kind: 'string', string: 'attempt to add with overflow' },
88
+ '15764276373176857197': { error_kind: 'string', string: 'Stack too deep' },
89
+ '15835548349546956319': { error_kind: 'string', string: 'Field failed to decompose into specified 32 limbs' },
90
+ '16431471497789672479': { error_kind: 'string', string: 'Index out of bounds' },
91
+ },
92
+ },
93
+ bytecode: Buffer.from([]),
94
+ debugSymbols: '',
95
+ },
96
+ {
97
+ ...{
98
+ functionType: FunctionType.PUBLIC,
99
+ name: 'public_dispatch',
100
+ isOnlySelf: false,
101
+ isStatic: false,
102
+ isInitializer: false,
103
+ parameters: [{ name: 'selector', type: { kind: 'field' }, visibility: 'private' }],
104
+ returnTypes: [],
105
+ errorTypes: {
106
+ '361444214588792908': { error_kind: 'string', string: 'attempt to multiply with overflow' },
107
+ '1080336462466469436': {
108
+ error_kind: 'string',
109
+ string: 'Function check_balance can only be called statically',
110
+ },
111
+ '1998584279744703196': { error_kind: 'string', string: 'attempt to subtract with overflow' },
112
+ '8637882143979902881': {
113
+ error_kind: 'string',
114
+ string: 'Function _increase_public_balance can only be called by the same contract',
115
+ },
116
+ '9543832133280402246': { error_kind: 'string', string: 'Balance too low' },
117
+ '12511970388699677811': { error_kind: 'fmtstring', length: 27, item_types: [{ kind: 'field' }] },
118
+ '13455385521185560676': {
119
+ error_kind: 'string',
120
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.',
121
+ },
122
+ '14990209321349310352': { error_kind: 'string', string: 'attempt to add with overflow' },
123
+ '15764276373176857197': { error_kind: 'string', string: 'Stack too deep' },
124
+ '15860392472534760515': {
125
+ error_kind: 'string',
126
+ string: 'Function balance_of_public can only be called statically',
127
+ },
128
+ '16431471497789672479': { error_kind: 'string', string: 'Index out of bounds' },
129
+ },
130
+ },
131
+ bytecode: Buffer.from([]),
132
+ debugSymbols: '',
133
+ },
134
+ ],
135
+ nonDispatchPublicFunctions: [
136
+ {
137
+ functionType: FunctionType.PUBLIC,
138
+ name: '_increase_public_balance',
139
+ isOnlySelf: true,
140
+ isStatic: false,
141
+ isInitializer: false,
142
+ parameters: [
143
+ {
144
+ name: 'to',
145
+ type: {
146
+ kind: 'struct',
147
+ fields: [{ name: 'inner', type: { kind: 'field' } }],
148
+ path: 'aztec::protocol_types::address::aztec_address::AztecAddress',
149
+ },
150
+ visibility: 'private',
151
+ },
152
+ { name: 'amount', type: { kind: 'integer', sign: 'unsigned', width: 128 }, visibility: 'private' },
153
+ ],
154
+ returnTypes: [],
155
+ errorTypes: {
156
+ '361444214588792908': { error_kind: 'string', string: 'attempt to multiply with overflow' },
157
+ '1998584279744703196': { error_kind: 'string', string: 'attempt to subtract with overflow' },
158
+ '8637882143979902881': {
159
+ error_kind: 'string',
160
+ string: 'Function _increase_public_balance can only be called by the same contract',
161
+ },
162
+ '13455385521185560676': {
163
+ error_kind: 'string',
164
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.',
165
+ },
166
+ '14990209321349310352': { error_kind: 'string', string: 'attempt to add with overflow' },
167
+ '15764276373176857197': { error_kind: 'string', string: 'Stack too deep' },
168
+ '16431471497789672479': { error_kind: 'string', string: 'Index out of bounds' },
169
+ },
170
+ },
171
+ {
172
+ functionType: FunctionType.PUBLIC,
173
+ name: 'balance_of_public',
174
+ isOnlySelf: false,
175
+ isStatic: true,
176
+ isInitializer: false,
177
+ parameters: [
178
+ {
179
+ name: 'owner',
180
+ type: {
181
+ kind: 'struct',
182
+ fields: [{ name: 'inner', type: { kind: 'field' } }],
183
+ path: 'aztec::protocol_types::address::aztec_address::AztecAddress',
184
+ },
185
+ visibility: 'private',
186
+ },
187
+ ],
188
+ returnTypes: [{ kind: 'integer', sign: 'unsigned', width: 128 }],
189
+ errorTypes: {
190
+ '13455385521185560676': {
191
+ error_kind: 'string',
192
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.',
193
+ },
194
+ '15764276373176857197': { error_kind: 'string', string: 'Stack too deep' },
195
+ '15860392472534760515': {
196
+ error_kind: 'string',
197
+ string: 'Function balance_of_public can only be called statically',
198
+ },
199
+ },
200
+ },
201
+ {
202
+ functionType: FunctionType.PUBLIC,
203
+ name: 'check_balance',
204
+ isOnlySelf: false,
205
+ isStatic: true,
206
+ isInitializer: false,
207
+ parameters: [
208
+ { name: 'fee_limit', type: { kind: 'integer', sign: 'unsigned', width: 128 }, visibility: 'private' },
209
+ ],
210
+ returnTypes: [],
211
+ errorTypes: {
212
+ '1080336462466469436': { error_kind: 'string', string: 'Function check_balance can only be called statically' },
213
+ '9543832133280402246': { error_kind: 'string', string: 'Balance too low' },
214
+ '13455385521185560676': {
215
+ error_kind: 'string',
216
+ string: 'Storage slot 0 not allowed. Storage slots must start from 1.',
217
+ },
218
+ '15764276373176857197': { error_kind: 'string', string: 'Stack too deep' },
219
+ },
220
+ },
221
+ ],
222
+ outputs: { structs: {}, globals: {} },
223
+ storageLayout: {},
224
+ fileMap: {},
225
+ };
226
+
227
+ export class FeeJuiceContract extends ContractBase {
228
+ private constructor(wallet: Wallet) {
229
+ super(ProtocolContractAddress.FeeJuice, FeeJuiceContractArtifact, wallet);
230
+ }
231
+
232
+ public static at(wallet: Wallet): FeeJuiceContract {
233
+ return new FeeJuiceContract(wallet);
234
+ }
235
+
236
+ declare public methods: {
237
+ /** balance_of_public(owner: struct) */
238
+ balance_of_public: ((owner: AztecAddressLike) => ContractFunctionInteraction) & Pick<ContractMethod, 'selector'>;
239
+
240
+ /** check_balance(fee_limit: integer) */
241
+ check_balance: ((fee_limit: bigint | number) => ContractFunctionInteraction) & Pick<ContractMethod, 'selector'>;
242
+
243
+ /** claim(to: struct, amount: integer, secret: field, message_leaf_index: field) */
244
+ claim: ((
245
+ to: AztecAddressLike,
246
+ amount: bigint | number,
247
+ secret: FieldLike,
248
+ message_leaf_index: FieldLike,
249
+ ) => ContractFunctionInteraction) &
250
+ Pick<ContractMethod, 'selector'>;
251
+
252
+ /** claim_and_end_setup(to: struct, amount: integer, secret: field, message_leaf_index: field) */
253
+ claim_and_end_setup: ((
254
+ to: AztecAddressLike,
255
+ amount: bigint | number,
256
+ secret: FieldLike,
257
+ message_leaf_index: FieldLike,
258
+ ) => ContractFunctionInteraction) &
259
+ Pick<ContractMethod, 'selector'>;
260
+
261
+ /** public_dispatch(selector: field) */
262
+ public_dispatch: ((selector: FieldLike) => ContractFunctionInteraction) & Pick<ContractMethod, 'selector'>;
263
+ };
264
+ }