@coinbase/cdp-sdk 1.45.0 → 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 (211) hide show
  1. package/CHANGELOG.md +14 -2
  2. package/README.md +47 -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/toEvmSmartAccount.js +6 -2
  6. package/_cjs/accounts/evm/toEvmSmartAccount.js.map +1 -1
  7. package/_cjs/accounts/evm/toNetworkScopedEvmSmartAccount.js +31 -0
  8. package/_cjs/accounts/evm/toNetworkScopedEvmSmartAccount.js.map +1 -1
  9. package/_cjs/actions/solana/transfer.js.map +1 -1
  10. package/_cjs/actions/solana/utils.js +9 -9
  11. package/_cjs/actions/solana/utils.js.map +1 -1
  12. package/_cjs/auth/utils/http.js +1 -0
  13. package/_cjs/auth/utils/http.js.map +1 -1
  14. package/_cjs/client/cdp.js +4 -1
  15. package/_cjs/client/cdp.js.map +1 -1
  16. package/_cjs/client/end-user/endUser.js +385 -4
  17. package/_cjs/client/end-user/endUser.js.map +1 -1
  18. package/_cjs/client/end-user/toEndUserAccount.js +201 -23
  19. package/_cjs/client/end-user/toEndUserAccount.js.map +1 -1
  20. package/_cjs/client/solana/solana.js +39 -13
  21. package/_cjs/client/solana/solana.js.map +1 -1
  22. package/_cjs/index.js.map +1 -1
  23. package/_cjs/openapi-client/cdpApiClient.js +32 -0
  24. package/_cjs/openapi-client/cdpApiClient.js.map +1 -1
  25. package/_cjs/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js +52 -15
  26. package/_cjs/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js.map +1 -1
  27. package/_cjs/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.js +261 -0
  28. package/_cjs/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.js.map +1 -0
  29. package/_cjs/openapi-client/generated/end-user-accounts/end-user-accounts.js.map +1 -1
  30. package/_cjs/openapi-client/generated/evm-accounts/evm-accounts.js.map +1 -1
  31. package/_cjs/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js +2 -2
  32. package/_cjs/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js.map +1 -1
  33. package/_cjs/openapi-client/generated/evm-swaps/evm-swaps.js.map +1 -1
  34. package/_cjs/openapi-client/generated/evm-token-balances/evm-token-balances.js.map +1 -1
  35. package/_cjs/openapi-client/generated/faucets/faucets.js +6 -5
  36. package/_cjs/openapi-client/generated/faucets/faucets.js.map +1 -1
  37. package/_cjs/openapi-client/generated/onchain-data/onchain-data.js.map +1 -1
  38. package/_cjs/openapi-client/generated/onramp/onramp.js.map +1 -1
  39. package/_cjs/openapi-client/generated/policy-engine/policy-engine.js.map +1 -1
  40. package/_cjs/openapi-client/generated/solana-accounts/solana-accounts.js.map +1 -1
  41. package/_cjs/openapi-client/generated/solana-token-balances/solana-token-balances.js.map +1 -1
  42. package/_cjs/openapi-client/generated/sql-api/sql-api.js +75 -0
  43. package/_cjs/openapi-client/generated/sql-api/sql-api.js.map +1 -0
  44. package/_cjs/openapi-client/generated/webhooks/webhooks.js.map +1 -1
  45. package/_cjs/openapi-client/generated/x402-facilitator/x402-facilitator.js.map +1 -1
  46. package/_cjs/openapi-client/index.js +4 -1
  47. package/_cjs/openapi-client/index.js.map +1 -1
  48. package/_cjs/utils/export.js +6 -5
  49. package/_cjs/utils/export.js.map +1 -1
  50. package/_cjs/version.js +1 -1
  51. package/_esm/accounts/evm/eip6492.js +46 -0
  52. package/_esm/accounts/evm/eip6492.js.map +1 -0
  53. package/_esm/accounts/evm/toEvmSmartAccount.js +6 -2
  54. package/_esm/accounts/evm/toEvmSmartAccount.js.map +1 -1
  55. package/_esm/accounts/evm/toNetworkScopedEvmSmartAccount.js +31 -0
  56. package/_esm/accounts/evm/toNetworkScopedEvmSmartAccount.js.map +1 -1
  57. package/_esm/actions/solana/transfer.js.map +1 -1
  58. package/_esm/actions/solana/utils.js +9 -9
  59. package/_esm/actions/solana/utils.js.map +1 -1
  60. package/_esm/auth/utils/http.js +1 -0
  61. package/_esm/auth/utils/http.js.map +1 -1
  62. package/_esm/client/cdp.js +4 -1
  63. package/_esm/client/cdp.js.map +1 -1
  64. package/_esm/client/end-user/endUser.js +385 -4
  65. package/_esm/client/end-user/endUser.js.map +1 -1
  66. package/_esm/client/end-user/toEndUserAccount.js +201 -23
  67. package/_esm/client/end-user/toEndUserAccount.js.map +1 -1
  68. package/_esm/client/solana/solana.js +39 -13
  69. package/_esm/client/solana/solana.js.map +1 -1
  70. package/_esm/index.js.map +1 -1
  71. package/_esm/openapi-client/cdpApiClient.js +32 -0
  72. package/_esm/openapi-client/cdpApiClient.js.map +1 -1
  73. package/_esm/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js +49 -12
  74. package/_esm/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js.map +1 -1
  75. package/_esm/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.js +243 -0
  76. package/_esm/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.js.map +1 -0
  77. package/_esm/openapi-client/generated/end-user-accounts/end-user-accounts.js.map +1 -1
  78. package/_esm/openapi-client/generated/evm-accounts/evm-accounts.js.map +1 -1
  79. package/_esm/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js +2 -2
  80. package/_esm/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js.map +1 -1
  81. package/_esm/openapi-client/generated/evm-swaps/evm-swaps.js.map +1 -1
  82. package/_esm/openapi-client/generated/evm-token-balances/evm-token-balances.js.map +1 -1
  83. package/_esm/openapi-client/generated/faucets/faucets.js +6 -5
  84. package/_esm/openapi-client/generated/faucets/faucets.js.map +1 -1
  85. package/_esm/openapi-client/generated/onchain-data/onchain-data.js.map +1 -1
  86. package/_esm/openapi-client/generated/onramp/onramp.js.map +1 -1
  87. package/_esm/openapi-client/generated/policy-engine/policy-engine.js.map +1 -1
  88. package/_esm/openapi-client/generated/solana-accounts/solana-accounts.js.map +1 -1
  89. package/_esm/openapi-client/generated/solana-token-balances/solana-token-balances.js.map +1 -1
  90. package/_esm/openapi-client/generated/sql-api/sql-api.js +70 -0
  91. package/_esm/openapi-client/generated/sql-api/sql-api.js.map +1 -0
  92. package/_esm/openapi-client/generated/webhooks/webhooks.js.map +1 -1
  93. package/_esm/openapi-client/generated/x402-facilitator/x402-facilitator.js.map +1 -1
  94. package/_esm/openapi-client/index.js +4 -1
  95. package/_esm/openapi-client/index.js.map +1 -1
  96. package/_esm/utils/export.js +6 -5
  97. package/_esm/utils/export.js.map +1 -1
  98. package/_esm/version.js +1 -1
  99. package/_types/accounts/evm/eip6492.d.ts +17 -0
  100. package/_types/accounts/evm/eip6492.d.ts.map +1 -0
  101. package/_types/accounts/evm/toEvmSmartAccount.d.ts.map +1 -1
  102. package/_types/accounts/evm/toNetworkScopedEvmSmartAccount.d.ts +4 -4
  103. package/_types/accounts/evm/toNetworkScopedEvmSmartAccount.d.ts.map +1 -1
  104. package/_types/accounts/evm/types.d.ts +3 -2
  105. package/_types/accounts/evm/types.d.ts.map +1 -1
  106. package/_types/actions/solana/transfer.d.ts +3 -4
  107. package/_types/actions/solana/transfer.d.ts.map +1 -1
  108. package/_types/actions/solana/types.d.ts +79 -29
  109. package/_types/actions/solana/types.d.ts.map +1 -1
  110. package/_types/actions/solana/utils.d.ts +10 -9
  111. package/_types/actions/solana/utils.d.ts.map +1 -1
  112. package/_types/auth/utils/http.d.ts.map +1 -1
  113. package/_types/client/cdp.d.ts +4 -0
  114. package/_types/client/cdp.d.ts.map +1 -1
  115. package/_types/client/end-user/endUser.d.ts +272 -1
  116. package/_types/client/end-user/endUser.d.ts.map +1 -1
  117. package/_types/client/end-user/endUser.types.d.ts +491 -1
  118. package/_types/client/end-user/endUser.types.d.ts.map +1 -1
  119. package/_types/client/end-user/toEndUserAccount.d.ts +4 -1
  120. package/_types/client/end-user/toEndUserAccount.d.ts.map +1 -1
  121. package/_types/client/evm/evm.types.d.ts.map +1 -1
  122. package/_types/client/solana/solana.d.ts +38 -12
  123. package/_types/client/solana/solana.d.ts.map +1 -1
  124. package/_types/index.d.ts +1 -1
  125. package/_types/index.d.ts.map +1 -1
  126. package/_types/openapi-client/cdpApiClient.d.ts.map +1 -1
  127. package/_types/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.d.ts +487 -119
  128. package/_types/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.d.ts.map +1 -1
  129. package/_types/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.d.ts +163 -0
  130. package/_types/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.d.ts.map +1 -0
  131. package/_types/openapi-client/generated/end-user-accounts/end-user-accounts.d.ts +9 -9
  132. package/_types/openapi-client/generated/end-user-accounts/end-user-accounts.d.ts.map +1 -1
  133. package/_types/openapi-client/generated/evm-accounts/evm-accounts.d.ts +16 -16
  134. package/_types/openapi-client/generated/evm-accounts/evm-accounts.d.ts.map +1 -1
  135. package/_types/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.d.ts +14 -14
  136. package/_types/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.d.ts.map +1 -1
  137. package/_types/openapi-client/generated/evm-swaps/evm-swaps.d.ts +3 -3
  138. package/_types/openapi-client/generated/evm-swaps/evm-swaps.d.ts.map +1 -1
  139. package/_types/openapi-client/generated/evm-token-balances/evm-token-balances.d.ts +2 -2
  140. package/_types/openapi-client/generated/evm-token-balances/evm-token-balances.d.ts.map +1 -1
  141. package/_types/openapi-client/generated/faucets/faucets.d.ts +9 -8
  142. package/_types/openapi-client/generated/faucets/faucets.d.ts.map +1 -1
  143. package/_types/openapi-client/generated/onchain-data/onchain-data.d.ts +3 -3
  144. package/_types/openapi-client/generated/onchain-data/onchain-data.d.ts.map +1 -1
  145. package/_types/openapi-client/generated/onramp/onramp.d.ts +5 -5
  146. package/_types/openapi-client/generated/onramp/onramp.d.ts.map +1 -1
  147. package/_types/openapi-client/generated/policy-engine/policy-engine.d.ts +6 -6
  148. package/_types/openapi-client/generated/policy-engine/policy-engine.d.ts.map +1 -1
  149. package/_types/openapi-client/generated/solana-accounts/solana-accounts.d.ts +12 -12
  150. package/_types/openapi-client/generated/solana-accounts/solana-accounts.d.ts.map +1 -1
  151. package/_types/openapi-client/generated/solana-token-balances/solana-token-balances.d.ts +2 -2
  152. package/_types/openapi-client/generated/solana-token-balances/solana-token-balances.d.ts.map +1 -1
  153. package/_types/openapi-client/generated/sql-api/sql-api.d.ts +73 -0
  154. package/_types/openapi-client/generated/sql-api/sql-api.d.ts.map +1 -0
  155. package/_types/openapi-client/generated/webhooks/webhooks.d.ts +6 -6
  156. package/_types/openapi-client/generated/webhooks/webhooks.d.ts.map +1 -1
  157. package/_types/openapi-client/generated/x402-facilitator/x402-facilitator.d.ts +4 -4
  158. package/_types/openapi-client/generated/x402-facilitator/x402-facilitator.d.ts.map +1 -1
  159. package/_types/openapi-client/index.d.ts +19 -3
  160. package/_types/openapi-client/index.d.ts.map +1 -1
  161. package/_types/policies/evmSchema.d.ts +26 -78
  162. package/_types/policies/evmSchema.d.ts.map +1 -1
  163. package/_types/policies/types.d.ts.map +1 -1
  164. package/_types/types/contract.d.ts.map +1 -1
  165. package/_types/utils/export.d.ts +1 -1
  166. package/_types/utils/export.d.ts.map +1 -1
  167. package/_types/version.d.ts +1 -1
  168. package/accounts/evm/eip6492.ts +60 -0
  169. package/accounts/evm/toEvmSmartAccount.ts +17 -4
  170. package/accounts/evm/toNetworkScopedEvmSmartAccount.ts +44 -5
  171. package/accounts/evm/types.ts +8 -3
  172. package/actions/solana/transfer.ts +3 -3
  173. package/actions/solana/types.ts +79 -29
  174. package/actions/solana/utils.ts +13 -11
  175. package/auth/utils/http.ts +1 -0
  176. package/client/cdp.ts +6 -1
  177. package/client/end-user/endUser.ts +513 -4
  178. package/client/end-user/endUser.types.ts +598 -0
  179. package/client/end-user/toEndUserAccount.ts +330 -26
  180. package/client/evm/evm.types.ts +4 -2
  181. package/client/solana/solana.ts +39 -13
  182. package/index.ts +31 -1
  183. package/openapi-client/cdpApiClient.ts +34 -0
  184. package/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.ts +566 -152
  185. package/openapi-client/generated/embedded-wallets-core-functionality/embedded-wallets-core-functionality.ts +455 -0
  186. package/openapi-client/generated/end-user-accounts/end-user-accounts.ts +12 -9
  187. package/openapi-client/generated/evm-accounts/evm-accounts.ts +19 -16
  188. package/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.ts +16 -16
  189. package/openapi-client/generated/evm-swaps/evm-swaps.ts +3 -3
  190. package/openapi-client/generated/evm-token-balances/evm-token-balances.ts +2 -2
  191. package/openapi-client/generated/faucets/faucets.ts +9 -8
  192. package/openapi-client/generated/onchain-data/onchain-data.ts +3 -3
  193. package/openapi-client/generated/onramp/onramp.ts +5 -5
  194. package/openapi-client/generated/policy-engine/policy-engine.ts +12 -6
  195. package/openapi-client/generated/solana-accounts/solana-accounts.ts +12 -12
  196. package/openapi-client/generated/solana-token-balances/solana-token-balances.ts +2 -2
  197. package/openapi-client/generated/sql-api/sql-api.ts +92 -0
  198. package/openapi-client/generated/webhooks/webhooks.ts +6 -6
  199. package/openapi-client/generated/x402-facilitator/x402-facilitator.ts +6 -4
  200. package/openapi-client/index.ts +4 -1
  201. package/package.json +7 -8
  202. package/types/contract.ts +2 -4
  203. package/utils/export.ts +6 -5
  204. package/version.ts +1 -1
  205. package/_cjs/openapi-client/generated/sql-api-alpha/sql-api-alpha.js +0 -55
  206. package/_cjs/openapi-client/generated/sql-api-alpha/sql-api-alpha.js.map +0 -1
  207. package/_esm/openapi-client/generated/sql-api-alpha/sql-api-alpha.js +0 -50
  208. package/_esm/openapi-client/generated/sql-api-alpha/sql-api-alpha.js.map +0 -1
  209. package/_types/openapi-client/generated/sql-api-alpha/sql-api-alpha.d.ts +0 -53
  210. package/_types/openapi-client/generated/sql-api-alpha/sql-api-alpha.d.ts.map +0 -1
  211. package/openapi-client/generated/sql-api-alpha/sql-api-alpha.ts +0 -72
