You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: consolidate credit tier resolution into CreditScoringService and match contract parameters (#108)
- Remove duplicate mapScoreToCreditTier() from loans.service.ts
- Wire getAvailableCredit through CreditScoringService.resolveTier()
- Define CREDIT_TIERS as the single source of truth in credit-scoring.service.ts
- Match authoritative values from parameters-contract (gold: 10000/4%, silver: 5000/6%, bronze: 2500/8%, starter: 1000/10%)
- Reconcile tier naming: 'poor' -> 'starter' across all DTOs, services, and tests
- Add contract-alignment test ensuring CREDIT_TIERS never drifts from parameters-contract
- Add boundary score tests for 90, 89, 75, 74, 60, 59
- Update ReputationService to share CREDIT_TIERS constants
BREAKING CHANGE: API tier name changes from 'poor' to 'starter' in /reputation and
/loans/available-credit responses. Credit limits and interest rates updated to match
deployed contract parameters (gold 10000/4%, silver 5000/6%, bronze 2500/8%,
starter 1000/10%). StepFi-Web and StepFi-App must update tier name references.
0 commit comments