candidhealth 1.6.0 → 1.8.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.
Files changed (151) hide show
  1. checksums.yaml +4 -4
  2. data/lib/candidhealth/auth/default/client.rb +74 -0
  3. data/lib/candidhealth/charge_capture/v_1/client.rb +48 -48
  4. data/lib/candidhealth/charge_capture/v_1/types/charge_capture_data.rb +70 -56
  5. data/lib/candidhealth/commons/types/clearinghouse.rb +18 -0
  6. data/lib/candidhealth/commons/types/procedure_modifier.rb +11 -0
  7. data/lib/candidhealth/credentialing/v_2/client.rb +342 -8
  8. data/lib/candidhealth/credentialing/v_2/types/base_credentialing_span.rb +143 -0
  9. data/lib/candidhealth/credentialing/v_2/types/facility_credentialing_span.rb +165 -0
  10. data/lib/candidhealth/credentialing/v_2/types/facility_credentialing_span_page.rb +88 -0
  11. data/lib/candidhealth/credentialing/v_2/types/provider_credentialing_span.rb +34 -34
  12. data/lib/candidhealth/encounter_providers/v_2/types/billing_provider.rb +1 -1
  13. data/lib/candidhealth/encounter_providers/v_2/types/billing_provider_update.rb +1 -1
  14. data/lib/candidhealth/encounter_providers/v_2/types/billing_provider_update_with_optional_address.rb +1 -1
  15. data/lib/candidhealth/encounters/v_4/client.rb +3253 -2040
  16. data/lib/candidhealth/encounters/v_4/types/encounter.rb +111 -86
  17. data/lib/candidhealth/encounters/v_4/types/encounter_base.rb +39 -33
  18. data/lib/candidhealth/encounters/v_4/types/encounter_create.rb +796 -0
  19. data/lib/candidhealth/encounters/v_4/types/encounter_create_from_pre_encounter.rb +131 -117
  20. data/lib/candidhealth/encounters/v_4/types/encounter_deep_optional.rb +70 -56
  21. data/lib/candidhealth/encounters/v_4/types/encounter_optional.rb +29 -39
  22. data/lib/candidhealth/encounters/v_4/types/encounter_rendering_or_attending_provider_required_error.rb +55 -0
  23. data/lib/candidhealth/encounters/v_4/types/encounter_update.rb +736 -0
  24. data/lib/candidhealth/encounters_universal/types/universal_encounter_create.rb +944 -0
  25. data/lib/candidhealth/encounters_universal/types/universal_encounter_create_base.rb +691 -0
  26. data/lib/candidhealth/encounters_universal/types/universal_encounter_create_from_pre_encounter.rb +791 -0
  27. data/lib/candidhealth/encounters_universal/types/universal_encounter_create_from_pre_encounter_base.rb +572 -0
  28. data/lib/candidhealth/encounters_universal/types/universal_encounter_update.rb +872 -0
  29. data/lib/candidhealth/encounters_universal/types/universal_encounter_update_base.rb +700 -0
  30. data/lib/candidhealth/fee_schedules/v_3/client.rb +57 -0
  31. data/lib/candidhealth/fee_schedules/v_3/types/validation_error.rb +12 -0
  32. data/lib/candidhealth/financials/types/patient_transaction_source.rb +1 -0
  33. data/lib/candidhealth/health_care_code_information/client.rb +30 -0
  34. data/lib/candidhealth/health_care_code_information/v_1/client.rb +268 -0
  35. data/lib/candidhealth/health_care_code_information/v_1/types/admitting_diagnosis.rb +236 -0
  36. data/lib/candidhealth/health_care_code_information/v_1/types/admitting_diagnosis_code_qualifier.rb +14 -0
  37. data/lib/candidhealth/health_care_code_information/v_1/types/admitting_diagnosis_new.rb +206 -0
  38. data/lib/candidhealth/health_care_code_information/v_1/types/code_list_qualifier_code.rb +1068 -0
  39. data/lib/candidhealth/health_care_code_information/v_1/types/condition_code.rb +71 -0
  40. data/lib/candidhealth/health_care_code_information/v_1/types/condition_information.rb +237 -0
  41. data/lib/candidhealth/health_care_code_information/v_1/types/condition_information_code_qualifier.rb +13 -0
  42. data/lib/candidhealth/health_care_code_information/v_1/types/condition_information_new.rb +207 -0
  43. data/lib/candidhealth/health_care_code_information/v_1/types/date_time_period_format_qualifier.rb +54 -0
  44. data/lib/candidhealth/health_care_code_information/v_1/types/diagnosis_related_group.rb +236 -0
  45. data/lib/candidhealth/health_care_code_information/v_1/types/diagnosis_related_group_code_qualifier.rb +13 -0
  46. data/lib/candidhealth/health_care_code_information/v_1/types/diagnosis_related_group_new.rb +206 -0
  47. data/lib/candidhealth/health_care_code_information/v_1/types/external_cause_of_injury.rb +245 -0
  48. data/lib/candidhealth/health_care_code_information/v_1/types/external_cause_of_injury_code_qualifier.rb +14 -0
  49. data/lib/candidhealth/health_care_code_information/v_1/types/external_cause_of_injury_new.rb +245 -0
  50. data/lib/candidhealth/health_care_code_information/v_1/types/health_care_code_information.rb +218 -0
  51. data/lib/candidhealth/health_care_code_information/v_1/types/health_care_code_information_create.rb +225 -0
  52. data/lib/candidhealth/health_care_code_information/v_1/types/health_care_code_information_get_all_response.rb +227 -0
  53. data/lib/candidhealth/health_care_code_information/v_1/types/health_care_code_information_new.rb +188 -0
  54. data/lib/candidhealth/health_care_code_information/v_1/types/health_care_code_information_update.rb +225 -0
  55. data/lib/candidhealth/health_care_code_information/v_1/types/occurrence_code.rb +71 -0
  56. data/lib/candidhealth/health_care_code_information/v_1/types/occurrence_information.rb +249 -0
  57. data/lib/candidhealth/health_care_code_information/v_1/types/occurrence_information_code_qualifier.rb +13 -0
  58. data/lib/candidhealth/health_care_code_information/v_1/types/occurrence_information_new.rb +219 -0
  59. data/lib/candidhealth/health_care_code_information/v_1/types/occurrence_span_code.rb +25 -0
  60. data/lib/candidhealth/health_care_code_information/v_1/types/occurrence_span_code_qualifier.rb +13 -0
  61. data/lib/candidhealth/health_care_code_information/v_1/types/occurrence_span_information.rb +252 -0
  62. data/lib/candidhealth/health_care_code_information/v_1/types/occurrence_span_information_new.rb +222 -0
  63. data/lib/candidhealth/health_care_code_information/v_1/types/other_diagnosis_information.rb +245 -0
  64. data/lib/candidhealth/health_care_code_information/v_1/types/other_diagnosis_information_code_qualifier.rb +14 -0
  65. data/lib/candidhealth/health_care_code_information/v_1/types/other_diagnosis_information_new.rb +215 -0
  66. data/lib/candidhealth/health_care_code_information/v_1/types/other_procedure_information.rb +248 -0
  67. data/lib/candidhealth/health_care_code_information/v_1/types/other_procedure_information_code_qualifier.rb +14 -0
  68. data/lib/candidhealth/health_care_code_information/v_1/types/other_procedure_information_new.rb +218 -0
  69. data/lib/candidhealth/health_care_code_information/v_1/types/patient_reason_for_visit.rb +236 -0
  70. data/lib/candidhealth/health_care_code_information/v_1/types/patient_reason_for_visit_code_qualifier.rb +14 -0
  71. data/lib/candidhealth/health_care_code_information/v_1/types/patient_reason_for_visit_new.rb +206 -0
  72. data/lib/candidhealth/health_care_code_information/v_1/types/present_on_admission_indicator_code.rb +17 -0
  73. data/lib/candidhealth/health_care_code_information/v_1/types/principal_diagnosis.rb +245 -0
  74. data/lib/candidhealth/health_care_code_information/v_1/types/principal_diagnosis_code_qualifier.rb +14 -0
  75. data/lib/candidhealth/health_care_code_information/v_1/types/principal_diagnosis_new.rb +215 -0
  76. data/lib/candidhealth/health_care_code_information/v_1/types/principal_procedure_information.rb +246 -0
  77. data/lib/candidhealth/health_care_code_information/v_1/types/principal_procedure_information_code_qualifier.rb +15 -0
  78. data/lib/candidhealth/health_care_code_information/v_1/types/principal_procedure_information_new.rb +216 -0
  79. data/lib/candidhealth/health_care_code_information/v_1/types/rd_8_date.rb +72 -0
  80. data/lib/candidhealth/health_care_code_information/v_1/types/set_or_clear_admitting_diagnosis.rb +69 -0
  81. data/lib/candidhealth/health_care_code_information/v_1/types/set_or_clear_diagnosis_related_group.rb +69 -0
  82. data/lib/candidhealth/health_care_code_information/v_1/types/set_or_clear_principal_diagnosis.rb +69 -0
  83. data/lib/candidhealth/health_care_code_information/v_1/types/set_or_clear_principal_procedure_information.rb +71 -0
  84. data/lib/candidhealth/health_care_code_information/v_1/types/treatment_code_information.rb +236 -0
  85. data/lib/candidhealth/health_care_code_information/v_1/types/treatment_code_information_new.rb +206 -0
  86. data/lib/candidhealth/health_care_code_information/v_1/types/treatment_code_qualifier.rb +13 -0
  87. data/lib/candidhealth/health_care_code_information/v_1/types/value_code.rb +119 -0
  88. data/lib/candidhealth/health_care_code_information/v_1/types/value_code_qualifier.rb +13 -0
  89. data/lib/candidhealth/health_care_code_information/v_1/types/value_information.rb +245 -0
  90. data/lib/candidhealth/health_care_code_information/v_1/types/value_information_new.rb +215 -0
  91. data/lib/candidhealth/individual/types/patient.rb +6 -6
  92. data/lib/candidhealth/individual/types/patient_base.rb +6 -6
  93. data/lib/candidhealth/individual/types/patient_create.rb +6 -6
  94. data/lib/candidhealth/individual/types/patient_update.rb +6 -6
  95. data/lib/candidhealth/individual/types/patient_update_with_optional_address.rb +6 -6
  96. data/lib/candidhealth/organization_providers/v_2/types/license_type.rb +2 -0
  97. data/lib/candidhealth/patient_ar/client.rb +30 -0
  98. data/lib/candidhealth/patient_ar/v_1/client.rb +161 -0
  99. data/lib/candidhealth/patient_ar/v_1/types/insurance_adjustment_info.rb +60 -0
  100. data/lib/candidhealth/patient_ar/v_1/types/insurance_payment_info.rb +60 -0
  101. data/lib/candidhealth/patient_ar/v_1/types/invalid_filters_error_type.rb +60 -0
  102. data/lib/candidhealth/patient_ar/v_1/types/inventory_record.rb +101 -0
  103. data/lib/candidhealth/patient_ar/v_1/types/invoice_itemization_response.rb +103 -0
  104. data/lib/candidhealth/patient_ar/v_1/types/list_inventory_paged_response.rb +77 -0
  105. data/lib/candidhealth/patient_ar/v_1/types/non_insurance_adjustment_info.rb +60 -0
  106. data/lib/candidhealth/patient_ar/v_1/types/non_insurance_payment_info.rb +60 -0
  107. data/lib/candidhealth/patient_ar/v_1/types/patient_adjustment_info.rb +60 -0
  108. data/lib/candidhealth/patient_ar/v_1/types/patient_ar_status.rb +14 -0
  109. data/lib/candidhealth/patient_ar/v_1/types/patient_payment_allocation.rb +76 -0
  110. data/lib/candidhealth/patient_ar/v_1/types/patient_payment_info.rb +75 -0
  111. data/lib/candidhealth/patient_ar/v_1/types/service_line_itemization.rb +210 -0
  112. data/lib/candidhealth/payers/client.rb +7 -0
  113. data/lib/candidhealth/payers/v_4/client.rb +137 -0
  114. data/lib/candidhealth/payers/v_4/types/clearinghouse_payer_info.rb +93 -0
  115. data/lib/candidhealth/payers/v_4/types/payer.rb +116 -0
  116. data/lib/candidhealth/payers/v_4/types/payer_ids.rb +107 -0
  117. data/lib/candidhealth/payers/v_4/types/payer_page.rb +88 -0
  118. data/lib/candidhealth/payers/v_4/types/support_state.rb +15 -0
  119. data/lib/candidhealth/pre_encounter/coverages/v_1/client.rb +4 -4
  120. data/lib/candidhealth/pre_encounter/coverages/v_1/types/subscriber.rb +3 -3
  121. data/lib/candidhealth/pre_encounter/patients/v_1/client.rb +204 -6
  122. data/lib/candidhealth/pre_encounter/patients/v_1/types/guarantor.rb +3 -3
  123. data/lib/candidhealth/pre_encounter/patients/v_1/types/inferred_patient_metadata.rb +80 -0
  124. data/lib/candidhealth/pre_encounter/patients/v_1/types/mutable_patient.rb +33 -5
  125. data/lib/candidhealth/pre_encounter/patients/v_1/types/mutable_patient_with_mrn.rb +33 -5
  126. data/lib/candidhealth/pre_encounter/patients/v_1/types/origination_detail.rb +104 -0
  127. data/lib/candidhealth/pre_encounter/patients/v_1/types/patient.rb +32 -4
  128. data/lib/candidhealth/pre_encounter/patients/v_1/types/referral_source.rb +18 -0
  129. data/lib/candidhealth/pre_encounter/patients/v_1/types/referral_type.rb +17 -0
  130. data/lib/candidhealth/pre_encounter/patients/v_1/types/specialization_category.rb +42 -0
  131. data/lib/candidhealth/service_lines/v_2/client.rb +252 -10
  132. data/lib/candidhealth/service_lines/v_2/types/service_line.rb +28 -10
  133. data/lib/candidhealth/service_lines/v_2/types/service_line_create.rb +52 -40
  134. data/lib/candidhealth/service_lines/v_2/types/service_line_create_base.rb +251 -0
  135. data/lib/candidhealth/service_lines/v_2/types/service_line_create_base_base.rb +243 -0
  136. data/lib/candidhealth/service_lines/v_2/types/service_line_create_optional.rb +48 -24
  137. data/lib/candidhealth/service_lines/v_2/types/service_line_create_standalone.rb +58 -46
  138. data/lib/candidhealth/service_lines/v_2/types/service_line_create_standalone_base.rb +273 -0
  139. data/lib/candidhealth/service_lines/v_2/types/service_line_create_standalone_base_base.rb +265 -0
  140. data/lib/candidhealth/service_lines/v_2/types/service_line_update.rb +64 -54
  141. data/lib/candidhealth/service_lines/v_2/types/service_line_update_base.rb +263 -0
  142. data/lib/candidhealth/service_lines/v_2/types/universal_service_line_create.rb +271 -0
  143. data/lib/candidhealth/service_lines/v_2/types/universal_service_line_create_standalone.rb +317 -0
  144. data/lib/candidhealth/service_lines/v_2/types/universal_service_line_update.rb +307 -0
  145. data/lib/candidhealth/x_12/v_1/types/type_of_bill_composite.rb +2 -2
  146. data/lib/candidhealth/x_12/v_1/types/type_of_bill_composite_base.rb +90 -0
  147. data/lib/candidhealth/x_12/v_1/types/type_of_bill_composite_update.rb +112 -0
  148. data/lib/candidhealth.rb +21 -7
  149. data/lib/requests.rb +2 -2
  150. data/lib/types_export.rb +116 -13
  151. metadata +109 -2
