@shroud-fi/transport 0.1.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.
Files changed (79) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +55 -0
  3. package/dist/cjs/abis.d.ts +446 -0
  4. package/dist/cjs/abis.d.ts.map +1 -0
  5. package/dist/cjs/abis.js +287 -0
  6. package/dist/cjs/abis.js.map +1 -0
  7. package/dist/cjs/addresses.d.ts +38 -0
  8. package/dist/cjs/addresses.d.ts.map +1 -0
  9. package/dist/cjs/addresses.js +43 -0
  10. package/dist/cjs/addresses.js.map +1 -0
  11. package/dist/cjs/chains.d.ts +2 -0
  12. package/dist/cjs/chains.d.ts.map +1 -0
  13. package/dist/cjs/chains.js +7 -0
  14. package/dist/cjs/chains.js.map +1 -0
  15. package/dist/cjs/create.d.ts +3 -0
  16. package/dist/cjs/create.d.ts.map +1 -0
  17. package/dist/cjs/create.js +18 -0
  18. package/dist/cjs/create.js.map +1 -0
  19. package/dist/cjs/deployments-helpers.d.ts +54 -0
  20. package/dist/cjs/deployments-helpers.d.ts.map +1 -0
  21. package/dist/cjs/deployments-helpers.js +99 -0
  22. package/dist/cjs/deployments-helpers.js.map +1 -0
  23. package/dist/cjs/deployments.d.ts +35 -0
  24. package/dist/cjs/deployments.d.ts.map +1 -0
  25. package/dist/cjs/deployments.js +78 -0
  26. package/dist/cjs/deployments.js.map +1 -0
  27. package/dist/cjs/errors.d.ts +9 -0
  28. package/dist/cjs/errors.d.ts.map +1 -0
  29. package/dist/cjs/errors.js +18 -0
  30. package/dist/cjs/errors.js.map +1 -0
  31. package/dist/cjs/index.d.ts +10 -0
  32. package/dist/cjs/index.d.ts.map +1 -0
  33. package/dist/cjs/index.js +45 -0
  34. package/dist/cjs/index.js.map +1 -0
  35. package/dist/cjs/package.json +1 -0
  36. package/dist/cjs/types.d.ts +17 -0
  37. package/dist/cjs/types.d.ts.map +1 -0
  38. package/dist/cjs/types.js +3 -0
  39. package/dist/cjs/types.js.map +1 -0
  40. package/dist/esm/abis.d.ts +446 -0
  41. package/dist/esm/abis.d.ts.map +1 -0
  42. package/dist/esm/abis.js +284 -0
  43. package/dist/esm/abis.js.map +1 -0
  44. package/dist/esm/addresses.d.ts +38 -0
  45. package/dist/esm/addresses.d.ts.map +1 -0
  46. package/dist/esm/addresses.js +40 -0
  47. package/dist/esm/addresses.js.map +1 -0
  48. package/dist/esm/chains.d.ts +2 -0
  49. package/dist/esm/chains.d.ts.map +1 -0
  50. package/dist/esm/chains.js +2 -0
  51. package/dist/esm/chains.js.map +1 -0
  52. package/dist/esm/create.d.ts +3 -0
  53. package/dist/esm/create.d.ts.map +1 -0
  54. package/dist/esm/create.js +15 -0
  55. package/dist/esm/create.js.map +1 -0
  56. package/dist/esm/deployments-helpers.d.ts +54 -0
  57. package/dist/esm/deployments-helpers.d.ts.map +1 -0
  58. package/dist/esm/deployments-helpers.js +85 -0
  59. package/dist/esm/deployments-helpers.js.map +1 -0
  60. package/dist/esm/deployments.d.ts +35 -0
  61. package/dist/esm/deployments.d.ts.map +1 -0
  62. package/dist/esm/deployments.js +75 -0
  63. package/dist/esm/deployments.js.map +1 -0
  64. package/dist/esm/errors.d.ts +9 -0
  65. package/dist/esm/errors.d.ts.map +1 -0
  66. package/dist/esm/errors.js +13 -0
  67. package/dist/esm/errors.js.map +1 -0
  68. package/dist/esm/index.d.ts +10 -0
  69. package/dist/esm/index.d.ts.map +1 -0
  70. package/dist/esm/index.js +8 -0
  71. package/dist/esm/index.js.map +1 -0
  72. package/dist/esm/types.d.ts +17 -0
  73. package/dist/esm/types.d.ts.map +1 -0
  74. package/dist/esm/types.js +2 -0
  75. package/dist/esm/types.js.map +1 -0
  76. package/dist/tsconfig.cjs.tsbuildinfo +1 -0
  77. package/dist/tsconfig.esm.tsbuildinfo +1 -0
  78. package/dist/tsconfig.tsbuildinfo +1 -0
  79. package/package.json +55 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"abis.d.ts","sourceRoot":"","sources":["../../src/abis.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAwBtB,CAAC;AAEX,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA2DrB,CAAC;AAEX;;;;;;;;GAQG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAoCvB,CAAC;AAEX,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAsCX,CAAC;AAEX,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmFrB,CAAC;AAEX,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4BrB,CAAC"}
