184 Commits

Author SHA1 Message Date
barsa
29b511e44c refactor: update password validation requirements and messaging
- Removed special character requirement from password validation across various components and schemas.
- Updated user-facing messages to reflect the new password criteria.
- Adjusted related validation logic in the domain and portal to ensure consistency.
2026-03-02 17:40:47 +09:00
barsa
49d6d21974 fix: restore lost error classifications and address code review findings
- Salesforce: add validation/duplicate/access/storage error classes and
  restore classification in error handler (400/409/403/503 vs generic 502)
- Freebit: add auth/rate-limit/validation/network error classes and
  restore result-code-based classification (215, 381, 382)
- Portal: replace unsafe string→enum casts with typed state variables
- BaseRepository: narrow orderBy from unknown to Record<string, "asc"|"desc">
- WHMCS: narrow WhmcsNotFoundError.providerCode from string to union type
- Remove unused UnitOfWork service from PrismaModule
2026-03-02 13:11:11 +09:00
barsa
2d076cf6d4 refactor: add typed provider error classes replacing string matching
Add structured error code enums to domain package for WHMCS, Salesforce,
and Freebit providers. Create BaseProviderError and typed error classes
for each provider. Update UnifiedExceptionFilter to handle provider errors.
Migrate all three error handler services from DomainHttpException with
brittle string matching to typed error classes with instanceof checks.
2026-03-02 13:11:11 +09:00
barsa
7da032fd95 refactor: tighten support schema to use defined enum validators
Replace loose z.string() fields in supportCaseSchema and supportCaseFilterSchema
with the already-defined enum schemas (status, priority, category). Add JSDoc
to intentional escape hatches in customer contract interfaces. Fix portal
type assertions for the stricter filter types.
2026-03-02 13:11:10 +09:00
barsa
b206de8dba refactor: enterprise-grade cleanup of BFF and domain packages
Comprehensive refactoring across 70 files (net -298 lines) improving
type safety, error handling, and code organization:

- Replace .passthrough()/.catchall(z.unknown()) with .strip() in all Zod schemas
- Tighten Record<string, unknown> to bounded union types where possible
- Replace throw new Error with domain-specific exceptions (OrderException,
  FulfillmentException, WhmcsOperationException, SalesforceOperationException, etc.)
- Split AuthTokenService (625 lines) into TokenGeneratorService and
  TokenRefreshService with thin orchestrator
- Deduplicate FreebitClientService with shared makeRequest() method
- Add typed interfaces to WHMCS facade, order service, and fulfillment mapper
- Externalize hardcoded config values to ConfigService with env fallbacks
- Consolidate duplicate billing cycle enums into shared billingCycleSchema
- Standardize logger usage (nestjs-pino @Inject(Logger) everywhere)
- Move shared WHMCS number coercion helpers to whmcs-utils/schema.ts
2026-02-24 19:05:30 +09:00
barsa
f4918b8a79 refactor: update WHMCS phone country code handling and schema validation
- Modify the phoneCountryCode assignment in the WHMCS mapper to ensure it is always a string when present.
- Change the phonecc type in the WHMCS raw types schema to use numberLike for improved type safety and validation consistency.
2026-02-24 14:54:38 +09:00
barsa
9941250cb5 refactor: streamline authentication workflows and remove legacy services
- Replace SignupWorkflowService and GetStartedWorkflowService with new coordinator services for improved modularity and clarity.
- Update auth controller to utilize the new GetStartedCoordinator.
- Refactor account status handling in the GetStartedForm component to leverage XState for state management.
- Introduce new hooks for managing the get-started flow, enhancing the overall user experience.
- Remove deprecated services and clean up related imports to maintain code hygiene.
2026-02-24 14:37:23 +09:00
barsa
5c329bbe96 refactor: update WHMCS mappers and schemas to use numberLike for type safety
- Refactor various mappers in billing, payments, services, and subscriptions to ensure IDs are consistently converted to numbers.
- Update raw types schemas to utilize whmcsNumberLike and whmcsString for improved validation and type safety.
- Enhance the whmcs-utils to include schema exports for better modularity.
2026-02-24 13:56:02 +09:00
barsa
0c63bc5c33 refactor: domain package cleanup
- Remove validation wrapper functions from common/validation.ts (use Zod schemas directly)
- Delete duplicate CheckoutItem/CheckoutTotals/CheckoutCart/OrderCreateResponse from orders/contract.ts
- Delete empty orders/checkout.ts
- Remove unused MIGRATION_STEPS/MIGRATION_TRANSFER_ITEMS UI constants from auth/forms.ts
- Standardize checkout/contract.ts to not re-export schema types
- Fix customer/providers/index.ts to not re-export contract types through providers barrel
2026-02-24 11:57:43 +09:00
barsa
6e51012d21 UAT docs and bug fixes 2026-02-24 11:09:35 +09:00
Temuulen Ankhbayar
5e5bff12da fix: comprehensive SIM audit fixes and MNP debug logging
Address critical, high, and medium issues found during SIM management audit:

Critical: fix eSIM plan code mapping (SKU→PASI), PA05-41 endpoint typo,
PA05-05 gender mapping (F→W) and katakana field names.

High: fix double authKey injection, add MNP/porting fields to SF getOrder
SOQL, add reissue params to eSIM addAcnt, remove console.error debug stmt.

Medium: fix KB/MB conversion (1000→1024), birthday UTC timezone bug, plan
code regex matching "5G" as 5GB, case-insensitive isMnp flag, domain schema
enums (addKind +M, simkind E0/E2/E3), move identity into mnp Level 2.

Frontend: fix SVG donut radius mismatch (r=88→96), fix FreebitError typo.

Add comprehensive MNP debug logging across the entire data flow pipeline:
SF order extraction, config mapping, MNP field parsing, API payload assembly.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-17 18:48:50 +09:00
barsa
4c724da7ae feat: implement trusted device functionality for enhanced login experience 2026-02-03 19:21:48 +09:00
barsa
7abd433d95 Refactor conditional rendering and improve code readability across multiple components
- Simplified conditional rendering in OrderSummary, ProductCard, InstallationOptions, InternetOfferingCard, DeviceCompatibility, SimPlansContent, and other components by removing unnecessary parentheses.
- Enhanced clarity in the use of ternary operators for better maintainability.
- Updated documentation to reflect changes in development setup for skipping OTP verification during login.
- Removed outdated orchestrator refactoring plan document.
- Added new environment variable for skipping OTP verification in development.
- Minor adjustments in domain contracts and mappers for consistency in conditional checks.
2026-02-03 18:28:38 +09:00
barsa
2dec0af63b fix: resolve nested ternary lint errors across codebase 2026-02-03 18:11:51 +09:00
barsa
4cb393bdb8 refactor: simplify order fulfillment and remove unused public pages
- Extract fulfillment step executors and factory from orchestrator
- Remove unused signup, migrate, and internet configure pages
- Simplify PublicShell and landing page components
- Standardize conditional expressions across codebase
2026-02-03 17:35:47 +09:00
barsa
ff9ee10860 Merge main into alt-design
Resolved merge conflicts between main and alt-design branches.

Key decisions:
- BFF: Adopted SIM-first workflow from main (PA05-18 → PA02-01 → PA05-05 → WHMCS)
- BFF: Kept FreebitFacade pattern, added new services (AccountRegistration, VoiceOptions, SemiBlack)
- BFF: Fixed freebit-usage.service.ts bug (quotaKb → quotaMb)
- BFF: Merged rate limiting + HTTP status parsing in WHMCS error handler
- Portal: Took main's UI implementations
- Deleted: TV page, SignupForm, ServicesGrid (as per main)
- Added whmcsRegistrationUrl to field-maps.ts (was missing after file consolidation)

TODO post-merge:
- Refactor order-fulfillment-orchestrator.service.ts to use buildTransactionSteps abstraction
- Fix ESLint errors from main's code (skipped pre-commit for merge)
2026-02-03 16:12:05 +09:00
Temuuleenn
35619f24d1 Simplify physical SIM activation and enhance order fulfillment
- Remove PA05-18 semi-black step from physical SIM flow, use PA02-01 directly
- Add WHMCS client ID fallback from Salesforce WH_Account__c field
- Return service IDs from WHMCS AcceptOrder for proper linking
- Add phone number to WHMCS domain field and WHMCS admin URL to Salesforce
- Change SIM Inventory status from "In Use" to "Assigned"
- Fix SIM services query case sensitivity ("SIM" → "Sim")
- Add bash 3.2 compatibility to dev-watch.sh
- Add "Most Popular Services" section to landing page
- Add "Trusted By" company carousel to About page

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-03 15:41:32 +09:00
barsa
d5e22f14f5 feat: add address reconciliation queue service for Salesforce integration
- Implement AddressReconcileQueueService to handle address reconciliation jobs between WHMCS and Salesforce.
- Define job data structure and queue configuration for retries and error handling.
- Add methods for enqueueing reconciliation jobs and retrieving queue health metrics.