@@ -5,7 +5,6 @@ require_relative "../../../claims/types/claim"
5
5
  require_relative "../../../individual/types/patient"
6
6
  require_relative "../../../guarantor/v_1/types/guarantor"
7
7
  require_relative "../../../encounter_providers/v_2/types/encounter_provider"
8
- require_relative "../../../encounter_providers/v_2/types/rendering_provider"
9
8
  require_relative "../../../x_12/v_1/types/type_of_admission_or_visit_code"
10
9
  require_relative "../../../x_12/v_1/types/point_of_origin_for_admission_or_visit_code"
11
10
  require_relative "../../../x_12/v_1/types/patient_discharge_status_code"
@@ -30,10 +29,10 @@ require_relative "epsdt_referral"
30
29
  require_relative "claim_supplemental_information"
31
30
  require_relative "../../../commons/types/next_responsible_party"
32
31
  require_relative "medication"
33
- require_relative "vitals"
34
32
  require_relative "intervention"
35
33
  require_relative "../../../commons/types/street_address_long_zip"
36
34
  require_relative "synchronicity_type"
35
+ require_relative "vitals"
37
36
  require_relative "billable_status_type"
38
37
  require_relative "service_authorization_exception_code"
39
38
  require_relative "../../../commons/types/delay_reason_code"
