viem 2.57.1 → 2.57.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (80) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/_cjs/chains/definitions/crymad.js +32 -0
  3. package/_cjs/chains/definitions/crymad.js.map +1 -0
  4. package/_cjs/chains/definitions/crymadL2.js +33 -0
  5. package/_cjs/chains/definitions/crymadL2.js.map +1 -0
  6. package/_cjs/chains/index.js +17 -13
  7. package/_cjs/chains/index.js.map +1 -1
  8. package/_cjs/errors/version.js +1 -1
  9. package/_cjs/tempo/Abis.js +177 -36
  10. package/_cjs/tempo/Abis.js.map +1 -1
  11. package/_cjs/tempo/ExecutionError.js +2 -0
  12. package/_cjs/tempo/ExecutionError.js.map +1 -1
  13. package/_cjs/tempo/Selectors.js +17 -6
  14. package/_cjs/tempo/Selectors.js.map +1 -1
  15. package/_cjs/tempo/Transaction.js.map +1 -1
  16. package/_cjs/tempo/actions/token.js +12 -5
  17. package/_cjs/tempo/actions/token.js.map +1 -1
  18. package/_cjs/tempo/chainConfig.js +1 -1
  19. package/_cjs/tempo/chainConfig.js.map +1 -1
  20. package/_cjs/tokens/definitions/ousd.js +1 -0
  21. package/_cjs/tokens/definitions/ousd.js.map +1 -1
  22. package/_cjs/tokens/sets.js +1 -1
  23. package/_cjs/tokens/sets.js.map +1 -1
  24. package/_esm/chains/definitions/crymad.js +29 -0
  25. package/_esm/chains/definitions/crymad.js.map +1 -0
  26. package/_esm/chains/definitions/crymadL2.js +30 -0
  27. package/_esm/chains/definitions/crymadL2.js.map +1 -0
  28. package/_esm/chains/index.js +2 -0
  29. package/_esm/chains/index.js.map +1 -1
  30. package/_esm/errors/version.js +1 -1
  31. package/_esm/tempo/Abis.js +178 -37
  32. package/_esm/tempo/Abis.js.map +1 -1
  33. package/_esm/tempo/ExecutionError.js +2 -0
  34. package/_esm/tempo/ExecutionError.js.map +1 -1
  35. package/_esm/tempo/Selectors.js +16 -5
  36. package/_esm/tempo/Selectors.js.map +1 -1
  37. package/_esm/tempo/Transaction.js.map +1 -1
  38. package/_esm/tempo/actions/token.js +13 -6
  39. package/_esm/tempo/actions/token.js.map +1 -1
  40. package/_esm/tempo/chainConfig.js +1 -1
  41. package/_esm/tempo/chainConfig.js.map +1 -1
  42. package/_esm/tokens/definitions/ousd.js +1 -0
  43. package/_esm/tokens/definitions/ousd.js.map +1 -1
  44. package/_esm/tokens/sets.js +1 -1
  45. package/_esm/tokens/sets.js.map +1 -1
  46. package/_types/chains/definitions/crymad.d.ts +49 -0
  47. package/_types/chains/definitions/crymad.d.ts.map +1 -0
  48. package/_types/chains/definitions/crymadL2.d.ts +49 -0
  49. package/_types/chains/definitions/crymadL2.d.ts.map +1 -0
  50. package/_types/chains/index.d.ts +2 -0
  51. package/_types/chains/index.d.ts.map +1 -1
  52. package/_types/errors/version.d.ts +1 -1
  53. package/_types/tempo/Abis.d.ts +778 -174
  54. package/_types/tempo/Abis.d.ts.map +1 -1
  55. package/_types/tempo/ExecutionError.d.ts.map +1 -1
  56. package/_types/tempo/Selectors.d.ts +16 -5
  57. package/_types/tempo/Selectors.d.ts.map +1 -1
  58. package/_types/tempo/Transaction.d.ts +1 -0
  59. package/_types/tempo/Transaction.d.ts.map +1 -1
  60. package/_types/tempo/actions/reward.d.ts +72 -0
  61. package/_types/tempo/actions/reward.d.ts.map +1 -1
  62. package/_types/tempo/actions/token.d.ts +576 -5
  63. package/_types/tempo/actions/token.d.ts.map +1 -1
  64. package/_types/tokens/definitions/ousd.d.ts +1 -0
  65. package/_types/tokens/definitions/ousd.d.ts.map +1 -1
  66. package/_types/tokens/sets.d.ts +13 -0
  67. package/_types/tokens/sets.d.ts.map +1 -1
  68. package/chains/definitions/crymad.ts +29 -0
  69. package/chains/definitions/crymadL2.ts +30 -0
  70. package/chains/index.ts +2 -0
  71. package/errors/version.ts +1 -1
  72. package/package.json +1 -1
  73. package/tempo/Abis.ts +179 -37
  74. package/tempo/ExecutionError.ts +3 -0
  75. package/tempo/Selectors.ts +25 -11
  76. package/tempo/Transaction.ts +1 -0
  77. package/tempo/actions/token.ts +29 -9
  78. package/tempo/chainConfig.ts +1 -1
  79. package/tokens/definitions/ousd.ts +1 -0
  80. package/tokens/sets.ts +1 -1