feat: create loading components for various services in the portal

- Add loading skeletons for Internet, SIM, VPN, and public services configuration.
- Implement loading states for account-related views including account details, services, and verification settings.
- Introduce loading states for support case details and subscription actions.

feat: implement OTP input component for user verification

- Create OtpInput component to handle 6-digit OTP input with auto-focus and navigation.
- Add LoginOtpStep component for OTP verification during login, including countdown timer and error handling.

feat: define address domain constants for validation

- Establish constants for address field length limits to ensure compliance with WHMCS API constraints.
- Include maximum lengths for address fields and user input fields to maintain data integrity.
2026-02-03 11:48:49 +09:00
tema
1283880f7d Revamp Physical SIM activation to use PA02-01 + PA05-05
Replace PA05-33 OTA API with the proper two-step activation flow:
- PA02-01: Account Registration (/master/addAcnt/)
- PA05-05: Voice Options Registration (/mvno/talkoption/addOrder/)

Changes:
- Add FreebitAccountRegistrationService for PA02-01 account registration
- Add FreebitVoiceOptionsService for PA05-05 voice options
- Update SimFulfillmentService to use new APIs instead of PA05-33 OTA
- Add SalesforceSIMInventoryService for fetching SIM inventory data
- Remove deprecated FreebitOtaService (PA05-33 no longer used)
- Remove debug console.log statements

The new flow:
1. Fetch SIM inventory from Salesforce (phone number, PT number)
2. Call PA02-01 to register MVNO account with plan code
3. Call PA05-05 to configure voice options with customer identity
4. Update SIM inventory status to "In Use"

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-30 18:22:00 +09:00
barsa
464f98284a feat(eligibility): add address key field for Salesforce Flow duplicate detection
Add Eligibility_Address_Key__c field (postcode:streetAddress format) to Case records
for eligibility check requests. Salesforce Flow will use this field to detect duplicate
requests for the same address within a time period.

Changes:
- Add eligibilityAddressKey to CreateCaseParams and CASE_FIELDS mapping
- Add streetAddress param to EligibilityCheckCaseParams for passing from callers
- Add createAddressKey() helper in WorkflowCaseManager to generate the key
- Update raw.types.ts schema with new field
- Note in internet-eligibility.service.ts that basic flow skips duplicate detection
2026-01-20 19:00:09 +09:00
barsa
2a40d84691 feat: implement ServicesOverviewContent component for consistent service listings
refactor: update AccountServicesOverview and PublicServicesOverview to use ServicesOverviewContent
fix: enhance case comment transformation with email-based customer identification
refactor: improve SupportCaseDetailView with message grouping and localStorage tracking
2026-01-19 16:29:26 +09:00
barsa
0a5a33da98 Refactor conditional statements for improved readability and consistency
- Updated various components to use parentheses in conditional statements for clarity.
- Refactored `renderSubCardHeader` to use an options object for better parameter handling.
- Enhanced error handling messages across multiple components to provide clearer feedback.
- Adjusted query string handling in routing to improve readability.
- Made minor adjustments to ensure consistent formatting and style across the codebase.
2026-01-19 15:14:39 +09:00
barsa
6a7ea6e057 feat: add services for SIM billing, details, top-up pricing, and usage management 2026-01-19 14:15:43 +09:00
barsa
d3b94b1ed3 feat(auth): implement permission-based access control and centralized error handling
- Introduced PermissionsGuard to enforce permission checks on routes.
- Added RequirePermissions decorator for specifying required permissions on handlers.
- Created AUTH_ERRORS constants for consistent error messages across the auth module.
- Updated CsrfService to reduce CSRF token expiry time for enhanced security.
- Refactored auth cookie handling into utility functions for better maintainability.
- Enhanced TokenBlacklistService to default to fail-closed in production environments.
- Updated various DTOs and schemas for consistency and clarity.
- Removed legacy code and types related to SIM requests.
- Improved logging and error handling in GlobalAuthGuard.
- Added middleware for public path checks and optimistic authentication.
2026-01-19 10:40:50 +09:00
barsa
37ef51cc82 chore: update repository structure documentation for clarity and organization 2026-01-15 16:31:15 +09:00
barsa
aa77f23d85 Refactor conditional rendering and improve code readability across multiple components
- Updated conditional rendering syntax in CheckoutStatusBanners, IdentityVerificationSection, and other components for consistency.
- Removed unused quick eligibility and maybe later API functions from get-started API.
- Enhanced error handling messages in various subscription views.
- Updated documentation to reflect changes in eligibility check flow.
- Cleaned up unused fields in Salesforce mapping and raw types.
2026-01-15 16:11:11 +09:00
barsa
a01361bb89 Enhance JapanAddressForm with 2026-01-15 14:38:25 +09:00
barsa
c4abd41ec6 2026-01-15 12:38:16 +09:00
barsa
0f6bae840f feat: add eligibility check flow with form, OTP, and success steps
- Implemented FormStep component for user input (name, email, address).
- Created OtpStep component for OTP verification.
- Developed SuccessStep component to display success messages based on account creation.
- Introduced eligibility-check.store for managing state throughout the eligibility check process.
- Added commitlint configuration for standardized commit messages.
- Configured knip for workspace management and project structure.
2026-01-15 11:28:25 +09:00
barsa
1d1602f5e7 feat: Implement unified eligibility check flow with inline OTP verification
- Refactor PublicLandingView to enhance service section animations.
- Update SimPlansContent and PublicEligibilityCheck to streamline service highlights.
- Revise PublicEligibilityCheck to support new flow: "Send Request Only" and "Continue to Create Account".
- Introduce guest eligibility check API with handoff token for account creation.
- Modify success step to provide clear options for account creation and navigation.
- Enhance form handling and error management in PublicEligibilityCheckView.
- Update domain schemas to accommodate guest eligibility requests and responses.
- Document new eligibility check flows and testing procedures.
2026-01-14 17:14:07 +09:00
barsa
bb4be98444 feat: Enhance About Us page with animations and updated styles
- Updated typography for headings and paragraphs in AboutUsView.
- Added animation effects for header and sections to improve user experience.
- Refactored section headers to use new display styles.

