candidhealth 1.3.0 → 1.4.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.
- checksums.yaml +4 -4
- data/lib/candidhealth/charge_capture/v_1/client.rb +28 -2
- data/lib/candidhealth/claim_submission/v_1/types/claim_submission_record_create.rb +4 -4
- data/lib/candidhealth/claim_submission/v_1/types/claim_submission_record_create_optional.rb +4 -4
- data/lib/candidhealth/commons/types/next_responsible_party.rb +16 -0
- data/lib/candidhealth/contracts/v_2/client.rb +4 -4
- data/lib/candidhealth/diagnoses/types/service_lines_must_have_at_least_one_diagnosis_error.rb +77 -0
- data/lib/candidhealth/encounters/v_4/client.rb +2 -0
- data/lib/candidhealth/encounters/v_4/types/encounter.rb +162 -2
- data/lib/candidhealth/encounters/v_4/types/encounter_submission_expectation.rb +23 -0
- data/lib/candidhealth/exports/v_3/client.rb +16 -10
- data/lib/candidhealth/organization_providers/v_2/types/license_type.rb +1 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/client.rb +205 -2
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/coordination_of_benefits_recommendation.rb +63 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/eligibility_recommendation.rb +144 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/eligibility_recommendation_patient_info.rb +124 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/eligibility_recommendation_payload.rb +102 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/medicare_advantage_recommendation.rb +70 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/medicare_advantage_recommendation_payload.rb +87 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/payer_search_response.rb +107 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/post_eligibility_recommendation_request.rb +96 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/stedi_payer.rb +144 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/stedi_payer_item.rb +79 -0
- data/lib/candidhealth/pre_encounter/lists/v_1/types/patient_list_item.rb +28 -1
- data/lib/candidhealth/pre_encounter/tags/v_1/client.rb +8 -0
- data/lib/candidhealth/pre_encounter/tags/v_1/types/mutable_tag.rb +22 -3
- data/lib/candidhealth/pre_encounter/tags/v_1/types/tag.rb +21 -3
- data/lib/candidhealth/service_lines/v_2/client.rb +4 -0
- data/lib/candidhealth/service_lines/v_2/types/service_line.rb +18 -2
- data/lib/candidhealth/service_lines/v_2/types/service_line_create.rb +10 -2
- data/lib/candidhealth/service_lines/v_2/types/service_line_create_optional.rb +10 -2
- data/lib/candidhealth/service_lines/v_2/types/service_line_create_standalone.rb +10 -2
- data/lib/candidhealth/service_lines/v_2/types/service_line_update.rb +10 -2
- data/lib/candidhealth/x_12/v_1/types/patient_discharge_status_code.rb +52 -0
- data/lib/candidhealth/x_12/v_1/types/point_of_origin_for_admission_or_visit_code.rb +23 -0
- data/lib/candidhealth/x_12/v_1/types/type_of_admission_or_visit_code.rb +18 -0
- data/lib/candidhealth/x_12/v_1/types/type_of_bill_composite.rb +98 -0
- data/lib/candidhealth/x_12/v_1/types/type_of_bill_frequency_code.rb +39 -0
- data/lib/candidhealth/x_12/v_1/types/type_of_care_code.rb +21 -0
- data/lib/candidhealth/x_12/v_1/types/type_of_facility_code.rb +19 -0
- data/lib/requests.rb +2 -2
- data/lib/types_export.rb +20 -1
- metadata +22 -3
- data/lib/candidhealth/claim_submission/v_1/types/claim_frequency_type_code.rb +0 -15
@@ -1,9 +1,16 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
+
require_relative "../../../commons/types/state"
|
3
4
|
require_relative "../../../claims/types/claim"
|
4
5
|
require_relative "../../../individual/types/patient"
|
5
6
|
require_relative "../../../guarantor/v_1/types/guarantor"
|
6
7
|
require_relative "../../../encounter_providers/v_2/types/encounter_provider"
|
8
|
+
require_relative "../../../encounter_providers/v_2/types/rendering_provider"
|
9
|
+
require_relative "../../../x_12/v_1/types/type_of_admission_or_visit_code"
|
10
|
+
require_relative "../../../x_12/v_1/types/point_of_origin_for_admission_or_visit_code"
|
11
|
+
require_relative "../../../x_12/v_1/types/patient_discharge_status_code"
|
12
|
+
require_relative "encounter_submission_expectation"
|
13
|
+
require_relative "../../../x_12/v_1/types/type_of_bill_composite"
|
7
14
|
require_relative "../../../service_facility/types/encounter_service_facility"
|
8
15
|
require_relative "../../../individual/types/subscriber"
|
9
16
|
require_relative "responsible_party_type"
|
@@ -21,6 +28,7 @@ require_relative "encounter_submission_origin_type"
|
|
21
28
|
require_relative "../../../custom_schemas/v_1/types/schema_instance"
|
22
29
|
require_relative "epsdt_referral"
|
23
30
|
require_relative "claim_supplemental_information"
|
31
|
+
require_relative "../../../commons/types/next_responsible_party"
|
24
32
|
require_relative "medication"
|
25
33
|
require_relative "vitals"
|
26
34
|
require_relative "intervention"
|
@@ -37,6 +45,9 @@ module CandidApiClient
|
|
37
45
|
module V4
|
38
46
|
module Types
|
39
47
|
class Encounter
|
48
|
+
# @return [CandidApiClient::Commons::Types::State] 837i-REF1000 -- an optional state indicating where an accident related to the
|
49
|
+
# encounter occurred.
|
50
|
+
attr_reader :accident_state_or_province_code
|
40
51
|
# @return [String] If the encounter was created from ingested charge captures, this is the
|
41
52
|
# associated Charge Capture Claim Creation Id.
|
42
53
|
attr_reader :claim_creation_id
|
@@ -70,6 +81,41 @@ module CandidApiClient
|
|
70
81
|
# communication, or other service. The rendering provider address should generally
|
71
82
|
# be the same as the service facility address.
|
72
83
|
attr_reader :rendering_provider
|
84
|
+
# @return [CandidApiClient::EncounterProviders::V2::Types::RenderingProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
|
85
|
+
# has overall responsibility for the patient in institutional claims processing.
|
86
|
+
attr_reader :attending_provider
|
87
|
+
# @return [Integer] 837i Loop 2300 DTP-03
|
88
|
+
# Extension of the admission date with hour (0-23) details.
|
89
|
+
# Required for institutional submission.
|
90
|
+
attr_reader :admission_hour
|
91
|
+
# @return [CandidApiClient::X12::V1::Types::TypeOfAdmissionOrVisitCode] 837i Loop 2300 CL1-01
|
92
|
+
# Code used to indicate the priority of an admission or visit.
|
93
|
+
attr_reader :admission_type_code
|
94
|
+
# @return [CandidApiClient::X12::V1::Types::PointOfOriginForAdmissionOrVisitCode] 837i Loop 2300 CLI1-02
|
95
|
+
# Code used to indicate the conditions under which an admission occurs.
|
96
|
+
attr_reader :admission_source_code
|
97
|
+
# @return [Integer] 837i Loop 2300 DTP-03
|
98
|
+
# Extension of the discharge date with hour (0-23) details.
|
99
|
+
# Required for institutional submission.
|
100
|
+
attr_reader :discharge_hour
|
101
|
+
# @return [CandidApiClient::X12::V1::Types::PatientDischargeStatusCode] 837i CL1-03
|
102
|
+
# Code indicating patient status as of the "statement covers through date".
|
103
|
+
attr_reader :discharge_status
|
104
|
+
# @return [CandidApiClient::EncounterProviders::V2::Types::RenderingProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
|
105
|
+
# has primary responsibility for surgical procedures in institutional claims
|
106
|
+
# processing.
|
107
|
+
attr_reader :operating_provider
|
108
|
+
# @return [CandidApiClient::EncounterProviders::V2::Types::RenderingProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
|
109
|
+
# has secondary responsibility for surgical procedures in institutional claims
|
110
|
+
# processing. Only used when operating_provider is also set.
|
111
|
+
attr_reader :other_operating_provider
|
112
|
+
# @return [CandidApiClient::Encounters::V4::Types::EncounterSubmissionExpectation] Describes the currently expected target form for this encounter. This effects
|
113
|
+
# what validations and queues the form is processed under. When this value is not
|
114
|
+
# set, it should be assumed to be TARGET_PROFESSIONAL.
|
115
|
+
attr_reader :submission_expectation
|
116
|
+
# @return [CandidApiClient::X12::V1::Types::TypeOfBillComposite] Used by institutional forms to indicate how the bill is to be interpreted.
|
117
|
+
# Professional forms are not required to submit this attribute.
|
118
|
+
attr_reader :type_of_bill
|
73
119
|
# @return [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider]
|
74
120
|
attr_reader :referring_provider
|
75
121
|
# @return [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider]
|
@@ -164,6 +210,9 @@ module CandidApiClient
|
|
164
210
|
attr_reader :last_submitted_at
|
165
211
|
# @return [DateTime] The date and time the encounter was created.
|
166
212
|
attr_reader :created_at
|
213
|
+
# @return [CandidApiClient::Commons::Types::NextResponsibleParty] The party (payer, patient, etc.) responsible for the remainder of the balance on
|
214
|
+
# the claim.
|
215
|
+
attr_reader :next_responsible_party
|
167
216
|
# @return [String] A client-specified unique ID to associate with this encounter;
|
168
217
|
# for example, your internal encounter ID or a Dr. Chrono encounter ID.
|
169
218
|
# This field should not contain PHI.
|
@@ -264,6 +313,8 @@ module CandidApiClient
|
|
264
313
|
|
265
314
|
OMIT = Object.new
|
266
315
|
|
316
|
+
# @param accident_state_or_province_code [CandidApiClient::Commons::Types::State] 837i-REF1000 -- an optional state indicating where an accident related to the
|
317
|
+
# encounter occurred.
|
267
318
|
# @param claim_creation_id [String] If the encounter was created from ingested charge captures, this is the
|
268
319
|
# associated Charge Capture Claim Creation Id.
|
269
320
|
# @param patient_control_number [String] A patient control number (PCN) is a unique identifier assigned to a patient
|
@@ -289,6 +340,31 @@ module CandidApiClient
|
|
289
340
|
# For telehealth services, the rendering provider performs the visit, asynchronous
|
290
341
|
# communication, or other service. The rendering provider address should generally
|
291
342
|
# be the same as the service facility address.
|
343
|
+
# @param attending_provider [CandidApiClient::EncounterProviders::V2::Types::RenderingProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
|
344
|
+
# has overall responsibility for the patient in institutional claims processing.
|
345
|
+
# @param admission_hour [Integer] 837i Loop 2300 DTP-03
|
346
|
+
# Extension of the admission date with hour (0-23) details.
|
347
|
+
# Required for institutional submission.
|
348
|
+
# @param admission_type_code [CandidApiClient::X12::V1::Types::TypeOfAdmissionOrVisitCode] 837i Loop 2300 CL1-01
|
349
|
+
# Code used to indicate the priority of an admission or visit.
|
350
|
+
# @param admission_source_code [CandidApiClient::X12::V1::Types::PointOfOriginForAdmissionOrVisitCode] 837i Loop 2300 CLI1-02
|
351
|
+
# Code used to indicate the conditions under which an admission occurs.
|
352
|
+
# @param discharge_hour [Integer] 837i Loop 2300 DTP-03
|
353
|
+
# Extension of the discharge date with hour (0-23) details.
|
354
|
+
# Required for institutional submission.
|
355
|
+
# @param discharge_status [CandidApiClient::X12::V1::Types::PatientDischargeStatusCode] 837i CL1-03
|
356
|
+
# Code indicating patient status as of the "statement covers through date".
|
357
|
+
# @param operating_provider [CandidApiClient::EncounterProviders::V2::Types::RenderingProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
|
358
|
+
# has primary responsibility for surgical procedures in institutional claims
|
359
|
+
# processing.
|
360
|
+
# @param other_operating_provider [CandidApiClient::EncounterProviders::V2::Types::RenderingProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
|
361
|
+
# has secondary responsibility for surgical procedures in institutional claims
|
362
|
+
# processing. Only used when operating_provider is also set.
|
363
|
+
# @param submission_expectation [CandidApiClient::Encounters::V4::Types::EncounterSubmissionExpectation] Describes the currently expected target form for this encounter. This effects
|
364
|
+
# what validations and queues the form is processed under. When this value is not
|
365
|
+
# set, it should be assumed to be TARGET_PROFESSIONAL.
|
366
|
+
# @param type_of_bill [CandidApiClient::X12::V1::Types::TypeOfBillComposite] Used by institutional forms to indicate how the bill is to be interpreted.
|
367
|
+
# Professional forms are not required to submit this attribute.
|
292
368
|
# @param referring_provider [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider]
|
293
369
|
# @param initial_referring_provider [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider]
|
294
370
|
# @param supervising_provider [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider]
|
@@ -353,6 +429,8 @@ module CandidApiClient
|
|
353
429
|
# identify the primary payer. This is required for certain states.
|
354
430
|
# @param last_submitted_at [DateTime] The date and time the encounter was last submitted to a payer.
|
355
431
|
# @param created_at [DateTime] The date and time the encounter was created.
|
432
|
+
# @param next_responsible_party [CandidApiClient::Commons::Types::NextResponsibleParty] The party (payer, patient, etc.) responsible for the remainder of the balance on
|
433
|
+
# the claim.
|
356
434
|
# @param external_id [String] A client-specified unique ID to associate with this encounter;
|
357
435
|
# for example, your internal encounter ID or a Dr. Chrono encounter ID.
|
358
436
|
# This field should not contain PHI.
|
@@ -427,8 +505,11 @@ module CandidApiClient
|
|
427
505
|
# Code indicating the reason why a request was delayed
|
428
506
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
429
507
|
# @return [CandidApiClient::Encounters::V4::Types::Encounter]
|
430
|
-
def initialize(encounter_id:, claims:, patient:, billing_provider:, rendering_provider:, service_facility:,
|
431
|
-
guarantor: OMIT, referring_provider: OMIT, initial_referring_provider: OMIT, supervising_provider: OMIT, subscriber_primary: OMIT, subscriber_secondary: OMIT, subscriber_tertiary: OMIT, prior_authorization_number: OMIT, billing_notes: OMIT, place_of_service_code: OMIT, place_of_service_code_as_submitted: OMIT, coding_attribution: OMIT, work_queue_id: OMIT, work_queue_membership_activated_at: OMIT, referral_number: OMIT, epsdt_referral: OMIT, claim_supplemental_information: OMIT, secondary_payer_carrier_code: OMIT, last_submitted_at: OMIT, date_of_service: OMIT, end_date_of_service: OMIT, appointment_type: OMIT, existing_medications: OMIT, vitals: OMIT, interventions: OMIT, pay_to_address: OMIT, synchronicity: OMIT, additional_information: OMIT, service_authorization_exception_code: OMIT, admission_date: OMIT, discharge_date: OMIT, onset_of_current_illness_or_symptom_date: OMIT, last_menstrual_period_date: OMIT, delay_reason_code: OMIT, additional_properties: nil)
|
508
|
+
def initialize(encounter_id:, claims:, patient:, billing_provider:, rendering_provider:, service_facility:,
|
509
|
+
responsible_party:, url:, diagnoses:, clinical_notes:, patient_histories:, patient_payments:, tags:, owner_of_next_action:, submission_origin:, schema_instances:, created_at:, external_id:, patient_authorized_release:, benefits_assigned_to_provider:, provider_accepts_assignment:, billable_status:, accident_state_or_province_code: OMIT, claim_creation_id: OMIT, patient_control_number: OMIT, guarantor: OMIT, attending_provider: OMIT, admission_hour: OMIT, admission_type_code: OMIT, admission_source_code: OMIT, discharge_hour: OMIT, discharge_status: OMIT, operating_provider: OMIT, other_operating_provider: OMIT, submission_expectation: OMIT, type_of_bill: OMIT, referring_provider: OMIT, initial_referring_provider: OMIT, supervising_provider: OMIT, subscriber_primary: OMIT, subscriber_secondary: OMIT, subscriber_tertiary: OMIT, prior_authorization_number: OMIT, billing_notes: OMIT, place_of_service_code: OMIT, place_of_service_code_as_submitted: OMIT, coding_attribution: OMIT, work_queue_id: OMIT, work_queue_membership_activated_at: OMIT, referral_number: OMIT, epsdt_referral: OMIT, claim_supplemental_information: OMIT, secondary_payer_carrier_code: OMIT, last_submitted_at: OMIT, next_responsible_party: OMIT, date_of_service: OMIT, end_date_of_service: OMIT, appointment_type: OMIT, existing_medications: OMIT, vitals: OMIT, interventions: OMIT, pay_to_address: OMIT, synchronicity: OMIT, additional_information: OMIT, service_authorization_exception_code: OMIT, admission_date: OMIT, discharge_date: OMIT, onset_of_current_illness_or_symptom_date: OMIT, last_menstrual_period_date: OMIT, delay_reason_code: OMIT, additional_properties: nil)
|
510
|
+
if accident_state_or_province_code != OMIT
|
511
|
+
@accident_state_or_province_code = accident_state_or_province_code
|
512
|
+
end
|
432
513
|
@claim_creation_id = claim_creation_id if claim_creation_id != OMIT
|
433
514
|
@patient_control_number = patient_control_number if patient_control_number != OMIT
|
434
515
|
@encounter_id = encounter_id
|
@@ -437,6 +518,16 @@ module CandidApiClient
|
|
437
518
|
@guarantor = guarantor if guarantor != OMIT
|
438
519
|
@billing_provider = billing_provider
|
439
520
|
@rendering_provider = rendering_provider
|
521
|
+
@attending_provider = attending_provider if attending_provider != OMIT
|
522
|
+
@admission_hour = admission_hour if admission_hour != OMIT
|
523
|
+
@admission_type_code = admission_type_code if admission_type_code != OMIT
|
524
|
+
@admission_source_code = admission_source_code if admission_source_code != OMIT
|
525
|
+
@discharge_hour = discharge_hour if discharge_hour != OMIT
|
526
|
+
@discharge_status = discharge_status if discharge_status != OMIT
|
527
|
+
@operating_provider = operating_provider if operating_provider != OMIT
|
528
|
+
@other_operating_provider = other_operating_provider if other_operating_provider != OMIT
|
529
|
+
@submission_expectation = submission_expectation if submission_expectation != OMIT
|
530
|
+
@type_of_bill = type_of_bill if type_of_bill != OMIT
|
440
531
|
@referring_provider = referring_provider if referring_provider != OMIT
|
441
532
|
@initial_referring_provider = initial_referring_provider if initial_referring_provider != OMIT
|
442
533
|
@supervising_provider = supervising_provider if supervising_provider != OMIT
|
@@ -471,6 +562,7 @@ module CandidApiClient
|
|
471
562
|
@secondary_payer_carrier_code = secondary_payer_carrier_code if secondary_payer_carrier_code != OMIT
|
472
563
|
@last_submitted_at = last_submitted_at if last_submitted_at != OMIT
|
473
564
|
@created_at = created_at
|
565
|
+
@next_responsible_party = next_responsible_party if next_responsible_party != OMIT
|
474
566
|
@external_id = external_id
|
475
567
|
@date_of_service = date_of_service if date_of_service != OMIT
|
476
568
|
@end_date_of_service = end_date_of_service if end_date_of_service != OMIT
|
@@ -497,6 +589,7 @@ module CandidApiClient
|
|
497
589
|
@delay_reason_code = delay_reason_code if delay_reason_code != OMIT
|
498
590
|
@additional_properties = additional_properties
|
499
591
|
@_field_set = {
|
592
|
+
"accident_state_or_province_code": accident_state_or_province_code,
|
500
593
|
"claim_creation_id": claim_creation_id,
|
501
594
|
"patient_control_number": patient_control_number,
|
502
595
|
"encounter_id": encounter_id,
|
@@ -505,6 +598,16 @@ module CandidApiClient
|
|
505
598
|
"guarantor": guarantor,
|
506
599
|
"billing_provider": billing_provider,
|
507
600
|
"rendering_provider": rendering_provider,
|
601
|
+
"attending_provider": attending_provider,
|
602
|
+
"admission_hour": admission_hour,
|
603
|
+
"admission_type_code": admission_type_code,
|
604
|
+
"admission_source_code": admission_source_code,
|
605
|
+
"discharge_hour": discharge_hour,
|
606
|
+
"discharge_status": discharge_status,
|
607
|
+
"operating_provider": operating_provider,
|
608
|
+
"other_operating_provider": other_operating_provider,
|
609
|
+
"submission_expectation": submission_expectation,
|
610
|
+
"type_of_bill": type_of_bill,
|
508
611
|
"referring_provider": referring_provider,
|
509
612
|
"initial_referring_provider": initial_referring_provider,
|
510
613
|
"supervising_provider": supervising_provider,
|
@@ -535,6 +638,7 @@ module CandidApiClient
|
|
535
638
|
"secondary_payer_carrier_code": secondary_payer_carrier_code,
|
536
639
|
"last_submitted_at": last_submitted_at,
|
537
640
|
"created_at": created_at,
|
641
|
+
"next_responsible_party": next_responsible_party,
|
538
642
|
"external_id": external_id,
|
539
643
|
"date_of_service": date_of_service,
|
540
644
|
"end_date_of_service": end_date_of_service,
|
@@ -567,6 +671,7 @@ module CandidApiClient
|
|
567
671
|
def self.from_json(json_object:)
|
568
672
|
struct = JSON.parse(json_object, object_class: OpenStruct)
|
569
673
|
parsed_json = JSON.parse(json_object)
|
674
|
+
accident_state_or_province_code = struct["accident_state_or_province_code"]
|
570
675
|
claim_creation_id = struct["claim_creation_id"]
|
571
676
|
patient_control_number = struct["patient_control_number"]
|
572
677
|
encounter_id = struct["encounter_id"]
|
@@ -598,6 +703,36 @@ module CandidApiClient
|
|
598
703
|
rendering_provider = parsed_json["rendering_provider"].to_json
|
599
704
|
rendering_provider = CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.from_json(json_object: rendering_provider)
|
600
705
|
end
|
706
|
+
if parsed_json["attending_provider"].nil?
|
707
|
+
attending_provider = nil
|
708
|
+
else
|
709
|
+
attending_provider = parsed_json["attending_provider"].to_json
|
710
|
+
attending_provider = CandidApiClient::EncounterProviders::V2::Types::RenderingProvider.from_json(json_object: attending_provider)
|
711
|
+
end
|
712
|
+
admission_hour = struct["admission_hour"]
|
713
|
+
admission_type_code = struct["admission_type_code"]
|
714
|
+
admission_source_code = struct["admission_source_code"]
|
715
|
+
discharge_hour = struct["discharge_hour"]
|
716
|
+
discharge_status = struct["discharge_status"]
|
717
|
+
if parsed_json["operating_provider"].nil?
|
718
|
+
operating_provider = nil
|
719
|
+
else
|
720
|
+
operating_provider = parsed_json["operating_provider"].to_json
|
721
|
+
operating_provider = CandidApiClient::EncounterProviders::V2::Types::RenderingProvider.from_json(json_object: operating_provider)
|
722
|
+
end
|
723
|
+
if parsed_json["other_operating_provider"].nil?
|
724
|
+
other_operating_provider = nil
|
725
|
+
else
|
726
|
+
other_operating_provider = parsed_json["other_operating_provider"].to_json
|
727
|
+
other_operating_provider = CandidApiClient::EncounterProviders::V2::Types::RenderingProvider.from_json(json_object: other_operating_provider)
|
728
|
+
end
|
729
|
+
submission_expectation = struct["submission_expectation"]
|
730
|
+
if parsed_json["type_of_bill"].nil?
|
731
|
+
type_of_bill = nil
|
732
|
+
else
|
733
|
+
type_of_bill = parsed_json["type_of_bill"].to_json
|
734
|
+
type_of_bill = CandidApiClient::X12::V1::Types::TypeOfBillComposite.from_json(json_object: type_of_bill)
|
735
|
+
end
|
601
736
|
if parsed_json["referring_provider"].nil?
|
602
737
|
referring_provider = nil
|
603
738
|
else
|
@@ -696,6 +831,7 @@ module CandidApiClient
|
|
696
831
|
DateTime.parse(parsed_json["last_submitted_at"])
|
697
832
|
end
|
698
833
|
created_at = (DateTime.parse(parsed_json["created_at"]) unless parsed_json["created_at"].nil?)
|
834
|
+
next_responsible_party = struct["next_responsible_party"]
|
699
835
|
external_id = struct["external_id"]
|
700
836
|
date_of_service = (Date.parse(parsed_json["date_of_service"]) unless parsed_json["date_of_service"].nil?)
|
701
837
|
end_date_of_service = unless parsed_json["end_date_of_service"].nil?
|
@@ -739,6 +875,7 @@ module CandidApiClient
|
|
739
875
|
end
|
740
876
|
delay_reason_code = struct["delay_reason_code"]
|
741
877
|
new(
|
878
|
+
accident_state_or_province_code: accident_state_or_province_code,
|
742
879
|
claim_creation_id: claim_creation_id,
|
743
880
|
patient_control_number: patient_control_number,
|
744
881
|
encounter_id: encounter_id,
|
@@ -747,6 +884,16 @@ module CandidApiClient
|
|
747
884
|
guarantor: guarantor,
|
748
885
|
billing_provider: billing_provider,
|
749
886
|
rendering_provider: rendering_provider,
|
887
|
+
attending_provider: attending_provider,
|
888
|
+
admission_hour: admission_hour,
|
889
|
+
admission_type_code: admission_type_code,
|
890
|
+
admission_source_code: admission_source_code,
|
891
|
+
discharge_hour: discharge_hour,
|
892
|
+
discharge_status: discharge_status,
|
893
|
+
operating_provider: operating_provider,
|
894
|
+
other_operating_provider: other_operating_provider,
|
895
|
+
submission_expectation: submission_expectation,
|
896
|
+
type_of_bill: type_of_bill,
|
750
897
|
referring_provider: referring_provider,
|
751
898
|
initial_referring_provider: initial_referring_provider,
|
752
899
|
supervising_provider: supervising_provider,
|
@@ -777,6 +924,7 @@ module CandidApiClient
|
|
777
924
|
secondary_payer_carrier_code: secondary_payer_carrier_code,
|
778
925
|
last_submitted_at: last_submitted_at,
|
779
926
|
created_at: created_at,
|
927
|
+
next_responsible_party: next_responsible_party,
|
780
928
|
external_id: external_id,
|
781
929
|
date_of_service: date_of_service,
|
782
930
|
end_date_of_service: end_date_of_service,
|
@@ -815,6 +963,7 @@ module CandidApiClient
|
|
815
963
|
# @param obj [Object]
|
816
964
|
# @return [Void]
|
817
965
|
def self.validate_raw(obj:)
|
966
|
+
obj.accident_state_or_province_code&.is_a?(CandidApiClient::Commons::Types::State) != false || raise("Passed value for field obj.accident_state_or_province_code is not the expected type, validation failed.")
|
818
967
|
obj.claim_creation_id&.is_a?(String) != false || raise("Passed value for field obj.claim_creation_id is not the expected type, validation failed.")
|
819
968
|
obj.patient_control_number&.is_a?(String) != false || raise("Passed value for field obj.patient_control_number is not the expected type, validation failed.")
|
820
969
|
obj.encounter_id.is_a?(String) != false || raise("Passed value for field obj.encounter_id is not the expected type, validation failed.")
|
@@ -823,6 +972,16 @@ module CandidApiClient
|
|
823
972
|
obj.guarantor.nil? || CandidApiClient::Guarantor::V1::Types::Guarantor.validate_raw(obj: obj.guarantor)
|
824
973
|
CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.validate_raw(obj: obj.billing_provider)
|
825
974
|
CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.validate_raw(obj: obj.rendering_provider)
|
975
|
+
obj.attending_provider.nil? || CandidApiClient::EncounterProviders::V2::Types::RenderingProvider.validate_raw(obj: obj.attending_provider)
|
976
|
+
obj.admission_hour&.is_a?(Integer) != false || raise("Passed value for field obj.admission_hour is not the expected type, validation failed.")
|
977
|
+
obj.admission_type_code&.is_a?(CandidApiClient::X12::V1::Types::TypeOfAdmissionOrVisitCode) != false || raise("Passed value for field obj.admission_type_code is not the expected type, validation failed.")
|
978
|
+
obj.admission_source_code&.is_a?(CandidApiClient::X12::V1::Types::PointOfOriginForAdmissionOrVisitCode) != false || raise("Passed value for field obj.admission_source_code is not the expected type, validation failed.")
|
979
|
+
obj.discharge_hour&.is_a?(Integer) != false || raise("Passed value for field obj.discharge_hour is not the expected type, validation failed.")
|
980
|
+
obj.discharge_status&.is_a?(CandidApiClient::X12::V1::Types::PatientDischargeStatusCode) != false || raise("Passed value for field obj.discharge_status is not the expected type, validation failed.")
|
981
|
+
obj.operating_provider.nil? || CandidApiClient::EncounterProviders::V2::Types::RenderingProvider.validate_raw(obj: obj.operating_provider)
|
982
|
+
obj.other_operating_provider.nil? || CandidApiClient::EncounterProviders::V2::Types::RenderingProvider.validate_raw(obj: obj.other_operating_provider)
|
983
|
+
obj.submission_expectation&.is_a?(CandidApiClient::Encounters::V4::Types::EncounterSubmissionExpectation) != false || raise("Passed value for field obj.submission_expectation is not the expected type, validation failed.")
|
984
|
+
obj.type_of_bill.nil? || CandidApiClient::X12::V1::Types::TypeOfBillComposite.validate_raw(obj: obj.type_of_bill)
|
826
985
|
obj.referring_provider.nil? || CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.validate_raw(obj: obj.referring_provider)
|
827
986
|
obj.initial_referring_provider.nil? || CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.validate_raw(obj: obj.initial_referring_provider)
|
828
987
|
obj.supervising_provider.nil? || CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.validate_raw(obj: obj.supervising_provider)
|
@@ -853,6 +1012,7 @@ module CandidApiClient
|
|
853
1012
|
obj.secondary_payer_carrier_code&.is_a?(String) != false || raise("Passed value for field obj.secondary_payer_carrier_code is not the expected type, validation failed.")
|
854
1013
|
obj.last_submitted_at&.is_a?(DateTime) != false || raise("Passed value for field obj.last_submitted_at is not the expected type, validation failed.")
|
855
1014
|
obj.created_at.is_a?(DateTime) != false || raise("Passed value for field obj.created_at is not the expected type, validation failed.")
|
1015
|
+
obj.next_responsible_party&.is_a?(CandidApiClient::Commons::Types::NextResponsibleParty) != false || raise("Passed value for field obj.next_responsible_party is not the expected type, validation failed.")
|
856
1016
|
obj.external_id.is_a?(String) != false || raise("Passed value for field obj.external_id is not the expected type, validation failed.")
|
857
1017
|
obj.date_of_service&.is_a?(Date) != false || raise("Passed value for field obj.date_of_service is not the expected type, validation failed.")
|
858
1018
|
obj.end_date_of_service&.is_a?(Date) != false || raise("Passed value for field obj.end_date_of_service is not the expected type, validation failed.")
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module CandidApiClient
|
4
|
+
module Encounters
|
5
|
+
module V4
|
6
|
+
module Types
|
7
|
+
# Used to describe the currently expected target form for this encounter. This
|
8
|
+
# effects what
|
9
|
+
# validations and queues the form is processed under. If you're not sure, you can
|
10
|
+
# set this value
|
11
|
+
# to UNEXPECTED, in which case the form will be treated loosely during processing.
|
12
|
+
# Before
|
13
|
+
# submission, this value will be required by some rules or user intervention. It
|
14
|
+
# can be changed
|
15
|
+
# at any time, although doing so may incur other rules.
|
16
|
+
class EncounterSubmissionExpectation
|
17
|
+
TARGET_PROFESSIONAL = "TARGET_PROFESSIONAL"
|
18
|
+
TARGET_INSTITUTIONAL = "TARGET_INSTITUTIONAL"
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -18,7 +18,14 @@ module CandidApiClient
|
|
18
18
|
@request_client = request_client
|
19
19
|
end
|
20
20
|
|
21
|
-
#
|
21
|
+
# <Warning>
|
22
|
+
# API-based exports are in the process of being deprecated in favor of Candid Data
|
23
|
+
# Share and are not being offered to new customers.
|
24
|
+
# Please see the [Candid Data Share
|
25
|
+
# docs](https://docs.joincandidhealth.com/introduction/candid-data-share) for more
|
26
|
+
# information.
|
27
|
+
# </Warning>
|
28
|
+
# Retrieve CSV-formatted reports on claim submissions and outcomes. This endpoint
|
22
29
|
# returns Export objects that contain an
|
23
30
|
# authenticated URL to a customer's reports with a 2min TTL. The schema for the
|
24
31
|
# CSV export can be found
|
@@ -40,10 +47,6 @@ module CandidApiClient
|
|
40
47
|
# up to 90 days in the past by default. Please email our [Support
|
41
48
|
# team](mailto:support@joincandidhealth.com) with any data requests
|
42
49
|
# outside of these stated guarantees.
|
43
|
-
# **New Customers:** This endpoint is not enabled by default for new Candid
|
44
|
-
# customers. To have this endpoint enabled for your organization,
|
45
|
-
# please email our [Support team](mailto:support@joincandidhealth.com) with the
|
46
|
-
# request.
|
47
50
|
#
|
48
51
|
# @param start_date [Date] Beginning date of claim versions returned in the export, ISO 8601 date e.g.
|
49
52
|
# 2019-08-24.
|
@@ -87,7 +90,14 @@ module CandidApiClient
|
|
87
90
|
@request_client = request_client
|
88
91
|
end
|
89
92
|
|
90
|
-
#
|
93
|
+
# <Warning>
|
94
|
+
# API-based exports are in the process of being deprecated in favor of Candid Data
|
95
|
+
# Share and are not being offered to new customers.
|
96
|
+
# Please see the [Candid Data Share
|
97
|
+
# docs](https://docs.joincandidhealth.com/introduction/candid-data-share) for more
|
98
|
+
# information.
|
99
|
+
# </Warning>
|
100
|
+
# Retrieve CSV-formatted reports on claim submissions and outcomes. This endpoint
|
91
101
|
# returns Export objects that contain an
|
92
102
|
# authenticated URL to a customer's reports with a 2min TTL. The schema for the
|
93
103
|
# CSV export can be found
|
@@ -109,10 +119,6 @@ module CandidApiClient
|
|
109
119
|
# up to 90 days in the past by default. Please email our [Support
|
110
120
|
# team](mailto:support@joincandidhealth.com) with any data requests
|
111
121
|
# outside of these stated guarantees.
|
112
|
-
# **New Customers:** This endpoint is not enabled by default for new Candid
|
113
|
-
# customers. To have this endpoint enabled for your organization,
|
114
|
-
# please email our [Support team](mailto:support@joincandidhealth.com) with the
|
115
|
-
# request.
|
116
122
|
#
|
117
123
|
# @param start_date [Date] Beginning date of claim versions returned in the export, ISO 8601 date e.g.
|
118
124
|
# 2019-08-24.
|