@@ -0,0 +1,455 @@
1
+ /**
2
+ * Generated by orval v7.21.0 🍺
3
+ * Do not edit manually.
4
+ * Coinbase Developer Platform APIs
5
+ * The Coinbase Developer Platform APIs - leading the world's transition onchain.
6
+ * OpenAPI spec version: 2.0.0
7
+ */
8
+ import type {
9
+ BlockchainAddress,
10
+ CreateEvmEip7702DelegationWithEndUserAccount201,
11
+ CreateEvmEip7702DelegationWithEndUserAccountBody,
12
+ EvmUserOperation,
13
+ RevokeDelegationForEndUserBody,
14
+ RevokeSpendPermissionRequest,
15
+ SendEvmAssetWithEndUserAccount200,
16
+ SendEvmAssetWithEndUserAccountBody,
17
+ SendEvmTransactionWithEndUserAccount200,
18
+ SendEvmTransactionWithEndUserAccountBody,
19
+ SendSolanaAssetWithEndUserAccount200,
20
+ SendSolanaAssetWithEndUserAccountBody,
21
+ SendSolanaTransactionWithEndUserAccount200,
22
+ SendSolanaTransactionWithEndUserAccountBody,
23
+ SendUserOperationWithEndUserAccountBody,
24
+ SignEvmHashWithEndUserAccount200,
25
+ SignEvmHashWithEndUserAccountBody,
26
+ SignEvmMessageWithEndUserAccount200,
27
+ SignEvmMessageWithEndUserAccountBody,
28
+ SignEvmTransactionWithEndUserAccount200,
29
+ SignEvmTransactionWithEndUserAccountBody,
30
+ SignEvmTypedDataWithEndUserAccount200,
31
+ SignEvmTypedDataWithEndUserAccountBody,
32
+ SignSolanaHashWithEndUserAccount200,
33
+ SignSolanaHashWithEndUserAccountBody,
34
+ SignSolanaMessageWithEndUserAccount200,
35
+ SignSolanaMessageWithEndUserAccountBody,
36
+ SignSolanaTransactionWithEndUserAccount200,
37
+ SignSolanaTransactionWithEndUserAccountBody,
38
+ } from "../coinbaseDeveloperPlatformAPIs.schemas.js";
39
+
40
+ import { cdpApiClient } from "../../cdpApiClient.js";
41
+
42
+ type SecondParameter<T extends (...args: never) => unknown> = Parameters<T>[1];
43
+
44
+ /**
45
+ * Signs an arbitrary 32 byte hash with the end user's given EVM account.
46
+ * @summary Sign a hash with end user EVM account
47
+ */
48
+ export const signEvmHashWithEndUserAccount = (
49
+ projectId: string,
50
+ userId: string,
51
+ signEvmHashWithEndUserAccountBody: SignEvmHashWithEndUserAccountBody,
52
+ options?: SecondParameter<typeof cdpApiClient<SignEvmHashWithEndUserAccount200>>,
53
+ ) => {
54
+ return cdpApiClient<SignEvmHashWithEndUserAccount200>(
55
+ {
56
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/evm/sign`,
57
+ method: "POST",
58
+ headers: { "Content-Type": "application/json" },
59
+ data: signEvmHashWithEndUserAccountBody,
60
+ },
61
+ options,
62
+ );
63
+ };
64
+ /**
65
+ * Signs a transaction with the given end user EVM account.
66
+ The transaction should be serialized as a hex string using [RLP](https://ethereum.org/en/developers/docs/data-structures-and-encoding/rlp/).
67
+
68
+ The transaction must be an [EIP-1559 dynamic fee transaction](https://github.com/ethereum/EIPs/blob/master/EIPS/eip-1559.md). The developer is responsible for ensuring that the unsigned transaction is valid, as the API will not validate the transaction.
69
+ * @summary Sign a transaction with end user EVM account
70
+ */
71
+ export const signEvmTransactionWithEndUserAccount = (
72
+ projectId: string,
73
+ userId: string,
74
+ signEvmTransactionWithEndUserAccountBody: SignEvmTransactionWithEndUserAccountBody,
75
+ options?: SecondParameter<typeof cdpApiClient<SignEvmTransactionWithEndUserAccount200>>,
76
+ ) => {
77
+ return cdpApiClient<SignEvmTransactionWithEndUserAccount200>(
78
+ {
79
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/evm/sign/transaction`,
80
+ method: "POST",
81
+ headers: { "Content-Type": "application/json" },
82
+ data: signEvmTransactionWithEndUserAccountBody,
83
+ },
84
+ options,
85
+ );
86
+ };
87
+ /**
88
+ * Signs a transaction with the given end user EVM account and sends it to the indicated supported network. This API handles nonce management and gas estimation, leaving the developer to provide only the minimal set of fields necessary to send the transaction. The transaction should be serialized as a hex string using [RLP](https://ethereum.org/en/developers/docs/data-structures-and-encoding/rlp/).
89
+
90
+ The transaction must be an [EIP-1559 dynamic fee transaction](https://github.com/ethereum/EIPs/blob/master/EIPS/eip-1559.md).
91
+
92
+
93
+ **Transaction fields and API behavior**
94
+
95
+ - `to` *(Required)*: The address of the contract or account to send the transaction to.
96
+ - `chainId` *(Ignored)*: The value of the `chainId` field in the transaction is ignored.
97
+ The transaction will be sent to the network indicated by the `network` field in the request body.
98
+
99
+ - `nonce` *(Optional)*: The nonce to use for the transaction. If not provided, the API will assign
100
+ a nonce to the transaction based on the current state of the account.
101
+
102
+ - `maxPriorityFeePerGas` *(Optional)*: The maximum priority fee per gas to use for the transaction.
103
+ If not provided, the API will estimate a value based on current network conditions.
104
+
105
+ - `maxFeePerGas` *(Optional)*: The maximum fee per gas to use for the transaction.
106
+ If not provided, the API will estimate a value based on current network conditions.
107
+
108
+ - `gasLimit` *(Optional)*: The gas limit to use for the transaction. If not provided, the API will estimate a value
109
+ based on the `to` and `data` fields of the transaction.
110
+
111
+ - `value` *(Optional)*: The amount of ETH, in wei, to send with the transaction.
112
+ - `data` *(Optional)*: The data to send with the transaction; only used for contract calls.
113
+ - `accessList` *(Optional)*: The access list to use for the transaction.
114
+ * @summary Send a transaction with end user EVM account
115
+ */
116
+ export const sendEvmTransactionWithEndUserAccount = (
117
+ projectId: string,
118
+ userId: string,
119
+ sendEvmTransactionWithEndUserAccountBody: SendEvmTransactionWithEndUserAccountBody,
120
+ options?: SecondParameter<typeof cdpApiClient<SendEvmTransactionWithEndUserAccount200>>,
121
+ ) => {
122
+ return cdpApiClient<SendEvmTransactionWithEndUserAccount200>(
123
+ {
124
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/evm/send/transaction`,
125
+ method: "POST",
126
+ headers: { "Content-Type": "application/json" },
127
+ data: sendEvmTransactionWithEndUserAccountBody,
128
+ },
129
+ options,
130
+ );
131
+ };
132
+ /**
133
+ * Sends USDC from an end user's EVM account (EOA or Smart Account) to a recipient address on a supported EVM network. This endpoint simplifies USDC transfers by automatically handling contract resolution, decimal conversion, gas estimation, and transaction encoding.
134
+ The `amount` field accepts human-readable amounts as decimal strings (e.g., "1.5", "25.50").
135
+ * @summary Send USDC on EVM
136
+ */
137
+ export const sendEvmAssetWithEndUserAccount = (
138
+ projectId: string,
139
+ userId: string,
140
+ address: BlockchainAddress,
141
+ asset: "usdc",
142
+ sendEvmAssetWithEndUserAccountBody: SendEvmAssetWithEndUserAccountBody,
143
+ options?: SecondParameter<typeof cdpApiClient<SendEvmAssetWithEndUserAccount200>>,
144
+ ) => {
145
+ return cdpApiClient<SendEvmAssetWithEndUserAccount200>(
146
+ {
147
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/evm/${address}/send/${asset}`,
148
+ method: "POST",
149
+ headers: { "Content-Type": "application/json" },
150
+ data: sendEvmAssetWithEndUserAccountBody,
151
+ },
152
+ options,
153
+ );
154
+ };
155
+ /**
156
+ * Signs an [EIP-191](https://eips.ethereum.org/EIPS/eip-191) message with the given end user EVM account.
157
+
158
+ Per the specification, the message in the request body is prepended with `0x19 <0x45 (E)> <thereum Signed Message:\n" + len(message)>` before being signed.
159
+ * @summary Sign an EIP-191 message with end user EVM account
160
+ */
161
+ export const signEvmMessageWithEndUserAccount = (
162
+ projectId: string,
163
+ userId: string,
164
+ signEvmMessageWithEndUserAccountBody: SignEvmMessageWithEndUserAccountBody,
165
+ options?: SecondParameter<typeof cdpApiClient<SignEvmMessageWithEndUserAccount200>>,
166
+ ) => {
167
+ return cdpApiClient<SignEvmMessageWithEndUserAccount200>(
168
+ {
169
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/evm/sign/message`,
170
+ method: "POST",
171
+ headers: { "Content-Type": "application/json" },
172
+ data: signEvmMessageWithEndUserAccountBody,
173
+ },
174
+ options,
175
+ );
176
+ };
177
+ /**
178
+ * Signs [EIP-712](https://eips.ethereum.org/EIPS/eip-712) typed data with the given end user EVM account.
179
+ * @summary Sign EIP-712 typed data with end user EVM account
180
+ */
181
+ export const signEvmTypedDataWithEndUserAccount = (
182
+ projectId: string,
183
+ userId: string,
184
+ signEvmTypedDataWithEndUserAccountBody: SignEvmTypedDataWithEndUserAccountBody,
185
+ options?: SecondParameter<typeof cdpApiClient<SignEvmTypedDataWithEndUserAccount200>>,
186
+ ) => {
187
+ return cdpApiClient<SignEvmTypedDataWithEndUserAccount200>(
188
+ {
189
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/evm/sign/typed-data`,
190
+ method: "POST",
191
+ headers: { "Content-Type": "application/json" },
192
+ data: signEvmTypedDataWithEndUserAccountBody,
193
+ },
194
+ options,
195
+ );
196
+ };
197
+ /**
198
+ * Revokes all active delegations for the specified end user. This operation can be performed by the end user themselves or by a developer using their API key.
199
+ * @summary Revoke delegation for end user
200
+ */
201
+ export const revokeDelegationForEndUser = (
202
+ projectId: string,
203
+ userId: string,
204
+ revokeDelegationForEndUserBody: RevokeDelegationForEndUserBody,
205
+ options?: SecondParameter<typeof cdpApiClient<void>>,
206
+ ) => {
207
+ return cdpApiClient<void>(
208
+ {
209
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/delegation`,
210
+ method: "DELETE",
211
+ headers: { "Content-Type": "application/json" },
212
+ data: revokeDelegationForEndUserBody,
213
+ },
214
+ options,
215
+ );
216
+ };
217
+ /**
218
+ * Creates an EIP-7702 delegation for an end user's EVM EOA account, upgrading it with smart account capabilities.
219
+
220
+ This endpoint:
221
+ - Retrieves delegation artifacts from onchain
222
+ - Signs the EIP-7702 authorization for delegation
223
+ - Assembles and submits a Type 4 transaction
224
+ - Creates an associated smart account object
225
+
226
+ The delegation allows the EVM EOA to be used as a smart account, which enables batched transactions and gas sponsorship via paymaster.
227
+ * @summary Create EIP-7702 delegation for end user EVM account
228
+ */
229
+ export const createEvmEip7702DelegationWithEndUserAccount = (
230
+ projectId: string,
231
+ userId: string,
232
+ createEvmEip7702DelegationWithEndUserAccountBody: CreateEvmEip7702DelegationWithEndUserAccountBody,
233
+ options?: SecondParameter<typeof cdpApiClient<CreateEvmEip7702DelegationWithEndUserAccount201>>,
234
+ ) => {
235
+ return cdpApiClient<CreateEvmEip7702DelegationWithEndUserAccount201>(
236
+ {
237
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/evm/eip7702/delegation`,
238
+ method: "POST",
239
+ headers: { "Content-Type": "application/json" },
240
+ data: createEvmEip7702DelegationWithEndUserAccountBody,
241
+ },
242
+ options,
243
+ );
244
+ };
245
+ /**
246
+ * Prepares, signs, and sends a user operation for an end user's Smart Account.
247
+ * @summary Send a user operation for end user Smart Account
248
+ */
249
+ export const sendUserOperationWithEndUserAccount = (
250
+ projectId: string,
251
+ userId: string,
252
+ address: string,
253
+ sendUserOperationWithEndUserAccountBody: SendUserOperationWithEndUserAccountBody,
254
+ options?: SecondParameter<typeof cdpApiClient<EvmUserOperation>>,
255
+ ) => {
256
+ return cdpApiClient<EvmUserOperation>(
257
+ {
258
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/evm/smart-accounts/${address}/send`,
259
+ method: "POST",
260
+ headers: { "Content-Type": "application/json" },
261
+ data: sendUserOperationWithEndUserAccountBody,
262
+ },
263
+ options,
264
+ );
265
+ };
266
+ /**
267
+ * Revokes an existing spend permission.
268
+ * @summary Revoke a spend permission
269
+ */
270
+ export const revokeSpendPermissionWithEndUserAccount = (
271
+ projectId: string,
272
+ userId: string,
273
+ address: string,
274
+ revokeSpendPermissionRequest: RevokeSpendPermissionRequest,
275
+ options?: SecondParameter<typeof cdpApiClient<EvmUserOperation>>,
276
+ ) => {
277
+ return cdpApiClient<EvmUserOperation>(
278
+ {
279
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/evm/smart-accounts/${address}/spend-permissions/revoke`,
280
+ method: "POST",
281
+ headers: { "Content-Type": "application/json" },
282
+ data: revokeSpendPermissionRequest,
283
+ },
284
+ options,
285
+ );
286
+ };
287
+ /**
288
+ * Signs an arbitrary 32 byte hash with the end user's given Solana account.
289
+ * @summary Sign a hash with end user Solana account
290
+ */
291
+ export const signSolanaHashWithEndUserAccount = (
292
+ projectId: string,
293
+ userId: string,
294
+ signSolanaHashWithEndUserAccountBody: SignSolanaHashWithEndUserAccountBody,
295
+ options?: SecondParameter<typeof cdpApiClient<SignSolanaHashWithEndUserAccount200>>,
296
+ ) => {
297
+ return cdpApiClient<SignSolanaHashWithEndUserAccount200>(
298
+ {
299
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/solana/sign`,
300
+ method: "POST",
301
+ headers: { "Content-Type": "application/json" },
302
+ data: signSolanaHashWithEndUserAccountBody,
303
+ },
304
+ options,
305
+ );
306
+ };
307
+ /**
308
+ * Signs an arbitrary Base64 encoded message with the given Solana account.
309
+ **WARNING:** Never sign a message that you didn't generate as it may put your funds at risk.
310
+ * @summary Sign a Base64 encoded message
311
+ */
312
+ export const signSolanaMessageWithEndUserAccount = (
313
+ projectId: string,
314
+ userId: string,
315
+ signSolanaMessageWithEndUserAccountBody: SignSolanaMessageWithEndUserAccountBody,
316
+ options?: SecondParameter<typeof cdpApiClient<SignSolanaMessageWithEndUserAccount200>>,
317
+ ) => {
318
+ return cdpApiClient<SignSolanaMessageWithEndUserAccount200>(
319
+ {
320
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/solana/sign/message`,
321
+ method: "POST",
322
+ headers: { "Content-Type": "application/json" },
323
+ data: signSolanaMessageWithEndUserAccountBody,
324
+ },
325
+ options,
326
+ );
327
+ };
328
+ /**
329
+ * Signs a transaction with the given end user Solana account.
330
+ The unsigned transaction should be serialized into a byte array and then encoded as base64.
331
+ **Transaction types**
332
+ The following transaction types are supported:
333
+ * [Legacy transactions](https://solana-labs.github.io/solana-web3.js/classes/Transaction.html)
334
+ * [Versioned transactions](https://solana-labs.github.io/solana-web3.js/classes/VersionedTransaction.html)
335
+ The developer is responsible for ensuring that the unsigned transaction is valid, as the API will not validate the transaction.
336
+ * @summary Sign a transaction with end user Solana account
337
+ */
338
+ export const signSolanaTransactionWithEndUserAccount = (
339
+ projectId: string,
340
+ userId: string,
341
+ signSolanaTransactionWithEndUserAccountBody: SignSolanaTransactionWithEndUserAccountBody,
342
+ options?: SecondParameter<typeof cdpApiClient<SignSolanaTransactionWithEndUserAccount200>>,
343
+ ) => {
344
+ return cdpApiClient<SignSolanaTransactionWithEndUserAccount200>(
345
+ {
346
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/solana/sign/transaction`,
347
+ method: "POST",
348
+ headers: { "Content-Type": "application/json" },
349
+ data: signSolanaTransactionWithEndUserAccountBody,
350
+ },
351
+ options,
352
+ );
353
+ };
354
+ /**
355
+ * Signs a transaction with the given end user Solana account and sends it to the indicated supported network.
356
+ The API handles recent blockhash management and fee estimation, leaving the developer to provide only the minimal set of fields necessary to send the transaction.
357
+ The unsigned transaction should be serialized into a byte array and then encoded as base64.
358
+ **Transaction types**
359
+ The following transaction types are supported:
360
+ * [Legacy transactions](https://solana.com/developers/guides/advanced/versions#current-transaction-versions)
361
+ * [Versioned transactions](https://solana.com/developers/guides/advanced/versions)
362
+ **Instruction Batching**
363
+ To batch multiple operations, include multiple instructions within a single transaction. All instructions within a transaction are executed atomically - if any instruction fails, the entire transaction fails and is rolled back.
364
+ **Network Support**
365
+ The following Solana networks are supported:
366
+ * `solana` - Solana Mainnet
367
+ * `solana-devnet` - Solana Devnet
368
+ The developer is responsible for ensuring that the unsigned transaction is valid, as the API will not validate the transaction.
369
+ * @summary Send a transaction with end user Solana account
370
+ */
371
+ export const sendSolanaTransactionWithEndUserAccount = (
372
+ projectId: string,
373
+ userId: string,
374
+ sendSolanaTransactionWithEndUserAccountBody: SendSolanaTransactionWithEndUserAccountBody,
375
+ options?: SecondParameter<typeof cdpApiClient<SendSolanaTransactionWithEndUserAccount200>>,
376
+ ) => {
377
+ return cdpApiClient<SendSolanaTransactionWithEndUserAccount200>(
378
+ {
379
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/solana/send/transaction`,
380
+ method: "POST",
381
+ headers: { "Content-Type": "application/json" },
382
+ data: sendSolanaTransactionWithEndUserAccountBody,
383
+ },
384
+ options,
385
+ );
386
+ };
387
+ /**
388
+ * Sends USDC from an end user's Solana account to a recipient address on the Solana network. This endpoint simplifies USDC transfers by automatically handling mint resolution, Associated Token Account (ATA) creation, decimal conversion, and transaction encoding.
389
+ The `amount` field accepts human-readable amounts as decimal strings (e.g., "1.5", "25.50").
390
+ Use the optional `createRecipientAta` parameter to control whether the sender pays for creating the recipient's Associated Token Account if it doesn't exist.
391
+ * @summary Send USDC on Solana
392
+ */
393
+ export const sendSolanaAssetWithEndUserAccount = (
394
+ projectId: string,
395
+ userId: string,
396
+ address: BlockchainAddress,
397
+ asset: "usdc",
398
+ sendSolanaAssetWithEndUserAccountBody: SendSolanaAssetWithEndUserAccountBody,
399
+ options?: SecondParameter<typeof cdpApiClient<SendSolanaAssetWithEndUserAccount200>>,
400
+ ) => {
401
+ return cdpApiClient<SendSolanaAssetWithEndUserAccount200>(
402
+ {
403
+ url: `/v2/embedded-wallet-api/projects/${projectId}/end-users/${userId}/solana/${address}/send/${asset}`,
404
+ method: "POST",
405
+ headers: { "Content-Type": "application/json" },
406
+ data: sendSolanaAssetWithEndUserAccountBody,
407
+ },
408
+ options,
409
+ );
410
+ };
411
+ export type SignEvmHashWithEndUserAccountResult = NonNullable<
412
+ Awaited<ReturnType<typeof signEvmHashWithEndUserAccount>>
413
+ >;
414
+ export type SignEvmTransactionWithEndUserAccountResult = NonNullable<
415
+ Awaited<ReturnType<typeof signEvmTransactionWithEndUserAccount>>
416
+ >;
417
+ export type SendEvmTransactionWithEndUserAccountResult = NonNullable<
418
+ Awaited<ReturnType<typeof sendEvmTransactionWithEndUserAccount>>
419
+ >;
420
+ export type SendEvmAssetWithEndUserAccountResult = NonNullable<
421
+ Awaited<ReturnType<typeof sendEvmAssetWithEndUserAccount>>
422
+ >;
423
+ export type SignEvmMessageWithEndUserAccountResult = NonNullable<
424
+ Awaited<ReturnType<typeof signEvmMessageWithEndUserAccount>>
425
+ >;
426
+ export type SignEvmTypedDataWithEndUserAccountResult = NonNullable<
427
+ Awaited<ReturnType<typeof signEvmTypedDataWithEndUserAccount>>
428
+ >;
429
+ export type RevokeDelegationForEndUserResult = NonNullable<
430
+ Awaited<ReturnType<typeof revokeDelegationForEndUser>>
431
+ >;
432
+ export type CreateEvmEip7702DelegationWithEndUserAccountResult = NonNullable<
433
+ Awaited<ReturnType<typeof createEvmEip7702DelegationWithEndUserAccount>>
434
+ >;
435
+ export type SendUserOperationWithEndUserAccountResult = NonNullable<
436
+ Awaited<ReturnType<typeof sendUserOperationWithEndUserAccount>>
437
+ >;
438
+ export type RevokeSpendPermissionWithEndUserAccountResult = NonNullable<
439
+ Awaited<ReturnType<typeof revokeSpendPermissionWithEndUserAccount>>
440
+ >;
441
+ export type SignSolanaHashWithEndUserAccountResult = NonNullable<
442
+ Awaited<ReturnType<typeof signSolanaHashWithEndUserAccount>>
443
+ >;
444
+ export type SignSolanaMessageWithEndUserAccountResult = NonNullable<
445
+ Awaited<ReturnType<typeof signSolanaMessageWithEndUserAccount>>
446
+ >;
447
+ export type SignSolanaTransactionWithEndUserAccountResult = NonNullable<
448
+ Awaited<ReturnType<typeof signSolanaTransactionWithEndUserAccount>>
449
+ >;
450
+ export type SendSolanaTransactionWithEndUserAccountResult = NonNullable<
451
+ Awaited<ReturnType<typeof sendSolanaTransactionWithEndUserAccount>>
452
+ >;
453
+ export type SendSolanaAssetWithEndUserAccountResult = NonNullable<
454
+ Awaited<ReturnType<typeof sendSolanaAssetWithEndUserAccount>>
455
+ >;
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Generated by orval v7.6.0 🍺
2
+ * Generated by orval v7.21.0 🍺
3
3
  * Do not edit manually.
