@coinbase/cdp-sdk 1.44.1 → 1.46.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 (282) hide show
  1. package/CHANGELOG.md +28 -2
  2. package/README.md +164 -43
  3. package/_cjs/accounts/evm/eip6492.js +49 -0
  4. package/_cjs/accounts/evm/eip6492.js.map +1 -0
  5. package/_cjs/accounts/evm/toEvmDelegatedAccount.js +27 -0
  6. package/_cjs/accounts/evm/toEvmDelegatedAccount.js.map +1 -0
  7. package/_cjs/accounts/evm/toEvmServerAccount.js +127 -55
  8. package/_cjs/accounts/evm/toEvmServerAccount.js.map +1 -1
  9. package/_cjs/accounts/evm/toEvmSmartAccount.js +115 -45
  10. package/_cjs/accounts/evm/toEvmSmartAccount.js.map +1 -1
  11. package/_cjs/accounts/evm/toNetworkScopedEvmSmartAccount.js +31 -0
  12. package/_cjs/accounts/evm/toNetworkScopedEvmSmartAccount.js.map +1 -1
  13. package/_cjs/accounts/solana/toSolanaAccount.js +49 -19
  14. package/_cjs/accounts/solana/toSolanaAccount.js.map +1 -1
  15. package/_cjs/actions/evm/waitForEvmEip7702DelegationStatus.js +37 -0
  16. package/_cjs/actions/evm/waitForEvmEip7702DelegationStatus.js.map +1 -0
  17. package/_cjs/actions/solana/transfer.js.map +1 -1
  18. package/_cjs/actions/solana/utils.js +9 -9
  19. package/_cjs/actions/solana/utils.js.map +1 -1
  20. package/_cjs/analytics.js +10 -228
  21. package/_cjs/analytics.js.map +1 -1
  22. package/_cjs/auth/utils/http.js +1 -0
  23. package/_cjs/auth/utils/http.js.map +1 -1
  24. package/_cjs/client/cdp.js +4 -7
  25. package/_cjs/client/cdp.js.map +1 -1
  26. package/_cjs/client/end-user/endUser.js +385 -4
  27. package/_cjs/client/end-user/endUser.js.map +1 -1
  28. package/_cjs/client/end-user/toEndUserAccount.js +201 -23
  29. package/_cjs/client/end-user/toEndUserAccount.js.map +1 -1
  30. package/_cjs/client/evm/evm.js +482 -227
  31. package/_cjs/client/evm/evm.js.map +1 -1
  32. package/_cjs/client/policies/policies.js +41 -11
  33. package/_cjs/client/policies/policies.js.map +1 -1
  34. package/_cjs/client/solana/solana.js +215 -118
  35. package/_cjs/client/solana/solana.js.map +1 -1
  36. package/_cjs/index.js +3 -1
  37. package/_cjs/index.js.map +1 -1
  38. package/_cjs/openapi-client/cdpApiClient.js +32 -0
  39. package/_cjs/openapi-client/cdpApiClient.js.map +1 -1
  40. package/_cjs/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js +178 -9
  41. package/_cjs/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js.map +1 -1
  42. package/_cjs/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.js +261 -0
  43. package/_cjs/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.js.map +1 -0
  44. package/_cjs/openapi-client/generated/end-user-accounts/end-user-accounts.js.map +1 -1
  45. package/_cjs/openapi-client/generated/evm-accounts/evm-accounts.js +30 -1
  46. package/_cjs/openapi-client/generated/evm-accounts/evm-accounts.js.map +1 -1
  47. package/_cjs/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js +2 -2
  48. package/_cjs/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js.map +1 -1
  49. package/_cjs/openapi-client/generated/evm-swaps/evm-swaps.js.map +1 -1
  50. package/_cjs/openapi-client/generated/evm-token-balances/evm-token-balances.js.map +1 -1
  51. package/_cjs/openapi-client/generated/faucets/faucets.js +6 -5
  52. package/_cjs/openapi-client/generated/faucets/faucets.js.map +1 -1
  53. package/_cjs/openapi-client/generated/onchain-data/onchain-data.js.map +1 -1
  54. package/_cjs/openapi-client/generated/onramp/onramp.js +15 -1
  55. package/_cjs/openapi-client/generated/onramp/onramp.js.map +1 -1
  56. package/_cjs/openapi-client/generated/policy-engine/policy-engine.js.map +1 -1
  57. package/_cjs/openapi-client/generated/solana-accounts/solana-accounts.js.map +1 -1
  58. package/_cjs/openapi-client/generated/solana-token-balances/solana-token-balances.js.map +1 -1
  59. package/_cjs/openapi-client/generated/sql-api/sql-api.js +75 -0
  60. package/_cjs/openapi-client/generated/sql-api/sql-api.js.map +1 -0
  61. package/_cjs/openapi-client/generated/webhooks/webhooks.js.map +1 -1
  62. package/_cjs/openapi-client/generated/x402-facilitator/x402-facilitator.js.map +1 -1
  63. package/_cjs/openapi-client/index.js +4 -1
  64. package/_cjs/openapi-client/index.js.map +1 -1
  65. package/_cjs/policies/evmSchema.js +127 -1
  66. package/_cjs/policies/evmSchema.js.map +1 -1
  67. package/_cjs/policies/solanaSchema.js +102 -1
  68. package/_cjs/policies/solanaSchema.js.map +1 -1
  69. package/_cjs/policies/types.js +7 -0
  70. package/_cjs/policies/types.js.map +1 -1
  71. package/_cjs/utils/export.js +6 -5
  72. package/_cjs/utils/export.js.map +1 -1
  73. package/_cjs/version.js +1 -1
  74. package/_esm/accounts/evm/eip6492.js +46 -0
  75. package/_esm/accounts/evm/eip6492.js.map +1 -0
  76. package/_esm/accounts/evm/toEvmDelegatedAccount.js +24 -0
  77. package/_esm/accounts/evm/toEvmDelegatedAccount.js.map +1 -0
  78. package/_esm/accounts/evm/toEvmServerAccount.js +127 -55
  79. package/_esm/accounts/evm/toEvmServerAccount.js.map +1 -1
  80. package/_esm/accounts/evm/toEvmSmartAccount.js +115 -45
  81. package/_esm/accounts/evm/toEvmSmartAccount.js.map +1 -1
  82. package/_esm/accounts/evm/toNetworkScopedEvmSmartAccount.js +31 -0
  83. package/_esm/accounts/evm/toNetworkScopedEvmSmartAccount.js.map +1 -1
  84. package/_esm/accounts/solana/toSolanaAccount.js +49 -19
  85. package/_esm/accounts/solana/toSolanaAccount.js.map +1 -1
  86. package/_esm/actions/evm/waitForEvmEip7702DelegationStatus.js +34 -0
  87. package/_esm/actions/evm/waitForEvmEip7702DelegationStatus.js.map +1 -0
  88. package/_esm/actions/solana/transfer.js.map +1 -1
  89. package/_esm/actions/solana/utils.js +9 -9
  90. package/_esm/actions/solana/utils.js.map +1 -1
  91. package/_esm/analytics.js +9 -227
  92. package/_esm/analytics.js.map +1 -1
  93. package/_esm/auth/utils/http.js +1 -0
  94. package/_esm/auth/utils/http.js.map +1 -1
  95. package/_esm/client/cdp.js +4 -7
  96. package/_esm/client/cdp.js.map +1 -1
  97. package/_esm/client/end-user/endUser.js +385 -4
  98. package/_esm/client/end-user/endUser.js.map +1 -1
  99. package/_esm/client/end-user/toEndUserAccount.js +201 -23
  100. package/_esm/client/end-user/toEndUserAccount.js.map +1 -1
  101. package/_esm/client/evm/evm.js +482 -227
  102. package/_esm/client/evm/evm.js.map +1 -1
  103. package/_esm/client/policies/policies.js +41 -11
  104. package/_esm/client/policies/policies.js.map +1 -1
  105. package/_esm/client/solana/solana.js +215 -118
  106. package/_esm/client/solana/solana.js.map +1 -1
  107. package/_esm/index.js +1 -0
  108. package/_esm/index.js.map +1 -1
  109. package/_esm/openapi-client/cdpApiClient.js +32 -0
  110. package/_esm/openapi-client/cdpApiClient.js.map +1 -1
  111. package/_esm/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js +175 -7
  112. package/_esm/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js.map +1 -1
  113. package/_esm/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.js +243 -0
  114. package/_esm/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.js.map +1 -0
  115. package/_esm/openapi-client/generated/end-user-accounts/end-user-accounts.js.map +1 -1
  116. package/_esm/openapi-client/generated/evm-accounts/evm-accounts.js +27 -0
  117. package/_esm/openapi-client/generated/evm-accounts/evm-accounts.js.map +1 -1
  118. package/_esm/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js +2 -2
  119. package/_esm/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js.map +1 -1
  120. package/_esm/openapi-client/generated/evm-swaps/evm-swaps.js.map +1 -1
  121. package/_esm/openapi-client/generated/evm-token-balances/evm-token-balances.js.map +1 -1
  122. package/_esm/openapi-client/generated/faucets/faucets.js +6 -5
  123. package/_esm/openapi-client/generated/faucets/faucets.js.map +1 -1
  124. package/_esm/openapi-client/generated/onchain-data/onchain-data.js.map +1 -1
  125. package/_esm/openapi-client/generated/onramp/onramp.js +13 -0
  126. package/_esm/openapi-client/generated/onramp/onramp.js.map +1 -1
  127. package/_esm/openapi-client/generated/policy-engine/policy-engine.js.map +1 -1
  128. package/_esm/openapi-client/generated/solana-accounts/solana-accounts.js.map +1 -1
  129. package/_esm/openapi-client/generated/solana-token-balances/solana-token-balances.js.map +1 -1
  130. package/_esm/openapi-client/generated/sql-api/sql-api.js +70 -0
  131. package/_esm/openapi-client/generated/sql-api/sql-api.js.map +1 -0
  132. package/_esm/openapi-client/generated/webhooks/webhooks.js.map +1 -1
  133. package/_esm/openapi-client/generated/x402-facilitator/x402-facilitator.js.map +1 -1
  134. package/_esm/openapi-client/index.js +4 -1
  135. package/_esm/openapi-client/index.js.map +1 -1
  136. package/_esm/policies/evmSchema.js +126 -0
  137. package/_esm/policies/evmSchema.js.map +1 -1
  138. package/_esm/policies/solanaSchema.js +101 -0
  139. package/_esm/policies/solanaSchema.js.map +1 -1
  140. package/_esm/policies/types.js +9 -2
  141. package/_esm/policies/types.js.map +1 -1
  142. package/_esm/utils/export.js +6 -5
  143. package/_esm/utils/export.js.map +1 -1
  144. package/_esm/version.js +1 -1
  145. package/_types/accounts/evm/eip6492.d.ts +17 -0
  146. package/_types/accounts/evm/eip6492.d.ts.map +1 -0
  147. package/_types/accounts/evm/toEvmDelegatedAccount.d.ts +13 -0
  148. package/_types/accounts/evm/toEvmDelegatedAccount.d.ts.map +1 -0
  149. package/_types/accounts/evm/toEvmServerAccount.d.ts.map +1 -1
  150. package/_types/accounts/evm/toEvmSmartAccount.d.ts.map +1 -1
  151. package/_types/accounts/evm/toNetworkScopedEvmSmartAccount.d.ts +4 -4
  152. package/_types/accounts/evm/toNetworkScopedEvmSmartAccount.d.ts.map +1 -1
  153. package/_types/accounts/evm/types.d.ts +3 -2
  154. package/_types/accounts/evm/types.d.ts.map +1 -1
  155. package/_types/accounts/solana/toSolanaAccount.d.ts.map +1 -1
  156. package/_types/actions/evm/waitForEvmEip7702DelegationStatus.d.ts +32 -0
  157. package/_types/actions/evm/waitForEvmEip7702DelegationStatus.d.ts.map +1 -0
  158. package/_types/actions/solana/transfer.d.ts +3 -4
  159. package/_types/actions/solana/transfer.d.ts.map +1 -1
  160. package/_types/actions/solana/types.d.ts +79 -29
  161. package/_types/actions/solana/types.d.ts.map +1 -1
  162. package/_types/actions/solana/utils.d.ts +10 -9
  163. package/_types/actions/solana/utils.d.ts.map +1 -1
  164. package/_types/analytics.d.ts +5 -38
  165. package/_types/analytics.d.ts.map +1 -1
  166. package/_types/auth/utils/http.d.ts.map +1 -1
  167. package/_types/client/cdp.d.ts +4 -0
  168. package/_types/client/cdp.d.ts.map +1 -1
  169. package/_types/client/end-user/endUser.d.ts +272 -1
  170. package/_types/client/end-user/endUser.d.ts.map +1 -1
  171. package/_types/client/end-user/endUser.types.d.ts +491 -1
  172. package/_types/client/end-user/endUser.types.d.ts.map +1 -1
  173. package/_types/client/end-user/toEndUserAccount.d.ts +4 -1
  174. package/_types/client/end-user/toEndUserAccount.d.ts.map +1 -1
  175. package/_types/client/evm/evm.d.ts +54 -1
  176. package/_types/client/evm/evm.d.ts.map +1 -1
  177. package/_types/client/evm/evm.types.d.ts +29 -2
  178. package/_types/client/evm/evm.types.d.ts.map +1 -1
  179. package/_types/client/policies/policies.d.ts.map +1 -1
  180. package/_types/client/solana/solana.d.ts +38 -12
  181. package/_types/client/solana/solana.d.ts.map +1 -1
  182. package/_types/index.d.ts +3 -1
  183. package/_types/index.d.ts.map +1 -1
  184. package/_types/openapi-client/cdpApiClient.d.ts.map +1 -1
  185. package/_types/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.d.ts +884 -90
  186. package/_types/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.d.ts.map +1 -1
  187. package/_types/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.d.ts +163 -0
  188. package/_types/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.d.ts.map +1 -0
  189. package/_types/openapi-client/generated/end-user-accounts/end-user-accounts.d.ts +9 -9
  190. package/_types/openapi-client/generated/end-user-accounts/end-user-accounts.d.ts.map +1 -1
  191. package/_types/openapi-client/generated/evm-accounts/evm-accounts.d.ts +35 -15
  192. package/_types/openapi-client/generated/evm-accounts/evm-accounts.d.ts.map +1 -1
  193. package/_types/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.d.ts +14 -14
  194. package/_types/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.d.ts.map +1 -1
  195. package/_types/openapi-client/generated/evm-swaps/evm-swaps.d.ts +3 -3
  196. package/_types/openapi-client/generated/evm-swaps/evm-swaps.d.ts.map +1 -1
  197. package/_types/openapi-client/generated/evm-token-balances/evm-token-balances.d.ts +2 -2
  198. package/_types/openapi-client/generated/evm-token-balances/evm-token-balances.d.ts.map +1 -1
  199. package/_types/openapi-client/generated/faucets/faucets.d.ts +9 -8
  200. package/_types/openapi-client/generated/faucets/faucets.d.ts.map +1 -1
  201. package/_types/openapi-client/generated/onchain-data/onchain-data.d.ts +3 -3
  202. package/_types/openapi-client/generated/onchain-data/onchain-data.d.ts.map +1 -1
  203. package/_types/openapi-client/generated/onramp/onramp.d.ts +12 -5
  204. package/_types/openapi-client/generated/onramp/onramp.d.ts.map +1 -1
  205. package/_types/openapi-client/generated/policy-engine/policy-engine.d.ts +6 -6
  206. package/_types/openapi-client/generated/policy-engine/policy-engine.d.ts.map +1 -1
  207. package/_types/openapi-client/generated/solana-accounts/solana-accounts.d.ts +12 -12
  208. package/_types/openapi-client/generated/solana-accounts/solana-accounts.d.ts.map +1 -1
  209. package/_types/openapi-client/generated/solana-token-balances/solana-token-balances.d.ts +2 -2
  210. package/_types/openapi-client/generated/solana-token-balances/solana-token-balances.d.ts.map +1 -1
  211. package/_types/openapi-client/generated/sql-api/sql-api.d.ts +73 -0
  212. package/_types/openapi-client/generated/sql-api/sql-api.d.ts.map +1 -0
  213. package/_types/openapi-client/generated/webhooks/webhooks.d.ts +6 -6
  214. package/_types/openapi-client/generated/webhooks/webhooks.d.ts.map +1 -1
  215. package/_types/openapi-client/generated/x402-facilitator/x402-facilitator.d.ts +4 -4
  216. package/_types/openapi-client/generated/x402-facilitator/x402-facilitator.d.ts.map +1 -1
  217. package/_types/openapi-client/index.d.ts +23 -3
  218. package/_types/openapi-client/index.d.ts.map +1 -1
  219. package/_types/policies/evmSchema.d.ts +3128 -1064
  220. package/_types/policies/evmSchema.d.ts.map +1 -1
  221. package/_types/policies/solanaSchema.d.ts +1411 -47
  222. package/_types/policies/solanaSchema.d.ts.map +1 -1
  223. package/_types/policies/types.d.ts +8427 -2942
  224. package/_types/policies/types.d.ts.map +1 -1
  225. package/_types/types/contract.d.ts.map +1 -1
  226. package/_types/utils/export.d.ts +1 -1
  227. package/_types/utils/export.d.ts.map +1 -1
  228. package/_types/version.d.ts +1 -1
  229. package/accounts/evm/eip6492.ts +60 -0
  230. package/accounts/evm/toEvmDelegatedAccount.ts +26 -0
  231. package/accounts/evm/toEvmServerAccount.ts +115 -67
  232. package/accounts/evm/toEvmSmartAccount.ts +114 -57
  233. package/accounts/evm/toNetworkScopedEvmSmartAccount.ts +44 -5
  234. package/accounts/evm/types.ts +8 -3
  235. package/accounts/solana/toSolanaAccount.ts +44 -24
  236. package/actions/evm/waitForEvmEip7702DelegationStatus.ts +57 -0
  237. package/actions/solana/transfer.ts +3 -3
  238. package/actions/solana/types.ts +79 -29
  239. package/actions/solana/utils.ts +13 -11
  240. package/analytics.ts +8 -294
  241. package/auth/utils/http.ts +1 -0
  242. package/client/cdp.ts +6 -8
  243. package/client/end-user/endUser.ts +513 -4
  244. package/client/end-user/endUser.types.ts +598 -0
  245. package/client/end-user/toEndUserAccount.ts +330 -26
  246. package/client/evm/evm.ts +517 -282
  247. package/client/evm/evm.types.ts +45 -2
  248. package/client/policies/policies.ts +41 -16
  249. package/client/solana/solana.ts +233 -153
  250. package/index.ts +36 -1
  251. package/openapi-client/cdpApiClient.ts +34 -0
  252. package/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.ts +1155 -172
  253. package/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.ts +455 -0
  254. package/openapi-client/generated/end-user-accounts/end-user-accounts.ts +12 -9
  255. package/openapi-client/generated/evm-accounts/evm-accounts.ts +66 -14
  256. package/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.ts +16 -16
  257. package/openapi-client/generated/evm-swaps/evm-swaps.ts +3 -3
  258. package/openapi-client/generated/evm-token-balances/evm-token-balances.ts +2 -2
  259. package/openapi-client/generated/faucets/faucets.ts +9 -8
  260. package/openapi-client/generated/onchain-data/onchain-data.ts +3 -3
  261. package/openapi-client/generated/onramp/onramp.ts +28 -4
  262. package/openapi-client/generated/policy-engine/policy-engine.ts +12 -6
  263. package/openapi-client/generated/solana-accounts/solana-accounts.ts +12 -12
  264. package/openapi-client/generated/solana-token-balances/solana-token-balances.ts +2 -2
  265. package/openapi-client/generated/sql-api/sql-api.ts +92 -0
  266. package/openapi-client/generated/webhooks/webhooks.ts +6 -6
  267. package/openapi-client/generated/x402-facilitator/x402-facilitator.ts +6 -4
  268. package/openapi-client/index.ts +4 -1
  269. package/package.json +7 -8
  270. package/policies/evmSchema.ts +164 -0
  271. package/policies/solanaSchema.ts +130 -0
  272. package/policies/types.ts +14 -0
  273. package/types/contract.ts +2 -4
  274. package/utils/export.ts +6 -5
  275. package/version.ts +1 -1
  276. package/_cjs/openapi-client/generated/sql-api-alpha/sql-api-alpha.js +0 -55
  277. package/_cjs/openapi-client/generated/sql-api-alpha/sql-api-alpha.js.map +0 -1
  278. package/_esm/openapi-client/generated/sql-api-alpha/sql-api-alpha.js +0 -50
  279. package/_esm/openapi-client/generated/sql-api-alpha/sql-api-alpha.js.map +0 -1
  280. package/_types/openapi-client/generated/sql-api-alpha/sql-api-alpha.d.ts +0 -53
  281. package/_types/openapi-client/generated/sql-api-alpha/sql-api-alpha.d.ts.map +0 -1
  282. package/openapi-client/generated/sql-api-alpha/sql-api-alpha.ts +0 -72
