@account-kit/wallet-client 0.1.0-alpha.9 → 4.50.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 (276) hide show
  1. package/LICENSE +21 -0
  2. package/dist/esm/client/actions/formatSign.d.ts +30 -0
  3. package/dist/esm/client/actions/formatSign.js +32 -0
  4. package/dist/esm/client/actions/formatSign.js.map +1 -0
  5. package/dist/esm/client/actions/getCallsStatus.d.ts +6 -3
  6. package/dist/esm/client/actions/getCallsStatus.js +3 -0
  7. package/dist/esm/client/actions/getCallsStatus.js.map +1 -1
  8. package/dist/esm/client/actions/grantPermissions.d.ts +10 -11
  9. package/dist/esm/client/actions/grantPermissions.js +26 -12
  10. package/dist/esm/client/actions/grantPermissions.js.map +1 -1
  11. package/dist/esm/client/actions/listAccounts.d.ts +10 -3
  12. package/dist/esm/client/actions/listAccounts.js +14 -2
  13. package/dist/esm/client/actions/listAccounts.js.map +1 -1
  14. package/dist/esm/client/actions/prepareCalls.d.ts +6 -3
  15. package/dist/esm/client/actions/prepareCalls.js +12 -8
  16. package/dist/esm/client/actions/prepareCalls.js.map +1 -1
  17. package/dist/esm/client/actions/prepareSign.d.ts +28 -0
  18. package/dist/esm/client/actions/prepareSign.js +31 -0
  19. package/dist/esm/client/actions/prepareSign.js.map +1 -0
  20. package/dist/esm/client/actions/requestAccount.d.ts +3 -1
  21. package/dist/esm/client/actions/requestAccount.js +5 -3
  22. package/dist/esm/client/actions/requestAccount.js.map +1 -1
  23. package/dist/esm/client/actions/sendPreparedCalls.d.ts +3 -1
  24. package/dist/esm/client/actions/sendPreparedCalls.js +2 -0
  25. package/dist/esm/client/actions/sendPreparedCalls.js.map +1 -1
  26. package/dist/esm/client/actions/signMessage.d.ts +5 -2
  27. package/dist/esm/client/actions/signMessage.js +5 -2
  28. package/dist/esm/client/actions/signMessage.js.map +1 -1
  29. package/dist/esm/client/actions/signPreparedCalls.d.ts +2 -2
  30. package/dist/esm/client/actions/signPreparedCalls.js +3 -3
  31. package/dist/esm/client/actions/signPreparedCalls.js.map +1 -1
  32. package/dist/esm/client/actions/signSignatureRequest.d.ts +6 -10
  33. package/dist/esm/client/actions/signSignatureRequest.js +4 -7
  34. package/dist/esm/client/actions/signSignatureRequest.js.map +1 -1
  35. package/dist/esm/client/actions/signTypedData.d.ts +2 -0
  36. package/dist/esm/client/actions/signTypedData.js +2 -0
  37. package/dist/esm/client/actions/signTypedData.js.map +1 -1
  38. package/dist/esm/client/decorator.d.ts +0 -2
  39. package/dist/esm/client/decorator.js +1 -3
  40. package/dist/esm/client/decorator.js.map +1 -1
  41. package/dist/esm/client/index.d.ts +10 -6
  42. package/dist/esm/client/index.js +18 -21
  43. package/dist/esm/client/index.js.map +1 -1
  44. package/dist/esm/exports/index.d.ts +1 -5
  45. package/dist/esm/exports/index.js +1 -6
  46. package/dist/esm/exports/index.js.map +1 -1
  47. package/dist/esm/internal/account.d.ts +33 -0
  48. package/dist/esm/{isomorphic/utils/createAccount.js → internal/account.js} +25 -49
  49. package/dist/esm/internal/account.js.map +1 -0
  50. package/dist/esm/types.d.ts +5 -11
  51. package/dist/esm/types.js.map +1 -1
  52. package/dist/esm/utils.d.ts +13 -1
  53. package/dist/esm/utils.js +13 -1
  54. package/dist/esm/utils.js.map +1 -1
  55. package/dist/esm/version.d.ts +1 -0
  56. package/dist/esm/version.js +4 -0
  57. package/dist/esm/version.js.map +1 -0
  58. package/dist/types/client/actions/formatSign.d.ts +31 -0
  59. package/dist/types/client/actions/formatSign.d.ts.map +1 -0
  60. package/dist/types/client/actions/getCallsStatus.d.ts +6 -3
  61. package/dist/types/client/actions/getCallsStatus.d.ts.map +1 -1
  62. package/dist/types/client/actions/grantPermissions.d.ts +10 -11
  63. package/dist/types/client/actions/grantPermissions.d.ts.map +1 -1
  64. package/dist/types/client/actions/listAccounts.d.ts +10 -3
  65. package/dist/types/client/actions/listAccounts.d.ts.map +1 -1
  66. package/dist/types/client/actions/prepareCalls.d.ts +6 -3
  67. package/dist/types/client/actions/prepareCalls.d.ts.map +1 -1
  68. package/dist/types/client/actions/prepareSign.d.ts +29 -0
  69. package/dist/types/client/actions/prepareSign.d.ts.map +1 -0
  70. package/dist/types/client/actions/requestAccount.d.ts +3 -1
  71. package/dist/types/client/actions/requestAccount.d.ts.map +1 -1
  72. package/dist/types/client/actions/sendPreparedCalls.d.ts +3 -1
  73. package/dist/types/client/actions/sendPreparedCalls.d.ts.map +1 -1
  74. package/dist/types/client/actions/signMessage.d.ts +5 -2
  75. package/dist/types/client/actions/signMessage.d.ts.map +1 -1
  76. package/dist/types/client/actions/signPreparedCalls.d.ts +2 -2
  77. package/dist/types/client/actions/signPreparedCalls.d.ts.map +1 -1
  78. package/dist/types/client/actions/signSignatureRequest.d.ts +6 -10
  79. package/dist/types/client/actions/signSignatureRequest.d.ts.map +1 -1
  80. package/dist/types/client/actions/signTypedData.d.ts +2 -0
  81. package/dist/types/client/actions/signTypedData.d.ts.map +1 -1
  82. package/dist/types/client/decorator.d.ts +0 -2
  83. package/dist/types/client/decorator.d.ts.map +1 -1
  84. package/dist/types/client/index.d.ts +10 -6
  85. package/dist/types/client/index.d.ts.map +1 -1
  86. package/dist/types/exports/index.d.ts +1 -5
  87. package/dist/types/exports/index.d.ts.map +1 -1
  88. package/dist/types/internal/account.d.ts +34 -0
  89. package/dist/types/internal/account.d.ts.map +1 -0
  90. package/dist/types/types.d.ts +5 -11
  91. package/dist/types/types.d.ts.map +1 -1
  92. package/dist/types/utils.d.ts +13 -1
  93. package/dist/types/utils.d.ts.map +1 -1
  94. package/dist/types/version.d.ts +2 -0
  95. package/dist/types/version.d.ts.map +1 -0
  96. package/package.json +33 -28
  97. package/src/client/actions/formatSign.ts +55 -0
  98. package/src/client/actions/getCallsStatus.ts +10 -6
  99. package/src/client/actions/grantPermissions.ts +46 -18
  100. package/src/client/actions/listAccounts.ts +22 -5
  101. package/src/client/actions/prepareCalls.ts +22 -16
  102. package/src/client/actions/prepareSign.ts +51 -0
  103. package/src/client/actions/requestAccount.ts +6 -4
  104. package/src/client/actions/sendPreparedCalls.ts +3 -1
  105. package/src/client/actions/signMessage.ts +5 -2
  106. package/src/client/actions/signPreparedCalls.ts +8 -12
  107. package/src/client/actions/signSignatureRequest.ts +12 -15
  108. package/src/client/actions/signTypedData.ts +2 -0
  109. package/src/client/decorator.ts +1 -8
  110. package/src/client/index.ts +41 -33
  111. package/src/exports/index.ts +1 -13
  112. package/src/internal/account.ts +120 -0
  113. package/src/types.ts +7 -18
  114. package/src/utils.ts +13 -1
  115. package/src/version.ts +3 -0
  116. package/dist/esm/capabilities/eip7702Auth.d.ts +0 -4
  117. package/dist/esm/capabilities/eip7702Auth.js +0 -18
  118. package/dist/esm/capabilities/eip7702Auth.js.map +0 -1
  119. package/dist/esm/capabilities/index.d.ts +0 -41
  120. package/dist/esm/capabilities/index.js +0 -14
  121. package/dist/esm/capabilities/index.js.map +0 -1
  122. package/dist/esm/capabilities/multiDimensionalNonce.d.ts +0 -3
  123. package/dist/esm/capabilities/multiDimensionalNonce.js +0 -7
  124. package/dist/esm/capabilities/multiDimensionalNonce.js.map +0 -1
  125. package/dist/esm/capabilities/overrides.d.ts +0 -26
  126. package/dist/esm/capabilities/overrides.js +0 -14
  127. package/dist/esm/capabilities/overrides.js.map +0 -1
  128. package/dist/esm/capabilities/paymaster.d.ts +0 -3
  129. package/dist/esm/capabilities/paymaster.js +0 -5
  130. package/dist/esm/capabilities/paymaster.js.map +0 -1
  131. package/dist/esm/capabilities/permissions/index.d.ts +0 -145
  132. package/dist/esm/capabilities/permissions/index.js +0 -83
  133. package/dist/esm/capabilities/permissions/index.js.map +0 -1
  134. package/dist/esm/capabilities/permissions/mav2.d.ts +0 -36
  135. package/dist/esm/capabilities/permissions/mav2.js +0 -88
  136. package/dist/esm/capabilities/permissions/mav2.js.map +0 -1
  137. package/dist/esm/client/actions/createAccount.d.ts +0 -35
  138. package/dist/esm/client/actions/createAccount.js +0 -32
  139. package/dist/esm/client/actions/createAccount.js.map +0 -1
  140. package/dist/esm/client/client.e2e-test.d.ts +0 -1
  141. package/dist/esm/client/client.e2e-test.js +0 -375
  142. package/dist/esm/client/client.e2e-test.js.map +0 -1
  143. package/dist/esm/exports/internal.d.ts +0 -14
  144. package/dist/esm/exports/internal.js +0 -16
  145. package/dist/esm/exports/internal.js.map +0 -1
  146. package/dist/esm/isomorphic/actions/createSession.d.ts +0 -14
  147. package/dist/esm/isomorphic/actions/createSession.js +0 -95
  148. package/dist/esm/isomorphic/actions/createSession.js.map +0 -1
  149. package/dist/esm/isomorphic/actions/getCallsStatus.d.ts +0 -21
  150. package/dist/esm/isomorphic/actions/getCallsStatus.js +0 -113
  151. package/dist/esm/isomorphic/actions/getCallsStatus.js.map +0 -1
  152. package/dist/esm/isomorphic/actions/prepareCalls.d.ts +0 -8
  153. package/dist/esm/isomorphic/actions/prepareCalls.js +0 -116
  154. package/dist/esm/isomorphic/actions/prepareCalls.js.map +0 -1
  155. package/dist/esm/isomorphic/actions/sendPreparedCalls.d.ts +0 -8
  156. package/dist/esm/isomorphic/actions/sendPreparedCalls.js +0 -157
  157. package/dist/esm/isomorphic/actions/sendPreparedCalls.js.map +0 -1
  158. package/dist/esm/isomorphic/client.d.ts +0 -239
  159. package/dist/esm/isomorphic/client.js +0 -37
  160. package/dist/esm/isomorphic/client.js.map +0 -1
  161. package/dist/esm/isomorphic/utils/7702.d.ts +0 -23
  162. package/dist/esm/isomorphic/utils/7702.js +0 -75
  163. package/dist/esm/isomorphic/utils/7702.js.map +0 -1
  164. package/dist/esm/isomorphic/utils/createAccount.d.ts +0 -24
  165. package/dist/esm/isomorphic/utils/createAccount.js.map +0 -1
  166. package/dist/esm/isomorphic/utils/createDummySigner.d.ts +0 -3
  167. package/dist/esm/isomorphic/utils/createDummySigner.js +0 -17
  168. package/dist/esm/isomorphic/utils/createDummySigner.js.map +0 -1
  169. package/dist/esm/isomorphic/utils/decodeSignature.d.ts +0 -3
  170. package/dist/esm/isomorphic/utils/decodeSignature.js +0 -13
  171. package/dist/esm/isomorphic/utils/decodeSignature.js.map +0 -1
  172. package/dist/esm/isomorphic/utils/parsePermissionsContext.d.ts +0 -21
  173. package/dist/esm/isomorphic/utils/parsePermissionsContext.js +0 -34
  174. package/dist/esm/isomorphic/utils/parsePermissionsContext.js.map +0 -1
  175. package/dist/esm/isomorphic/utils/supportsFeature.d.ts +0 -4
  176. package/dist/esm/isomorphic/utils/supportsFeature.js +0 -21
  177. package/dist/esm/isomorphic/utils/supportsFeature.js.map +0 -1
  178. package/dist/esm/local/client.d.ts +0 -3
  179. package/dist/esm/local/client.js +0 -97
  180. package/dist/esm/local/client.js.map +0 -1
  181. package/dist/esm/remote/client.d.ts +0 -9
  182. package/dist/esm/remote/client.js +0 -41
  183. package/dist/esm/remote/client.js.map +0 -1
  184. package/dist/esm/rpc/examples.d.ts +0 -230
  185. package/dist/esm/rpc/examples.js +0 -314
  186. package/dist/esm/rpc/examples.js.map +0 -1
  187. package/dist/esm/rpc/request.d.ts +0 -755
  188. package/dist/esm/rpc/request.js +0 -214
  189. package/dist/esm/rpc/request.js.map +0 -1
  190. package/dist/esm/rpc/schema.d.ts +0 -703
  191. package/dist/esm/rpc/schema.js +0 -5
  192. package/dist/esm/rpc/schema.js.map +0 -1
  193. package/dist/esm/schemas.d.ts +0 -712
  194. package/dist/esm/schemas.js +0 -463
  195. package/dist/esm/schemas.js.map +0 -1
  196. package/dist/types/capabilities/eip7702Auth.d.ts +0 -5
  197. package/dist/types/capabilities/eip7702Auth.d.ts.map +0 -1
  198. package/dist/types/capabilities/index.d.ts +0 -42
  199. package/dist/types/capabilities/index.d.ts.map +0 -1
  200. package/dist/types/capabilities/multiDimensionalNonce.d.ts +0 -4
  201. package/dist/types/capabilities/multiDimensionalNonce.d.ts.map +0 -1
  202. package/dist/types/capabilities/overrides.d.ts +0 -27
  203. package/dist/types/capabilities/overrides.d.ts.map +0 -1
  204. package/dist/types/capabilities/paymaster.d.ts +0 -4
  205. package/dist/types/capabilities/paymaster.d.ts.map +0 -1
  206. package/dist/types/capabilities/permissions/index.d.ts +0 -146
  207. package/dist/types/capabilities/permissions/index.d.ts.map +0 -1
  208. package/dist/types/capabilities/permissions/mav2.d.ts +0 -37
  209. package/dist/types/capabilities/permissions/mav2.d.ts.map +0 -1
  210. package/dist/types/client/actions/createAccount.d.ts +0 -36
  211. package/dist/types/client/actions/createAccount.d.ts.map +0 -1
  212. package/dist/types/client/client.e2e-test.d.ts +0 -2
  213. package/dist/types/client/client.e2e-test.d.ts.map +0 -1
  214. package/dist/types/exports/internal.d.ts +0 -15
  215. package/dist/types/exports/internal.d.ts.map +0 -1
  216. package/dist/types/isomorphic/actions/createSession.d.ts +0 -15
  217. package/dist/types/isomorphic/actions/createSession.d.ts.map +0 -1
  218. package/dist/types/isomorphic/actions/getCallsStatus.d.ts +0 -22
  219. package/dist/types/isomorphic/actions/getCallsStatus.d.ts.map +0 -1
  220. package/dist/types/isomorphic/actions/prepareCalls.d.ts +0 -9
  221. package/dist/types/isomorphic/actions/prepareCalls.d.ts.map +0 -1
  222. package/dist/types/isomorphic/actions/sendPreparedCalls.d.ts +0 -9
  223. package/dist/types/isomorphic/actions/sendPreparedCalls.d.ts.map +0 -1
  224. package/dist/types/isomorphic/client.d.ts +0 -240
  225. package/dist/types/isomorphic/client.d.ts.map +0 -1
  226. package/dist/types/isomorphic/utils/7702.d.ts +0 -24
  227. package/dist/types/isomorphic/utils/7702.d.ts.map +0 -1
  228. package/dist/types/isomorphic/utils/createAccount.d.ts +0 -25
  229. package/dist/types/isomorphic/utils/createAccount.d.ts.map +0 -1
  230. package/dist/types/isomorphic/utils/createDummySigner.d.ts +0 -4
  231. package/dist/types/isomorphic/utils/createDummySigner.d.ts.map +0 -1
  232. package/dist/types/isomorphic/utils/decodeSignature.d.ts +0 -4
  233. package/dist/types/isomorphic/utils/decodeSignature.d.ts.map +0 -1
  234. package/dist/types/isomorphic/utils/parsePermissionsContext.d.ts +0 -22
  235. package/dist/types/isomorphic/utils/parsePermissionsContext.d.ts.map +0 -1
  236. package/dist/types/isomorphic/utils/supportsFeature.d.ts +0 -5
  237. package/dist/types/isomorphic/utils/supportsFeature.d.ts.map +0 -1
  238. package/dist/types/local/client.d.ts +0 -4
  239. package/dist/types/local/client.d.ts.map +0 -1
  240. package/dist/types/remote/client.d.ts +0 -10
  241. package/dist/types/remote/client.d.ts.map +0 -1
  242. package/dist/types/rpc/examples.d.ts +0 -231
  243. package/dist/types/rpc/examples.d.ts.map +0 -1
  244. package/dist/types/rpc/request.d.ts +0 -756
  245. package/dist/types/rpc/request.d.ts.map +0 -1
  246. package/dist/types/rpc/schema.d.ts +0 -704
  247. package/dist/types/rpc/schema.d.ts.map +0 -1
  248. package/dist/types/schemas.d.ts +0 -713
  249. package/dist/types/schemas.d.ts.map +0 -1
  250. package/src/capabilities/eip7702Auth.ts +0 -26
  251. package/src/capabilities/index.ts +0 -14
  252. package/src/capabilities/multiDimensionalNonce.ts +0 -7
  253. package/src/capabilities/overrides.ts +0 -35
  254. package/src/capabilities/paymaster.ts +0 -5
  255. package/src/capabilities/permissions/index.ts +0 -163
  256. package/src/capabilities/permissions/mav2.ts +0 -138
  257. package/src/client/actions/createAccount.ts +0 -53
  258. package/src/client/client.e2e-test.ts +0 -463
  259. package/src/exports/internal.ts +0 -17
  260. package/src/isomorphic/actions/createSession.ts +0 -159
  261. package/src/isomorphic/actions/getCallsStatus.ts +0 -170
  262. package/src/isomorphic/actions/prepareCalls.ts +0 -170
  263. package/src/isomorphic/actions/sendPreparedCalls.ts +0 -232
  264. package/src/isomorphic/client.ts +0 -94
  265. package/src/isomorphic/utils/7702.ts +0 -143
  266. package/src/isomorphic/utils/createAccount.ts +0 -170
  267. package/src/isomorphic/utils/createDummySigner.ts +0 -27
  268. package/src/isomorphic/utils/decodeSignature.ts +0 -18
  269. package/src/isomorphic/utils/parsePermissionsContext.ts +0 -49
  270. package/src/isomorphic/utils/supportsFeature.ts +0 -34
  271. package/src/local/client.ts +0 -136
  272. package/src/remote/client.ts +0 -67
  273. package/src/rpc/examples.ts +0 -342
  274. package/src/rpc/request.ts +0 -300
  275. package/src/rpc/schema.ts +0 -40
  276. package/src/schemas.ts +0 -657
