@coinbase-sample/prime-sdk-ts 0.1.0 → 0.2.1
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/dist/futures/index.d.ts +37 -0
- package/dist/futures/index.js +95 -0
- package/dist/futures/types.d.ts +48 -0
- package/dist/futures/types.js +2 -0
- package/dist/index.d.ts +14 -12
- package/dist/index.js +5 -1
- package/dist/model/AcceptQuoteRequest.d.ts +32 -0
- package/dist/model/AcceptQuoteRequest.js +21 -0
- package/dist/model/AcceptQuoteResponse.d.ts +22 -0
- package/dist/model/AcceptQuoteResponse.js +21 -0
- package/dist/model/Activity.d.ts +3 -3
- package/dist/model/Activity.js +2 -2
- package/dist/model/ActivityCreationResponse.d.ts +25 -0
- package/dist/model/ActivityCreationResponse.js +21 -0
- package/dist/model/ActivityMetadataAccount.d.ts +2 -2
- package/dist/model/ActivityMetadataAccount.js +2 -2
- package/dist/model/ActivityMetadataConsensus.d.ts +2 -2
- package/dist/model/ActivityMetadataConsensus.js +2 -2
- package/dist/model/ActivityMetadataTransactions.d.ts +2 -2
- package/dist/model/ActivityMetadataTransactions.js +2 -2
- package/dist/model/AddressBookEntry.d.ts +2 -2
- package/dist/model/AddressBookEntry.js +2 -2
- package/dist/model/AddressEntry.d.ts +27 -0
- package/dist/model/AddressEntry.js +21 -0
- package/dist/model/AddressGroup.d.ts +27 -0
- package/dist/model/AddressGroup.js +21 -0
- package/dist/model/AggregatedFiatBalance.d.ts +2 -2
- package/dist/model/AggregatedFiatBalance.js +2 -2
- package/dist/model/Allocation.d.ts +2 -2
- package/dist/model/Allocation.js +2 -2
- package/dist/model/AllocationLeg.d.ts +2 -2
- package/dist/model/AllocationLeg.js +2 -2
- package/dist/model/AmountDue.d.ts +2 -2
- package/dist/model/AmountDue.js +2 -2
- package/dist/model/Asset.d.ts +7 -2
- package/dist/model/Asset.js +2 -2
- package/dist/model/AssetChange.d.ts +2 -2
- package/dist/model/AssetChange.js +2 -2
- package/dist/model/Balance.d.ts +2 -2
- package/dist/model/Balance.js +2 -2
- package/dist/model/BlockchainAddress.d.ts +10 -2
- package/dist/model/BlockchainAddress.js +2 -2
- package/dist/model/CancelFuturesSweepResponse.d.ts +29 -0
- package/dist/model/CancelFuturesSweepResponse.js +21 -0
- package/dist/model/CancelOrderResponse.d.ts +2 -2
- package/dist/model/CancelOrderResponse.js +2 -2
- package/dist/model/Commission.d.ts +2 -2
- package/dist/model/Commission.js +2 -2
- package/dist/model/CreateAddressGroup.d.ts +26 -0
- package/dist/model/CreateAddressGroup.js +21 -0
- package/dist/model/CreateAllocationRequest.d.ts +2 -2
- package/dist/model/CreateAllocationRequest.js +2 -2
- package/dist/model/CreateAllocationResponse.d.ts +2 -2
- package/dist/model/CreateAllocationResponse.js +2 -2
- package/dist/model/CreateAllocationResponseBody.d.ts +2 -2
- package/dist/model/CreateAllocationResponseBody.js +2 -2
- package/dist/model/CreateConversionRequest.d.ts +2 -2
- package/dist/model/CreateConversionRequest.js +2 -2
- package/dist/model/CreateConversionResponse.d.ts +2 -2
- package/dist/model/CreateConversionResponse.js +2 -2
- package/dist/model/CreateNetAllocationResponse.d.ts +2 -2
- package/dist/model/CreateNetAllocationResponse.js +2 -2
- package/dist/model/CreateNetAllocationResponseBody.d.ts +2 -2
- package/dist/model/CreateNetAllocationResponseBody.js +2 -2
- package/dist/model/CreateOnchainTransactionRequest.d.ts +29 -0
- package/dist/model/CreateOnchainTransactionRequest.js +21 -0
- package/dist/model/CreateOnchainTransactionRequestEvmParams.d.ts +33 -0
- package/dist/model/CreateOnchainTransactionRequestEvmParams.js +21 -0
- package/dist/model/CreateOnchainTransactionResponse.d.ts +25 -0
- package/dist/model/CreateOnchainTransactionResponse.js +21 -0
- package/dist/model/CreateOrderRequest.d.ts +2 -2
- package/dist/model/CreateOrderRequest.js +2 -2
- package/dist/model/CreateOrderResponse.d.ts +2 -2
- package/dist/model/CreateOrderResponse.js +2 -2
- package/dist/model/CreatePortfolioAddressBookEntryRequest.d.ts +2 -2
- package/dist/model/CreatePortfolioAddressBookEntryRequest.js +2 -2
- package/dist/model/CreatePortfolioAddressBookEntryResponse.d.ts +3 -3
- package/dist/model/CreatePortfolioAddressBookEntryResponse.js +2 -2
- package/dist/model/CreateWalletRequest.d.ts +6 -2
- package/dist/model/CreateWalletRequest.js +2 -2
- package/dist/model/CreateWalletResponse.d.ts +4 -2
- package/dist/model/CreateWalletResponse.js +2 -2
- package/dist/model/CreateWalletTransferResponse.d.ts +2 -2
- package/dist/model/CreateWalletTransferResponse.js +2 -2
- package/dist/model/CreateWalletWithdrawalRequest.d.ts +2 -2
- package/dist/model/CreateWalletWithdrawalRequest.js +2 -2
- package/dist/model/CreateWalletWithdrawalResponse.d.ts +2 -2
- package/dist/model/CreateWalletWithdrawalResponse.js +2 -2
- package/dist/model/DefiBalance.d.ts +2 -2
- package/dist/model/DefiBalance.js +2 -2
- package/dist/model/DestinationAlloc.d.ts +2 -2
- package/dist/model/DestinationAlloc.js +2 -2
- package/dist/model/DisplayUser.d.ts +2 -2
- package/dist/model/DisplayUser.js +2 -2
- package/dist/model/EntityUser.d.ts +2 -2
- package/dist/model/EntityUser.js +2 -2
- package/dist/model/EstimatedNetworkFees.d.ts +2 -2
- package/dist/model/EstimatedNetworkFees.js +2 -2
- package/dist/model/FcmFuturesSweep.d.ts +37 -0
- package/dist/model/FcmFuturesSweep.js +21 -0
- package/dist/model/FcmFuturesSweepRequestAmount.d.ts +29 -0
- package/dist/model/FcmFuturesSweepRequestAmount.js +21 -0
- package/dist/model/FcmPosition.d.ts +51 -0
- package/dist/model/FcmPosition.js +21 -0
- package/dist/model/Fill.d.ts +2 -2
- package/dist/model/Fill.js +2 -2
- package/dist/model/GetActivityResponse.d.ts +2 -2
- package/dist/model/GetActivityResponse.js +2 -2
- package/dist/model/GetAllocationResponse.d.ts +2 -2
- package/dist/model/GetAllocationResponse.js +2 -2
- package/dist/model/GetAllocationsByClientNettingIdResponse.d.ts +2 -2
- package/dist/model/GetAllocationsByClientNettingIdResponse.js +2 -2
- package/dist/model/GetEntityActivitiesResponse.d.ts +2 -2
- package/dist/model/GetEntityActivitiesResponse.js +2 -2
- package/dist/model/GetEntityAssetsResponse.d.ts +2 -2
- package/dist/model/GetEntityAssetsResponse.js +2 -2
- package/dist/model/GetEntityPaymentMethodDetailsResponse.d.ts +2 -2
- package/dist/model/GetEntityPaymentMethodDetailsResponse.js +2 -2
- package/dist/model/GetEntityPaymentMethodsResponse.d.ts +2 -2
- package/dist/model/GetEntityPaymentMethodsResponse.js +2 -2
- package/dist/model/GetEntityUsersResponse.d.ts +2 -2
- package/dist/model/GetEntityUsersResponse.js +2 -2
- package/dist/model/GetFcmBalanceResponse.d.ts +57 -0
- package/dist/model/GetFcmBalanceResponse.js +21 -0
- package/dist/model/GetFuturesSweepsResponse.d.ts +24 -0
- package/dist/model/GetFuturesSweepsResponse.js +21 -0
- package/dist/model/GetInvoicesResponse.d.ts +2 -2
- package/dist/model/GetInvoicesResponse.js +2 -2
- package/dist/model/GetOpenOrdersResponse.d.ts +2 -2
- package/dist/model/GetOpenOrdersResponse.js +2 -2
- package/dist/model/GetOrderFillsResponse.d.ts +2 -2
- package/dist/model/GetOrderFillsResponse.js +2 -2
- package/dist/model/GetOrderResponse.d.ts +2 -2
- package/dist/model/GetOrderResponse.js +2 -2
- package/dist/model/GetOrdersResponse.d.ts +2 -2
- package/dist/model/GetOrdersResponse.js +2 -2
- package/dist/model/GetPortfolioActivitiesResponse.d.ts +2 -2
- package/dist/model/GetPortfolioActivitiesResponse.js +2 -2
- package/dist/model/GetPortfolioActivityResponse.d.ts +2 -2
- package/dist/model/GetPortfolioActivityResponse.js +2 -2
- package/dist/model/GetPortfolioAddressBookResponse.d.ts +2 -2
- package/dist/model/GetPortfolioAddressBookResponse.js +2 -2
- package/dist/model/GetPortfolioAllocationsResponse.d.ts +2 -2
- package/dist/model/GetPortfolioAllocationsResponse.js +2 -2
- package/dist/model/GetPortfolioBalancesResponse.d.ts +3 -2
- package/dist/model/GetPortfolioBalancesResponse.js +2 -2
- package/dist/model/GetPortfolioCommissionResponse.d.ts +2 -2
- package/dist/model/GetPortfolioCommissionResponse.js +2 -2
- package/dist/model/GetPortfolioFillsResponse.d.ts +2 -2
- package/dist/model/GetPortfolioFillsResponse.js +2 -2
- package/dist/model/GetPortfolioProductsResponse.d.ts +2 -2
- package/dist/model/GetPortfolioProductsResponse.js +2 -2
- package/dist/model/GetPortfolioResponse.d.ts +2 -2
- package/dist/model/GetPortfolioResponse.js +2 -2
- package/dist/model/GetPortfolioTransactionsResponse.d.ts +2 -2
- package/dist/model/GetPortfolioTransactionsResponse.js +2 -2
- package/dist/model/GetPortfolioUsersResponse.d.ts +2 -2
- package/dist/model/GetPortfolioUsersResponse.js +2 -2
- package/dist/model/GetPortfoliosResponse.d.ts +2 -2
- package/dist/model/GetPortfoliosResponse.js +2 -2
- package/dist/model/GetPositionsResponse.d.ts +27 -0
- package/dist/model/GetPositionsResponse.js +21 -0
- package/dist/model/GetPostTradeCreditResponse.d.ts +2 -2
- package/dist/model/GetPostTradeCreditResponse.js +2 -2
- package/dist/model/GetTransactionResponse.d.ts +2 -2
- package/dist/model/GetTransactionResponse.js +2 -2
- package/dist/model/GetWalletAddressesResponse.d.ts +25 -0
- package/dist/model/GetWalletAddressesResponse.js +21 -0
- package/dist/model/GetWalletBalanceResponse.d.ts +2 -2
- package/dist/model/GetWalletBalanceResponse.js +2 -2
- package/dist/model/GetWalletDepositInstructionsResponse.d.ts +2 -2
- package/dist/model/GetWalletDepositInstructionsResponse.js +2 -2
- package/dist/model/GetWalletResponse.d.ts +2 -2
- package/dist/model/GetWalletResponse.js +2 -2
- package/dist/model/GetWalletTransactionsResponse.d.ts +2 -2
- package/dist/model/GetWalletTransactionsResponse.js +2 -2
- package/dist/model/GetWalletsResponse.d.ts +2 -2
- package/dist/model/GetWalletsResponse.js +2 -2
- package/dist/model/Invoice.d.ts +2 -2
- package/dist/model/Invoice.js +2 -2
- package/dist/model/InvoiceItem.d.ts +2 -2
- package/dist/model/InvoiceItem.js +2 -2
- package/dist/model/ListOnchainAddressGroupsResponse.d.ts +23 -0
- package/dist/model/ListOnchainAddressGroupsResponse.js +21 -0
- package/dist/model/ListWeb3WalletBalancesResponse.d.ts +2 -2
- package/dist/model/ListWeb3WalletBalancesResponse.js +2 -2
- package/dist/model/MatchMetadata.d.ts +2 -2
- package/dist/model/MatchMetadata.js +2 -2
- package/dist/model/NFTCollection.d.ts +2 -2
- package/dist/model/NFTCollection.js +2 -2
- package/dist/model/NFTItem.d.ts +2 -2
- package/dist/model/NFTItem.js +2 -2
- package/dist/model/Network.d.ts +29 -0
- package/dist/model/Network.js +21 -0
- package/dist/model/NetworkDetails.d.ts +55 -0
- package/dist/model/NetworkDetails.js +21 -0
- package/dist/model/OnchainTransactionDetails.d.ts +53 -0
- package/dist/model/OnchainTransactionDetails.js +21 -0
- package/dist/model/Order.d.ts +6 -2
- package/dist/model/Order.js +2 -2
- package/dist/model/OrderPreviewRequest.d.ts +2 -2
- package/dist/model/OrderPreviewRequest.js +2 -2
- package/dist/model/PaginatedResponse.d.ts +2 -2
- package/dist/model/PaginatedResponse.js +2 -2
- package/dist/model/PaymentMethodDestination.d.ts +2 -2
- package/dist/model/PaymentMethodDestination.js +2 -2
- package/dist/model/PaymentMethodDetails.d.ts +2 -2
- package/dist/model/PaymentMethodDetails.js +2 -2
- package/dist/model/PaymentMethodSummary.d.ts +2 -2
- package/dist/model/PaymentMethodSummary.js +2 -2
- package/dist/model/PortfolioUser.d.ts +2 -2
- package/dist/model/PortfolioUser.js +2 -2
- package/dist/model/PostOrderPreviewResponse.d.ts +2 -2
- package/dist/model/PostOrderPreviewResponse.js +2 -2
- package/dist/model/PostTradeCreditInformation.d.ts +2 -2
- package/dist/model/PostTradeCreditInformation.js +2 -2
- package/dist/model/Product.d.ts +2 -2
- package/dist/model/Product.js +2 -2
- package/dist/model/QuoteResponse.d.ts +26 -0
- package/dist/model/QuoteResponse.js +21 -0
- package/dist/model/RFQ.d.ts +34 -0
- package/dist/model/RFQ.js +21 -0
- package/dist/model/RiskAssessment.d.ts +29 -0
- package/dist/model/RiskAssessment.js +21 -0
- package/dist/model/RpcConfig.d.ts +29 -0
- package/dist/model/RpcConfig.js +21 -0
- package/dist/model/ScheduleFuturesSweepRequest.d.ts +29 -0
- package/dist/model/ScheduleFuturesSweepRequest.js +21 -0
- package/dist/model/ScheduleFuturesSweepResponse.d.ts +29 -0
- package/dist/model/ScheduleFuturesSweepResponse.js +21 -0
- package/dist/model/SetAutoSweepRequest.d.ts +25 -0
- package/dist/model/SetAutoSweepRequest.js +21 -0
- package/dist/model/SetAutoSweepResponse.d.ts +25 -0
- package/dist/model/SetAutoSweepResponse.js +21 -0
- package/dist/model/Transaction.d.ts +7 -3
- package/dist/model/Transaction.js +2 -2
- package/dist/model/TransactionMetadata.d.ts +4 -2
- package/dist/model/TransactionMetadata.js +2 -2
- package/dist/model/TransferLocation.d.ts +2 -2
- package/dist/model/TransferLocation.js +2 -2
- package/dist/model/UserAction.d.ts +2 -2
- package/dist/model/UserAction.js +2 -2
- package/dist/model/Wallet.d.ts +6 -2
- package/dist/model/Wallet.js +2 -2
- package/dist/model/WalletCryptoDepositInstructions.d.ts +4 -2
- package/dist/model/WalletCryptoDepositInstructions.js +2 -2
- package/dist/model/WalletFiatDepositInstructions.d.ts +2 -2
- package/dist/model/WalletFiatDepositInstructions.js +2 -2
- package/dist/model/Web3Asset.d.ts +2 -2
- package/dist/model/Web3Asset.js +2 -2
- package/dist/model/Web3Balance.d.ts +2 -2
- package/dist/model/Web3Balance.js +2 -2
- package/dist/model/Web3TransactionMetadata.d.ts +30 -0
- package/dist/model/Web3TransactionMetadata.js +21 -0
- package/dist/model/changeOnchainAddressGroupRequestIsARequestToCreateOrUpdateANewOnchainAddressGroup.d.ts +23 -0
- package/dist/model/changeOnchainAddressGroupRequestIsARequestToCreateOrUpdateANewOnchainAddressGroup.js +21 -0
- package/dist/model/createATransferBetweenTwoWallets.d.ts +2 -2
- package/dist/model/createATransferBetweenTwoWallets.js +2 -2
- package/dist/model/enums/Action.d.ts +2 -2
- package/dist/model/enums/Action.js +2 -2
- package/dist/model/enums/ActivityCategory.d.ts +2 -2
- package/dist/model/enums/ActivityCategory.js +2 -2
- package/dist/model/enums/ActivityLevel.d.ts +2 -2
- package/dist/model/enums/ActivityLevel.js +2 -2
- package/dist/model/enums/ActivitySecondaryType.d.ts +2 -2
- package/dist/model/enums/ActivitySecondaryType.js +2 -2
- package/dist/model/enums/ActivityStatus.d.ts +2 -2
- package/dist/model/enums/ActivityStatus.js +2 -2
- package/dist/model/enums/ActivityType.d.ts +2 -2
- package/dist/model/enums/ActivityType.js +2 -2
- package/dist/model/enums/AddressBookType.d.ts +2 -2
- package/dist/model/enums/AddressBookType.js +2 -2
- package/dist/model/enums/AllocationSizeType.d.ts +2 -2
- package/dist/model/enums/AllocationSizeType.js +2 -2
- package/dist/model/enums/AllocationStatus.d.ts +2 -2
- package/dist/model/enums/AllocationStatus.js +2 -2
- package/dist/model/enums/AssetChangeType.d.ts +2 -2
- package/dist/model/enums/AssetChangeType.js +2 -2
- package/dist/model/enums/CustodyActivityType.d.ts +51 -0
- package/dist/model/enums/CustodyActivityType.js +55 -0
- package/dist/model/enums/DestinationType.d.ts +2 -2
- package/dist/model/enums/DestinationType.js +2 -2
- package/dist/model/enums/FcmFuturesSweepStatus.d.ts +26 -0
- package/dist/model/enums/FcmFuturesSweepStatus.js +30 -0
- package/dist/model/enums/FcmPositionSide.d.ts +24 -0
- package/dist/model/enums/FcmPositionSide.js +28 -0
- package/dist/model/enums/HierarchyType.d.ts +2 -2
- package/dist/model/enums/HierarchyType.js +2 -2
- package/dist/model/enums/InvoiceState.d.ts +2 -2
- package/dist/model/enums/InvoiceState.js +2 -2
- package/dist/model/enums/InvoiceType.d.ts +2 -2
- package/dist/model/enums/InvoiceType.js +2 -2
- package/dist/model/enums/NetworkFamily.d.ts +24 -0
- package/dist/model/enums/NetworkFamily.js +28 -0
- package/dist/model/enums/NetworkType.d.ts +23 -0
- package/dist/model/enums/NetworkType.js +27 -0
- package/dist/model/enums/OrderSide.d.ts +2 -2
- package/dist/model/enums/OrderSide.js +2 -2
- package/dist/model/enums/OrderStatus.d.ts +2 -2
- package/dist/model/enums/OrderStatus.js +2 -2
- package/dist/model/enums/OrderType.d.ts +5 -4
- package/dist/model/enums/OrderType.js +4 -3
- package/dist/model/enums/PaymentMethodType.d.ts +2 -2
- package/dist/model/enums/PaymentMethodType.js +2 -2
- package/dist/model/enums/PortfolioBalanceType.d.ts +4 -3
- package/dist/model/enums/PortfolioBalanceType.js +3 -2
- package/dist/model/enums/PrimeActivityType.d.ts +63 -0
- package/dist/model/enums/PrimeActivityType.js +67 -0
- package/dist/model/enums/ProductPermissions.d.ts +2 -2
- package/dist/model/enums/ProductPermissions.js +2 -2
- package/dist/model/enums/SigningStatus.d.ts +24 -0
- package/dist/model/enums/SigningStatus.js +28 -0
- package/dist/model/enums/SortDirection.d.ts +2 -2
- package/dist/model/enums/SortDirection.js +2 -2
- package/dist/model/enums/TimeInForceType.d.ts +2 -2
- package/dist/model/enums/TimeInForceType.js +2 -2
- package/dist/model/enums/TransactionStatus.d.ts +2 -2
- package/dist/model/enums/TransactionStatus.js +2 -2
- package/dist/model/enums/TransactionType.d.ts +5 -4
- package/dist/model/enums/TransactionType.js +4 -3
- package/dist/model/enums/TransferLocationType.d.ts +2 -2
- package/dist/model/enums/TransferLocationType.js +2 -2
- package/dist/model/enums/UserRole.d.ts +2 -2
- package/dist/model/enums/UserRole.js +2 -2
- package/dist/model/enums/VisibilityStatus.d.ts +2 -2
- package/dist/model/enums/VisibilityStatus.js +2 -2
- package/dist/model/enums/WalletDepositInstructionType.d.ts +5 -4
- package/dist/model/enums/WalletDepositInstructionType.js +4 -3
- package/dist/model/enums/WalletType.d.ts +5 -5
- package/dist/model/enums/WalletType.js +4 -4
- package/dist/model/enums/WalletVisibility.d.ts +24 -0
- package/dist/model/enums/WalletVisibility.js +28 -0
- package/dist/model/portfolio.d.ts +2 -2
- package/dist/model/portfolio.js +2 -2
- package/dist/onchainAddressBook/index.d.ts +33 -0
- package/dist/onchainAddressBook/index.js +75 -0
- package/dist/onchainAddressBook/types.d.ts +35 -0
- package/dist/onchainAddressBook/types.js +2 -0
- package/dist/onchainAddressGroups/index.d.ts +27 -0
- package/dist/onchainAddressGroups/index.js +27 -0
- package/dist/onchainAddressGroups/types.d.ts +20 -0
- package/dist/onchainAddressGroups/types.js +2 -0
- package/dist/orders/index.d.ts +5 -1
- package/dist/orders/index.js +22 -0
- package/dist/orders/types.d.ts +11 -0
- package/dist/transactions/index.d.ts +3 -1
- package/dist/transactions/index.js +12 -0
- package/dist/transactions/types.d.ts +7 -0
- package/package.json +1 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/**
|
|
3
|
-
* Copyright
|
|
3
|
+
* Copyright 2025-present Coinbase Global, Inc.
|
|
4
4
|
*
|
|
5
|
-
* This file is generated by Openapi Generator https://github.com/openapitools/openapi-
|
|
5
|
+
* This file is generated by Openapi Generator https://github.com/openapitools/openapi-generator
|
|
6
6
|
*
|
|
7
7
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
8
8
|
* you may not use this file except in compliance with the License.
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
22
22
|
exports.WalletType = void 0;
|
|
23
23
|
/**
|
|
24
|
-
* - VAULT: A crypto vault - TRADING: A trading wallet - WALLET_TYPE_OTHER: Other wallet types (like consumer, etc) -
|
|
24
|
+
* - VAULT: A crypto vault - TRADING: A trading wallet - WALLET_TYPE_OTHER: Other wallet types (like consumer, etc) - QC: A QC Wallet - ONCHAIN: An Onchain wallet
|
|
25
25
|
*/
|
|
26
26
|
var WalletType;
|
|
27
27
|
(function (WalletType) {
|
|
@@ -29,6 +29,6 @@ var WalletType;
|
|
|
29
29
|
WalletType["Vault"] = "VAULT";
|
|
30
30
|
WalletType["Trading"] = "TRADING";
|
|
31
31
|
WalletType["WalletTypeOther"] = "WALLET_TYPE_OTHER";
|
|
32
|
-
WalletType["Web3"] = "WEB3";
|
|
33
32
|
WalletType["Qc"] = "QC";
|
|
33
|
+
WalletType["Onchain"] = "ONCHAIN";
|
|
34
34
|
})(WalletType || (exports.WalletType = WalletType = {}));
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright 2025-present Coinbase Global, Inc.
|
|
3
|
+
*
|
|
4
|
+
* This file is generated by Openapi Generator https://github.com/openapitools/openapi-generator
|
|
5
|
+
*
|
|
6
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
+
* you may not use this file except in compliance with the License.
|
|
8
|
+
* You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*
|
|
18
|
+
* Do not edit the class manually.
|
|
19
|
+
*/
|
|
20
|
+
export declare enum WalletVisibility {
|
|
21
|
+
Unspecified = "WALLET_VISIBILITY_UNSPECIFIED",
|
|
22
|
+
Visible = "WALLET_VISIBILITY_VISIBLE",
|
|
23
|
+
Hidden = "WALLET_VISIBILITY_HIDDEN"
|
|
24
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Copyright 2025-present Coinbase Global, Inc.
|
|
4
|
+
*
|
|
5
|
+
* This file is generated by Openapi Generator https://github.com/openapitools/openapi-generator
|
|
6
|
+
*
|
|
7
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
8
|
+
* you may not use this file except in compliance with the License.
|
|
9
|
+
* You may obtain a copy of the License at
|
|
10
|
+
*
|
|
11
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
12
|
+
*
|
|
13
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
14
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
15
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
16
|
+
* See the License for the specific language governing permissions and
|
|
17
|
+
* limitations under the License.
|
|
18
|
+
*
|
|
19
|
+
* Do not edit the class manually.
|
|
20
|
+
*/
|
|
21
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
22
|
+
exports.WalletVisibility = void 0;
|
|
23
|
+
var WalletVisibility;
|
|
24
|
+
(function (WalletVisibility) {
|
|
25
|
+
WalletVisibility["Unspecified"] = "WALLET_VISIBILITY_UNSPECIFIED";
|
|
26
|
+
WalletVisibility["Visible"] = "WALLET_VISIBILITY_VISIBLE";
|
|
27
|
+
WalletVisibility["Hidden"] = "WALLET_VISIBILITY_HIDDEN";
|
|
28
|
+
})(WalletVisibility || (exports.WalletVisibility = WalletVisibility = {}));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright
|
|
2
|
+
* Copyright 2025-present Coinbase Global, Inc.
|
|
3
3
|
*
|
|
4
|
-
* This file is generated by Openapi Generator https://github.com/openapitools/openapi-
|
|
4
|
+
* This file is generated by Openapi Generator https://github.com/openapitools/openapi-generator
|
|
5
5
|
*
|
|
6
6
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
7
|
* you may not use this file except in compliance with the License.
|
package/dist/model/portfolio.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/**
|
|
3
|
-
* Copyright
|
|
3
|
+
* Copyright 2025-present Coinbase Global, Inc.
|
|
4
4
|
*
|
|
5
|
-
* This file is generated by Openapi Generator https://github.com/openapitools/openapi-
|
|
5
|
+
* This file is generated by Openapi Generator https://github.com/openapitools/openapi-generator
|
|
6
6
|
*
|
|
7
7
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
8
8
|
* you may not use this file except in compliance with the License.
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright 2025-present Coinbase Global, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { CoinbaseCallOptions } from '@coinbase-sample/core-ts';
|
|
17
|
+
import { CoinbasePrimeClient } from '../client';
|
|
18
|
+
import { CoinbasePrimeClientException, CoinbasePrimeException } from '../errors';
|
|
19
|
+
import { ListOnchainAddressBookRequest, ListOnchainAddressBookResponse, CreateOnchainAddressBookEntryRequest, CreateOnchainAddressBookEntryResponse, UpdateOnchainAddressBookEntryRequest, UpdateOnchainAddressBookEntryResponse, DeleteOnchainAddressBookEntryRequest, DeleteOnchainAddressBookEntryResponse } from './types';
|
|
20
|
+
export interface IOnchainAddressBookService {
|
|
21
|
+
listOnchainAddressBook(request: ListOnchainAddressBookRequest, options?: CoinbaseCallOptions): Promise<ListOnchainAddressBookResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
22
|
+
createOnchainAddressBookEntry(request: CreateOnchainAddressBookEntryRequest, options?: CoinbaseCallOptions): Promise<CreateOnchainAddressBookEntryResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
23
|
+
updateOnchainAddressBookEntry(request: UpdateOnchainAddressBookEntryRequest, options?: CoinbaseCallOptions): Promise<UpdateOnchainAddressBookEntryResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
24
|
+
deleteOnchainAddressBook(request: DeleteOnchainAddressBookEntryRequest, options?: CoinbaseCallOptions): Promise<DeleteOnchainAddressBookEntryResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
25
|
+
}
|
|
26
|
+
export declare class OnchainAddressBookService implements IOnchainAddressBookService {
|
|
27
|
+
private client;
|
|
28
|
+
constructor(client: CoinbasePrimeClient);
|
|
29
|
+
listOnchainAddressBook(request: ListOnchainAddressBookRequest, options?: CoinbaseCallOptions): Promise<ListOnchainAddressBookResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
30
|
+
createOnchainAddressBookEntry(request: CreateOnchainAddressBookEntryRequest, options?: CoinbaseCallOptions): Promise<CreateOnchainAddressBookEntryResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
31
|
+
updateOnchainAddressBookEntry(request: UpdateOnchainAddressBookEntryRequest, options?: CoinbaseCallOptions): Promise<UpdateOnchainAddressBookEntryResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
32
|
+
deleteOnchainAddressBook(request: DeleteOnchainAddressBookEntryRequest, options?: CoinbaseCallOptions): Promise<DeleteOnchainAddressBookEntryResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
33
|
+
}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.OnchainAddressBookService = void 0;
|
|
13
|
+
/**
|
|
14
|
+
* Copyright 2025-present Coinbase Global, Inc.
|
|
15
|
+
*
|
|
16
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
17
|
+
* you may not use this file except in compliance with the License.
|
|
18
|
+
* You may obtain a copy of the License at
|
|
19
|
+
*
|
|
20
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
21
|
+
*
|
|
22
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
23
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
24
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
25
|
+
* See the License for the specific language governing permissions and
|
|
26
|
+
* limitations under the License.
|
|
27
|
+
*/
|
|
28
|
+
const core_ts_1 = require("@coinbase-sample/core-ts");
|
|
29
|
+
class OnchainAddressBookService {
|
|
30
|
+
constructor(client) {
|
|
31
|
+
this.client = client;
|
|
32
|
+
}
|
|
33
|
+
listOnchainAddressBook(request, options) {
|
|
34
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
35
|
+
const response = yield this.client.request({
|
|
36
|
+
url: `portfolios/${request.portfolioId}/onchain_address_groups`,
|
|
37
|
+
callOptions: options,
|
|
38
|
+
});
|
|
39
|
+
return response.data;
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
createOnchainAddressBookEntry(request, options) {
|
|
43
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
44
|
+
const response = yield this.client.request({
|
|
45
|
+
url: `portfolios/${request.portfolioId}/onchain_address_group`,
|
|
46
|
+
bodyParams: Object.assign(Object.assign({}, request), { portfolioId: undefined }),
|
|
47
|
+
method: core_ts_1.Method.POST,
|
|
48
|
+
callOptions: options,
|
|
49
|
+
});
|
|
50
|
+
return response.data;
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
updateOnchainAddressBookEntry(request, options) {
|
|
54
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
55
|
+
const response = yield this.client.request({
|
|
56
|
+
url: `portfolios/${request.portfolioId}/onchain_address_group`,
|
|
57
|
+
bodyParams: Object.assign(Object.assign({}, request), { portfolioId: undefined }),
|
|
58
|
+
method: core_ts_1.Method.PUT,
|
|
59
|
+
callOptions: options,
|
|
60
|
+
});
|
|
61
|
+
return response.data;
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
deleteOnchainAddressBook(request, options) {
|
|
65
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
66
|
+
const response = yield this.client.request({
|
|
67
|
+
url: `portfolios/${request.portfolioId}/onchain_address_group/${request.addressGroupId}`,
|
|
68
|
+
method: core_ts_1.Method.DELETE,
|
|
69
|
+
callOptions: options,
|
|
70
|
+
});
|
|
71
|
+
return response.data;
|
|
72
|
+
});
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
exports.OnchainAddressBookService = OnchainAddressBookService;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright 2025-present Coinbase Global, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { ListOnchainAddressGroupsResponse as listInt } from '../model/ListOnchainAddressGroupsResponse';
|
|
17
|
+
import { AddressGroup } from '../model/AddressGroup';
|
|
18
|
+
import { ActivityCreationResponse } from '../model/ActivityCreationResponse';
|
|
19
|
+
export type ListOnchainAddressBookRequest = {
|
|
20
|
+
portfolioId: string;
|
|
21
|
+
};
|
|
22
|
+
export type ListOnchainAddressBookResponse = listInt;
|
|
23
|
+
export type CreateOnchainAddressBookEntryRequest = AddressGroup & {
|
|
24
|
+
portfolioId: string;
|
|
25
|
+
};
|
|
26
|
+
export type CreateOnchainAddressBookEntryResponse = ActivityCreationResponse;
|
|
27
|
+
export type UpdateOnchainAddressBookEntryRequest = AddressGroup & {
|
|
28
|
+
portfolioId: string;
|
|
29
|
+
};
|
|
30
|
+
export type UpdateOnchainAddressBookEntryResponse = ActivityCreationResponse;
|
|
31
|
+
export type DeleteOnchainAddressBookEntryRequest = {
|
|
32
|
+
portfolioId: string;
|
|
33
|
+
addressGroupId: string;
|
|
34
|
+
};
|
|
35
|
+
export type DeleteOnchainAddressBookEntryResponse = ActivityCreationResponse;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright 2024-present Coinbase Global, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { CoinbaseCallOptions } from '@coinbase-sample/core-ts';
|
|
17
|
+
import { CoinbasePrimeClient } from '../client';
|
|
18
|
+
import { CoinbasePrimeClientException, CoinbasePrimeException } from '../errors';
|
|
19
|
+
import { ListOnchainAddressGroupsRequest, ListOnchainAddressGroupsResponse } from './types';
|
|
20
|
+
export interface IOnchainAddressGroupsService {
|
|
21
|
+
listEntityPaymentMethods(request: ListOnchainAddressGroupsRequest, options?: CoinbaseCallOptions): Promise<ListOnchainAddressGroupsResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
22
|
+
}
|
|
23
|
+
export declare class OnchainAddressGroupsService implements IOnchainAddressGroupsService {
|
|
24
|
+
private client;
|
|
25
|
+
constructor(client: CoinbasePrimeClient);
|
|
26
|
+
listEntityPaymentMethods(request: ListOnchainAddressGroupsRequest, options?: CoinbaseCallOptions): Promise<ListOnchainAddressGroupsResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
27
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.OnchainAddressGroupsService = void 0;
|
|
13
|
+
class OnchainAddressGroupsService {
|
|
14
|
+
constructor(client) {
|
|
15
|
+
this.client = client;
|
|
16
|
+
}
|
|
17
|
+
listEntityPaymentMethods(request, options) {
|
|
18
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
19
|
+
const response = yield this.client.request({
|
|
20
|
+
url: `portfolios/${request.portfolioId}/onchain_address_groups`,
|
|
21
|
+
callOptions: options,
|
|
22
|
+
});
|
|
23
|
+
return response.data;
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
exports.OnchainAddressGroupsService = OnchainAddressGroupsService;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright 2024-present Coinbase Global, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { ListOnchainAddressGroupsResponse as listInt } from '../model/ListOnchainAddressGroupsResponse';
|
|
17
|
+
export type ListOnchainAddressGroupsRequest = {
|
|
18
|
+
portfolioId: string;
|
|
19
|
+
};
|
|
20
|
+
export type ListOnchainAddressGroupsResponse = listInt;
|
package/dist/orders/index.d.ts
CHANGED
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
import { CoinbaseCallOptions } from '@coinbase-sample/core-ts';
|
|
17
17
|
import { CoinbasePrimeClient } from '../client';
|
|
18
18
|
import { CoinbasePrimeClientException, CoinbasePrimeException } from '../errors';
|
|
19
|
-
import { ListOpenOrdersResponse, ListOpenOrdersRequest, ListOrderFillsRequest, ListOrderFillsResponse, ListPortfolioOrdersResponse, ListPortfolioOrdersRequest, GetOrderResponse, GetOrderRequest, ListPortfolioFillsRequest, ListPortfolioFillsResponse, CreateOrderPreviewRequest, CreateOrderPreviewResponse, CancelOrderRequest, CancelOrderResponse, CreateOrderRequest, CreateOrderResponse } from './types';
|
|
19
|
+
import { ListOpenOrdersResponse, ListOpenOrdersRequest, ListOrderFillsRequest, ListOrderFillsResponse, ListPortfolioOrdersResponse, ListPortfolioOrdersRequest, GetOrderResponse, GetOrderRequest, ListPortfolioFillsRequest, ListPortfolioFillsResponse, CreateOrderPreviewRequest, CreateOrderPreviewResponse, CancelOrderRequest, CancelOrderResponse, CreateOrderRequest, CreateOrderResponse, CreateQuoteRequest, CreateQuoteResponse, AcceptQuoteRequest, AcceptQuoteResponse } from './types';
|
|
20
20
|
export interface IOrdersService {
|
|
21
21
|
getOrder(request: GetOrderRequest, options?: CoinbaseCallOptions): Promise<GetOrderResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
22
22
|
listPortfolioFills(request: ListPortfolioFillsRequest, options?: CoinbaseCallOptions): Promise<ListPortfolioFillsResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
@@ -26,6 +26,8 @@ export interface IOrdersService {
|
|
|
26
26
|
createOrderPreview(request: CreateOrderPreviewRequest, options?: CoinbaseCallOptions): Promise<CreateOrderPreviewResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
27
27
|
cancelOrder(request: CancelOrderRequest, options?: CoinbaseCallOptions): Promise<CancelOrderResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
28
28
|
createOrder(request: CreateOrderRequest, options?: CoinbaseCallOptions): Promise<CreateOrderResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
29
|
+
createQuote(request: CreateQuoteRequest, options?: CoinbaseCallOptions): Promise<CreateQuoteResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
30
|
+
acceptQuote(request: AcceptQuoteRequest, options?: CoinbaseCallOptions): Promise<AcceptQuoteResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
29
31
|
}
|
|
30
32
|
export declare class OrdersService implements IOrdersService {
|
|
31
33
|
private client;
|
|
@@ -38,4 +40,6 @@ export declare class OrdersService implements IOrdersService {
|
|
|
38
40
|
createOrderPreview(request: CreateOrderPreviewRequest, options?: CoinbaseCallOptions): Promise<CreateOrderPreviewResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
39
41
|
cancelOrder(request: CancelOrderRequest, options?: CoinbaseCallOptions): Promise<CancelOrderResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
40
42
|
createOrder(request: CreateOrderRequest, options?: CoinbaseCallOptions): Promise<CreateOrderResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
43
|
+
createQuote(request: CreateQuoteRequest, options?: CoinbaseCallOptions): Promise<CreateQuoteResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
44
|
+
acceptQuote(request: AcceptQuoteRequest, options?: CoinbaseCallOptions): Promise<AcceptQuoteResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
41
45
|
}
|
package/dist/orders/index.js
CHANGED
|
@@ -115,5 +115,27 @@ class OrdersService {
|
|
|
115
115
|
return response.data;
|
|
116
116
|
});
|
|
117
117
|
}
|
|
118
|
+
createQuote(request, options) {
|
|
119
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
120
|
+
const response = yield this.client.request({
|
|
121
|
+
url: `portfolios/${request.portfolioId}/rfq`,
|
|
122
|
+
method: core_ts_1.Method.POST,
|
|
123
|
+
bodyParams: request,
|
|
124
|
+
callOptions: options,
|
|
125
|
+
});
|
|
126
|
+
return response.data;
|
|
127
|
+
});
|
|
128
|
+
}
|
|
129
|
+
acceptQuote(request, options) {
|
|
130
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
131
|
+
const response = yield this.client.request({
|
|
132
|
+
url: `portfolios/${request.portfolioId}/accept_quote`,
|
|
133
|
+
method: core_ts_1.Method.POST,
|
|
134
|
+
bodyParams: request,
|
|
135
|
+
callOptions: options,
|
|
136
|
+
});
|
|
137
|
+
return response.data;
|
|
138
|
+
});
|
|
139
|
+
}
|
|
118
140
|
}
|
|
119
141
|
exports.OrdersService = OrdersService;
|
package/dist/orders/types.d.ts
CHANGED
|
@@ -27,6 +27,9 @@ import { CancelOrderResponse as internalCancel } from '../model/CancelOrderRespo
|
|
|
27
27
|
import { CreateOrderResponse as internalCreateResp } from '../model/CreateOrderResponse';
|
|
28
28
|
import { CreateOrderRequest as internalCreate } from '../model/CreateOrderRequest';
|
|
29
29
|
import { Pagination } from '../shared/pagination';
|
|
30
|
+
import { QuoteResponse } from '../model/QuoteResponse';
|
|
31
|
+
import { AcceptQuoteRequest as internalAcceptQuoteReq } from '../model/AcceptQuoteRequest';
|
|
32
|
+
import { AcceptQuoteResponse as internalAcceptQuoteResp } from '../model/AcceptQuoteResponse';
|
|
30
33
|
export type GetOrderRequest = {
|
|
31
34
|
portfolioId: string;
|
|
32
35
|
orderId: string;
|
|
@@ -75,3 +78,11 @@ export type CreateOrderRequest = internalCreate & {
|
|
|
75
78
|
portfolioId: string;
|
|
76
79
|
};
|
|
77
80
|
export type CreateOrderResponse = internalCreateResp;
|
|
81
|
+
export type CreateQuoteRequest = internalCreate & {
|
|
82
|
+
portfolioId: string;
|
|
83
|
+
};
|
|
84
|
+
export type CreateQuoteResponse = QuoteResponse;
|
|
85
|
+
export type AcceptQuoteRequest = internalAcceptQuoteReq & {
|
|
86
|
+
portfolioId: string;
|
|
87
|
+
};
|
|
88
|
+
export type AcceptQuoteResponse = internalAcceptQuoteResp;
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
import { CoinbaseCallOptions } from '@coinbase-sample/core-ts';
|
|
17
17
|
import { CoinbasePrimeClient } from '../client';
|
|
18
18
|
import { CoinbasePrimeClientException, CoinbasePrimeException } from '../errors';
|
|
19
|
-
import { CreateConversionRequest, CreateConversionResponse, CreateTransferRequest, CreateTransferResponse, CreateWithdrawalRequest, CreateWithdrawalResponse, GetTransactionRequest, GetTransactionResponse, ListPortfolioTransactionsRequest, ListPortfolioTransactionsResponse, ListWalletTransactionsRequest, ListWalletTransactionsResponse } from './types';
|
|
19
|
+
import { CreateConversionRequest, CreateConversionResponse, CreateOnchainTransactionRequest, CreateOnchainTransactionResponse, CreateTransferRequest, CreateTransferResponse, CreateWithdrawalRequest, CreateWithdrawalResponse, GetTransactionRequest, GetTransactionResponse, ListPortfolioTransactionsRequest, ListPortfolioTransactionsResponse, ListWalletTransactionsRequest, ListWalletTransactionsResponse } from './types';
|
|
20
20
|
export interface ITransactionsService {
|
|
21
21
|
getTransaction(request: GetTransactionRequest, options?: CoinbaseCallOptions): Promise<GetTransactionResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
22
22
|
listPortfolioTransactions(request: ListPortfolioTransactionsRequest, options?: CoinbaseCallOptions): Promise<ListPortfolioTransactionsResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
@@ -24,6 +24,7 @@ export interface ITransactionsService {
|
|
|
24
24
|
createConversion(request: CreateConversionRequest, options?: CoinbaseCallOptions): Promise<CreateConversionResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
25
25
|
createTransfer(request: CreateTransferRequest, options?: CoinbaseCallOptions): Promise<CreateTransferResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
26
26
|
createWithdrawal(request: CreateWithdrawalRequest, options?: CoinbaseCallOptions): Promise<CreateWithdrawalResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
27
|
+
createOnchainTransaction(request: CreateOnchainTransactionRequest, options?: CoinbaseCallOptions): Promise<CreateOnchainTransactionResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
27
28
|
}
|
|
28
29
|
export declare class TransactionsService implements ITransactionsService {
|
|
29
30
|
private client;
|
|
@@ -34,4 +35,5 @@ export declare class TransactionsService implements ITransactionsService {
|
|
|
34
35
|
createConversion(request: CreateConversionRequest, options?: CoinbaseCallOptions): Promise<CreateConversionResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
35
36
|
createTransfer(request: CreateTransferRequest, options?: CoinbaseCallOptions): Promise<CreateTransferResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
36
37
|
createWithdrawal(request: CreateWithdrawalRequest, options?: CoinbaseCallOptions): Promise<CreateWithdrawalResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
38
|
+
createOnchainTransaction(request: CreateOnchainTransactionRequest, options?: CoinbaseCallOptions): Promise<CreateOnchainTransactionResponse | CoinbasePrimeClientException | CoinbasePrimeException>;
|
|
37
39
|
}
|
|
@@ -97,5 +97,17 @@ class TransactionsService {
|
|
|
97
97
|
return response.data;
|
|
98
98
|
});
|
|
99
99
|
}
|
|
100
|
+
createOnchainTransaction(request, options) {
|
|
101
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
102
|
+
const bodyParams = Object.assign(Object.assign({}, request), { portfolioId: undefined, walletId: undefined });
|
|
103
|
+
const response = yield this.client.request({
|
|
104
|
+
url: `portfolios/${request.portfolioId}/wallets/${request.walletId}/onchain_transaction`,
|
|
105
|
+
bodyParams,
|
|
106
|
+
method: core_ts_1.Method.POST,
|
|
107
|
+
callOptions: options,
|
|
108
|
+
});
|
|
109
|
+
return response.data;
|
|
110
|
+
});
|
|
111
|
+
}
|
|
100
112
|
}
|
|
101
113
|
exports.TransactionsService = TransactionsService;
|
|
@@ -24,6 +24,8 @@ import { CreateWalletWithdrawalRequest } from '../model/CreateWalletWithdrawalRe
|
|
|
24
24
|
import { CreateWalletWithdrawalResponse } from '../model/CreateWalletWithdrawalResponse';
|
|
25
25
|
import { Pagination } from '../shared/pagination';
|
|
26
26
|
import { CreateWalletTransferResponse } from '../model/CreateWalletTransferResponse';
|
|
27
|
+
import { CreateOnchainTransactionRequest as internalCreate } from '../model/CreateOnchainTransactionRequest';
|
|
28
|
+
import { CreateOnchainTransactionResponse as internalCreateResp } from '../model/CreateOnchainTransactionResponse';
|
|
27
29
|
export type ListPortfolioTransactionsRequest = Pagination & {
|
|
28
30
|
portfolioId: string;
|
|
29
31
|
symbols?: string[];
|
|
@@ -60,3 +62,8 @@ export type CreateWithdrawalRequest = CreateWalletWithdrawalRequest & {
|
|
|
60
62
|
walletId: string;
|
|
61
63
|
};
|
|
62
64
|
export type CreateWithdrawalResponse = CreateWalletWithdrawalResponse;
|
|
65
|
+
export type CreateOnchainTransactionRequest = internalCreate & {
|
|
66
|
+
portfolioId: string;
|
|
67
|
+
walletId: string;
|
|
68
|
+
};
|
|
69
|
+
export type CreateOnchainTransactionResponse = internalCreateResp;
|