export type TransferParams = { /** * The amount to be transferred. */ amount: number; /** * The currency code for the transfer (e.g., "GMD", "USD"). */ currency: string; /** * Optional description or note for the transfer. */ narration?: string; /** * The payment network to use for the transfer (e.g., "afrimoney", "wave"). */ network: string; /** * Name of the beneficiary receiving the transfer. */ beneficiary_name: string; /** * Optional additional metadata associated with the transfer. */ metadata?: object; /** * The account number of the beneficiary. */ account_number: string; /** * The URL to which Modem Pay will send a callback or webhook notification after payout processing. */ callback_url?: string; }; /** * Representation of a transfer transaction. */ export type Transfer = { /** * Unique identifier for the transfer. */ id: string; /** * ID of the business initiating the transfer. */ business_id: string; /** * ID of the account from which the transfer is made. */ account_id: string; /** * ID of the merchant associated with the transfer. */ merchant_id?: string; /** * ID of the recipient business, if applicable. */ recipient_business_id?: string; /** * Amount to be transferred. */ amount: number; /** * Fee charged for the transfer. */ fee: number; /** * Currency code for the transfer (e.g., "GMD", "USD"). */ currency: string; /** * Type of transfer (self, modem-pay, mobile-money, or bank). */ type: "self" | "modem-pay" | "mobile-money" | "bank"; /** * Current status of the transfer. */ status: "pending" | "completed" | "failed" | "cancelled" | "reversed"; /** * Account balance before the transfer. */ balance_before: number; /** * Account balance after the transfer. */ balance_after: number; /** * Name of the account holder. */ account_name?: string; /** * Payment network used for the transfer. */ network?: string; /** * Bank name for bank transfers. */ bank?: string; /** * Amount received by the beneficiary. */ amount_received?: number; /** * Mobile number for mobile money transfers. */ mobile_number?: string; /** * Account number for bank transfers. */ account_number?: string; /** * Unique reference number for the transfer. */ transfer_reference: string; /** * Indicates if the transfer is in test mode. */ test_mode: boolean; /** * Record of events related to the transfer. */ events: object; /** * Additional notes about the transfer. */ note?: string; /** * One-time password for transfer verification. */ otp?: string; /** * Additional metadata associated with the transfer. */ metadata: object; }; export type TransferFeeCheckParams = { /** * The amount to be transferred. */ amount: number; /** * The currency code for the transfer amount (e.g., "GMD", "USD"). */ currency: string; /** * The payment network to be used for the transfer (e.g., "afrimoney", "wave"). */ network: string; }; export type TransferFeeCheckResponse = { /** * The fee amount charged for the transfer. */ fee: number; /** * The currency code for the fee amount (e.g., "GMD", "USD"). */ currency: string; /** * The payment network used for the transfer (e.g., "afrimoney", "wave"). */ network: string; /** * The total amount to be transferred including fees. */ amount: number; }; /** * Represents a single payout transaction within a bulk payout operation. */ interface IPayout { /** * The amount to be paid out. */ amount: number; /** * The payment network to use for the payout (e.g., "wave" or "afrimoney"). */ network: "wave" | "afrimoney"; /** * Full name of the payout beneficiary. */ beneficiary_name: string; /** * Account number to which the payout will be credited. */ account_number: string; /** * Currency code for the payout (always "GMD"). */ currency: "GMD"; } /** * Parameters required to initiate a bulk payout operation. */ export interface BulkPayoutParams { /** * An array of individual payout instructions to be processed in the batch. */ payouts: IPayout[]; /** * A unique reference identifier for this batch of payouts. */ batch_reference: string; /** * Optional URL where notifications (callback/webhook) will be sent after payout processing. */ callback_url?: string; /** * Optional additional metadata to associate with the bulk payout. */ metadata?: Record; } /** * Represents a bulk payout containing multiple individual payout transactions. */ export interface BulkPayout { /** * Unique identifier of the bulk payout. */ id: string; /** * Identifier of the business initiating the payout. */ business_id: string; /** * Account ID related to the payout. */ account_id: string; /** * Indicates whether the payout is in test mode. */ test_mode: boolean; /** * Status of the bulk payout operation. */ status: "pending" | "in-progress" | "completed" | "failed" | "partially_completed" | "partially_failed"; /** * Additional metadata associated with the bulk payout. */ metadata: Record; /** * A reference identifier for the batch of payouts. */ batch_reference: string; /** * Total number of individual payouts in this batch. */ count: number; /** * Progress of the bulk payout operation (e.g., number completed). */ progress: number; /** * The total amount chargeable for the bulk payout, including all individual payouts. */ total_chargeable_amount: number; /** * The total fees accrued for the payout operation. */ total_fees: number; /** * Array of individual payout transactions within this bulk payout. */ payouts: Array; /** * Callback URL for status updates about the bulk payout. */ callback_url: string; /** * Number of successful payout transactions in the batch. */ success_count: number; /** * Number of failed payout transactions in the batch. */ failure_count: number; } export {};