feat: Implement bilingual address handling in AddressConfirmation

- Integrated JapanAddressForm for ZIP code lookup and bilingual address input.
- Updated state management to handle bilingual addresses and validation.
- Enhanced save functionality to support dual-write to WHMCS and Salesforce.

fix: Adjust Japan Post address mapping to handle nullish values

- Updated address mapping to use nullish coalescing for optional fields.
- Ensured compatibility with API responses that may return null for certain fields.

feat: Add ServiceCard component for displaying services

- Created a flexible ServiceCard component with multiple variants (default, featured, minimal, bento).
- Implemented accent color options and responsive design for better UI.
- Added detailed props documentation and usage examples.

chore: Clean up development scripts

- Removed unnecessary build steps for validation package in manage.sh.
2026-01-14 16:25:06 +09:00
barsa
fd15324ef0 feat(address): integrate AddressModule and optimize Japan address form handling 2026-01-14 13:54:01 +09:00
barsa
78689da8fb feat(address): implement Japan address form with ZIP code lookup
- Add JapanAddressForm component for complete Japanese address input.
- Integrate ZipCodeInput for automatic address population via Japan Post API.
- Create hooks for ZIP code lookup and address service status.
- Define address-related types and constants in the domain package.
- Document the feature, including environment variables and API endpoints.
- Implement mapping functions for WHMCS and Salesforce address formats.
2026-01-13 18:41:17 +09:00
barsa
dc32e7aa07 feat: Enhance Public VPN Plans view with marketing content and new components
- Added detailed service highlights, how it works steps, and FAQs to the Public VPN Plans view.
- Introduced new components: CtaButton, FeaturedServiceCard, ProcessStep, ServiceCard, ServiceShowcaseCard, TrustBadge, TrustIndicators, HowItWorks, ServiceCTA, and ServiceFAQ for improved layout and functionality.
- Implemented a new design for the landing page with enhanced visuals and user engagement elements.
- Updated the VPN plans section to include a more informative and visually appealing layout.
2026-01-13 18:19:58 +09:00
barsa
bde9f706ce feat: add VPN services and call history management features
- Implemented VpnServicesService for managing VPN plans and activation fees.
- Created SimCallHistoryFormatterService for formatting call history data.
- Developed SimCallHistoryParserService to parse call history CSV files.
- Added AnimatedContainer and AnimatedBackground components for UI animations.
- Introduced BentoServiceCard, FloatingGlassCard, GlowButton, and ValuePropCard components for landing page.
- Implemented useCountUp hook for animated number counting.
- Added cancellation months utility functions for subscription management.
2026-01-13 16:19:39 +09:00
barsa
f447ba1800 Refactor codebase: eliminate duplication, standardize patterns, resolve circular deps
Phase 1: Portal Duplication Cleanup
- Delete apps/portal/src/lib/ directory (12 duplicate files)
- Update imports to use canonical locations (core/, shared/)

