import { ProjectivePoint } from "../types.js"; import { ProofOfWithdraw } from "../provers/withdraw.js"; import { CipherBalance } from "../types.js"; import { Call, Contract, CairoOption } from "starknet"; import { AEBalance } from "../ae_balance.js"; import { IOperation, OperationType } from "./operation.js"; import { Audit } from "./audit.js"; export interface IWithdrawOperation extends IOperation { type: typeof OperationType.Withdraw; } /** * Represents the calldata of a withdraw operation. * @interface WithdrawOpParams * @property {ProjectivePoint} from - The Tongo account to withdraw from * @property {bigint} amount - The amount of tongo to withdraw * @property {bigint} to - The starknet contract address to send the funds to * @property {AEBalance} hint - AE encryption of the final balance of the account * @property {ProofOfWithdraw} proof - ZK proof for the withdraw operation * @property {CairoOption} auditPart - Optional Audit to declare the balance of the account after the tx * @property {Contract} Tongo - The Tongo instance to interact with */ interface WithdrawOpParams { from: ProjectivePoint; to: bigint; amount: bigint; auxiliarCipher: CipherBalance; hint: AEBalance; proof: ProofOfWithdraw; auditPart: CairoOption; Tongo: Contract; } export declare class WithdrawOperation implements IWithdrawOperation { type: typeof OperationType.Withdraw; from: ProjectivePoint; to: bigint; amount: bigint; hint: AEBalance; auxiliarCipher: CipherBalance; proof: ProofOfWithdraw; auditPart: CairoOption; Tongo: Contract; constructor({ from, to, amount, proof, auditPart, Tongo, hint, auxiliarCipher }: WithdrawOpParams); toCalldata(): Call; } export {};