Skip to content

SAIF.Domain overview

Documentation context: Packaged Component (NuGet)

SAIF.Domain is the domain-logic layer of the SAIF platform's electronic-billing (ebilling), claims, and policy-correspondence subsystems: it wraps NHibernate-mapped entities supplied by SAIF.Data and SAIF.Data.Guidewire in domain objects that expose business behaviour, and it is consumed exclusively by SAIF.Services in production. It ships inside the SAIF.SAIFCode.Core NuGet package as lib\net462\SAIF.Domain.dll.

Purpose

  • Assigns, indexes, and generates CBP (converted-bill-processing) bills from inbound electronic bills, parses and builds the surrounding EDI files (837, 835, 277, 999-style acknowledgements), and generates explanation-of-benefits (EOB) records from Guidewire payment extracts.
  • Manages bill audits and audit notes, bill regeneration, policy certificate-holder lifecycle, document-packet assembly for policy correspondence, and a Guidewire-backed Claim read model that merges legacy WCIS data with live ClaimCenter API data.
  • Consumed exclusively by SAIF.Services in production, which owns all transaction (IUnitOfWork.Begin/Commit) boundaries around calls into this library.

Responsibilities

  • Wrap SAIF.Data entities in domain objects that expose behaviour methods such as Bill.ModifyStatus, Bill.SendToAudit, Audit.AllowAllServices, and CertificateHolder.Expire.
  • Drive the ebilling lifecycle end to end: patient/provider/service indexing, bill assignment, CBP bill generation, EDI file parsing/building, and EOB generation.
  • Manage bill audits, audit notes, and bill regeneration.
  • Manage policy certificate-holder lifecycle (create, update, expire, reinstate, supersede).
  • Present a Guidewire-backed Claim read model for consumers that need combined legacy/ClaimCenter claim data.
  • Generate document packets for policy correspondence.

Key components

  • DomainBase<TItem> / DomainQueryBase<TItem,TQueryProvider> / DomainRepositoryBase<TItem>: shared base classes every domain wrapper builds on.
  • BillAssignment, PatientIndexer, ProviderIndexerV2, BillServiceIndexer, GenerateCbpBills: the ebilling assignment/indexing/CBP-generation pipeline.
  • File837Extractor, File835Builder, File277CaBuilder, File837AckBuilder, EdiBuildSegments: EDI file parsing and building.
  • EobBuilder, EobGenerator, EobExtensions: EOB record generation and rendering.
  • Bill, Audit, AuditNote, BillRegenerator: bill lifecycle, auditing, and note-taking.
  • Claim, ClaimAdjuster, ClaimReserveGenerator, Worker: the Guidewire-backed claim read model.
  • CertificateHolder: policy certificate-holder lifecycle management.
  • PacketManager, PacketGenerator, PacketDefinition: document-packet assembly for policy correspondence.

Sources

  • Domain/SAIF.Domain/SAIF.Domain.csproj
  • Core/SAIF.Core/SAIF.SAIFCode.Core.nuspec
  • Domain/SAIF.Domain/packages.config