@@ -73,7 +72,8 @@ module CandidApiClient
73
72
  # circumstances, this will be an individual provider. In that case, submit that
74
73
  # provider's NPI and the tax ID (TIN) that the provider gave to the payer during
75
74
  # contracting. In other cases, the billing entity will be a medical group. If so,
76
- # submit the group NPI and the group's tax ID. Box 33 on the CMS-1500 claim form.
75
+ # submit the group NPI and the group's tax ID. Box 33 on the CMS-1500 claim form
76
+ # or Form Locator 1 on a UB-04 claim form.
77
77
  attr_reader :billing_provider
78
78
  # @return [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider] The rendering provider is the practitioner -- physician, nurse practitioner,
79
79
  # etc. -- performing the service.
@@ -81,31 +81,33 @@ module CandidApiClient
81
81
  # communication, or other service. The rendering provider address should generally
82
82
  # be the same as the service facility address.
83
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
84
+ # @return [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
85
85
  # has overall responsibility for the patient in institutional claims processing.
86
86
  attr_reader :attending_provider
87
87
  # @return [Integer] 837i Loop 2300 DTP-03
88
88
  # Extension of the admission date with hour (0-23) details.
89
89
  # Required for institutional submission.
90
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.
91
+ # @return [CandidApiClient::X12::V1::Types::TypeOfAdmissionOrVisitCode] 837i Loop 2300 CL1-01 Code used to indicate the priority of an admission or
92
+ # visit. Equivalent to Form Locator 14 Priority of Admission on a UB-04 claim, not
93
+ # used on CMS-1500 claim forms.
93
94
  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.
95
+ # @return [CandidApiClient::X12::V1::Types::PointOfOriginForAdmissionOrVisitCode] 837i Loop 2300 CLI1-02 Code used to indicate the conditions under which an
96
+ # admission occurs. Equivalent to Form Locator 15 Point of Origin on a UB-04
97
+ # claim, not used on CMS-1500 claim forms.
96
98
  attr_reader :admission_source_code
97
99
  # @return [Integer] 837i Loop 2300 DTP-03
98
100
  # Extension of the discharge date with hour (0-23) details.
99
- # Required for institutional submission.
100
101
  attr_reader :discharge_hour
101
- # @return [CandidApiClient::X12::V1::Types::PatientDischargeStatusCode] 837i CL1-03
102
+ # @return [CandidApiClient::X12::V1::Types::PatientDischargeStatusCode] 837i CL1-03 or Form Locator 17 on a UB-04 claim form. This is a required field
103
+ # on UB-04 claims.
102
104
  # Code indicating patient status as of the "statement covers through date".