@@ -1,4 +1,4 @@
1
- import type { CreateEndUserBody, ListEndUsersParams, ImportEndUserBodyKeyType, AuthenticationMethods, AddEndUserEvmAccount201, AddEndUserEvmSmartAccount201, AddEndUserSolanaAccount201, EndUser as OpenAPIEndUser } from "../../openapi-client/index.js";
1
+ import type { CreateEndUserBody, ListEndUsersParams, ImportEndUserBodyKeyType, AuthenticationMethods, AddEndUserEvmAccount201, AddEndUserEvmSmartAccount201, AddEndUserSolanaAccount201, EndUser as OpenAPIEndUser, SignEvmHashWithEndUserAccount200, SignEvmTransactionWithEndUserAccount200, SignEvmMessageWithEndUserAccount200, SignEvmTypedDataWithEndUserAccount200, SendEvmTransactionWithEndUserAccount200, SendEvmTransactionWithEndUserAccountBodyNetwork, SendEvmAssetWithEndUserAccount200, SendEvmAssetWithEndUserAccountBodyNetwork, SendUserOperationWithEndUserAccountResult, EvmUserOperationNetwork, EvmCall, CreateEvmEip7702DelegationWithEndUserAccount201, EvmEip7702DelegationNetwork, SignSolanaHashWithEndUserAccount200, SignSolanaMessageWithEndUserAccount200, SignSolanaTransactionWithEndUserAccount200, SendSolanaTransactionWithEndUserAccount200, SendSolanaTransactionWithEndUserAccountBodyNetwork, SendSolanaAssetWithEndUserAccount200, SendSolanaAssetWithEndUserAccountBodyNetwork, EIP712Message } from "../../openapi-client/index.js";
2
2
  import type { Prettify } from "../../types/utils.js";
