@spritz-finance/service-client 0.3.109 → 0.3.111
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.
|
@@ -24,6 +24,11 @@ export declare function updateCardStatus({ userId, status, cardExternalId, }: {
|
|
|
24
24
|
status: VirtualCardStatus;
|
|
25
25
|
cardExternalId: string;
|
|
26
26
|
}): Promise<import("../types").ApiFailure | import("../types").ApiSuccess<RainCard>>;
|
|
27
|
+
export declare function getLiveBalance({ userId }: {
|
|
28
|
+
userId: string;
|
|
29
|
+
}): Promise<import("../types").ApiFailure | import("../types").ApiSuccess<{
|
|
30
|
+
balance: number;
|
|
31
|
+
}>>;
|
|
27
32
|
export declare function requestWithdrawalSignature({ userId, network, amount, }: {
|
|
28
33
|
userId: string;
|
|
29
34
|
network: string;
|
|
@@ -23,7 +23,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
23
23
|
return result;
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.requestWithdrawalSignature = exports.updateCardStatus = exports.createRainCard = exports.getApplicationStatus = exports.validateContractAddress = exports.getUserDepositAddress = exports.createCardApplication = exports.RainClient = void 0;
|
|
26
|
+
exports.requestWithdrawalSignature = exports.getLiveBalance = exports.updateCardStatus = exports.createRainCard = exports.getApplicationStatus = exports.validateContractAddress = exports.getUserDepositAddress = exports.createCardApplication = exports.RainClient = void 0;
|
|
27
27
|
exports.RainClient = __importStar(require("./rainServiceClient"));
|
|
28
28
|
const serviceClient_1 = require("../serviceClient");
|
|
29
29
|
const RAIN_ENDPOINT = '/rain-v2';
|
|
@@ -67,6 +67,12 @@ async function updateCardStatus({ userId, status, cardExternalId, }) {
|
|
|
67
67
|
.then((res) => res.data);
|
|
68
68
|
}
|
|
69
69
|
exports.updateCardStatus = updateCardStatus;
|
|
70
|
+
async function getLiveBalance({ userId }) {
|
|
71
|
+
return serviceClient_1.baseClient
|
|
72
|
+
.get(`${RAIN_ENDPOINT}/user/${userId}/live-card-balance`)
|
|
73
|
+
.then((res) => res.data);
|
|
74
|
+
}
|
|
75
|
+
exports.getLiveBalance = getLiveBalance;
|
|
70
76
|
async function requestWithdrawalSignature({ userId, network, amount, }) {
|
|
71
77
|
return serviceClient_1.baseClient
|
|
72
78
|
.post(`${RAIN_ENDPOINT}/withdrawl-signature`, {
|