@orbinum/sdk 0.2.0 → 0.3.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/dist/index.d.mts +1137 -70
- package/dist/index.d.ts +1137 -70
- package/dist/index.js +75 -0
- package/dist/index.mjs +72 -0
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -270,7 +270,7 @@ type FullIdentityInfo = {
|
|
|
270
270
|
* Signature verification scheme for cross-chain links.
|
|
271
271
|
* Mirrors `SignatureScheme` in pallet-account-mapping.
|
|
272
272
|
*/
|
|
273
|
-
type SignatureScheme = 'Eip191' | 'Ed25519';
|
|
273
|
+
type SignatureScheme$1 = 'Eip191' | 'Ed25519';
|
|
274
274
|
/** A verified public link to an external chain wallet. */
|
|
275
275
|
type ChainLink = {
|
|
276
276
|
chainId: number;
|
|
@@ -320,7 +320,7 @@ type AccountListing = {
|
|
|
320
320
|
/** A supported chain and its signature verification scheme. */
|
|
321
321
|
type SupportedChain = {
|
|
322
322
|
chainId: number;
|
|
323
|
-
scheme: SignatureScheme;
|
|
323
|
+
scheme: SignatureScheme$1;
|
|
324
324
|
};
|
|
325
325
|
/**
|
|
326
326
|
* Bitmask to convert a SLIP-0044 coin type into an Orbinum ChainId.
|
|
@@ -1340,6 +1340,49 @@ declare const KNOWN_PRECOMPILES: Record<string, KnownPrecompileInfo>;
|
|
|
1340
1340
|
*/
|
|
1341
1341
|
declare function getPrecompileLabel(address: string | null | undefined): string | null;
|
|
1342
1342
|
|
|
1343
|
+
/**
|
|
1344
|
+
* Options for {@link formatBalance}.
|
|
1345
|
+
*/
|
|
1346
|
+
interface FormatOptions {
|
|
1347
|
+
/** On-chain token decimals. Defaults to `18`. */
|
|
1348
|
+
decimals?: number;
|
|
1349
|
+
/** Token symbol appended to the output. Defaults to `'ORB'`. */
|
|
1350
|
+
symbol?: string;
|
|
1351
|
+
/** Whether to append the symbol. Defaults to `true`. */
|
|
1352
|
+
showSymbol?: boolean;
|
|
1353
|
+
/** Maximum number of decimal digits shown in output. Defaults to `6`. */
|
|
1354
|
+
precision?: number;
|
|
1355
|
+
}
|
|
1356
|
+
/**
|
|
1357
|
+
* Formats a raw on-chain token amount to a human-readable string.
|
|
1358
|
+
*
|
|
1359
|
+
* Handles the following input forms:
|
|
1360
|
+
* - `bigint` — raw planck/wei amount.
|
|
1361
|
+
* - `string` — decimal integer, hex (`0x`-prefixed), or already-formatted decimal.
|
|
1362
|
+
* - `number` — interpreted as a plain integer.
|
|
1363
|
+
* - `null` / `undefined` — treated as zero.
|
|
1364
|
+
*
|
|
1365
|
+
* Does NOT depend on `ethers`. Uses pure BigInt arithmetic.
|
|
1366
|
+
*
|
|
1367
|
+
* @example
|
|
1368
|
+
* formatBalance('1000000000000000000') // '1 ORB'
|
|
1369
|
+
* formatBalance(500000000000000000n, { precision: 2 }) // '0.50 ORB'
|
|
1370
|
+
* formatBalance('0x0de0b6b3a7640000', { showSymbol: false }) // '1'
|
|
1371
|
+
* formatBalance(null) // '0 ORB'
|
|
1372
|
+
*/
|
|
1373
|
+
declare function formatBalance(raw: string | bigint | number | null | undefined, options?: FormatOptions | number): string;
|
|
1374
|
+
/**
|
|
1375
|
+
* Convenience wrapper for formatting ORB amounts with 18 decimals.
|
|
1376
|
+
*
|
|
1377
|
+
* @param raw Raw planck amount (string, bigint, number, or null).
|
|
1378
|
+
* @param precision Max decimal digits shown. Defaults to `6`.
|
|
1379
|
+
*
|
|
1380
|
+
* @example
|
|
1381
|
+
* formatORB('1000000000000000000') // '1 ORB'
|
|
1382
|
+
* formatORB(500000000000000000n, 2) // '0.50 ORB'
|
|
1383
|
+
*/
|
|
1384
|
+
declare function formatORB(raw: string | bigint | number | null | undefined, precision?: number): string;
|
|
1385
|
+
|
|
1343
1386
|
/**
|
|
1344
1387
|
* Serialises a bigint as a 32-byte little-endian Uint8Array.
|
|
1345
1388
|
*/
|
|
@@ -1449,100 +1492,157 @@ declare function substrateSs58ToAccountIdHex(addr: string): string | null;
|
|
|
1449
1492
|
declare function addressToAccountIdHex(addr: string): string | null;
|
|
1450
1493
|
|
|
1451
1494
|
/**
|
|
1452
|
-
*
|
|
1453
|
-
*
|
|
1495
|
+
* TypeScript types for events emitted by pallet-shielded-pool.
|
|
1496
|
+
*
|
|
1497
|
+
* Conventions:
|
|
1498
|
+
* - Byte arrays (Commitment, Nullifier, Hash) → `string` (0x-prefixed hex, LE)
|
|
1499
|
+
* - Balances (BalanceOf<T>) → `bigint`
|
|
1500
|
+
* - AccountId → `string` (SS58 or 0x-prefixed)
|
|
1501
|
+
* - BoundedVec<T, N> → `T[]` (max N documented per field)
|
|
1502
|
+
* - u32 / leaf indices → `number`
|
|
1503
|
+
* - Option<T> → `T | null`
|
|
1454
1504
|
*/
|
|
1455
|
-
/** Arguments for the `shield` extrinsic. */
|
|
1456
|
-
type ShieldArgs = {
|
|
1457
|
-
assetId: number;
|
|
1458
|
-
amount: bigint;
|
|
1459
|
-
/** 32-byte Poseidon commitment (LE). */
|
|
1460
|
-
commitment: number[];
|
|
1461
|
-
/** 104-byte encrypted memo. */
|
|
1462
|
-
encryptedMemo: number[];
|
|
1463
|
-
};
|
|
1464
|
-
/** Arguments for the `unshield` extrinsic. */
|
|
1465
|
-
type UnshieldArgs = {
|
|
1466
|
-
/** Groth16 proof bytes. */
|
|
1467
|
-
proof: number[];
|
|
1468
|
-
/** 32-byte Merkle root (LE). */
|
|
1469
|
-
merkleRoot: number[];
|
|
1470
|
-
/** 32-byte Poseidon nullifier (LE). */
|
|
1471
|
-
nullifier: number[];
|
|
1472
|
-
assetId: number;
|
|
1473
|
-
amount: bigint;
|
|
1474
|
-
/** 32-byte recipient AccountId. */
|
|
1475
|
-
recipient: number[];
|
|
1476
|
-
};
|
|
1477
|
-
/** Single input note for a private transfer. */
|
|
1478
|
-
type PrivateTransferInput = {
|
|
1479
|
-
/** 32-byte Poseidon nullifier (LE). */
|
|
1480
|
-
nullifier: number[];
|
|
1481
|
-
/** 32-byte Poseidon commitment (LE). */
|
|
1482
|
-
commitment: number[];
|
|
1483
|
-
};
|
|
1484
|
-
/** Single output note for a private transfer. */
|
|
1485
|
-
type PrivateTransferOutput = {
|
|
1486
|
-
/** 32-byte Poseidon commitment (LE). */
|
|
1487
|
-
commitment: number[];
|
|
1488
|
-
/** 104-byte encrypted memo. */
|
|
1489
|
-
memo: number[];
|
|
1490
|
-
};
|
|
1491
|
-
/** Arguments for the `private_transfer` extrinsic. */
|
|
1492
|
-
type PrivateTransferArgs = {
|
|
1493
|
-
inputs: PrivateTransferInput[];
|
|
1494
|
-
outputs: PrivateTransferOutput[];
|
|
1495
|
-
/** Groth16 proof bytes. */
|
|
1496
|
-
proof: number[];
|
|
1497
|
-
/** 32-byte Merkle root (LE). */
|
|
1498
|
-
merkleRoot: number[];
|
|
1499
|
-
};
|
|
1500
|
-
|
|
1501
1505
|
/**
|
|
1502
|
-
*
|
|
1503
|
-
*
|
|
1506
|
+
* Emitted by `shield()` when a note is deposited into the shielded pool.
|
|
1507
|
+
* Rust variant: `Shielded { depositor, amount, commitment, encrypted_memo, leaf_index }`
|
|
1504
1508
|
*/
|
|
1505
|
-
/** Emitted by `shield()` when a note is deposited. */
|
|
1506
1509
|
type ShieldedEvent = {
|
|
1507
|
-
/** SS58
|
|
1510
|
+
/** SS58 AccountId of the depositor. */
|
|
1508
1511
|
depositor: string;
|
|
1509
1512
|
amount: bigint;
|
|
1510
|
-
/** 0x-prefixed 32-byte commitment
|
|
1513
|
+
/** 0x-prefixed 32-byte Poseidon commitment (LE). */
|
|
1511
1514
|
commitment: string;
|
|
1512
|
-
/** 0x-prefixed encrypted memo
|
|
1515
|
+
/** 0x-prefixed encrypted memo bytes (104 bytes). */
|
|
1513
1516
|
encryptedMemo: string;
|
|
1514
1517
|
/** Leaf index assigned in the Merkle tree. */
|
|
1515
1518
|
leafIndex: number;
|
|
1516
1519
|
};
|
|
1517
|
-
/**
|
|
1520
|
+
/**
|
|
1521
|
+
* Emitted by `private_transfer()`.
|
|
1522
|
+
* Rust variant: `PrivateTransfer { nullifiers, commitments, encrypted_memos, leaf_indices }`
|
|
1523
|
+
* Max 2 inputs / 2 outputs.
|
|
1524
|
+
*/
|
|
1518
1525
|
type PrivateTransferEvent = {
|
|
1519
|
-
/** Input nullifiers
|
|
1526
|
+
/** Input nullifiers — max 2. 0x-prefixed 32-byte hex each. */
|
|
1520
1527
|
nullifiers: string[];
|
|
1521
|
-
/** Output commitments
|
|
1528
|
+
/** Output commitments — max 2. 0x-prefixed 32-byte hex each. */
|
|
1522
1529
|
commitments: string[];
|
|
1523
|
-
/** Encrypted memos for each output. */
|
|
1530
|
+
/** Encrypted memos for each output — max 2. */
|
|
1524
1531
|
encryptedMemos: string[];
|
|
1525
|
-
/** Leaf indices assigned to output commitments. */
|
|
1532
|
+
/** Leaf indices assigned to output commitments — max 2. */
|
|
1526
1533
|
leafIndices: number[];
|
|
1527
1534
|
};
|
|
1528
|
-
/**
|
|
1535
|
+
/**
|
|
1536
|
+
* Emitted by `unshield()` when a note is withdrawn to the public chain.
|
|
1537
|
+
* Rust variant: `Unshielded { nullifier, amount, recipient }`
|
|
1538
|
+
*/
|
|
1529
1539
|
type UnshieldedEvent = {
|
|
1530
|
-
/** 0x-prefixed 32-byte nullifier
|
|
1540
|
+
/** 0x-prefixed 32-byte Poseidon nullifier (LE). */
|
|
1531
1541
|
nullifier: string;
|
|
1532
1542
|
amount: bigint;
|
|
1533
|
-
/** SS58
|
|
1543
|
+
/** SS58 AccountId of the recipient. */
|
|
1534
1544
|
recipient: string;
|
|
1535
1545
|
};
|
|
1536
|
-
/**
|
|
1546
|
+
/**
|
|
1547
|
+
* Emitted after every Merkle tree update (shield / transfer / unshield).
|
|
1548
|
+
* Rust variant: `MerkleRootUpdated { old_root, new_root, tree_size }`
|
|
1549
|
+
*/
|
|
1537
1550
|
type MerkleRootUpdatedEvent = {
|
|
1538
|
-
/** 0x-prefixed previous root
|
|
1551
|
+
/** 0x-prefixed previous Merkle root (32 bytes, LE). */
|
|
1539
1552
|
oldRoot: string;
|
|
1540
|
-
/** 0x-prefixed new root
|
|
1553
|
+
/** 0x-prefixed new Merkle root (32 bytes, LE). */
|
|
1541
1554
|
newRoot: string;
|
|
1542
|
-
/**
|
|
1555
|
+
/** Total number of leaves after the update. */
|
|
1543
1556
|
treeSize: number;
|
|
1544
1557
|
};
|
|
1545
|
-
/**
|
|
1558
|
+
/**
|
|
1559
|
+
* Emitted by `set_audit_policy()` when an account sets or updates its audit policy.
|
|
1560
|
+
* Rust variant: `AuditPolicySet { account, version }`
|
|
1561
|
+
*/
|
|
1562
|
+
type AuditPolicySetEvent = {
|
|
1563
|
+
/** SS58 AccountId of the policy owner. */
|
|
1564
|
+
account: string;
|
|
1565
|
+
/** Policy version number (monotonically increasing). */
|
|
1566
|
+
version: number;
|
|
1567
|
+
};
|
|
1568
|
+
/**
|
|
1569
|
+
* Emitted by `disclose()` when a note is disclosed.
|
|
1570
|
+
* Rust variant: `Disclosed { who, commitment, auditor }`
|
|
1571
|
+
*/
|
|
1572
|
+
type DisclosedEvent = {
|
|
1573
|
+
/** SS58 AccountId of the discloser. */
|
|
1574
|
+
who: string;
|
|
1575
|
+
/** 0x-prefixed 32-byte commitment of the disclosed note. */
|
|
1576
|
+
commitment: string;
|
|
1577
|
+
/** SS58 AccountId of the auditor, or null for voluntary disclosure. */
|
|
1578
|
+
auditor: string | null;
|
|
1579
|
+
};
|
|
1580
|
+
/**
|
|
1581
|
+
* Emitted by `request_disclosure()` when an auditor requests a note disclosure.
|
|
1582
|
+
* Rust variant: `DisclosureRequested { target, auditor, reason }`
|
|
1583
|
+
*/
|
|
1584
|
+
type DisclosureRequestedEvent = {
|
|
1585
|
+
/** SS58 AccountId of the note owner (disclosure target). */
|
|
1586
|
+
target: string;
|
|
1587
|
+
/** SS58 AccountId of the requesting auditor. */
|
|
1588
|
+
auditor: string;
|
|
1589
|
+
/** Reason string (max 256 bytes, UTF-8). */
|
|
1590
|
+
reason: string;
|
|
1591
|
+
};
|
|
1592
|
+
/**
|
|
1593
|
+
* Emitted by `reject_disclosure()` when a note owner rejects a disclosure request.
|
|
1594
|
+
* Rust variant: `DisclosureRejected { target, auditor, reason }`
|
|
1595
|
+
*/
|
|
1596
|
+
type DisclosureRejectedEvent = {
|
|
1597
|
+
/** SS58 AccountId of the note owner. */
|
|
1598
|
+
target: string;
|
|
1599
|
+
/** SS58 AccountId of the auditor whose request was rejected. */
|
|
1600
|
+
auditor: string;
|
|
1601
|
+
/** Rejection reason string (max 256 bytes, UTF-8). */
|
|
1602
|
+
reason: string;
|
|
1603
|
+
};
|
|
1604
|
+
/**
|
|
1605
|
+
* Emitted when a pending disclosure request expires (on_finalize pruning).
|
|
1606
|
+
* Rust variant: `DisclosureRequestExpired { target, auditor }`
|
|
1607
|
+
*/
|
|
1608
|
+
type DisclosureRequestExpiredEvent = {
|
|
1609
|
+
/** SS58 AccountId of the note owner. */
|
|
1610
|
+
target: string;
|
|
1611
|
+
/** SS58 AccountId of the auditor. */
|
|
1612
|
+
auditor: string;
|
|
1613
|
+
};
|
|
1614
|
+
/**
|
|
1615
|
+
* Emitted by `revoke_disclosure_record()` when an account revokes a previous disclosure.
|
|
1616
|
+
* Rust variant: `DisclosureRecordRevoked { who, commitment }`
|
|
1617
|
+
*/
|
|
1618
|
+
type DisclosureRecordRevokedEvent = {
|
|
1619
|
+
/** SS58 AccountId of the note owner. */
|
|
1620
|
+
who: string;
|
|
1621
|
+
/** 0x-prefixed 32-byte commitment of the revoked note. */
|
|
1622
|
+
commitment: string;
|
|
1623
|
+
};
|
|
1624
|
+
/**
|
|
1625
|
+
* Emitted by `register_asset()` when a new asset is registered in the pool.
|
|
1626
|
+
* Rust variant: `AssetRegistered { asset_id }`
|
|
1627
|
+
*/
|
|
1628
|
+
type AssetRegisteredEvent = {
|
|
1629
|
+
assetId: number;
|
|
1630
|
+
};
|
|
1631
|
+
/**
|
|
1632
|
+
* Emitted by `verify_asset()` when an asset is verified (marked as trusted).
|
|
1633
|
+
* Rust variant: `AssetVerified { asset_id }`
|
|
1634
|
+
*/
|
|
1635
|
+
type AssetVerifiedEvent = {
|
|
1636
|
+
assetId: number;
|
|
1637
|
+
};
|
|
1638
|
+
/**
|
|
1639
|
+
* Emitted by `unverify_asset()` when an asset's verified status is removed.
|
|
1640
|
+
* Rust variant: `AssetUnverified { asset_id }`
|
|
1641
|
+
*/
|
|
1642
|
+
type AssetUnverifiedEvent = {
|
|
1643
|
+
assetId: number;
|
|
1644
|
+
};
|
|
1645
|
+
/** All events emitted by pallet-shielded-pool as a discriminated union. */
|
|
1546
1646
|
type ShieldedPoolEvent = {
|
|
1547
1647
|
type: 'Shielded';
|
|
1548
1648
|
data: ShieldedEvent;
|
|
@@ -1555,6 +1655,973 @@ type ShieldedPoolEvent = {
|
|
|
1555
1655
|
} | {
|
|
1556
1656
|
type: 'MerkleRootUpdated';
|
|
1557
1657
|
data: MerkleRootUpdatedEvent;
|
|
1658
|
+
} | {
|
|
1659
|
+
type: 'AuditPolicySet';
|
|
1660
|
+
data: AuditPolicySetEvent;
|
|
1661
|
+
} | {
|
|
1662
|
+
type: 'Disclosed';
|
|
1663
|
+
data: DisclosedEvent;
|
|
1664
|
+
} | {
|
|
1665
|
+
type: 'DisclosureRequested';
|
|
1666
|
+
data: DisclosureRequestedEvent;
|
|
1667
|
+
} | {
|
|
1668
|
+
type: 'DisclosureRejected';
|
|
1669
|
+
data: DisclosureRejectedEvent;
|
|
1670
|
+
} | {
|
|
1671
|
+
type: 'DisclosureRequestExpired';
|
|
1672
|
+
data: DisclosureRequestExpiredEvent;
|
|
1673
|
+
} | {
|
|
1674
|
+
type: 'DisclosureRecordRevoked';
|
|
1675
|
+
data: DisclosureRecordRevokedEvent;
|
|
1676
|
+
} | {
|
|
1677
|
+
type: 'AssetRegistered';
|
|
1678
|
+
data: AssetRegisteredEvent;
|
|
1679
|
+
} | {
|
|
1680
|
+
type: 'AssetVerified';
|
|
1681
|
+
data: AssetVerifiedEvent;
|
|
1682
|
+
} | {
|
|
1683
|
+
type: 'AssetUnverified';
|
|
1684
|
+
data: AssetUnverifiedEvent;
|
|
1685
|
+
};
|
|
1686
|
+
|
|
1687
|
+
/**
|
|
1688
|
+
* TypeScript types for pallet-shielded-pool extrinsics and supporting structures.
|
|
1689
|
+
*
|
|
1690
|
+
* Conventions:
|
|
1691
|
+
* - Fixed/bounded byte arrays → `number[]` (SCALE-compatible)
|
|
1692
|
+
* - Balances (u128) → `bigint`
|
|
1693
|
+
* - AccountId → `string` (SS58 or 0x-prefixed 64-char hex)
|
|
1694
|
+
* - Block numbers → `number`
|
|
1695
|
+
* - Optional fields → `T | null`
|
|
1696
|
+
*/
|
|
1697
|
+
/**
|
|
1698
|
+
* 32-byte SCALE-encoded value (commitment, nullifier, Merkle root, etc.).
|
|
1699
|
+
* Stored as little-endian Poseidon field elements on-chain.
|
|
1700
|
+
*/
|
|
1701
|
+
type Bytes32 = number[];
|
|
1702
|
+
/**
|
|
1703
|
+
* Structured disclosure public signals — exactly 76 bytes:
|
|
1704
|
+
* commitment[0..32] | revealed_value[32..40] | revealed_asset_id[40..44] | owner_hash[44..76]
|
|
1705
|
+
*/
|
|
1706
|
+
type DisclosurePublicSignals = number[];
|
|
1707
|
+
/**
|
|
1708
|
+
* A single auditor entry in an audit policy.
|
|
1709
|
+
* Maps to `Auditor<AccountId>` in Rust.
|
|
1710
|
+
*/
|
|
1711
|
+
type Auditor = {
|
|
1712
|
+
/** SS58 or 0x-prefixed AccountId of the authorized auditor. */
|
|
1713
|
+
account: string;
|
|
1714
|
+
};
|
|
1715
|
+
/**
|
|
1716
|
+
* A condition that must be satisfied before disclosure is permitted.
|
|
1717
|
+
* Maps to `DisclosureCondition` in Rust. Max 10 conditions per policy.
|
|
1718
|
+
*/
|
|
1719
|
+
type DisclosureCondition = {
|
|
1720
|
+
type: 'MinValue';
|
|
1721
|
+
value: bigint;
|
|
1722
|
+
} | {
|
|
1723
|
+
type: 'MaxValue';
|
|
1724
|
+
value: bigint;
|
|
1725
|
+
} | {
|
|
1726
|
+
type: 'AssetId';
|
|
1727
|
+
assetId: number;
|
|
1728
|
+
} | {
|
|
1729
|
+
type: 'RecipientIs';
|
|
1730
|
+
recipient: string;
|
|
1731
|
+
} | {
|
|
1732
|
+
type: 'Custom';
|
|
1733
|
+
encoded: number[];
|
|
1734
|
+
};
|
|
1735
|
+
/**
|
|
1736
|
+
* A single entry in a batch disclosure proof submission.
|
|
1737
|
+
* Maps to `BatchDisclosureSubmission<AccountId>` in Rust.
|
|
1738
|
+
*/
|
|
1739
|
+
type BatchDisclosureSubmission = {
|
|
1740
|
+
/** 32-byte commitment (LE). */
|
|
1741
|
+
commitment: Bytes32;
|
|
1742
|
+
/** Groth16 proof bytes — max 256 bytes. */
|
|
1743
|
+
proof: number[];
|
|
1744
|
+
/** 76-byte public signals: commitment(32) | value(8) | asset_id(4) | owner_hash(32). */
|
|
1745
|
+
publicSignals: DisclosurePublicSignals;
|
|
1746
|
+
/** Optional auditor AccountId. Null = voluntary disclosure. */
|
|
1747
|
+
auditor: string | null;
|
|
1748
|
+
};
|
|
1749
|
+
/**
|
|
1750
|
+
* A single shield operation for use in `shield_batch`.
|
|
1751
|
+
*/
|
|
1752
|
+
type ShieldOperation = {
|
|
1753
|
+
assetId: number;
|
|
1754
|
+
amount: bigint;
|
|
1755
|
+
/** 32-byte Poseidon commitment (LE). */
|
|
1756
|
+
commitment: Bytes32;
|
|
1757
|
+
/** Encrypted memo bytes — exactly 104 bytes. */
|
|
1758
|
+
encryptedMemo: number[];
|
|
1759
|
+
};
|
|
1760
|
+
/**
|
|
1761
|
+
* Call index 0 — `shield` (Signed origin)
|
|
1762
|
+
* Deposits a public token amount into the shielded pool.
|
|
1763
|
+
*/
|
|
1764
|
+
type ShieldArgs = {
|
|
1765
|
+
assetId: number;
|
|
1766
|
+
amount: bigint;
|
|
1767
|
+
/** 32-byte Poseidon commitment (LE). */
|
|
1768
|
+
commitment: Bytes32;
|
|
1769
|
+
/** Encrypted memo — exactly 104 bytes. */
|
|
1770
|
+
encryptedMemo: number[];
|
|
1771
|
+
};
|
|
1772
|
+
/**
|
|
1773
|
+
* Call index 12 — `shield_batch` (Signed origin)
|
|
1774
|
+
* Deposits multiple notes in a single extrinsic — max 20 operations.
|
|
1775
|
+
*/
|
|
1776
|
+
type ShieldBatchArgs = {
|
|
1777
|
+
operations: ShieldOperation[];
|
|
1778
|
+
};
|
|
1779
|
+
/** Input note consumed by a private transfer. */
|
|
1780
|
+
type PrivateTransferInput = {
|
|
1781
|
+
/** 32-byte Poseidon nullifier (LE). */
|
|
1782
|
+
nullifier: Bytes32;
|
|
1783
|
+
/** 32-byte Poseidon commitment (LE). */
|
|
1784
|
+
commitment: Bytes32;
|
|
1785
|
+
};
|
|
1786
|
+
/** Output note created by a private transfer. */
|
|
1787
|
+
type PrivateTransferOutput = {
|
|
1788
|
+
/** 32-byte Poseidon commitment (LE). */
|
|
1789
|
+
commitment: Bytes32;
|
|
1790
|
+
/** Encrypted memo — exactly 104 bytes. */
|
|
1791
|
+
memo: number[];
|
|
1792
|
+
};
|
|
1793
|
+
/**
|
|
1794
|
+
* Call index 1 — `private_transfer` (Signed origin)
|
|
1795
|
+
* Transfers value between notes without revealing sender, recipient or amount.
|
|
1796
|
+
* Accepts 1–2 inputs and 1–2 outputs; total input value must equal total output value.
|
|
1797
|
+
*/
|
|
1798
|
+
type PrivateTransferArgs = {
|
|
1799
|
+
/** Groth16 proof bytes — max 512 bytes. */
|
|
1800
|
+
proof: number[];
|
|
1801
|
+
/** 32-byte Merkle root (LE). */
|
|
1802
|
+
merkleRoot: Bytes32;
|
|
1803
|
+
nullifiers: PrivateTransferInput[];
|
|
1804
|
+
outputs: PrivateTransferOutput[];
|
|
1805
|
+
encryptedMemos: number[][];
|
|
1806
|
+
};
|
|
1807
|
+
/**
|
|
1808
|
+
* Call index 2 — `unshield` (Signed origin)
|
|
1809
|
+
* Withdraws a note from the pool to a public account.
|
|
1810
|
+
*/
|
|
1811
|
+
type UnshieldArgs = {
|
|
1812
|
+
/** Groth16 proof bytes — max 512 bytes. */
|
|
1813
|
+
proof: number[];
|
|
1814
|
+
/** 32-byte Merkle root (LE). */
|
|
1815
|
+
merkleRoot: Bytes32;
|
|
1816
|
+
/** 32-byte nullifier of the spent note (LE). */
|
|
1817
|
+
nullifier: Bytes32;
|
|
1818
|
+
assetId: number;
|
|
1819
|
+
amount: bigint;
|
|
1820
|
+
/** SS58 or 0x-prefixed AccountId of the recipient. */
|
|
1821
|
+
recipient: string;
|
|
1822
|
+
};
|
|
1823
|
+
/**
|
|
1824
|
+
* Call index 4 — `set_audit_policy` (Signed origin)
|
|
1825
|
+
* Registers or replaces the caller's audit policy for selective disclosure.
|
|
1826
|
+
*/
|
|
1827
|
+
type SetAuditPolicyArgs = {
|
|
1828
|
+
/** Up to 10 authorized auditors. */
|
|
1829
|
+
auditors: Auditor[];
|
|
1830
|
+
/** Up to 10 disclosure conditions. */
|
|
1831
|
+
conditions: DisclosureCondition[];
|
|
1832
|
+
/** Minimum blocks between disclosures to the same auditor. Null = no limit. */
|
|
1833
|
+
maxFrequency: number | null;
|
|
1834
|
+
/** Block after which the policy expires. Null = no expiry. */
|
|
1835
|
+
validUntil: number | null;
|
|
1836
|
+
};
|
|
1837
|
+
/**
|
|
1838
|
+
* Call index 5 — `request_disclosure` (Signed origin)
|
|
1839
|
+
* Auditor requests selective disclosure from a target account.
|
|
1840
|
+
*/
|
|
1841
|
+
type RequestDisclosureArgs = {
|
|
1842
|
+
/** AccountId of the disclosure target. */
|
|
1843
|
+
target: string;
|
|
1844
|
+
/** Human-readable request reason — max 256 bytes UTF-8. */
|
|
1845
|
+
reason: string;
|
|
1846
|
+
};
|
|
1847
|
+
/**
|
|
1848
|
+
* Call index 6 — `disclose` (Signed origin)
|
|
1849
|
+
* Submit a Groth16 disclosure proof for a commitment.
|
|
1850
|
+
*/
|
|
1851
|
+
type DiscloseArgs = {
|
|
1852
|
+
/** 32-byte note commitment to disclose (LE). */
|
|
1853
|
+
commitment: Bytes32;
|
|
1854
|
+
/** Groth16 proof bytes — max 256 bytes. */
|
|
1855
|
+
proofBytes: number[];
|
|
1856
|
+
/** 76-byte public signals: commitment(32) | value(8) | asset_id(4) | owner_hash(32). */
|
|
1857
|
+
publicSignals: DisclosurePublicSignals;
|
|
1858
|
+
/** Target auditor AccountId. Null = voluntary public disclosure. */
|
|
1859
|
+
auditor: string | null;
|
|
1860
|
+
};
|
|
1861
|
+
/**
|
|
1862
|
+
* Call index 7 — `reject_disclosure` (Signed origin)
|
|
1863
|
+
* Disclosure target rejects a pending request from an auditor.
|
|
1864
|
+
*/
|
|
1865
|
+
type RejectDisclosureArgs = {
|
|
1866
|
+
/** AccountId of the auditor whose request is rejected. */
|
|
1867
|
+
auditor: string;
|
|
1868
|
+
/** Rejection reason — max 256 bytes UTF-8. */
|
|
1869
|
+
reason: string;
|
|
1870
|
+
};
|
|
1871
|
+
/**
|
|
1872
|
+
* Call index 13 — `batch_submit_disclosure_proofs` (Signed origin)
|
|
1873
|
+
* Submit up to 10 disclosure proofs in one extrinsic.
|
|
1874
|
+
*/
|
|
1875
|
+
type BatchSubmitDisclosureProofsArgs = {
|
|
1876
|
+
submissions: BatchDisclosureSubmission[];
|
|
1877
|
+
};
|
|
1878
|
+
/**
|
|
1879
|
+
* Call index 9 — `register_asset` (Root origin)
|
|
1880
|
+
* Registers a new asset in the shielded pool registry.
|
|
1881
|
+
*/
|
|
1882
|
+
type RegisterAssetArgs = {
|
|
1883
|
+
/** Asset name — max 64 bytes UTF-8. */
|
|
1884
|
+
name: string;
|
|
1885
|
+
/** Asset ticker symbol, e.g. "USDT" — max 16 bytes UTF-8. */
|
|
1886
|
+
symbol: string;
|
|
1887
|
+
/** Token decimal precision (e.g. 18 for ORB, 6 for USDT). */
|
|
1888
|
+
decimals: number;
|
|
1889
|
+
/** 20-byte EVM contract address for ERC-20 assets. Null = native asset. */
|
|
1890
|
+
contractAddress: number[] | null;
|
|
1891
|
+
};
|
|
1892
|
+
/**
|
|
1893
|
+
* Call index 10 — `verify_asset` (Root origin)
|
|
1894
|
+
* Marks a registered asset as verified, enabling shielding.
|
|
1895
|
+
*/
|
|
1896
|
+
type VerifyAssetArgs = {
|
|
1897
|
+
assetId: number;
|
|
1898
|
+
};
|
|
1899
|
+
/**
|
|
1900
|
+
* Call index 11 — `unverify_asset` (Root origin)
|
|
1901
|
+
* Removes the verified status from an asset, disabling new shield operations.
|
|
1902
|
+
*/
|
|
1903
|
+
type UnverifyAssetArgs = {
|
|
1904
|
+
assetId: number;
|
|
1905
|
+
};
|
|
1906
|
+
/**
|
|
1907
|
+
* Call index 14 — `prune_expired_request` (Signed origin)
|
|
1908
|
+
* Cleans up a disclosure request that has passed its expiration block.
|
|
1909
|
+
*/
|
|
1910
|
+
type PruneExpiredRequestArgs = {
|
|
1911
|
+
/** AccountId of the disclosure target. */
|
|
1912
|
+
target: string;
|
|
1913
|
+
/** AccountId of the auditor. */
|
|
1914
|
+
auditor: string;
|
|
1915
|
+
};
|
|
1916
|
+
/**
|
|
1917
|
+
* Call index 15 — `revoke_disclosure_record` (Signed origin)
|
|
1918
|
+
* Allows the note owner to revoke a previously submitted disclosure record.
|
|
1919
|
+
*/
|
|
1920
|
+
type RevokeDisclosureRecordArgs = {
|
|
1921
|
+
/** 32-byte commitment whose disclosure record should be revoked (LE). */
|
|
1922
|
+
commitment: Bytes32;
|
|
1923
|
+
};
|
|
1924
|
+
/** All pallet-shielded-pool calls as a discriminated union. */
|
|
1925
|
+
type ShieldedPoolCall = {
|
|
1926
|
+
type: 'shield';
|
|
1927
|
+
args: ShieldArgs;
|
|
1928
|
+
} | {
|
|
1929
|
+
type: 'shieldBatch';
|
|
1930
|
+
args: ShieldBatchArgs;
|
|
1931
|
+
} | {
|
|
1932
|
+
type: 'privateTransfer';
|
|
1933
|
+
args: PrivateTransferArgs;
|
|
1934
|
+
} | {
|
|
1935
|
+
type: 'unshield';
|
|
1936
|
+
args: UnshieldArgs;
|
|
1937
|
+
} | {
|
|
1938
|
+
type: 'setAuditPolicy';
|
|
1939
|
+
args: SetAuditPolicyArgs;
|
|
1940
|
+
} | {
|
|
1941
|
+
type: 'requestDisclosure';
|
|
1942
|
+
args: RequestDisclosureArgs;
|
|
1943
|
+
} | {
|
|
1944
|
+
type: 'disclose';
|
|
1945
|
+
args: DiscloseArgs;
|
|
1946
|
+
} | {
|
|
1947
|
+
type: 'rejectDisclosure';
|
|
1948
|
+
args: RejectDisclosureArgs;
|
|
1949
|
+
} | {
|
|
1950
|
+
type: 'batchSubmitDisclosureProofs';
|
|
1951
|
+
args: BatchSubmitDisclosureProofsArgs;
|
|
1952
|
+
} | {
|
|
1953
|
+
type: 'registerAsset';
|
|
1954
|
+
args: RegisterAssetArgs;
|
|
1955
|
+
} | {
|
|
1956
|
+
type: 'verifyAsset';
|
|
1957
|
+
args: VerifyAssetArgs;
|
|
1958
|
+
} | {
|
|
1959
|
+
type: 'unverifyAsset';
|
|
1960
|
+
args: UnverifyAssetArgs;
|
|
1961
|
+
} | {
|
|
1962
|
+
type: 'pruneExpiredRequest';
|
|
1963
|
+
args: PruneExpiredRequestArgs;
|
|
1964
|
+
} | {
|
|
1965
|
+
type: 'revokeDisclosureRecord';
|
|
1966
|
+
args: RevokeDisclosureRecordArgs;
|
|
1967
|
+
};
|
|
1968
|
+
|
|
1969
|
+
/**
|
|
1970
|
+
* TypeScript types for pallet-zk-verifier extrinsics.
|
|
1971
|
+
*
|
|
1972
|
+
* Conventions:
|
|
1973
|
+
* - Byte arrays → `number[]` (SCALE-compatible)
|
|
1974
|
+
* - Versions → `number` (u32)
|
|
1975
|
+
*/
|
|
1976
|
+
/**
|
|
1977
|
+
* On-chain circuit identifier (u32 newtype on-chain).
|
|
1978
|
+
* Use the {@link CircuitId} constant object for named values.
|
|
1979
|
+
*/
|
|
1980
|
+
type CircuitId = (typeof CircuitId)[keyof typeof CircuitId];
|
|
1981
|
+
/**
|
|
1982
|
+
* Named constants for all supported ZK circuits.
|
|
1983
|
+
*
|
|
1984
|
+
* | Name | Value | Circuit |
|
|
1985
|
+
* |--------------|-------|---------------------------------|
|
|
1986
|
+
* | Transfer | 1 | 2-in-2-out private transfer |
|
|
1987
|
+
* | Unshield | 2 | Withdrawal from the pool |
|
|
1988
|
+
* | Disclosure | 3 | Selective disclosure |
|
|
1989
|
+
* | PrivateLink | 4 | Private chain-link proof |
|
|
1990
|
+
*/
|
|
1991
|
+
declare const CircuitId: {
|
|
1992
|
+
readonly Transfer: 1;
|
|
1993
|
+
readonly Unshield: 2;
|
|
1994
|
+
readonly Disclosure: 3;
|
|
1995
|
+
readonly PrivateLink: 4;
|
|
1996
|
+
};
|
|
1997
|
+
/**
|
|
1998
|
+
* A single verification key registration entry used in batch operations.
|
|
1999
|
+
* Maps to `VkEntry` in Rust.
|
|
2000
|
+
*/
|
|
2001
|
+
type VkEntry = {
|
|
2002
|
+
circuitId: CircuitId;
|
|
2003
|
+
/** Circuit version number (u32 on-chain). Versions are independent per circuit. */
|
|
2004
|
+
version: number;
|
|
2005
|
+
/** Serialised Groth16 verification key bytes — max 8 192 bytes. */
|
|
2006
|
+
verificationKey: number[];
|
|
2007
|
+
};
|
|
2008
|
+
/**
|
|
2009
|
+
* Call index 0 — `register_verification_key` (Root origin)
|
|
2010
|
+
* Registers a Groth16 verification key for a specific circuit and version.
|
|
2011
|
+
*/
|
|
2012
|
+
type RegisterVerificationKeyArgs = {
|
|
2013
|
+
circuitId: CircuitId;
|
|
2014
|
+
/** Version to associate with this key. */
|
|
2015
|
+
version: number;
|
|
2016
|
+
/** Serialised Groth16 verification key bytes — max 8 192 bytes. */
|
|
2017
|
+
verificationKey: number[];
|
|
2018
|
+
};
|
|
2019
|
+
/**
|
|
2020
|
+
* Call index 1 — `set_active_version` (Root origin)
|
|
2021
|
+
* Designates a specific version as the active one used for proof verification.
|
|
2022
|
+
*/
|
|
2023
|
+
type SetActiveVersionArgs = {
|
|
2024
|
+
circuitId: CircuitId;
|
|
2025
|
+
version: number;
|
|
2026
|
+
};
|
|
2027
|
+
/**
|
|
2028
|
+
* Call index 2 — `remove_verification_key` (Root origin)
|
|
2029
|
+
* Removes a registered verification key.
|
|
2030
|
+
* The currently active version cannot be removed.
|
|
2031
|
+
*/
|
|
2032
|
+
type RemoveVerificationKeyArgs = {
|
|
2033
|
+
circuitId: CircuitId;
|
|
2034
|
+
version: number;
|
|
2035
|
+
};
|
|
2036
|
+
/**
|
|
2037
|
+
* Call index 3 — `verify_proof` (Signed origin)
|
|
2038
|
+
* Verifies a single Groth16 proof on-chain for the specified circuit.
|
|
2039
|
+
* Uses the circuit's currently active verification key version.
|
|
2040
|
+
*/
|
|
2041
|
+
type VerifyProofArgs = {
|
|
2042
|
+
circuitId: CircuitId;
|
|
2043
|
+
/** Groth16 proof bytes. */
|
|
2044
|
+
proof: number[];
|
|
2045
|
+
/**
|
|
2046
|
+
* Public inputs as a list of 32-byte field elements (LE).
|
|
2047
|
+
* Number and meaning of inputs depends on the circuit:
|
|
2048
|
+
* - Transfer: [merkle_root, nullifier_0, nullifier_1, commitment_0, commitment_1]
|
|
2049
|
+
* - Unshield: [merkle_root, nullifier, amount_fe, recipient_hash, asset_id_fe]
|
|
2050
|
+
* - Disclosure: [commitment, revealed_value_fe, revealed_asset_id_fe, owner_hash]
|
|
2051
|
+
* - PrivateLink: [commitment, call_hash_fe]
|
|
2052
|
+
*/
|
|
2053
|
+
publicInputs: number[][];
|
|
2054
|
+
};
|
|
2055
|
+
/**
|
|
2056
|
+
* Call index 4 — `batch_register_verification_keys` (Root origin)
|
|
2057
|
+
* Registers up to 10 verification keys in one extrinsic.
|
|
2058
|
+
* Useful for initial chain setup or coordinated upgrades.
|
|
2059
|
+
*/
|
|
2060
|
+
type BatchRegisterVerificationKeysArgs = {
|
|
2061
|
+
/** Up to 10 VK entries. */
|
|
2062
|
+
entries: VkEntry[];
|
|
2063
|
+
};
|
|
2064
|
+
/** All pallet-zk-verifier calls as a discriminated union. */
|
|
2065
|
+
type ZkVerifierCall = {
|
|
2066
|
+
type: 'registerVerificationKey';
|
|
2067
|
+
args: RegisterVerificationKeyArgs;
|
|
2068
|
+
} | {
|
|
2069
|
+
type: 'setActiveVersion';
|
|
2070
|
+
args: SetActiveVersionArgs;
|
|
2071
|
+
} | {
|
|
2072
|
+
type: 'removeVerificationKey';
|
|
2073
|
+
args: RemoveVerificationKeyArgs;
|
|
2074
|
+
} | {
|
|
2075
|
+
type: 'verifyProof';
|
|
2076
|
+
args: VerifyProofArgs;
|
|
2077
|
+
} | {
|
|
2078
|
+
type: 'batchRegisterVerificationKeys';
|
|
2079
|
+
args: BatchRegisterVerificationKeysArgs;
|
|
2080
|
+
};
|
|
2081
|
+
|
|
2082
|
+
/**
|
|
2083
|
+
* TypeScript types for pallet-account-mapping extrinsics.
|
|
2084
|
+
*
|
|
2085
|
+
* Conventions:
|
|
2086
|
+
* - Byte arrays → `number[]` (SCALE-compatible)
|
|
2087
|
+
* - Balances → `bigint`
|
|
2088
|
+
* - AccountId → `string` (SS58 or 0x-prefixed 64-char hex)
|
|
2089
|
+
* - ChainId → `number` (u32, typically a SLIP-0044 coin type)
|
|
2090
|
+
* - Optional → `T | null`
|
|
2091
|
+
*/
|
|
2092
|
+
/**
|
|
2093
|
+
* External chain signature scheme.
|
|
2094
|
+
* Maps to `SignatureScheme` enum in pallet-account-mapping.
|
|
2095
|
+
*
|
|
2096
|
+
* - `Eip191` — Ethereum personal_sign (EIP-191 prefix)
|
|
2097
|
+
* - `Ed25519` — Raw Ed25519 signature (Solana, Polkadot, etc.)
|
|
2098
|
+
*/
|
|
2099
|
+
type SignatureScheme = 'Eip191' | 'Ed25519';
|
|
2100
|
+
/**
|
|
2101
|
+
* Call index 2 — `register_alias` (Signed origin)
|
|
2102
|
+
* Registers a human-readable identity alias for the caller's Substrate account.
|
|
2103
|
+
* Valid characters: alphanumeric, underscore, hyphen.
|
|
2104
|
+
* Length bounded by `T::MaxAliasLength` on-chain (configurable; typically ≤ 32 bytes).
|
|
2105
|
+
*/
|
|
2106
|
+
type RegisterAliasArgs = {
|
|
2107
|
+
alias: string;
|
|
2108
|
+
};
|
|
2109
|
+
/**
|
|
2110
|
+
* Call index 4 — `transfer_alias` (Signed origin)
|
|
2111
|
+
* Transfers the caller's alias to another account.
|
|
2112
|
+
* The current owner loses the alias; the new owner must not already hold one.
|
|
2113
|
+
*/
|
|
2114
|
+
type TransferAliasArgs = {
|
|
2115
|
+
/** AccountId of the new owner. */
|
|
2116
|
+
newOwner: string;
|
|
2117
|
+
};
|
|
2118
|
+
/**
|
|
2119
|
+
* Call index 5 — `put_alias_on_sale` (Signed origin)
|
|
2120
|
+
* Lists the caller's alias for purchase at a given planck price.
|
|
2121
|
+
*/
|
|
2122
|
+
type PutAliasOnSaleArgs = {
|
|
2123
|
+
/** Sale price in planck (native token smallest unit). Cannot be zero. */
|
|
2124
|
+
price: bigint;
|
|
2125
|
+
/**
|
|
2126
|
+
* Optional whitelist of AccountIds allowed to buy.
|
|
2127
|
+
* Null = unrestricted public sale.
|
|
2128
|
+
* Max {@link MAX_WHITELIST_SIZE} entries.
|
|
2129
|
+
*/
|
|
2130
|
+
allowedBuyers: string[] | null;
|
|
2131
|
+
};
|
|
2132
|
+
/**
|
|
2133
|
+
* Call index 7 — `buy_alias` (Signed origin)
|
|
2134
|
+
* Purchases an alias currently listed for sale.
|
|
2135
|
+
* The buyer must not already hold an alias.
|
|
2136
|
+
*/
|
|
2137
|
+
type BuyAliasArgs = {
|
|
2138
|
+
/** The alias to purchase. */
|
|
2139
|
+
alias: string;
|
|
2140
|
+
};
|
|
2141
|
+
/**
|
|
2142
|
+
* Call index 8 — `add_chain_link` (Signed origin)
|
|
2143
|
+
* Links an external-chain address to the caller's Orbinum identity.
|
|
2144
|
+
* The `signature` must be produced over a deterministic challenge message
|
|
2145
|
+
* using the private key corresponding to `address` on the given chain.
|
|
2146
|
+
*/
|
|
2147
|
+
type AddChainLinkArgs = {
|
|
2148
|
+
/** u32 chain identifier (must be in the supported chains registry). */
|
|
2149
|
+
chainId: number;
|
|
2150
|
+
/** Raw external address bytes — 20 bytes for EVM, 32 bytes for Ed25519 chains. */
|
|
2151
|
+
address: number[];
|
|
2152
|
+
/** Ownership proof signature bytes. */
|
|
2153
|
+
signature: number[];
|
|
2154
|
+
};
|
|
2155
|
+
/**
|
|
2156
|
+
* Call index 9 — `remove_chain_link` (Signed origin)
|
|
2157
|
+
* Removes a previously verified external chain link from the caller's identity.
|
|
2158
|
+
*/
|
|
2159
|
+
type RemoveChainLinkArgs = {
|
|
2160
|
+
/** u32 chain identifier of the link to remove. */
|
|
2161
|
+
chainId: number;
|
|
2162
|
+
};
|
|
2163
|
+
/**
|
|
2164
|
+
* Call index 10 — `set_account_metadata` (Signed origin)
|
|
2165
|
+
* Sets or updates the caller's public profile metadata.
|
|
2166
|
+
* Fields set to null are cleared from storage.
|
|
2167
|
+
*/
|
|
2168
|
+
type SetAccountMetadataArgs = {
|
|
2169
|
+
/** Display name — max 64 bytes UTF-8. Null removes the field. */
|
|
2170
|
+
displayName: string | null;
|
|
2171
|
+
/** Short biography — max 512 bytes UTF-8. Null removes the field. */
|
|
2172
|
+
bio: string | null;
|
|
2173
|
+
/** Avatar URL or IPFS CID — max 256 bytes. Null removes the field. */
|
|
2174
|
+
avatar: string | null;
|
|
2175
|
+
};
|
|
2176
|
+
/**
|
|
2177
|
+
* Call index 11 — `add_supported_chain` (Root origin)
|
|
2178
|
+
* Registers a new external chain in the supported chains registry.
|
|
2179
|
+
*/
|
|
2180
|
+
type AddSupportedChainArgs = {
|
|
2181
|
+
/** u32 chain identifier (e.g. SLIP-0044 coin type). */
|
|
2182
|
+
chainId: number;
|
|
2183
|
+
/** Signature scheme used for address-ownership proofs on this chain. */
|
|
2184
|
+
scheme: SignatureScheme;
|
|
2185
|
+
};
|
|
2186
|
+
/**
|
|
2187
|
+
* Call index 12 — `remove_supported_chain` (Root origin)
|
|
2188
|
+
* Removes a chain from the supported chains registry.
|
|
2189
|
+
* Existing links for that chain are unaffected.
|
|
2190
|
+
*/
|
|
2191
|
+
type RemoveSupportedChainArgs = {
|
|
2192
|
+
/** u32 chain identifier to remove. */
|
|
2193
|
+
chainId: number;
|
|
2194
|
+
};
|
|
2195
|
+
/**
|
|
2196
|
+
* Call index 13 — `dispatch_as_linked_account` (Signed origin, relayer)
|
|
2197
|
+
* Dispatches a RuntimeCall on behalf of an account that owns a verified chain link.
|
|
2198
|
+
* The relayer pays fees; authorisation comes from the external chain signature.
|
|
2199
|
+
*/
|
|
2200
|
+
type DispatchAsLinkedAccountArgs = {
|
|
2201
|
+
/** AccountId on whose behalf to dispatch. */
|
|
2202
|
+
owner: string;
|
|
2203
|
+
/** u32 chain identifier of the link used for authorisation. */
|
|
2204
|
+
chainId: number;
|
|
2205
|
+
/** Raw external address bytes of the authorising signer. */
|
|
2206
|
+
address: number[];
|
|
2207
|
+
/** Signature over the SCALE-encoded `call` payload. */
|
|
2208
|
+
signature: number[];
|
|
2209
|
+
/** SCALE-encoded RuntimeCall to dispatch. */
|
|
2210
|
+
call: number[];
|
|
2211
|
+
};
|
|
2212
|
+
/**
|
|
2213
|
+
* Call index 14 — `register_private_link` (Signed origin)
|
|
2214
|
+
* Registers a hidden chain link using a Poseidon commitment: H(address, blinding).
|
|
2215
|
+
* The actual external address is not revealed on-chain.
|
|
2216
|
+
*/
|
|
2217
|
+
type RegisterPrivateLinkArgs = {
|
|
2218
|
+
/** u32 chain identifier. */
|
|
2219
|
+
chainId: number;
|
|
2220
|
+
/** 32-byte Poseidon commitment: H(address || blinding) (LE). */
|
|
2221
|
+
commitment: number[];
|
|
2222
|
+
};
|
|
2223
|
+
/**
|
|
2224
|
+
* Call index 15 — `remove_private_link` (Signed origin)
|
|
2225
|
+
* Removes a private chain link identified by its commitment.
|
|
2226
|
+
*/
|
|
2227
|
+
type RemovePrivateLinkArgs = {
|
|
2228
|
+
/** 32-byte commitment identifying the link to remove (LE). */
|
|
2229
|
+
commitment: number[];
|
|
2230
|
+
};
|
|
2231
|
+
/**
|
|
2232
|
+
* Call index 16 — `reveal_private_link` (Signed origin)
|
|
2233
|
+
* Reveals a previously registered private link by providing the commitment preimage.
|
|
2234
|
+
* After this call the link becomes publicly readable in storage.
|
|
2235
|
+
*/
|
|
2236
|
+
type RevealPrivateLinkArgs = {
|
|
2237
|
+
/** 32-byte commitment: H(address || blinding) (LE). */
|
|
2238
|
+
commitment: number[];
|
|
2239
|
+
/** The actual raw external address bytes being revealed. */
|
|
2240
|
+
address: number[];
|
|
2241
|
+
/** 32-byte blinding factor used when creating the commitment (LE). */
|
|
2242
|
+
blinding: number[];
|
|
2243
|
+
/** Ownership proof signature produced with the external-chain key. */
|
|
2244
|
+
signature: number[];
|
|
2245
|
+
};
|
|
2246
|
+
/**
|
|
2247
|
+
* Call index 17 — `dispatch_as_private_link` (Signed origin, relayer)
|
|
2248
|
+
* Dispatches a RuntimeCall on behalf of an account identified only by a private
|
|
2249
|
+
* link commitment. A Groth16 ZK proof (PRIVATE_LINK circuit) authorises the
|
|
2250
|
+
* dispatch without revealing the external address.
|
|
2251
|
+
*/
|
|
2252
|
+
type DispatchAsPrivateLinkArgs = {
|
|
2253
|
+
/** AccountId on whose behalf to dispatch. */
|
|
2254
|
+
owner: string;
|
|
2255
|
+
/** 32-byte commitment identifying the private link (LE). */
|
|
2256
|
+
commitment: number[];
|
|
2257
|
+
/** Groth16 proof bytes (PRIVATE_LINK circuit). */
|
|
2258
|
+
zkProof: number[];
|
|
2259
|
+
/** SCALE-encoded RuntimeCall to dispatch. */
|
|
2260
|
+
call: number[];
|
|
2261
|
+
};
|
|
2262
|
+
/** All pallet-account-mapping calls as a discriminated union. */
|
|
2263
|
+
type AccountMappingCall = {
|
|
2264
|
+
type: 'mapAccount';
|
|
2265
|
+
} | {
|
|
2266
|
+
type: 'unmapAccount';
|
|
2267
|
+
} | {
|
|
2268
|
+
type: 'registerAlias';
|
|
2269
|
+
args: RegisterAliasArgs;
|
|
2270
|
+
} | {
|
|
2271
|
+
type: 'releaseAlias';
|
|
2272
|
+
} | {
|
|
2273
|
+
type: 'transferAlias';
|
|
2274
|
+
args: TransferAliasArgs;
|
|
2275
|
+
} | {
|
|
2276
|
+
type: 'putAliasOnSale';
|
|
2277
|
+
args: PutAliasOnSaleArgs;
|
|
2278
|
+
} | {
|
|
2279
|
+
type: 'cancelSale';
|
|
2280
|
+
} | {
|
|
2281
|
+
type: 'buyAlias';
|
|
2282
|
+
args: BuyAliasArgs;
|
|
2283
|
+
} | {
|
|
2284
|
+
type: 'addChainLink';
|
|
2285
|
+
args: AddChainLinkArgs;
|
|
2286
|
+
} | {
|
|
2287
|
+
type: 'removeChainLink';
|
|
2288
|
+
args: RemoveChainLinkArgs;
|
|
2289
|
+
} | {
|
|
2290
|
+
type: 'setAccountMetadata';
|
|
2291
|
+
args: SetAccountMetadataArgs;
|
|
2292
|
+
} | {
|
|
2293
|
+
type: 'addSupportedChain';
|
|
2294
|
+
args: AddSupportedChainArgs;
|
|
2295
|
+
} | {
|
|
2296
|
+
type: 'removeSupportedChain';
|
|
2297
|
+
args: RemoveSupportedChainArgs;
|
|
2298
|
+
} | {
|
|
2299
|
+
type: 'dispatchAsLinkedAccount';
|
|
2300
|
+
args: DispatchAsLinkedAccountArgs;
|
|
2301
|
+
} | {
|
|
2302
|
+
type: 'registerPrivateLink';
|
|
2303
|
+
args: RegisterPrivateLinkArgs;
|
|
2304
|
+
} | {
|
|
2305
|
+
type: 'removePrivateLink';
|
|
2306
|
+
args: RemovePrivateLinkArgs;
|
|
2307
|
+
} | {
|
|
2308
|
+
type: 'revealPrivateLink';
|
|
2309
|
+
args: RevealPrivateLinkArgs;
|
|
2310
|
+
} | {
|
|
2311
|
+
type: 'dispatchAsPrivateLink';
|
|
2312
|
+
args: DispatchAsPrivateLinkArgs;
|
|
2313
|
+
};
|
|
2314
|
+
|
|
2315
|
+
/**
|
|
2316
|
+
* TypeScript types for events emitted by pallet-zk-verifier.
|
|
2317
|
+
*
|
|
2318
|
+
* Conventions:
|
|
2319
|
+
* - CircuitId → imported from pallet-extrinsics (u32 newtype)
|
|
2320
|
+
* - version → `number` (u32)
|
|
2321
|
+
* - count → `number` (u32)
|
|
2322
|
+
*/
|
|
2323
|
+
|
|
2324
|
+
/**
|
|
2325
|
+
* Emitted by `register_verification_key()` when a new VK is stored.
|
|
2326
|
+
* Rust variant: `VerificationKeyRegistered { circuit_id, version }`
|
|
2327
|
+
*/
|
|
2328
|
+
type VerificationKeyRegisteredEvent = {
|
|
2329
|
+
circuitId: CircuitId;
|
|
2330
|
+
version: number;
|
|
2331
|
+
};
|
|
2332
|
+
/**
|
|
2333
|
+
* Emitted by `set_active_version()` when the active VK version changes.
|
|
2334
|
+
* Rust variant: `ActiveVersionSet { circuit_id, version }`
|
|
2335
|
+
*/
|
|
2336
|
+
type ActiveVersionSetEvent = {
|
|
2337
|
+
circuitId: CircuitId;
|
|
2338
|
+
version: number;
|
|
2339
|
+
};
|
|
2340
|
+
/**
|
|
2341
|
+
* Emitted by `remove_verification_key()` when a VK is deleted.
|
|
2342
|
+
* Rust variant: `VerificationKeyRemoved { circuit_id, version }`
|
|
2343
|
+
*/
|
|
2344
|
+
type VerificationKeyRemovedEvent = {
|
|
2345
|
+
circuitId: CircuitId;
|
|
2346
|
+
version: number;
|
|
2347
|
+
};
|
|
2348
|
+
/**
|
|
2349
|
+
* Emitted by `verify_proof()` when a ZK proof is successfully verified.
|
|
2350
|
+
* Rust variant: `ProofVerified { circuit_id, version }`
|
|
2351
|
+
*/
|
|
2352
|
+
type ProofVerifiedEvent = {
|
|
2353
|
+
circuitId: CircuitId;
|
|
2354
|
+
version: number;
|
|
2355
|
+
};
|
|
2356
|
+
/**
|
|
2357
|
+
* Emitted by `verify_proof()` when ZK proof verification fails.
|
|
2358
|
+
* Rust variant: `ProofVerificationFailed { circuit_id, version }`
|
|
2359
|
+
*/
|
|
2360
|
+
type ProofVerificationFailedEvent = {
|
|
2361
|
+
circuitId: CircuitId;
|
|
2362
|
+
version: number;
|
|
2363
|
+
};
|
|
2364
|
+
/**
|
|
2365
|
+
* Emitted by `batch_register_verification_keys()` on success.
|
|
2366
|
+
* Rust variant: `BatchVerificationKeysRegistered { count }`
|
|
2367
|
+
*/
|
|
2368
|
+
type BatchVerificationKeysRegisteredEvent = {
|
|
2369
|
+
/** Number of VK entries registered in the batch. */
|
|
2370
|
+
count: number;
|
|
2371
|
+
};
|
|
2372
|
+
/** All events emitted by pallet-zk-verifier as a discriminated union. */
|
|
2373
|
+
type ZkVerifierEvent = {
|
|
2374
|
+
type: 'VerificationKeyRegistered';
|
|
2375
|
+
data: VerificationKeyRegisteredEvent;
|
|
2376
|
+
} | {
|
|
2377
|
+
type: 'ActiveVersionSet';
|
|
2378
|
+
data: ActiveVersionSetEvent;
|
|
2379
|
+
} | {
|
|
2380
|
+
type: 'VerificationKeyRemoved';
|
|
2381
|
+
data: VerificationKeyRemovedEvent;
|
|
2382
|
+
} | {
|
|
2383
|
+
type: 'ProofVerified';
|
|
2384
|
+
data: ProofVerifiedEvent;
|
|
2385
|
+
} | {
|
|
2386
|
+
type: 'ProofVerificationFailed';
|
|
2387
|
+
data: ProofVerificationFailedEvent;
|
|
2388
|
+
} | {
|
|
2389
|
+
type: 'BatchVerificationKeysRegistered';
|
|
2390
|
+
data: BatchVerificationKeysRegisteredEvent;
|
|
2391
|
+
};
|
|
2392
|
+
|
|
2393
|
+
/**
|
|
2394
|
+
* TypeScript types for events emitted by pallet-account-mapping.
|
|
2395
|
+
*
|
|
2396
|
+
* Conventions:
|
|
2397
|
+
* - AccountId → `string` (SS58)
|
|
2398
|
+
* - H160 → `string` (0x-prefixed 20-byte Ethereum address)
|
|
2399
|
+
* - AliasOf<T> → `string` (bounded string, max configurable)
|
|
2400
|
+
* - ChainId → `number` (SLIP-0044 coin-type u32)
|
|
2401
|
+
* - ExternalAddr → `string` (chain-specific address string)
|
|
2402
|
+
* - BalanceOf<T> → `bigint`
|
|
2403
|
+
* - [u8; 32] → `string` (0x-prefixed hex, for private commitments)
|
|
2404
|
+
* - SignatureScheme → imported from pallet-extrinsics
|
|
2405
|
+
*/
|
|
2406
|
+
|
|
2407
|
+
/**
|
|
2408
|
+
* Emitted when a Substrate account is mapped to an Ethereum address.
|
|
2409
|
+
* Rust variant: `AccountMapped { account, address }`
|
|
2410
|
+
*/
|
|
2411
|
+
type AccountMappedEvent = {
|
|
2412
|
+
account: string;
|
|
2413
|
+
/** 0x-prefixed 20-byte Ethereum address. */
|
|
2414
|
+
address: string;
|
|
2415
|
+
};
|
|
2416
|
+
/**
|
|
2417
|
+
* Emitted when an existing account mapping is removed.
|
|
2418
|
+
* Rust variant: `AccountUnmapped { account, address }`
|
|
2419
|
+
*/
|
|
2420
|
+
type AccountUnmappedEvent = {
|
|
2421
|
+
account: string;
|
|
2422
|
+
/** 0x-prefixed 20-byte Ethereum address. */
|
|
2423
|
+
address: string;
|
|
2424
|
+
};
|
|
2425
|
+
/**
|
|
2426
|
+
* Emitted by `register_alias()` when a new alias is claimed.
|
|
2427
|
+
* Rust variant: `AliasRegistered { account, alias, evm_address }`
|
|
2428
|
+
*/
|
|
2429
|
+
type AliasRegisteredEvent = {
|
|
2430
|
+
account: string;
|
|
2431
|
+
alias: string;
|
|
2432
|
+
/** Optional EVM address linked at registration time. */
|
|
2433
|
+
evmAddress: string | null;
|
|
2434
|
+
};
|
|
2435
|
+
/**
|
|
2436
|
+
* Emitted when an alias is released (burned / expired).
|
|
2437
|
+
* Rust variant: `AliasReleased { account, alias }`
|
|
2438
|
+
*/
|
|
2439
|
+
type AliasReleasedEvent = {
|
|
2440
|
+
account: string;
|
|
2441
|
+
alias: string;
|
|
2442
|
+
};
|
|
2443
|
+
/**
|
|
2444
|
+
* Emitted by `transfer_alias()` when ownership changes hands.
|
|
2445
|
+
* Rust variant: `AliasTransferred { from, to, alias }`
|
|
2446
|
+
*/
|
|
2447
|
+
type AliasTransferredEvent = {
|
|
2448
|
+
from: string;
|
|
2449
|
+
to: string;
|
|
2450
|
+
alias: string;
|
|
2451
|
+
};
|
|
2452
|
+
/**
|
|
2453
|
+
* Emitted by `put_alias_on_sale()` when an alias is listed on the marketplace.
|
|
2454
|
+
* Rust variant: `AliasListedForSale { seller, alias, price, private }`
|
|
2455
|
+
*/
|
|
2456
|
+
type AliasListedForSaleEvent = {
|
|
2457
|
+
seller: string;
|
|
2458
|
+
alias: string;
|
|
2459
|
+
price: bigint;
|
|
2460
|
+
/** Whether the listing is private (whitelist-only). */
|
|
2461
|
+
private: boolean;
|
|
2462
|
+
};
|
|
2463
|
+
/**
|
|
2464
|
+
* Emitted when an alias listing is cancelled before a sale.
|
|
2465
|
+
* Rust variant: `AliasSaleCancelled { seller, alias }`
|
|
2466
|
+
*/
|
|
2467
|
+
type AliasSaleCancelledEvent = {
|
|
2468
|
+
seller: string;
|
|
2469
|
+
alias: string;
|
|
2470
|
+
};
|
|
2471
|
+
/**
|
|
2472
|
+
* Emitted by `buy_alias()` when an alias is purchased.
|
|
2473
|
+
* Rust variant: `AliasSold { seller, buyer, alias, price }`
|
|
2474
|
+
*/
|
|
2475
|
+
type AliasSoldEvent = {
|
|
2476
|
+
seller: string;
|
|
2477
|
+
buyer: string;
|
|
2478
|
+
alias: string;
|
|
2479
|
+
price: bigint;
|
|
2480
|
+
};
|
|
2481
|
+
/**
|
|
2482
|
+
* Emitted by `add_chain_link()` when an external address is linked.
|
|
2483
|
+
* Rust variant: `ChainLinkAdded { account, chain_id, address }`
|
|
2484
|
+
*/
|
|
2485
|
+
type ChainLinkAddedEvent = {
|
|
2486
|
+
account: string;
|
|
2487
|
+
/** SLIP-0044 coin-type identifying the external chain. */
|
|
2488
|
+
chainId: number;
|
|
2489
|
+
/** Chain-specific address string. */
|
|
2490
|
+
address: string;
|
|
2491
|
+
};
|
|
2492
|
+
/**
|
|
2493
|
+
* Emitted by `remove_chain_link()` when an external address link is removed.
|
|
2494
|
+
* Rust variant: `ChainLinkRemoved { account, chain_id }`
|
|
2495
|
+
*/
|
|
2496
|
+
type ChainLinkRemovedEvent = {
|
|
2497
|
+
account: string;
|
|
2498
|
+
chainId: number;
|
|
2499
|
+
};
|
|
2500
|
+
/**
|
|
2501
|
+
* Emitted by `set_account_metadata()` when an account's metadata is updated.
|
|
2502
|
+
* Rust variant: `MetadataUpdated { account }`
|
|
2503
|
+
*/
|
|
2504
|
+
type MetadataUpdatedEvent = {
|
|
2505
|
+
account: string;
|
|
2506
|
+
};
|
|
2507
|
+
/**
|
|
2508
|
+
* Emitted by `add_supported_chain()` (governance) when a new chain type is whitelisted.
|
|
2509
|
+
* Rust variant: `SupportedChainAdded { chain_id, scheme }`
|
|
2510
|
+
*/
|
|
2511
|
+
type SupportedChainAddedEvent = {
|
|
2512
|
+
chainId: number;
|
|
2513
|
+
scheme: SignatureScheme;
|
|
2514
|
+
};
|
|
2515
|
+
/**
|
|
2516
|
+
* Emitted by `remove_supported_chain()` (governance) when a chain type is removed.
|
|
2517
|
+
* Rust variant: `SupportedChainRemoved { chain_id }`
|
|
2518
|
+
*/
|
|
2519
|
+
type SupportedChainRemovedEvent = {
|
|
2520
|
+
chainId: number;
|
|
2521
|
+
};
|
|
2522
|
+
/**
|
|
2523
|
+
* Emitted after a successful `dispatch_as_linked_account()` call.
|
|
2524
|
+
* Rust variant: `ProxyCallExecuted { owner, chain_id, address }`
|
|
2525
|
+
*/
|
|
2526
|
+
type ProxyCallExecutedEvent = {
|
|
2527
|
+
owner: string;
|
|
2528
|
+
chainId: number;
|
|
2529
|
+
address: string;
|
|
2530
|
+
};
|
|
2531
|
+
/**
|
|
2532
|
+
* Emitted by `register_private_link()` when a private (commitment-based) chain link is added.
|
|
2533
|
+
* Rust variant: `PrivateChainLinkAdded { account, chain_id, commitment }`
|
|
2534
|
+
*/
|
|
2535
|
+
type PrivateChainLinkAddedEvent = {
|
|
2536
|
+
account: string;
|
|
2537
|
+
chainId: number;
|
|
2538
|
+
/** 0x-prefixed 32-byte Poseidon commitment of the private link. */
|
|
2539
|
+
commitment: string;
|
|
2540
|
+
};
|
|
2541
|
+
/**
|
|
2542
|
+
* Emitted by `remove_private_link()` when a private chain link is removed.
|
|
2543
|
+
* Rust variant: `PrivateChainLinkRemoved { account, chain_id, commitment }`
|
|
2544
|
+
*/
|
|
2545
|
+
type PrivateChainLinkRemovedEvent = {
|
|
2546
|
+
account: string;
|
|
2547
|
+
chainId: number;
|
|
2548
|
+
/** 0x-prefixed 32-byte commitment. */
|
|
2549
|
+
commitment: string;
|
|
2550
|
+
};
|
|
2551
|
+
/**
|
|
2552
|
+
* Emitted by `reveal_private_link()` when a private link is publicly revealed.
|
|
2553
|
+
* Rust variant: `PrivateChainLinkRevealed { account, chain_id, address }`
|
|
2554
|
+
*/
|
|
2555
|
+
type PrivateChainLinkRevealedEvent = {
|
|
2556
|
+
account: string;
|
|
2557
|
+
chainId: number;
|
|
2558
|
+
/** The now-revealed external address. */
|
|
2559
|
+
address: string;
|
|
2560
|
+
};
|
|
2561
|
+
/**
|
|
2562
|
+
* Emitted after a successful `dispatch_as_private_link()` call.
|
|
2563
|
+
* Rust variant: `PrivateLinkDispatchExecuted { owner, commitment }`
|
|
2564
|
+
*/
|
|
2565
|
+
type PrivateLinkDispatchExecutedEvent = {
|
|
2566
|
+
owner: string;
|
|
2567
|
+
/** 0x-prefixed 32-byte commitment of the private link used. */
|
|
2568
|
+
commitment: string;
|
|
2569
|
+
};
|
|
2570
|
+
/** All events emitted by pallet-account-mapping as a discriminated union. */
|
|
2571
|
+
type AccountMappingEvent = {
|
|
2572
|
+
type: 'AccountMapped';
|
|
2573
|
+
data: AccountMappedEvent;
|
|
2574
|
+
} | {
|
|
2575
|
+
type: 'AccountUnmapped';
|
|
2576
|
+
data: AccountUnmappedEvent;
|
|
2577
|
+
} | {
|
|
2578
|
+
type: 'AliasRegistered';
|
|
2579
|
+
data: AliasRegisteredEvent;
|
|
2580
|
+
} | {
|
|
2581
|
+
type: 'AliasReleased';
|
|
2582
|
+
data: AliasReleasedEvent;
|
|
2583
|
+
} | {
|
|
2584
|
+
type: 'AliasTransferred';
|
|
2585
|
+
data: AliasTransferredEvent;
|
|
2586
|
+
} | {
|
|
2587
|
+
type: 'AliasListedForSale';
|
|
2588
|
+
data: AliasListedForSaleEvent;
|
|
2589
|
+
} | {
|
|
2590
|
+
type: 'AliasSaleCancelled';
|
|
2591
|
+
data: AliasSaleCancelledEvent;
|
|
2592
|
+
} | {
|
|
2593
|
+
type: 'AliasSold';
|
|
2594
|
+
data: AliasSoldEvent;
|
|
2595
|
+
} | {
|
|
2596
|
+
type: 'ChainLinkAdded';
|
|
2597
|
+
data: ChainLinkAddedEvent;
|
|
2598
|
+
} | {
|
|
2599
|
+
type: 'ChainLinkRemoved';
|
|
2600
|
+
data: ChainLinkRemovedEvent;
|
|
2601
|
+
} | {
|
|
2602
|
+
type: 'MetadataUpdated';
|
|
2603
|
+
data: MetadataUpdatedEvent;
|
|
2604
|
+
} | {
|
|
2605
|
+
type: 'SupportedChainAdded';
|
|
2606
|
+
data: SupportedChainAddedEvent;
|
|
2607
|
+
} | {
|
|
2608
|
+
type: 'SupportedChainRemoved';
|
|
2609
|
+
data: SupportedChainRemovedEvent;
|
|
2610
|
+
} | {
|
|
2611
|
+
type: 'ProxyCallExecuted';
|
|
2612
|
+
data: ProxyCallExecutedEvent;
|
|
2613
|
+
} | {
|
|
2614
|
+
type: 'PrivateChainLinkAdded';
|
|
2615
|
+
data: PrivateChainLinkAddedEvent;
|
|
2616
|
+
} | {
|
|
2617
|
+
type: 'PrivateChainLinkRemoved';
|
|
2618
|
+
data: PrivateChainLinkRemovedEvent;
|
|
2619
|
+
} | {
|
|
2620
|
+
type: 'PrivateChainLinkRevealed';
|
|
2621
|
+
data: PrivateChainLinkRevealedEvent;
|
|
2622
|
+
} | {
|
|
2623
|
+
type: 'PrivateLinkDispatchExecuted';
|
|
2624
|
+
data: PrivateLinkDispatchExecutedEvent;
|
|
1558
2625
|
};
|
|
1559
2626
|
|
|
1560
2627
|
/** Configuration for IndexerClient. */
|
|
@@ -1688,4 +2755,4 @@ declare class IndexerClient {
|
|
|
1688
2755
|
getLatestMerkleRoot(): Promise<MerkleRoot | null>;
|
|
1689
2756
|
}
|
|
1690
2757
|
|
|
1691
|
-
export { type AccountListing, AccountMappingModule, AccountMappingPrecompile, type AccountMetadata, type AddChainLinkParams, type AliasFullIdentity, type AliasInfo, type ChainInfo, type ChainLink, ChainModule, type CommitmentMerkleProof, CryptoPrecompiles, type DecryptedMemo, type DispatchAsLinkedParams, EncryptedMemo, EvmClient, type EvmSigner, type EvmTxRequest, type FullIdentityInfo, IndexerClient, type IndexerClientConfig, KNOWN_PRECOMPILES, type KnownPrecompileInfo, type ListingInfo, MerkleModule, type MerkleProof, type MerkleRoot, type MerkleRootUpdatedEvent, type MerkleTreeInfo, NoteBuilder, type NoteInput, type NullifierStatus, type NullifierStatusResult, OrbinumClient, type OrbinumClientConfig, PRECOMPILE_ADDR, type PaginatedResult, type PoolBalance, type PoolStats, PrivacyKeyManager, type PrivateLink, type PrivateTransfer, type PrivateTransferArgs, type PrivateTransferEvent, type PrivateTransferInput, type PrivateTransferOutput, type PrivateTransferParams, type PutOnSaleParams, type ResolvedAlias, SLIP0044_NAMESPACE, type ScanCommitment, type SetMetadataParams, type ShieldArgs, type ShieldParams, type ShieldResult, type ShieldedCommitment, type ShieldedEvent, type ShieldedPoolEvent, ShieldedPoolModule, ShieldedPoolPrecompile, type SignatureScheme, type SpentNullifier, SubstrateClient, type SupportedChain, type TransferInput, type TransferOutput, type TxResult, type Unshield, type UnshieldArgs, type UnshieldParams, type UnshieldedEvent, type ZkNote, accountIdHexToSs58, addressToAccountIdHex, bigintTo32Be, bigintTo32Le, bigintTo32LeArr, bytesToBigintLE, computePathIndices, decryptJson, deriveOwnerPk, deriveSpendingKeyFromSignature, deriveSpendingKeyMessage, deriveVaultKey, deriveViewingKey, encryptJson, ensureHexPrefix, evmAddressToAccountId, evmToImplicitSubstrate, evmToSubstrate, fromHex, getPrecompileLabel, implicitSubstrateToEvm, isEvmAddress, isImplicitEvmAccount, isSs58, isSubstrateAddress, isUnifiedAddress, leHexToBigint, normalizeEvmAddress, substrateSs58ToAccountIdHex, substrateToEvm, toHex, tryDecryptNote, vaultReplacer, vaultReviver };
|
|
2758
|
+
export { type AccountListing, type AccountMappedEvent, type AccountMappingCall, type AccountMappingEvent, AccountMappingModule, AccountMappingPrecompile, type AccountMetadata, type AccountUnmappedEvent, type ActiveVersionSetEvent, type AddChainLinkArgs, type AddChainLinkParams, type AddSupportedChainArgs, type AliasFullIdentity, type AliasInfo, type AliasListedForSaleEvent, type AliasRegisteredEvent, type AliasReleasedEvent, type AliasSaleCancelledEvent, type AliasSoldEvent, type AliasTransferredEvent, type AssetRegisteredEvent, type AssetUnverifiedEvent, type AssetVerifiedEvent, type AuditPolicySetEvent, type Auditor, type BatchDisclosureSubmission, type BatchRegisterVerificationKeysArgs, type BatchSubmitDisclosureProofsArgs, type BatchVerificationKeysRegisteredEvent, type BuyAliasArgs, type Bytes32, type ChainInfo, type ChainLink, type ChainLinkAddedEvent, type ChainLinkRemovedEvent, ChainModule, CircuitId, CircuitId as CircuitIdType, type CommitmentMerkleProof, CryptoPrecompiles, type DecryptedMemo, type DiscloseArgs, type DisclosedEvent, type DisclosureCondition, type DisclosurePublicSignals, type DisclosureRecordRevokedEvent, type DisclosureRejectedEvent, type DisclosureRequestExpiredEvent, type DisclosureRequestedEvent, type DispatchAsLinkedAccountArgs, type DispatchAsLinkedParams, type DispatchAsPrivateLinkArgs, EncryptedMemo, EvmClient, type EvmSigner, type EvmTxRequest, type FormatOptions, type FullIdentityInfo, IndexerClient, type IndexerClientConfig, KNOWN_PRECOMPILES, type KnownPrecompileInfo, type ListingInfo, MerkleModule, type MerkleProof, type MerkleRoot, type MerkleRootUpdatedEvent, type MerkleTreeInfo, type MetadataUpdatedEvent, NoteBuilder, type NoteInput, type NullifierStatus, type NullifierStatusResult, OrbinumClient, type OrbinumClientConfig, PRECOMPILE_ADDR, type PaginatedResult, type PoolBalance, type PoolStats, PrivacyKeyManager, type PrivateChainLinkAddedEvent, type PrivateChainLinkRemovedEvent, type PrivateChainLinkRevealedEvent, type PrivateLink, type PrivateLinkDispatchExecutedEvent, type PrivateTransfer, type PrivateTransferArgs, type PrivateTransferEvent, type PrivateTransferInput, type PrivateTransferOutput, type PrivateTransferParams, type ProofVerificationFailedEvent, type ProofVerifiedEvent, type ProxyCallExecutedEvent, type PruneExpiredRequestArgs, type PutAliasOnSaleArgs, type PutOnSaleParams, type RegisterAliasArgs, type RegisterAssetArgs, type RegisterPrivateLinkArgs, type RegisterVerificationKeyArgs, type RejectDisclosureArgs, type RemoveChainLinkArgs, type RemovePrivateLinkArgs, type RemoveSupportedChainArgs, type RemoveVerificationKeyArgs, type RequestDisclosureArgs, type ResolvedAlias, type RevealPrivateLinkArgs, type RevokeDisclosureRecordArgs, SLIP0044_NAMESPACE, type ScanCommitment, type SetAccountMetadataArgs, type SetActiveVersionArgs, type SetAuditPolicyArgs, type SetMetadataParams, type ShieldArgs, type ShieldBatchArgs, type ShieldOperation, type ShieldParams, type ShieldResult, type ShieldedCommitment, type ShieldedEvent, type ShieldedPoolCall, type ShieldedPoolEvent, ShieldedPoolModule, ShieldedPoolPrecompile, type SignatureScheme$1 as SignatureScheme, type SpentNullifier, SubstrateClient, type SupportedChain, type SupportedChainAddedEvent, type SupportedChainRemovedEvent, type TransferAliasArgs, type TransferInput, type TransferOutput, type TxResult, type Unshield, type UnshieldArgs, type UnshieldParams, type UnshieldedEvent, type UnverifyAssetArgs, type VerificationKeyRegisteredEvent, type VerificationKeyRemovedEvent, type VerifyAssetArgs, type VerifyProofArgs, type VkEntry, type ZkNote, type ZkVerifierCall, type ZkVerifierEvent, accountIdHexToSs58, addressToAccountIdHex, bigintTo32Be, bigintTo32Le, bigintTo32LeArr, bytesToBigintLE, computePathIndices, decryptJson, deriveOwnerPk, deriveSpendingKeyFromSignature, deriveSpendingKeyMessage, deriveVaultKey, deriveViewingKey, encryptJson, ensureHexPrefix, evmAddressToAccountId, evmToImplicitSubstrate, evmToSubstrate, formatBalance, formatORB, fromHex, getPrecompileLabel, implicitSubstrateToEvm, isEvmAddress, isImplicitEvmAccount, isSs58, isSubstrateAddress, isUnifiedAddress, leHexToBigint, normalizeEvmAddress, substrateSs58ToAccountIdHex, substrateToEvm, toHex, tryDecryptNote, vaultReplacer, vaultReviver };
|