candidhealth 0.34.1 → 0.34.2
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.
- checksums.yaml +4 -4
- data/lib/candidhealth/encounter_providers/v_2/types/rendering_provider.rb +10 -10
- data/lib/candidhealth/encounter_providers/v_2/types/rendering_provider_update.rb +123 -0
- data/lib/candidhealth/encounters/v_4/client.rb +282 -32
- data/lib/candidhealth/encounters/v_4/types/encounter.rb +11 -11
- data/lib/candidhealth/encounters/v_4/types/encounter_base.rb +11 -1
- data/lib/candidhealth/{third_party_payers/v_1/types/toggle_third_party_payer_enablement_request.rb → encounters/v_4/types/insurance_pay_missing_primary_coverage_error_type.rb} +17 -16
- data/lib/candidhealth/guarantor/v_1/client.rb +39 -89
- data/lib/candidhealth/guarantor/v_1/types/guarantor_update.rb +144 -0
- data/lib/candidhealth/payers/v_3/types/payer.rb +41 -2
- data/lib/candidhealth/pre_encounter/appointments/v_1/client.rb +68 -4
- data/lib/candidhealth/pre_encounter/appointments/v_1/types/appointment.rb +17 -1
- data/lib/candidhealth/pre_encounter/appointments/v_1/types/mutable_appointment.rb +17 -1
- data/lib/candidhealth/pre_encounter/common/types/additional_payer_information.rb +92 -0
- data/lib/candidhealth/pre_encounter/coverages/v_1/client.rb +48 -4
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/benefit_type.rb +20 -0
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/coverage.rb +15 -1
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/coverage_details.rb +104 -0
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/coverage_level.rb +17 -0
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/coverage_value_unit.rb +17 -0
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/insurance_plan.rb +16 -2
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/latest_eligibility_check.rb +83 -0
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/mutable_coverage.rb +15 -1
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/plan_coverage.rb +29 -2
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/service_coverage.rb +26 -2
- data/lib/candidhealth/pre_encounter/patients/v_1/client.rb +12 -4
- data/lib/candidhealth/pre_encounter/patients/v_1/types/authorization.rb +148 -0
- data/lib/candidhealth/pre_encounter/patients/v_1/types/authorization_unit.rb +15 -0
- data/lib/candidhealth/pre_encounter/patients/v_1/types/mutable_patient.rb +26 -2
- data/lib/candidhealth/pre_encounter/patients/v_1/types/patient.rb +26 -2
- data/lib/candidhealth/pre_encounter/patients/v_1/types/referral.rb +106 -0
- data/lib/candidhealth/service_facility/client.rb +27 -51
- data/lib/candidhealth/service_facility/types/encounter_service_facility_update.rb +90 -0
- data/lib/candidhealth.rb +0 -21
- data/lib/requests.rb +2 -2
- data/lib/types_export.rb +13 -16
- metadata +15 -24
- data/lib/candidhealth/third_party_payer_payments/client.rb +0 -30
- data/lib/candidhealth/third_party_payer_payments/v_1/client.rb +0 -360
- data/lib/candidhealth/third_party_payer_payments/v_1/types/third_party_payer_payment.rb +0 -138
- data/lib/candidhealth/third_party_payer_payments/v_1/types/third_party_payer_payment_create.rb +0 -124
- data/lib/candidhealth/third_party_payer_payments/v_1/types/third_party_payer_payment_sort_field.rb +0 -14
- data/lib/candidhealth/third_party_payer_payments/v_1/types/third_party_payer_payments_page.rb +0 -88
- data/lib/candidhealth/third_party_payer_refunds/client.rb +0 -30
- data/lib/candidhealth/third_party_payer_refunds/v_1/client.rb +0 -385
- data/lib/candidhealth/third_party_payer_refunds/v_1/types/third_party_payer_refund.rb +0 -139
- data/lib/candidhealth/third_party_payer_refunds/v_1/types/third_party_payer_refund_create.rb +0 -125
- data/lib/candidhealth/third_party_payer_refunds/v_1/types/third_party_payer_refund_sort_field.rb +0 -14
- data/lib/candidhealth/third_party_payer_refunds/v_1/types/third_party_payer_refunds_page.rb +0 -88
- data/lib/candidhealth/third_party_payers/client.rb +0 -30
- data/lib/candidhealth/third_party_payers/v_1/client.rb +0 -375
- data/lib/candidhealth/third_party_payers/v_1/types/create_third_party_payer_request.rb +0 -79
- data/lib/candidhealth/third_party_payers/v_1/types/third_party_payer.rb +0 -100
- data/lib/candidhealth/third_party_payers/v_1/types/third_party_payer_category_update.rb +0 -97
- data/lib/candidhealth/third_party_payers/v_1/types/third_party_payer_description_update.rb +0 -97
- data/lib/candidhealth/third_party_payers/v_1/types/third_party_payer_page.rb +0 -88
- data/lib/candidhealth/third_party_payers/v_1/types/third_party_payer_sort_field.rb +0 -16
- data/lib/candidhealth/third_party_payers/v_1/types/third_party_payer_update_request.rb +0 -92
@@ -48,6 +48,11 @@ module CandidApiClient
|
|
48
48
|
# * :member_id (String)
|
49
49
|
# * :payer_id (String)
|
50
50
|
# * :payer_name (String)
|
51
|
+
# * :additional_payer_information (Hash)
|
52
|
+
# * :availity_eligibility_id (String)
|
53
|
+
# * :availity_payer_id (String)
|
54
|
+
# * :availity_payer_name (String)
|
55
|
+
# * :availity_remittance_payer_id (String)
|
51
56
|
# * :group_number (String)
|
52
57
|
# * :name (String)
|
53
58
|
# * :plan_type (CandidApiClient::PreEncounter::Coverages::V1::Types::NetworkType)
|
@@ -58,6 +63,10 @@ module CandidApiClient
|
|
58
63
|
# * :insurance_card_image_locator (String)
|
59
64
|
# * :verified (Boolean)
|
60
65
|
# * :eligibility_checks (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityCheckMetadata>)
|
66
|
+
# * :latest_eligibility_check (Hash)
|
67
|
+
# * :check_id (String)
|
68
|
+
# * :status (CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityStatus)
|
69
|
+
# * :initiated_at (DateTime)
|
61
70
|
# * :benefits (Hash)
|
62
71
|
# * :plan_coverage (Hash)
|
63
72
|
# * :in_network (Hash)
|
@@ -74,6 +83,7 @@ module CandidApiClient
|
|
74
83
|
# * :family (Float)
|
75
84
|
# * :individual (Float)
|
76
85
|
# * :additional_notes (String)
|
86
|
+
# * :in_network_flat (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageDetails>)
|
77
87
|
# * :out_of_network (Hash)
|
78
88
|
# * :deductible (Hash)
|
79
89
|
# * :family (Float)
|
@@ -88,12 +98,13 @@ module CandidApiClient
|
|
88
98
|
# * :family (Float)
|
89
99
|
# * :individual (Float)
|
90
100
|
# * :additional_notes (String)
|
101
|
+
# * :out_of_network_flat (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageDetails>)
|
91
102
|
# * :service_specific_coverage (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::ServiceCoverage>)
|
92
103
|
# @param request_options [CandidApiClient::RequestOptions]
|
93
104
|
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::Coverage]
|
94
105
|
# @example
|
95
106
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
96
|
-
# api.pre_encounter.coverages.v_1.create(request: { status: ACTIVE, subscriber: { name: { family: "string", given: ["string"], use: USUAL, period: { start:
|
107
|
+
# api.pre_encounter.coverages.v_1.create(request: { status: ACTIVE, subscriber: { name: { family: "string", given: ["string"], use: USUAL, period: { start: {"key":"value"}, end_: {"key":"value"} } }, date_of_birth: DateTime.parse(2023-01-15), biological_sex: FEMALE }, relationship: SELF, patient: "string", insurance_plan: { member_id: "string", payer_id: "string", payer_name: "string", additional_payer_information: { availity_eligibility_id: "string", availity_payer_id: "string", availity_payer_name: "string", availity_remittance_payer_id: "string" }, group_number: "string", name: "string", plan_type: SELF_PAY, type: C_01, period: { start: {"key":"value"}, end_: {"key":"value"} }, insurance_card_image_locator: "string" }, verified: true, eligibility_checks: [{ check_id: "string", service_code: MEDICAL_CARE, status: CREATED, initiated_by: "string", initiated_at: DateTime.parse(2024-01-15T09:30:00.000Z) }], latest_eligibility_check: { check_id: "string", status: ACTIVE, initiated_at: DateTime.parse(2024-01-15T09:30:00.000Z) }, benefits: { plan_coverage: {"key":"value"}, service_specific_coverage: {"key":"value"} } })
|
97
108
|
def create(request:, request_options: nil)
|
98
109
|
response = @request_client.conn.post do |req|
|
99
110
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -133,6 +144,11 @@ module CandidApiClient
|
|
133
144
|
# * :member_id (String)
|
134
145
|
# * :payer_id (String)
|
135
146
|
# * :payer_name (String)
|
147
|
+
# * :additional_payer_information (Hash)
|
148
|
+
# * :availity_eligibility_id (String)
|
149
|
+
# * :availity_payer_id (String)
|
150
|
+
# * :availity_payer_name (String)
|
151
|
+
# * :availity_remittance_payer_id (String)
|
136
152
|
# * :group_number (String)
|
137
153
|
# * :name (String)
|
138
154
|
# * :plan_type (CandidApiClient::PreEncounter::Coverages::V1::Types::NetworkType)
|
@@ -143,6 +159,10 @@ module CandidApiClient
|
|
143
159
|
# * :insurance_card_image_locator (String)
|
144
160
|
# * :verified (Boolean)
|
145
161
|
# * :eligibility_checks (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityCheckMetadata>)
|
162
|
+
# * :latest_eligibility_check (Hash)
|
163
|
+
# * :check_id (String)
|
164
|
+
# * :status (CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityStatus)
|
165
|
+
# * :initiated_at (DateTime)
|
146
166
|
# * :benefits (Hash)
|
147
167
|
# * :plan_coverage (Hash)
|
148
168
|
# * :in_network (Hash)
|
@@ -159,6 +179,7 @@ module CandidApiClient
|
|
159
179
|
# * :family (Float)
|
160
180
|
# * :individual (Float)
|
161
181
|
# * :additional_notes (String)
|
182
|
+
# * :in_network_flat (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageDetails>)
|
162
183
|
# * :out_of_network (Hash)
|
163
184
|
# * :deductible (Hash)
|
164
185
|
# * :family (Float)
|
@@ -173,6 +194,7 @@ module CandidApiClient
|
|
173
194
|
# * :family (Float)
|
174
195
|
# * :individual (Float)
|
175
196
|
# * :additional_notes (String)
|
197
|
+
# * :out_of_network_flat (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageDetails>)
|
176
198
|
# * :service_specific_coverage (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::ServiceCoverage>)
|
177
199
|
# @param request_options [CandidApiClient::RequestOptions]
|
178
200
|
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::Coverage]
|
@@ -181,7 +203,7 @@ module CandidApiClient
|
|
181
203
|
# api.pre_encounter.coverages.v_1.update(
|
182
204
|
# id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
183
205
|
# version: "string",
|
184
|
-
# request: { status: ACTIVE, subscriber: { name: { family: "string", given: ["string"], use: USUAL, period: { start:
|
206
|
+
# request: { status: ACTIVE, subscriber: { name: { family: "string", given: ["string"], use: USUAL, period: { start: {"key":"value"}, end_: {"key":"value"} } }, date_of_birth: DateTime.parse(2023-01-15), biological_sex: FEMALE }, relationship: SELF, patient: "string", insurance_plan: { member_id: "string", payer_id: "string", payer_name: "string", additional_payer_information: { availity_eligibility_id: "string", availity_payer_id: "string", availity_payer_name: "string", availity_remittance_payer_id: "string" }, group_number: "string", name: "string", plan_type: SELF_PAY, type: C_01, period: { start: {"key":"value"}, end_: {"key":"value"} }, insurance_card_image_locator: "string" }, verified: true, eligibility_checks: [{ check_id: "string", service_code: MEDICAL_CARE, status: CREATED, initiated_by: "string", initiated_at: DateTime.parse(2024-01-15T09:30:00.000Z) }], latest_eligibility_check: { check_id: "string", status: ACTIVE, initiated_at: DateTime.parse(2024-01-15T09:30:00.000Z) }, benefits: { plan_coverage: {"key":"value"}, service_specific_coverage: {"key":"value"} } }
|
185
207
|
# )
|
186
208
|
def update(id:, version:, request:, request_options: nil)
|
187
209
|
response = @request_client.conn.put do |req|
|
@@ -404,6 +426,11 @@ module CandidApiClient
|
|
404
426
|
# * :member_id (String)
|
405
427
|
# * :payer_id (String)
|
406
428
|
# * :payer_name (String)
|
429
|
+
# * :additional_payer_information (Hash)
|
430
|
+
# * :availity_eligibility_id (String)
|
431
|
+
# * :availity_payer_id (String)
|
432
|
+
# * :availity_payer_name (String)
|
433
|
+
# * :availity_remittance_payer_id (String)
|
407
434
|
# * :group_number (String)
|
408
435
|
# * :name (String)
|
409
436
|
# * :plan_type (CandidApiClient::PreEncounter::Coverages::V1::Types::NetworkType)
|
@@ -414,6 +441,10 @@ module CandidApiClient
|
|
414
441
|
# * :insurance_card_image_locator (String)
|
415
442
|
# * :verified (Boolean)
|
416
443
|
# * :eligibility_checks (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityCheckMetadata>)
|
444
|
+
# * :latest_eligibility_check (Hash)
|
445
|
+
# * :check_id (String)
|
446
|
+
# * :status (CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityStatus)
|
447
|
+
# * :initiated_at (DateTime)
|
417
448
|
# * :benefits (Hash)
|
418
449
|
# * :plan_coverage (Hash)
|
419
450
|
# * :in_network (Hash)
|
@@ -430,6 +461,7 @@ module CandidApiClient
|
|
430
461
|
# * :family (Float)
|
431
462
|
# * :individual (Float)
|
432
463
|
# * :additional_notes (String)
|
464
|
+
# * :in_network_flat (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageDetails>)
|
433
465
|
# * :out_of_network (Hash)
|
434
466
|
# * :deductible (Hash)
|
435
467
|
# * :family (Float)
|
@@ -444,12 +476,13 @@ module CandidApiClient
|
|
444
476
|
# * :family (Float)
|
445
477
|
# * :individual (Float)
|
446
478
|
# * :additional_notes (String)
|
479
|
+
# * :out_of_network_flat (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageDetails>)
|
447
480
|
# * :service_specific_coverage (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::ServiceCoverage>)
|
448
481
|
# @param request_options [CandidApiClient::RequestOptions]
|
449
482
|
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::Coverage]
|
450
483
|
# @example
|
451
484
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
452
|
-
# api.pre_encounter.coverages.v_1.create(request: { status: ACTIVE, subscriber: { name: { family: "string", given: ["string"], use: USUAL, period: { start:
|
485
|
+
# api.pre_encounter.coverages.v_1.create(request: { status: ACTIVE, subscriber: { name: { family: "string", given: ["string"], use: USUAL, period: { start: {"key":"value"}, end_: {"key":"value"} } }, date_of_birth: DateTime.parse(2023-01-15), biological_sex: FEMALE }, relationship: SELF, patient: "string", insurance_plan: { member_id: "string", payer_id: "string", payer_name: "string", additional_payer_information: { availity_eligibility_id: "string", availity_payer_id: "string", availity_payer_name: "string", availity_remittance_payer_id: "string" }, group_number: "string", name: "string", plan_type: SELF_PAY, type: C_01, period: { start: {"key":"value"}, end_: {"key":"value"} }, insurance_card_image_locator: "string" }, verified: true, eligibility_checks: [{ check_id: "string", service_code: MEDICAL_CARE, status: CREATED, initiated_by: "string", initiated_at: DateTime.parse(2024-01-15T09:30:00.000Z) }], latest_eligibility_check: { check_id: "string", status: ACTIVE, initiated_at: DateTime.parse(2024-01-15T09:30:00.000Z) }, benefits: { plan_coverage: {"key":"value"}, service_specific_coverage: {"key":"value"} } })
|
453
486
|
def create(request:, request_options: nil)
|
454
487
|
Async do
|
455
488
|
response = @request_client.conn.post do |req|
|
@@ -491,6 +524,11 @@ module CandidApiClient
|
|
491
524
|
# * :member_id (String)
|
492
525
|
# * :payer_id (String)
|
493
526
|
# * :payer_name (String)
|
527
|
+
# * :additional_payer_information (Hash)
|
528
|
+
# * :availity_eligibility_id (String)
|
529
|
+
# * :availity_payer_id (String)
|
530
|
+
# * :availity_payer_name (String)
|
531
|
+
# * :availity_remittance_payer_id (String)
|
494
532
|
# * :group_number (String)
|
495
533
|
# * :name (String)
|
496
534
|
# * :plan_type (CandidApiClient::PreEncounter::Coverages::V1::Types::NetworkType)
|
@@ -501,6 +539,10 @@ module CandidApiClient
|
|
501
539
|
# * :insurance_card_image_locator (String)
|
502
540
|
# * :verified (Boolean)
|
503
541
|
# * :eligibility_checks (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityCheckMetadata>)
|
542
|
+
# * :latest_eligibility_check (Hash)
|
543
|
+
# * :check_id (String)
|
544
|
+
# * :status (CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityStatus)
|
545
|
+
# * :initiated_at (DateTime)
|
504
546
|
# * :benefits (Hash)
|
505
547
|
# * :plan_coverage (Hash)
|
506
548
|
# * :in_network (Hash)
|
@@ -517,6 +559,7 @@ module CandidApiClient
|
|
517
559
|
# * :family (Float)
|
518
560
|
# * :individual (Float)
|
519
561
|
# * :additional_notes (String)
|
562
|
+
# * :in_network_flat (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageDetails>)
|
520
563
|
# * :out_of_network (Hash)
|
521
564
|
# * :deductible (Hash)
|
522
565
|
# * :family (Float)
|
@@ -531,6 +574,7 @@ module CandidApiClient
|
|
531
574
|
# * :family (Float)
|
532
575
|
# * :individual (Float)
|
533
576
|
# * :additional_notes (String)
|
577
|
+
# * :out_of_network_flat (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageDetails>)
|
534
578
|
# * :service_specific_coverage (Array<CandidApiClient::PreEncounter::Coverages::V1::Types::ServiceCoverage>)
|
535
579
|
# @param request_options [CandidApiClient::RequestOptions]
|
536
580
|
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::Coverage]
|
@@ -539,7 +583,7 @@ module CandidApiClient
|
|
539
583
|
# api.pre_encounter.coverages.v_1.update(
|
540
584
|
# id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
541
585
|
# version: "string",
|
542
|
-
# request: { status: ACTIVE, subscriber: { name: { family: "string", given: ["string"], use: USUAL, period: { start:
|
586
|
+
# request: { status: ACTIVE, subscriber: { name: { family: "string", given: ["string"], use: USUAL, period: { start: {"key":"value"}, end_: {"key":"value"} } }, date_of_birth: DateTime.parse(2023-01-15), biological_sex: FEMALE }, relationship: SELF, patient: "string", insurance_plan: { member_id: "string", payer_id: "string", payer_name: "string", additional_payer_information: { availity_eligibility_id: "string", availity_payer_id: "string", availity_payer_name: "string", availity_remittance_payer_id: "string" }, group_number: "string", name: "string", plan_type: SELF_PAY, type: C_01, period: { start: {"key":"value"}, end_: {"key":"value"} }, insurance_card_image_locator: "string" }, verified: true, eligibility_checks: [{ check_id: "string", service_code: MEDICAL_CARE, status: CREATED, initiated_by: "string", initiated_at: DateTime.parse(2024-01-15T09:30:00.000Z) }], latest_eligibility_check: { check_id: "string", status: ACTIVE, initiated_at: DateTime.parse(2024-01-15T09:30:00.000Z) }, benefits: { plan_coverage: {"key":"value"}, service_specific_coverage: {"key":"value"} } }
|
543
587
|
# )
|
544
588
|
def update(id:, version:, request:, request_options: nil)
|
545
589
|
Async do
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module CandidApiClient
|
4
|
+
module PreEncounter
|
5
|
+
module Coverages
|
6
|
+
module V1
|
7
|
+
module Types
|
8
|
+
class BenefitType
|
9
|
+
DEDUCTIBLE = "DEDUCTIBLE"
|
10
|
+
DEDUCTIBLE_REMAINING = "DEDUCTIBLE_REMAINING"
|
11
|
+
OOP_MAX = "OOP_MAX"
|
12
|
+
OOP_MAX_REMAINING = "OOP_MAX_REMAINING"
|
13
|
+
COPAY = "COPAY"
|
14
|
+
COINSURANCE = "COINSURANCE"
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
@@ -6,6 +6,7 @@ require_relative "subscriber"
|
|
6
6
|
require_relative "../../../common/types/relationship"
|
7
7
|
require_relative "insurance_plan"
|
8
8
|
require_relative "eligibility_check_metadata"
|
9
|
+
require_relative "latest_eligibility_check"
|
9
10
|
require_relative "coverage_benefits"
|
10
11
|
require "ostruct"
|
11
12
|
require "json"
|
@@ -48,6 +49,8 @@ module CandidApiClient
|
|
48
49
|
attr_reader :verified
|
49
50
|
# @return [Array<CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityCheckMetadata>] A list of eligibility check metadata that have been initiated on this coverage.
|
50
51
|
attr_reader :eligibility_checks
|
52
|
+
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::LatestEligibilityCheck] The latest eligibility check metadata that has been initiated on this coverage.
|
53
|
+
attr_reader :latest_eligibility_check
|
51
54
|
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageBenefits] The eligibility of the patient for the coverage, manually verified by users.
|
52
55
|
attr_reader :benefits
|
53
56
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
@@ -76,11 +79,12 @@ module CandidApiClient
|
|
76
79
|
# @param insurance_plan [CandidApiClient::PreEncounter::Coverages::V1::Types::InsurancePlan]
|
77
80
|
# @param verified [Boolean] A boolean indicating if the coverage has been verified by a user.
|
78
81
|
# @param eligibility_checks [Array<CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityCheckMetadata>] A list of eligibility check metadata that have been initiated on this coverage.
|
82
|
+
# @param latest_eligibility_check [CandidApiClient::PreEncounter::Coverages::V1::Types::LatestEligibilityCheck] The latest eligibility check metadata that has been initiated on this coverage.
|
79
83
|
# @param benefits [CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageBenefits] The eligibility of the patient for the coverage, manually verified by users.
|
80
84
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
81
85
|
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::Coverage]
|
82
86
|
def initialize(id:, organization_id:, deactivated:, version:, updated_at:, updating_user_id:, status:,
|
83
|
-
subscriber:, relationship:, patient:, insurance_plan:, verified:, eligibility_checks: OMIT, benefits: OMIT, additional_properties: nil)
|
87
|
+
subscriber:, relationship:, patient:, insurance_plan:, verified:, eligibility_checks: OMIT, latest_eligibility_check: OMIT, benefits: OMIT, additional_properties: nil)
|
84
88
|
@id = id
|
85
89
|
@organization_id = organization_id
|
86
90
|
@deactivated = deactivated
|
@@ -94,6 +98,7 @@ module CandidApiClient
|
|
94
98
|
@insurance_plan = insurance_plan
|
95
99
|
@verified = verified
|
96
100
|
@eligibility_checks = eligibility_checks if eligibility_checks != OMIT
|
101
|
+
@latest_eligibility_check = latest_eligibility_check if latest_eligibility_check != OMIT
|
97
102
|
@benefits = benefits if benefits != OMIT
|
98
103
|
@additional_properties = additional_properties
|
99
104
|
@_field_set = {
|
@@ -110,6 +115,7 @@ module CandidApiClient
|
|
110
115
|
"insurance_plan": insurance_plan,
|
111
116
|
"verified": verified,
|
112
117
|
"eligibility_checks": eligibility_checks,
|
118
|
+
"latest_eligibility_check": latest_eligibility_check,
|
113
119
|
"benefits": benefits
|
114
120
|
}.reject do |_k, v|
|
115
121
|
v == OMIT
|
@@ -149,6 +155,12 @@ module CandidApiClient
|
|
149
155
|
item = item.to_json
|
150
156
|
CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityCheckMetadata.from_json(json_object: item)
|
151
157
|
end
|
158
|
+
if parsed_json["latest_eligibility_check"].nil?
|
159
|
+
latest_eligibility_check = nil
|
160
|
+
else
|
161
|
+
latest_eligibility_check = parsed_json["latest_eligibility_check"].to_json
|
162
|
+
latest_eligibility_check = CandidApiClient::PreEncounter::Coverages::V1::Types::LatestEligibilityCheck.from_json(json_object: latest_eligibility_check)
|
163
|
+
end
|
152
164
|
if parsed_json["benefits"].nil?
|
153
165
|
benefits = nil
|
154
166
|
else
|
@@ -169,6 +181,7 @@ module CandidApiClient
|
|
169
181
|
insurance_plan: insurance_plan,
|
170
182
|
verified: verified,
|
171
183
|
eligibility_checks: eligibility_checks,
|
184
|
+
latest_eligibility_check: latest_eligibility_check,
|
172
185
|
benefits: benefits,
|
173
186
|
additional_properties: struct
|
174
187
|
)
|
@@ -201,6 +214,7 @@ module CandidApiClient
|
|
201
214
|
CandidApiClient::PreEncounter::Coverages::V1::Types::InsurancePlan.validate_raw(obj: obj.insurance_plan)
|
202
215
|
obj.verified.is_a?(Boolean) != false || raise("Passed value for field obj.verified is not the expected type, validation failed.")
|
203
216
|
obj.eligibility_checks&.is_a?(Array) != false || raise("Passed value for field obj.eligibility_checks is not the expected type, validation failed.")
|
217
|
+
obj.latest_eligibility_check.nil? || CandidApiClient::PreEncounter::Coverages::V1::Types::LatestEligibilityCheck.validate_raw(obj: obj.latest_eligibility_check)
|
204
218
|
obj.benefits.nil? || CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageBenefits.validate_raw(obj: obj.benefits)
|
205
219
|
end
|
206
220
|
end
|
@@ -0,0 +1,104 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "benefit_type"
|
4
|
+
require_relative "coverage_level"
|
5
|
+
require_relative "coverage_value_unit"
|
6
|
+
require "ostruct"
|
7
|
+
require "json"
|
8
|
+
|
9
|
+
module CandidApiClient
|
10
|
+
module PreEncounter
|
11
|
+
module Coverages
|
12
|
+
module V1
|
13
|
+
module Types
|
14
|
+
class CoverageDetails
|
15
|
+
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::BenefitType]
|
16
|
+
attr_reader :type
|
17
|
+
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageLevel]
|
18
|
+
attr_reader :coverage_level
|
19
|
+
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageValueUnit]
|
20
|
+
attr_reader :unit
|
21
|
+
# @return [Float]
|
22
|
+
attr_reader :value
|
23
|
+
# @return [String]
|
24
|
+
attr_reader :additional_notes
|
25
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
26
|
+
attr_reader :additional_properties
|
27
|
+
# @return [Object]
|
28
|
+
attr_reader :_field_set
|
29
|
+
protected :_field_set
|
30
|
+
|
31
|
+
OMIT = Object.new
|
32
|
+
|
33
|
+
# @param type [CandidApiClient::PreEncounter::Coverages::V1::Types::BenefitType]
|
34
|
+
# @param coverage_level [CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageLevel]
|
35
|
+
# @param unit [CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageValueUnit]
|
36
|
+
# @param value [Float]
|
37
|
+
# @param additional_notes [String]
|
38
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
39
|
+
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageDetails]
|
40
|
+
def initialize(type:, coverage_level:, unit:, value:, additional_notes: OMIT, additional_properties: nil)
|
41
|
+
@type = type
|
42
|
+
@coverage_level = coverage_level
|
43
|
+
@unit = unit
|
44
|
+
@value = value
|
45
|
+
@additional_notes = additional_notes if additional_notes != OMIT
|
46
|
+
@additional_properties = additional_properties
|
47
|
+
@_field_set = {
|
48
|
+
"type": type,
|
49
|
+
"coverageLevel": coverage_level,
|
50
|
+
"unit": unit,
|
51
|
+
"value": value,
|
52
|
+
"additional_notes": additional_notes
|
53
|
+
}.reject do |_k, v|
|
54
|
+
v == OMIT
|
55
|
+
end
|
56
|
+
end
|
57
|
+
|
58
|
+
# Deserialize a JSON object to an instance of CoverageDetails
|
59
|
+
#
|
60
|
+
# @param json_object [String]
|
61
|
+
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageDetails]
|
62
|
+
def self.from_json(json_object:)
|
63
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
64
|
+
type = struct["type"]
|
65
|
+
coverage_level = struct["coverageLevel"]
|
66
|
+
unit = struct["unit"]
|
67
|
+
value = struct["value"]
|
68
|
+
additional_notes = struct["additional_notes"]
|
69
|
+
new(
|
70
|
+
type: type,
|
71
|
+
coverage_level: coverage_level,
|
72
|
+
unit: unit,
|
73
|
+
value: value,
|
74
|
+
additional_notes: additional_notes,
|
75
|
+
additional_properties: struct
|
76
|
+
)
|
77
|
+
end
|
78
|
+
|
79
|
+
# Serialize an instance of CoverageDetails to a JSON object
|
80
|
+
#
|
81
|
+
# @return [String]
|
82
|
+
def to_json(*_args)
|
83
|
+
@_field_set&.to_json
|
84
|
+
end
|
85
|
+
|
86
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
87
|
+
# hash and check each fields type against the current object's property
|
88
|
+
# definitions.
|
89
|
+
#
|
90
|
+
# @param obj [Object]
|
91
|
+
# @return [Void]
|
92
|
+
def self.validate_raw(obj:)
|
93
|
+
obj.type.is_a?(CandidApiClient::PreEncounter::Coverages::V1::Types::BenefitType) != false || raise("Passed value for field obj.type is not the expected type, validation failed.")
|
94
|
+
obj.coverage_level.is_a?(CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageLevel) != false || raise("Passed value for field obj.coverage_level is not the expected type, validation failed.")
|
95
|
+
obj.unit.is_a?(CandidApiClient::PreEncounter::Coverages::V1::Types::CoverageValueUnit) != false || raise("Passed value for field obj.unit is not the expected type, validation failed.")
|
96
|
+
obj.value.is_a?(Float) != false || raise("Passed value for field obj.value is not the expected type, validation failed.")
|
97
|
+
obj.additional_notes&.is_a?(String) != false || raise("Passed value for field obj.additional_notes is not the expected type, validation failed.")
|
98
|
+
end
|
99
|
+
end
|
100
|
+
end
|
101
|
+
end
|
102
|
+
end
|
103
|
+
end
|
104
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module CandidApiClient
|
4
|
+
module PreEncounter
|
5
|
+
module Coverages
|
6
|
+
module V1
|
7
|
+
module Types
|
8
|
+
class CoverageLevel
|
9
|
+
INDIVIDUAL = "INDIVIDUAL"
|
10
|
+
FAMILY = "FAMILY"
|
11
|
+
EMPLOYEE_ONLY = "EMPLOYEE_ONLY"
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module CandidApiClient
|
4
|
+
module PreEncounter
|
5
|
+
module Coverages
|
6
|
+
module V1
|
7
|
+
module Types
|
8
|
+
class CoverageValueUnit
|
9
|
+
PERCENT = "PERCENT"
|
10
|
+
CURRENCY = "CURRENCY"
|
11
|
+
COUNT = "COUNT"
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
@@ -1,5 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
+
require_relative "../../../common/types/additional_payer_information"
|
3
4
|
require_relative "network_type"
|
4
5
|
require_relative "insurance_type_code"
|
5
6
|
require_relative "../../../common/types/period"
|
@@ -18,6 +19,8 @@ module CandidApiClient
|
|
18
19
|
attr_reader :payer_id
|
19
20
|
# @return [String]
|
20
21
|
attr_reader :payer_name
|
22
|
+
# @return [CandidApiClient::PreEncounter::Common::Types::AdditionalPayerInformation]
|
23
|
+
attr_reader :additional_payer_information
|
21
24
|
# @return [String]
|
22
25
|
attr_reader :group_number
|
23
26
|
# @return [String]
|
@@ -41,6 +44,7 @@ module CandidApiClient
|
|
41
44
|
# @param member_id [String]
|
42
45
|
# @param payer_id [String]
|
43
46
|
# @param payer_name [String]
|
47
|
+
# @param additional_payer_information [CandidApiClient::PreEncounter::Common::Types::AdditionalPayerInformation]
|
44
48
|
# @param group_number [String]
|
45
49
|
# @param name [String]
|
46
50
|
# @param plan_type [CandidApiClient::PreEncounter::Coverages::V1::Types::NetworkType]
|
@@ -49,11 +53,12 @@ module CandidApiClient
|
|
49
53
|
# @param insurance_card_image_locator [String]
|
50
54
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
51
55
|
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::InsurancePlan]
|
52
|
-
def initialize(member_id:, payer_id:, payer_name:,
|
53
|
-
type: OMIT, period: OMIT, insurance_card_image_locator: OMIT, additional_properties: nil)
|
56
|
+
def initialize(member_id:, payer_id:, payer_name:, additional_payer_information: OMIT, group_number: OMIT,
|
57
|
+
name: OMIT, plan_type: OMIT, type: OMIT, period: OMIT, insurance_card_image_locator: OMIT, additional_properties: nil)
|
54
58
|
@member_id = member_id
|
55
59
|
@payer_id = payer_id
|
56
60
|
@payer_name = payer_name
|
61
|
+
@additional_payer_information = additional_payer_information if additional_payer_information != OMIT
|
57
62
|
@group_number = group_number if group_number != OMIT
|
58
63
|
@name = name if name != OMIT
|
59
64
|
@plan_type = plan_type if plan_type != OMIT
|
@@ -65,6 +70,7 @@ module CandidApiClient
|
|
65
70
|
"member_id": member_id,
|
66
71
|
"payer_id": payer_id,
|
67
72
|
"payer_name": payer_name,
|
73
|
+
"additional_payer_information": additional_payer_information,
|
68
74
|
"group_number": group_number,
|
69
75
|
"name": name,
|
70
76
|
"plan_type": plan_type,
|
@@ -86,6 +92,12 @@ module CandidApiClient
|
|
86
92
|
member_id = struct["member_id"]
|
87
93
|
payer_id = struct["payer_id"]
|
88
94
|
payer_name = struct["payer_name"]
|
95
|
+
if parsed_json["additional_payer_information"].nil?
|
96
|
+
additional_payer_information = nil
|
97
|
+
else
|
98
|
+
additional_payer_information = parsed_json["additional_payer_information"].to_json
|
99
|
+
additional_payer_information = CandidApiClient::PreEncounter::Common::Types::AdditionalPayerInformation.from_json(json_object: additional_payer_information)
|
100
|
+
end
|
89
101
|
group_number = struct["group_number"]
|
90
102
|
name = struct["name"]
|
91
103
|
plan_type = struct["plan_type"]
|
@@ -101,6 +113,7 @@ module CandidApiClient
|
|
101
113
|
member_id: member_id,
|
102
114
|
payer_id: payer_id,
|
103
115
|
payer_name: payer_name,
|
116
|
+
additional_payer_information: additional_payer_information,
|
104
117
|
group_number: group_number,
|
105
118
|
name: name,
|
106
119
|
plan_type: plan_type,
|
@@ -128,6 +141,7 @@ module CandidApiClient
|
|
128
141
|
obj.member_id.is_a?(String) != false || raise("Passed value for field obj.member_id is not the expected type, validation failed.")
|
129
142
|
obj.payer_id.is_a?(String) != false || raise("Passed value for field obj.payer_id is not the expected type, validation failed.")
|
130
143
|
obj.payer_name.is_a?(String) != false || raise("Passed value for field obj.payer_name is not the expected type, validation failed.")
|
144
|
+
obj.additional_payer_information.nil? || CandidApiClient::PreEncounter::Common::Types::AdditionalPayerInformation.validate_raw(obj: obj.additional_payer_information)
|
131
145
|
obj.group_number&.is_a?(String) != false || raise("Passed value for field obj.group_number is not the expected type, validation failed.")
|
132
146
|
obj.name&.is_a?(String) != false || raise("Passed value for field obj.name is not the expected type, validation failed.")
|
133
147
|
obj.plan_type&.is_a?(CandidApiClient::PreEncounter::Coverages::V1::Types::NetworkType) != false || raise("Passed value for field obj.plan_type is not the expected type, validation failed.")
|
@@ -0,0 +1,83 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "eligibility_status"
|
4
|
+
require "date"
|
5
|
+
require "ostruct"
|
6
|
+
require "json"
|
7
|
+
|
8
|
+
module CandidApiClient
|
9
|
+
module PreEncounter
|
10
|
+
module Coverages
|
11
|
+
module V1
|
12
|
+
module Types
|
13
|
+
# A type to represent the latest eligibility check status of a coverage.
|
14
|
+
class LatestEligibilityCheck
|
15
|
+
# @return [String]
|
16
|
+
attr_reader :check_id
|
17
|
+
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityStatus]
|
18
|
+
attr_reader :status
|
19
|
+
# @return [DateTime]
|
20
|
+
attr_reader :initiated_at
|
21
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
22
|
+
attr_reader :additional_properties
|
23
|
+
# @return [Object]
|
24
|
+
attr_reader :_field_set
|
25
|
+
protected :_field_set
|
26
|
+
|
27
|
+
OMIT = Object.new
|
28
|
+
|
29
|
+
# @param check_id [String]
|
30
|
+
# @param status [CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityStatus]
|
31
|
+
# @param initiated_at [DateTime]
|
32
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
33
|
+
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::LatestEligibilityCheck]
|
34
|
+
def initialize(check_id:, status:, initiated_at:, additional_properties: nil)
|
35
|
+
@check_id = check_id
|
36
|
+
@status = status
|
37
|
+
@initiated_at = initiated_at
|
38
|
+
@additional_properties = additional_properties
|
39
|
+
@_field_set = { "check_id": check_id, "status": status, "initiated_at": initiated_at }
|
40
|
+
end
|
41
|
+
|
42
|
+
# Deserialize a JSON object to an instance of LatestEligibilityCheck
|
43
|
+
#
|
44
|
+
# @param json_object [String]
|
45
|
+
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::LatestEligibilityCheck]
|
46
|
+
def self.from_json(json_object:)
|
47
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
48
|
+
parsed_json = JSON.parse(json_object)
|
49
|
+
check_id = struct["check_id"]
|
50
|
+
status = struct["status"]
|
51
|
+
initiated_at = (DateTime.parse(parsed_json["initiated_at"]) unless parsed_json["initiated_at"].nil?)
|
52
|
+
new(
|
53
|
+
check_id: check_id,
|
54
|
+
status: status,
|
55
|
+
initiated_at: initiated_at,
|
56
|
+
additional_properties: struct
|
57
|
+
)
|
58
|
+
end
|
59
|
+
|
60
|
+
# Serialize an instance of LatestEligibilityCheck to a JSON object
|
61
|
+
#
|
62
|
+
# @return [String]
|
63
|
+
def to_json(*_args)
|
64
|
+
@_field_set&.to_json
|
65
|
+
end
|
66
|
+
|
67
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
68
|
+
# hash and check each fields type against the current object's property
|
69
|
+
# definitions.
|
70
|
+
#
|
71
|
+
# @param obj [Object]
|
72
|
+
# @return [Void]
|
73
|
+
def self.validate_raw(obj:)
|
74
|
+
obj.check_id.is_a?(String) != false || raise("Passed value for field obj.check_id is not the expected type, validation failed.")
|
75
|
+
obj.status.is_a?(CandidApiClient::PreEncounter::Coverages::V1::Types::EligibilityStatus) != false || raise("Passed value for field obj.status is not the expected type, validation failed.")
|
76
|
+
obj.initiated_at.is_a?(DateTime) != false || raise("Passed value for field obj.initiated_at is not the expected type, validation failed.")
|
77
|
+
end
|
78
|
+
end
|
79
|
+
end
|
80
|
+
end
|
81
|
+
end
|
82
|
+
end
|
83
|
+
end
|