@mistcash/config 0.2.2 → 0.5.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.
package/src/contracts.ts CHANGED
@@ -1,772 +1,819 @@
1
- import { Abi, TypedContractV2 } from "starknet";
1
+ import { Abi, TypedContractV2 } from 'starknet';
2
2
 
3
- export const CHAMBER_ADDR_MAINNET = (process.env.CHAMBER_ADDR_MAINNET || '0x063eab2f19523fc8578c66a3ddf248d72094c65154b6dd7680b6e05a64845277') as `0x${string}`;
3
+ export const CHAMBER_ADDR_MAINNET = (process.env.CHAMBER_ADDR_MAINNET ||
4
+ '0x03a889eb7aecedcb76b987fc981ad3b92689cf45bffec8c1c409a4b0b79c3f31') as `0x${string}`;
4
5
 
5
6
  export const CHAMBER_ABI = [
6
- {
7
- "type": "impl",
8
- "name": "UpgradeableImpl",
9
- "interface_name": "openzeppelin_upgrades::interface::IUpgradeable"
10
- },
11
- {
12
- "type": "interface",
13
- "name": "openzeppelin_upgrades::interface::IUpgradeable",
14
- "items": [
15
- {
16
- "type": "function",
17
- "name": "upgrade",
18
- "inputs": [
19
- {
20
- "name": "new_class_hash",
21
- "type": "core::starknet::class_hash::ClassHash"
22
- }
23
- ],
24
- "outputs": [],
25
- "state_mutability": "external"
26
- }
27
- ]
28
- },
29
- {
30
- "type": "impl",
31
- "name": "IChamberImpl",
32
- "interface_name": "contracts::multi_asset::IChamber"
33
- },
34
- {
35
- "type": "struct",
36
- "name": "core::integer::u256",
37
- "members": [
38
- {
39
- "name": "low",
40
- "type": "core::integer::u128"
41
- },
42
- {
43
- "name": "high",
44
- "type": "core::integer::u128"
45
- }
46
- ]
47
- },
48
- {
49
- "type": "struct",
50
- "name": "contracts::multi_asset::Asset",
51
- "members": [
52
- {
53
- "name": "amount",
54
- "type": "core::integer::u256"
55
- },
56
- {
57
- "name": "addr",
58
- "type": "core::starknet::contract_address::ContractAddress"
59
- }
60
- ]
61
- },
62
- {
63
- "type": "struct",
64
- "name": "core::array::Span::<core::integer::u256>",
65
- "members": [
66
- {
67
- "name": "snapshot",
68
- "type": "@core::array::Array::<core::integer::u256>"
69
- }
70
- ]
71
- },
72
- {
73
- "type": "struct",
74
- "name": "core::array::Span::<core::felt252>",
75
- "members": [
76
- {
77
- "name": "snapshot",
78
- "type": "@core::array::Array::<core::felt252>"
79
- }
80
- ]
81
- },
82
- {
83
- "type": "interface",
84
- "name": "contracts::multi_asset::IChamber",
85
- "items": [
86
- {
87
- "type": "function",
88
- "name": "deposit",
89
- "inputs": [
90
- {
91
- "name": "hash",
92
- "type": "core::integer::u256"
93
- },
94
- {
95
- "name": "asset",
96
- "type": "contracts::multi_asset::Asset"
97
- }
98
- ],
99
- "outputs": [],
100
- "state_mutability": "external"
101
- },
102
- {
103
- "type": "function",
104
- "name": "withdraw_no_zk",
105
- "inputs": [
106
- {
107
- "name": "claiming_key",
108
- "type": "core::integer::u256"
109
- },
110
- {
111
- "name": "recipient",
112
- "type": "core::starknet::contract_address::ContractAddress"
113
- },
114
- {
115
- "name": "asset",
116
- "type": "contracts::multi_asset::Asset"
117
- },
118
- {
119
- "name": "proof",
120
- "type": "core::array::Span::<core::integer::u256>"
121
- }
122
- ],
123
- "outputs": [],
124
- "state_mutability": "external"
125
- },
126
- {
127
- "type": "function",
128
- "name": "seek_and_hide_no_zk",
129
- "inputs": [
130
- {
131
- "name": "claiming_key",
132
- "type": "core::integer::u256"
133
- },
134
- {
135
- "name": "recipient",
136
- "type": "core::starknet::contract_address::ContractAddress"
137
- },
138
- {
139
- "name": "asset",
140
- "type": "contracts::multi_asset::Asset"
141
- },
142
- {
143
- "name": "proof",
144
- "type": "core::array::Span::<core::integer::u256>"
145
- },
146
- {
147
- "name": "new_tx_secret",
148
- "type": "core::integer::u256"
149
- },
150
- {
151
- "name": "new_tx_amount",
152
- "type": "core::integer::u256"
153
- }
154
- ],
155
- "outputs": [],
156
- "state_mutability": "external"
157
- },
158
- {
159
- "type": "function",
160
- "name": "handle_zkp",
161
- "inputs": [
162
- {
163
- "name": "proof",
164
- "type": "core::array::Span::<core::felt252>"
165
- }
166
- ],
167
- "outputs": [],
168
- "state_mutability": "external"
169
- },
170
- {
171
- "type": "function",
172
- "name": "tx_array",
173
- "inputs": [],
174
- "outputs": [
175
- {
176
- "type": "core::array::Array::<core::integer::u256>"
177
- }
178
- ],
179
- "state_mutability": "view"
180
- },
181
- {
182
- "type": "function",
183
- "name": "merkle_root",
184
- "inputs": [],
185
- "outputs": [
186
- {
187
- "type": "core::integer::u256"
188
- }
189
- ],
190
- "state_mutability": "view"
191
- },
192
- {
193
- "type": "function",
194
- "name": "merkle_proof",
195
- "inputs": [
196
- {
197
- "name": "index",
198
- "type": "core::integer::u32"
199
- }
200
- ],
201
- "outputs": [
202
- {
203
- "type": "core::array::Span::<core::integer::u256>"
204
- }
205
- ],
206
- "state_mutability": "external"
207
- },
208
- {
209
- "type": "function",
210
- "name": "merkle_leaves",
211
- "inputs": [
212
- {
213
- "name": "height",
214
- "type": "core::integer::u32"
215
- }
216
- ],
217
- "outputs": [
218
- {
219
- "type": "core::array::Array::<core::integer::u256>"
220
- }
221
- ],
222
- "state_mutability": "external"
223
- }
224
- ]
225
- },
226
- {
227
- "type": "impl",
228
- "name": "OwnableMixinImpl",
229
- "interface_name": "openzeppelin_access::ownable::interface::OwnableABI"
230
- },
231
- {
232
- "type": "interface",
233
- "name": "openzeppelin_access::ownable::interface::OwnableABI",
234
- "items": [
235
- {
236
- "type": "function",
237
- "name": "owner",
238
- "inputs": [],
239
- "outputs": [
240
- {
241
- "type": "core::starknet::contract_address::ContractAddress"
242
- }
243
- ],
244
- "state_mutability": "view"
245
- },
246
- {
247
- "type": "function",
248
- "name": "transfer_ownership",
249
- "inputs": [
250
- {
251
- "name": "new_owner",
252
- "type": "core::starknet::contract_address::ContractAddress"
253
- }
254
- ],
255
- "outputs": [],
256
- "state_mutability": "external"
257
- },
258
- {
259
- "type": "function",
260
- "name": "renounce_ownership",
261
- "inputs": [],
262
- "outputs": [],
263
- "state_mutability": "external"
264
- },
265
- {
266
- "type": "function",
267
- "name": "transferOwnership",
268
- "inputs": [
269
- {
270
- "name": "newOwner",
271
- "type": "core::starknet::contract_address::ContractAddress"
272
- }
273
- ],
274
- "outputs": [],
275
- "state_mutability": "external"
276
- },
277
- {
278
- "type": "function",
279
- "name": "renounceOwnership",
280
- "inputs": [],
281
- "outputs": [],
282
- "state_mutability": "external"
283
- }
284
- ]
285
- },
286
- {
287
- "type": "struct",
288
- "name": "verifier_contracts::honk_verifier::IUltraStarknetZKHonkVerifierDispatcher",
289
- "members": [
290
- {
291
- "name": "contract_address",
292
- "type": "core::starknet::contract_address::ContractAddress"
293
- }
294
- ]
295
- },
296
- {
297
- "type": "constructor",
298
- "name": "constructor",
299
- "inputs": [
300
- {
301
- "name": "owner",
302
- "type": "core::starknet::contract_address::ContractAddress"
303
- },
304
- {
305
- "name": "verifier",
306
- "type": "verifier_contracts::honk_verifier::IUltraStarknetZKHonkVerifierDispatcher"
307
- }
308
- ]
309
- },
310
- {
311
- "type": "function",
312
- "name": "read_tx",
313
- "inputs": [
314
- {
315
- "name": "tx_hash",
316
- "type": "core::integer::u256"
317
- }
318
- ],
319
- "outputs": [
320
- {
321
- "type": "contracts::multi_asset::Asset"
322
- }
323
- ],
324
- "state_mutability": "view"
325
- },
326
- {
327
- "type": "function",
328
- "name": "setVerifierAddress",
329
- "inputs": [
330
- {
331
- "name": "verifier",
332
- "type": "verifier_contracts::honk_verifier::IUltraStarknetZKHonkVerifierDispatcher"
333
- }
334
- ],
335
- "outputs": [],
336
- "state_mutability": "external"
337
- },
338
- {
339
- "type": "function",
340
- "name": "recalculate_merkle_root",
341
- "inputs": [],
342
- "outputs": [],
343
- "state_mutability": "external"
344
- },
345
- {
346
- "type": "event",
347
- "name": "openzeppelin_access::ownable::ownable::OwnableComponent::OwnershipTransferred",
348
- "kind": "struct",
349
- "members": [
350
- {
351
- "name": "previous_owner",
352
- "type": "core::starknet::contract_address::ContractAddress",
353
- "kind": "key"
354
- },
355
- {
356
- "name": "new_owner",
357
- "type": "core::starknet::contract_address::ContractAddress",
358
- "kind": "key"
359
- }
360
- ]
361
- },
362
- {
363
- "type": "event",
364
- "name": "openzeppelin_access::ownable::ownable::OwnableComponent::OwnershipTransferStarted",
365
- "kind": "struct",
366
- "members": [
367
- {
368
- "name": "previous_owner",
369
- "type": "core::starknet::contract_address::ContractAddress",
370
- "kind": "key"
371
- },
372
- {
373
- "name": "new_owner",
374
- "type": "core::starknet::contract_address::ContractAddress",
375
- "kind": "key"
376
- }
377
- ]
378
- },
379
- {
380
- "type": "event",
381
- "name": "openzeppelin_access::ownable::ownable::OwnableComponent::Event",
382
- "kind": "enum",
383
- "variants": [
384
- {
385
- "name": "OwnershipTransferred",
386
- "type": "openzeppelin_access::ownable::ownable::OwnableComponent::OwnershipTransferred",
387
- "kind": "nested"
388
- },
389
- {
390
- "name": "OwnershipTransferStarted",
391
- "type": "openzeppelin_access::ownable::ownable::OwnableComponent::OwnershipTransferStarted",
392
- "kind": "nested"
393
- }
394
- ]
395
- },
396
- {
397
- "type": "event",
398
- "name": "openzeppelin_upgrades::upgradeable::UpgradeableComponent::Upgraded",
399
- "kind": "struct",
400
- "members": [
401
- {
402
- "name": "class_hash",
403
- "type": "core::starknet::class_hash::ClassHash",
404
- "kind": "data"
405
- }
406
- ]
407
- },
408
- {
409
- "type": "event",
410
- "name": "openzeppelin_upgrades::upgradeable::UpgradeableComponent::Event",
411
- "kind": "enum",
412
- "variants": [
413
- {
414
- "name": "Upgraded",
415
- "type": "openzeppelin_upgrades::upgradeable::UpgradeableComponent::Upgraded",
416
- "kind": "nested"
417
- }
418
- ]
419
- },
420
- {
421
- "type": "event",
422
- "name": "contracts::multi_asset::Chamber::Event",
423
- "kind": "enum",
424
- "variants": [
425
- {
426
- "name": "OwnableEvent",
427
- "type": "openzeppelin_access::ownable::ownable::OwnableComponent::Event",
428
- "kind": "flat"
429
- },
430
- {
431
- "name": "UpgradeableEvent",
432
- "type": "openzeppelin_upgrades::upgradeable::UpgradeableComponent::Event",
433
- "kind": "flat"
434
- }
435
- ]
436
- }
7
+ {
8
+ "type": "impl",
9
+ "name": "UpgradeableImpl",
10
+ "interface_name": "openzeppelin_upgrades::interface::IUpgradeable"
11
+ },
12
+ {
13
+ "type": "interface",
14
+ "name": "openzeppelin_upgrades::interface::IUpgradeable",
15
+ "items": [
16
+ {
17
+ "type": "function",
18
+ "name": "upgrade",
19
+ "inputs": [
20
+ {
21
+ "name": "new_class_hash",
22
+ "type": "core::starknet::class_hash::ClassHash"
23
+ }
24
+ ],
25
+ "outputs": [],
26
+ "state_mutability": "external"
27
+ }
28
+ ]
29
+ },
30
+ {
31
+ "type": "impl",
32
+ "name": "IChamberImpl",
33
+ "interface_name": "contracts::chamber::IChamber"
34
+ },
35
+ {
36
+ "type": "struct",
37
+ "name": "core::integer::u256",
38
+ "members": [
39
+ {
40
+ "name": "low",
41
+ "type": "core::integer::u128"
42
+ },
43
+ {
44
+ "name": "high",
45
+ "type": "core::integer::u128"
46
+ }
47
+ ]
48
+ },
49
+ {
50
+ "type": "struct",
51
+ "name": "contracts::chamber::Asset",
52
+ "members": [
53
+ {
54
+ "name": "amount",
55
+ "type": "core::integer::u256"
56
+ },
57
+ {
58
+ "name": "addr",
59
+ "type": "core::starknet::contract_address::ContractAddress"
60
+ }
61
+ ]
62
+ },
63
+ {
64
+ "type": "struct",
65
+ "name": "core::array::Span::<core::integer::u256>",
66
+ "members": [
67
+ {
68
+ "name": "snapshot",
69
+ "type": "@core::array::Array::<core::integer::u256>"
70
+ }
71
+ ]
72
+ },
73
+ {
74
+ "type": "struct",
75
+ "name": "core::array::Span::<core::felt252>",
76
+ "members": [
77
+ {
78
+ "name": "snapshot",
79
+ "type": "@core::array::Array::<core::felt252>"
80
+ }
81
+ ]
82
+ },
83
+ {
84
+ "type": "enum",
85
+ "name": "core::bool",
86
+ "variants": [
87
+ {
88
+ "name": "False",
89
+ "type": "()"
90
+ },
91
+ {
92
+ "name": "True",
93
+ "type": "()"
94
+ }
95
+ ]
96
+ },
97
+ {
98
+ "type": "struct",
99
+ "name": "verifier_contracts::groth16_verifier::IGroth16VerifierBN254Dispatcher",
100
+ "members": [
101
+ {
102
+ "name": "contract_address",
103
+ "type": "core::starknet::contract_address::ContractAddress"
104
+ }
105
+ ]
106
+ },
107
+ {
108
+ "type": "interface",
109
+ "name": "contracts::chamber::IChamber",
110
+ "items": [
111
+ {
112
+ "type": "function",
113
+ "name": "deposit",
114
+ "inputs": [
115
+ {
116
+ "name": "hash",
117
+ "type": "core::integer::u256"
118
+ },
119
+ {
120
+ "name": "asset",
121
+ "type": "contracts::chamber::Asset"
122
+ }
123
+ ],
124
+ "outputs": [],
125
+ "state_mutability": "external"
126
+ },
127
+ {
128
+ "type": "function",
129
+ "name": "withdraw_no_zk",
130
+ "inputs": [
131
+ {
132
+ "name": "claiming_key",
133
+ "type": "core::integer::u256"
134
+ },
135
+ {
136
+ "name": "recipient",
137
+ "type": "core::starknet::contract_address::ContractAddress"
138
+ },
139
+ {
140
+ "name": "asset",
141
+ "type": "contracts::chamber::Asset"
142
+ },
143
+ {
144
+ "name": "proof",
145
+ "type": "core::array::Span::<core::integer::u256>"
146
+ }
147
+ ],
148
+ "outputs": [],
149
+ "state_mutability": "external"
150
+ },
151
+ {
152
+ "type": "function",
153
+ "name": "seek_and_hide_no_zk",
154
+ "inputs": [
155
+ {
156
+ "name": "claiming_key",
157
+ "type": "core::integer::u256"
158
+ },
159
+ {
160
+ "name": "recipient",
161
+ "type": "core::starknet::contract_address::ContractAddress"
162
+ },
163
+ {
164
+ "name": "asset",
165
+ "type": "contracts::chamber::Asset"
166
+ },
167
+ {
168
+ "name": "proof",
169
+ "type": "core::array::Span::<core::integer::u256>"
170
+ },
171
+ {
172
+ "name": "new_tx_secret",
173
+ "type": "core::integer::u256"
174
+ },
175
+ {
176
+ "name": "new_tx_amount",
177
+ "type": "core::integer::u256"
178
+ }
179
+ ],
180
+ "outputs": [],
181
+ "state_mutability": "external"
182
+ },
183
+ {
184
+ "type": "function",
185
+ "name": "handle_zkp",
186
+ "inputs": [
187
+ {
188
+ "name": "proof",
189
+ "type": "core::array::Span::<core::felt252>"
190
+ }
191
+ ],
192
+ "outputs": [],
193
+ "state_mutability": "external"
194
+ },
195
+ {
196
+ "type": "function",
197
+ "name": "tx_array",
198
+ "inputs": [],
199
+ "outputs": [
200
+ {
201
+ "type": "core::array::Array::<core::integer::u256>"
202
+ }
203
+ ],
204
+ "state_mutability": "view"
205
+ },
206
+ {
207
+ "type": "function",
208
+ "name": "merkle_root",
209
+ "inputs": [],
210
+ "outputs": [
211
+ {
212
+ "type": "core::integer::u256"
213
+ }
214
+ ],
215
+ "state_mutability": "view"
216
+ },
217
+ {
218
+ "type": "function",
219
+ "name": "merkle_proof",
220
+ "inputs": [
221
+ {
222
+ "name": "index",
223
+ "type": "core::integer::u32"
224
+ }
225
+ ],
226
+ "outputs": [
227
+ {
228
+ "type": "core::array::Span::<core::integer::u256>"
229
+ }
230
+ ],
231
+ "state_mutability": "external"
232
+ },
233
+ {
234
+ "type": "function",
235
+ "name": "merkle_leaves",
236
+ "inputs": [
237
+ {
238
+ "name": "height",
239
+ "type": "core::integer::u32"
240
+ }
241
+ ],
242
+ "outputs": [
243
+ {
244
+ "type": "core::array::Array::<core::integer::u256>"
245
+ }
246
+ ],
247
+ "state_mutability": "external"
248
+ },
249
+ {
250
+ "type": "function",
251
+ "name": "assets_from_secret",
252
+ "inputs": [
253
+ {
254
+ "name": "tx_secret",
255
+ "type": "core::integer::u256"
256
+ }
257
+ ],
258
+ "outputs": [
259
+ {
260
+ "type": "contracts::chamber::Asset"
261
+ }
262
+ ],
263
+ "state_mutability": "view"
264
+ },
265
+ {
266
+ "type": "function",
267
+ "name": "nullifiers_spent",
268
+ "inputs": [
269
+ {
270
+ "name": "nullifiers",
271
+ "type": "core::array::Array::<core::integer::u256>"
272
+ }
273
+ ],
274
+ "outputs": [
275
+ {
276
+ "type": "core::array::Array::<core::bool>"
277
+ }
278
+ ],
279
+ "state_mutability": "view"
280
+ },
281
+ {
282
+ "type": "function",
283
+ "name": "transactions_exist",
284
+ "inputs": [
285
+ {
286
+ "name": "transactions",
287
+ "type": "core::array::Array::<core::integer::u256>"
288
+ }
289
+ ],
290
+ "outputs": [
291
+ {
292
+ "type": "core::array::Array::<core::bool>"
293
+ }
294
+ ],
295
+ "state_mutability": "view"
296
+ },
297
+ {
298
+ "type": "function",
299
+ "name": "setVerifierAddress",
300
+ "inputs": [
301
+ {
302
+ "name": "verifier",
303
+ "type": "verifier_contracts::groth16_verifier::IGroth16VerifierBN254Dispatcher"
304
+ }
305
+ ],
306
+ "outputs": [],
307
+ "state_mutability": "external"
308
+ },
309
+ {
310
+ "type": "function",
311
+ "name": "recalculate_merkle_root",
312
+ "inputs": [],
313
+ "outputs": [],
314
+ "state_mutability": "external"
315
+ }
316
+ ]
317
+ },
318
+ {
319
+ "type": "impl",
320
+ "name": "OwnableMixinImpl",
321
+ "interface_name": "openzeppelin_access::ownable::interface::OwnableABI"
322
+ },
323
+ {
324
+ "type": "interface",
325
+ "name": "openzeppelin_access::ownable::interface::OwnableABI",
326
+ "items": [
327
+ {
328
+ "type": "function",
329
+ "name": "owner",
330
+ "inputs": [],
331
+ "outputs": [
332
+ {
333
+ "type": "core::starknet::contract_address::ContractAddress"
334
+ }
335
+ ],
336
+ "state_mutability": "view"
337
+ },
338
+ {
339
+ "type": "function",
340
+ "name": "transfer_ownership",
341
+ "inputs": [
342
+ {
343
+ "name": "new_owner",
344
+ "type": "core::starknet::contract_address::ContractAddress"
345
+ }
346
+ ],
347
+ "outputs": [],
348
+ "state_mutability": "external"
349
+ },
350
+ {
351
+ "type": "function",
352
+ "name": "renounce_ownership",
353
+ "inputs": [],
354
+ "outputs": [],
355
+ "state_mutability": "external"
356
+ },
357
+ {
358
+ "type": "function",
359
+ "name": "transferOwnership",
360
+ "inputs": [
361
+ {
362
+ "name": "newOwner",
363
+ "type": "core::starknet::contract_address::ContractAddress"
364
+ }
365
+ ],
366
+ "outputs": [],
367
+ "state_mutability": "external"
368
+ },
369
+ {
370
+ "type": "function",
371
+ "name": "renounceOwnership",
372
+ "inputs": [],
373
+ "outputs": [],
374
+ "state_mutability": "external"
375
+ }
376
+ ]
377
+ },
378
+ {
379
+ "type": "constructor",
380
+ "name": "constructor",
381
+ "inputs": [
382
+ {
383
+ "name": "owner",
384
+ "type": "core::starknet::contract_address::ContractAddress"
385
+ },
386
+ {
387
+ "name": "verifier",
388
+ "type": "verifier_contracts::groth16_verifier::IGroth16VerifierBN254Dispatcher"
389
+ }
390
+ ]
391
+ },
392
+ {
393
+ "type": "event",
394
+ "name": "openzeppelin_access::ownable::ownable::OwnableComponent::OwnershipTransferred",
395
+ "kind": "struct",
396
+ "members": [
397
+ {
398
+ "name": "previous_owner",
399
+ "type": "core::starknet::contract_address::ContractAddress",
400
+ "kind": "key"
401
+ },
402
+ {
403
+ "name": "new_owner",
404
+ "type": "core::starknet::contract_address::ContractAddress",
405
+ "kind": "key"
406
+ }
407
+ ]
408
+ },
409
+ {
410
+ "type": "event",
411
+ "name": "openzeppelin_access::ownable::ownable::OwnableComponent::OwnershipTransferStarted",
412
+ "kind": "struct",
413
+ "members": [
414
+ {
415
+ "name": "previous_owner",
416
+ "type": "core::starknet::contract_address::ContractAddress",
417
+ "kind": "key"
418
+ },
419
+ {
420
+ "name": "new_owner",
421
+ "type": "core::starknet::contract_address::ContractAddress",
422
+ "kind": "key"
423
+ }
424
+ ]
425
+ },
426
+ {
427
+ "type": "event",
428
+ "name": "openzeppelin_access::ownable::ownable::OwnableComponent::Event",
429
+ "kind": "enum",
430
+ "variants": [
431
+ {
432
+ "name": "OwnershipTransferred",
433
+ "type": "openzeppelin_access::ownable::ownable::OwnableComponent::OwnershipTransferred",
434
+ "kind": "nested"
435
+ },
436
+ {
437
+ "name": "OwnershipTransferStarted",
438
+ "type": "openzeppelin_access::ownable::ownable::OwnableComponent::OwnershipTransferStarted",
439
+ "kind": "nested"
440
+ }
441
+ ]
442
+ },
443
+ {
444
+ "type": "event",
445
+ "name": "openzeppelin_upgrades::upgradeable::UpgradeableComponent::Upgraded",
446
+ "kind": "struct",
447
+ "members": [
448
+ {
449
+ "name": "class_hash",
450
+ "type": "core::starknet::class_hash::ClassHash",
451
+ "kind": "data"
452
+ }
453
+ ]
454
+ },
455
+ {
456
+ "type": "event",
457
+ "name": "openzeppelin_upgrades::upgradeable::UpgradeableComponent::Event",
458
+ "kind": "enum",
459
+ "variants": [
460
+ {
461
+ "name": "Upgraded",
462
+ "type": "openzeppelin_upgrades::upgradeable::UpgradeableComponent::Upgraded",
463
+ "kind": "nested"
464
+ }
465
+ ]
466
+ },
467
+ {
468
+ "type": "event",
469
+ "name": "contracts::chamber::Chamber::Event",
470
+ "kind": "enum",
471
+ "variants": [
472
+ {
473
+ "name": "OwnableEvent",
474
+ "type": "openzeppelin_access::ownable::ownable::OwnableComponent::Event",
475
+ "kind": "flat"
476
+ },
477
+ {
478
+ "name": "UpgradeableEvent",
479
+ "type": "openzeppelin_upgrades::upgradeable::UpgradeableComponent::Event",
480
+ "kind": "flat"
481
+ }
482
+ ]
483
+ }
437
484
  ] as const satisfies Abi;