103
105
  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
106
+ # @return [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
105
107
  # has primary responsibility for surgical procedures in institutional claims
106
108
  # processing.
107
109
  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
110
+ # @return [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
109
111
  # has secondary responsibility for surgical procedures in institutional claims
110
112
  # processing. Only used when operating_provider is also set.
111
113
  attr_reader :other_operating_provider
@@ -113,8 +115,11 @@ module CandidApiClient
113
115
  # what validations and queues the form is processed under. When this value is not
114
116
  # set, it should be assumed to be TARGET_PROFESSIONAL.
115
117
  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
+ # @return [CandidApiClient::X12::V1::Types::TypeOfBillComposite] Four digit code used in institutional forms to indicate the type of bill (e.g.,
119
+ # hospital inpatient, hospital outpatient). First digit is a leading 0, followed
120
+ # by the type_of_facility, type_of_care, then frequency_code. Professional forms
121
+ # are not required to submit this attribute. You may send the 4 digit code via
122
+ # raw_code, or each individual digit separately via composite_codes.
118
123
  attr_reader :type_of_bill
119
124
  # @return [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider]
120
125
  attr_reader :referring_provider
@@ -127,10 +132,12 @@ module CandidApiClient
127
132
  # facility can represent the provider's location when the service was delivered
128
133
  # (e.g., home), or the location where an in-person visit would have taken place,
129
134
  # whichever is easier to identify. If the provider is in-network, service facility
130
- # may be defined in payer contracts. Box 32 on the CMS-1500 claim form. Note that
135
+ # may be defined in payer contracts. Box 32 on the CMS-1500 claim form. There is
136
+ # no equivalent on the paper UB-04 claim form, but this field is equivalent to
137
+ # Loop 2310E Service Facility Location details on an 837i form, and is used when
138
+ # this is different to the entity identified as the Billing Provider. Note that
131
139
  # for an in-network claim to be successfully adjudicated, the service facility
132
- # address listed on claims must match what was provided to the payer during the
133
- # credentialing process.
140
+ # address listed
134
141
  attr_reader :service_facility
135
142
  # @return [CandidApiClient::Individual::Types::Subscriber] Subscriber_primary is required when responsible_party is INSURANCE_PAY (i.e.
136
143
  # when the claim should be billed to insurance).
@@ -145,15 +152,17 @@ module CandidApiClient
145
152
  attr_reader :subscriber_secondary
146
153
  # @return [CandidApiClient::Individual::Types::Subscriber] Contains details of the tertiary insurance subscriber.
147
154
  attr_reader :subscriber_tertiary
148
- # @return [String] Box 23 on the CMS-1500 claim form.
155
+ # @return [String] Box 23 on the CMS-1500 claim form or Form Locator 63 on a UB-04 claim form.
149
156
  attr_reader :prior_authorization_number
150
157
  # @return [CandidApiClient::Encounters::V4::Types::ResponsiblePartyType] Defines the party to be billed with the initial balance owed on the claim.
151
158
  attr_reader :responsible_party
152
159
  # @return [String] URL that links directly to the claim created in Candid.
153
160
  attr_reader :url
154
- # @return [Array<CandidApiClient::Diagnoses::Types::Diagnosis>] Ideally, this field should contain no more than 12 diagnoses. However, more
155
- # diagnoses may be submitted at this time, and coders will later prioritize the 12
156
- # that will be submitted to the payor.
161
+ # @return [Array<CandidApiClient::Diagnoses::Types::Diagnosis>] Contains the primary and other diagnosis health care code information objects
162
+ # associated with this encounter. For professional claims, these diagnoses
163
+ # correspond with those that are set on service lines directly, where as for
164
+ # institutional claims these are only associated directly with the claim itself.
165
+ # See also Health Care Code Information objects and corresponding apis.
157
166
  attr_reader :diagnoses
158
167
  # @return [Array<CandidApiClient::Encounters::V4::Types::ClinicalNoteCategory>] Holds a collection of clinical observations made by healthcare providers during
159
168
  # patient encounters. Please note that medical records for appeals should be sent
@@ -197,11 +206,11 @@ module CandidApiClient
197
206
  attr_reader :schema_instances
198
207
  # @return [String] Refers to REF*9F on the 837p. Value cannot be greater than 50 characters.
199
208
  attr_reader :referral_number
200
- # @return [CandidApiClient::Encounters::V4::Types::EpsdtReferral] Refers Box 24H on the CMS1500 form and Loop 2300 CRC - EPSDT Referral on the
201
- # 837P form
209
+ # @return [CandidApiClient::Encounters::V4::Types::EpsdtReferral] Refers to Box 24H on the CMS1500 form and Loop 2300 CRC - EPSDT Referral on the
210
+ # 837P and 837i form
202
211
  attr_reader :epsdt_referral
203
- # @return [Array<CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation>] Refers to Loop 2300 - Segment PWK on the 837P form. No more than 10 entries are
204
- # permitted.
212
+ # @return [Array<CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation>] Refers to Loop 2300 - Segment PWK on the 837P and 837i form. No more than 10
213
+ # entries are permitted.
205
214
  attr_reader :claim_supplemental_information
206
215
  # @return [String] When Medicaid is billed as the secondary payer the Carrier Code is used to
207
216
  # identify the primary payer. This is required for certain states.
@@ -219,7 +228,7 @@ module CandidApiClient
219
228
  attr_reader :external_id
220
229
  # @return [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-24.
221
230
  # This date must be the local date in the timezone where the service occurred.
222
- # Box 24a on the CMS-1500 claim form.
231
+ # Box 24a on the CMS-1500 claim form or Form Locator 45 on the UB-04 claim form.
223
232
  # If service occurred over a range of dates, this should be the start date.
224
233
  # date_of_service must be defined on either the encounter or the service lines but
225
234
  # not both.
@@ -237,23 +246,22 @@ module CandidApiClient
237
246
  attr_reader :end_date_of_service
238
247
  # @return [Boolean] Whether this patient has authorized the release of medical information
239
248
  # for billing purpose.
240
- # Box 12 on the CMS-1500 claim form.
249
+ # Box 12 on the CMS-1500 claim form or Form Locator 52 on a UB-04 claim form.
241
250
  attr_reader :patient_authorized_release
242
251
  # @return [Boolean] Whether this patient has authorized insurance payments to be made to you,
243
252
  # not them. If false, patient may receive reimbursement.
