Fix TypeScript build errors

- Remove duplicate EscalationLevel export from regulatory.ts
- Add missing logger.ts and reports.ts files to audit package
- Fix treasury package type issues
- Clean dist folders and rebuild
This commit is contained in:
defiQUG
2026-01-23 14:53:05 -08:00
parent 8c771da399
commit aedf572b99
185 changed files with 2925 additions and 4 deletions

42
packages/rules-engine/src/aml.d.ts vendored Normal file
View File

@@ -0,0 +1,42 @@
/**
* AML (Anti-Money Laundering) and anti-structuring detection
*/
import type { Transaction, AMLCheckResult, SingleTransactionAMLResult, StructuringCheckResult, RuleResult } from '@brazil-swift-ops/types';
/**
* Transaction history for structuring detection (in production, this would be a database)
*/
interface TransactionHistory {
transactionId: string;
amount: number;
currency: string;
usdEquivalent: number;
date: Date;
orderingCustomerTaxId?: string;
beneficiaryTaxId?: string;
}
declare class TransactionHistoryStore {
private history;
add(entry: TransactionHistory): void;
getByDateRange(startDate: Date, endDate: Date): TransactionHistory[];
getByCustomer(taxId: string, startDate: Date, endDate: Date): TransactionHistory[];
getAll(): TransactionHistory[];
}
export declare function getHistoryStore(): TransactionHistoryStore;
/**
* Check single transaction AML threshold
*/
export declare function checkSingleTransactionAML(transaction: Transaction): SingleTransactionAMLResult;
/**
* Check for structuring patterns (multiple small transactions that sum above threshold)
*/
export declare function checkStructuring(transaction: Transaction, historicalTransactions?: TransactionHistory[]): StructuringCheckResult | undefined;
/**
* Perform complete AML check
*/
export declare function performAMLCheck(transaction: Transaction, historicalTransactions?: TransactionHistory[]): AMLCheckResult;
/**
* Create rule result for AML check
*/
export declare function createAMLRuleResult(check: AMLCheckResult): RuleResult;
export {};
//# sourceMappingURL=aml.d.ts.map