games_app/backend/dist/services/withdrawalService.d.ts
2026-07-07 15:03:17 +02:00

19 lines
794 B
TypeScript

/**
* On-chain withdrawal service.
* Locks ledger balance, broadcasts via hot wallet, finalizes ledger atomically after broadcast.
*/
import { SecurityBlockedError } from './securityService';
export type WithdrawalResult = {
transactionId: string;
status: string;
amount: string;
fee: string;
totalDebited: string;
};
/**
* Submits a withdrawal: locks funds (amount + network fee), sends amount on-chain from hot wallet.
* If on-chain succeeds but ledger finalization fails, funds stay locked and security is alerted.
*/
export declare function requestWithdrawal(userId: string, walletTypeCode: string, toAddress: string, amountRaw: bigint, totpCode?: string): Promise<WithdrawalResult>;
export { SecurityBlockedError };
//# sourceMappingURL=withdrawalService.d.ts.map