@@ -0,0 +1,284 @@
1
+ export const ERC5564AnnouncerAbi = [
2
+ {
3
+ type: 'function',
4
+ name: 'announce',
5
+ inputs: [
6
+ { name: 'schemeId', type: 'uint256' },
7
+ { name: 'stealthAddress', type: 'address' },
8
+ { name: 'ephemeralPubKey', type: 'bytes' },
9
+ { name: 'metadata', type: 'bytes' },
10
+ ],
11
+ outputs: [],
12
+ stateMutability: 'nonpayable',
13
+ },
14
+ {
15
+ type: 'event',
16
+ name: 'Announcement',
17
+ inputs: [
18
+ { name: 'schemeId', type: 'uint256', indexed: true },
19
+ { name: 'stealthAddress', type: 'address', indexed: true },
20
+ { name: 'caller', type: 'address', indexed: true },
21
+ { name: 'ephemeralPubKey', type: 'bytes', indexed: false },
22
+ { name: 'metadata', type: 'bytes', indexed: false },
23
+ ],
24
+ },
25
+ ];
26
+ export const ShroudFiStealthAbi = [
27
+ {
28
+ type: 'function',
29
+ name: 'sendETH',
30
+ inputs: [
31
+ { name: 'stealthAddress', type: 'address' },
32
+ { name: 'ephemeralPubKey', type: 'bytes' },
33
+ { name: 'viewTag', type: 'bytes1' },
34
+ ],
35
+ outputs: [],
36
+ stateMutability: 'payable',
37
+ },
38
+ {
39
+ type: 'function',
40
+ name: 'sendERC20',
41
+ inputs: [
42
+ { name: 'stealthAddress', type: 'address' },
43
+ { name: 'token', type: 'address' },
44
+ { name: 'amount', type: 'uint256' },
45
+ { name: 'ephemeralPubKey', type: 'bytes' },
46
+ { name: 'viewTag', type: 'bytes1' },
47
+ ],
48
+ outputs: [],
49
+ stateMutability: 'nonpayable',
50
+ },
51
+ {
52
+ type: 'function',
53
+ name: 'ANNOUNCER',
54
+ inputs: [],
55
+ outputs: [{ name: '', type: 'address' }],
56
+ stateMutability: 'view',
57
+ },
58
+ {
59
+ type: 'function',
60
+ name: 'SCHEME_ID',
61
+ inputs: [],
62
+ outputs: [{ name: '', type: 'uint256' }],
63
+ stateMutability: 'view',
64
+ },
65
+ {
66
+ type: 'function',
67
+ name: 'ETH_TOKEN_ADDRESS',
68
+ inputs: [],
69
+ outputs: [{ name: '', type: 'address' }],
70
+ stateMutability: 'view',
71
+ },
72
+ {
73
+ type: 'event',
74
+ name: 'StealthPayment',
75
+ inputs: [
76
+ { name: 'stealthAddress', type: 'address', indexed: true },
77
+ { name: 'token', type: 'address', indexed: true },
78
+ { name: 'amount', type: 'uint256', indexed: false },
79
+ ],
80
+ },
81
+ { type: 'error', name: 'ZeroAddress', inputs: [] },
82
+ { type: 'error', name: 'ZeroAmount', inputs: [] },
83
+ { type: 'error', name: 'InsufficientETH', inputs: [] },
84
+ { type: 'error', name: 'ETHTransferFailed', inputs: [] },
85
+ ];
86
+ /**
87
+ * Minimal ABI for USDC's EIP-3009 `transferWithAuthorization`. Pulled out as
88
+ * a separate constant because not every ERC-20 supports it — only Circle's
89
+ * USDC contract and a handful of other authorization-capable tokens. Use
90
+ * `USDC_BY_CHAIN[chainId]` to address the right deployment.
91
+ *
92
+ * The `authorizationState` view is included so callers can confirm a nonce
93
+ * has not already been consumed before submitting.
94
+ */
95
+ export const USDCAuthorizationAbi = [
96
+ {
97
+ type: 'function',
98
+ name: 'transferWithAuthorization',
99
+ inputs: [
100
+ { name: 'from', type: 'address' },
101
+ { name: 'to', type: 'address' },
102
+ { name: 'value', type: 'uint256' },
103
+ { name: 'validAfter', type: 'uint256' },
104
+ { name: 'validBefore', type: 'uint256' },
105
+ { name: 'nonce', type: 'bytes32' },
106
+ { name: 'v', type: 'uint8' },
107
+ { name: 'r', type: 'bytes32' },
108
+ { name: 's', type: 'bytes32' },
109
+ ],
110
+ outputs: [],
111
+ stateMutability: 'nonpayable',
112
+ },
113
+ {
114
+ type: 'function',
115
+ name: 'authorizationState',
116
+ inputs: [
117
+ { name: 'authorizer', type: 'address' },
118
+ { name: 'nonce', type: 'bytes32' },
119
+ ],
120
+ outputs: [{ name: '', type: 'bool' }],
121
+ stateMutability: 'view',
122
+ },
123
+ {
124
+ type: 'event',
125
+ name: 'AuthorizationUsed',
126
+ inputs: [
127
+ { name: 'authorizer', type: 'address', indexed: true },
128
+ { name: 'nonce', type: 'bytes32', indexed: true },
129
+ ],
130
+ },
131
+ ];
132
+ export const ERC20Abi = [
133
+ {
134
+ type: 'function',
135
+ name: 'balanceOf',
136
+ inputs: [{ name: 'account', type: 'address' }],
137
+ outputs: [{ name: '', type: 'uint256' }],
138
+ stateMutability: 'view',
139
+ },
140
+ {
141
+ type: 'function',
142
+ name: 'transfer',
143
+ inputs: [
144
+ { name: 'to', type: 'address' },
145
+ { name: 'amount', type: 'uint256' },
146
+ ],
147
+ outputs: [{ name: '', type: 'bool' }],
148
+ stateMutability: 'nonpayable',
149
+ },
150
+ {
151
+ type: 'function',
152
+ name: 'approve',
153
+ inputs: [
154
+ { name: 'spender', type: 'address' },
155
+ { name: 'amount', type: 'uint256' },
156
+ ],
157
+ outputs: [{ name: '', type: 'bool' }],
158
+ stateMutability: 'nonpayable',
159
+ },
160
+ {
161
+ type: 'function',
162
+ name: 'allowance',
163
+ inputs: [
164
+ { name: 'owner', type: 'address' },
165
+ { name: 'spender', type: 'address' },
166
+ ],
167
+ outputs: [{ name: '', type: 'uint256' }],
168
+ stateMutability: 'view',
169
+ },
170
+ ];
171
+ export const ShroudFiRelayerAbi = [
172
+ {
173
+ type: 'function',
174
+ name: 'sweepERC20WithPermit',
175
+ inputs: [
176
+ { name: 'token', type: 'address' },
177
+ { name: 'destination', type: 'address' },
178
+ { name: 'deadline', type: 'uint256' },
179
+ { name: 'v', type: 'uint8' },
180
+ { name: 'r', type: 'bytes32' },
181
+ { name: 's', type: 'bytes32' },
182
+ ],
183
+ outputs: [],
184
+ stateMutability: 'nonpayable',
185
+ },
186
+ {
187
+ type: 'function',
188
+ name: 'previewFee',
189
+ inputs: [{ name: 'grossAmount', type: 'uint256' }],
190
+ outputs: [
191
+ { name: 'fee', type: 'uint256' },
192
+ { name: 'net', type: 'uint256' },
193
+ ],
194
+ stateMutability: 'view',
195
+ },
196
+ {
197
+ type: 'function',
198
+ name: 'FEE_BPS',
199
+ inputs: [],
200
+ outputs: [{ name: '', type: 'uint16' }],
201
+ stateMutability: 'view',
202
+ },
203
+ {
204
+ type: 'function',
205
+ name: 'BPS_DENOMINATOR',
206
+ inputs: [],
207
+ outputs: [{ name: '', type: 'uint16' }],
208
+ stateMutability: 'view',
209
+ },
210
+ {
211
+ type: 'function',
212
+ name: 'TREASURY',
213
+ inputs: [],
214
+ outputs: [{ name: '', type: 'address' }],
215
+ stateMutability: 'view',
216
+ },
217
+ {
218
+ type: 'function',
219
+ name: 'treasury',
220
+ inputs: [],
221
+ outputs: [{ name: '', type: 'address' }],
222
+ stateMutability: 'view',
223
+ },
224
+ {
225
+ type: 'function',
226
+ name: 'trustedForwarder',
227
+ inputs: [],
228
+ outputs: [{ name: '', type: 'address' }],
229
+ stateMutability: 'view',
230
+ },
231
+ {
232
+ type: 'function',
233
+ name: 'isTrustedForwarder',
234
+ inputs: [{ name: 'forwarder', type: 'address' }],
235
+ outputs: [{ name: '', type: 'bool' }],
236
+ stateMutability: 'view',
237
+ },
238
+ {
239
+ type: 'event',
240
+ name: 'SweepRelayed',
241
+ inputs: [
242
+ { name: 'stealthAddress', type: 'address', indexed: true },
243
+ { name: 'token', type: 'address', indexed: true },
244
+ { name: 'destination', type: 'address', indexed: false },
245
+ { name: 'grossAmount', type: 'uint256', indexed: false },
246
+ { name: 'feeAmount', type: 'uint256', indexed: false },
247
+ ],
248
+ },
249
+ { type: 'error', name: 'InvalidToken', inputs: [] },
250
+ { type: 'error', name: 'InvalidDestination', inputs: [] },
251
+ { type: 'error', name: 'ZeroBalance', inputs: [] },
252
+ { type: 'error', name: 'PermitFailedAndNoAllowance', inputs: [] },
253
+ { type: 'error', name: 'TransferFailed', inputs: [] },
254
+ ];
255
+ export const ERC6538RegistryAbi = [
256
+ {
257
+ type: 'function',
258
+ name: 'registerKeys',
259
+ inputs: [
260
+ { name: 'schemeId', type: 'uint256' },
261
+ { name: 'stealthMetaAddress', type: 'bytes' },
262
+ ],
263
+ outputs: [],
264
+ stateMutability: 'nonpayable',
265
+ },
266
+ {
267
+ type: 'function',
268
+ name: 'stealthMetaAddressOf',
269
+ inputs: [
270
+ { name: 'registrant', type: 'address' },
271
+ { name: 'schemeId', type: 'uint256' },
272
+ ],
273
+ outputs: [{ name: '', type: 'bytes' }],
274
+ stateMutability: 'view',
275
+ },
276
+ {
277
+ type: 'function',
278
+ name: 'incrementNonce',
279
+ inputs: [{ name: 'schemeId', type: 'uint256' }],
280
+ outputs: [],
281
+ stateMutability: 'nonpayable',
282
+ },
283
+ ];
284
+ //# sourceMappingURL=abis.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"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AAU;QAChB,IAAI,EAAE,cAAc;QACpB,MAAM,EAAE;YACN,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,EAAE,SAAS,EAAE;YACrC,EAAE,IAAI,EAAE,oBAAoB,EAAE,IAAI,EAAE,OAAO,EAAE;SAC9C;QACD,OAAO,EAAE,EAAE;QACX,eAAe,EAAE,YAAY;KAC9B;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,sBAAsB;QAC5B,MAAM,EAAE;YACN,EAAE,IAAI,EAAE,YAAY,EAAE,IAAI,EAAE,SAAS,EAAE;YACvC,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,EAAE,SAAS,EAAE;SACtC;QACD,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;QACtC,eAAe,EAAE,MAAM;KACxB;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,gBAAgB;QACtB,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC;QAC/C,OAAO,EAAE,EAAE;QACX,eAAe,EAAE,YAAY;KAC9B;CACO,CAAC"}
@@ -0,0 +1,38 @@
1
+ import type { Address } from 'viem';
2
+ /** Canonical ERC-5564 stealth announcement contract — same address every EVM chain (CREATE2). */
3
+ export declare const ERC5564_ANNOUNCER: "0x55649E01B5Df198D18D95b5cc5051630cfD45564";
4
+ /** Canonical ERC-6538 stealth meta-address registry — same address every EVM chain (CREATE2). */
5
+ export declare const ERC6538_REGISTRY: "0x6538E6bf4B0eBd30A8Ea093027Ac2422ce5d6538";
6
+ /**
7
+ * Canonical USDC (Circle-issued) contract addresses, keyed by chain id.
8
+ *
9
+ * Per-chain because USDC is NOT CREATE2-deterministic across chains — Circle
10
+ * deploys a native contract per network with a different address each time.
11
+ *
12
+ * Coverage (P6 v1):
13
+ * - 8453 Base mainnet — Circle-native USDC
14
+ * - 84532 Base Sepolia — Circle-native testnet USDC
15
+ *
16
+ * Both addresses verified against Circle's official deployment registry on
17
+ * 2026-06-03. Adding new chains: confirm via https://developers.circle.com/
18
+ * stablecoin/docs/usdc-on-other-chains before extending this map.
19
+ *
20
+ * Both contracts implement EIP-3009 `transferWithAuthorization` (the signing
21
+ * primitive x402's `exact` scheme depends on) AND EIP-2612 `permit` (the
22
+ * signing primitive `ShroudFiRelayer` uses). Either path drives sweeps for
23
+ * USDC stealth payments — see `@shroud-fi/payments` for the dispatch logic.
24
+ */
25
+ export declare const USDC_BY_CHAIN: Readonly<Record<number, Address>>;
26
+ /**
27
+ * EIP-712 domain metadata for USDC per chain. Required for client agents
28
+ * signing `TransferWithAuthorization` against the correct domain separator.
29
+ *
30
+ * USDC on Base mainnet + Sepolia both use the same domain shape (Circle's
31
+ * standard issuance contract). Other chains MAY differ — re-verify before
32
+ * extending.
33
+ */
34
+ export declare const USDC_EIP712_DOMAIN_BY_CHAIN: Readonly<Record<number, {
35
+ readonly name: string;
36
+ readonly version: string;
37
+ }>>;
38
+ //# sourceMappingURL=addresses.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"addresses.d.ts","sourceRoot":"","sources":["../../src/addresses.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAEpC,iGAAiG;AACjG,eAAO,MAAM,iBAAiB,EAAG,4CAAqD,CAAC;AAEvF,iGAAiG;AACjG,eAAO,MAAM,gBAAgB,EAAG,4CAAqD,CAAC;AAEtF;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,aAAa,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAGjD,CAAC;AAEZ;;;;;;;GAOG;AACH,eAAO,MAAM,2BAA2B,EAAE,QAAQ,CAChD,MAAM,CAAC,MAAM,EAAE;IAAE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC,CAI1D,CAAC"}
@@ -0,0 +1,40 @@
1
+ /** Canonical ERC-5564 stealth announcement contract — same address every EVM chain (CREATE2). */
2
+ export const ERC5564_ANNOUNCER = '0x55649E01B5Df198D18D95b5cc5051630cfD45564';
3
+ /** Canonical ERC-6538 stealth meta-address registry — same address every EVM chain (CREATE2). */
4
+ export const ERC6538_REGISTRY = '0x6538E6bf4B0eBd30A8Ea093027Ac2422ce5d6538';
5
+ /**
6
+ * Canonical USDC (Circle-issued) contract addresses, keyed by chain id.
7
+ *
8
+ * Per-chain because USDC is NOT CREATE2-deterministic across chains — Circle
9
+ * deploys a native contract per network with a different address each time.
10
+ *
11
+ * Coverage (P6 v1):
12
+ * - 8453 Base mainnet — Circle-native USDC
13
+ * - 84532 Base Sepolia — Circle-native testnet USDC
14
+ *
15
+ * Both addresses verified against Circle's official deployment registry on
16
+ * 2026-06-03. Adding new chains: confirm via https://developers.circle.com/
17
+ * stablecoin/docs/usdc-on-other-chains before extending this map.
18
+ *
19
+ * Both contracts implement EIP-3009 `transferWithAuthorization` (the signing
20
+ * primitive x402's `exact` scheme depends on) AND EIP-2612 `permit` (the
21
+ * signing primitive `ShroudFiRelayer` uses). Either path drives sweeps for
22
+ * USDC stealth payments — see `@shroud-fi/payments` for the dispatch logic.
23
+ */
24
+ export const USDC_BY_CHAIN = Object.freeze({
25
+ 8453: '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913',
26
+ 84532: '0x036CbD53842c5426634e7929541eC2318f3dCF7e',
27
+ });
28
+ /**
29
+ * EIP-712 domain metadata for USDC per chain. Required for client agents
30
+ * signing `TransferWithAuthorization` against the correct domain separator.
31
+ *
32
+ * USDC on Base mainnet + Sepolia both use the same domain shape (Circle's
33
+ * standard issuance contract). Other chains MAY differ — re-verify before
34
+ * extending.
35
+ */
36
+ export const USDC_EIP712_DOMAIN_BY_CHAIN = Object.freeze({
37
+ 8453: Object.freeze({ name: 'USD Coin', version: '2' }),
38
+ 84532: Object.freeze({ name: 'USDC', version: '2' }),
39
+ });
40
+ //# sourceMappingURL=addresses.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"addresses.js","sourceRoot":"","sources":["../../src/addresses.ts"],"names":[],"mappings":"AAEA,iGAAiG;AACjG,MAAM,CAAC,MAAM,iBAAiB,GAAG,4CAAqD,CAAC;AAEvF,iGAAiG;AACjG,MAAM,CAAC,MAAM,gBAAgB,GAAG,4CAAqD,CAAC;AAEtF;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,CAAC,MAAM,aAAa,GAAsC,MAAM,CAAC,MAAM,CAAC;IAC5E,IAAI,EAAE,4CAA4C;IAClD,KAAK,EAAE,4CAA4C;CAC3C,CAAC,CAAC;AAEZ;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,2BAA2B,GAEpC,MAAM,CAAC,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC;IACvD,KAAK,EAAE,MAAM,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC;CAC5C,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export { base, baseSepolia } from 'viem/chains';
2
+ //# sourceMappingURL=chains.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"chains.d.ts","sourceRoot":"","sources":["../../src/chains.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC"}
@@ -0,0 +1,2 @@
1
+ export { base, baseSepolia } from 'viem/chains';
2
+ //# sourceMappingURL=chains.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"chains.js","sourceRoot":"","sources":["../../src/chains.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC"}
@@ -0,0 +1,3 @@
1
+ import type { ShroudFiTransport, ShroudFiTransportConfig } from './types.js';
2
+ export declare function createTransport(config: ShroudFiTransportConfig): ShroudFiTransport;
3
+ //# sourceMappingURL=create.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../../src/create.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,iBAAiB,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAE7E,wBAAgB,eAAe,CAAC,MAAM,EAAE,uBAAuB,GAAG,iBAAiB,CAalF"}
@@ -0,0 +1,15 @@
1
+ import { createPublicClient, createWalletClient, http } from 'viem';
2
+ import { base, baseSepolia } from 'viem/chains';
3
+ import { privateKeyToAccount } from 'viem/accounts';
4
+ export function createTransport(config) {
5
+ const chain = config.chain === 'base' ? base : baseSepolia;
6
+ const transport = config.rpcUrl ? http(config.rpcUrl) : http();
7
+ const publicClient = createPublicClient({ chain, transport });
8
+ let walletClient;
9
+ if (config.privateKey) {
10
+ const account = privateKeyToAccount(config.privateKey);
11
+ walletClient = createWalletClient({ account, chain, transport });
12
+ }
13
+ return { publicClient, walletClient, chain };
14
+ }
15
+ //# sourceMappingURL=create.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"create.js","sourceRoot":"","sources":["../../src/create.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,IAAI,EAAc,MAAM,MAAM,CAAC;AAChF,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAGpD,MAAM,UAAU,eAAe,CAAC,MAA+B;IAC7D,MAAM,KAAK,GAAU,MAAM,CAAC,KAAK,KAAK,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,WAAW,CAAC;IAClE,MAAM,SAAS,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC;IAE/D,MAAM,YAAY,GAAG,kBAAkB,CAAC,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;IAE9D,IAAI,YAA+C,CAAC;IACpD,IAAI,MAAM,CAAC,UAAU,EAAE,CAAC;QACtB,MAAM,OAAO,GAAG,mBAAmB,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC;QACvD,YAAY,GAAG,kBAAkB,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;IACnE,CAAC;IAED,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,KAAK,EAAuB,CAAC;AACpE,CAAC"}
@@ -0,0 +1,54 @@
1
+ import type { Address } from 'viem';
2
+ import type { DeploymentManifest } from './deployments.js';
3
+ export declare function getShroudFiStealth(chainId: number): Address;
4
+ export declare function getShroudFiRegistrar(chainId: number): Address;
5
+ /**
6
+ * MockERC20 lookup. Returns undefined for chains that don't carry one
7
+ * (e.g. mainnet — mocks are testnet-only).
8
+ */
9
+ export declare function getMockERC20(chainId: number): Address | undefined;
10
+ /**
11
+ * ShroudFiRelayer lookup. Returns undefined for chains where the relayer
12
+ * contract has not yet been deployed (e.g. before Wave 3 populates the manifest).
13
+ */
14
+ export declare function getRelayer(chainId: number): Address | undefined;
15
+ /**
16
+ * ShroudFiEthRelayer (P5.1) lookup. Returns undefined for chains where the
17
+ * EIP-7702 ETH gasless sweep contract has not yet been deployed.
18
+ */
19
+ export declare function getEthRelayer(chainId: number): Address | undefined;
20
+ /**
21
+ * MockERC20Permit lookup — the permit-capable ERC-20 mock used by the demo
22
+ * for both direct sweep AND gasless sweep paths. The original MockERC20
23
+ * (non-permit) remains in the manifest as a backward-compatibility entry
24
+ * but new code paths should prefer this one.
25
+ *
26
+ * Returns undefined for chains that don't carry a deployment (mainnet etc.).
27
+ */
28
+ export declare function getMockERC20Permit(chainId: number): Address | undefined;
29
+ /**
30
+ * Canonical USDC (Circle-issued) address lookup. Returns undefined for any
31
+ * chain not in the supported allowlist — callers should treat undefined as
32
+ * "USDC not available on this chain" and surface a clear error, NOT fall back
33
+ * to a zero address or a non-Circle token.
34
+ */
35
+ export declare function getUSDC(chainId: number): Address | undefined;
36
+ /**
37
+ * EIP-712 domain metadata (`name`, `version`) for USDC on a given chain.
38
+ * Required to sign `TransferWithAuthorization` for x402's `exact` scheme and
39
+ * for `ShroudFiRelayer` ERC-20 permit-based gasless sweeps.
40
+ *
41
+ * Returns undefined when USDC is not supported on the chain.
42
+ */
43
+ export declare function getUSDCDomain(chainId: number): {
44
+ readonly name: string;
45
+ readonly version: string;
46
+ } | undefined;
47
+ /**
48
+ * Boolean check — is USDC available (and supported by this SDK) on this chain?
49
+ */
50
+ export declare function hasUSDC(chainId: number): boolean;
51
+ export declare function getDeployment(chainId: number): DeploymentManifest;
52
+ export declare function hasDeployment(chainId: number): boolean;
53
+ export declare function listDeployedChains(): readonly number[];
54
+ //# sourceMappingURL=deployments-helpers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"deployments-helpers.d.ts","sourceRoot":"","sources":["../../src/deployments-helpers.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAUpC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAI3D,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAI3D;AAED,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAI7D;AAED;;;GAGG;AACH,wBAAgB,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CAEjE;AAED;;;GAGG;AACH,wBAAgB,UAAU,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CAE/D;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CAElE;AAED;;;;;;;GAOG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CAEvE;AAED;;;;;GAKG;AACH,wBAAgB,OAAO,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CAE5D;AAED;;;;;;GAMG;AACH,wBAAgB,aAAa,CAC3B,OAAO,EAAE,MAAM,GACd;IAAE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAA;CAAE,GAAG,SAAS,CAEjE;AAED;;GAEG;AACH,wBAAgB,OAAO,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAEhD;AAED,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,kBAAkB,CAIjE;AAED,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAEtD;AAED,wBAAgB,kBAAkB,IAAI,SAAS,MAAM,EAAE,CAEtD"}
@@ -0,0 +1,85 @@
1
+ import { DEPLOYMENTS, SHROUDFI_STEALTH_BY_CHAIN, SHROUDFI_REGISTRAR_BY_CHAIN, MOCK_ERC20_BY_CHAIN, MOCK_ERC20_PERMIT_BY_CHAIN, SHROUDFI_RELAYER_BY_CHAIN, SHROUDFI_ETH_RELAYER_BY_CHAIN, } from './deployments.js';
2
+ import { USDC_BY_CHAIN, USDC_EIP712_DOMAIN_BY_CHAIN } from './addresses.js';
3
+ import { UnknownChainError } from './errors.js';
4
+ export function getShroudFiStealth(chainId) {
5
+ const a = SHROUDFI_STEALTH_BY_CHAIN[chainId];
6
+ if (!a)
7
+ throw new UnknownChainError(chainId);
8
+ return a;
9
+ }
10
+ export function getShroudFiRegistrar(chainId) {
11
+ const a = SHROUDFI_REGISTRAR_BY_CHAIN[chainId];
12
+ if (!a)
13
+ throw new UnknownChainError(chainId);
14
+ return a;
15
+ }
16
+ /**
17
+ * MockERC20 lookup. Returns undefined for chains that don't carry one
18
+ * (e.g. mainnet — mocks are testnet-only).
19
+ */
20
+ export function getMockERC20(chainId) {
21
+ return MOCK_ERC20_BY_CHAIN[chainId];
22
+ }
23
+ /**
24
+ * ShroudFiRelayer lookup. Returns undefined for chains where the relayer
25
+ * contract has not yet been deployed (e.g. before Wave 3 populates the manifest).
26
+ */
27
+ export function getRelayer(chainId) {
28
+ return SHROUDFI_RELAYER_BY_CHAIN[chainId];
29
+ }
30
+ /**
31
+ * ShroudFiEthRelayer (P5.1) lookup. Returns undefined for chains where the
32
+ * EIP-7702 ETH gasless sweep contract has not yet been deployed.
33
+ */
34
+ export function getEthRelayer(chainId) {
35
+ return SHROUDFI_ETH_RELAYER_BY_CHAIN[chainId];
36
+ }
37
+ /**
38
+ * MockERC20Permit lookup — the permit-capable ERC-20 mock used by the demo
39
+ * for both direct sweep AND gasless sweep paths. The original MockERC20
40
+ * (non-permit) remains in the manifest as a backward-compatibility entry
41
+ * but new code paths should prefer this one.
42
+ *
43
+ * Returns undefined for chains that don't carry a deployment (mainnet etc.).
44
+ */
45
+ export function getMockERC20Permit(chainId) {
46
+ return MOCK_ERC20_PERMIT_BY_CHAIN[chainId];
47
+ }
48
+ /**
49
+ * Canonical USDC (Circle-issued) address lookup. Returns undefined for any
50
+ * chain not in the supported allowlist — callers should treat undefined as
51
+ * "USDC not available on this chain" and surface a clear error, NOT fall back
52
+ * to a zero address or a non-Circle token.
53
+ */
54
+ export function getUSDC(chainId) {
55
+ return USDC_BY_CHAIN[chainId];
56
+ }
57
+ /**
58
+ * EIP-712 domain metadata (`name`, `version`) for USDC on a given chain.
59
+ * Required to sign `TransferWithAuthorization` for x402's `exact` scheme and
60
+ * for `ShroudFiRelayer` ERC-20 permit-based gasless sweeps.
61
+ *
62
+ * Returns undefined when USDC is not supported on the chain.
63
+ */
64
+ export function getUSDCDomain(chainId) {
65
+ return USDC_EIP712_DOMAIN_BY_CHAIN[chainId];
66
+ }
67
+ /**
68
+ * Boolean check — is USDC available (and supported by this SDK) on this chain?
69
+ */
70
+ export function hasUSDC(chainId) {
71
+ return chainId in USDC_BY_CHAIN;
72
+ }
73
+ export function getDeployment(chainId) {
74
+ const m = DEPLOYMENTS[chainId];
75
+ if (!m)
76
+ throw new UnknownChainError(chainId);
77
+ return m;
78
+ }
79
+ export function hasDeployment(chainId) {
80
+ return Boolean(DEPLOYMENTS[chainId]);
81
+ }
82
+ export function listDeployedChains() {
83
+ return Object.keys(DEPLOYMENTS).map(Number);
84
+ }
85
+ //# sourceMappingURL=deployments-helpers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"deployments-helpers.js","sourceRoot":"","sources":["../../src/deployments-helpers.ts"],"names":[],"mappings":"AACA,OAAO,EACL,WAAW,EACX,yBAAyB,EACzB,2BAA2B,EAC3B,mBAAmB,EACnB,0BAA0B,EAC1B,yBAAyB,EACzB,6BAA6B,GAC9B,MAAM,kBAAkB,CAAC;AAE1B,OAAO,EAAE,aAAa,EAAE,2BAA2B,EAAE,MAAM,gBAAgB,CAAC;AAC5E,OAAO,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAEhD,MAAM,UAAU,kBAAkB,CAAC,OAAe;IAChD,MAAM,CAAC,GAAG,yBAAyB,CAAC,OAAO,CAAC,CAAC;IAC7C,IAAI,CAAC,CAAC;QAAE,MAAM,IAAI,iBAAiB,CAAC,OAAO,CAAC,CAAC;IAC7C,OAAO,CAAC,CAAC;AACX,CAAC;AAED,MAAM,UAAU,oBAAoB,CAAC,OAAe;IAClD,MAAM,CAAC,GAAG,2BAA2B,CAAC,OAAO,CAAC,CAAC;IAC/C,IAAI,CAAC,CAAC;QAAE,MAAM,IAAI,iBAAiB,CAAC,OAAO,CAAC,CAAC;IAC7C,OAAO,CAAC,CAAC;AACX,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,YAAY,CAAC,OAAe;IAC1C,OAAO,mBAAmB,CAAC,OAAO,CAAC,CAAC;AACtC,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,UAAU,CAAC,OAAe;IACxC,OAAO,yBAAyB,CAAC,OAAO,CAAC,CAAC;AAC5C,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,aAAa,CAAC,OAAe;IAC3C,OAAO,6BAA6B,CAAC,OAAO,CAAC,CAAC;AAChD,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,kBAAkB,CAAC,OAAe;IAChD,OAAO,0BAA0B,CAAC,OAAO,CAAC,CAAC;AAC7C,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,OAAO,CAAC,OAAe;IACrC,OAAO,aAAa,CAAC,OAAO,CAAC,CAAC;AAChC,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,aAAa,CAC3B,OAAe;IAEf,OAAO,2BAA2B,CAAC,OAAO,CAAC,CAAC;AAC9C,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,OAAO,CAAC,OAAe;IACrC,OAAO,OAAO,IAAI,aAAa,CAAC;AAClC,CAAC;AAED,MAAM,UAAU,aAAa,CAAC,OAAe;IAC3C,MAAM,CAAC,GAAG,WAAW,CAAC,OAAO,CAAC,CAAC;IAC/B,IAAI,CAAC,CAAC;QAAE,MAAM,IAAI,iBAAiB,CAAC,OAAO,CAAC,CAAC;IAC7C,OAAO,CAAC,CAAC;AACX,CAAC;AAED,MAAM,UAAU,aAAa,CAAC,OAAe;IAC3C,OAAO,OAAO,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC,CAAC;AACvC,CAAC;AAED,MAAM,UAAU,kBAAkB;IAChC,OAAO,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;AAC9C,CAAC"}
@@ -0,0 +1,35 @@
1
+ import type { Address, Hex } from 'viem';
2
+ export interface DeploymentManifest {
3
+ readonly chainId: number;
4
+ readonly chainName: string;
5
+ readonly deployedAt: string;
6
+ readonly deployer: Address;
7
+ readonly shroudfiStealth: Address;
8
+ readonly shroudfiRegistrar: Address;
9
+ readonly stealthSalt: Hex;
10
+ readonly registrarSalt: Hex;
11
+ readonly announcer: Address;
12
+ readonly registry: Address;
13
+ readonly block: number;
14
+ readonly blockscoutUrl?: string;
15
+ readonly mockERC20?: Address;
16
+ readonly mockERC20Block?: number;
17
+ readonly shroudfiRelayer?: Address;
18
+ readonly relayerTreasury?: Address;
19
+ readonly relayerForwarder?: Address;
20
+ readonly relayerBlock?: number;
21
+ readonly mockERC20Permit?: Address;
22
+ readonly mockERC20PermitBlock?: number;
23
+ readonly shroudfiEthRelayer?: Address;
24
+ readonly shroudfiEthRelayerBlock?: number;
25
+ readonly ethRelayerOperator?: Address;
26
+ readonly isExample?: boolean;
27
+ }
28
+ export declare const DEPLOYMENTS: Readonly<Record<number, DeploymentManifest>>;
29
+ export declare const SHROUDFI_STEALTH_BY_CHAIN: Readonly<Record<number, Address>>;
30
+ export declare const SHROUDFI_REGISTRAR_BY_CHAIN: Readonly<Record<number, Address>>;
31
+ export declare const MOCK_ERC20_BY_CHAIN: Readonly<Record<number, Address>>;
32
+ export declare const SHROUDFI_RELAYER_BY_CHAIN: Readonly<Record<number, Address>>;
33
+ export declare const MOCK_ERC20_PERMIT_BY_CHAIN: Readonly<Record<number, Address>>;
34
+ export declare const SHROUDFI_ETH_RELAYER_BY_CHAIN: Readonly<Record<number, Address>>;
35
+ //# sourceMappingURL=deployments.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"deployments.d.ts","sourceRoot":"","sources":["../../src/deployments.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,MAAM,MAAM,CAAC;AAEzC,MAAM,WAAW,kBAAkB;IACjC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,QAAQ,CAA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