3
3
  /**
4
4
  * The options for validating an access token.
@@ -99,6 +99,391 @@ export interface ImportEndUserOptions {
99
99
  */
100
100
  encryptionPublicKey?: string;
101
101
  }
102
+ /**
103
+ * The options for revoking all active delegations for an end user.
104
+ */
105
+ export interface RevokeDelegationForEndUserOptions {
106
+ /**
107
+ * The unique identifier of the end user.
108
+ */
109
+ userId: string;
110
+ }
111
+ /**
112
+ * The options for signing an EVM hash on behalf of an end user.
113
+ */
114
+ export interface SignEvmHashOptions {
115
+ /** The unique identifier of the end user. */
116
+ userId: string;
117
+ /** The 32-byte hash to sign, hex-encoded. */
118
+ hash: string;
119
+ /** The EVM address to sign with. */
120
+ address: string;
121
+ }
122
+ /**
123
+ * The result of signing an EVM hash on behalf of an end user.
124
+ */
125
+ export type SignEvmHashResult = SignEvmHashWithEndUserAccount200;
126
+ /**
127
+ * The options for signing an EVM transaction on behalf of an end user.
128
+ */
129
+ export interface SignEvmTransactionOptions {
130
+ /** The unique identifier of the end user. */
131
+ userId: string;
132
+ /** The EVM address to sign with. */
133
+ address: string;
134
+ /** The RLP-serialized EIP-1559 transaction to sign, hex-encoded. */
135
+ transaction: string;
136
+ }
137
+ /**
138
+ * The result of signing an EVM transaction on behalf of an end user.
139
+ */
140
+ export type SignEvmTransactionResult = SignEvmTransactionWithEndUserAccount200;
141
+ /**
142
+ * The options for signing an EVM message on behalf of an end user.
143
+ */
144
+ export interface SignEvmMessageOptions {
145
+ /** The unique identifier of the end user. */
146
+ userId: string;
147
+ /** The EVM address to sign with. */
148
+ address: string;
149
+ /** The EIP-191 message to sign. */
150
+ message: string;
151
+ }
152
+ /**
153
+ * The result of signing an EVM message on behalf of an end user.
154
+ */
155
+ export type SignEvmMessageResult = SignEvmMessageWithEndUserAccount200;
156
+ /**
157
+ * The options for signing EVM EIP-712 typed data on behalf of an end user.
158
+ */
159
+ export interface SignEvmTypedDataOptions {
160
+ /** The unique identifier of the end user. */
161
+ userId: string;
162
+ /** The EVM address to sign with. */
163
+ address: string;
164
+ /** The EIP-712 typed data to sign. */
165
+ typedData: EIP712Message;
166
+ }
167
+ /**
168
+ * The result of signing EVM typed data on behalf of an end user.
169
+ */
170
+ export type SignEvmTypedDataResult = SignEvmTypedDataWithEndUserAccount200;
171
+ /**
172
+ * The options for sending an EVM transaction on behalf of an end user.
173
+ */
174
+ export interface SendEvmTransactionOptions {
175
+ /** The unique identifier of the end user. */
176
+ userId: string;
177
+ /** The EVM address to send from. */
178
+ address: string;
179
+ /** The RLP-serialized EIP-1559 transaction to send, hex-encoded. */
180
+ transaction: string;
181
+ /** The network to send the transaction on. */
182
+ network: SendEvmTransactionWithEndUserAccountBodyNetwork;
183
+ }
184
+ /**
185
+ * The result of sending an EVM transaction on behalf of an end user.
186
+ */
187
+ export type SendEvmTransactionResult = SendEvmTransactionWithEndUserAccount200;
188
+ /**
189
+ * The options for sending an EVM asset on behalf of an end user.
190
+ */
191
+ export interface SendEvmAssetOptions {
192
+ /** The unique identifier of the end user. */
193
+ userId: string;
194
+ /** The EVM address to send from. */
195
+ address: string;
196
+ /** The asset to send. Defaults to "usdc". */
197
+ asset?: "usdc";
198
+ /** The recipient address. */
199
+ to: string;
200
+ /** The amount to send. */
201
+ amount: string;
202
+ /** The network to send on. */
203
+ network: SendEvmAssetWithEndUserAccountBodyNetwork;
204
+ /** Whether to use the CDP paymaster. */
205
+ useCdpPaymaster?: boolean;
206
+ /** A custom paymaster URL. */
207
+ paymasterUrl?: string;
208
+ }
209
+ /**
210
+ * The result of sending an EVM asset on behalf of an end user.
211
+ */
212
+ export type SendEvmAssetResult = SendEvmAssetWithEndUserAccount200;
213
+ /**
214
+ * The options for sending a user operation on behalf of an end user.
215
+ */
216
+ export interface SendUserOperationOptions {
217
+ /** The unique identifier of the end user. */
218
+ userId: string;
219
+ /** The EVM smart account address. */
220
+ address: string;
221
+ /** The network to send the user operation on. */
222
+ network: EvmUserOperationNetwork;
223
+ /** The calls to execute. */
224
+ calls: EvmCall[];
225
+ /** Whether to use the CDP paymaster. */
226
+ useCdpPaymaster: boolean;
227
+ /** A custom paymaster URL. */
228
+ paymasterUrl?: string;
229
+ /** An optional data suffix. */
230
+ dataSuffix?: string;
231
+ }
232
+ /**
233
+ * The result of sending a user operation on behalf of an end user.
234
+ */
235
+ export type SendUserOperationResult = SendUserOperationWithEndUserAccountResult;
236
+ /**
237
+ * The options for creating an EVM EIP-7702 delegation on behalf of an end user.
238
+ */
239
+ export interface CreateEvmEip7702DelegationOptions {
240
+ /** The unique identifier of the end user. */
241
+ userId: string;
242
+ /** The EVM address to delegate. */
243
+ address: string;
244
+ /** The network for the delegation. */
245
+ network: EvmEip7702DelegationNetwork;
246
+ /** Whether to enable spend permissions for the delegation. */
247
+ enableSpendPermissions?: boolean;
248
+ }
249
+ /**
250
+ * The result of creating an EVM EIP-7702 delegation on behalf of an end user.
251
+ */
252
+ export type CreateEvmEip7702DelegationForEndUserResult = CreateEvmEip7702DelegationWithEndUserAccount201;
253
+ /**
254
+ * The options for signing a Solana hash on behalf of an end user.
255
+ */
256
+ export interface SignSolanaHashOptions {
257
+ /** The unique identifier of the end user. */
258
+ userId: string;
259
+ /** The 32-byte hash to sign. */
260
+ hash: string;
261
+ /** The Solana address to sign with. */
262
+ address: string;
263
+ }
264
+ /**
265
+ * The result of signing a Solana hash on behalf of an end user.
266
+ */
267
+ export type SignSolanaHashResult = SignSolanaHashWithEndUserAccount200;
268
+ /**
269
+ * The options for signing a Solana message on behalf of an end user.
270
+ */
271
+ export interface SignSolanaMessageOptions {
272
+ /** The unique identifier of the end user. */
273
+ userId: string;
274
+ /** The Solana address to sign with. */
275
+ address: string;
276
+ /** The base64-encoded message to sign. */
277
+ message: string;
278
+ }
279
+ /**
280
+ * The result of signing a Solana message on behalf of an end user.
281
+ */
282
+ export type SignSolanaMessageResult = SignSolanaMessageWithEndUserAccount200;
283
+ /**
284
+ * The options for signing a Solana transaction on behalf of an end user.
285
+ */
286
+ export interface SignSolanaTransactionOptions {
287
+ /** The unique identifier of the end user. */
288
+ userId: string;
289
+ /** The Solana address to sign with. */
290
+ address: string;
291
+ /** The base64-encoded Solana transaction to sign. */
292
+ transaction: string;
293
+ }
294
+ /**
295
+ * The result of signing a Solana transaction on behalf of an end user.
296
+ */
297
+ export type SignSolanaTransactionResult = SignSolanaTransactionWithEndUserAccount200;
298
+ /**
299
+ * The options for sending a Solana transaction on behalf of an end user.
300
+ */
301
+ export interface SendSolanaTransactionOptions {
302
+ /** The unique identifier of the end user. */
303
+ userId: string;
304
+ /** The Solana address to send from. */
305
+ address: string;
306
+ /** The base64-encoded Solana transaction to send. */
307
+ transaction: string;
308
+ /** The Solana network to send on. */
309
+ network: SendSolanaTransactionWithEndUserAccountBodyNetwork;
310
+ }
311
+ /**
312
+ * The result of sending a Solana transaction on behalf of an end user.
313
+ */
314
+ export type SendSolanaTransactionResult = SendSolanaTransactionWithEndUserAccount200;
315
+ /**
316
+ * The options for sending a Solana asset on behalf of an end user.
317
+ */
318
+ export interface SendSolanaAssetOptions {
319
+ /** The unique identifier of the end user. */
320
+ userId: string;
321
+ /** The Solana address to send from. */
322
+ address: string;
323
+ /** The asset to send. Defaults to "usdc". */
324
+ asset?: "usdc";
325
+ /** The recipient address. */
326
+ to: string;
327
+ /** The amount to send. */
328
+ amount: string;
329
+ /** The Solana network to send on. */
330
+ network: SendSolanaAssetWithEndUserAccountBodyNetwork;
331
+ /** Whether to create the recipient's associated token account if it doesn't exist. */
332
+ createRecipientAta?: boolean;
333
+ }
334
+ /**
335
+ * The result of sending a Solana asset on behalf of an end user.
336
+ */
337
+ export type SendSolanaAssetResult = SendSolanaAssetWithEndUserAccount200;
338
+ /**
339
+ * The options for signing an EVM hash on an EndUser object.
340
+ */
341
+ export interface AccountSignEvmHashOptions {
342
+ /** The 32-byte hash to sign, hex-encoded. */
343
+ hash: string;
344
+ /** The EVM address to sign with. Uses the first EVM account if not provided. */
345
+ address?: string;
346
+ }
347
+ /**
348
+ * The options for signing an EVM transaction on an EndUser object.
349
+ */
350
+ export interface AccountSignEvmTransactionOptions {
351
+ /** The EVM address to sign with. Uses the first EVM account if not provided. */
352
+ address?: string;
353
+ /** The RLP-serialized EIP-1559 transaction to sign, hex-encoded. */
354
+ transaction: string;
355
+ }
356
+ /**
357
+ * The options for signing an EVM message on an EndUser object.
358
+ */
359
+ export interface AccountSignEvmMessageOptions {
360
+ /** The EVM address to sign with. Uses the first EVM account if not provided. */
361
+ address?: string;
362
+ /** The EIP-191 message to sign. */
363
+ message: string;
364
+ }
365
+ /**
366
+ * The options for signing EVM typed data on an EndUser object.
367
+ */
368
+ export interface AccountSignEvmTypedDataOptions {
369
+ /** The EVM address to sign with. Uses the first EVM account if not provided. */
370
+ address?: string;
371
+ /** The EIP-712 typed data to sign. */
372
+ typedData: EIP712Message;
373
+ }
374
+ /**
375
+ * The options for sending an EVM transaction on an EndUser object.
376
+ */
377
+ export interface AccountSendEvmTransactionOptions {
378
+ /** The EVM address to send from. Uses the first EVM account if not provided. */
379
+ address?: string;
380
+ /** The RLP-serialized EIP-1559 transaction to send, hex-encoded. */
381
+ transaction: string;
382
+ /** The network to send the transaction on. */
383
+ network: SendEvmTransactionWithEndUserAccountBodyNetwork;
384
+ }
385
+ /**
386
+ * The options for sending an EVM asset on an EndUser object.
387
+ */
388
+ export interface AccountSendEvmAssetOptions {
389
+ /** The EVM address to send from. Uses the first EVM account if not provided. */
390
+ address?: string;
391
+ /** The asset to send. Defaults to "usdc". */
392
+ asset?: "usdc";
393
+ /** The recipient address. */
394
+ to: string;
395
+ /** The amount to send. */
396
+ amount: string;
397
+ /** The network to send on. */
398
+ network: SendEvmAssetWithEndUserAccountBodyNetwork;
399
+ /** Whether to use the CDP paymaster. */
400
+ useCdpPaymaster?: boolean;
401
+ /** A custom paymaster URL. */
402
+ paymasterUrl?: string;
403
+ }
404
+ /**
405
+ * The options for sending a user operation on an EndUser object.
406
+ */
407
+ export interface AccountSendUserOperationOptions {
408
+ /** The EVM smart account address. Uses the first smart account if not provided. */
409
+ address?: string;
410
+ /** The network to send the user operation on. */
411
+ network: EvmUserOperationNetwork;
412
+ /** The calls to execute. */
413
+ calls: EvmCall[];
414
+ /** Whether to use the CDP paymaster. */
415
+ useCdpPaymaster: boolean;
416
+ /** A custom paymaster URL. */
417
+ paymasterUrl?: string;
418
+ /** An optional data suffix. */
419
+ dataSuffix?: string;
420
+ }
421
+ /**
422
+ * The options for creating an EVM EIP-7702 delegation on an EndUser object.
423
+ */
424
+ export interface AccountCreateEvmEip7702DelegationOptions {
425
+ /** The EVM address to delegate. Uses the first EVM account if not provided. */
426
+ address?: string;
427
+ /** The network for the delegation. */
428
+ network: EvmEip7702DelegationNetwork;
429
+ /** Whether to enable spend permissions for the delegation. */
430
+ enableSpendPermissions?: boolean;
431
+ }
432
+ /**
433
+ * The options for signing a Solana hash on an EndUser object.
434
+ */
435
+ export interface AccountSignSolanaHashOptions {
436
+ /** The 32-byte hash to sign. */
437
+ hash: string;
438
+ /** The Solana address to sign with. Uses the first Solana account if not provided. */
439
+ address?: string;
440
+ }
441
+ /**
442
+ * The options for signing a Solana message on an EndUser object.
443
+ */
444
+ export interface AccountSignSolanaMessageOptions {
445
+ /** The Solana address to sign with. Uses the first Solana account if not provided. */
446
+ address?: string;
447
+ /** The base64-encoded message to sign. */
448
+ message: string;
449
+ }
450
+ /**
451
+ * The options for signing a Solana transaction on an EndUser object.
452
+ */
453
+ export interface AccountSignSolanaTransactionOptions {
454
+ /** The Solana address to sign with. Uses the first Solana account if not provided. */
455
+ address?: string;
456
+ /** The base64-encoded Solana transaction to sign. */
457
+ transaction: string;
458
+ }
459
+ /**
460
+ * The options for sending a Solana transaction on an EndUser object.
461
+ */
462
+ export interface AccountSendSolanaTransactionOptions {
463
+ /** The Solana address to send from. Uses the first Solana account if not provided. */
464
+ address?: string;
465
+ /** The base64-encoded Solana transaction to send. */
466
+ transaction: string;
467
+ /** The Solana network to send on. */
468
+ network: SendSolanaTransactionWithEndUserAccountBodyNetwork;
469
+ }
470
+ /**
471
+ * The options for sending a Solana asset on an EndUser object.
472
+ */
473
+ export interface AccountSendSolanaAssetOptions {
474
+ /** The Solana address to send from. Uses the first Solana account if not provided. */
475
+ address?: string;
476
+ /** The asset to send. Defaults to "usdc". */
477
+ asset?: "usdc";
478
+ /** The recipient address. */
479
+ to: string;
480
+ /** The amount to send. */
481
+ amount: string;
482
+ /** The Solana network to send on. */
483
+ network: SendSolanaAssetWithEndUserAccountBodyNetwork;
484
+ /** Whether to create the recipient's associated token account if it doesn't exist. */
485
+ createRecipientAta?: boolean;
486
+ }
102
487
  /**
103
488
  * The options for adding an EVM smart account to an EndUser object.
104
489
  */