244
- # Box 13 on the CMS-1500 claim form.
253
+ # Box 13 on the CMS-1500 claim form or Form Locator 53 on a UB-04 claim form.
245
254
  attr_reader :benefits_assigned_to_provider
246
255
  # @return [Boolean] Whether you have accepted the patient's authorization for insurance payments
247
256
  # to be made to you, not them.
248
- # Box 27 on the CMS-1500 claim form.
257
+ # Box 27 on the CMS-1500 claim form. There is no exact equivalent of this field on
258
+ # a UB-04 claim, however contributes to the concept of Form Locator 53.
249
259
  attr_reader :provider_accepts_assignment
250
260
  # @return [String] Human-readable description of the appointment type (ex: "Acupuncture -
251
261
  # Headaches").
252
262
  attr_reader :appointment_type
253
263
  # @return [Array<CandidApiClient::Encounters::V4::Types::Medication>]
254
264
  attr_reader :existing_medications
255
- # @return [CandidApiClient::Encounters::V4::Types::Vitals]
256
- attr_reader :vitals
257
265
  # @return [Array<CandidApiClient::Encounters::V4::Types::Intervention>]
258
266
  attr_reader :interventions
259
267
  # @return [CandidApiClient::Commons::Types::StreetAddressLongZip] Specifies the address to which payments for the claim should be sent.
@@ -266,13 +274,15 @@ module CandidApiClient
266
274
  # interacts
267
275
  # directly with the provider, such as over video or a phone call.
268
276
  attr_reader :synchronicity
277
+ # @return [CandidApiClient::Encounters::V4::Types::Vitals]
278
+ attr_reader :vitals
269
279
  # @return [CandidApiClient::Encounters::V4::Types::BillableStatusType] Defines if the Encounter is to be billed by Candid to the responsible_party.
270
280
  # Examples for when this should be set to NOT_BILLABLE include
271
281
  # if the Encounter has not occurred yet or if there is no intention of ever
272
282
  # billing the responsible_party.
273
283
  attr_reader :billable_status
274
284
  # @return [String] Defines additional information on the claim needed by the payer.
275
- # Box 19 on the CMS-1500 claim form.
285
+ # Box 19 on the CMS-1500 claim form or Form Locator 80 on a UB-04 claim form.
276
286
  attr_reader :additional_information
277
287
  # @return [CandidApiClient::Encounters::V4::Types::ServiceAuthorizationExceptionCode] 837p Loop2300 REF*4N
278
288
  # Required when mandated by government law or regulation to obtain authorization
@@ -281,15 +291,15 @@ module CandidApiClient
281
291
  # the service was performed without
282
292
  # obtaining the authorization.
283
293
  attr_reader :service_authorization_exception_code
284
- # @return [Date] 837p Loop2300 DTP*435, CMS-1500 Box 18
294
+ # @return [Date] 837p Loop2300 DTP*435, CMS-1500 Box 18 or UB-04 Form Locator 12.
285
295
  # Required on all ambulance claims when the patient was known to be admitted to
286
296
  # the hospital.
287
297
  # OR
288
298
  # Required on all claims involving inpatient medical visits.
289
299
  attr_reader :admission_date
290
- # @return [Date] 837p Loop2300 DTP*096, CMS-1500 Box 18
291
- # Required for inpatient claims when the patient was discharged from the facility
292
- # and the discharge date is known.
300
+ # @return [Date] 837p Loop2300 DTP*096, CMS-1500 Box 18 Required for inpatient claims when the
301
+ # patient was discharged from the facility and the discharge date is known. Not
302
+ # used on an institutional claim.
293
303
  attr_reader :discharge_date
294
304
  # @return [Date] 837p Loop2300 DTP*431, CMS-1500 Box 14
295
305
  # Required for the initial medical service or visit performed in response to a
@@ -297,10 +307,12 @@ module CandidApiClient
297
307
  # service.
298
308
  # OR
299
309
  # This date is the onset of acute symptoms for the current illness or condition.
310
+ # For UB-04 claims, this is populated separately via occurrence codes.
300
311
  attr_reader :onset_of_current_illness_or_symptom_date
301
312
  # @return [Date] 837p Loop2300 DTP*484, CMS-1500 Box 14
302
313
  # Required when, in the judgment of the provider, the services on this claim are
303
314
  # related to the patient's pregnancy.
315
+ # This field is populated separately via occurrence codes for UB-04 claim forms.
304
316
  attr_reader :last_menstrual_period_date
305
317
  # @return [CandidApiClient::Commons::Types::DelayReasonCode] 837i Loop2300, CLM-1300 Box 20
306
318
  # Code indicating the reason why a request was delayed
@@ -334,37 +346,43 @@ module CandidApiClient
334
346
  # circumstances, this will be an individual provider. In that case, submit that
335
347
  # provider's NPI and the tax ID (TIN) that the provider gave to the payer during
336
348
  # contracting. In other cases, the billing entity will be a medical group. If so,
337
- # submit the group NPI and the group's tax ID. Box 33 on the CMS-1500 claim form.
349
+ # submit the group NPI and the group's tax ID. Box 33 on the CMS-1500 claim form
350
+ # or Form Locator 1 on a UB-04 claim form.
338
351
  # @param rendering_provider [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider] The rendering provider is the practitioner -- physician, nurse practitioner,
339
352
  # etc. -- performing the service.
340
353
  # For telehealth services, the rendering provider performs the visit, asynchronous
341
354
  # communication, or other service. The rendering provider address should generally
342
355
  # 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
356
+ # @param attending_provider [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
344
357
  # has overall responsibility for the patient in institutional claims processing.
345
358
  # @param admission_hour [Integer] 837i Loop 2300 DTP-03
346
359
  # Extension of the admission date with hour (0-23) details.
347
360
  # 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.
361
+ # @param admission_type_code [CandidApiClient::X12::V1::Types::TypeOfAdmissionOrVisitCode] 837i Loop 2300 CL1-01 Code used to indicate the priority of an admission or
362
+ # visit. Equivalent to Form Locator 14 Priority of Admission on a UB-04 claim, not
363
+ # used on CMS-1500 claim forms.
364
+ # @param admission_source_code [CandidApiClient::X12::V1::Types::PointOfOriginForAdmissionOrVisitCode] 837i Loop 2300 CLI1-02 Code used to indicate the conditions under which an
365
+ # admission occurs. Equivalent to Form Locator 15 Point of Origin on a UB-04
366
+ # claim, not used on CMS-1500 claim forms.
352
367
  # @param discharge_hour [Integer] 837i Loop 2300 DTP-03
353
368
  # 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