Phase 2: Domain Package Standardization
- Add contract.ts to notifications and checkout modules
- Update billing schema to derive enums from contract

Phase 3: BFF Error Handling
- Remove hardcoded test SIM number from SimValidationService
- Use ConfigService for TEST_SIM_ACCOUNT env variable

Phase 4: Circular Dependency Resolution
- Create VoiceOptionsModule to break FreebitModule <-> SimManagementModule cycle
- Remove forwardRef usage between these modules
- Move SimVoiceOptionsService to new voice-options module

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-13 14:25:14 +09:00
barsa
a8580b0d61 Enhance Salesforce Account and Contact Creation in Signup Workflow
- Updated SalesforceAccountService to map gender values to Salesforce picklist values and added date of birth handling for contact creation.
- Modified SignupWorkflowService to require gender and date of birth during account creation, ensuring complete data submission.
- Adjusted SignupAccountResolverService to include gender and date of birth in account creation logic, improving data integrity.
- Introduced SalesforceContactRecord interface in domain to standardize contact data structure, enhancing type safety and validation.
2026-01-06 16:52:02 +09:00
barsa
b19c213931 Implement Unified Cancellation Features for SIM and Internet Services
- Added new methods in SalesforceOpportunityService to retrieve cancellation statuses for both Internet and SIM services by Opportunity ID, enhancing cancellation handling.
- Updated BFF module to include a new CancellationModule, improving service organization and modularity.
- Refactored portal routes and components to unify cancellation navigation, streamlining user experience.
- Introduced new domain schemas for unified cancellation previews, ensuring consistent data structure and validation across services.
- Removed deprecated cancellation components from the portal, promoting cleaner code and improved maintainability.
2026-01-05 17:09:10 +09:00
barsa
6096c15659 Refactor Salesforce Opportunity Integration for SIM and Internet Cancellations
- Updated opportunity field mappings to replace deprecated fields with new ones for SIM and Internet cancellations, enhancing clarity and consistency.
- Introduced separate data structures for Internet and SIM cancellation data, improving type safety and validation.
- Refactored SalesforceOpportunityService to handle updates for both Internet and SIM cancellations, ensuring accurate data handling.
- Enhanced cancellation query fields to support new SIM cancellation requirements, improving the overall cancellation process.
- Cleaned up the portal integration to reflect changes in opportunity source fields, promoting better data integrity and tracking.
2026-01-05 17:08:33 +09:00
barsa
a41f2bf47e Enhance BFF Modules and Update Domain Schemas
- Added new modules for SIM management, internet management, and call history to the BFF, improving service organization and modularity.
- Updated environment validation schema to reflect changes in Salesforce event channels, ensuring accurate configuration.
- Refactored router configuration to include new subscription-related modules, enhancing API routing clarity.
- Cleaned up Salesforce integration by removing unused service files and optimizing event handling logic.
- Improved support service by adding cache invalidation logic for case comments, ensuring real-time updates for users.
- Updated domain schemas to remove deprecated fields and enhance validation for residence card verification, promoting data integrity.
- Enhanced utility functions in the portal for better address formatting and confirmation prompts, improving user experience.
2026-01-05 15:11:56 +09:00
barsa
fd5336f499 Implement Case Messaging and Commenting Features in Salesforce Integration
- Added methods in `SalesforceCaseService` to fetch and add case messages, unifying email messages and case comments into a chronological conversation thread.
- Enhanced `SupportService` and `SupportController` to handle case message retrieval and comment addition, integrating new DTOs for request and response validation.
- Updated `SupportCaseDetailView` in the Portal to display conversation messages and allow users to add comments, improving user interaction with support cases.
- Introduced new schemas in the domain for case messages and comments, ensuring robust validation and type safety.
- Refactored Salesforce mappers to transform email messages and case comments into a unified format for display in the portal.
2025-12-29 18:39:13 +09:00
barsa
a938c605c7 Enhance Salesforce Case Integration and Update Eligibility Logic
- Added new fields for notes and case ID in the ServicesCdcSubscriber to improve eligibility detail tracking.
- Refactored the SalesforceCaseService to unify case creation for various case types, including customer support and internal workflow cases.
- Updated InternetServicesService to create internal workflow cases for eligibility checks, enhancing tracking and management.
- Improved error handling and logging consistency across services when creating cases.
- Cleaned up unused imports and optimized code structure for better maintainability.
2025-12-29 16:53:32 +09:00
barsa
a55967a31f Refactor Error Handling and Improve Service Consistency
- Introduced `mapHttpStatusToErrorCode` function in the domain to standardize error code mapping from HTTP status codes, enhancing error handling across the application.
- Updated various services and controllers to utilize the new error mapping function, ensuring consistent error responses and improved clarity in logging.
- Refactored error handling in the BillingController and other modules to align with the updated practices, promoting maintainability and clarity in API responses.
- Cleaned up unused imports and optimized code structure for better maintainability across the BFF modules.
2025-12-29 15:44:01 +09:00
barsa
03eccd1db2 Enhance Error Handling and Logging Consistency Across Services
- Replaced instances of `getErrorMessage` with `extractErrorMessage` in various services to ensure consistent error handling and improve clarity in logging.
- Updated error logging in the Whmcs, Salesforce, and subscription services to utilize the new error extraction method, enhancing maintainability and debugging capabilities.
- Adjusted ESLint configuration to prevent the use of `console.log` in production code, promoting the use of a centralized logging solution.
- Refactored error handling in the Agentforce widget and other components to align with the updated logging practices, ensuring a consistent approach to error management across the application.
- Cleaned up unused imports and optimized code structure for better maintainability.
2025-12-29 15:07:11 +09:00
barsa
cdcdb4c172 Enhance User ID Handling and Validation Across Services
- Added optional userId parameter to payment capture methods in WhmcsService and WhmcsInvoiceService to improve tracking and management of user-related transactions.
- Updated invoice retrieval and user profile services to utilize parseUuidOrThrow for user ID validation, ensuring consistent error messaging for invalid formats.
- Refactored SIM billing and activation services to include userId in one-time charge creation, enhancing billing traceability.
- Adjusted validation logic in various services to improve clarity and maintainability, ensuring robust handling of user IDs throughout the application.
2025-12-29 14:21:55 +09:00
barsa
ed5c2ead63 Refactor Salesforce Integration and Update Billing Logic
- Replaced the OrderFieldConfigModule with SalesforceOrderFieldConfigModule in the Salesforce integration module to streamline configuration management.
- Updated SalesforceOrderService to utilize SalesforceOrderFieldMapService, enhancing consistency in order field mapping.
- Refactored multiple controllers to remove inline query parsing, directly using query parameters for improved clarity and maintainability.
- Adjusted the ResidenceCardService to enhance error handling and response consistency when interacting with Salesforce.
- Cleaned up unused imports and optimized code structure for better maintainability across the BFF modules.
2025-12-29 14:09:33 +09:00
barsa
2a1b4d93ed Refactor API Response Handling and Update Service Implementations
- Removed the TransformInterceptor to streamline response handling, ensuring that all responses are returned directly without a success envelope.
- Updated various controllers and services to utilize new action response schemas, enhancing clarity and consistency in API responses.
- Refactored error handling in the CsrfController and CheckoutController to improve logging and error management.
- Cleaned up unused imports and optimized code structure for better maintainability and clarity across the application.
2025-12-29 11:12:20 +09:00
barsa
fb682c4c44 Refactor Error Handling Utilities and Update Service Implementations
- Renamed `getErrorMessage` to `extractErrorMessage` for clarity and to avoid confusion with the domain's `getMessageForErrorCode`.
- Introduced a deprecation notice for `getErrorMessage` to maintain backward compatibility.
- Updated various services and controllers to utilize the new `extractErrorMessage` function, ensuring consistent error handling across the application.
- Enhanced error handling in the `BillingController`, `SubscriptionsService`, and other modules to improve maintainability and clarity in API responses.
2025-12-26 18:17:37 +09:00
barsa
934a87330d Refactor Billing Controller to Improve Error Handling
- Replaced inline error throwing with NotFoundException in the BillingController to enhance error handling and provide clearer responses for missing WHMCS client mappings.
- Updated multiple methods to ensure consistent error management across the controller, improving maintainability and clarity in API responses.
2025-12-26 17:36:06 +09:00
barsa
465a62a3e8 Refactor Domain Mappings and Update Import Paths
- Removed the domain mappings module, consolidating related types and schemas into the id-mappings feature.
- Updated import paths across the BFF to reflect the new structure, ensuring compliance with import hygiene rules.
- Cleaned up unused files and optimized the codebase for better maintainability and clarity.
2025-12-26 17:27:22 +09:00