@@ -1,146 +0,0 @@
1
- import { type TLiteral, type TObject } from "@sinclair/typebox";
2
- export declare const TypePermission: import("@sinclair/typebox").TUnion<[TObject<{
3
- type: TLiteral<"native-token-transfer">;
4
- data: TObject<{
5
- allowance: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
6
- }>;
7
- }>, TObject<{
8
- type: TLiteral<"erc20-token-transfer">;
9
- data: TObject<{
10
- allowance: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
11
- address: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
12
- }>;
13
- }>, TObject<{
14
- type: TLiteral<"gas-limit">;
15
- data: TObject<{
16
- limit: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
17
- }>;
18
- }>, TObject<{
19
- type: TLiteral<"contract-access">;
20
- data: TObject<{
21
- address: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
22
- }>;
23
- }>, TObject<{
24
- type: TLiteral<"account-functions">;
25
- data: TObject<{
26
- functions: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">>;
27
- }>;
28
- }>, TObject<{
29
- type: TLiteral<"functions-on-all-contracts">;
30
- data: TObject<{
31
- functions: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">>;
32
- }>;
33
- }>, TObject<{
34
- type: TLiteral<"functions-on-contract">;
35
- data: TObject<{
36
- address: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
37
- functions: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">>;
38
- }>;
39
- }>, TObject<{
40
- type: TLiteral<"root">;
41
- data: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNever>;
42
- }>]>;
43
- export declare const PermissionsArray: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnion<[TObject<{
44
- type: TLiteral<"native-token-transfer">;
45
- data: TObject<{
46
- allowance: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
47
- }>;
48
- }>, TObject<{
49
- type: TLiteral<"erc20-token-transfer">;
50
- data: TObject<{
51
- allowance: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
52
- address: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
53
- }>;
54
- }>, TObject<{
55
- type: TLiteral<"gas-limit">;
56
- data: TObject<{
57
- limit: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
58
- }>;
59
- }>, TObject<{
60
- type: TLiteral<"contract-access">;
61
- data: TObject<{
62
- address: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
63
- }>;
64
- }>, TObject<{
65
- type: TLiteral<"account-functions">;
66
- data: TObject<{
67
- functions: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">>;
68
- }>;
69
- }>, TObject<{
70
- type: TLiteral<"functions-on-all-contracts">;
71
- data: TObject<{
72
- functions: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">>;
73
- }>;
74
- }>, TObject<{
75
- type: TLiteral<"functions-on-contract">;
76
- data: TObject<{
77
- address: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
78
- functions: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">>;
79
- }>;
80
- }>, TObject<{
81
- type: TLiteral<"root">;
82
- data: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNever>;
83
- }>]>>;
84
- export declare const PermissionsContext: TObject<{
85
- context: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
86
- }>;
87
- export declare const RemotePermission: TObject<{
88
- sessionId: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
89
- signature: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
90
- }>;
91
- export declare const PermissionsData: TObject<{
92
- chainId: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
93
- expirySec: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TInteger>;
94
- key: TObject<{
95
- type: import("@sinclair/typebox").TUnion<[TLiteral<"secp256k1">, TLiteral<"ecdsa">, TLiteral<"contract">]>;
96
- publicKey: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
97
- }>;
98
- permissions: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnion<[TObject<{
99
- type: TLiteral<"native-token-transfer">;
100
- data: TObject<{
101
- allowance: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
102
- }>;
103
- }>, TObject<{
104
- type: TLiteral<"erc20-token-transfer">;
105
- data: TObject<{
106
- allowance: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
107
- address: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
108
- }>;
109
- }>, TObject<{
110
- type: TLiteral<"gas-limit">;
111
- data: TObject<{
112
- limit: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
113
- }>;
114
- }>, TObject<{
115
- type: TLiteral<"contract-access">;
116
- data: TObject<{
117
- address: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
118
- }>;
119
- }>, TObject<{
120
- type: TLiteral<"account-functions">;
121
- data: TObject<{
122
- functions: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">>;
123
- }>;
124
- }>, TObject<{
125
- type: TLiteral<"functions-on-all-contracts">;
126
- data: TObject<{
127
- functions: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">>;
128
- }>;
129
- }>, TObject<{
130
- type: TLiteral<"functions-on-contract">;
131
- data: TObject<{
132
- address: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
133
- functions: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">>;
134
- }>;
135
- }>, TObject<{
136
- type: TLiteral<"root">;
137
- data: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNever>;
138
- }>]>>;
139
- }>;
140
- export declare const PermissionsCapability: import("@sinclair/typebox").TUnion<[TObject<{
141
- context: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
142
- }>, TObject<{
143
- sessionId: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
144
- signature: import("@sinclair/typebox").TTemplateLiteralSyntax<"0x${string}">;
145
- }>]>;
146
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/capabilities/permissions/index.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,KAAK,QAAQ,EAEb,KAAK,OAAO,EAEb,MAAM,mBAAmB,CAAC;AAwG3B,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAWzB,CAAC;AAEH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAA8C,CAAC;AAE5E,eAAO,MAAM,kBAAkB;;EAO9B,CAAC;AAEF,eAAO,MAAM,gBAAgB;;;EAQ5B,CAAC;AAEF,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAU1B,CAAC;AAEH,eAAO,MAAM,qBAAqB;;;;;IAKhC,CAAC"}
@@ -1,37 +0,0 @@
1
- import type { Static } from "@sinclair/typebox";
2
- import { type Hex } from "viem";
3
- import type { KeySigner } from "../../schemas.ts";
4
- import type { PermissionsCapability, PermissionsData } from "./index.ts";
5
- export declare const SESSION_ID_LENGTH_BYTES = 16;
6
- export declare const ENTITY_ID_LENGTH_BYTES = 4;
7
- export declare const PermissionsContextVersion: {
8
- readonly REMOTE_MODE_DEFERRED_ACTION: "0x00";
9
- readonly LOCAL_MODE_DEFERRED_ACTION: "0x01";
10
- readonly NON_DEFERRED_ACTION: "0x02";
11
- };
12
- type DecodedPermissionsContext = {
13
- contextVersion: keyof typeof PermissionsContextVersion;
14
- } & ({
15
- contextVersion: "REMOTE_MODE_DEFERRED_ACTION";
16
- sessionId: Hex;
17
- signature: Hex;
18
- deferredAction?: never;
19
- } | {
20
- contextVersion: "LOCAL_MODE_DEFERRED_ACTION";
21
- deferredAction: Hex;
22
- sessionId?: never;
23
- signature?: never;
24
- } | {
25
- contextVersion: "NON_DEFERRED_ACTION";
26
- deferredAction?: never;
27
- sessionId?: never;
28
- signature?: never;
29
- entityId: Hex;
30
- isGlobalValidation: boolean;
31
- });
32
- export declare const encodePermissionsContext: (context: DecodedPermissionsContext) => Hex;
33
- export declare const decodePermissionsContext: (capability: Static<typeof PermissionsCapability>) => DecodedPermissionsContext;
34
- export declare const prefixSignatureKeyType: (sig: Hex, type: KeySigner["type"]) => Hex;
35
- export declare const isGlobalValidation: (data: Pick<Static<typeof PermissionsData>, "permissions">) => boolean;
36
- export {};
37
- //# sourceMappingURL=mav2.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"mav2.d.ts","sourceRoot":"","sources":["../../../../src/capabilities/permissions/mav2.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAuB,KAAK,GAAG,EAAE,MAAM,MAAM,CAAC;AACrD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAElD,OAAO,KAAK,EAAE,qBAAqB,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAEzE,eAAO,MAAM,uBAAuB,KAAK,CAAC;AAC1C,eAAO,MAAM,sBAAsB,IAAI,CAAC;AAExC,eAAO,MAAM,yBAAyB;;;;CAI5B,CAAC;AAKX,KAAK,yBAAyB,GAAG;IAC/B,cAAc,EAAE,MAAM,OAAO,yBAAyB,CAAC;CACxD,GAAG,CACA;IACE,cAAc,EAAE,6BAA6B,CAAC;IAC9C,SAAS,EAAE,GAAG,CAAC;IACf,SAAS,EAAE,GAAG,CAAC;IACf,cAAc,CAAC,EAAE,KAAK,CAAC;CACxB,GACD;IACE,cAAc,EAAE,4BAA4B,CAAC;IAC7C,cAAc,EAAE,GAAG,CAAC;IACpB,SAAS,CAAC,EAAE,KAAK,CAAC;IAClB,SAAS,CAAC,EAAE,KAAK,CAAC;CACnB,GACD;IACE,cAAc,EAAE,qBAAqB,CAAC;IACtC,cAAc,CAAC,EAAE,KAAK,CAAC;IACvB,SAAS,CAAC,EAAE,KAAK,CAAC;IAClB,SAAS,CAAC,EAAE,KAAK,CAAC;IAClB,QAAQ,EAAE,GAAG,CAAC;IACd,kBAAkB,EAAE,OAAO,CAAC;CAC7B,CACJ,CAAC;AAEF,eAAO,MAAM,wBAAwB,GACnC,SAAS,yBAAyB,KACjC,GAsBF,CAAC;AAEF,eAAO,MAAM,wBAAwB,GACnC,YAAY,MAAM,CAAC,OAAO,qBAAqB,CAAC,KAC/C,yBA4CF,CAAC;AAEF,eAAO,MAAM,sBAAsB,GACjC,KAAK,GAAG,EACR,MAAM,SAAS,CAAC,MAAM,CAAC,KACtB,GAUF,CAAC;AAEF,eAAO,MAAM,kBAAkB,GAC7B,MAAM,IAAI,CAAC,MAAM,CAAC,OAAO,eAAe,CAAC,EAAE,aAAa,CAAC,KACxD,OAEF,CAAC"}
@@ -1,36 +0,0 @@
1
- import type { SmartAccountSigner } from "@aa-sdk/core";
2
- import type { Static } from "@sinclair/typebox";
3
- import type { Address } from "abitype";
4
- import type { wallet_createAccount } from "../../rpc/request.ts";
5
- import type { InnerWalletApiClient } from "../../types.ts";
6
- export type CreateAccountParams = Omit<Extract<Static<typeof wallet_createAccount>["Request"]["params"][0], {
7
- signerAddress: Address;
8
- }>, "signerAddress">;
9
- export type CreateAccountResult = Static<typeof wallet_createAccount>["ReturnType"];
10
- /**
11
- * Creates a new account for the provided signer using the wallet API client.
12
- * This method is primarily used to import existing accounts.
13
- * For most cases, you should use requestAccount instead.
14
- * If the account already exists, an error will be thrown.
15
- *
16
- * @param {InnerWalletApiClient} client - The wallet API client to use for the request
17
- * @param {SmartAccountSigner} signer - The signer that will be associated with the account
18
- * @param {CreateAccountParams} params - Parameters for creating the account
19
- * @param {string} [params.id] - Optional UUID v4 identifier for the account
20
- * @param {object} params.creationOptions - Options for account creation
21
- * @param {string} [params.creationOptions.accountType] - Currently only "sma-b" (Modular Account v2) is supported
22
- * @param {string} [params.creationOptions.salt] - Optional hex string to use as salt for account creation
23
- * @returns {Promise<CreateAccountResult>} A Promise that resolves to the created account information
24
- *
25
- * @example
26
- * // Create a new account with a custom salt
27
- * const account = await client.createAccount({
28
- * creationOptions: {
29
- * accountType: "sma-b",
30
- * salt: "0x04"
31
- * }
32
- * });
33
- * console.log(`Created account at address: ${account.accountAddress}`);
34
- */
35
- export declare function createAccount(client: InnerWalletApiClient, signer: SmartAccountSigner, params: CreateAccountParams): Promise<CreateAccountResult>;
36
- //# sourceMappingURL=createAccount.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"createAccount.d.ts","sourceRoot":"","sources":["../../../../src/client/actions/createAccount.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AACvD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAC;AACjE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAE3D,MAAM,MAAM,mBAAmB,GAAG,IAAI,CACpC,OAAO,CACL,MAAM,CAAC,OAAO,oBAAoB,CAAC,CAAC,SAAS,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,EAC3D;IAAE,aAAa,EAAE,OAAO,CAAA;CAAE,CAC3B,EACD,eAAe,CAChB,CAAC;AAEF,MAAM,MAAM,mBAAmB,GAAG,MAAM,CACtC,OAAO,oBAAoB,CAC5B,CAAC,YAAY,CAAC,CAAC;AAEhB;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,wBAAsB,aAAa,CACjC,MAAM,EAAE,oBAAoB,EAC5B,MAAM,EAAE,kBAAkB,EAC1B,MAAM,EAAE,mBAAmB,GAC1B,OAAO,CAAC,mBAAmB,CAAC,CAK9B"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=client.e2e-test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"client.e2e-test.d.ts","sourceRoot":"","sources":["../../../src/client/client.e2e-test.ts"],"names":[],"mappings":""}
@@ -1,15 +0,0 @@
1
- export * from "../capabilities/index.js";
2
- export * from "../capabilities/paymaster.js";
3
- export * from "../capabilities/permissions/index.js";
4
- export * from "../capabilities/permissions/mav2.js";
5
- export type * from "../isomorphic/client.js";
6
- export { createIsomorphicClient } from "../isomorphic/client.js";
7
- export { createDummySigner } from "../isomorphic/utils/createDummySigner.js";
8
- export { prepareInitialOwners } from "../isomorphic/utils/createAccount.js";
9
- export * from "../rpc/request.js";
10
- export * as RpcSchemas from "../rpc/request.js";
11
- export * from "../rpc/schema.js";
12
- export * from "../schemas.js";
13
- export type * from "../types.ts";
14
- export * from "../utils.js";
15
- //# sourceMappingURL=internal.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../../../src/exports/internal.ts"],"names":[],"mappings":"AAGA,cAAc,0BAA0B,CAAC;AACzC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,sCAAsC,CAAC;AACrD,cAAc,qCAAqC,CAAC;AACpD,mBAAmB,yBAAyB,CAAC;AAC7C,OAAO,EAAE,sBAAsB,EAAE,MAAM,yBAAyB,CAAC;AACjE,OAAO,EAAE,iBAAiB,EAAE,MAAM,0CAA0C,CAAC;AAC7E,OAAO,EAAE,oBAAoB,EAAE,MAAM,sCAAsC,CAAC;AAC5E,cAAc,mBAAmB,CAAC;AAClC,OAAO,KAAK,UAAU,MAAM,mBAAmB,CAAC;AAChD,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,mBAAmB,aAAa,CAAC;AACjC,cAAc,aAAa,CAAC"}
@@ -1,15 +0,0 @@
1
- import { type SmartAccountClient, type SmartContractAccount } from "@aa-sdk/core";
2
- import type { Static } from "@sinclair/typebox";
3
- import { type Chain, type Hex, type Transport } from "viem";
4
- import type { wallet_createSession } from "../../rpc/request.js";
5
- import type { WalletServerViemRpcSchema } from "../../rpc/schema.js";
6
- export type CreateSessionParams = Omit<Static<(typeof wallet_createSession)["properties"]["Request"]["properties"]["params"]>[0], "chainId"> & {
7
- entityId?: Hex;
8
- };
9
- export type CreateSessionResult = Omit<Static<(typeof wallet_createSession)["properties"]["ReturnType"]>, "sessionId"> & {
10
- sessionId: Hex | null;
11
- entityId: Hex;
12
- fullPreSignatureDeferredActionDigest: Hex;
13
- };
14
- export declare function createSession(client: SmartAccountClient<Transport, Chain, SmartContractAccount | undefined, Record<string, unknown>, WalletServerViemRpcSchema>, params: CreateSessionParams): Promise<CreateSessionResult>;
15
- //# sourceMappingURL=createSession.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"createSession.d.ts","sourceRoot":"","sources":["../../../../src/isomorphic/actions/createSession.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EAC1B,MAAM,cAAc,CAAC;AAKtB,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,EAML,KAAK,KAAK,EACV,KAAK,GAAG,EACR,KAAK,SAAS,EACf,MAAM,MAAM,CAAC;AAId,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAC;AACjE,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAMrE,MAAM,MAAM,mBAAmB,GAAG,IAAI,CACpC,MAAM,CACJ,CAAC,OAAO,oBAAoB,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,CAAC,CAAC,YAAY,CAAC,CAAC,QAAQ,CAAC,CAC/E,CAAC,CAAC,CAAC,EACJ,SAAS,CACV,GAAG;IACF,QAAQ,CAAC,EAAE,GAAG,CAAC;CAChB,CAAC;AAEF,MAAM,MAAM,mBAAmB,GAAG,IAAI,CACpC,MAAM,CAAC,CAAC,OAAO,oBAAoB,CAAC,CAAC,YAAY,CAAC,CAAC,YAAY,CAAC,CAAC,EACjE,WAAW,CACZ,GAAG;IACF,SAAS,EAAE,GAAG,GAAG,IAAI,CAAC;IACtB,QAAQ,EAAE,GAAG,CAAC;IACd,oCAAoC,EAAE,GAAG,CAAC;CAC3C,CAAC;AAEF,wBAAsB,aAAa,CACjC,MAAM,EAAE,kBAAkB,CACxB,SAAS,EACT,KAAK,EACL,oBAAoB,GAAG,SAAS,EAChC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACvB,yBAAyB,CAC1B,EACD,MAAM,EAAE,mBAAmB,GAC1B,OAAO,CAAC,mBAAmB,CAAC,CAoG9B"}
@@ -1,22 +0,0 @@
1
- import { type SmartAccountClient, type SmartContractAccount } from "@aa-sdk/core";
2
- import type { Static } from "@sinclair/typebox";
3
- import { type Chain, type Transport } from "viem";
4
- import type { wallet_getCallsStatus } from "../../rpc/request.js";
5
- import type { WalletServerViemRpcSchema } from "../../rpc/schema.js";
6
- export type GetCallsStatusParams = Static<(typeof wallet_getCallsStatus)["properties"]["Request"]["properties"]["params"]>[0];
7
- export type GetCallsStatusResponse = Static<(typeof wallet_getCallsStatus)["properties"]["ReturnType"]>;
8
- /** EIP-5792 call status codes */
9
- export declare const CallStatusCode: {
10
- /** Batch has been received by the wallet but has not completed execution onchain */
11
- readonly PENDING: 100;
12
- /** Batch has been included onchain without reverts, receipts array contains info of all calls */
13
- readonly CONFIRMED: 200;
14
- /** Batch has not been included onchain and wallet will not retry */
15
- readonly OFFCHAIN_FAILURE: 400;
16
- /** Batch reverted *completely* and only changes related to gas charge may have been included onchain */
17
- readonly CHAIN_RULES_FAILURE: 500;
18
- /** Batch reverted *partially* and some changes related to batch calls may have been included onchain */
19
- readonly PARTIAL_CHAIN_RULES_FAILURE: 600;
20
- };
21
- export declare function getCallsStatus(client: SmartAccountClient<Transport, Chain, SmartContractAccount | undefined, Record<string, unknown>, WalletServerViemRpcSchema>, callId: GetCallsStatusParams): Promise<GetCallsStatusResponse>;
22
- //# sourceMappingURL=getCallsStatus.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"getCallsStatus.d.ts","sourceRoot":"","sources":["../../../../src/isomorphic/actions/getCallsStatus.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EAC1B,MAAM,cAAc,CAAC;AACtB,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,EAIL,KAAK,KAAK,EAGV,KAAK,SAAS,EACf,MAAM,MAAM,CAAC;AACd,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,sBAAsB,CAAC;AAClE,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAmBrE,MAAM,MAAM,oBAAoB,GAAG,MAAM,CACvC,CAAC,OAAO,qBAAqB,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,CAAC,CAAC,YAAY,CAAC,CAAC,QAAQ,CAAC,CAChF,CAAC,CAAC,CAAC,CAAC;AAEL,MAAM,MAAM,sBAAsB,GAAG,MAAM,CACzC,CAAC,OAAO,qBAAqB,CAAC,CAAC,YAAY,CAAC,CAAC,YAAY,CAAC,CAC3D,CAAC;AAOF,iCAAiC;AACjC,eAAO,MAAM,cAAc;IACzB,oFAAoF;;IAEpF,iGAAiG;;IAEjG,oEAAoE;;IAEpE,wGAAwG;;IAExG,wGAAwG;;CAEhG,CAAC;AAyBX,wBAAsB,cAAc,CAClC,MAAM,EAAE,kBAAkB,CACxB,SAAS,EACT,KAAK,EACL,oBAAoB,GAAG,SAAS,EAChC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACvB,yBAAyB,CAC1B,EACD,MAAM,EAAE,oBAAoB,GAC3B,OAAO,CAAC,sBAAsB,CAAC,CAqDjC"}
@@ -1,9 +0,0 @@
1
- import { type SmartAccountClient, type SmartContractAccount } from "@aa-sdk/core";
2
- import type { Static } from "@sinclair/typebox";
3
- import { type Chain, type Transport } from "viem";
4
- import type { wallet_prepareCalls } from "../../rpc/request.js";
5
- import type { WalletServerViemRpcSchema } from "../../rpc/schema.js";
6
- export type PrepareCallsParams = Omit<Static<(typeof wallet_prepareCalls)["properties"]["Request"]["properties"]["params"]>[0], "chainId">;
7
- export type PrepareCallsResult = Static<(typeof wallet_prepareCalls)["properties"]["ReturnType"]>;
8
- export declare function prepareCalls(client: SmartAccountClient<Transport, Chain, SmartContractAccount | undefined, Record<string, unknown>, WalletServerViemRpcSchema>, params: PrepareCallsParams): Promise<PrepareCallsResult>;
9
- //# sourceMappingURL=prepareCalls.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"prepareCalls.d.ts","sourceRoot":"","sources":["../../../../src/isomorphic/actions/prepareCalls.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EAC1B,MAAM,cAAc,CAAC;AACtB,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAML,KAAK,KAAK,EACV,KAAK,SAAS,EACf,MAAM,MAAM,CAAC;AACd,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAChE,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAQrE,MAAM,MAAM,kBAAkB,GAAG,IAAI,CACnC,MAAM,CACJ,CAAC,OAAO,mBAAmB,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,CAAC,CAAC,YAAY,CAAC,CAAC,QAAQ,CAAC,CAC9E,CAAC,CAAC,CAAC,EACJ,SAAS,CACV,CAAC;AAEF,MAAM,MAAM,kBAAkB,GAAG,MAAM,CACrC,CAAC,OAAO,mBAAmB,CAAC,CAAC,YAAY,CAAC,CAAC,YAAY,CAAC,CACzD,CAAC;AAEF,wBAAsB,YAAY,CAChC,MAAM,EAAE,kBAAkB,CACxB,SAAS,EACT,KAAK,EACL,oBAAoB,GAAG,SAAS,EAChC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACvB,yBAAyB,CAC1B,EACD,MAAM,EAAE,kBAAkB,GACzB,OAAO,CAAC,kBAAkB,CAAC,CA4H7B"}
@@ -1,9 +0,0 @@
1
- import { type SmartAccountClient, type SmartContractAccount } from "@aa-sdk/core";
2
- import { type Chain, type Transport } from "viem";
3
- import { type wallet_sendPreparedCalls } from "../../rpc/request.js";
4
- import type { WalletServerViemRpcSchema } from "../../rpc/schema.js";
5
- import type { Static } from "@sinclair/typebox";
6
- export type SendPreparedCallsParams = Static<(typeof wallet_sendPreparedCalls)["properties"]["Request"]["properties"]["params"]>[0];
7
- export type SendPreparedCallsResult = Static<(typeof wallet_sendPreparedCalls)["properties"]["ReturnType"]>;
8
- export declare function sendPreparedCalls(client: SmartAccountClient<Transport, Chain, SmartContractAccount | undefined, Record<string, unknown>, WalletServerViemRpcSchema>, params: SendPreparedCallsParams): Promise<SendPreparedCallsResult>;
9
- //# sourceMappingURL=sendPreparedCalls.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"sendPreparedCalls.d.ts","sourceRoot":"","sources":["../../../../src/isomorphic/actions/sendPreparedCalls.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EAC1B,MAAM,cAAc,CAAC;AAEtB,OAAO,EASL,KAAK,KAAK,EAEV,KAAK,SAAS,EACf,MAAM,MAAM,CAAC;AAEd,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AACrE,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAKrE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAGhD,MAAM,MAAM,uBAAuB,GAAG,MAAM,CAC1C,CAAC,OAAO,wBAAwB,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,CAAC,CAAC,YAAY,CAAC,CAAC,QAAQ,CAAC,CACnF,CAAC,CAAC,CAAC,CAAC;AAEL,MAAM,MAAM,uBAAuB,GAAG,MAAM,CAC1C,CAAC,OAAO,wBAAwB,CAAC,CAAC,YAAY,CAAC,CAAC,YAAY,CAAC,CAC9D,CAAC;AAGF,wBAAsB,iBAAiB,CACrC,MAAM,EAAE,kBAAkB,CACxB,SAAS,EACT,KAAK,EACL,oBAAoB,GAAG,SAAS,EAChC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACvB,yBAAyB,CAC1B,EACD,MAAM,EAAE,uBAAuB,GAC9B,OAAO,CAAC,uBAAuB,CAAC,CAwLlC"}
@@ -1,240 +0,0 @@
1
- import { type SmartAccountClient, type SmartAccountClientRpcSchema, type SmartContractAccount } from "@aa-sdk/core";
2
- import { type Chain, type Transport } from "viem";
3
- import type { WalletServerViemRpcSchema } from "../rpc/schema.js";
4
- import { type CreateSessionParams } from "./actions/createSession.js";
5
- import { type GetCallsStatusParams } from "./actions/getCallsStatus.js";
6
- import { type PrepareCallsParams } from "./actions/prepareCalls.js";
7
- import { type SendPreparedCallsParams } from "./actions/sendPreparedCalls.js";
8
- type ClientParams = {
9
- chain: Chain;
10
- transport: Transport;
11
- policyId?: string;
12
- useErc7677middleware?: boolean;
13
- };
14
- export declare function isomorphicClientActions(client: SmartAccountClient<Transport, Chain, SmartContractAccount | undefined, Record<string, unknown>, WalletServerViemRpcSchema>): {
15
- prepareCalls: (params: PrepareCallsParams) => Promise<{
16
- type: "array";
17
- data: ({
18
- type: "user-operation-v060";
19
- chainId: `0x${string}`;
20
- data: {
21
- sender: `0x${string}`;
22
- nonce: `0x${string}`;
23
- initCode: `0x${string}`;
24
- callData: `0x${string}`;
25
- callGasLimit: `0x${string}`;
26
- verificationGasLimit: `0x${string}`;
27
- preVerificationGas: `0x${string}`;
28
- maxFeePerGas: `0x${string}`;
29
- maxPriorityFeePerGas: `0x${string}`;
30
- paymasterAndData: `0x${string}`;
31
- };
32
- signatureRequest: {
33
- type: "eth_signTypedData_v4";
34
- data: {
35
- domain?: {
36
- chainId?: number | undefined;
37
- salt?: `0x${string}` | undefined;
38
- name?: string | undefined;
39
- verifyingContract?: `0x${string}` | undefined;
40
- version?: string | undefined;
41
- } | undefined;
42
- types: {
43
- [x: string]: {
44
- type: string;
45
- name: string;
46
- }[];
47
- };
48
- primaryType: string;
49
- message: {
50
- [x: string]: unknown;
51
- };
52
- };
53
- rawPayload: `0x${string}`;
54
- } | {
55
- type: "personal_sign";
56
- data: string | {
57
- raw: `0x${string}`;
58
- };
59
- rawPayload: `0x${string}`;
60
- };
61
- } | {
62
- type: "user-operation-v070";
63
- chainId: `0x${string}`;
64
- data: {
65
- factory?: `0x${string}` | undefined;
66
- factoryData?: `0x${string}` | undefined;
67
- paymaster?: `0x${string}` | undefined;
68
- paymasterData?: `0x${string}` | undefined;
69
- paymasterVerificationGasLimit?: `0x${string}` | undefined;
70
- paymasterPostOpGasLimit?: `0x${string}` | undefined;
71
- sender: `0x${string}`;
72
- nonce: `0x${string}`;
73
- callData: `0x${string}`;
74
- callGasLimit: `0x${string}`;
75
- verificationGasLimit: `0x${string}`;
76
- preVerificationGas: `0x${string}`;
77
- maxFeePerGas: `0x${string}`;
78
- maxPriorityFeePerGas: `0x${string}`;
79
- };
80
- signatureRequest: {
81
- type: "eth_signTypedData_v4";
82
- data: {
83
- domain?: {
84
- chainId?: number | undefined;
85
- salt?: `0x${string}` | undefined;
86
- name?: string | undefined;
87
- verifyingContract?: `0x${string}` | undefined;
88
- version?: string | undefined;
89
- } | undefined;
90
- types: {
91
- [x: string]: {
92
- type: string;
93
- name: string;
94
- }[];
95
- };
96
- primaryType: string;
97
- message: {
98
- [x: string]: unknown;
99
- };
100
- };
101
- rawPayload: `0x${string}`;
102
- } | {
103
- type: "personal_sign";
104
- data: string | {
105
- raw: `0x${string}`;
106
- };
107
- rawPayload: `0x${string}`;
108
- };
109
- } | {
110
- type: "authorization";
111
- chainId: `0x${string}`;
112
- data: {
113
- nonce: `0x${string}`;
114
- address: `0x${string}`;
115
- };
116
- signatureRequest: {
117
- type: "eip7702Auth";
118
- rawPayload: `0x${string}`;
119
- };
120
- })[];
121
- } | {
122
- type: "user-operation-v060";
123
- chainId: `0x${string}`;
124
- data: {
125
- sender: `0x${string}`;
126
- nonce: `0x${string}`;
127
- initCode: `0x${string}`;
128
- callData: `0x${string}`;
129
- callGasLimit: `0x${string}`;
130
- verificationGasLimit: `0x${string}`;
131
- preVerificationGas: `0x${string}`;
132
- maxFeePerGas: `0x${string}`;
133
- maxPriorityFeePerGas: `0x${string}`;
134
- paymasterAndData: `0x${string}`;
135
- };
136
- signatureRequest: {
137
- type: "eth_signTypedData_v4";
138
- data: {
139
- domain?: {
140
- chainId?: number | undefined;
141
- salt?: `0x${string}` | undefined;
142
- name?: string | undefined;
143
- verifyingContract?: `0x${string}` | undefined;
144
- version?: string | undefined;
145
- } | undefined;
146
- types: {
147
- [x: string]: {
148
- type: string;
149
- name: string;
150
- }[];
151
- };
152
- primaryType: string;
153
- message: {
154
- [x: string]: unknown;
155
- };
156
- };
157
- rawPayload: `0x${string}`;
158
- } | {
159
- type: "personal_sign";
160
- data: string | {
161
- raw: `0x${string}`;
162
- };
163
- rawPayload: `0x${string}`;
164
- };
165
- } | {
166
- type: "user-operation-v070";
167
- chainId: `0x${string}`;
168
- data: {
169
- factory?: `0x${string}` | undefined;
170
- factoryData?: `0x${string}` | undefined;
171
- paymaster?: `0x${string}` | undefined;
172
- paymasterData?: `0x${string}` | undefined;
173
- paymasterVerificationGasLimit?: `0x${string}` | undefined;
174
- paymasterPostOpGasLimit?: `0x${string}` | undefined;
175
- sender: `0x${string}`;
176
- nonce: `0x${string}`;
177
- callData: `0x${string}`;
178
- callGasLimit: `0x${string}`;
179
- verificationGasLimit: `0x${string}`;
180
- preVerificationGas: `0x${string}`;
181
- maxFeePerGas: `0x${string}`;
182
- maxPriorityFeePerGas: `0x${string}`;
183
- };
184
- signatureRequest: {
185
- type: "eth_signTypedData_v4";
186
- data: {
187
- domain?: {
188
- chainId?: number | undefined;
189
- salt?: `0x${string}` | undefined;
190
- name?: string | undefined;
191
- verifyingContract?: `0x${string}` | undefined;
192
- version?: string | undefined;
193
- } | undefined;
194
- types: {
195
- [x: string]: {
196
- type: string;
197
- name: string;
198
- }[];
199
- };
200
- primaryType: string;
201
- message: {
202
- [x: string]: unknown;
203
- };
204
- };
205
- rawPayload: `0x${string}`;
206
- } | {
207
- type: "personal_sign";
208
- data: string | {
209
- raw: `0x${string}`;
210
- };
211
- rawPayload: `0x${string}`;
212
- };
213
- }>;
214
- sendPreparedCalls: (params: SendPreparedCallsParams) => Promise<{
215
- preparedCallIds: `0x${string}`[];
216
- }>;
217
- getCallsStatus: (params: GetCallsStatusParams) => Promise<{
218
- receipts?: {
219
- status: `0x${string}`;
220
- logs: {
221
- address: `0x${string}`;
222
- data: `0x${string}`;
223
- topics: `0x${string}`[];
224
- }[];
225
- blockHash: `0x${string}`;
226
- blockNumber: `0x${string}`;
227
- gasUsed: `0x${string}`;
228
- transactionHash: `0x${string}`;
229
- }[] | undefined;
230
- chainId: `0x${string}`;
231
- id: `0x${string}`;
232
- atomic: boolean;
233
- status: 200 | 100 | 400 | 500 | 600;
234
- }>;
235
- createSession: (params: CreateSessionParams) => Promise<import("./actions/createSession.js").CreateSessionResult>;
236
- };
237
- export declare function createIsomorphicClient({ chain, transport, policyId, useErc7677middleware, }: ClientParams): SmartAccountClient<Transport, Chain, SmartContractAccount | undefined, ReturnType<typeof isomorphicClientActions>, WalletServerViemRpcSchema & SmartAccountClientRpcSchema>;
238
- export type IsomorphicClient = ReturnType<typeof createIsomorphicClient>;
239
- export {};
240
- //# sourceMappingURL=client.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../src/isomorphic/client.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,kBAAkB,EACvB,KAAK,2BAA2B,EAChC,KAAK,oBAAoB,EAC1B,MAAM,cAAc,CAAC;AAOtB,OAAO,EAAE,KAAK,KAAK,EAAE,KAAK,SAAS,EAAE,MAAM,MAAM,CAAC;AAClD,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kBAAkB,CAAC;AAClE,OAAO,EAEL,KAAK,mBAAmB,EACzB,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAEL,KAAK,oBAAoB,EAC1B,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAEL,KAAK,kBAAkB,EACxB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAEL,KAAK,uBAAuB,EAC7B,MAAM,gCAAgC,CAAC;AAGxC,KAAK,YAAY,GAAG;IAClB,KAAK,EAAE,KAAK,CAAC;IACb,SAAS,EAAE,SAAS,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,oBAAoB,CAAC,EAAE,OAAO,CAAC;CAChC,CAAC;AAEF,wBAAgB,uBAAuB,CACrC,MAAM,EAAE,kBAAkB,CACxB,SAAS,EACT,KAAK,EACL,oBAAoB,GAAG,SAAS,EAChC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACvB,yBAAyB,CAC1B;2BAGwB,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gCACb,uBAAuB;;;6BAE1B,oBAAoB;;;;;;;;;;;;;;;;;;4BAErB,mBAAmB;EAG9C;AAID,wBAAgB,sBAAsB,CAAC,EACrC,KAAK,EACL,SAAS,EACT,QAAQ,EACR,oBAA2B,GAC5B,EAAE,YAAY,GAAG,kBAAkB,CAClC,SAAS,EACT,KAAK,EACL,oBAAoB,GAAG,SAAS,EAChC,UAAU,CAAC,OAAO,uBAAuB,CAAC,EAC1C,yBAAyB,GAAG,2BAA2B,CACxD,CAmBA;AAED,MAAM,MAAM,gBAAgB,GAAG,UAAU,CAAC,OAAO,sBAAsB,CAAC,CAAC"}
@@ -1,24 +0,0 @@
1
- import type { SmartAccountClient, SmartContractAccount } from "@aa-sdk/core";
2
- import { type Address, type Chain, type Transport } from "viem";
3
- import type { WalletServerViemRpcSchema } from "../../rpc/schema.js";
4
- import { PreparedCall_Authorization } from "../../schemas.js";
5
- import type { Eip7702AuthCapability } from "../../capabilities/eip7702Auth.ts";
6
- import type { Static } from "@sinclair/typebox";
7
- /** Checks if an address is actively delegated on-chain. */
8
- export declare const isDelegated: (client: SmartAccountClient<Transport, Chain, SmartContractAccount | undefined, Record<string, unknown>, WalletServerViemRpcSchema>, params: {
9
- address: Address;
10
- delegation: Address;
11
- }) => Promise<boolean>;
12
- export declare const createAuthorizationRequest: (client: SmartAccountClient<Transport, Chain, SmartContractAccount | undefined, Record<string, unknown>, WalletServerViemRpcSchema>, params: {
13
- address: Address;
14
- delegation: Address;
15
- }) => Promise<Static<typeof PreparedCall_Authorization>>;
16
- export declare const EIP_7702_ACCOUNT_TYPE: readonly ["ModularAccountV2"];
17
- type Supported7702AccountType = (typeof EIP_7702_ACCOUNT_TYPE)[number];
18
- export declare const SUPPORTED_DELEGATION_ADDRESSES: "0x69007702764179f14F51cdce752f4f775d74E139"[];
19
- export declare const isSupportedDelegationAddress7702: (address: Address) => boolean;
20
- export declare const getAccountTypeForDelegationAddress7702: (address: Address) => Supported7702AccountType | undefined;
21
- export declare const parseDelegation: (eip7702AuthCapability: Static<typeof Eip7702AuthCapability>) => "0x69007702764179f14F51cdce752f4f775d74E139";
22
- export declare const assertValid7702AccountAddress: (fromAddress: Address, eip7702AuthCapability: Static<typeof Eip7702AuthCapability> | undefined) => void;
23
- export {};
24
- //# sourceMappingURL=7702.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"7702.d.ts","sourceRoot":"","sources":["../../../../src/isomorphic/utils/7702.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAC7E,OAAO,EAGL,KAAK,OAAO,EACZ,KAAK,KAAK,EACV,KAAK,SAAS,EAGf,MAAM,MAAM,CAAC;AACd,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AACrE,OAAO,EAAE,0BAA0B,EAAE,MAAM,kBAAkB,CAAC;AAC9D,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,mCAAmC,CAAC;AAC/E,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAIhD,2DAA2D;AAC3D,eAAO,MAAM,WAAW,GACtB,QAAQ,kBAAkB,CACxB,SAAS,EACT,KAAK,EACL,oBAAoB,GAAG,SAAS,EAChC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACvB,yBAAyB,CAC1B,EACD,QAAQ;IAAE,OAAO,EAAE,OAAO,CAAC;IAAC,UAAU,EAAE,OAAO,CAAA;CAAE,KAChD,OAAO,CAAC,OAAO,CAIjB,CAAC;AAEF,eAAO,MAAM,0BAA0B,GACrC,QAAQ,kBAAkB,CACxB,SAAS,EACT,KAAK,EACL,oBAAoB,GAAG,SAAS,EAChC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACvB,yBAAyB,CAC1B,EACD,QAAQ;IAAE,OAAO,EAAE,OAAO,CAAC;IAAC,UAAU,EAAE,OAAO,CAAA;CAAE,KAChD,OAAO,CAAC,MAAM,CAAC,OAAO,0BAA0B,CAAC,CAsBnD,CAAC;AAEF,eAAO,MAAM,qBAAqB,+BAAgC,CAAC;AAEnE,KAAK,wBAAwB,GAAG,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,CAAC,CAAC;AAgBvE,eAAO,MAAM,8BAA8B,gDAE1C,CAAC;AAEF,eAAO,MAAM,gCAAgC,GAAI,SAAS,OAAO,KAAG,OAEnE,CAAC;AAEF,eAAO,MAAM,sCAAsC,GACjD,SAAS,OAAO,KACf,wBAAwB,GAAG,SAE7B,CAAC;AAWF,eAAO,MAAM,eAAe,GAC1B,uBAAuB,MAAM,CAAC,OAAO,qBAAqB,CAAC,iDAS5D,CAAC;AAEF,eAAO,MAAM,6BAA6B,GACxC,aAAa,OAAO,EACpB,uBAAuB,MAAM,CAAC,OAAO,qBAAqB,CAAC,GAAG,SAAS,SAqBxE,CAAC"}