@coinbase/cdp-sdk
Version:
SDK for interacting with the Coinbase Developer Platform Wallet API
34 lines • 1.76 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.getDepositDestinationById = exports.createDepositDestination = exports.listDepositDestinations = void 0;
const cdpApiClient_js_1 = require("../../cdpApiClient.js");
/**
* List deposit destinations. You can optionally filter the results by type, account ID, network, or cryptocurrency address. Results are sorted by creation date in descending order (newest first).
* @summary List deposit destinations
*/
const listDepositDestinations = (params, options) => {
return (0, cdpApiClient_js_1.cdpApiClient)({ url: `/v2/deposit-destinations`, method: "GET", params }, options);
};
exports.listDepositDestinations = listDepositDestinations;
/**
* Create a new deposit destination for an account. A deposit destination is a cryptocurrency address that can be used to receive funds. The address will be generated for the specified network.
* @summary Create deposit destination
*/
const createDepositDestination = (createDepositDestinationRequest, options) => {
return (0, cdpApiClient_js_1.cdpApiClient)({
url: `/v2/deposit-destinations`,
method: "POST",
headers: { "Content-Type": "application/json" },
data: createDepositDestinationRequest,
}, options);
};
exports.createDepositDestination = createDepositDestination;
/**
* Get a specific deposit destination by its ID.
* @summary Get deposit destination
*/
const getDepositDestinationById = (depositDestinationId, options) => {
return (0, cdpApiClient_js_1.cdpApiClient)({ url: `/v2/deposit-destinations/${depositDestinationId}`, method: "GET" }, options);
};
exports.getDepositDestinationById = getDepositDestinationById;
//# sourceMappingURL=deposit-destinations.js.map