package/tempo/Abis.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  // Generated with `pnpm gen:tempo-abis`. Do not modify manually.
2
- // Source: tempoxyz/tempo@a2624758a6709731d98b9bd6fc8e5afca398fea9
2
+ // Source: tempoxyz/tempo@6ef1f812c9ddcbe90a88ada73944012520942d26
3
3
 
4
4
  export const accountKeychain = [
5
5
  {
@@ -1942,6 +1942,16 @@ export const tip20 = [
1942
1942
  ],
1943
1943
  outputs: [],
1944
1944
  },
1945
+ {
1946
+ name: 'burnAt',
1947
+ type: 'function',
1948
+ stateMutability: 'nonpayable',
1949
+ inputs: [
1950
+ { type: 'address', name: 'from' },
1951
+ { type: 'uint256', name: 'amount' },
1952
+ ],
1953
+ outputs: [],
1954
+ },
1945
1955
  {
1946
1956
  name: 'mintWithMemo',
1947
1957
  type: 'function',
@@ -2056,6 +2066,13 @@ export const tip20 = [
2056
2066
  inputs: [],
2057
2067
  outputs: [{ type: 'bytes32' }],
2058
2068
  },
2069
+ {
2070
+ name: 'BURN_AT_ROLE',
2071
+ type: 'function',
2072
+ stateMutability: 'view',
2073
+ inputs: [],
2074
+ outputs: [{ type: 'bytes32' }],
2075
+ },
2059
2076
  {
2060
2077
  name: 'permit',
2061
2078
  type: 'function',
@@ -2185,6 +2202,15 @@ export const tip20 = [
2185
2202
  { type: 'uint256', name: 'amount' },
2186
2203
  ],
2187
2204
  },
2205
+ {
2206
+ name: 'BurnAt',
2207
+ type: 'event',
2208
+ inputs: [
2209
+ { type: 'address', name: 'burner', indexed: true },
2210
+ { type: 'address', name: 'from', indexed: true },
2211
+ { type: 'uint256', name: 'amount', indexed: true },
2212
+ ],
2213
+ },
2188
2214
  {
2189
2215
  name: 'TransferWithMemo',
2190
2216
  type: 'event',
@@ -3695,6 +3721,20 @@ export const zonePortal = [
3695
3721
  inputs: [],
3696
3722
  outputs: [{ type: 'uint64' }],
3697
3723
  },
3724
+ {
3725
+ name: 'MAX_UNPROCESSED_DEPOSITS',
3726
+ type: 'function',
3727
+ stateMutability: 'view',
3728
+ inputs: [],
3729
+ outputs: [{ type: 'uint64' }],
3730
+ },
3731
+ {
3732
+ name: 'MAX_UNPROCESSED_TOKEN_ENABLEMENTS',
3733
+ type: 'function',
3734
+ stateMutability: 'view',
3735
+ inputs: [],
3736
+ outputs: [{ type: 'uint64' }],
3737
+ },
3698
3738
  {
3699
3739
  name: 'MAX_WITHDRAWAL_GAS_LIMIT',
3700
3740
  type: 'function',
@@ -3801,6 +3841,47 @@ export const zonePortal = [
3801
3841
  ],
3802
3842
  outputs: [],
3803
3843
  },
3844
+ {
3845
+ name: 'submitBatch',
3846
+ type: 'function',
3847
+ stateMutability: 'nonpayable',
3848
+ inputs: [
3849
+ { type: 'uint64', name: 'tempoBlockNumber' },
3850
+ { type: 'uint64', name: 'recentTempoBlockNumber' },
3851
+ {
3852
+ type: 'tuple',
3853
+ name: 'blockTransition',
3854
+ components: [
3855
+ { type: 'bytes32', name: 'prevBlockHash' },
3856
+ { type: 'bytes32', name: 'nextBlockHash' },
3857
+ ],
3858
+ },
3859
+ {
3860
+ type: 'tuple',
3861
+ name: 'depositQueueTransition',
3862
+ components: [
3863
+ { type: 'bytes32', name: 'prevProcessedHash' },
3864
+ { type: 'bytes32', name: 'nextProcessedHash' },
3865
+ { type: 'uint64', name: 'prevDepositNumber' },
3866
+ { type: 'uint64', name: 'nextDepositNumber' },
3867
+ ],
3868
+ },
3869
+ {
3870
+ type: 'tuple',
3871
+ name: 'tokenEnablementTransition',
3872
+ components: [
3873
+ { type: 'uint64', name: 'prevProcessedTokenCount' },
3874
+ { type: 'uint64', name: 'nextProcessedTokenCount' },
3875
+ ],
3876
+ },
3877
+ { type: 'bytes32', name: 'withdrawalQueueHash' },
3878
+ { type: 'bytes', name: 'verifierConfig' },
3879
+ { type: 'bytes', name: 'proof' },
3880
+ { type: 'uint256', name: 'nextZoneHeight' },
3881
+ { type: 'bytes[]', name: 'signatures' },
3882
+ ],
3883
+ outputs: [],
3884
+ },
3804
3885
  {
3805
3886
  name: 'enableToken',
3806
3887
  type: 'function',
@@ -3944,6 +4025,20 @@ export const zonePortal = [
3944
4025
  inputs: [],
3945
4026
  outputs: [{ type: 'uint256' }],
3946
4027
  },
4028
+ {
4029
+ name: 'lastProcessedEnabledTokenCount',
4030
+ type: 'function',
4031
+ stateMutability: 'view',
4032
+ inputs: [],
4033
+ outputs: [{ type: 'uint64' }],
4034
+ },
4035
+ {
4036
+ name: 'tokenEnablementCursorInitialized',
4037
+ type: 'function',
4038
+ stateMutability: 'view',
4039
+ inputs: [],
4040
+ outputs: [{ type: 'bool' }],
4041
+ },
3947
4042
  {
3948
4043
  name: 'enabledTokenAt',
3949
4044
  type: 'function',
@@ -4134,6 +4229,19 @@ export const zonePortal = [
4134
4229
  { type: 'uint64', name: 'lastProcessedDepositNumber' },
4135
4230
  ],
4136
4231
  },
4232
+ {
4233
+ name: 'BatchSubmitted',
4234
+ type: 'event',
4235
+ inputs: [
4236
+ { type: 'uint64', name: 'withdrawalBatchIndex', indexed: true },
4237
+ { type: 'uint256', name: 'withdrawalQueueIndex', indexed: true },
4238
+ { type: 'bytes32', name: 'nextProcessedDepositQueueHash' },
4239
+ { type: 'bytes32', name: 'nextBlockHash' },
4240
+ { type: 'bytes32', name: 'withdrawalQueueHash' },
4241
+ { type: 'uint64', name: 'lastProcessedDepositNumber' },
4242
+ { type: 'uint64', name: 'lastProcessedEnabledTokenCount' },
4243
+ ],
4244
+ },
4137
4245
  {
4138
4246
  name: 'WithdrawalProcessed',
4139
4247
  type: 'event',
@@ -4281,7 +4389,9 @@ export const zonePortal = [
4281
4389
  { name: 'DepositsNotActive', type: 'error', inputs: [] },
4282
4390
  { name: 'TokenAlreadyEnabled', type: 'error', inputs: [] },
4283
4391
  { name: 'TokenTransferPolicyNotSet', type: 'error', inputs: [] },
4392
+ { name: 'TokenEnablementCursorNotInitialized', type: 'error', inputs: [] },
4284
4393
  { name: 'InvalidDepositTransition', type: 'error', inputs: [] },
4394
+ { name: 'InvalidTokenEnablementTransition', type: 'error', inputs: [] },
4285
4395
  { name: 'InvalidSequencerSet', type: 'error', inputs: [] },
4286
4396
  { name: 'SequencerConfigurationUnchanged', type: 'error', inputs: [] },
4287
4397
  { name: 'InvalidQuorumCertificate', type: 'error', inputs: [] },
@@ -4369,40 +4479,6 @@ export const zoneVerifier = [
4369
4479
  ],
4370
4480
  outputs: [{ type: 'bool' }],
4371
4481
  },
4372
- {
4373
- name: 'verify',
4374
- type: 'function',
4375
- stateMutability: 'view',
4376
- inputs: [
4377
- { type: 'uint32', name: 'zoneId' },
4378
- { type: 'uint64', name: 'tempoBlockNumber' },
4379
- { type: 'uint64', name: 'anchorBlockNumber' },
4380
- { type: 'bytes32', name: 'anchorBlockHash' },
4381
- { type: 'uint64', name: 'expectedWithdrawalBatchIndex' },
4382
- {
4383
- type: 'tuple',
4384
- name: 'blockTransition',
4385
- components: [
4386
- { type: 'bytes32', name: 'prevBlockHash' },
4387
- { type: 'bytes32', name: 'nextBlockHash' },
4388
- ],
4389
- },
4390
- {
4391
- type: 'tuple',
4392
- name: 'depositQueueTransition',
4393
- components: [
4394
- { type: 'bytes32', name: 'prevProcessedHash' },
4395
- { type: 'bytes32', name: 'nextProcessedHash' },
4396
- { type: 'uint64', name: 'prevDepositNumber' },
4397
- { type: 'uint64', name: 'nextDepositNumber' },
4398
- ],
4399
- },
4400
- { type: 'bytes32', name: 'withdrawalQueueHash' },
4401
- { type: 'bytes', name: 'verifierConfig' },
4402
- { type: 'bytes', name: 'proof' },
4403
- ],
4404
- outputs: [{ type: 'bool' }],
4405
- },
4406
4482
  ] as const
4407
4483
 
4408
4484
  // Source: tempoxyz/earn@d6373e4939ec2bbf5dcccffd5f2519ff4a62d6b1
@@ -8321,7 +8397,69 @@ export const earnRouterCallbackData = [
8321
8397
  },
8322
8398
  ] as const
8323
8399
 
8324
- // Source: tempoxyz/zones@421d77a9e5a12cd3fbb2ed10da1010f31b75f012
8400
+ // Source: tempoxyz/zones@22318d90a098149fecd0c56ae4e20e55fea24bdd
8401
+
8402
+ export const zonePortalPreT13Retired = [
8403
+ {
8404
+ name: 'MAX_DEPOSITS_PER_TEMPO_BLOCK',
8405
+ type: 'function',
8406
+ stateMutability: 'view',
8407
+ inputs: [],
8408
+ outputs: [{ type: 'uint64' }],
8409
+ },
8410
+ {
8411
+ name: 'MAX_TOKENS_ENABLED_PER_TEMPO_BLOCK',
8412
+ type: 'function',
8413
+ stateMutability: 'view',
8414
+ inputs: [],
8415
+ outputs: [{ type: 'uint64' }],
8416
+ },
8417
+ {
8418
+ name: 'submitBatch',
8419
+ type: 'function',
8420
+ stateMutability: 'nonpayable',
8421
+ inputs: [
8422
+ { type: 'uint64', name: 'tempoBlockNumber' },
8423
+ { type: 'uint64', name: 'recentTempoBlockNumber' },
8424
+ {
8425
+ type: 'tuple',
8426
+ name: 'blockTransition',
8427
+ components: [
8428
+ { type: 'bytes32', name: 'prevBlockHash' },
8429
+ { type: 'bytes32', name: 'nextBlockHash' },
8430
+ ],
8431
+ },
8432
+ {
8433
+ type: 'tuple',
8434
+ name: 'depositQueueTransition',
8435
+ components: [
8436
+ { type: 'bytes32', name: 'prevProcessedHash' },
8437
+ { type: 'bytes32', name: 'nextProcessedHash' },
8438
+ { type: 'uint64', name: 'prevDepositNumber' },
8439
+ { type: 'uint64', name: 'nextDepositNumber' },
8440
+ ],
8441
+ },
8442
+ { type: 'bytes32', name: 'withdrawalQueueHash' },
8443
+ { type: 'bytes', name: 'verifierConfig' },
8444
+ { type: 'bytes', name: 'proof' },
8445
+ { type: 'uint256', name: 'nextZoneHeight' },
8446
+ { type: 'bytes[]', name: 'signatures' },
8447
+ ],
8448
+ outputs: [],
8449
+ },
8450
+ {
8451
+ name: 'BatchSubmitted',
8452
+ type: 'event',
8453
+ inputs: [
8454
+ { type: 'uint64', name: 'withdrawalBatchIndex', indexed: true },
8455
+ { type: 'uint256', name: 'withdrawalQueueIndex', indexed: true },
8456
+ { type: 'bytes32', name: 'nextProcessedDepositQueueHash' },
8457
+ { type: 'bytes32', name: 'nextBlockHash' },
8458
+ { type: 'bytes32', name: 'withdrawalQueueHash' },
8459
+ { type: 'uint64', name: 'lastProcessedDepositNumber' },
8460
+ ],
8461
+ },
8462
+ ] as const
8325
8463
 
8326
8464
  export const zoneOutbox = [
8327
8465
  {
@@ -9543,7 +9681,11 @@ export const earn = [
9543
9681
  ...vedaEngine,
9544
9682
  ] as const
9545
9683
 
9546
- export const zone = [...zoneMessenger, ...zoneOutbox] as const
9684
+ export const zone = [
9685
+ ...zoneMessenger,
9686
+ ...zoneOutbox,
9687
+ ...zonePortalPreT13Retired,
9688
+ ] as const
9547
9689
 
9548
9690
  export const propAmm = [...directPropAmm] as const
9549
9691
 
@@ -141,6 +141,7 @@ export const messages: Record<`${AbiErrorName}(${string})`, string> = {
141
141
  'InvalidThreshold()': 'Invalid threshold.',
142
142
  'InvalidTick()': 'The price tick is invalid.',
143
143
  'InvalidToken()': 'This token is not supported on the exchange.',
144
+ 'InvalidTokenEnablementTransition()': 'Invalid token enablement transition.',
144
145
  'InvalidTransferPolicyId()': 'Invalid transfer policy.',
145
146
  'InvalidValidatorAddress()': 'Invalid validator address.',
146
147
  'InvalidWeight()': 'Invalid weight.',
@@ -208,6 +209,8 @@ export const messages: Record<`${AbiErrorName}(${string})`, string> = {
208
209
  'TokenAlreadyExists(address)': 'Token {0} already exists.',
209
210
  'TokenEnablementBlockCapacityExceeded(uint64)':
210
211
  'The token enablement capacity per block exceeds the maximum ({0}).',
212
+ 'TokenEnablementCursorNotInitialized()':
213
+ 'The token enablement cursor is not initialized.',
211
214
  'TokenMetadataTooLong()': 'Token metadata is too long.',
212
215
  'TokenNotEnabled()': 'The token is not enabled.',
213
216
  'TokenTransferPolicyNotSet()': 'The token transfer policy is not set.',
@@ -174,6 +174,7 @@ export const tip20Factory = {
174
174
  OverloadedFunctionSelectors<'createToken'>
175
175
 
176
176
  export const tip20 = {
177
+ BURN_AT_ROLE: '0xc6990381',
177
178
  BURN_BLOCKED_ROLE: '0x32ad9be8',
178
179
  DOMAIN_SEPARATOR: '0x3644e515',
179
180
  ISSUER_ROLE: '0x82aefa24',
@@ -183,6 +184,7 @@ export const tip20 = {
183
184
  approve: '0x095ea7b3',
184
185
  balanceOf: '0x70a08231',
185
186
  burn: '0x42966c68',
187
+ burnAt: '0x9803f216',
186
188
  burnBlocked: '0xec0cf3dc',
187
189
  burnWithMemo: '0x38f23b0b',
188
190
  changeTransferPolicyId: '0xfd5e9420',
@@ -302,14 +304,8 @@ export const zoneFactory = {
302
304
  OverloadedFunctionSelectors<'createZone'>
303
305
 
304
306
  export const zoneVerifier = {
305
- verify: {
306
- 'verify(uint32,uint64,uint64,bytes32,uint64,(bytes32,bytes32),(bytes32,bytes32,uint64,uint64),bytes32,bytes,bytes)':
307
- '0x7106a43e',
308
- 'verify(uint32,uint64,uint64,bytes32,uint64,uint256,(bytes32,bytes32),(bytes32,bytes32,uint64,uint64),(uint64,uint64),bytes32,bytes,bytes)':
309
- '0xebb2ddc9',
310
- },
311
- } as const satisfies FunctionSelectors<typeof Abis.zoneVerifier, 'verify'> &
312
- OverloadedFunctionSelectors<'verify'>
307
+ verify: '0xebb2ddc9',
308
+ } as const satisfies FunctionSelectors<typeof Abis.zoneVerifier>
313
309
 
314
310
  export const zonePortal = {
315
311
  FIXED_DEPOSIT_GAS: '0xf706cfbf',
@@ -317,6 +313,8 @@ export const zonePortal = {
317
313
  MAX_GAS_FEE_RATE: '0xf490ca96',
318
314
  MAX_TOKENS_ENABLED_PER_TEMPO_BLOCK: '0x3fcf7df4',
319
315
  MAX_TOKEN_METADATA_BYTES: '0x996329a2',
316
+ MAX_UNPROCESSED_DEPOSITS: '0x5e53dcd3',
317
+ MAX_UNPROCESSED_TOKEN_ENABLEMENTS: '0x3b667e74',
320
318
  MAX_WITHDRAWAL_GAS_LIMIT: '0x86f47e55',
321
319
  abdicate: '0xbf4c5411',
322
320
  abdicationEffectiveAt: '0x04a3b098',
@@ -351,6 +349,7 @@ export const zonePortal = {
351
349
  isSequencer: '0x6d46e987',
352
350
  isTokenEnabled: '0x748538d9',
353
351
  lastProcessedDepositNumber: '0xe84abe69',
352
+ lastProcessedEnabledTokenCount: '0xccd537ca',
354
353
  lastSyncedTempoBlockNumber: '0xbe2a63ee',
355
354
  leader: '0x40eedabb',
356
355
  leaderActivationTempoBlock: '0xb83c755f',
@@ -384,8 +383,14 @@ export const zonePortal = {
384
383
  setSequencerEncryptionKey: '0xef10b187',
385
384
  setSequencerSet: '0x86012b45',
386
385
  setZoneGasRate: '0x0e86bbdc',
387
- submitBatch: '0x78fb159b',
386
+ submitBatch: {
387
+ 'submitBatch(uint64,uint64,(bytes32,bytes32),(bytes32,bytes32,uint64,uint64),(uint64,uint64),bytes32,bytes,bytes,uint256,bytes[])':
388
+ '0x4cd6c7c7',
389
+ 'submitBatch(uint64,uint64,(bytes32,bytes32),(bytes32,bytes32,uint64,uint64),bytes32,bytes,bytes,uint256,bytes[])':
390
+ '0x78fb159b',
391
+ },
388
392
  tokenConfig: '0xfe136c4e',
393
+ tokenEnablementCursorInitialized: '0x370ddf99',
389
394
  tokenEnablementHash: '0xb456c0dd',
390
395
  transferAdmin: '0x75829def',
391
396
  verifier: '0x2b7ac3f3',
@@ -396,8 +401,17 @@ export const zonePortal = {
396
401
  zoneGasRate: '0xecf79a4e',
397
402
  zoneHeight: '0x430f8b4f',
398
403
  zoneId: '0xd179978a',
399
- } as const satisfies FunctionSelectors<typeof Abis.zonePortal, 'deposit'> &
400
- OverloadedFunctionSelectors<'deposit'>
404
+ } as const satisfies FunctionSelectors<
405
+ typeof Abis.zonePortal,
406
+ 'deposit' | 'submitBatch'
407
+ > &
408
+ OverloadedFunctionSelectors<'deposit' | 'submitBatch'>
409
+
410
+ export const zonePortalPreT13Retired = {
411
+ MAX_DEPOSITS_PER_TEMPO_BLOCK: '0x1bf00ca8',
412
+ MAX_TOKENS_ENABLED_PER_TEMPO_BLOCK: '0x3fcf7df4',
413
+ submitBatch: '0x78fb159b',
414
+ } as const satisfies FunctionSelectors<typeof Abis.zonePortalPreT13Retired>
401
415
 
402
416
  export const zoneOutbox = {
403
417
  AUTHENTICATED_WITHDRAWAL_CIPHERTEXT_LENGTH: '0x43c3cb83',
@@ -136,6 +136,7 @@ export type TransactionRequestTempo<
136
136
  hash?: Hex.Hex | undefined
137
137
  keyAuthorization?: KeyAuthorization.Signed<quantity, index> | undefined
138
138
  multisigSimulation?: MultisigSimulation.Spec | undefined
139
+ /** Nonce lane, or `'expiring'` for time-bounded transactions. `nonce` can distinguish otherwise identical expiring transactions. */
139
140
  nonceKey?: 'expiring' | quantity | undefined
140
141
  owner?: RootAccount | undefined
141
142
  signatures?: readonly SignatureEnvelope.Serialized[] | undefined
@@ -546,9 +546,20 @@ export namespace burn {
546
546
  export type Args = {
547
547
  /** Amount of tokens to burn, in base units or formatted decimal form. */
548
548
  amount: internal_Token.AmountInput
549
- /** Memo to include in the transfer. */
550
- memo?: Hex.Hex | undefined
551
- } & TokenParameter
549
+ } & TokenParameter &
550
+ OneOf<
551
+ | {
552
+ /** Memo to include in the transfer. */
553
+ memo?: Hex.Hex | undefined
554
+ }
555
+ | {
556
+ /**
557
+ * Address to burn tokens from. Requires `BURN_AT_ROLE` (T12+).
558
+ * Omit to burn from the caller's balance.
559
+ */
560
+ from: Address
561
+ }
562
+ >
552
563
 
553
564
  export type Parameters<
554
565
  chain extends Chain | undefined = Chain | undefined,
@@ -570,8 +581,8 @@ export namespace burn {
570
581
  client: Client<Transport, chain, account>,
571
582
  parameters: burn.Parameters<chain, account>,
572
583
  ): Promise<ReturnType<action>> {
573
- const { amount, memo, token, ...rest } = parameters
574
- const call = burn.call(client, { amount, memo, token } as never)
584
+ const { amount, from, memo, token, ...rest } = parameters
585
+ const call = burn.call(client, { amount, from, memo, token } as never)
575
586
  return (await action(client, {
576
587
  ...rest,
577
588
  ...call,
@@ -579,7 +590,7 @@ export namespace burn {
579
590
  }
580
591
 
581
592
  /**
582
- * Defines a call to the `burn` or `burnWithMemo` function.
593
+ * Defines a call to the `burn`, `burnWithMemo`, or `burnAt` function.
583
594
  *
584
595
  * Can be passed as a parameter to:
585
596
  * - [`estimateContractGas`](https://viem.sh/docs/contract/estimateContractGas): estimate the gas cost of the call
@@ -616,9 +627,16 @@ export namespace burn {
616
627
  ...parameters: CallParameters<Args, Client<Transport, chain>>
617
628
  ) {
618
629
  const [client, args] = resolveCallParameters(parameters)
619
- const { amount, memo, token } = args
630
+ const { amount, from, memo, token } = args
620
631
  const { address, decimals } = resolveToken(client, { token })
621
632
  const value = internal_Token.toBaseUnits(amount, decimals)
633
+ if (from)
634
+ return defineCall({
635
+ address,
636
+ abi: Abis.tip20,
637
+ functionName: 'burnAt',
638
+ args: [from, value],
639
+ })
622
640
  const callArgs = memo
623
641
  ? ({
624
642
  functionName: 'burnWithMemo',
@@ -645,9 +663,9 @@ export namespace burn {
645
663
  const [log] = parseEventLogs({
646
664
  abi: Abis.tip20,
647
665
  logs,
648
- eventName: 'Burn',
666
+ eventName: ['Burn', 'BurnAt'],
649
667
  })
650
- if (!log) throw new Error('`Burn` event not found.')
668
+ if (!log) throw new Error('`Burn` or `BurnAt` event not found.')
651
669
  return log
652
670
  }
653
671
  }
@@ -716,6 +734,8 @@ export namespace burnSync {
716
734
  Required: true
717
735
  }
718
736
  > & {
737
+ /** `BURN_AT_ROLE` holder that performed the burn. Set when `from` is provided. */
738
+ burner?: Address | undefined
719
739
  receipt: TransactionReceipt
720
740
  }
721
741
  >
@@ -234,7 +234,7 @@ export const chainConfig = {
234
234
  request.nonce = 0
235
235
  } else if (useExpiringNonce) {
236
236
  request.nonceKey = maxUint256
237
- request.nonce = 0
237
+ request.nonce ??= 0
238
238
  if (typeof request.validAfter === 'undefined')
239
239
  request.validAfter = randomValidAfter()
240
240
  if (typeof request.validBefore === 'undefined')
@@ -21,5 +21,6 @@ export const ousd = /*#__PURE__*/ defineToken({
21
21
  currency: 'USD',
22
22
  decimals: 6,
23
23
  name: 'OpenUSD',
24
+ popular: true,
24
25
  symbol: 'OUSD',
25
26
  })
package/tokens/sets.ts CHANGED
@@ -73,7 +73,7 @@ const all = [
73
73
  ] as const satisfies Tokens
74
74
 
75
75
  /** Tokens flagged as popular. */
76
- const popular = [usdc] as const satisfies Tokens
76
+ const popular = [ousd, usdc] as const satisfies Tokens
77
77
 
78
78
  /** All tokens available on Tempo chains. */
79
79
  const tempo = [