@umbra-privacy/sdk 1.0.0 → 2.0.1
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/README.md +104 -25
- package/dist/{addresses-Brzgurv_.d.ts → addresses-B7HybtbJ.d.ts} +2 -1
- package/dist/{addresses-D_0YAS6B.d.cts → addresses-CTVY1oi7.d.cts} +2 -1
- package/dist/arcium-BXXlryfe.d.cts +20 -0
- package/dist/arcium-BXXlryfe.d.ts +20 -0
- package/dist/chunk-3LS5P32X.cjs +10892 -0
- package/dist/chunk-3LS5P32X.cjs.map +1 -0
- package/dist/chunk-4RHXVBNI.js +203 -0
- package/dist/chunk-4RHXVBNI.js.map +1 -0
- package/dist/chunk-4TZVXB5G.js +324 -0
- package/dist/chunk-4TZVXB5G.js.map +1 -0
- package/dist/chunk-5GUSMQ74.cjs +549 -0
- package/dist/chunk-5GUSMQ74.cjs.map +1 -0
- package/dist/chunk-5KPQXPQM.js +36 -0
- package/dist/chunk-5KPQXPQM.js.map +1 -0
- package/dist/chunk-AXD7LXYY.cjs +405 -0
- package/dist/chunk-AXD7LXYY.cjs.map +1 -0
- package/dist/{chunk-HOEXDXRC.cjs → chunk-BL6WXLPV.cjs} +32 -360
- package/dist/chunk-BL6WXLPV.cjs.map +1 -0
- package/dist/chunk-CFFLOE7D.cjs +598 -0
- package/dist/chunk-CFFLOE7D.cjs.map +1 -0
- package/dist/{chunk-BM7N6N7E.js → chunk-CFTW5WNG.js} +3 -325
- package/dist/chunk-CFTW5WNG.js.map +1 -0
- package/dist/chunk-DD2WCK4C.js +327 -0
- package/dist/chunk-DD2WCK4C.js.map +1 -0
- package/dist/chunk-DMPMQ74B.cjs +246 -0
- package/dist/chunk-DMPMQ74B.cjs.map +1 -0
- package/dist/{chunk-2Q75CQQJ.js → chunk-EEKF4553.js} +2 -2
- package/dist/chunk-EEKF4553.js.map +1 -0
- package/dist/chunk-ENVYYEM4.cjs +113 -0
- package/dist/chunk-ENVYYEM4.cjs.map +1 -0
- package/dist/chunk-FQX6ZYGJ.js +500 -0
- package/dist/chunk-FQX6ZYGJ.js.map +1 -0
- package/dist/chunk-FSK2ICMB.cjs +39 -0
- package/dist/chunk-FSK2ICMB.cjs.map +1 -0
- package/dist/chunk-FZYWLQAF.cjs +355 -0
- package/dist/chunk-FZYWLQAF.cjs.map +1 -0
- package/dist/chunk-GP26R377.js +436 -0
- package/dist/chunk-GP26R377.js.map +1 -0
- package/dist/chunk-HA5FLM63.js +393 -0
- package/dist/chunk-HA5FLM63.js.map +1 -0
- package/dist/chunk-INJ73LXQ.js +1107 -0
- package/dist/chunk-INJ73LXQ.js.map +1 -0
- package/dist/chunk-KMRROOME.js +10750 -0
- package/dist/chunk-KMRROOME.js.map +1 -0
- package/dist/{chunk-MDFSBU5W.cjs → chunk-LTCKPTZC.cjs} +2 -351
- package/dist/chunk-LTCKPTZC.cjs.map +1 -0
- package/dist/chunk-MKNCBUFA.js +564 -0
- package/dist/chunk-MKNCBUFA.js.map +1 -0
- package/dist/chunk-NKVMSABR.cjs +207 -0
- package/dist/chunk-NKVMSABR.cjs.map +1 -0
- package/dist/chunk-OFDWNWCL.js +70 -0
- package/dist/chunk-OFDWNWCL.js.map +1 -0
- package/dist/chunk-QJAUUYZU.cjs +331 -0
- package/dist/chunk-QJAUUYZU.cjs.map +1 -0
- package/dist/chunk-TLR7A64G.js +103 -0
- package/dist/chunk-TLR7A64G.js.map +1 -0
- package/dist/{chunk-MVKTV3FT.cjs → chunk-TQQZGNOI.cjs} +2 -2
- package/dist/chunk-TQQZGNOI.cjs.map +1 -0
- package/dist/chunk-UOFYS6M3.js +219 -0
- package/dist/chunk-UOFYS6M3.js.map +1 -0
- package/dist/chunk-UXMQI6B7.js +2406 -0
- package/dist/chunk-UXMQI6B7.js.map +1 -0
- package/dist/chunk-WN75ORDT.js +571 -0
- package/dist/chunk-WN75ORDT.js.map +1 -0
- package/dist/chunk-Y55PYKXH.cjs +595 -0
- package/dist/chunk-Y55PYKXH.cjs.map +1 -0
- package/dist/chunk-YEZBTYCP.cjs +77 -0
- package/dist/chunk-YEZBTYCP.cjs.map +1 -0
- package/dist/chunk-ZQOIYCGA.cjs +1126 -0
- package/dist/chunk-ZQOIYCGA.cjs.map +1 -0
- package/dist/chunk-ZY3TSHMJ.cjs +2665 -0
- package/dist/chunk-ZY3TSHMJ.cjs.map +1 -0
- package/dist/client-DkVBHMWb.d.cts +2613 -0
- package/dist/client-V4AF6Bz9.d.ts +2613 -0
- package/dist/common/pda/index.cjs +145 -0
- package/dist/common/pda/index.cjs.map +1 -0
- package/dist/common/pda/index.d.cts +1250 -0
- package/dist/common/pda/index.d.ts +1250 -0
- package/dist/common/pda/index.js +8 -0
- package/dist/common/pda/index.js.map +1 -0
- package/dist/constants/index.cjs +38 -164
- package/dist/constants/index.cjs.map +1 -1
- package/dist/constants/index.d.cts +8 -425
- package/dist/constants/index.d.ts +8 -425
- package/dist/constants/index.js +15 -124
- package/dist/constants/index.js.map +1 -1
- package/dist/crypto/index.cjs +583 -0
- package/dist/crypto/index.cjs.map +1 -0
- package/dist/crypto/index.d.cts +6731 -0
- package/dist/crypto/index.d.ts +6731 -0
- package/dist/crypto/index.js +14 -0
- package/dist/crypto/index.js.map +1 -0
- package/dist/{cryptography-BTGC72u-.d.ts → cryptography-BFSJcvi6.d.ts} +3 -2465
- package/dist/{cryptography-BTGC72u-.d.cts → cryptography-D6tPDh-Y.d.cts} +3 -2465
- package/dist/errors/index.cjs +64 -54
- package/dist/errors/index.d.cts +7 -797
- package/dist/errors/index.d.ts +7 -797
- package/dist/errors/index.js +3 -1
- package/dist/errors-B9EoPeWV.d.cts +593 -0
- package/dist/errors-B9EoPeWV.d.ts +593 -0
- package/dist/errors-DAIrstEL.d.cts +300 -0
- package/dist/errors-DPNMfyh0.d.ts +300 -0
- package/dist/index-BG0yjL7C.d.cts +6006 -0
- package/dist/index-ByynoyBO.d.ts +6006 -0
- package/dist/index.cjs +5133 -16116
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1031 -7685
- package/dist/index.d.ts +1031 -7685
- package/dist/index.js +3228 -14905
- package/dist/index.js.map +1 -1
- package/dist/interfaces/index.d.cts +14 -6
- package/dist/interfaces/index.d.ts +14 -6
- package/dist/interfaces-43cReBcS.d.cts +3346 -0
- package/dist/interfaces-B8xKNl_6.d.ts +997 -0
- package/dist/interfaces-D2NO6kDD.d.cts +997 -0
- package/dist/interfaces-z_xYJlgV.d.ts +3346 -0
- package/dist/math/index.cjs +115 -0
- package/dist/math/index.cjs.map +1 -0
- package/dist/math/index.d.cts +1327 -0
- package/dist/math/index.d.ts +1327 -0
- package/dist/math/index.js +10 -0
- package/dist/math/index.js.map +1 -0
- package/dist/networks-RMd3abPE.d.ts +44 -0
- package/dist/networks-yAoO8peQ.d.cts +44 -0
- package/dist/relayer-NRRMSMNB.js +4 -0
- package/dist/relayer-NRRMSMNB.js.map +1 -0
- package/dist/relayer-RJHEIXJG.cjs +21 -0
- package/dist/relayer-RJHEIXJG.cjs.map +1 -0
- package/dist/solana/index.cjs +56 -0
- package/dist/solana/index.cjs.map +1 -0
- package/dist/solana/index.d.cts +105 -0
- package/dist/solana/index.d.ts +105 -0
- package/dist/solana/index.js +7 -0
- package/dist/solana/index.js.map +1 -0
- package/dist/{index-CLj_zWSD.d.ts → temporal-BbRaEPoO.d.ts} +1 -1
- package/dist/{index-CX6_pIRS.d.cts → temporal-oUj7iCaq.d.cts} +1 -1
- package/dist/transaction-forwarder-5mAMTjw6.d.ts +1155 -0
- package/dist/transaction-forwarder-C6gMUG7a.d.cts +1155 -0
- package/dist/types/index.cjs +232 -231
- package/dist/types/index.d.cts +15 -1485
- package/dist/types/index.d.ts +15 -1485
- package/dist/types/index.js +2 -1
- package/dist/types-BohhvPth.d.cts +87 -0
- package/dist/types-CW0oTT0j.d.ts +87 -0
- package/dist/types-C_V_CaKK.d.cts +2468 -0
- package/dist/types-C_V_CaKK.d.ts +2468 -0
- package/dist/types-Ca7frykr.d.ts +793 -0
- package/dist/types-CuKeoI19.d.cts +1296 -0
- package/dist/types-CxfTIpN9.d.ts +1052 -0
- package/dist/{types-n-sHFcgr.d.ts → types-D1jDUjfN.d.ts} +2 -2
- package/dist/types-DKEDUlH9.d.ts +1296 -0
- package/dist/types-EKuIfxTz.d.cts +1052 -0
- package/dist/{types-BBuELtY8.d.cts → types-IMGYmlv-.d.cts} +2 -2
- package/dist/types-PwNLi_2k.d.cts +793 -0
- package/dist/utils/index.cjs +823 -525
- package/dist/utils/index.d.cts +1711 -4021
- package/dist/utils/index.d.ts +1711 -4021
- package/dist/utils/index.js +9 -3
- package/dist/{versions-D9PqsEvj.d.cts → versions-BRlR36EA.d.cts} +1 -0
- package/dist/{versions-D9PqsEvj.d.ts → versions-BRlR36EA.d.ts} +1 -0
- package/package.json +79 -18
- package/dist/chunk-2Q75CQQJ.js.map +0 -1
- package/dist/chunk-BM7N6N7E.js.map +0 -1
- package/dist/chunk-GXKSUB2U.cjs +0 -4416
- package/dist/chunk-GXKSUB2U.cjs.map +0 -1
- package/dist/chunk-HOEXDXRC.cjs.map +0 -1
- package/dist/chunk-MDFSBU5W.cjs.map +0 -1
- package/dist/chunk-MQY7HDIA.js +0 -600
- package/dist/chunk-MQY7HDIA.js.map +0 -1
- package/dist/chunk-MVKTV3FT.cjs.map +0 -1
- package/dist/chunk-PG2J6V6Y.js +0 -4094
- package/dist/chunk-PG2J6V6Y.js.map +0 -1
- package/dist/chunk-VEGLTTYQ.cjs +0 -621
- package/dist/chunk-VEGLTTYQ.cjs.map +0 -1
- package/dist/chunk-WVHQ46DD.js +0 -758
- package/dist/chunk-WVHQ46DD.js.map +0 -1
- package/dist/index-B9pDY73x.d.ts +0 -12933
- package/dist/index-D33yo0qB.d.cts +0 -12933
- package/dist/networks-C-orpSFW.d.ts +0 -65
- package/dist/networks-FxYERGD1.d.cts +0 -65
package/README.md
CHANGED
|
@@ -12,23 +12,23 @@ pnpm add @umbra-privacy/sdk
|
|
|
12
12
|
|
|
13
13
|
```typescript
|
|
14
14
|
import {
|
|
15
|
-
|
|
16
|
-
|
|
15
|
+
getInMemorySigner,
|
|
16
|
+
getUmbraClient,
|
|
17
17
|
getUserRegistrationFunction,
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
getPublicBalanceToEncryptedBalanceDirectDepositorFunction,
|
|
19
|
+
getEncryptedBalanceToPublicBalanceDirectWithdrawerFunction,
|
|
20
20
|
} from "@umbra-privacy/sdk";
|
|
21
21
|
|
|
22
22
|
// 1. Create a signer (use a wallet adapter in production)
|
|
23
|
-
const signer = await
|
|
23
|
+
const signer = await getInMemorySigner();
|
|
24
24
|
|
|
25
25
|
// 2. Create the Umbra client
|
|
26
|
-
const client = await
|
|
26
|
+
const client = await getUmbraClient({
|
|
27
27
|
signer,
|
|
28
28
|
network: "mainnet",
|
|
29
29
|
rpcUrl: "https://api.mainnet-beta.solana.com",
|
|
30
30
|
rpcSubscriptionsUrl: "wss://api.mainnet-beta.solana.com",
|
|
31
|
-
indexerApiEndpoint: "https://
|
|
31
|
+
indexerApiEndpoint: "https://indexer.umbraprivacy.com",
|
|
32
32
|
});
|
|
33
33
|
|
|
34
34
|
// 3. Register (idempotent — safe to call even if already registered)
|
|
@@ -36,13 +36,13 @@ const register = getUserRegistrationFunction({ client });
|
|
|
36
36
|
await register({ confidential: true, anonymous: true });
|
|
37
37
|
|
|
38
38
|
// 4. Deposit tokens into an encrypted balance
|
|
39
|
-
const deposit =
|
|
40
|
-
const
|
|
41
|
-
await deposit(signer.address,
|
|
39
|
+
const deposit = getPublicBalanceToEncryptedBalanceDirectDepositorFunction({ client });
|
|
40
|
+
const USDC = "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v";
|
|
41
|
+
await deposit(signer.address, USDC, 1_000_000n);
|
|
42
42
|
|
|
43
43
|
// 5. Withdraw back to public wallet
|
|
44
|
-
const withdraw =
|
|
45
|
-
await withdraw(signer.address,
|
|
44
|
+
const withdraw = getEncryptedBalanceToPublicBalanceDirectWithdrawerFunction({ client });
|
|
45
|
+
await withdraw(signer.address, USDC, 1_000_000n);
|
|
46
46
|
```
|
|
47
47
|
|
|
48
48
|
## Features
|
|
@@ -58,9 +58,12 @@ await withdraw(signer.address, MINT, 1_000_000n);
|
|
|
58
58
|
The SDK provides granular subpath exports to keep bundle sizes small:
|
|
59
59
|
|
|
60
60
|
- `@umbra-privacy/sdk` — Client construction, service factories, cryptographic operations
|
|
61
|
+
- `@umbra-privacy/sdk/crypto` — Rescue cipher, Poseidon hash, AES, key derivation, Fiat-Shamir challenges
|
|
62
|
+
- `@umbra-privacy/sdk/pda` — Program Derived Address derivation for all Umbra and Arcium accounts
|
|
63
|
+
- `@umbra-privacy/sdk/solana` — RPC providers, signers, transaction forwarding
|
|
64
|
+
- `@umbra-privacy/sdk/math` — BN254 and Curve25519 field arithmetic
|
|
61
65
|
- `@umbra-privacy/sdk/types` — Branded types and assertion functions (`assertU64`, `assertAddress`, etc.)
|
|
62
66
|
- `@umbra-privacy/sdk/interfaces` — Function type signatures for all factory functions and dependencies
|
|
63
|
-
- `@umbra-privacy/sdk/utils` — Converter utilities, PDA derivation helpers, address utilities
|
|
64
67
|
- `@umbra-privacy/sdk/constants` — Network configs, program IDs, domain separators
|
|
65
68
|
- `@umbra-privacy/sdk/errors` — Error classes, stage enums, and type guards
|
|
66
69
|
|
|
@@ -69,10 +72,10 @@ The SDK provides granular subpath exports to keep bundle sizes small:
|
|
|
69
72
|
Every SDK operation follows the same two-step pattern:
|
|
70
73
|
|
|
71
74
|
```typescript
|
|
72
|
-
// Build the function once (captures client config and optional dependency overrides)
|
|
75
|
+
// Step 1: Build the function once (captures client config and optional dependency overrides)
|
|
73
76
|
const operation = getOperationFunction({ client }, optionalDeps);
|
|
74
77
|
|
|
75
|
-
// Call it at runtime
|
|
78
|
+
// Step 2: Call it at runtime (can be called many times with different args)
|
|
76
79
|
const result = await operation(/* runtime arguments */);
|
|
77
80
|
```
|
|
78
81
|
|
|
@@ -80,15 +83,91 @@ The optional `deps` argument accepts injectable overrides for RPC providers, key
|
|
|
80
83
|
|
|
81
84
|
## Available Services
|
|
82
85
|
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
- **
|
|
86
|
-
- **
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
-
|
|
91
|
-
-
|
|
86
|
+
### Token Flow (Source → Destination → Action)
|
|
87
|
+
|
|
88
|
+
- **Direct Deposit** — `getPublicBalanceToEncryptedBalanceDirectDepositorFunction` — Move tokens from public wallet into encrypted balance
|
|
89
|
+
- **Direct Withdraw** — `getEncryptedBalanceToPublicBalanceDirectWithdrawerFunction` — Move tokens from encrypted balance to public wallet
|
|
90
|
+
|
|
91
|
+
### UTXO Creation (Stealth Pool Deposits)
|
|
92
|
+
|
|
93
|
+
- `getPublicBalanceToSelfClaimableUtxoCreatorFunction` — Shield your own public tokens into the mixer
|
|
94
|
+
- `getEncryptedBalanceToSelfClaimableUtxoCreatorFunction` — Shield your own encrypted tokens into the mixer
|
|
95
|
+
- `getPublicBalanceToReceiverClaimableUtxoCreatorFunction` — Send public tokens to a receiver via the mixer
|
|
96
|
+
- `getEncryptedBalanceToReceiverClaimableUtxoCreatorFunction` — Send encrypted tokens to a receiver via the mixer
|
|
97
|
+
|
|
98
|
+
### UTXO Scanning & Claiming
|
|
99
|
+
|
|
100
|
+
- `getClaimableUtxoScannerFunction` — Scan Merkle trees for UTXOs addressed to your keys
|
|
101
|
+
- `getSelfClaimableUtxoToEncryptedBalanceClaimerFunction` — Claim your own UTXO into encrypted balance
|
|
102
|
+
- `getSelfClaimableUtxoToPublicBalanceClaimerFunction` — Claim your own UTXO into public wallet
|
|
103
|
+
- `getReceiverClaimableUtxoToEncryptedBalanceClaimerFunction` — Claim a received UTXO into encrypted balance
|
|
104
|
+
|
|
105
|
+
### User Account Management
|
|
106
|
+
|
|
107
|
+
- `getUserRegistrationFunction` — Account init, X25519 key registration, anonymous usage setup
|
|
108
|
+
- `getUserEncryptionKeyRotatorFunction` — Rotate user account X25519 encryption key
|
|
109
|
+
- `getMasterViewingKeyRotatorFunction` — Rotate master viewing key
|
|
110
|
+
- `getUserEntropySeedRotatorFunction` — Rotate user-level entropy seed
|
|
111
|
+
- `getTokenEntropySeedRotatorFunction` — Rotate per-token entropy seed
|
|
112
|
+
- `getStagedSolRecovererFunction` — Recover SOL stuck from failed MPC callbacks
|
|
113
|
+
- `getStagedSplRecovererFunction` — Recover SPL tokens stuck from failed MPC callbacks
|
|
114
|
+
|
|
115
|
+
### Query
|
|
116
|
+
|
|
117
|
+
- `getUserAccountQuerierFunction` — Read user account state
|
|
118
|
+
- `getEncryptedBalanceQuerierFunction` — Read and decrypt encrypted token balance
|
|
119
|
+
|
|
120
|
+
### Conversion
|
|
121
|
+
|
|
122
|
+
- `getNetworkEncryptionToSharedEncryptionConverterFunction` — Convert from network-only to shared encryption mode
|
|
123
|
+
- `getMintEncryptionKeyRotatorFunction` — Rotate per-mint encryption key
|
|
124
|
+
|
|
125
|
+
### Compliance
|
|
126
|
+
|
|
127
|
+
- `getComplianceGrantIssuerFunction` — Authorize an auditor to view encrypted data
|
|
128
|
+
- `getComplianceGrantRevokerFunction` — Revoke auditor access
|
|
129
|
+
- `getSharedCiphertextReencryptorForUserGrantFunction` — Re-encrypt shared balance for a user-granted auditor
|
|
130
|
+
- `getNetworkCiphertextReencryptorForNetworkGrantFunction` — Re-encrypt network balance for a network-granted auditor
|
|
131
|
+
- `getSharedCiphertextReencryptorForNetworkGrantFunction` — Re-encrypt shared balance for a network-granted auditor
|
|
132
|
+
|
|
133
|
+
## PDA Derivation
|
|
134
|
+
|
|
135
|
+
All Program Derived Address functions use the `find*Pda` convention:
|
|
136
|
+
|
|
137
|
+
```typescript
|
|
138
|
+
import {
|
|
139
|
+
findEncryptedTokenAccountPda,
|
|
140
|
+
findStealthPoolPda,
|
|
141
|
+
findNullifierSetPdas,
|
|
142
|
+
} from "@umbra-privacy/sdk/pda";
|
|
143
|
+
|
|
144
|
+
const tokenAccountPda = await findEncryptedTokenAccountPda(userAddress, mintAddress, programId);
|
|
145
|
+
const stealthPoolPda = await findStealthPoolPda(treeIndex, programId);
|
|
146
|
+
const nullifierPdas = await findNullifierSetPdas(treeIndex, programId);
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
## Cryptography
|
|
150
|
+
|
|
151
|
+
```typescript
|
|
152
|
+
import {
|
|
153
|
+
getRescueEncryptorFromPrivateKey,
|
|
154
|
+
getRescueDecryptorFromPrivateKey,
|
|
155
|
+
getPoseidonHasher,
|
|
156
|
+
getMasterViewingKeyDeriver,
|
|
157
|
+
} from "@umbra-privacy/sdk/crypto";
|
|
158
|
+
|
|
159
|
+
// Rescue cipher encryption
|
|
160
|
+
const encryptor = getRescueEncryptorFromPrivateKey(privateKey);
|
|
161
|
+
const { ciphertexts, nonce } = await encryptor([plaintext]);
|
|
162
|
+
|
|
163
|
+
// Poseidon hashing
|
|
164
|
+
const hasher = getPoseidonHasher();
|
|
165
|
+
const hash = hasher([input1, input2]);
|
|
166
|
+
|
|
167
|
+
// Key derivation
|
|
168
|
+
const deriveMvk = getMasterViewingKeyDeriver({ client });
|
|
169
|
+
const masterViewingKey = await deriveMvk();
|
|
170
|
+
```
|
|
92
171
|
|
|
93
172
|
## ZK Provers
|
|
94
173
|
|
|
@@ -102,7 +181,7 @@ pnpm add @umbra-privacy/web-zk-prover
|
|
|
102
181
|
import { getCreateReceiverClaimableUtxoFromPublicBalanceProver } from "@umbra-privacy/web-zk-prover";
|
|
103
182
|
|
|
104
183
|
const zkProver = getCreateReceiverClaimableUtxoFromPublicBalanceProver();
|
|
105
|
-
const createUtxo =
|
|
184
|
+
const createUtxo = getPublicBalanceToReceiverClaimableUtxoCreatorFunction(
|
|
106
185
|
{ client },
|
|
107
186
|
{ zkProver },
|
|
108
187
|
);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Address } from '@solana/kit';
|
|
2
|
-
import { U as U128 } from './
|
|
2
|
+
import { U as U128 } from './types-C_V_CaKK.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Address Utilities
|
|
@@ -34,6 +34,7 @@ import { U as U128 } from './cryptography-BTGC72u-.js';
|
|
|
34
34
|
* Poseidon hash calls, and the TypeScript SDK.
|
|
35
35
|
*
|
|
36
36
|
* @packageDocumentation
|
|
37
|
+
* @since 2.0.0
|
|
37
38
|
* @module utils/miscellaneous/addresses
|
|
38
39
|
*/
|
|
39
40
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Address } from '@solana/kit';
|
|
2
|
-
import { U as U128 } from './
|
|
2
|
+
import { U as U128 } from './types-C_V_CaKK.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Address Utilities
|
|
@@ -34,6 +34,7 @@ import { U as U128 } from './cryptography-BTGC72u-.cjs';
|
|
|
34
34
|
* Poseidon hash calls, and the TypeScript SDK.
|
|
35
35
|
*
|
|
36
36
|
* @packageDocumentation
|
|
37
|
+
* @since 2.0.0
|
|
37
38
|
* @module utils/miscellaneous/addresses
|
|
38
39
|
*/
|
|
39
40
|
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Arcium Protocol Types
|
|
3
|
+
*
|
|
4
|
+
* Branded types for Arcium-specific protocol values.
|
|
5
|
+
*
|
|
6
|
+
* @since 2.0.0
|
|
7
|
+
* @module types/arcium
|
|
8
|
+
*/
|
|
9
|
+
/**
|
|
10
|
+
* Micro-lamports per Arcium Computation Unit.
|
|
11
|
+
*
|
|
12
|
+
* This is a branded bigint representing the price a user is willing to pay
|
|
13
|
+
* per ACU of Arcium computation. The value is passed directly to the on-chain
|
|
14
|
+
* `priorityFees` instruction field.
|
|
15
|
+
*/
|
|
16
|
+
type MicroLamportsPerAcu = bigint & {
|
|
17
|
+
readonly __brand: "MicroLamportsPerAcu";
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export type { MicroLamportsPerAcu as M };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Arcium Protocol Types
|
|
3
|
+
*
|
|
4
|
+
* Branded types for Arcium-specific protocol values.
|
|
5
|
+
*
|
|
6
|
+
* @since 2.0.0
|
|
7
|
+
* @module types/arcium
|
|
8
|
+
*/
|
|
9
|
+
/**
|
|
10
|
+
* Micro-lamports per Arcium Computation Unit.
|
|
11
|
+
*
|
|
12
|
+
* This is a branded bigint representing the price a user is willing to pay
|
|
13
|
+
* per ACU of Arcium computation. The value is passed directly to the on-chain
|
|
14
|
+
* `priorityFees` instruction field.
|
|
15
|
+
*/
|
|
16
|
+
type MicroLamportsPerAcu = bigint & {
|
|
17
|
+
readonly __brand: "MicroLamportsPerAcu";
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export type { MicroLamportsPerAcu as M };
|