@@ -165,6 +550,111 @@ export type EndUserAccountActions = {
165
550
  * ```
166
551
  */
167
552
  addSolanaAccount: () => Promise<AddEndUserSolanaAccountResult>;
553
+ /**
554
+ * Revokes all active delegations for this end user.
555
+ * This operation can be performed by the end user themselves or by a developer using their API key.
556
+ *
557
+ * @returns A promise that resolves when the delegation has been revoked.
558
+ *
559
+ * @example
560
+ * ```ts
561
+ * const endUser = await cdp.endUser.getEndUser({ userId: "user-123" });
562
+ *
563
+ * await endUser.revokeDelegation();
564
+ * ```
565
+ */
566
+ revokeDelegation: () => Promise<void>;
567
+ /**
568
+ * Signs an EVM hash on behalf of this end user using a delegation.
569
+ *
570
+ * @param options - The signing options.
571
+ * @returns A promise that resolves to the signature.
572
+ */
573
+ signEvmHash: (options: AccountSignEvmHashOptions) => Promise<SignEvmHashResult>;
574
+ /**
575
+ * Signs an EVM transaction on behalf of this end user using a delegation.
576
+ *
577
+ * @param options - The signing options.
578
+ * @returns A promise that resolves to the signed transaction.
579
+ */
580
+ signEvmTransaction: (options: AccountSignEvmTransactionOptions) => Promise<SignEvmTransactionResult>;
581
+ /**
582
+ * Signs an EVM message on behalf of this end user using a delegation.
583
+ *
584
+ * @param options - The signing options.
585
+ * @returns A promise that resolves to the signature.
586
+ */
587
+ signEvmMessage: (options: AccountSignEvmMessageOptions) => Promise<SignEvmMessageResult>;
588
+ /**
589
+ * Signs EVM EIP-712 typed data on behalf of this end user using a delegation.
590
+ *
591
+ * @param options - The signing options.
592
+ * @returns A promise that resolves to the signature.
593
+ */
594
+ signEvmTypedData: (options: AccountSignEvmTypedDataOptions) => Promise<SignEvmTypedDataResult>;
595
+ /**
596
+ * Sends an EVM transaction on behalf of this end user using a delegation.
597
+ *
598
+ * @param options - The send options.
599
+ * @returns A promise that resolves to the transaction hash.
600
+ */
601
+ sendEvmTransaction: (options: AccountSendEvmTransactionOptions) => Promise<SendEvmTransactionResult>;
602
+ /**
603
+ * Sends an EVM asset on behalf of this end user using a delegation.
604
+ *
605
+ * @param options - The send options.
606
+ * @returns A promise that resolves to the transaction result.
607
+ */
608
+ sendEvmAsset: (options: AccountSendEvmAssetOptions) => Promise<SendEvmAssetResult>;
609
+ /**
610
+ * Sends a user operation on behalf of this end user using a delegation.
611
+ *
612
+ * @param options - The send options.
613
+ * @returns A promise that resolves to the user operation result.
614
+ */
615
+ sendUserOperation: (options: AccountSendUserOperationOptions) => Promise<SendUserOperationResult>;
616
+ /**
617
+ * Creates an EVM EIP-7702 delegation on behalf of this end user.
618
+ *
619
+ * @param options - The delegation options.
620
+ * @returns A promise that resolves to the delegation operation ID.
621
+ */
622
+ createEvmEip7702Delegation: (options: AccountCreateEvmEip7702DelegationOptions) => Promise<CreateEvmEip7702DelegationForEndUserResult>;
623
+ /**
624
+ * Signs a Solana hash on behalf of this end user using a delegation.
625
+ *
626
+ * @param options - The signing options.
627
+ * @returns A promise that resolves to the signature.
628
+ */
629
+ signSolanaHash: (options: AccountSignSolanaHashOptions) => Promise<SignSolanaHashResult>;
630
+ /**
631
+ * Signs a Solana message on behalf of this end user using a delegation.
632
+ *
633
+ * @param options - The signing options.
634
+ * @returns A promise that resolves to the signature.
635
+ */
636
+ signSolanaMessage: (options: AccountSignSolanaMessageOptions) => Promise<SignSolanaMessageResult>;
637
+ /**
638
+ * Signs a Solana transaction on behalf of this end user using a delegation.
639
+ *
640
+ * @param options - The signing options.
641
+ * @returns A promise that resolves to the signed transaction.
642
+ */
643
+ signSolanaTransaction: (options: AccountSignSolanaTransactionOptions) => Promise<SignSolanaTransactionResult>;
644
+ /**
645
+ * Sends a Solana transaction on behalf of this end user using a delegation.
646
+ *
647
+ * @param options - The send options.
648
+ * @returns A promise that resolves to the transaction signature.
649
+ */
650
+ sendSolanaTransaction: (options: AccountSendSolanaTransactionOptions) => Promise<SendSolanaTransactionResult>;
651
+ /**
652
+ * Sends a Solana asset on behalf of this end user using a delegation.
653
+ *
654
+ * @param options - The send options.
655
+ * @returns A promise that resolves to the transaction signature.
656
+ */
657
+ sendSolanaAsset: (options: AccountSendSolanaAssetOptions) => Promise<SendSolanaAssetResult>;
168
658
  };
169
659
  /**
170
660
  * An end user with actions that can be performed directly on the object.
@@ -1 +1 @@
1
- {"version":3,"file":"endUser.types.d.ts","sourceRoot":"","sources":["../../../client/end-user/endUser.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,iBAAiB,EACjB,kBAAkB,EAClB,wBAAwB,EACxB,qBAAqB,EACrB,uBAAuB,EACvB,4BAA4B,EAC5B,0BAA0B,EAC1B,OAAO,IAAI,cAAc,EAC1B,MAAM,+BAA+B,CAAC;AACvC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAErD;;GAEG;AACH,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,WAAW,EAAE,MAAM,CAAC;CACrB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;CAChB;AAED;;GAEG;AACH,MAAM,MAAM,mBAAmB,GAAG,kBAAkB,CAAC;AAErD;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG,iBAAiB,CAAC;AAErD;;GAEG;AACH,MAAM,WAAW,2BAA2B;IAC1C;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;CAChB;AAED;;GAEG;AACH,MAAM,MAAM,0BAA0B,GAAG,uBAAuB,CAAC;AAEjE;;GAEG;AACH,MAAM,WAAW,gCAAgC;IAC/C;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,sBAAsB,EAAE,OAAO,CAAC;CACjC;AAED;;GAEG;AACH,MAAM,MAAM,+BAA+B,GAAG,4BAA4B,CAAC;AAE3E;;GAEG;AACH,MAAM,WAAW,8BAA8B;IAC7C;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;CAChB;AAED;;GAEG;AACH,MAAM,MAAM,6BAA6B,GAAG,0BAA0B,CAAC;AAEvE;;GAEG;AACH,MAAM,WAAW,oBAAoB;IACnC;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;OAEG;IACH,qBAAqB,EAAE,qBAAqB,CAAC;IAC7C;;;;;OAKG;IACH,UAAU,EAAE,MAAM,GAAG,UAAU,CAAC;IAChC;;OAEG;IACH,OAAO,EAAE,wBAAwB,CAAC;IAClC;;;OAGG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B;AAED;;GAEG;AACH,MAAM,WAAW,yBAAyB;IACxC;;OAEG;IACH,sBAAsB,EAAE,OAAO,CAAC;CACjC;AAED;;GAEG;AACH,MAAM,MAAM,qBAAqB,GAAG;IAClC;;;;;;;;;;;;;;;OAeG;IACH,aAAa,EAAE,MAAM,OAAO,CAAC,0BAA0B,CAAC,CAAC;IAEzD;;;;;;;;;;;;;;;;;OAiBG;IACH,kBAAkB,EAAE,CAClB,OAAO,EAAE,yBAAyB,KAC/B,OAAO,CAAC,+BAA+B,CAAC,CAAC;IAE9C;;;;;;;;;;;;;;;OAeG;IACH,gBAAgB,EAAE,MAAM,OAAO,CAAC,6BAA6B,CAAC,CAAC;CAChE,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,cAAc,GAAG,QAAQ,CAAC,cAAc,GAAG,qBAAqB,CAAC,CAAC"}
1
+ {"version":3,"file":"endUser.types.d.ts","sourceRoot":"","sources":["../../../client/end-user/endUser.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,iBAAiB,EACjB,kBAAkB,EAClB,wBAAwB,EACxB,qBAAqB,EACrB,uBAAuB,EACvB,4BAA4B,EAC5B,0BAA0B,EAC1B,OAAO,IAAI,cAAc,EACzB,gCAAgC,EAChC,uCAAuC,EACvC,mCAAmC,EACnC,qCAA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AAG,QAAQ,CAAC,cAAc,GAAG,qBAAqB,CAAC,CAAC"}
@@ -6,10 +6,13 @@ import type { CdpOpenApiClientType, EndUser as OpenAPIEndUser } from "../../open
6
6
  export type ToEndUserAccountOptions = {
7
7
  /** The end user from the API response. */
8
8
  endUser: OpenAPIEndUser;
9
+ /** The CDP project ID. Required for delegation operations (signing, sending). */
10
+ projectId?: string;
9
11
  };
10
12
  /**
11
13
  * Creates an EndUserAccount instance with actions from an existing OpenAPI EndUser.
12
- * This wraps the raw API response and adds convenience methods for adding accounts.
14
+ * This wraps the raw API response and adds convenience methods for adding accounts
15
+ * and performing delegated signing/sending operations.
13
16
  *
14
17
  * @param apiClient - The API client.
15
18
  * @param options - Configuration options.
@@ -1 +1 @@
1
- {"version":3,"file":"toEndUserAccount.d.ts","sourceRoot":"","sources":["../../../client/end-user/toEndUserAccount.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,cAAc,EAKf,MAAM,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EACV,oBAAoB,EACpB,OAAO,IAAI,cAAc,EAC1B,MAAM,+BAA+B,CAAC;AAEvC;;GAEG;AACH,MAAM,MAAM,uBAAuB,GAAG;IACpC,0CAA0C;IAC1C,OAAO,EAAE,cAAc,CAAC;CACzB,CAAC;AAEF;;;;;;;;GAQG;AACH,wBAAgB,gBAAgB,CAC9B,SAAS,EAAE,oBAAoB,EAC/B,OAAO,EAAE,uBAAuB,GAC/B,cAAc,CA6ChB"}
1
+ {"version":3,"file":"toEndUserAccount.d.ts","sourceRoot":"","sources":["../../../client/end-user/toEndUserAccount.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,cAAc,EA+Bf,MAAM,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EACV,oBAAoB,EACpB,OAAO,IAAI,cAAc,EAC1B,MAAM,+BAA+B,CAAC;AAEvC;;GAEG;AACH,MAAM,MAAM,uBAAuB,GAAG;IACpC,0CAA0C;IAC1C,OAAO,EAAE,cAAc,CAAC;IACxB,iFAAiF;IACjF,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AAuEF;;;;;;;;;GASG;AACH,wBAAgB,gBAAgB,CAC9B,SAAS,EAAE,oBAAoB,EAC/B,OAAO,EAAE,uBAAuB,GAC/B,cAAc,CA2PhB"}
@@ -1,12 +1,14 @@
1
1
  /**
2
2
  * @module Client
3
3
  */
4
- import { CreateServerAccountOptions, CreateSmartAccountOptions, CreateSwapQuoteOptions, CreateSwapQuoteResult, EvmClientInterface, ExportServerAccountOptions, GetOrCreateServerAccountOptions, GetOrCreateSmartAccountOptions, GetServerAccountOptions, GetSmartAccountOptions, GetSwapPriceOptions, GetSwapPriceResult, GetUserOperationOptions, ImportServerAccountOptions, ListServerAccountResult, ListServerAccountsOptions, ListSmartAccountResult, ListSmartAccountsOptions, PrepareAndSendUserOperationOptions, PrepareUserOperationOptions, ServerAccount, SignatureResult, SignHashOptions, SignMessageOptions, SignTransactionOptions, SignTypedDataOptions, SmartAccount, SwapUnavailableResult, UpdateEvmAccountOptions, UpdateEvmSmartAccountOptions, UserOperation, WaitForUserOperationOptions } from "./evm.types.js";
4
+ import { CreateEvmEip7702DelegationResult, CreateServerAccountOptions, CreateSmartAccountOptions, CreateSwapQuoteOptions, CreateSwapQuoteResult, EvmClientInterface, ExportServerAccountOptions, GetOrCreateServerAccountOptions, GetOrCreateSmartAccountOptions, GetServerAccountOptions, GetSmartAccountOptions, GetSwapPriceOptions, GetSwapPriceResult, GetUserOperationOptions, ImportServerAccountOptions, ListServerAccountResult, ListServerAccountsOptions, ListSmartAccountResult, ListSmartAccountsOptions, PrepareAndSendUserOperationOptions, PrepareUserOperationOptions, ServerAccount, SignatureResult, SignHashOptions, SignMessageOptions, SignTransactionOptions, SignTypedDataOptions, SmartAccount, SwapUnavailableResult, UpdateEvmAccountOptions, UpdateEvmSmartAccountOptions, UserOperation, WaitForUserOperationOptions } from "./evm.types.js";
5
5
  import { ListSpendPermissionsResult } from "../../actions/evm/listSpendPermissions.js";
6
6
  import { ListTokenBalancesOptions, ListTokenBalancesResult } from "../../actions/evm/listTokenBalances.js";
7
7
  import { RequestFaucetOptions, RequestFaucetResult } from "../../actions/evm/requestFaucet.js";
8
8
  import { PrepareAndSendUserOperationReturnType, SendUserOperationOptions, SendUserOperationReturnType } from "../../actions/evm/sendUserOperation.js";
9
9
  import { WaitForUserOperationReturnType } from "../../actions/evm/waitForUserOperation.js";
10
+ import { EvmEip7702DelegationOperation } from "../../openapi-client/index.js";
11
+ import type { CreateEvmEip7702DelegationOptions, WaitForEvmEip7702DelegationOperationStatusOptions } from "./evm.types.js";
10
12
  import type { SendTransactionOptions, TransactionResult } from "../../actions/evm/sendTransaction.js";
11
13
  import type { CreateSpendPermissionOptions, ListSpendPermissionsOptions, RevokeSpendPermissionOptions } from "../../spend-permissions/types.js";
12
14
  /**
@@ -766,6 +768,57 @@ export declare class EvmClient implements EvmClientInterface {
766
768
  * @returns A promise that resolves to the updated account.
767
769
  */
768
770
  updateSmartAccount(options: UpdateEvmSmartAccountOptions): Promise<SmartAccount>;
771
+ /**
772
+ * Creates an EIP-7702 delegation for an EVM EOA account, upgrading it with smart account capabilities.
773
+ * The delegation allows the EVM EOA to be used as a smart account, which enables batched transactions and gas sponsorship via paymaster.
774
+ *
775
+ * @param {CreateEvmEip7702DelegationOptions} options - The delegation parameters (address and network required, enableSpendPermissions and idempotencyKey optional).
776
+ * @returns A promise that resolves to the delegation result including the delegation operation ID.
777
+ *
778
+ * @example
779
+ * ```ts
780
+ * const result = await cdp.evm.createEvmEip7702Delegation({
781
+ * address: account.address,
782
+ * network: "base-sepolia",
783
+ * enableSpendPermissions: false,
784
+ * });
785
+ * console.log(result.delegationOperationId);
786
+ * ```
787
+ */
788
+ createEvmEip7702Delegation(options: CreateEvmEip7702DelegationOptions): Promise<CreateEvmEip7702DelegationResult>;
789
+ /**
790
+ * Gets the EIP-7702 delegation operation status.
791
+ *
792
+ * @param {string} delegationOperationId - The delegation operation ID returned by createEvmEip7702Delegation.
793
+ * @returns A promise that resolves to the delegation operation status.
794
+ *
795
+ * @example
796
+ * ```ts
797
+ * const operation = await cdp.evm.getEvmEip7702DelegationOperationById(
798
+ * "delegation-op-123",
799
+ * );
800
+ * console.log(operation.status); // "PENDING" | "SUBMITTED" | "COMPLETED" | "FAILED"
801
+ * ```
802
+ */
803
+ getEvmEip7702DelegationOperationById(delegationOperationId: string): Promise<EvmEip7702DelegationOperation>;
804
+ /**
805
+ * Polls the EIP-7702 delegation operation status until the status is COMPLETED or a timeout occurs.
806
+ *
807
+ * @param {WaitForEvmEip7702DelegationOperationStatusOptions} options - Parameters for waiting, including delegationOperationId and optional wait configuration.
808
+ * @param {string} options.delegationOperationId - The delegation operation ID returned by createEvmEip7702Delegation.
809
+ * @param {WaitOptions} [options.waitOptions] - Optional parameters for the wait operation.
810
+ *
811
+ * @returns A promise that resolves to the delegation operation once it reaches COMPLETED.
812
+ *
813
+ * @example
814
+ * ```ts
815
+ * const operation = await cdp.evm.waitForEvmEip7702DelegationOperationStatus({
816
+ * delegationOperationId: "delegation-op-123",
817
+ * });
818
+ * console.log(operation.status); // "COMPLETED"
819
+ * ```
820
+ */
821
+ waitForEvmEip7702DelegationOperationStatus(options: WaitForEvmEip7702DelegationOperationStatusOptions): Promise<EvmEip7702DelegationOperation>;
769
822
  /**
770
823
  * Waits for a user operation to complete or fail.
771
824
  *
@@ -1 +1 @@
1
- {"version":3,"file":"evm.d.ts","sourceRoot":"","sources":["../../../client/evm/evm.ts"],"names":[],"mappings":"AAAA;;GAEG;AAMH,OAAO,EACL,0BAA0B,EAC1B,yBAAyB,EACzB,sBAAsB,EACtB,qBAAqB,EACrB,kBAAkB,EAClB,0BAA0B,EAC1B,+BAA+B,EAC/B,8BAA8B,EAC9B,uBAAuB,EACvB,sBAAsB,EACtB,mBAAmB,EACnB,kBAAkB,EAClB,uBAAuB,EACvB,0BAA0B,EAC1B,uBAAuB,EACvB,yBAAyB,EACzB,sBAAsB,EACtB,wBA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