369
+ # @param discharge_status [CandidApiClient::X12::V1::Types::PatientDischargeStatusCode] 837i CL1-03 or Form Locator 17 on a UB-04 claim form. This is a required field
370
+ # on UB-04 claims.
356
371
  # 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
372
+ # @param operating_provider [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
358
373
  # has primary responsibility for surgical procedures in institutional claims
359
374
  # 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
375
+ # @param other_operating_provider [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider] 837i NM1 2500 variant for Loop ID-2310. Used to indicate the individual whom
361
376
  # has secondary responsibility for surgical procedures in institutional claims
362
377
  # processing. Only used when operating_provider is also set.
363
378
  # @param submission_expectation [CandidApiClient::Encounters::V4::Types::EncounterSubmissionExpectation] Describes the currently expected target form for this encounter. This effects
364
379
  # what validations and queues the form is processed under. When this value is not
365
380
  # 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.
381
+ # @param type_of_bill [CandidApiClient::X12::V1::Types::TypeOfBillComposite] Four digit code used in institutional forms to indicate the type of bill (e.g.,
382
+ # hospital inpatient, hospital outpatient). First digit is a leading 0, followed
383
+ # by the type_of_facility, type_of_care, then frequency_code. Professional forms
384
+ # are not required to submit this attribute. You may send the 4 digit code via
385
+ # raw_code, or each individual digit separately via composite_codes.
368
386
  # @param referring_provider [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider]
369
387
  # @param initial_referring_provider [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider]
370
388
  # @param supervising_provider [CandidApiClient::EncounterProviders::V2::Types::EncounterProvider]
@@ -373,10 +391,12 @@ module CandidApiClient
373
391
  # facility can represent the provider's location when the service was delivered
374
392
  # (e.g., home), or the location where an in-person visit would have taken place,
375
393
  # whichever is easier to identify. If the provider is in-network, service facility
376
- # may be defined in payer contracts. Box 32 on the CMS-1500 claim form. Note that
394
+ # may be defined in payer contracts. Box 32 on the CMS-1500 claim form. There is
395
+ # no equivalent on the paper UB-04 claim form, but this field is equivalent to
396
+ # Loop 2310E Service Facility Location details on an 837i form, and is used when
397
+ # this is different to the entity identified as the Billing Provider. Note that
377
398
  # for an in-network claim to be successfully adjudicated, the service facility
378
- # address listed on claims must match what was provided to the payer during the
379
- # credentialing process.
399
+ # address listed
380
400
  # @param subscriber_primary [CandidApiClient::Individual::Types::Subscriber] Subscriber_primary is required when responsible_party is INSURANCE_PAY (i.e.
381
401
  # when the claim should be billed to insurance).
382
402
  # These are not required fields when responsible_party is SELF_PAY (i.e. when the
@@ -387,12 +407,14 @@ module CandidApiClient
387
407
  # to define self-pay claims.
388
408
  # @param subscriber_secondary [CandidApiClient::Individual::Types::Subscriber] Contains details of the secondary insurance subscriber.
389
409
  # @param subscriber_tertiary [CandidApiClient::Individual::Types::Subscriber] Contains details of the tertiary insurance subscriber.
390
- # @param prior_authorization_number [String] Box 23 on the CMS-1500 claim form.
410
+ # @param prior_authorization_number [String] Box 23 on the CMS-1500 claim form or Form Locator 63 on a UB-04 claim form.
391
411
  # @param responsible_party [CandidApiClient::Encounters::V4::Types::ResponsiblePartyType] Defines the party to be billed with the initial balance owed on the claim.
392
412
  # @param url [String] URL that links directly to the claim created in Candid.
393
- # @param diagnoses [Array<CandidApiClient::Diagnoses::Types::Diagnosis>] Ideally, this field should contain no more than 12 diagnoses. However, more
394
- # diagnoses may be submitted at this time, and coders will later prioritize the 12
395
- # that will be submitted to the payor.
413
+ # @param diagnoses [Array<CandidApiClient::Diagnoses::Types::Diagnosis>] Contains the primary and other diagnosis health care code information objects
414
+ # associated with this encounter. For professional claims, these diagnoses
415
+ # correspond with those that are set on service lines directly, where as for
416
+ # institutional claims these are only associated directly with the claim itself.
417
+ # See also Health Care Code Information objects and corresponding apis.
396
418
  # @param clinical_notes [Array<CandidApiClient::Encounters::V4::Types::ClinicalNoteCategory>] Holds a collection of clinical observations made by healthcare providers during
397
419
  # patient encounters. Please note that medical records for appeals should be sent
398
420
  # using the Encounter Attachments API.
@@ -421,10 +443,10 @@ module CandidApiClient
421
443
  # Multiple schema
422
444
  # instances cannot be created for the same schema on an encounter.
423
445
  # @param referral_number [String] Refers to REF*9F on the 837p. Value cannot be greater than 50 characters.
424
- # @param epsdt_referral [CandidApiClient::Encounters::V4::Types::EpsdtReferral] Refers Box 24H on the CMS1500 form and Loop 2300 CRC - EPSDT Referral on the
425
- # 837P form
426
- # @param claim_supplemental_information [Array<CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation>] Refers to Loop 2300 - Segment PWK on the 837P form. No more than 10 entries are
427
- # permitted.
446
+ # @param epsdt_referral [CandidApiClient::Encounters::V4::Types::EpsdtReferral] Refers to Box 24H on the CMS1500 form and Loop 2300 CRC - EPSDT Referral on the
447
+ # 837P and 837i form
448
+ # @param claim_supplemental_information [Array<CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation>] Refers to Loop 2300 - Segment PWK on the 837P and 837i form. No more than 10
449
+ # entries are permitted.
428
450
  # @param secondary_payer_carrier_code [String] When Medicaid is billed as the secondary payer the Carrier Code is used to
429
451
  # identify the primary payer. This is required for certain states.
430
452
  # @param last_submitted_at [DateTime] The date and time the encounter was last submitted to a payer.
@@ -436,7 +458,7 @@ module CandidApiClient
436
458
  # This field should not contain PHI.
437
459
  # @param date_of_service [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-24.
438
460
  # This date must be the local date in the timezone where the service occurred.
439
- # Box 24a on the CMS-1500 claim form.
461
+ # Box 24a on the CMS-1500 claim form or Form Locator 45 on the UB-04 claim form.
440
462
  # If service occurred over a range of dates, this should be the start date.
441
463
  # date_of_service must be defined on either the encounter or the service lines but
442
464
  # not both.
@@ -452,17 +474,17 @@ module CandidApiClient
452
474
  # for future API versions.
