@healthcloudai/hc-sdk 3.26.0 → 3.27.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -1328,6 +1328,68 @@ function StediClaimsResponseFromJSONTyped(json, ignoreDiscriminator) {
1328
1328
  };
1329
1329
  }
1330
1330
 
1331
+ // src/models/openapi-generated/patient/models/CheckInsuranceBenefitsRequest.ts
1332
+ function CheckInsuranceBenefitsRequestToJSON(json) {
1333
+ return CheckInsuranceBenefitsRequestToJSONTyped(json, false);
1334
+ }
1335
+ function CheckInsuranceBenefitsRequestToJSONTyped(value, ignoreDiscriminator = false) {
1336
+ if (value == null) {
1337
+ return value;
1338
+ }
1339
+ return {
1340
+ "request_id": value["request_id"],
1341
+ "service_date": value["service_date"] == null ? value["service_date"] : value["service_date"].toISOString().substring(0, 10),
1342
+ "service_type_code": value["service_type_code"]
1343
+ };
1344
+ }
1345
+
1346
+ // src/models/openapi-generated/patient/models/InsuranceBenefit.ts
1347
+ function InsuranceBenefitFromJSON(json) {
1348
+ return InsuranceBenefitFromJSONTyped(json, false);
1349
+ }
1350
+ function InsuranceBenefitFromJSONTyped(json, ignoreDiscriminator) {
1351
+ if (json == null) {
1352
+ return json;
1353
+ }
1354
+ return {
1355
+ "additional_conditions": json["additional_conditions"] == null ? void 0 : json["additional_conditions"],
1356
+ "amount": json["amount"] === void 0 ? void 0 : json["amount"] === null ? null : json["amount"],
1357
+ "benefit_end": json["benefit_end"] === void 0 ? void 0 : json["benefit_end"] === null ? null : new Date(json["benefit_end"]),
1358
+ "benefit_start": json["benefit_start"] === void 0 ? void 0 : json["benefit_start"] === null ? null : new Date(json["benefit_start"]),
1359
+ "benefit_type": json["benefit_type"],
1360
+ "coinsurance_fraction": json["coinsurance_fraction"] === void 0 ? void 0 : json["coinsurance_fraction"] === null ? null : json["coinsurance_fraction"],
1361
+ "coverage_level": json["coverage_level"] == null ? void 0 : json["coverage_level"],
1362
+ "network": json["network"] == null ? void 0 : json["network"],
1363
+ "plan_index": json["plan_index"],
1364
+ "service_type_code": json["service_type_code"],
1365
+ "time_period": json["time_period"] == null ? void 0 : json["time_period"]
1366
+ };
1367
+ }
1368
+
1369
+ // src/models/openapi-generated/patient/models/CheckInsuranceBenefitsResponse.ts
1370
+ function CheckInsuranceBenefitsResponseFromJSON(json) {
1371
+ return CheckInsuranceBenefitsResponseFromJSONTyped(json, false);
1372
+ }
1373
+ function CheckInsuranceBenefitsResponseFromJSONTyped(json, ignoreDiscriminator) {
1374
+ if (json == null) {
1375
+ return json;
1376
+ }
1377
+ return {
1378
+ "benefits": json["benefits"] == null ? void 0 : json["benefits"].map(InsuranceBenefitFromJSON),
1379
+ "check_id": json["check_id"],
1380
+ "checked_at": new Date(json["checked_at"]),
1381
+ "coverage_id": json["coverage_id"] === void 0 ? void 0 : json["coverage_id"] === null ? null : json["coverage_id"],
1382
+ "endpoint_version": json["endpoint_version"] == null ? void 0 : json["endpoint_version"],
1383
+ "interpretation": json["interpretation"] == null ? void 0 : json["interpretation"],
1384
+ "network_determination": json["network_determination"] == null ? void 0 : json["network_determination"],
1385
+ "reason": json["reason"],
1386
+ "service_date": json["service_date"] === void 0 ? void 0 : json["service_date"] === null ? null : new Date(json["service_date"]),
1387
+ "service_type_code": json["service_type_code"],
1388
+ "source": json["source"] == null ? void 0 : json["source"],
1389
+ "status": json["status"]
1390
+ };
1391
+ }
1392
+
1331
1393
  // src/models/openapi-generated/patient/models/CheckEligibilityResponse.ts
1332
1394
  function CheckEligibilityResponseFromJSON(json) {
1333
1395
  return CheckEligibilityResponseFromJSONTyped(json, false);
@@ -3496,6 +3558,12 @@ var PatientClient = class extends BaseServiceClient {
3496
3558
  body: StediRawX12EligibilityRequestToJSON(request)
3497
3559
  });
3498
3560
  }
3561
+ /** Check reported benefits. Persist this exact request ID/body for retries, including HTTP 202. */
3562
+ async checkInsuranceBenefits(request) {
3563
+ return CheckInsuranceBenefitsResponseFromJSON(await this.send("POST", "/insurance/benefits/check", {
3564
+ body: CheckInsuranceBenefitsRequestToJSON(request)
3565
+ }));
3566
+ }
3499
3567
  /** List Stedi claims linked to the authenticated patient's FHIR Claim records. */
3500
3568
  async listInsuranceClaims(query) {
3501
3569
  const response = await this.send("GET", "/insurance/claims", { query });