feat: Delta Indiv eligibility on coversme portal and ADA paper claim/preauth

Eligibility: rebuilt the Delta Indiv worker for my.deltadentalcoversme.com —
Dentist tab -> Universal Delta Sign In -> username/Next -> password -> SIGN IN,
confirmation-code (MFA) page detected by URL so the app's OTP popup shows,
then Search for Patient -> Last Name + DOB -> Submit. On the "Benefits for"
details page it reads the patient name, Subscriber # and Eligible through
(active while that date is today or later) and saves the PDF downloaded by
the Print link. Session persists: login is skipped while Search for Patient
is reachable, and Delta Indiv cookies are no longer wiped on agent startup.
The button needs Last Name + DOB (member ID optional; backend falls back to
the scraped Subscriber #). Chatbot gains a Delta Indiv option and aliases.

Claims: Delta Indiv uses the same 2024 ADA form as BCBS with the payer
address Delta Dental, P.O. Box 103, Stevens Point, WI 54481-0103. Adds Delta
Indiv Claim/PreAuth (ADA Form) buttons, Claim All and AI queue routing, Print
ADA Form in the claim viewer, a Delta Indiv fee schedule (copied from BCBS),
and Delta Indiv as its own insurance type so it is no longer treated as
Deltains.

Also renames eligibility buttons: Delta Indiv (Last name, DOB or ID),
Metlife Dental (ID or SSN), Altus (ID, First name, DOB).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-16 22:03:30 -04:00
co-authored by Claude Opus 5.5
parent a5beeb7ba9
commit 0082b7bd53
19 changed files with 714 additions and 462 deletions
@@ -84,6 +84,7 @@ export function siteKeyToAutoCheck(siteKey: string, dob?: string | Date | null):
case "CCA": return "cca";
case "DDMA": return "ddma";
case "DELTA_INS": return "delta-ins";
case "DELTA_INDIV": return "delta-indiv";
case "TUFTS_SCO": return "tufts-sco";
case "UNITED_SCO": return "united-sco";
case "UNITED_UCARD": return "united-ucard";
@@ -10,6 +10,13 @@
{ "keyword": "delta dental ma", "siteKey": "DDMA" },
{ "keyword": "ddma", "siteKey": "DDMA" },
{ "keyword": "delta dental indiv", "siteKey": "DELTA_INDIV" },
{ "keyword": "delta dental individual", "siteKey": "DELTA_INDIV" },
{ "keyword": "delta indiv", "siteKey": "DELTA_INDIV" },
{ "keyword": "deltaindiv", "siteKey": "DELTA_INDIV" },
{ "keyword": "delta individual", "siteKey": "DELTA_INDIV" },
{ "keyword": "coversme", "siteKey": "DELTA_INDIV" },
{ "keyword": "delta dental ins", "siteKey": "DELTA_INS" },
{ "keyword": "delta ins", "siteKey": "DELTA_INS" },
{ "keyword": "deltains", "siteKey": "DELTA_INS" },
@@ -83,6 +83,12 @@ async function processDeltaIndivResult(
const output: DeltaIndivEligibilityProcessorResult = {};
let createdPdfFileId: number | string | null = null;
// Delta Indiv searches by last name + DOB, so the form may have no member ID —
// fall back to the one scraped from the portal.
if (!insuranceId.trim() && typeof seleniumResult?.memberId === "string") {
insuranceId = seleniumResult.memberId.trim();
}
try {
// 1) Resolve patient name (prefer selenium extraction → form data)
const rawName =
+2
View File
@@ -12,6 +12,8 @@ const SCHEDULE_FILES: Record<string, string> = {
BCBS: "procedureCodesBCBS.json",
BCBS_MA: "procedureCodesBCBS.json",
ALTUS: "procedureCodesAltus.json",
DELTAINDIV: "procedureCodesDeltaIndiv.json",
DELTA_INDIV: "procedureCodesDeltaIndiv.json",
METLIFE: "procedureCodesMetLife.json",
METLIFEDENTAL: "procedureCodesMetLife.json",
TUFTSSCO: "procedureCodesTuftsSCO.json",
+9 -1
View File
@@ -33,11 +33,19 @@ export const ADA_PAYERS: Record<string, AdaPayer> = {
address1: "P.O. Box 1557",
cityStateZip: "Providence, RI 02901-1557",
},
DELTA_INDIV: {
name: "Delta Dental",
address1: "P.O. Box 103",
cityStateZip: "Stevens Point, WI 54481-0103",
},
};
/** ADA payer key for a claim's insurance provider text (defaults to BCBS MA). */
export function adaPayerKeyForProvider(provider?: string | null): string {
return /altus/i.test(provider ?? "") ? "ALTUS" : "BCBS_MA";
const p = provider ?? "";
if (/altus/i.test(p)) return "ALTUS";
if (/delta\s*(dental\s*)?indiv/i.test(p)) return "DELTA_INDIV";
return "BCBS_MA";
}
export type AdaClaimInput = {