453
475
  # @param patient_authorized_release [Boolean] Whether this patient has authorized the release of medical information
454
476
  # for billing purpose.
455
- # Box 12 on the CMS-1500 claim form.
477
+ # Box 12 on the CMS-1500 claim form or Form Locator 52 on a UB-04 claim form.
456
478
  # @param benefits_assigned_to_provider [Boolean] Whether this patient has authorized insurance payments to be made to you,
457
479
  # not them. If false, patient may receive reimbursement.
458
- # Box 13 on the CMS-1500 claim form.
480
+ # Box 13 on the CMS-1500 claim form or Form Locator 53 on a UB-04 claim form.
459
481
  # @param provider_accepts_assignment [Boolean] Whether you have accepted the patient's authorization for insurance payments
460
482
  # to be made to you, not them.
461
- # Box 27 on the CMS-1500 claim form.
483
+ # Box 27 on the CMS-1500 claim form. There is no exact equivalent of this field on
484
+ # a UB-04 claim, however contributes to the concept of Form Locator 53.
462
485
  # @param appointment_type [String] Human-readable description of the appointment type (ex: "Acupuncture -
463
486
  # Headaches").
464
487
  # @param existing_medications [Array<CandidApiClient::Encounters::V4::Types::Medication>]
465
- # @param vitals [CandidApiClient::Encounters::V4::Types::Vitals]
466
488
  # @param interventions [Array<CandidApiClient::Encounters::V4::Types::Intervention>]
467
489
  # @param pay_to_address [CandidApiClient::Commons::Types::StreetAddressLongZip] Specifies the address to which payments for the claim should be sent.
468
490
  # @param synchronicity [CandidApiClient::Encounters::V4::Types::SynchronicityType] Whether or not this was a synchronous or asynchronous encounter.
@@ -472,41 +494,44 @@ module CandidApiClient
472
494
  # Synchronous encounters occur in live, real-time settings where the patient
473
495
  # interacts
474
496
  # directly with the provider, such as over video or a phone call.
497
+ # @param vitals [CandidApiClient::Encounters::V4::Types::Vitals]
475
498
  # @param billable_status [CandidApiClient::Encounters::V4::Types::BillableStatusType] Defines if the Encounter is to be billed by Candid to the responsible_party.
476
499
  # Examples for when this should be set to NOT_BILLABLE include
477
500
  # if the Encounter has not occurred yet or if there is no intention of ever
478
501
  # billing the responsible_party.
479
502
  # @param additional_information [String] Defines additional information on the claim needed by the payer.
480
- # Box 19 on the CMS-1500 claim form.
503
+ # Box 19 on the CMS-1500 claim form or Form Locator 80 on a UB-04 claim form.
481
504
  # @param service_authorization_exception_code [CandidApiClient::Encounters::V4::Types::ServiceAuthorizationExceptionCode] 837p Loop2300 REF*4N
482
505
  # Required when mandated by government law or regulation to obtain authorization
483
506
  # for specific service(s) but, for the
484
507
  # reasons listed in one of the enum values of ServiceAuthorizationExceptionCode,
485
508
  # the service was performed without
486
509
  # obtaining the authorization.
487
- # @param admission_date [Date] 837p Loop2300 DTP*435, CMS-1500 Box 18
510
+ # @param admission_date [Date] 837p Loop2300 DTP*435, CMS-1500 Box 18 or UB-04 Form Locator 12.
488
511
  # Required on all ambulance claims when the patient was known to be admitted to
489
512
  # the hospital.
490
513
  # OR
491
514
  # Required on all claims involving inpatient medical visits.
492
- # @param discharge_date [Date] 837p Loop2300 DTP*096, CMS-1500 Box 18
493
- # Required for inpatient claims when the patient was discharged from the facility
494
- # and the discharge date is known.
515
+ # @param discharge_date [Date] 837p Loop2300 DTP*096, CMS-1500 Box 18 Required for inpatient claims when the
516
+ # patient was discharged from the facility and the discharge date is known. Not
517
+ # used on an institutional claim.
495
518
  # @param onset_of_current_illness_or_symptom_date [Date] 837p Loop2300 DTP*431, CMS-1500 Box 14
496
519
  # Required for the initial medical service or visit performed in response to a
497
520
  # medical emergency when the date is available and is different than the date of
498
521
  # service.
499
522
  # OR
500
523
  # This date is the onset of acute symptoms for the current illness or condition.
524
+ # For UB-04 claims, this is populated separately via occurrence codes.
501
525
  # @param last_menstrual_period_date [Date] 837p Loop2300 DTP*484, CMS-1500 Box 14
502
526
  # Required when, in the judgment of the provider, the services on this claim are
503
527
  # related to the patient's pregnancy.
528
+ # This field is populated separately via occurrence codes for UB-04 claim forms.
504
529
  # @param delay_reason_code [CandidApiClient::Commons::Types::DelayReasonCode] 837i Loop2300, CLM-1300 Box 20
505
530
  # Code indicating the reason why a request was delayed
506
531
  # @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
507
532
  # @return [CandidApiClient::Encounters::V4::Types::Encounter]
508
533
  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)
534
+ 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, interventions: OMIT, pay_to_address: OMIT, synchronicity: OMIT, vitals: 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
535
  if accident_state_or_province_code != OMIT
511
536
  @accident_state_or_province_code = accident_state_or_province_code
512
537
  end
@@ -571,10 +596,10 @@ module CandidApiClient
571
596
  @provider_accepts_assignment = provider_accepts_assignment
572
597
  @appointment_type = appointment_type if appointment_type != OMIT
573
598
  @existing_medications = existing_medications if existing_medications != OMIT
574
- @vitals = vitals if vitals != OMIT
575
599
  @interventions = interventions if interventions != OMIT
576
600
  @pay_to_address = pay_to_address if pay_to_address != OMIT
577
601
  @synchronicity = synchronicity if synchronicity != OMIT
602
+ @vitals = vitals if vitals != OMIT
578
603
  @billable_status = billable_status
579
604
  @additional_information = additional_information if additional_information != OMIT
580
605
  if service_authorization_exception_code != OMIT
@@ -647,10 +672,10 @@ module CandidApiClient
647
672
  "provider_accepts_assignment": provider_accepts_assignment,
648
673
  "appointment_type": appointment_type,
649
674
  "existing_medications": existing_medications,
650
- "vitals": vitals,
651
675
  "interventions": interventions,
652
676
  "pay_to_address": pay_to_address,
653
677
  "synchronicity": synchronicity,
678
+ "vitals": vitals,
654
679
  "billable_status": billable_status,
