@distilled.cloud/coinbase 0.0.0 → 0.2.5-alpha2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/category.d.ts +5 -0
- package/lib/category.d.ts.map +1 -0
- package/lib/category.js +5 -0
- package/lib/category.js.map +1 -0
- package/lib/client.d.ts +45 -0
- package/lib/client.d.ts.map +1 -0
- package/lib/client.js +244 -0
- package/lib/client.js.map +1 -0
- package/lib/credentials.d.ts +32 -0
- package/lib/credentials.d.ts.map +1 -0
- package/lib/credentials.js +29 -0
- package/lib/credentials.js.map +1 -0
- package/lib/errors.d.ts +855 -0
- package/lib/errors.d.ts.map +1 -0
- package/lib/errors.js +466 -0
- package/lib/errors.js.map +1 -0
- package/lib/index.d.ts +16 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +16 -0
- package/lib/index.js.map +1 -0
- package/lib/operations/addEndUserEvmAccount.d.ts +30 -0
- package/lib/operations/addEndUserEvmAccount.d.ts.map +1 -0
- package/lib/operations/addEndUserEvmAccount.js +38 -0
- package/lib/operations/addEndUserEvmAccount.js.map +1 -0
- package/lib/operations/addEndUserEvmSmartAccount.d.ts +32 -0
- package/lib/operations/addEndUserEvmSmartAccount.d.ts.map +1 -0
- package/lib/operations/addEndUserEvmSmartAccount.js +43 -0
- package/lib/operations/addEndUserEvmSmartAccount.js.map +1 -0
- package/lib/operations/addEndUserSolanaAccount.d.ts +30 -0
- package/lib/operations/addEndUserSolanaAccount.d.ts.map +1 -0
- package/lib/operations/addEndUserSolanaAccount.js +38 -0
- package/lib/operations/addEndUserSolanaAccount.js.map +1 -0
- package/lib/operations/createEndUser.d.ts +61 -0
- package/lib/operations/createEndUser.d.ts.map +1 -0
- package/lib/operations/createEndUser.js +67 -0
- package/lib/operations/createEndUser.js.map +1 -0
- package/lib/operations/createEvmAccount.d.ts +30 -0
- package/lib/operations/createEvmAccount.d.ts.map +1 -0
- package/lib/operations/createEvmAccount.js +36 -0
- package/lib/operations/createEvmAccount.js.map +1 -0
- package/lib/operations/createEvmEip7702Delegation.d.ts +34 -0
- package/lib/operations/createEvmEip7702Delegation.d.ts.map +1 -0
- package/lib/operations/createEvmEip7702Delegation.js +53 -0
- package/lib/operations/createEvmEip7702Delegation.js.map +1 -0
- package/lib/operations/createEvmSmartAccount.d.ts +27 -0
- package/lib/operations/createEvmSmartAccount.d.ts.map +1 -0
- package/lib/operations/createEvmSmartAccount.js +35 -0
- package/lib/operations/createEvmSmartAccount.js.map +1 -0
- package/lib/operations/createEvmSwapQuote.d.ts +26 -0
- package/lib/operations/createEvmSwapQuote.d.ts.map +1 -0
- package/lib/operations/createEvmSwapQuote.js +40 -0
- package/lib/operations/createEvmSwapQuote.js.map +1 -0
- package/lib/operations/createOnrampOrder.d.ts +58 -0
- package/lib/operations/createOnrampOrder.d.ts.map +1 -0
- package/lib/operations/createOnrampOrder.js +79 -0
- package/lib/operations/createOnrampOrder.js.map +1 -0
- package/lib/operations/createOnrampSession.d.ts +55 -0
- package/lib/operations/createOnrampSession.d.ts.map +1 -0
- package/lib/operations/createOnrampSession.js +70 -0
- package/lib/operations/createOnrampSession.js.map +1 -0
- package/lib/operations/createPolicy.d.ts +28 -0
- package/lib/operations/createPolicy.d.ts.map +1 -0
- package/lib/operations/createPolicy.js +34 -0
- package/lib/operations/createPolicy.js.map +1 -0
- package/lib/operations/createSolanaAccount.d.ts +30 -0
- package/lib/operations/createSolanaAccount.d.ts.map +1 -0
- package/lib/operations/createSolanaAccount.js +38 -0
- package/lib/operations/createSolanaAccount.js.map +1 -0
- package/lib/operations/createSpendPermission.d.ts +55 -0
- package/lib/operations/createSpendPermission.d.ts.map +1 -0
- package/lib/operations/createSpendPermission.js +93 -0
- package/lib/operations/createSpendPermission.js.map +1 -0
- package/lib/operations/createWebhookSubscription.d.ts +74 -0
- package/lib/operations/createWebhookSubscription.d.ts.map +1 -0
- package/lib/operations/createWebhookSubscription.js +82 -0
- package/lib/operations/createWebhookSubscription.js.map +1 -0
- package/lib/operations/deletePolicy.d.ts +20 -0
- package/lib/operations/deletePolicy.d.ts.map +1 -0
- package/lib/operations/deletePolicy.js +26 -0
- package/lib/operations/deletePolicy.js.map +1 -0
- package/lib/operations/deleteWebhookSubscription.d.ts +21 -0
- package/lib/operations/deleteWebhookSubscription.d.ts.map +1 -0
- package/lib/operations/deleteWebhookSubscription.js +32 -0
- package/lib/operations/deleteWebhookSubscription.js.map +1 -0
- package/lib/operations/exportEvmAccount.d.ts +27 -0
- package/lib/operations/exportEvmAccount.d.ts.map +1 -0
- package/lib/operations/exportEvmAccount.js +33 -0
- package/lib/operations/exportEvmAccount.js.map +1 -0
- package/lib/operations/exportEvmAccountByName.d.ts +27 -0
- package/lib/operations/exportEvmAccountByName.d.ts.map +1 -0
- package/lib/operations/exportEvmAccountByName.js +35 -0
- package/lib/operations/exportEvmAccountByName.js.map +1 -0
- package/lib/operations/exportSolanaAccount.d.ts +27 -0
- package/lib/operations/exportSolanaAccount.d.ts.map +1 -0
- package/lib/operations/exportSolanaAccount.js +35 -0
- package/lib/operations/exportSolanaAccount.js.map +1 -0
- package/lib/operations/exportSolanaAccountByName.d.ts +27 -0
- package/lib/operations/exportSolanaAccountByName.d.ts.map +1 -0
- package/lib/operations/exportSolanaAccountByName.js +38 -0
- package/lib/operations/exportSolanaAccountByName.js.map +1 -0
- package/lib/operations/getEndUser.d.ts +46 -0
- package/lib/operations/getEndUser.d.ts.map +1 -0
- package/lib/operations/getEndUser.js +52 -0
- package/lib/operations/getEndUser.js.map +1 -0
- package/lib/operations/getEvmAccount.d.ts +22 -0
- package/lib/operations/getEvmAccount.d.ts.map +1 -0
- package/lib/operations/getEvmAccount.js +28 -0
- package/lib/operations/getEvmAccount.js.map +1 -0
- package/lib/operations/getEvmAccountByName.d.ts +22 -0
- package/lib/operations/getEvmAccountByName.d.ts.map +1 -0
- package/lib/operations/getEvmAccountByName.js +30 -0
- package/lib/operations/getEvmAccountByName.js.map +1 -0
- package/lib/operations/getEvmEip7702DelegationOperationById.d.ts +22 -0
- package/lib/operations/getEvmEip7702DelegationOperationById.d.ts.map +1 -0
- package/lib/operations/getEvmEip7702DelegationOperationById.js +48 -0
- package/lib/operations/getEvmEip7702DelegationOperationById.js.map +1 -0
- package/lib/operations/getEvmSmartAccount.d.ts +23 -0
- package/lib/operations/getEvmSmartAccount.d.ts.map +1 -0
- package/lib/operations/getEvmSmartAccount.js +31 -0
- package/lib/operations/getEvmSmartAccount.js.map +1 -0
- package/lib/operations/getEvmSmartAccountByName.d.ts +23 -0
- package/lib/operations/getEvmSmartAccountByName.d.ts.map +1 -0
- package/lib/operations/getEvmSmartAccountByName.js +31 -0
- package/lib/operations/getEvmSmartAccountByName.js.map +1 -0
- package/lib/operations/getEvmSwapPrice.d.ts +21 -0
- package/lib/operations/getEvmSwapPrice.d.ts.map +1 -0
- package/lib/operations/getEvmSwapPrice.js +27 -0
- package/lib/operations/getEvmSwapPrice.js.map +1 -0
- package/lib/operations/getOnrampOrderById.d.ts +39 -0
- package/lib/operations/getOnrampOrderById.d.ts.map +1 -0
- package/lib/operations/getOnrampOrderById.js +56 -0
- package/lib/operations/getOnrampOrderById.js.map +1 -0
- package/lib/operations/getOnrampUserLimits.d.ts +24 -0
- package/lib/operations/getOnrampUserLimits.d.ts.map +1 -0
- package/lib/operations/getOnrampUserLimits.js +38 -0
- package/lib/operations/getOnrampUserLimits.js.map +1 -0
- package/lib/operations/getPolicyById.d.ts +23 -0
- package/lib/operations/getPolicyById.d.ts.map +1 -0
- package/lib/operations/getPolicyById.js +29 -0
- package/lib/operations/getPolicyById.js.map +1 -0
- package/lib/operations/getSQLGrammar.d.ts +14 -0
- package/lib/operations/getSQLGrammar.d.ts.map +1 -0
- package/lib/operations/getSQLGrammar.js +20 -0
- package/lib/operations/getSQLGrammar.js.map +1 -0
- package/lib/operations/getSolanaAccount.d.ts +22 -0
- package/lib/operations/getSolanaAccount.d.ts.map +1 -0
- package/lib/operations/getSolanaAccount.js +28 -0
- package/lib/operations/getSolanaAccount.js.map +1 -0
- package/lib/operations/getSolanaAccountByName.d.ts +22 -0
- package/lib/operations/getSolanaAccountByName.d.ts.map +1 -0
- package/lib/operations/getSolanaAccountByName.js +30 -0
- package/lib/operations/getSolanaAccountByName.js.map +1 -0
- package/lib/operations/getUserOperation.d.ts +39 -0
- package/lib/operations/getUserOperation.d.ts.map +1 -0
- package/lib/operations/getUserOperation.js +66 -0
- package/lib/operations/getUserOperation.js.map +1 -0
- package/lib/operations/getWebhookSubscription.d.ts +37 -0
- package/lib/operations/getWebhookSubscription.d.ts.map +1 -0
- package/lib/operations/getWebhookSubscription.js +48 -0
- package/lib/operations/getWebhookSubscription.js.map +1 -0
- package/lib/operations/importEndUser.d.ts +56 -0
- package/lib/operations/importEndUser.d.ts.map +1 -0
- package/lib/operations/importEndUser.js +62 -0
- package/lib/operations/importEndUser.js.map +1 -0
- package/lib/operations/importEvmAccount.d.ts +31 -0
- package/lib/operations/importEvmAccount.d.ts.map +1 -0
- package/lib/operations/importEvmAccount.js +37 -0
- package/lib/operations/importEvmAccount.js.map +1 -0
- package/lib/operations/importSolanaAccount.d.ts +30 -0
- package/lib/operations/importSolanaAccount.d.ts.map +1 -0
- package/lib/operations/importSolanaAccount.js +38 -0
- package/lib/operations/importSolanaAccount.js.map +1 -0
- package/lib/operations/index.d.ts +74 -0
- package/lib/operations/index.d.ts.map +1 -0
- package/lib/operations/index.js +74 -0
- package/lib/operations/index.js.map +1 -0
- package/lib/operations/listDataTokenBalances.d.ts +37 -0
- package/lib/operations/listDataTokenBalances.d.ts.map +1 -0
- package/lib/operations/listDataTokenBalances.js +48 -0
- package/lib/operations/listDataTokenBalances.js.map +1 -0
- package/lib/operations/listEndUsers.d.ts +53 -0
- package/lib/operations/listEndUsers.d.ts.map +1 -0
- package/lib/operations/listEndUsers.js +59 -0
- package/lib/operations/listEndUsers.js.map +1 -0
- package/lib/operations/listEvmAccounts.d.ts +28 -0
- package/lib/operations/listEvmAccounts.d.ts.map +1 -0
- package/lib/operations/listEvmAccounts.js +34 -0
- package/lib/operations/listEvmAccounts.js.map +1 -0
- package/lib/operations/listEvmSmartAccounts.d.ts +29 -0
- package/lib/operations/listEvmSmartAccounts.d.ts.map +1 -0
- package/lib/operations/listEvmSmartAccounts.js +37 -0
- package/lib/operations/listEvmSmartAccounts.js.map +1 -0
- package/lib/operations/listEvmTokenBalances.d.ts +37 -0
- package/lib/operations/listEvmTokenBalances.d.ts.map +1 -0
- package/lib/operations/listEvmTokenBalances.js +48 -0
- package/lib/operations/listEvmTokenBalances.js.map +1 -0
- package/lib/operations/listPolicies.d.ts +31 -0
- package/lib/operations/listPolicies.d.ts.map +1 -0
- package/lib/operations/listPolicies.js +37 -0
- package/lib/operations/listPolicies.js.map +1 -0
- package/lib/operations/listSolanaAccounts.d.ts +29 -0
- package/lib/operations/listSolanaAccounts.d.ts.map +1 -0
- package/lib/operations/listSolanaAccounts.js +37 -0
- package/lib/operations/listSolanaAccounts.js.map +1 -0
- package/lib/operations/listSolanaTokenBalances.d.ts +36 -0
- package/lib/operations/listSolanaTokenBalances.d.ts.map +1 -0
- package/lib/operations/listSolanaTokenBalances.js +47 -0
- package/lib/operations/listSolanaTokenBalances.js.map +1 -0
- package/lib/operations/listSpendPermissions.d.ts +40 -0
- package/lib/operations/listSpendPermissions.d.ts.map +1 -0
- package/lib/operations/listSpendPermissions.js +60 -0
- package/lib/operations/listSpendPermissions.js.map +1 -0
- package/lib/operations/listTokensForAccount.d.ts +23 -0
- package/lib/operations/listTokensForAccount.d.ts.map +1 -0
- package/lib/operations/listTokensForAccount.js +34 -0
- package/lib/operations/listTokensForAccount.js.map +1 -0
- package/lib/operations/listWebhookSubscriptions.d.ts +42 -0
- package/lib/operations/listWebhookSubscriptions.d.ts.map +1 -0
- package/lib/operations/listWebhookSubscriptions.js +50 -0
- package/lib/operations/listWebhookSubscriptions.js.map +1 -0
- package/lib/operations/prepareAndSendUserOperation.d.ts +53 -0
- package/lib/operations/prepareAndSendUserOperation.d.ts.map +1 -0
- package/lib/operations/prepareAndSendUserOperation.js +93 -0
- package/lib/operations/prepareAndSendUserOperation.js.map +1 -0
- package/lib/operations/prepareUserOperation.d.ts +46 -0
- package/lib/operations/prepareUserOperation.d.ts.map +1 -0
- package/lib/operations/prepareUserOperation.js +86 -0
- package/lib/operations/prepareUserOperation.js.map +1 -0
- package/lib/operations/requestEvmFaucet.d.ts +22 -0
- package/lib/operations/requestEvmFaucet.d.ts.map +1 -0
- package/lib/operations/requestEvmFaucet.js +32 -0
- package/lib/operations/requestEvmFaucet.js.map +1 -0
- package/lib/operations/requestSolanaFaucet.d.ts +21 -0
- package/lib/operations/requestSolanaFaucet.d.ts.map +1 -0
- package/lib/operations/requestSolanaFaucet.js +29 -0
- package/lib/operations/requestSolanaFaucet.js.map +1 -0
- package/lib/operations/revokeSpendPermission.d.ts +48 -0
- package/lib/operations/revokeSpendPermission.d.ts.map +1 -0
- package/lib/operations/revokeSpendPermission.js +86 -0
- package/lib/operations/revokeSpendPermission.js.map +1 -0
- package/lib/operations/runSQLQuery.d.ts +47 -0
- package/lib/operations/runSQLQuery.d.ts.map +1 -0
- package/lib/operations/runSQLQuery.js +74 -0
- package/lib/operations/runSQLQuery.js.map +1 -0
- package/lib/operations/sendEvmTransaction.d.ts +44 -0
- package/lib/operations/sendEvmTransaction.d.ts.map +1 -0
- package/lib/operations/sendEvmTransaction.js +64 -0
- package/lib/operations/sendEvmTransaction.js.map +1 -0
- package/lib/operations/sendSolanaTransaction.d.ts +38 -0
- package/lib/operations/sendSolanaTransaction.d.ts.map +1 -0
- package/lib/operations/sendSolanaTransaction.js +46 -0
- package/lib/operations/sendSolanaTransaction.js.map +1 -0
- package/lib/operations/sendUserOperation.d.ts +43 -0
- package/lib/operations/sendUserOperation.d.ts.map +1 -0
- package/lib/operations/sendUserOperation.js +71 -0
- package/lib/operations/sendUserOperation.js.map +1 -0
- package/lib/operations/settleX402Payment.d.ts +23 -0
- package/lib/operations/settleX402Payment.d.ts.map +1 -0
- package/lib/operations/settleX402Payment.js +79 -0
- package/lib/operations/settleX402Payment.js.map +1 -0
- package/lib/operations/signEvmHash.d.ts +27 -0
- package/lib/operations/signEvmHash.d.ts.map +1 -0
- package/lib/operations/signEvmHash.js +33 -0
- package/lib/operations/signEvmHash.js.map +1 -0
- package/lib/operations/signEvmMessage.d.ts +28 -0
- package/lib/operations/signEvmMessage.d.ts.map +1 -0
- package/lib/operations/signEvmMessage.js +34 -0
- package/lib/operations/signEvmMessage.js.map +1 -0
- package/lib/operations/signEvmTransaction.d.ts +29 -0
- package/lib/operations/signEvmTransaction.d.ts.map +1 -0
- package/lib/operations/signEvmTransaction.js +40 -0
- package/lib/operations/signEvmTransaction.js.map +1 -0
- package/lib/operations/signEvmTypedData.d.ts +36 -0
- package/lib/operations/signEvmTypedData.d.ts.map +1 -0
- package/lib/operations/signEvmTypedData.js +45 -0
- package/lib/operations/signEvmTypedData.js.map +1 -0
- package/lib/operations/signSolanaMessage.d.ts +28 -0
- package/lib/operations/signSolanaMessage.d.ts.map +1 -0
- package/lib/operations/signSolanaMessage.js +38 -0
- package/lib/operations/signSolanaMessage.js.map +1 -0
- package/lib/operations/signSolanaTransaction.d.ts +33 -0
- package/lib/operations/signSolanaTransaction.d.ts.map +1 -0
- package/lib/operations/signSolanaTransaction.js +44 -0
- package/lib/operations/signSolanaTransaction.js.map +1 -0
- package/lib/operations/supportedX402PaymentKinds.d.ts +21 -0
- package/lib/operations/supportedX402PaymentKinds.d.ts.map +1 -0
- package/lib/operations/supportedX402PaymentKinds.js +40 -0
- package/lib/operations/supportedX402PaymentKinds.js.map +1 -0
- package/lib/operations/updateEvmAccount.d.ts +28 -0
- package/lib/operations/updateEvmAccount.d.ts.map +1 -0
- package/lib/operations/updateEvmAccount.js +34 -0
- package/lib/operations/updateEvmAccount.js.map +1 -0
- package/lib/operations/updateEvmSmartAccount.d.ts +24 -0
- package/lib/operations/updateEvmSmartAccount.d.ts.map +1 -0
- package/lib/operations/updateEvmSmartAccount.js +32 -0
- package/lib/operations/updateEvmSmartAccount.js.map +1 -0
- package/lib/operations/updatePolicy.d.ts +29 -0
- package/lib/operations/updatePolicy.d.ts.map +1 -0
- package/lib/operations/updatePolicy.js +35 -0
- package/lib/operations/updatePolicy.js.map +1 -0
- package/lib/operations/updateSolanaAccount.d.ts +28 -0
- package/lib/operations/updateSolanaAccount.d.ts.map +1 -0
- package/lib/operations/updateSolanaAccount.js +36 -0
- package/lib/operations/updateSolanaAccount.js.map +1 -0
- package/lib/operations/updateWebhookSubscription.d.ts +47 -0
- package/lib/operations/updateWebhookSubscription.d.ts.map +1 -0
- package/lib/operations/updateWebhookSubscription.js +58 -0
- package/lib/operations/updateWebhookSubscription.js.map +1 -0
- package/lib/operations/validateEndUserAccessToken.d.ts +44 -0
- package/lib/operations/validateEndUserAccessToken.d.ts.map +1 -0
- package/lib/operations/validateEndUserAccessToken.js +52 -0
- package/lib/operations/validateEndUserAccessToken.js.map +1 -0
- package/lib/operations/verifyX402Payment.d.ts +21 -0
- package/lib/operations/verifyX402Payment.d.ts.map +1 -0
- package/lib/operations/verifyX402Payment.js +72 -0
- package/lib/operations/verifyX402Payment.js.map +1 -0
- package/lib/retry.d.ts +22 -0
- package/lib/retry.d.ts.map +1 -0
- package/lib/retry.js +21 -0
- package/lib/retry.js.map +1 -0
- package/lib/sensitive.d.ts +5 -0
- package/lib/sensitive.d.ts.map +1 -0
- package/lib/sensitive.js +5 -0
- package/lib/sensitive.js.map +1 -0
- package/lib/traits.d.ts +5 -0
- package/lib/traits.d.ts.map +1 -0
- package/lib/traits.js +5 -0
- package/lib/traits.js.map +1 -0
- package/package.json +82 -9
- package/src/category.ts +4 -0
- package/src/client.ts +290 -0
- package/src/credentials.ts +65 -0
- package/src/errors.ts +694 -0
- package/src/index.ts +15 -0
- package/src/operations/addEndUserEvmAccount.ts +44 -0
- package/src/operations/addEndUserEvmSmartAccount.ts +53 -0
- package/src/operations/addEndUserSolanaAccount.ts +46 -0
- package/src/operations/createEndUser.ts +87 -0
- package/src/operations/createEvmAccount.ts +42 -0
- package/src/operations/createEvmEip7702Delegation.ts +63 -0
- package/src/operations/createEvmSmartAccount.ts +42 -0
- package/src/operations/createEvmSwapQuote.ts +44 -0
- package/src/operations/createOnrampOrder.ts +89 -0
- package/src/operations/createOnrampSession.ts +80 -0
- package/src/operations/createPolicy.ts +38 -0
- package/src/operations/createSolanaAccount.ts +42 -0
- package/src/operations/createSpendPermission.ts +110 -0
- package/src/operations/createWebhookSubscription.ts +92 -0
- package/src/operations/deletePolicy.ts +32 -0
- package/src/operations/deleteWebhookSubscription.ts +42 -0
- package/src/operations/exportEvmAccount.ts +39 -0
- package/src/operations/exportEvmAccountByName.ts +45 -0
- package/src/operations/exportSolanaAccount.ts +41 -0
- package/src/operations/exportSolanaAccountByName.ts +48 -0
- package/src/operations/getEndUser.ts +68 -0
- package/src/operations/getEvmAccount.ts +32 -0
- package/src/operations/getEvmAccountByName.ts +34 -0
- package/src/operations/getEvmEip7702DelegationOperationById.ts +56 -0
- package/src/operations/getEvmSmartAccount.ts +35 -0
- package/src/operations/getEvmSmartAccountByName.ts +41 -0
- package/src/operations/getEvmSwapPrice.ts +31 -0
- package/src/operations/getOnrampOrderById.ts +62 -0
- package/src/operations/getOnrampUserLimits.ts +44 -0
- package/src/operations/getPolicyById.ts +35 -0
- package/src/operations/getSQLGrammar.ts +26 -0
- package/src/operations/getSolanaAccount.ts +34 -0
- package/src/operations/getSolanaAccountByName.ts +40 -0
- package/src/operations/getUserOperation.ts +82 -0
- package/src/operations/getWebhookSubscription.ts +60 -0
- package/src/operations/importEndUser.ts +78 -0
- package/src/operations/importEvmAccount.ts +43 -0
- package/src/operations/importSolanaAccount.ts +42 -0
- package/src/operations/index.ts +73 -0
- package/src/operations/listDataTokenBalances.ts +59 -0
- package/src/operations/listEndUsers.ts +77 -0
- package/src/operations/listEvmAccounts.ts +40 -0
- package/src/operations/listEvmSmartAccounts.ts +45 -0
- package/src/operations/listEvmTokenBalances.ts +58 -0
- package/src/operations/listPolicies.ts +43 -0
- package/src/operations/listSolanaAccounts.ts +43 -0
- package/src/operations/listSolanaTokenBalances.ts +59 -0
- package/src/operations/listSpendPermissions.ts +70 -0
- package/src/operations/listTokensForAccount.ts +42 -0
- package/src/operations/listWebhookSubscriptions.ts +62 -0
- package/src/operations/prepareAndSendUserOperation.ts +113 -0
- package/src/operations/prepareUserOperation.ts +104 -0
- package/src/operations/requestEvmFaucet.ts +38 -0
- package/src/operations/requestSolanaFaucet.ts +33 -0
- package/src/operations/revokeSpendPermission.ts +103 -0
- package/src/operations/runSQLQuery.ts +92 -0
- package/src/operations/sendEvmTransaction.ts +70 -0
- package/src/operations/sendSolanaTransaction.ts +55 -0
- package/src/operations/sendUserOperation.ts +87 -0
- package/src/operations/settleX402Payment.ts +87 -0
- package/src/operations/signEvmHash.ts +37 -0
- package/src/operations/signEvmMessage.ts +40 -0
- package/src/operations/signEvmTransaction.ts +46 -0
- package/src/operations/signEvmTypedData.ts +53 -0
- package/src/operations/signSolanaMessage.ts +46 -0
- package/src/operations/signSolanaTransaction.ts +53 -0
- package/src/operations/supportedX402PaymentKinds.ts +52 -0
- package/src/operations/updateEvmAccount.ts +40 -0
- package/src/operations/updateEvmSmartAccount.ts +39 -0
- package/src/operations/updatePolicy.ts +41 -0
- package/src/operations/updateSolanaAccount.ts +40 -0
- package/src/operations/updateWebhookSubscription.ts +70 -0
- package/src/operations/validateEndUserAccessToken.ts +74 -0
- package/src/operations/verifyX402Payment.ts +80 -0
- package/src/retry.ts +37 -0
- package/src/sensitive.ts +4 -0
- package/src/traits.ts +4 -0
- package/index.js +0 -2
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const CreateSpendPermissionInput =
|
|
7
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
8
|
+
address: Schema.String.pipe(T.PathParam()),
|
|
9
|
+
network: Schema.Literals([
|
|
10
|
+
"base",
|
|
11
|
+
"base-sepolia",
|
|
12
|
+
"ethereum",
|
|
13
|
+
"ethereum-sepolia",
|
|
14
|
+
"optimism",
|
|
15
|
+
"arbitrum",
|
|
16
|
+
"avalanche",
|
|
17
|
+
"polygon",
|
|
18
|
+
]),
|
|
19
|
+
spender: Schema.String,
|
|
20
|
+
token: Schema.String,
|
|
21
|
+
allowance: Schema.String,
|
|
22
|
+
period: Schema.String,
|
|
23
|
+
start: Schema.String,
|
|
24
|
+
end: Schema.String,
|
|
25
|
+
salt: Schema.optional(Schema.String),
|
|
26
|
+
extraData: Schema.optional(Schema.String),
|
|
27
|
+
paymasterUrl: Schema.optional(Schema.Struct({})),
|
|
28
|
+
}).pipe(
|
|
29
|
+
T.Http({
|
|
30
|
+
method: "POST",
|
|
31
|
+
path: "/v2/evm/smart-accounts/{address}/spend-permissions",
|
|
32
|
+
}),
|
|
33
|
+
);
|
|
34
|
+
export type CreateSpendPermissionInput = typeof CreateSpendPermissionInput.Type;
|
|
35
|
+
|
|
36
|
+
// Output Schema
|
|
37
|
+
export const CreateSpendPermissionOutput =
|
|
38
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
39
|
+
network: Schema.Literals([
|
|
40
|
+
"base-sepolia",
|
|
41
|
+
"base",
|
|
42
|
+
"arbitrum",
|
|
43
|
+
"optimism",
|
|
44
|
+
"zora",
|
|
45
|
+
"polygon",
|
|
46
|
+
"bnb",
|
|
47
|
+
"avalanche",
|
|
48
|
+
"ethereum",
|
|
49
|
+
"ethereum-sepolia",
|
|
50
|
+
]),
|
|
51
|
+
userOpHash: Schema.String,
|
|
52
|
+
calls: Schema.Array(
|
|
53
|
+
Schema.Struct({
|
|
54
|
+
to: Schema.String,
|
|
55
|
+
value: Schema.String,
|
|
56
|
+
data: Schema.String,
|
|
57
|
+
overrideGasLimit: Schema.optional(Schema.String),
|
|
58
|
+
}),
|
|
59
|
+
),
|
|
60
|
+
status: Schema.Literals([
|
|
61
|
+
"pending",
|
|
62
|
+
"signed",
|
|
63
|
+
"broadcast",
|
|
64
|
+
"complete",
|
|
65
|
+
"dropped",
|
|
66
|
+
"failed",
|
|
67
|
+
]),
|
|
68
|
+
transactionHash: Schema.optional(Schema.String),
|
|
69
|
+
receipts: Schema.optional(
|
|
70
|
+
Schema.Array(
|
|
71
|
+
Schema.Struct({
|
|
72
|
+
revert: Schema.optional(
|
|
73
|
+
Schema.Struct({
|
|
74
|
+
data: Schema.String,
|
|
75
|
+
message: Schema.String,
|
|
76
|
+
}),
|
|
77
|
+
),
|
|
78
|
+
transactionHash: Schema.optional(Schema.String),
|
|
79
|
+
blockHash: Schema.optional(Schema.String),
|
|
80
|
+
blockNumber: Schema.optional(Schema.Number),
|
|
81
|
+
gasUsed: Schema.optional(Schema.String),
|
|
82
|
+
}),
|
|
83
|
+
),
|
|
84
|
+
),
|
|
85
|
+
});
|
|
86
|
+
export type CreateSpendPermissionOutput =
|
|
87
|
+
typeof CreateSpendPermissionOutput.Type;
|
|
88
|
+
|
|
89
|
+
// The operation
|
|
90
|
+
/**
|
|
91
|
+
* Create a spend permission
|
|
92
|
+
*
|
|
93
|
+
* Creates a spend permission for the given smart account address.
|
|
94
|
+
*
|
|
95
|
+
* @param X-Wallet-Auth - A JWT signed using your Wallet Secret, encoded in base64. Refer to the
|
|
96
|
+
[Generate Wallet Token](https://docs.cdp.coinbase.com/api-reference/v2/authentication#2-generate-wallet-token)
|
|
97
|
+
section of our Authentication docs for more details on how to generate your Wallet Token.
|
|
98
|
+
|
|
99
|
+
* @param X-Idempotency-Key - An optional string request header for making requests safely retryable.
|
|
100
|
+
When included, duplicate requests with the same key will return identical responses.
|
|
101
|
+
Refer to our [Idempotency docs](https://docs.cdp.coinbase.com/api-reference/v2/idempotency) for more information on using idempotency keys.
|
|
102
|
+
|
|
103
|
+
* @param address - The address of the Smart Account to create the spend permission for.
|
|
104
|
+
*/
|
|
105
|
+
export const createSpendPermission = /*@__PURE__*/ /*#__PURE__*/ API.make(
|
|
106
|
+
() => ({
|
|
107
|
+
inputSchema: CreateSpendPermissionInput,
|
|
108
|
+
outputSchema: CreateSpendPermissionOutput,
|
|
109
|
+
}),
|
|
110
|
+
);
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const CreateWebhookSubscriptionInput =
|
|
7
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
8
|
+
description: Schema.optional(Schema.Struct({})),
|
|
9
|
+
eventTypes: Schema.Array(Schema.String),
|
|
10
|
+
isEnabled: Schema.Boolean,
|
|
11
|
+
target: Schema.Struct({
|
|
12
|
+
url: Schema.Struct({}),
|
|
13
|
+
headers: Schema.optional(Schema.Record(Schema.String, Schema.String)),
|
|
14
|
+
}),
|
|
15
|
+
metadata: Schema.optional(Schema.Record(Schema.String, Schema.String)),
|
|
16
|
+
labels: Schema.optional(Schema.Record(Schema.String, Schema.String)),
|
|
17
|
+
}).pipe(T.Http({ method: "POST", path: "/v2/data/webhooks/subscriptions" }));
|
|
18
|
+
export type CreateWebhookSubscriptionInput =
|
|
19
|
+
typeof CreateWebhookSubscriptionInput.Type;
|
|
20
|
+
|
|
21
|
+
// Output Schema
|
|
22
|
+
export const CreateWebhookSubscriptionOutput =
|
|
23
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
24
|
+
createdAt: Schema.String,
|
|
25
|
+
description: Schema.optional(Schema.Struct({})),
|
|
26
|
+
eventTypes: Schema.Array(Schema.String),
|
|
27
|
+
isEnabled: Schema.Boolean,
|
|
28
|
+
metadata: Schema.optional(
|
|
29
|
+
Schema.Struct({
|
|
30
|
+
secret: Schema.optional(Schema.String),
|
|
31
|
+
}),
|
|
32
|
+
),
|
|
33
|
+
secret: Schema.String,
|
|
34
|
+
subscriptionId: Schema.String,
|
|
35
|
+
target: Schema.Struct({
|
|
36
|
+
url: Schema.Struct({}),
|
|
37
|
+
headers: Schema.optional(Schema.Record(Schema.String, Schema.String)),
|
|
38
|
+
}),
|
|
39
|
+
labels: Schema.optional(Schema.Record(Schema.String, Schema.String)),
|
|
40
|
+
});
|
|
41
|
+
export type CreateWebhookSubscriptionOutput =
|
|
42
|
+
typeof CreateWebhookSubscriptionOutput.Type;
|
|
43
|
+
|
|
44
|
+
// The operation
|
|
45
|
+
/**
|
|
46
|
+
* Create webhook subscription
|
|
47
|
+
*
|
|
48
|
+
* Subscribe to real-time events across CDP products using flexible filtering.
|
|
49
|
+
* ### Event Types
|
|
50
|
+
* **Onchain Events** - Monitor Base mainnet with microsecond precision:
|
|
51
|
+
* - `onchain.activity.detected` - Smart contract events, transfers, swaps, NFT activity
|
|
52
|
+
* - **Requires** `labels` for filtering (e.g., `contract_address`, `event_name`)
|
|
53
|
+
* **Onramp/Offramp Events** - Transaction lifecycle notifications:
|
|
54
|
+
* - `onramp.transaction.created`, `onramp.transaction.updated`
|
|
55
|
+
* - `onramp.transaction.success`, `onramp.transaction.failed`
|
|
56
|
+
* - `offramp.transaction.created`, `offramp.transaction.updated`
|
|
57
|
+
* - `offramp.transaction.success`, `offramp.transaction.failed`
|
|
58
|
+
* - **No labels required** - maximum simplicity for transaction monitoring
|
|
59
|
+
* **Payments Transfers Events** - Transfer lifecycle notifications:
|
|
60
|
+
* - `payments.transfers.quoted`
|
|
61
|
+
* - `payments.transfers.processing`
|
|
62
|
+
* - `payments.transfers.completed`
|
|
63
|
+
* - `payments.transfers.failed`
|
|
64
|
+
* - **No labels required** - enable the transfers webhook to monitor status transitions
|
|
65
|
+
* **Wallet Events** - Wallet activity notifications:
|
|
66
|
+
* - `wallet.activity.detected`
|
|
67
|
+
* ### Webhook Signature Verification
|
|
68
|
+
* All webhooks include cryptographic signatures for security.
|
|
69
|
+
* The signature secret is returned in `secret` field when creating a subscription.
|
|
70
|
+
* **Note:** Webhooks are in beta and this interface is subject to change.
|
|
71
|
+
* See the [verification guide](https://docs.cdp.coinbase.com/onramp-&-offramp/webhooks#webhook-signature-verification) for implementation details.
|
|
72
|
+
* ### Onchain Label Filtering
|
|
73
|
+
* For `onchain.activity.detected` events, use `labels` for precise filtering with AND logic (max 20 labels per webhook).
|
|
74
|
+
* **Allowed labels** (all in snake_case format):
|
|
75
|
+
* - `network` (required) - Blockchain network
|
|
76
|
+
* - `contract_address` - Smart contract address
|
|
77
|
+
* - `event_name` - Event name (e.g., "Transfer", "Burn")
|
|
78
|
+
* - `event_signature` - Event signature hash
|
|
79
|
+
* - `transaction_from` - Transaction sender address
|
|
80
|
+
* - `transaction_to` - Transaction recipient address
|
|
81
|
+
* - `params.*` - Any event parameter (e.g., `params.from`, `params.to`, `params.sender`, `params.tokenId`)
|
|
82
|
+
* **Examples**:
|
|
83
|
+
* - **Liquidity Pool Monitor**: `{"network": "base-mainnet", "contract_address": "0xcd1f9777571493aeacb7eae45cd30a226d3e612d", "event_name": "Burn"}`
|
|
84
|
+
* - **Price Oracle Tracker**: `{"network": "base-mainnet", "contract_address": "0xbac4a9428ea707c51f171ed9890c3c2fa810305d", "event_name": "PriceUpdated"}`
|
|
85
|
+
* - **DeFi Protocol Activity**: `{"network": "base-mainnet", "contract_address": "0x45c6e6a47a711b14d8357d5243f46704904578e3", "event_name": "Deposit"}`
|
|
86
|
+
*/
|
|
87
|
+
export const createWebhookSubscription = /*@__PURE__*/ /*#__PURE__*/ API.make(
|
|
88
|
+
() => ({
|
|
89
|
+
inputSchema: CreateWebhookSubscriptionInput,
|
|
90
|
+
outputSchema: CreateWebhookSubscriptionOutput,
|
|
91
|
+
}),
|
|
92
|
+
);
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const DeletePolicyInput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
7
|
+
policyId: Schema.String.pipe(T.PathParam()),
|
|
8
|
+
}).pipe(
|
|
9
|
+
T.Http({ method: "DELETE", path: "/v2/policy-engine/policies/{policyId}" }),
|
|
10
|
+
);
|
|
11
|
+
export type DeletePolicyInput = typeof DeletePolicyInput.Type;
|
|
12
|
+
|
|
13
|
+
// Output Schema
|
|
14
|
+
export const DeletePolicyOutput = /*@__PURE__*/ /*#__PURE__*/ Schema.Void;
|
|
15
|
+
export type DeletePolicyOutput = typeof DeletePolicyOutput.Type;
|
|
16
|
+
|
|
17
|
+
// The operation
|
|
18
|
+
/**
|
|
19
|
+
* Delete a policy
|
|
20
|
+
*
|
|
21
|
+
* Delete a policy by its ID. This will have the effect of removing the policy from all accounts that are currently using it.
|
|
22
|
+
*
|
|
23
|
+
* @param X-Idempotency-Key - An optional string request header for making requests safely retryable.
|
|
24
|
+
When included, duplicate requests with the same key will return identical responses.
|
|
25
|
+
Refer to our [Idempotency docs](https://docs.cdp.coinbase.com/api-reference/v2/idempotency) for more information on using idempotency keys.
|
|
26
|
+
|
|
27
|
+
* @param policyId - The ID of the policy to delete.
|
|
28
|
+
*/
|
|
29
|
+
export const deletePolicy = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
|
|
30
|
+
inputSchema: DeletePolicyInput,
|
|
31
|
+
outputSchema: DeletePolicyOutput,
|
|
32
|
+
}));
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const DeleteWebhookSubscriptionInput =
|
|
7
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
8
|
+
subscriptionId: Schema.String.pipe(T.PathParam()),
|
|
9
|
+
}).pipe(
|
|
10
|
+
T.Http({
|
|
11
|
+
method: "DELETE",
|
|
12
|
+
path: "/v2/data/webhooks/subscriptions/{subscriptionId}",
|
|
13
|
+
}),
|
|
14
|
+
);
|
|
15
|
+
export type DeleteWebhookSubscriptionInput =
|
|
16
|
+
typeof DeleteWebhookSubscriptionInput.Type;
|
|
17
|
+
|
|
18
|
+
// Output Schema
|
|
19
|
+
export const DeleteWebhookSubscriptionOutput =
|
|
20
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Void;
|
|
21
|
+
export type DeleteWebhookSubscriptionOutput =
|
|
22
|
+
typeof DeleteWebhookSubscriptionOutput.Type;
|
|
23
|
+
|
|
24
|
+
// The operation
|
|
25
|
+
/**
|
|
26
|
+
* Delete webhook subscription
|
|
27
|
+
*
|
|
28
|
+
* Permanently delete a webhook subscription and stop all event deliveries.
|
|
29
|
+
* This action cannot be undone.
|
|
30
|
+
* ### Important Notes
|
|
31
|
+
* - All webhook deliveries will cease immediately
|
|
32
|
+
* - Subscription cannot be recovered after deletion
|
|
33
|
+
* - Consider disabling instead of deleting for temporary pauses
|
|
34
|
+
*
|
|
35
|
+
* @param subscriptionId - Unique identifier for the webhook subscription.
|
|
36
|
+
*/
|
|
37
|
+
export const deleteWebhookSubscription = /*@__PURE__*/ /*#__PURE__*/ API.make(
|
|
38
|
+
() => ({
|
|
39
|
+
inputSchema: DeleteWebhookSubscriptionInput,
|
|
40
|
+
outputSchema: DeleteWebhookSubscriptionOutput,
|
|
41
|
+
}),
|
|
42
|
+
);
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const ExportEvmAccountInput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
7
|
+
address: Schema.String.pipe(T.PathParam()),
|
|
8
|
+
exportEncryptionKey: Schema.String,
|
|
9
|
+
}).pipe(T.Http({ method: "POST", path: "/v2/evm/accounts/{address}/export" }));
|
|
10
|
+
export type ExportEvmAccountInput = typeof ExportEvmAccountInput.Type;
|
|
11
|
+
|
|
12
|
+
// Output Schema
|
|
13
|
+
export const ExportEvmAccountOutput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct(
|
|
14
|
+
{
|
|
15
|
+
encryptedPrivateKey: Schema.String,
|
|
16
|
+
},
|
|
17
|
+
);
|
|
18
|
+
export type ExportEvmAccountOutput = typeof ExportEvmAccountOutput.Type;
|
|
19
|
+
|
|
20
|
+
// The operation
|
|
21
|
+
/**
|
|
22
|
+
* Export an EVM account
|
|
23
|
+
*
|
|
24
|
+
* Export an existing EVM account's private key. It is important to store the private key in a secure place after it's exported.
|
|
25
|
+
*
|
|
26
|
+
* @param X-Wallet-Auth - A JWT signed using your Wallet Secret, encoded in base64. Refer to the
|
|
27
|
+
[Generate Wallet Token](https://docs.cdp.coinbase.com/api-reference/v2/authentication#2-generate-wallet-token)
|
|
28
|
+
section of our Authentication docs for more details on how to generate your Wallet Token.
|
|
29
|
+
|
|
30
|
+
* @param X-Idempotency-Key - An optional string request header for making requests safely retryable.
|
|
31
|
+
When included, duplicate requests with the same key will return identical responses.
|
|
32
|
+
Refer to our [Idempotency docs](https://docs.cdp.coinbase.com/api-reference/v2/idempotency) for more information on using idempotency keys.
|
|
33
|
+
|
|
34
|
+
* @param address - The 0x-prefixed address of the EVM account. The address does not need to be checksummed.
|
|
35
|
+
*/
|
|
36
|
+
export const exportEvmAccount = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
|
|
37
|
+
inputSchema: ExportEvmAccountInput,
|
|
38
|
+
outputSchema: ExportEvmAccountOutput,
|
|
39
|
+
}));
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const ExportEvmAccountByNameInput =
|
|
7
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
8
|
+
name: Schema.String.pipe(T.PathParam()),
|
|
9
|
+
exportEncryptionKey: Schema.String,
|
|
10
|
+
}).pipe(
|
|
11
|
+
T.Http({ method: "POST", path: "/v2/evm/accounts/export/by-name/{name}" }),
|
|
12
|
+
);
|
|
13
|
+
export type ExportEvmAccountByNameInput =
|
|
14
|
+
typeof ExportEvmAccountByNameInput.Type;
|
|
15
|
+
|
|
16
|
+
// Output Schema
|
|
17
|
+
export const ExportEvmAccountByNameOutput =
|
|
18
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
19
|
+
encryptedPrivateKey: Schema.String,
|
|
20
|
+
});
|
|
21
|
+
export type ExportEvmAccountByNameOutput =
|
|
22
|
+
typeof ExportEvmAccountByNameOutput.Type;
|
|
23
|
+
|
|
24
|
+
// The operation
|
|
25
|
+
/**
|
|
26
|
+
* Export an EVM account by name
|
|
27
|
+
*
|
|
28
|
+
* Export an existing EVM account's private key by its name. It is important to store the private key in a secure place after it's exported.
|
|
29
|
+
*
|
|
30
|
+
* @param X-Wallet-Auth - A JWT signed using your Wallet Secret, encoded in base64. Refer to the
|
|
31
|
+
[Generate Wallet Token](https://docs.cdp.coinbase.com/api-reference/v2/authentication#2-generate-wallet-token)
|
|
32
|
+
section of our Authentication docs for more details on how to generate your Wallet Token.
|
|
33
|
+
|
|
34
|
+
* @param X-Idempotency-Key - An optional string request header for making requests safely retryable.
|
|
35
|
+
When included, duplicate requests with the same key will return identical responses.
|
|
36
|
+
Refer to our [Idempotency docs](https://docs.cdp.coinbase.com/api-reference/v2/idempotency) for more information on using idempotency keys.
|
|
37
|
+
|
|
38
|
+
* @param name - The name of the EVM account.
|
|
39
|
+
*/
|
|
40
|
+
export const exportEvmAccountByName = /*@__PURE__*/ /*#__PURE__*/ API.make(
|
|
41
|
+
() => ({
|
|
42
|
+
inputSchema: ExportEvmAccountByNameInput,
|
|
43
|
+
outputSchema: ExportEvmAccountByNameOutput,
|
|
44
|
+
}),
|
|
45
|
+
);
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const ExportSolanaAccountInput =
|
|
7
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
8
|
+
address: Schema.String.pipe(T.PathParam()),
|
|
9
|
+
exportEncryptionKey: Schema.String,
|
|
10
|
+
}).pipe(
|
|
11
|
+
T.Http({ method: "POST", path: "/v2/solana/accounts/{address}/export" }),
|
|
12
|
+
);
|
|
13
|
+
export type ExportSolanaAccountInput = typeof ExportSolanaAccountInput.Type;
|
|
14
|
+
|
|
15
|
+
// Output Schema
|
|
16
|
+
export const ExportSolanaAccountOutput =
|
|
17
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
18
|
+
encryptedPrivateKey: Schema.String,
|
|
19
|
+
});
|
|
20
|
+
export type ExportSolanaAccountOutput = typeof ExportSolanaAccountOutput.Type;
|
|
21
|
+
|
|
22
|
+
// The operation
|
|
23
|
+
/**
|
|
24
|
+
* Export an Solana account
|
|
25
|
+
*
|
|
26
|
+
* Export an existing Solana account's private key. It is important to store the private key in a secure place after it's exported.
|
|
27
|
+
*
|
|
28
|
+
* @param X-Wallet-Auth - A JWT signed using your Wallet Secret, encoded in base64. Refer to the
|
|
29
|
+
[Generate Wallet Token](https://docs.cdp.coinbase.com/api-reference/v2/authentication#2-generate-wallet-token)
|
|
30
|
+
section of our Authentication docs for more details on how to generate your Wallet Token.
|
|
31
|
+
|
|
32
|
+
* @param X-Idempotency-Key - An optional string request header for making requests safely retryable.
|
|
33
|
+
When included, duplicate requests with the same key will return identical responses.
|
|
34
|
+
Refer to our [Idempotency docs](https://docs.cdp.coinbase.com/api-reference/v2/idempotency) for more information on using idempotency keys.
|
|
35
|
+
|
|
36
|
+
* @param address - The base58 encoded address of the Solana account.
|
|
37
|
+
*/
|
|
38
|
+
export const exportSolanaAccount = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
|
|
39
|
+
inputSchema: ExportSolanaAccountInput,
|
|
40
|
+
outputSchema: ExportSolanaAccountOutput,
|
|
41
|
+
}));
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const ExportSolanaAccountByNameInput =
|
|
7
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
8
|
+
name: Schema.String.pipe(T.PathParam()),
|
|
9
|
+
exportEncryptionKey: Schema.String,
|
|
10
|
+
}).pipe(
|
|
11
|
+
T.Http({
|
|
12
|
+
method: "POST",
|
|
13
|
+
path: "/v2/solana/accounts/export/by-name/{name}",
|
|
14
|
+
}),
|
|
15
|
+
);
|
|
16
|
+
export type ExportSolanaAccountByNameInput =
|
|
17
|
+
typeof ExportSolanaAccountByNameInput.Type;
|
|
18
|
+
|
|
19
|
+
// Output Schema
|
|
20
|
+
export const ExportSolanaAccountByNameOutput =
|
|
21
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
22
|
+
encryptedPrivateKey: Schema.String,
|
|
23
|
+
});
|
|
24
|
+
export type ExportSolanaAccountByNameOutput =
|
|
25
|
+
typeof ExportSolanaAccountByNameOutput.Type;
|
|
26
|
+
|
|
27
|
+
// The operation
|
|
28
|
+
/**
|
|
29
|
+
* Export a Solana account by name
|
|
30
|
+
*
|
|
31
|
+
* Export an existing Solana account's private key by its name. It is important to store the private key in a secure place after it's exported.
|
|
32
|
+
*
|
|
33
|
+
* @param X-Wallet-Auth - A JWT signed using your Wallet Secret, encoded in base64. Refer to the
|
|
34
|
+
[Generate Wallet Token](https://docs.cdp.coinbase.com/api-reference/v2/authentication#2-generate-wallet-token)
|
|
35
|
+
section of our Authentication docs for more details on how to generate your Wallet Token.
|
|
36
|
+
|
|
37
|
+
* @param X-Idempotency-Key - An optional string request header for making requests safely retryable.
|
|
38
|
+
When included, duplicate requests with the same key will return identical responses.
|
|
39
|
+
Refer to our [Idempotency docs](https://docs.cdp.coinbase.com/api-reference/v2/idempotency) for more information on using idempotency keys.
|
|
40
|
+
|
|
41
|
+
* @param name - The name of the Solana account.
|
|
42
|
+
*/
|
|
43
|
+
export const exportSolanaAccountByName = /*@__PURE__*/ /*#__PURE__*/ API.make(
|
|
44
|
+
() => ({
|
|
45
|
+
inputSchema: ExportSolanaAccountByNameInput,
|
|
46
|
+
outputSchema: ExportSolanaAccountByNameOutput,
|
|
47
|
+
}),
|
|
48
|
+
);
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const GetEndUserInput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
7
|
+
userId: Schema.String.pipe(T.PathParam()),
|
|
8
|
+
}).pipe(T.Http({ method: "GET", path: "/v2/end-users/{userId}" }));
|
|
9
|
+
export type GetEndUserInput = typeof GetEndUserInput.Type;
|
|
10
|
+
|
|
11
|
+
// Output Schema
|
|
12
|
+
export const GetEndUserOutput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
13
|
+
userId: Schema.String,
|
|
14
|
+
authenticationMethods: Schema.Array(Schema.Unknown),
|
|
15
|
+
mfaMethods: Schema.optional(
|
|
16
|
+
Schema.Struct({
|
|
17
|
+
enrollmentPromptedAt: Schema.optional(Schema.String),
|
|
18
|
+
totp: Schema.optional(
|
|
19
|
+
Schema.Struct({
|
|
20
|
+
enrolledAt: Schema.String,
|
|
21
|
+
}),
|
|
22
|
+
),
|
|
23
|
+
sms: Schema.optional(
|
|
24
|
+
Schema.Struct({
|
|
25
|
+
enrolledAt: Schema.String,
|
|
26
|
+
}),
|
|
27
|
+
),
|
|
28
|
+
}),
|
|
29
|
+
),
|
|
30
|
+
evmAccounts: Schema.Array(Schema.String),
|
|
31
|
+
evmAccountObjects: Schema.Array(
|
|
32
|
+
Schema.Struct({
|
|
33
|
+
address: Schema.String,
|
|
34
|
+
createdAt: Schema.String,
|
|
35
|
+
}),
|
|
36
|
+
),
|
|
37
|
+
evmSmartAccounts: Schema.Array(Schema.String),
|
|
38
|
+
evmSmartAccountObjects: Schema.Array(
|
|
39
|
+
Schema.Struct({
|
|
40
|
+
address: Schema.String,
|
|
41
|
+
ownerAddresses: Schema.Array(Schema.String),
|
|
42
|
+
createdAt: Schema.String,
|
|
43
|
+
}),
|
|
44
|
+
),
|
|
45
|
+
solanaAccounts: Schema.Array(Schema.String),
|
|
46
|
+
solanaAccountObjects: Schema.Array(
|
|
47
|
+
Schema.Struct({
|
|
48
|
+
address: Schema.String,
|
|
49
|
+
createdAt: Schema.String,
|
|
50
|
+
}),
|
|
51
|
+
),
|
|
52
|
+
createdAt: Schema.String,
|
|
53
|
+
});
|
|
54
|
+
export type GetEndUserOutput = typeof GetEndUserOutput.Type;
|
|
55
|
+
|
|
56
|
+
// The operation
|
|
57
|
+
/**
|
|
58
|
+
* Get an end user
|
|
59
|
+
*
|
|
60
|
+
* Gets an end user by ID.
|
|
61
|
+
* This API is intended to be used by the developer's own backend, and is authenticated using the developer's CDP API key.
|
|
62
|
+
*
|
|
63
|
+
* @param userId - The ID of the end user to get.
|
|
64
|
+
*/
|
|
65
|
+
export const getEndUser = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
|
|
66
|
+
inputSchema: GetEndUserInput,
|
|
67
|
+
outputSchema: GetEndUserOutput,
|
|
68
|
+
}));
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const GetEvmAccountInput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
7
|
+
address: Schema.String.pipe(T.PathParam()),
|
|
8
|
+
}).pipe(T.Http({ method: "GET", path: "/v2/evm/accounts/{address}" }));
|
|
9
|
+
export type GetEvmAccountInput = typeof GetEvmAccountInput.Type;
|
|
10
|
+
|
|
11
|
+
// Output Schema
|
|
12
|
+
export const GetEvmAccountOutput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
13
|
+
address: Schema.String,
|
|
14
|
+
name: Schema.optional(Schema.String),
|
|
15
|
+
policies: Schema.optional(Schema.Array(Schema.String)),
|
|
16
|
+
createdAt: Schema.optional(Schema.String),
|
|
17
|
+
updatedAt: Schema.optional(Schema.String),
|
|
18
|
+
});
|
|
19
|
+
export type GetEvmAccountOutput = typeof GetEvmAccountOutput.Type;
|
|
20
|
+
|
|
21
|
+
// The operation
|
|
22
|
+
/**
|
|
23
|
+
* Get an EVM account by address
|
|
24
|
+
*
|
|
25
|
+
* Gets an EVM account by its address.
|
|
26
|
+
*
|
|
27
|
+
* @param address - The 0x-prefixed address of the EVM account. The address does not need to be checksummed.
|
|
28
|
+
*/
|
|
29
|
+
export const getEvmAccount = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
|
|
30
|
+
inputSchema: GetEvmAccountInput,
|
|
31
|
+
outputSchema: GetEvmAccountOutput,
|
|
32
|
+
}));
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const GetEvmAccountByNameInput =
|
|
7
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
8
|
+
name: Schema.String.pipe(T.PathParam()),
|
|
9
|
+
}).pipe(T.Http({ method: "GET", path: "/v2/evm/accounts/by-name/{name}" }));
|
|
10
|
+
export type GetEvmAccountByNameInput = typeof GetEvmAccountByNameInput.Type;
|
|
11
|
+
|
|
12
|
+
// Output Schema
|
|
13
|
+
export const GetEvmAccountByNameOutput =
|
|
14
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
15
|
+
address: Schema.String,
|
|
16
|
+
name: Schema.optional(Schema.String),
|
|
17
|
+
policies: Schema.optional(Schema.Array(Schema.String)),
|
|
18
|
+
createdAt: Schema.optional(Schema.String),
|
|
19
|
+
updatedAt: Schema.optional(Schema.String),
|
|
20
|
+
});
|
|
21
|
+
export type GetEvmAccountByNameOutput = typeof GetEvmAccountByNameOutput.Type;
|
|
22
|
+
|
|
23
|
+
// The operation
|
|
24
|
+
/**
|
|
25
|
+
* Get an EVM account by name
|
|
26
|
+
*
|
|
27
|
+
* Gets an EVM account by its name.
|
|
28
|
+
*
|
|
29
|
+
* @param name - The name of the EVM account.
|
|
30
|
+
*/
|
|
31
|
+
export const getEvmAccountByName = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
|
|
32
|
+
inputSchema: GetEvmAccountByNameInput,
|
|
33
|
+
outputSchema: GetEvmAccountByNameOutput,
|
|
34
|
+
}));
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../client";
|
|
3
|
+
import * as T from "../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const GetEvmEip7702DelegationOperationByIdInput =
|
|
7
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
8
|
+
delegationOperationId: Schema.String.pipe(T.PathParam()),
|
|
9
|
+
}).pipe(
|
|
10
|
+
T.Http({
|
|
11
|
+
method: "GET",
|
|
12
|
+
path: "/v2/evm/eip7702/delegation-operations/{delegationOperationId}",
|
|
13
|
+
}),
|
|
14
|
+
);
|
|
15
|
+
export type GetEvmEip7702DelegationOperationByIdInput =
|
|
16
|
+
typeof GetEvmEip7702DelegationOperationByIdInput.Type;
|
|
17
|
+
|
|
18
|
+
// Output Schema
|
|
19
|
+
export const GetEvmEip7702DelegationOperationByIdOutput =
|
|
20
|
+
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
21
|
+
delegationOperationId: Schema.String,
|
|
22
|
+
status: Schema.Literals([
|
|
23
|
+
"UNSPECIFIED",
|
|
24
|
+
"PENDING",
|
|
25
|
+
"SUBMITTED",
|
|
26
|
+
"COMPLETED",
|
|
27
|
+
"FAILED",
|
|
28
|
+
]),
|
|
29
|
+
transactionHash: Schema.optional(Schema.String),
|
|
30
|
+
network: Schema.Literals([
|
|
31
|
+
"base-sepolia",
|
|
32
|
+
"base",
|
|
33
|
+
"arbitrum",
|
|
34
|
+
"optimism",
|
|
35
|
+
"polygon",
|
|
36
|
+
"ethereum",
|
|
37
|
+
"ethereum-sepolia",
|
|
38
|
+
]),
|
|
39
|
+
delegateAddress: Schema.optional(Schema.String),
|
|
40
|
+
});
|
|
41
|
+
export type GetEvmEip7702DelegationOperationByIdOutput =
|
|
42
|
+
typeof GetEvmEip7702DelegationOperationByIdOutput.Type;
|
|
43
|
+
|
|
44
|
+
// The operation
|
|
45
|
+
/**
|
|
46
|
+
* Get EIP-7702 delegation operation for an operationID
|
|
47
|
+
*
|
|
48
|
+
* Returns the EIP-7702 delegation operation. Use the delegationOperationId returned by the Create EIP-7702 delegation endpoint to poll for operation completion.
|
|
49
|
+
*
|
|
50
|
+
* @param delegationOperationId - The unique identifier for the delegation operation.
|
|
51
|
+
*/
|
|
52
|
+
export const getEvmEip7702DelegationOperationById =
|
|
53
|
+
/*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
|
|
54
|
+
inputSchema: GetEvmEip7702DelegationOperationByIdInput,
|
|
55
|
+
outputSchema: GetEvmEip7702DelegationOperationByIdOutput,
|
|
56
|
+
}));
|