4
4
  * Coinbase Developer Platform APIs
5
5
  * The Coinbase Developer Platform APIs - leading the world's transition onchain.
@@ -31,7 +31,7 @@ This API is intended to be used by the developer's own backend, and is authentic
31
31
  */
32
32
  export const createEndUser = (
33
33
  createEndUserBody: CreateEndUserBody,
34
- options?: SecondParameter<typeof cdpApiClient>,
34
+ options?: SecondParameter<typeof cdpApiClient<EndUser>>,
35
35
  ) => {
36
36
  return cdpApiClient<EndUser>(
37
37
  {
@@ -50,7 +50,7 @@ By default, the response is sorted by creation date in ascending order and pagin
50
50
  */
51
51
  export const listEndUsers = (
52
52
  params?: ListEndUsersParams,
53
- options?: SecondParameter<typeof cdpApiClient>,
53
+ options?: SecondParameter<typeof cdpApiClient<ListEndUsers200>>,
54
54
  ) => {
55
55
  return cdpApiClient<ListEndUsers200>({ url: `/v2/end-users`, method: "GET", params }, options);
56
56
  };
@@ -62,7 +62,7 @@ This API is intended to be used by the developer's own backend, and is authentic
62
62
  */
63
63
  export const validateEndUserAccessToken = (
64
64
  validateEndUserAccessTokenBody: ValidateEndUserAccessTokenBody,
65
- options?: SecondParameter<typeof cdpApiClient>,
65
+ options?: SecondParameter<typeof cdpApiClient<EndUser>>,
66
66
  ) => {
67
67
  return cdpApiClient<EndUser>(
68
68
  {
@@ -80,7 +80,10 @@ export const validateEndUserAccessToken = (
80
80
  This API is intended to be used by the developer's own backend, and is authenticated using the developer's CDP API key.
81
81
  * @summary Get an end user
82
82
  */
83
- export const getEndUser = (userId: string, options?: SecondParameter<typeof cdpApiClient>) => {
83
+ export const getEndUser = (
84
+ userId: string,
85
+ options?: SecondParameter<typeof cdpApiClient<EndUser>>,
86
+ ) => {
84
87
  return cdpApiClient<EndUser>({ url: `/v2/end-users/${userId}`, method: "GET" }, options);
85
88
  };
86
89
  /**
@@ -91,7 +94,7 @@ This API is intended to be used by the developer's own backend, and is authentic
91
94
  export const addEndUserEvmAccount = (
92
95
  userId: string,
93
96
  addEndUserEvmAccountBody?: AddEndUserEvmAccountBody,
94
- options?: SecondParameter<typeof cdpApiClient>,
97
+ options?: SecondParameter<typeof cdpApiClient<AddEndUserEvmAccount201>>,
95
98
  ) => {
96
99
  return cdpApiClient<AddEndUserEvmAccount201>(
97
100
  {
@@ -111,7 +114,7 @@ This API is intended to be used by the developer's own backend, and is authentic
111
114
  export const addEndUserEvmSmartAccount = (
112
115
  userId: string,
113
116
  addEndUserEvmSmartAccountBody?: AddEndUserEvmSmartAccountBody,
114
- options?: SecondParameter<typeof cdpApiClient>,
117
+ options?: SecondParameter<typeof cdpApiClient<AddEndUserEvmSmartAccount201>>,
115
118
  ) => {
116
119
  return cdpApiClient<AddEndUserEvmSmartAccount201>(
117
120
  {
@@ -131,7 +134,7 @@ This API is intended to be used by the developer's own backend, and is authentic
131
134
  export const addEndUserSolanaAccount = (
132
135
  userId: string,
133
136
  addEndUserSolanaAccountBody?: AddEndUserSolanaAccountBody,
134
- options?: SecondParameter<typeof cdpApiClient>,
137
+ options?: SecondParameter<typeof cdpApiClient<AddEndUserSolanaAccount201>>,
135
138
  ) => {
136
139
  return cdpApiClient<AddEndUserSolanaAccount201>(
137
140
  {
@@ -151,7 +154,7 @@ This endpoint allows developers to import existing keys for their end users, sup
151
154
  */
152
155
  export const importEndUser = (
153
156
  importEndUserBody: ImportEndUserBody,
154
- options?: SecondParameter<typeof cdpApiClient>,
157
+ options?: SecondParameter<typeof cdpApiClient<EndUser>>,
155
158
  ) => {
156
159
  return cdpApiClient<EndUser>(
157
160
  {
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Generated by orval v7.6.0 🍺
2
+ * Generated by orval v7.21.0 🍺
3
3
  * Do not edit manually.
4
4
  * Coinbase Developer Platform APIs
5
5
  * The Coinbase Developer Platform APIs - leading the world's transition onchain.
@@ -42,7 +42,7 @@ The response is paginated, and by default, returns 20 accounts per page.
42
42
  */
43
43
  export const listEvmAccounts = (
44
44
  params?: ListEvmAccountsParams,
45
- options?: SecondParameter<typeof cdpApiClient>,
45
+ options?: SecondParameter<typeof cdpApiClient<ListEvmAccounts200>>,
46
46
  ) => {
47
47
  return cdpApiClient<ListEvmAccounts200>(
48
48
  { url: `/v2/evm/accounts`, method: "GET", params },
@@ -55,7 +55,7 @@ export const listEvmAccounts = (
55
55
  */
56
56
  export const createEvmAccount = (
57
57
  createEvmAccountBody?: CreateEvmAccountBody,
58
- options?: SecondParameter<typeof cdpApiClient>,
58
+ options?: SecondParameter<typeof cdpApiClient<EvmAccount>>,
59
59
  ) => {
60
60
  return cdpApiClient<EvmAccount>(
61
61
  {
@@ -71,7 +71,10 @@ export const createEvmAccount = (
71
71
  * Gets an EVM account by its address.
72
72
  * @summary Get an EVM account by address
73
73
  */
74
- export const getEvmAccount = (address: string, options?: SecondParameter<typeof cdpApiClient>) => {
74
+ export const getEvmAccount = (
75
+ address: string,
76
+ options?: SecondParameter<typeof cdpApiClient<EvmAccount>>,
77
+ ) => {
75
78
  return cdpApiClient<EvmAccount>({ url: `/v2/evm/accounts/${address}`, method: "GET" }, options);
76
79
  };
77
80
  /**
@@ -81,7 +84,7 @@ export const getEvmAccount = (address: string, options?: SecondParameter<typeof
81
84
  export const updateEvmAccount = (
82
85
  address: string,
83
86
  updateEvmAccountBody: UpdateEvmAccountBody,
84
- options?: SecondParameter<typeof cdpApiClient>,
87
+ options?: SecondParameter<typeof cdpApiClient<EvmAccount>>,
85
88
  ) => {
86
89
  return cdpApiClient<EvmAccount>(
87
90
  {
@@ -99,7 +102,7 @@ export const updateEvmAccount = (
99
102
  */
100
103
  export const getEvmAccountByName = (
101
104
  name: string,
102
- options?: SecondParameter<typeof cdpApiClient>,
105
+ options?: SecondParameter<typeof cdpApiClient<EvmAccount>>,
103
106
  ) => {
104
107
  return cdpApiClient<EvmAccount>(
105
108
  { url: `/v2/evm/accounts/by-name/${name}`, method: "GET" },
@@ -138,7 +141,7 @@ The transaction must be an [EIP-1559 dynamic fee transaction](https://github.com
138
141
  export const sendEvmTransaction = (
139
142
  address: string,
140
143
  sendEvmTransactionBody: SendEvmTransactionBody,
141
- options?: SecondParameter<typeof cdpApiClient>,
144
+ options?: SecondParameter<typeof cdpApiClient<SendEvmTransaction200>>,
142
145
  ) => {
143
146
  return cdpApiClient<SendEvmTransaction200>(
144
147
  {
@@ -160,7 +163,7 @@ The transaction must be an [EIP-1559 dynamic fee transaction](https://github.com
160
163
  export const signEvmTransaction = (
161
164
  address: string,
162
165
  signEvmTransactionBody: SignEvmTransactionBody,
163
- options?: SecondParameter<typeof cdpApiClient>,
166
+ options?: SecondParameter<typeof cdpApiClient<SignEvmTransaction200>>,
164
167
  ) => {
165
168
  return cdpApiClient<SignEvmTransaction200>(
166
169
  {
@@ -179,7 +182,7 @@ export const signEvmTransaction = (
179
182
  export const signEvmHash = (
180
183
  address: string,
181
184
  signEvmHashBody: SignEvmHashBody,
182
- options?: SecondParameter<typeof cdpApiClient>,
185
+ options?: SecondParameter<typeof cdpApiClient<SignEvmHash200>>,
183
186
  ) => {
184
187
  return cdpApiClient<SignEvmHash200>(
185
188
  {
@@ -200,7 +203,7 @@ Per the specification, the message in the request body is prepended with `0x19 <
200
203
  export const signEvmMessage = (
201
204
  address: string,
202
205
  signEvmMessageBody: SignEvmMessageBody,
203
- options?: SecondParameter<typeof cdpApiClient>,
206
+ options?: SecondParameter<typeof cdpApiClient<SignEvmMessage200>>,
204
207
  ) => {
205
208
  return cdpApiClient<SignEvmMessage200>(
206
209
  {
@@ -219,7 +222,7 @@ export const signEvmMessage = (
219
222
  export const signEvmTypedData = (
220
223
  address: string,
221
224
  eIP712Message: EIP712Message,
222
- options?: SecondParameter<typeof cdpApiClient>,
225
+ options?: SecondParameter<typeof cdpApiClient<SignEvmTypedData200>>,
223
226
  ) => {
224
227
  return cdpApiClient<SignEvmTypedData200>(
225
228
  {
@@ -246,7 +249,7 @@ The delegation allows the EVM EOA to be used as a smart account, which enables b
246
249
  export const createEvmEip7702Delegation = (
247
250
  address: string,
248
251
  createEvmEip7702DelegationBody: CreateEvmEip7702DelegationBody,
249
- options?: SecondParameter<typeof cdpApiClient>,
252
+ options?: SecondParameter<typeof cdpApiClient<CreateEvmEip7702Delegation201>>,
250
253
  ) => {
251
254
  return cdpApiClient<CreateEvmEip7702Delegation201>(
252
255
  {
@@ -264,7 +267,7 @@ export const createEvmEip7702Delegation = (
264
267
  */
265
268
  export const getEvmEip7702DelegationOperationById = (
266
269
  delegationOperationId: string,
267
- options?: SecondParameter<typeof cdpApiClient>,
270
+ options?: SecondParameter<typeof cdpApiClient<EvmEip7702DelegationOperation>>,
268
271
  ) => {
269
272
  return cdpApiClient<EvmEip7702DelegationOperation>(
270
273
  { url: `/v2/evm/eip7702/delegation-operations/${delegationOperationId}`, method: "GET" },
@@ -277,7 +280,7 @@ export const getEvmEip7702DelegationOperationById = (
277
280
  */
278
281
  export const importEvmAccount = (
279
282
  importEvmAccountBody: ImportEvmAccountBody,
280
- options?: SecondParameter<typeof cdpApiClient>,
283
+ options?: SecondParameter<typeof cdpApiClient<EvmAccount>>,
281
284
  ) => {
282
285
  return cdpApiClient<EvmAccount>(
283
286
  {
@@ -296,7 +299,7 @@ export const importEvmAccount = (
296
299
  export const exportEvmAccount = (
297
300
  address: string,
298
301
  exportEvmAccountBody: ExportEvmAccountBody,
299
- options?: SecondParameter<typeof cdpApiClient>,
302
+ options?: SecondParameter<typeof cdpApiClient<ExportEvmAccount200>>,
300
303
  ) => {
301
304
  return cdpApiClient<ExportEvmAccount200>(
302
305
  {
@@ -315,7 +318,7 @@ export const exportEvmAccount = (
315
318
  export const exportEvmAccountByName = (
316
319
  name: string,
317
320
  exportEvmAccountByNameBody: ExportEvmAccountByNameBody,
318
- options?: SecondParameter<typeof cdpApiClient>,
321
+ options?: SecondParameter<typeof cdpApiClient<ExportEvmAccountByName200>>,
319
322
  ) => {
320
323
  return cdpApiClient<ExportEvmAccountByName200>(
321
324
  {