655
680
  "additional_information": additional_information,
656
681
  "service_authorization_exception_code": service_authorization_exception_code,
@@ -707,7 +732,7 @@ module CandidApiClient
707
732
  attending_provider = nil
708
733
  else
709
734
  attending_provider = parsed_json["attending_provider"].to_json
710
- attending_provider = CandidApiClient::EncounterProviders::V2::Types::RenderingProvider.from_json(json_object: attending_provider)
735
+ attending_provider = CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.from_json(json_object: attending_provider)
711
736
  end
712
737
  admission_hour = struct["admission_hour"]
713
738
  admission_type_code = struct["admission_type_code"]
@@ -718,13 +743,13 @@ module CandidApiClient
718
743
  operating_provider = nil
719
744
  else
720
745
  operating_provider = parsed_json["operating_provider"].to_json
721
- operating_provider = CandidApiClient::EncounterProviders::V2::Types::RenderingProvider.from_json(json_object: operating_provider)
746
+ operating_provider = CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.from_json(json_object: operating_provider)
722
747
  end
723
748
  if parsed_json["other_operating_provider"].nil?
724
749
  other_operating_provider = nil
725
750
  else
726
751
  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)
752
+ other_operating_provider = CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.from_json(json_object: other_operating_provider)
728
753
  end
729
754
  submission_expectation = struct["submission_expectation"]
730
755
  if parsed_json["type_of_bill"].nil?
@@ -845,12 +870,6 @@ module CandidApiClient
845
870
  item = item.to_json
846
871
  CandidApiClient::Encounters::V4::Types::Medication.from_json(json_object: item)
847
872
  end
848
- if parsed_json["vitals"].nil?
849
- vitals = nil
850
- else
851
- vitals = parsed_json["vitals"].to_json
852
- vitals = CandidApiClient::Encounters::V4::Types::Vitals.from_json(json_object: vitals)
853
- end
854
873
  interventions = parsed_json["interventions"]&.map do |item|
855
874
  item = item.to_json
856
875
  CandidApiClient::Encounters::V4::Types::Intervention.from_json(json_object: item)
@@ -862,6 +881,12 @@ module CandidApiClient
862
881
  pay_to_address = CandidApiClient::Commons::Types::StreetAddressLongZip.from_json(json_object: pay_to_address)
863
882
  end
864
883
  synchronicity = struct["synchronicity"]
884
+ if parsed_json["vitals"].nil?
885
+ vitals = nil
886
+ else
887
+ vitals = parsed_json["vitals"].to_json
888
+ vitals = CandidApiClient::Encounters::V4::Types::Vitals.from_json(json_object: vitals)
889
+ end
865
890
  billable_status = struct["billable_status"]
866
891
  additional_information = struct["additional_information"]
867
892
  service_authorization_exception_code = struct["service_authorization_exception_code"]
@@ -933,10 +958,10 @@ module CandidApiClient
933
958
  provider_accepts_assignment: provider_accepts_assignment,
934
959
  appointment_type: appointment_type,
935
960
  existing_medications: existing_medications,
936
- vitals: vitals,
937
961
  interventions: interventions,
938
962
  pay_to_address: pay_to_address,
939
963
  synchronicity: synchronicity,
964
+ vitals: vitals,
940
965
  billable_status: billable_status,
941
966
  additional_information: additional_information,
942
967
  service_authorization_exception_code: service_authorization_exception_code,
@@ -972,14 +997,14 @@ module CandidApiClient
972
997
  obj.guarantor.nil? || CandidApiClient::Guarantor::V1::Types::Guarantor.validate_raw(obj: obj.guarantor)
973
998
  CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.validate_raw(obj: obj.billing_provider)
974
999
  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)
1000
+ obj.attending_provider.nil? || CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.validate_raw(obj: obj.attending_provider)
976
1001
  obj.admission_hour&.is_a?(Integer) != false || raise("Passed value for field obj.admission_hour is not the expected type, validation failed.")
977
1002
  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
1003
  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
1004
  obj.discharge_hour&.is_a?(Integer) != false || raise("Passed value for field obj.discharge_hour is not the expected type, validation failed.")
980
1005
  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)
1006
+ obj.operating_provider.nil? || CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.validate_raw(obj: obj.operating_provider)
1007
+ obj.other_operating_provider.nil? || CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.validate_raw(obj: obj.other_operating_provider)
983
1008
  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
1009
  obj.type_of_bill.nil? || CandidApiClient::X12::V1::Types::TypeOfBillComposite.validate_raw(obj: obj.type_of_bill)
985
1010
  obj.referring_provider.nil? || CandidApiClient::EncounterProviders::V2::Types::EncounterProvider.validate_raw(obj: obj.referring_provider)
@@ -1021,10 +1046,10 @@ module CandidApiClient
1021
1046
  obj.provider_accepts_assignment.is_a?(Boolean) != false || raise("Passed value for field obj.provider_accepts_assignment is not the expected type, validation failed.")
1022
1047
  obj.appointment_type&.is_a?(String) != false || raise("Passed value for field obj.appointment_type is not the expected type, validation failed.")
1023
1048
  obj.existing_medications&.is_a?(Array) != false || raise("Passed value for field obj.existing_medications is not the expected type, validation failed.")
1024
- obj.vitals.nil? || CandidApiClient::Encounters::V4::Types::Vitals.validate_raw(obj: obj.vitals)
1025
1049
  obj.interventions&.is_a?(Array) != false || raise("Passed value for field obj.interventions is not the expected type, validation failed.")
1026
1050
  obj.pay_to_address.nil? || CandidApiClient::Commons::Types::StreetAddressLongZip.validate_raw(obj: obj.pay_to_address)
1027
1051
  obj.synchronicity&.is_a?(CandidApiClient::Encounters::V4::Types::SynchronicityType) != false || raise("Passed value for field obj.synchronicity is not the expected type, validation failed.")
1052
+ obj.vitals.nil? || CandidApiClient::Encounters::V4::Types::Vitals.validate_raw(obj: obj.vitals)
1028
1053
  obj.billable_status.is_a?(CandidApiClient::Encounters::V4::Types::BillableStatusType) != false || raise("Passed value for field obj.billable_status is not the expected type, validation failed.")
1029
1054
  obj.additional_information&.is_a?(String) != false || raise("Passed value for field obj.additional_information is not the expected type, validation failed.")
1030
1055
  obj.service_authorization_exception_code&.is_a?(CandidApiClient::Encounters::V4::Types::ServiceAuthorizationExceptionCode) != false || raise("Passed value for field obj.service_authorization_exception_code is not the expected type, validation failed.")