438
485
 
439
486
  export const ERC20_ABI = [
440
- {
441
- "type": "impl",
442
- "name": "ERC20MixinImpl",
443
- "interface_name": "openzeppelin_token::erc20::interface::IERC20Mixin"
444
- },
445
- {
446
- "type": "struct",
447
- "name": "core::integer::u256",
448
- "members": [
449
- {
450
- "name": "low",
451
- "type": "core::integer::u128"
452
- },
453
- {
454
- "name": "high",
455
- "type": "core::integer::u128"
456
- }
457
- ]
458
- },
459
- {
460
- "type": "enum",
461
- "name": "core::bool",
462
- "variants": [
463
- {
464
- "name": "False",
465
- "type": "()"
466
- },
467
- {
468
- "name": "True",
469
- "type": "()"
470
- }
471
- ]
472
- },
473
- {
474
- "type": "struct",
475
- "name": "core::byte_array::ByteArray",
476
- "members": [
477
- {
478
- "name": "data",
479
- "type": "core::array::Array::<core::bytes_31::bytes31>"
480
- },
481
- {
482
- "name": "pending_word",
483
- "type": "core::felt252"
484
- },
485
- {
486
- "name": "pending_word_len",
487
- "type": "core::integer::u32"
488
- }
489
- ]
490
- },
491
- {
492
- "type": "interface",
493
- "name": "openzeppelin_token::erc20::interface::IERC20Mixin",
494
- "items": [
495
- {
496
- "type": "function",
497
- "name": "total_supply",
498
- "inputs": [],
499
- "outputs": [
500
- {
501
- "type": "core::integer::u256"
502
- }
503
- ],
504
- "state_mutability": "view"
505
- },
506
- {
507
- "type": "function",
508
- "name": "balance_of",
509
- "inputs": [
510
- {
511
- "name": "account",
512
- "type": "core::starknet::contract_address::ContractAddress"
513
- }
514
- ],
515
- "outputs": [
516
- {
517
- "type": "core::integer::u256"
518
- }
519
- ],
520
- "state_mutability": "view"
521
- },
522
- {
523
- "type": "function",
524
- "name": "allowance",
525
- "inputs": [
526
- {
527
- "name": "owner",
528
- "type": "core::starknet::contract_address::ContractAddress"
529
- },
530
- {
531
- "name": "spender",
532
- "type": "core::starknet::contract_address::ContractAddress"
533
- }
534
- ],
535
- "outputs": [
536
- {
537
- "type": "core::integer::u256"
538
- }
539
- ],
540
- "state_mutability": "view"
541
- },
542
- {
543
- "type": "function",
544
- "name": "transfer",
545
- "inputs": [
546
- {
547
- "name": "recipient",
548
- "type": "core::starknet::contract_address::ContractAddress"
549
- },
550
- {
551
- "name": "amount",
552
- "type": "core::integer::u256"
553
- }
554
- ],
555
- "outputs": [
556
- {
557
- "type": "core::bool"
558
- }
559
- ],
560
- "state_mutability": "external"
561
- },
562
- {
563
- "type": "function",
564
- "name": "transfer_from",
565
- "inputs": [
566
- {
567
- "name": "sender",
568
- "type": "core::starknet::contract_address::ContractAddress"
569
- },
570
- {
571
- "name": "recipient",
572
- "type": "core::starknet::contract_address::ContractAddress"
573
- },
574
- {
575
- "name": "amount",
576
- "type": "core::integer::u256"
577
- }
578
- ],
579
- "outputs": [
580
- {
581
- "type": "core::bool"
582
- }
583
- ],
584
- "state_mutability": "external"
585
- },
586
- {
587
- "type": "function",
588
- "name": "approve",
589
- "inputs": [
590
- {
591
- "name": "spender",
592
- "type": "core::starknet::contract_address::ContractAddress"
593
- },
594
- {
595
- "name": "amount",
596
- "type": "core::integer::u256"
597
- }
598
- ],
599
- "outputs": [
600
- {
601
- "type": "core::bool"
602
- }
603
- ],
604
- "state_mutability": "external"
605
- },
606
- {
607
- "type": "function",
608
- "name": "name",
609
- "inputs": [],
610
- "outputs": [
611
- {
612
- "type": "core::byte_array::ByteArray"
613
- }
614
- ],
615
- "state_mutability": "view"
616
- },
617
- {
618
- "type": "function",
619
- "name": "symbol",
620
- "inputs": [],
621
- "outputs": [
622
- {
623
- "type": "core::byte_array::ByteArray"
624
- }
625
- ],
626
- "state_mutability": "view"
627
- },
628
- {
629
- "type": "function",
630
- "name": "decimals",
631
- "inputs": [],
632
- "outputs": [
633
- {
634
- "type": "core::integer::u8"
635
- }
636
- ],
637
- "state_mutability": "view"
638
- },
639
- {
640
- "type": "function",
641
- "name": "totalSupply",
642
- "inputs": [],
643
- "outputs": [
644
- {
645
- "type": "core::integer::u256"
646
- }
647
- ],
648
- "state_mutability": "view"
649
- },
650
- {
651
- "type": "function",
652
- "name": "balanceOf",
653
- "inputs": [
654
- {
655
- "name": "account",
656
- "type": "core::starknet::contract_address::ContractAddress"
657
- }
658
- ],
659
- "outputs": [
660
- {
661
- "type": "core::integer::u256"
662
- }
663
- ],
664
- "state_mutability": "view"
665
- },
666
- {
667
- "type": "function",
668
- "name": "transferFrom",
669
- "inputs": [
670
- {
671
- "name": "sender",
672
- "type": "core::starknet::contract_address::ContractAddress"
673
- },
674
- {
675
- "name": "recipient",
676
- "type": "core::starknet::contract_address::ContractAddress"
677
- },
678
- {
679
- "name": "amount",
680
- "type": "core::integer::u256"
681
- }
682
- ],
683
- "outputs": [
684
- {
685
- "type": "core::bool"
686
- }
687
- ],
688
- "state_mutability": "external"
689
- }
690
- ]
691
- },
692
- {
693
- "type": "constructor",
694
- "name": "constructor",
695
- "inputs": []
696
- },
697
- {
698
- "type": "event",
699
- "name": "openzeppelin_token::erc20::erc20::ERC20Component::Transfer",
700
- "kind": "struct",
701
- "members": [
702
- {
703
- "name": "from",
704
- "type": "core::starknet::contract_address::ContractAddress",
705
- "kind": "key"
706
- },
707
- {
708
- "name": "to",
709
- "type": "core::starknet::contract_address::ContractAddress",
710
- "kind": "key"
711
- },
712
- {
713
- "name": "value",
714
- "type": "core::integer::u256",
715
- "kind": "data"
716
- }
717
- ]
718
- },
719
- {
720
- "type": "event",
721
- "name": "openzeppelin_token::erc20::erc20::ERC20Component::Approval",
722
- "kind": "struct",
723
- "members": [
724
- {
725
- "name": "owner",
726
- "type": "core::starknet::contract_address::ContractAddress",
727
- "kind": "key"
728
- },
729
- {
730
- "name": "spender",
731
- "type": "core::starknet::contract_address::ContractAddress",
732
- "kind": "key"
733
- },
734
- {
735
- "name": "value",
736
- "type": "core::integer::u256",
737
- "kind": "data"
738
- }
739
- ]
740
- },
741
- {
742
- "type": "event",
743
- "name": "openzeppelin_token::erc20::erc20::ERC20Component::Event",
744
- "kind": "enum",
745
- "variants": [
746
- {
747
- "name": "Transfer",
748
- "type": "openzeppelin_token::erc20::erc20::ERC20Component::Transfer",
749
- "kind": "nested"
750
- },
751
- {
752
- "name": "Approval",
753
- "type": "openzeppelin_token::erc20::erc20::ERC20Component::Approval",
754
- "kind": "nested"
755
- }
756
- ]
757
- },
758
- {
759
- "type": "event",
760
- "name": "contracts::erc20::DummyERC20::Event",
761
- "kind": "enum",
762
- "variants": [
763
- {
764
- "name": "ERC20Event",
765
- "type": "openzeppelin_token::erc20::erc20::ERC20Component::Event",
766
- "kind": "flat"
767
- }
768
- ]
769
- }
487
+ {
488
+ type: 'impl',
489
+ name: 'ERC20MixinImpl',
490
+ interface_name: 'openzeppelin_token::erc20::interface::IERC20Mixin',
491
+ },
492
+ {
493
+ type: 'struct',
494
+ name: 'core::integer::u256',
495
+ members: [
496
+ {
497
+ name: 'low',
498
+ type: 'core::integer::u128',
499
+ },
500
+ {
501
+ name: 'high',
502
+ type: 'core::integer::u128',
503
+ },
504
+ ],
505
+ },
506
+ {
507
+ type: 'enum',
508
+ name: 'core::bool',
509
+ variants: [
510
+ {
511
+ name: 'False',
512
+ type: '()',
513
+ },
514
+ {
515
+ name: 'True',
516
+ type: '()',
517
+ },
518
+ ],
519
+ },
520
+ {
521
+ type: 'struct',
522
+ name: 'core::byte_array::ByteArray',
523
+ members: [
524
+ {
525
+ name: 'data',
526
+ type: 'core::array::Array::<core::bytes_31::bytes31>',
527
+ },
528
+ {
529
+ name: 'pending_word',
530
+ type: 'core::felt252',
531
+ },
532
+ {
533
+ name: 'pending_word_len',
534
+ type: 'core::integer::u32',
535
+ },
536
+ ],
537
+ },
538
+ {
539
+ type: 'interface',
540
+ name: 'openzeppelin_token::erc20::interface::IERC20Mixin',
541
+ items: [
542
+ {
543
+ type: 'function',
544
+ name: 'total_supply',
545
+ inputs: [],
546
+ outputs: [
547
+ {
548
+ type: 'core::integer::u256',
549
+ },
550
+ ],
551
+ state_mutability: 'view',
552
+ },
553
+ {
554
+ type: 'function',
555
+ name: 'balance_of',
556
+ inputs: [
557
+ {
558
+ name: 'account',
559
+ type: 'core::starknet::contract_address::ContractAddress',
560
+ },
561
+ ],
562
+ outputs: [
563
+ {
564
+ type: 'core::integer::u256',
565
+ },
566
+ ],
567
+ state_mutability: 'view',
568
+ },
569
+ {
570
+ type: 'function',
571
+ name: 'allowance',
572
+ inputs: [
573
+ {
574
+ name: 'owner',
575
+ type: 'core::starknet::contract_address::ContractAddress',
576
+ },
577
+ {
578
+ name: 'spender',
579
+ type: 'core::starknet::contract_address::ContractAddress',
580
+ },
581
+ ],
582
+ outputs: [
583
+ {
584
+ type: 'core::integer::u256',
585
+ },
586
+ ],
587
+ state_mutability: 'view',
588
+ },
589
+ {
590
+ type: 'function',
591
+ name: 'transfer',
592
+ inputs: [
593
+ {
594
+ name: 'recipient',
595
+ type: 'core::starknet::contract_address::ContractAddress',
596
+ },
597
+ {
598
+ name: 'amount',
599
+ type: 'core::integer::u256',
600
+ },
601
+ ],
602
+ outputs: [
603
+ {
604
+ type: 'core::bool',
605
+ },
606
+ ],
607
+ state_mutability: 'external',
608
+ },
609
+ {
610
+ type: 'function',
611
+ name: 'transfer_from',
612
+ inputs: [
613
+ {
614
+ name: 'sender',
615
+ type: 'core::starknet::contract_address::ContractAddress',
616
+ },
617
+ {
618
+ name: 'recipient',
619
+ type: 'core::starknet::contract_address::ContractAddress',
620
+ },
621
+ {
622
+ name: 'amount',
623
+ type: 'core::integer::u256',
624
+ },
625
+ ],
626
+ outputs: [
627
+ {
628
+ type: 'core::bool',
629
+ },
630
+ ],
631
+ state_mutability: 'external',
632
+ },
633
+ {
634
+ type: 'function',
635
+ name: 'approve',
636
+ inputs: [
637
+ {
638
+ name: 'spender',
639
+ type: 'core::starknet::contract_address::ContractAddress',
640
+ },
641
+ {
642
+ name: 'amount',
643
+ type: 'core::integer::u256',
644
+ },
645
+ ],
646
+ outputs: [
647
+ {
648
+ type: 'core::bool',
649
+ },
650
+ ],
651
+ state_mutability: 'external',
652
+ },
653
+ {
654
+ type: 'function',
655
+ name: 'name',
656
+ inputs: [],
657
+ outputs: [
658
+ {
659
+ type: 'core::byte_array::ByteArray',
660
+ },
661
+ ],
662
+ state_mutability: 'view',
663
+ },
664
+ {
665
+ type: 'function',
666
+ name: 'symbol',
667
+ inputs: [],
668
+ outputs: [
669
+ {
670
+ type: 'core::byte_array::ByteArray',
671
+ },
672
+ ],
673
+ state_mutability: 'view',
674
+ },
675
+ {
676
+ type: 'function',
677
+ name: 'decimals',
678
+ inputs: [],
679
+ outputs: [
680
+ {
681
+ type: 'core::integer::u8',
682
+ },
683
+ ],
684
+ state_mutability: 'view',
685
+ },
686
+ {
687
+ type: 'function',
688
+ name: 'totalSupply',
689
+ inputs: [],
690
+ outputs: [
691
+ {
692
+ type: 'core::integer::u256',
693
+ },
694
+ ],
695
+ state_mutability: 'view',
696
+ },
697
+ {
698
+ type: 'function',
699
+ name: 'balanceOf',
700
+ inputs: [
701
+ {
702
+ name: 'account',
703
+ type: 'core::starknet::contract_address::ContractAddress',
704
+ },
705
+ ],
706
+ outputs: [
707
+ {
708
+ type: 'core::integer::u256',
709
+ },
710
+ ],
711
+ state_mutability: 'view',
712
+ },
713
+ {
714
+ type: 'function',
715
+ name: 'transferFrom',
716
+ inputs: [
717
+ {
718
+ name: 'sender',
719
+ type: 'core::starknet::contract_address::ContractAddress',
720
+ },
721
+ {
722
+ name: 'recipient',
723
+ type: 'core::starknet::contract_address::ContractAddress',
724
+ },
725
+ {
726
+ name: 'amount',
727
+ type: 'core::integer::u256',
728
+ },
729
+ ],
730
+ outputs: [
731
+ {
732
+ type: 'core::bool',
733
+ },
734
+ ],
735
+ state_mutability: 'external',
736
+ },
737
+ ],
738
+ },
739
+ {
740
+ type: 'constructor',
741
+ name: 'constructor',
742
+ inputs: [],
743
+ },
744
+ {
745
+ type: 'event',
746
+ name: 'openzeppelin_token::erc20::erc20::ERC20Component::Transfer',
747
+ kind: 'struct',
748
+ members: [
749
+ {
750
+ name: 'from',
751
+ type: 'core::starknet::contract_address::ContractAddress',
752
+ kind: 'key',
753
+ },
754
+ {
755
+ name: 'to',
756
+ type: 'core::starknet::contract_address::ContractAddress',
757
+ kind: 'key',
758
+ },
759
+ {
760
+ name: 'value',
761
+ type: 'core::integer::u256',
762
+ kind: 'data',
763
+ },
764
+ ],
765
+ },
766
+ {
767
+ type: 'event',
768
+ name: 'openzeppelin_token::erc20::erc20::ERC20Component::Approval',
769
+ kind: 'struct',
770
+ members: [
771
+ {
772
+ name: 'owner',
773
+ type: 'core::starknet::contract_address::ContractAddress',
774
+ kind: 'key',
775
+ },
776
+ {
777
+ name: 'spender',
778
+ type: 'core::starknet::contract_address::ContractAddress',
779
+ kind: 'key',
780
+ },
781
+ {
782
+ name: 'value',
783
+ type: 'core::integer::u256',
784
+ kind: 'data',
785
+ },
786
+ ],
787
+ },
788
+ {
789
+ type: 'event',
790
+ name: 'openzeppelin_token::erc20::erc20::ERC20Component::Event',
791
+ kind: 'enum',
792
+ variants: [
793
+ {
794
+ name: 'Transfer',
795
+ type: 'openzeppelin_token::erc20::erc20::ERC20Component::Transfer',
796
+ kind: 'nested',
797
+ },
798
+ {
799
+ name: 'Approval',
800
+ type: 'openzeppelin_token::erc20::erc20::ERC20Component::Approval',
801
+ kind: 'nested',
802
+ },
803
+ ],
804
+ },
805
+ {
806
+ type: 'event',
807
+ name: 'contracts::erc20::DummyERC20::Event',
808
+ kind: 'enum',
809
+ variants: [
810
+ {
811
+ name: 'ERC20Event',
812
+ type: 'openzeppelin_token::erc20::erc20::ERC20Component::Event',
813
+ kind: 'flat',
814
+ },
815
+ ],
816
+ },
770
817
  ] as const satisfies Abi;
771
818
 
772
- export type ChamberTypedContract = TypedContractV2<typeof CHAMBER_ABI>;
819
+ export type ChamberTypedContract = TypedContractV2<typeof CHAMBER_ABI>;