candidhealth 0.21.0 → 0.24.0.pre.2a6d412
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/auth/client.rb +8 -6
 - data/lib/candidhealth/auth/v_2/client.rb +86 -38
 - data/lib/candidhealth/auth/v_2/types/auth_get_token_response.rb +61 -43
 - data/lib/candidhealth/auth/v_2/types/too_many_requests_error_type.rb +44 -33
 - data/lib/candidhealth/billing_notes/client.rb +8 -6
 - data/lib/candidhealth/billing_notes/v_2/client.rb +43 -21
 - data/lib/candidhealth/billing_notes/v_2/types/billing_note.rb +95 -72
 - data/lib/candidhealth/billing_notes/v_2/types/billing_note_base.rb +44 -33
 - data/lib/candidhealth/claim_submission/v_1/types/claim_frequency_type_code.rb +6 -4
 - data/lib/candidhealth/claim_submission/v_1/types/claim_submission_record_create.rb +80 -59
 - data/lib/candidhealth/claim_submission/v_1/types/external_claim_submission_create.rb +78 -56
 - data/lib/candidhealth/claims/types/claim.rb +114 -86
 - data/lib/candidhealth/claims/types/claim_status.rb +19 -17
 - data/lib/candidhealth/commons/types/claim_adjustment_group_codes.rb +14 -12
 - data/lib/candidhealth/commons/types/claim_submission_payer_responsibility_type.rb +6 -4
 - data/lib/candidhealth/commons/types/date_range_optional_end.rb +57 -40
 - data/lib/candidhealth/commons/types/delay_reason_code.rb +19 -17
 - data/lib/candidhealth/commons/types/emr_payer_crosswalk.rb +6 -4
 - data/lib/candidhealth/commons/types/entity_conflict_error_message.rb +45 -34
 - data/lib/candidhealth/commons/types/entity_not_found_error_message.rb +45 -34
 - data/lib/candidhealth/commons/types/facility_type_code.rb +58 -55
 - data/lib/candidhealth/commons/types/http_service_unavailable_error_message.rb +47 -34
 - data/lib/candidhealth/commons/types/insurance_type_code.rb +76 -73
 - data/lib/candidhealth/commons/types/intended_submission_medium.rb +9 -5
 - data/lib/candidhealth/commons/types/network_type.rb +23 -21
 - data/lib/candidhealth/commons/types/organization_not_authorized_error_message.rb +46 -34
 - data/lib/candidhealth/commons/types/patient_relationship_to_insured_code_all.rb +28 -26
 - data/lib/candidhealth/commons/types/phone_number.rb +55 -39
 - data/lib/candidhealth/commons/types/phone_number_type.rb +7 -5
 - data/lib/candidhealth/commons/types/procedure_modifier.rb +391 -389
 - data/lib/candidhealth/commons/types/qualifier_code.rb +14 -0
 - data/lib/candidhealth/commons/types/region_national.rb +39 -29
 - data/lib/candidhealth/commons/types/region_states.rb +45 -34
 - data/lib/candidhealth/commons/types/regions.rb +78 -72
 - data/lib/candidhealth/commons/types/removable_date_range_optional_end.rb +77 -71
 - data/lib/candidhealth/commons/types/request_validation_error.rb +57 -39
 - data/lib/candidhealth/commons/types/resource_page.rb +57 -40
 - data/lib/candidhealth/commons/types/service_line_units.rb +6 -4
 - data/lib/candidhealth/commons/types/sort_direction.rb +6 -4
 - data/lib/candidhealth/commons/types/source_of_payment_code.rb +28 -26
 - data/lib/candidhealth/commons/types/state.rb +66 -64
 - data/lib/candidhealth/commons/types/street_address_base.rb +84 -61
 - data/lib/candidhealth/commons/types/street_address_long_zip.rb +93 -68
 - data/lib/candidhealth/commons/types/street_address_short_zip.rb +93 -68
 - data/lib/candidhealth/commons/types/unauthorized_error_message.rb +47 -34
 - data/lib/candidhealth/commons/types/unprocessable_entity_error_message.rb +47 -34
 - data/lib/candidhealth/commons/types/updates_disabled_due_to_external_system_integration_error_message.rb +49 -34
 - data/lib/candidhealth/contracts/client.rb +8 -6
 - data/lib/candidhealth/contracts/v_2/client.rb +251 -127
 - data/lib/candidhealth/contracts/v_2/types/authorized_signatory.rb +92 -67
 - data/lib/candidhealth/contracts/v_2/types/authorized_signatory_update.rb +76 -70
 - data/lib/candidhealth/contracts/v_2/types/contract.rb +178 -141
 - data/lib/candidhealth/contracts/v_2/types/contract_base.rb +134 -106
 - data/lib/candidhealth/contracts/v_2/types/contract_is_linked_to_fee_schedule_error.rb +44 -33
 - data/lib/candidhealth/contracts/v_2/types/contract_status.rb +6 -4
 - data/lib/candidhealth/contracts/v_2/types/contract_with_providers.rb +191 -152
 - data/lib/candidhealth/contracts/v_2/types/contracts_page.rb +70 -47
 - data/lib/candidhealth/contracts/v_2/types/date_update.rb +76 -71
 - data/lib/candidhealth/contracts/v_2/types/insurance_types.rb +86 -80
 - data/lib/candidhealth/contracts/v_2/types/regions_update.rb +76 -70
 - data/lib/candidhealth/diagnoses/types/diagnosis.rb +126 -91
 - data/lib/candidhealth/diagnoses/types/diagnosis_create.rb +88 -58
 - data/lib/candidhealth/diagnoses/types/diagnosis_type_code.rb +14 -12
 - data/lib/candidhealth/diagnoses/types/standalone_diagnosis_create.rb +100 -64
 - data/lib/candidhealth/eligibility/client.rb +8 -6
 - data/lib/candidhealth/eligibility/v_2/client.rb +210 -124
 - data/lib/candidhealth/encounter_providers/v_2/types/billing_provider.rb +126 -86
 - data/lib/candidhealth/encounter_providers/v_2/types/encounter_provider.rb +128 -85
 - data/lib/candidhealth/encounter_providers/v_2/types/encounter_provider_base.rb +73 -44
 - data/lib/candidhealth/encounter_providers/v_2/types/initial_referring_provider.rb +132 -0
 - data/lib/candidhealth/encounter_providers/v_2/types/ordering_provider.rb +123 -0
 - data/lib/candidhealth/encounter_providers/v_2/types/referring_provider.rb +105 -73
 - data/lib/candidhealth/encounter_providers/v_2/types/rendering_provider.rb +105 -73
 - data/lib/candidhealth/encounter_providers/v_2/types/supervising_provider.rb +123 -0
 - data/lib/candidhealth/encounters/client.rb +8 -6
 - data/lib/candidhealth/encounters/v_4/client.rb +1056 -476
 - data/lib/candidhealth/encounters/v_4/types/billable_status_type.rb +5 -3
 - data/lib/candidhealth/encounters/v_4/types/cash_pay_payer_error_message.rb +44 -33
 - data/lib/candidhealth/encounters/v_4/types/clinical_note.rb +76 -50
 - data/lib/candidhealth/encounters/v_4/types/clinical_note_category.rb +70 -45
 - data/lib/candidhealth/encounters/v_4/types/clinical_note_category_create.rb +57 -40
 - data/lib/candidhealth/encounters/v_4/types/coding_attribution_type.rb +7 -5
 - data/lib/candidhealth/encounters/v_4/types/encounter.rb +732 -482
 - data/lib/candidhealth/encounters/v_4/types/encounter_base.rb +304 -223
 - data/lib/candidhealth/encounters/v_4/types/encounter_external_id_uniqueness_error_type.rb +47 -34
 - data/lib/candidhealth/encounters/v_4/types/encounter_guarantor_missing_contact_info_error_type.rb +46 -33
 - data/lib/candidhealth/encounters/v_4/types/encounter_owner_of_next_action_type.rb +7 -5
 - data/lib/candidhealth/encounters/v_4/types/encounter_page.rb +70 -47
 - data/lib/candidhealth/encounters/v_4/types/encounter_patient_control_number_uniqueness_error_type.rb +46 -33
 - data/lib/candidhealth/encounters/v_4/types/encounter_sort_options.rb +7 -5
 - data/lib/candidhealth/encounters/v_4/types/encounter_submission_origin_type.rb +5 -3
 - data/lib/candidhealth/encounters/v_4/types/intake_follow_up.rb +63 -44
 - data/lib/candidhealth/encounters/v_4/types/intake_question.rb +66 -46
 - data/lib/candidhealth/encounters/v_4/types/intake_response_and_follow_ups.rb +59 -40
 - data/lib/candidhealth/encounters/v_4/types/intervention.rb +92 -66
 - data/lib/candidhealth/encounters/v_4/types/intervention_category.rb +7 -5
 - data/lib/candidhealth/encounters/v_4/types/lab.rb +63 -43
 - data/lib/candidhealth/encounters/v_4/types/lab_code_type.rb +5 -3
 - data/lib/candidhealth/encounters/v_4/types/medication.rb +92 -68
 - data/lib/candidhealth/encounters/v_4/types/note_category.rb +17 -15
 - data/lib/candidhealth/encounters/v_4/types/patient_history_category.rb +57 -40
 - data/lib/candidhealth/encounters/v_4/types/patient_history_category_enum.rb +7 -5
 - data/lib/candidhealth/encounters/v_4/types/responsible_party_type.rb +6 -4
 - data/lib/candidhealth/encounters/v_4/types/service_authorization_exception_code.rb +14 -10
 - data/lib/candidhealth/encounters/v_4/types/synchronicity_type.rb +5 -3
 - data/lib/candidhealth/encounters/v_4/types/vitals.rb +84 -62
 - data/lib/candidhealth/era/types/era.rb +62 -46
 - data/lib/candidhealth/era/types/era_base.rb +55 -40
 - data/lib/candidhealth/era/types/era_not_fully_processed_error_message.rb +55 -40
 - data/lib/candidhealth/era_commons/types/claim_status_code_create.rb +14 -12
 - data/lib/candidhealth/expected_network_status/client.rb +16 -10
 - data/lib/candidhealth/expected_network_status/v_1/client.rb +76 -29
 - data/lib/candidhealth/expected_network_status/v_1/types/expected_network_status.rb +6 -4
 - data/lib/candidhealth/expected_network_status/v_1/types/expected_network_status_response.rb +69 -49
 - data/lib/candidhealth/expected_network_status/v_2/client.rb +108 -69
 - data/lib/candidhealth/expected_network_status/v_2/types/compute_all_in_network_providers_request.rb +129 -96
 - data/lib/candidhealth/expected_network_status/v_2/types/compute_all_in_network_providers_response.rb +62 -47
 - data/lib/candidhealth/expected_network_status/v_2/types/compute_all_in_network_rendering_providers_result.rb +89 -82
 - data/lib/candidhealth/expected_network_status/v_2/types/expected_network_status_check_error_message.rb +45 -33
 - data/lib/candidhealth/expected_network_status/v_2/types/expected_network_status_request_v_2.rb +129 -96
 - data/lib/candidhealth/expected_network_status/v_2/types/expected_network_status_response_v_2.rb +59 -44
 - data/lib/candidhealth/expected_network_status/v_2/types/expected_network_status_subscriber_information.rb +68 -49
 - data/lib/candidhealth/expected_network_status/v_2/types/expected_network_status_v_2.rb +88 -82
 - data/lib/candidhealth/expected_network_status/v_2/types/explanation.rb +11 -9
 - data/lib/candidhealth/expected_network_status/v_2/types/in_network_rendering_providers_detail.rb +66 -51
 - data/lib/candidhealth/expected_network_status/v_2/types/in_network_status.rb +57 -41
 - data/lib/candidhealth/expected_network_status/v_2/types/indeterminate_network_status.rb +76 -57
 - data/lib/candidhealth/expected_network_status/v_2/types/insurance_type.rb +59 -43
 - data/lib/candidhealth/expected_network_status/v_2/types/insurance_type_codes.rb +86 -80
 - data/lib/candidhealth/expected_network_status/v_2/types/line_of_business.rb +6 -4
 - data/lib/candidhealth/expected_network_status/v_2/types/out_of_network_status.rb +65 -50
 - data/lib/candidhealth/expected_network_status/v_2/types/service_type.rb +44 -42
 - data/lib/candidhealth/exports/client.rb +8 -6
 - data/lib/candidhealth/exports/v_3/client.rb +88 -48
 - data/lib/candidhealth/exports/v_3/types/get_exports_response.rb +79 -58
 - data/lib/candidhealth/external_payment_account_config/client.rb +30 -0
 - data/lib/candidhealth/external_payment_account_config/v_1/client.rb +89 -0
 - data/lib/candidhealth/external_payment_account_config/v_1/types/external_payment_account_config.rb +70 -0
 - data/lib/candidhealth/external_payment_account_config/v_1/types/external_payment_account_config_page.rb +88 -0
 - data/lib/candidhealth/fee_schedules/client.rb +8 -6
 - data/lib/candidhealth/fee_schedules/v_3/client.rb +429 -181
 - data/lib/candidhealth/fee_schedules/v_3/types/dimension_match.rb +159 -130
 - data/lib/candidhealth/fee_schedules/v_3/types/dimension_name.rb +7 -5
 - data/lib/candidhealth/fee_schedules/v_3/types/dimensions.rb +146 -117
 - data/lib/candidhealth/fee_schedules/v_3/types/dimensions_page.rb +70 -51
 - data/lib/candidhealth/fee_schedules/v_3/types/match_cpt_code.rb +62 -44
 - data/lib/candidhealth/fee_schedules/v_3/types/match_date.rb +65 -44
 - data/lib/candidhealth/fee_schedules/v_3/types/match_facility_type_code.rb +64 -44
 - data/lib/candidhealth/fee_schedules/v_3/types/match_geo.rb +76 -49
 - data/lib/candidhealth/fee_schedules/v_3/types/match_license_type.rb +64 -44
 - data/lib/candidhealth/fee_schedules/v_3/types/match_modifiers.rb +67 -48
 - data/lib/candidhealth/fee_schedules/v_3/types/match_network_types.rb +67 -48
 - data/lib/candidhealth/fee_schedules/v_3/types/match_payer.rb +62 -45
 - data/lib/candidhealth/fee_schedules/v_3/types/match_provider.rb +64 -45
 - data/lib/candidhealth/fee_schedules/v_3/types/match_result.rb +59 -43
 - data/lib/candidhealth/fee_schedules/v_3/types/match_test_result.rb +63 -46
 - data/lib/candidhealth/fee_schedules/v_3/types/new_rate.rb +61 -44
 - data/lib/candidhealth/fee_schedules/v_3/types/new_rate_version.rb +70 -46
 - data/lib/candidhealth/fee_schedules/v_3/types/optional_dimensions.rb +148 -117
 - data/lib/candidhealth/fee_schedules/v_3/types/overlapping_rate_entries_error.rb +71 -52
 - data/lib/candidhealth/fee_schedules/v_3/types/payer_threshold.rb +77 -50
 - data/lib/candidhealth/fee_schedules/v_3/types/payer_thresholds_page.rb +70 -51
 - data/lib/candidhealth/fee_schedules/v_3/types/rate.rb +100 -75
 - data/lib/candidhealth/fee_schedules/v_3/types/rate_entry.rb +79 -55
 - data/lib/candidhealth/fee_schedules/v_3/types/rate_upload.rb +77 -71
 - data/lib/candidhealth/fee_schedules/v_3/types/rate_upload_with_possible_errors.rb +79 -55
 - data/lib/candidhealth/fee_schedules/v_3/types/rates_page.rb +70 -47
 - data/lib/candidhealth/fee_schedules/v_3/types/threshold_match.rb +79 -54
 - data/lib/candidhealth/fee_schedules/v_3/types/validation_error.rb +108 -102
 - data/lib/candidhealth/financials/types/account_type.rb +6 -4
 - data/lib/candidhealth/financials/types/allocation.rb +60 -43
 - data/lib/candidhealth/financials/types/allocation_create.rb +63 -45
 - data/lib/candidhealth/financials/types/allocation_target.rb +102 -95
 - data/lib/candidhealth/financials/types/allocation_target_create.rb +113 -110
 - data/lib/candidhealth/financials/types/billing_provider_allocation_target.rb +45 -35
 - data/lib/candidhealth/financials/types/claim_allocation_target.rb +55 -41
 - data/lib/candidhealth/financials/types/invoice_update.rb +77 -72
 - data/lib/candidhealth/financials/types/note_update.rb +77 -71
 - data/lib/candidhealth/financials/types/patient_transaction_source.rb +11 -9
 - data/lib/candidhealth/financials/types/refund_reason.rb +5 -3
 - data/lib/candidhealth/financials/types/refund_reason_update.rb +77 -71
 - data/lib/candidhealth/financials/types/service_line_allocation_target.rb +62 -48
 - data/lib/candidhealth/guarantor/client.rb +8 -6
 - data/lib/candidhealth/guarantor/v_1/client.rb +136 -63
 - data/lib/candidhealth/guarantor/v_1/types/encounter_has_existing_guarantor_error_type.rb +45 -33
 - data/lib/candidhealth/guarantor/v_1/types/guarantor.rb +131 -100
 - data/lib/candidhealth/guarantor/v_1/types/guarantor_base.rb +89 -65
 - data/lib/candidhealth/guarantor/v_1/types/guarantor_create.rb +123 -93
 - data/lib/candidhealth/identifiers/types/identifier.rb +85 -64
 - data/lib/candidhealth/identifiers/types/identifier_base.rb +77 -53
 - data/lib/candidhealth/identifiers/types/identifier_code.rb +6 -4
 - data/lib/candidhealth/identifiers/types/identifier_create.rb +77 -53
 - data/lib/candidhealth/identifiers/types/identifier_update.rb +86 -65
 - data/lib/candidhealth/identifiers/types/identifier_value.rb +78 -72
 - data/lib/candidhealth/identifiers/types/medicaid_provider_identifier.rb +55 -39
 - data/lib/candidhealth/identifiers/types/medicare_provider_identifier.rb +55 -39
 - data/lib/candidhealth/identifiers/types/updatable_identifier.rb +89 -84
 - data/lib/candidhealth/import_invoice/client.rb +8 -6
 - data/lib/candidhealth/import_invoice/v_1/client.rb +182 -86
 - data/lib/candidhealth/import_invoice/v_1/types/create_import_invoice_request.rb +123 -83
 - data/lib/candidhealth/import_invoice/v_1/types/import_invoice.rb +145 -110
 - data/lib/candidhealth/import_invoice/v_1/types/import_invoice_update_request.rb +89 -65
 - data/lib/candidhealth/import_invoice/v_1/types/import_invoices_page.rb +70 -47
 - data/lib/candidhealth/import_invoice/v_1/types/invoice_item_info_update.rb +61 -42
 - data/lib/candidhealth/import_invoice/v_1/types/invoice_item_update_type.rb +5 -3
 - data/lib/candidhealth/individual/types/gender.rb +9 -7
 - data/lib/candidhealth/individual/types/individual_base.rb +62 -44
 - data/lib/candidhealth/individual/types/patient.rb +145 -108
 - data/lib/candidhealth/individual/types/patient_base.rb +101 -73
 - data/lib/candidhealth/individual/types/patient_create.rb +137 -101
 - data/lib/candidhealth/individual/types/subscriber.rb +119 -91
 - data/lib/candidhealth/individual/types/subscriber_base.rb +99 -74
 - data/lib/candidhealth/individual/types/subscriber_create.rb +111 -84
 - data/lib/candidhealth/insurance_adjudications/client.rb +8 -6
 - data/lib/candidhealth/insurance_adjudications/v_1/client.rb +106 -47
 - data/lib/candidhealth/insurance_adjudications/v_1/types/claim_adjudication.rb +106 -81
 - data/lib/candidhealth/insurance_adjudications/v_1/types/claim_adjudication_create.rb +98 -74
 - data/lib/candidhealth/insurance_adjudications/v_1/types/insurance_adjudication.rb +104 -80
 - data/lib/candidhealth/insurance_adjudications/v_1/types/insurance_adjudication_create.rb +113 -87
 - data/lib/candidhealth/insurance_adjudications/v_1/types/service_line_adjudication.rb +121 -91
 - data/lib/candidhealth/insurance_adjudications/v_1/types/service_line_adjudication_create.rb +113 -84
 - data/lib/candidhealth/insurance_cards/v_2/types/insurance_card.rb +140 -105
 - data/lib/candidhealth/insurance_cards/v_2/types/insurance_card_base.rb +76 -55
 - data/lib/candidhealth/insurance_cards/v_2/types/insurance_card_create.rb +140 -104
 - data/lib/candidhealth/insurance_payments/client.rb +8 -6
 - data/lib/candidhealth/insurance_payments/v_1/client.rb +214 -102
 - data/lib/candidhealth/insurance_payments/v_1/types/insurance_payment.rb +101 -77
 - data/lib/candidhealth/insurance_payments/v_1/types/insurance_payment_create.rb +93 -70
 - data/lib/candidhealth/insurance_payments/v_1/types/insurance_payment_sort_field.rb +6 -4
 - data/lib/candidhealth/insurance_payments/v_1/types/insurance_payments_page.rb +70 -47
 - data/lib/candidhealth/insurance_refunds/client.rb +8 -6
 - data/lib/candidhealth/insurance_refunds/v_1/client.rb +218 -108
 - data/lib/candidhealth/insurance_refunds/v_1/types/insurance_refund.rb +109 -83
 - data/lib/candidhealth/insurance_refunds/v_1/types/insurance_refund_create.rb +101 -76
 - data/lib/candidhealth/insurance_refunds/v_1/types/insurance_refund_sort_field.rb +7 -5
 - data/lib/candidhealth/insurance_refunds/v_1/types/insurance_refunds_page.rb +70 -47
 - data/lib/candidhealth/invoices/types/invoice.rb +152 -117
 - data/lib/candidhealth/invoices/types/invoice_item.rb +55 -40
 - data/lib/candidhealth/invoices/types/invoice_status.rb +10 -8
 - data/lib/candidhealth/invoices/v_2/types/claim_invoice_item.rb +54 -39
 - data/lib/candidhealth/invoices/v_2/types/claim_invoice_item_info.rb +66 -48
 - data/lib/candidhealth/invoices/v_2/types/invoice.rb +151 -114
 - data/lib/candidhealth/invoices/v_2/types/invoice_destination.rb +8 -5
 - data/lib/candidhealth/invoices/v_2/types/invoice_destination_metadata.rb +78 -55
 - data/lib/candidhealth/invoices/v_2/types/invoice_info.rb +66 -48
 - data/lib/candidhealth/invoices/v_2/types/invoice_item_attribution_create.rb +88 -84
 - data/lib/candidhealth/invoices/v_2/types/invoice_item_create.rb +59 -42
 - data/lib/candidhealth/invoices/v_2/types/invoice_item_info.rb +59 -43
 - data/lib/candidhealth/invoices/v_2/types/invoice_sort_field.rb +9 -7
 - data/lib/candidhealth/invoices/v_2/types/invoice_status.rb +9 -7
 - data/lib/candidhealth/invoices/v_2/types/service_line_invoice_item.rb +54 -39
 - data/lib/candidhealth/invoices/v_2/types/unattributed_invoice_item.rb +44 -33
 - data/lib/candidhealth/organization_providers/client.rb +8 -6
 - data/lib/candidhealth/organization_providers/v_2/types/address_type.rb +4 -2
 - data/lib/candidhealth/organization_providers/v_2/types/employment_status.rb +5 -3
 - data/lib/candidhealth/organization_providers/v_2/types/license_type.rb +71 -69
 - data/lib/candidhealth/organization_providers/v_2/types/organization_provider.rb +189 -138
 - data/lib/candidhealth/organization_providers/v_2/types/organization_provider_address.rb +59 -42
 - data/lib/candidhealth/organization_providers/v_2/types/organization_provider_base.rb +157 -112
 - data/lib/candidhealth/organization_providers/v_2/types/organization_provider_sort_options.rb +7 -5
 - data/lib/candidhealth/organization_providers/v_2/types/provider_type.rb +5 -3
 - data/lib/candidhealth/organization_providers/v_3/client.rb +166 -80
 - data/lib/candidhealth/organization_providers/v_3/types/organization_provider_create_v_2.rb +171 -124
 - data/lib/candidhealth/organization_providers/v_3/types/organization_provider_page_v_2.rb +70 -47
 - data/lib/candidhealth/organization_providers/v_3/types/organization_provider_update_v_2.rb +169 -121
 - data/lib/candidhealth/organization_providers/v_3/types/organization_provider_v_2.rb +179 -131
 - data/lib/candidhealth/organization_service_facilities/client.rb +8 -6
 - data/lib/candidhealth/organization_service_facilities/v_2/client.rb +186 -90
 - data/lib/candidhealth/organization_service_facilities/v_2/types/organization_service_facility.rb +149 -111
 - data/lib/candidhealth/organization_service_facilities/v_2/types/organization_service_facility_create.rb +141 -104
 - data/lib/candidhealth/organization_service_facilities/v_2/types/organization_service_facility_page.rb +70 -47
 - data/lib/candidhealth/organization_service_facilities/v_2/types/organization_service_facility_update.rb +141 -104
 - data/lib/candidhealth/organization_service_facilities/v_2/types/service_facility_mode.rb +5 -3
 - data/lib/candidhealth/organization_service_facilities/v_2/types/service_facility_operational_status.rb +9 -7
 - data/lib/candidhealth/organization_service_facilities/v_2/types/service_facility_physical_type.rb +17 -15
 - data/lib/candidhealth/organization_service_facilities/v_2/types/service_facility_status.rb +6 -4
 - data/lib/candidhealth/organization_service_facilities/v_2/types/service_facility_type.rb +126 -124
 - data/lib/candidhealth/patient_payments/client.rb +8 -6
 - data/lib/candidhealth/patient_payments/v_3/types/patient_payment.rb +143 -111
 - data/lib/candidhealth/patient_payments/v_3/types/patient_payment_source.rb +12 -10
 - data/lib/candidhealth/patient_payments/v_3/types/patient_payment_status.rb +14 -12
 - data/lib/candidhealth/patient_payments/v_4/client.rb +230 -103
 - data/lib/candidhealth/patient_payments/v_4/types/patient_payment.rb +129 -100
 - data/lib/candidhealth/patient_payments/v_4/types/patient_payment_sort_field.rb +7 -5
 - data/lib/candidhealth/patient_payments/v_4/types/patient_payments_page.rb +70 -47
 - data/lib/candidhealth/patient_refunds/client.rb +8 -6
 - data/lib/candidhealth/patient_refunds/v_1/client.rb +236 -107
 - data/lib/candidhealth/patient_refunds/v_1/types/patient_refund.rb +137 -106
 - data/lib/candidhealth/patient_refunds/v_1/types/patient_refund_sort_field.rb +8 -6
 - data/lib/candidhealth/patient_refunds/v_1/types/patient_refunds_page.rb +70 -47
 - data/lib/candidhealth/payers/client.rb +8 -6
 - data/lib/candidhealth/payers/v_3/client.rb +73 -32
 - data/lib/candidhealth/payers/v_3/types/payer.rb +61 -44
 - data/lib/candidhealth/payers/v_3/types/payer_identifier.rb +77 -72
 - data/lib/candidhealth/payers/v_3/types/payer_info.rb +54 -40
 - data/lib/candidhealth/payers/v_3/types/payer_page.rb +70 -47
 - data/lib/candidhealth/pre_encounter/client.rb +30 -0
 - data/lib/candidhealth/pre_encounter/common/types/address.rb +123 -0
 - data/lib/candidhealth/pre_encounter/common/types/address_use.rb +17 -0
 - data/lib/candidhealth/pre_encounter/common/types/contact_point.rb +87 -0
 - data/lib/candidhealth/pre_encounter/common/types/contact_point_use.rb +17 -0
 - data/lib/candidhealth/pre_encounter/common/types/error_base.rb +60 -0
 - data/lib/candidhealth/pre_encounter/common/types/gender.rb +16 -0
 - data/lib/candidhealth/pre_encounter/common/types/human_name.rb +94 -0
 - data/lib/candidhealth/pre_encounter/common/types/name_use.rb +19 -0
 - data/lib/candidhealth/pre_encounter/common/types/not_found_error_body.rb +70 -0
 - data/lib/candidhealth/pre_encounter/common/types/period.rb +74 -0
 - data/lib/candidhealth/pre_encounter/common/types/relationship.rb +17 -0
 - data/lib/candidhealth/pre_encounter/common/types/version_conflict_error_body.rb +77 -0
 - data/lib/candidhealth/pre_encounter/coverages/client.rb +32 -0
 - data/lib/candidhealth/pre_encounter/coverages/v_1/client.rb +34 -0
 - data/lib/candidhealth/pre_encounter/coverages/v_1/coverages/client.rb +487 -0
 - data/lib/candidhealth/pre_encounter/coverages/v_1/coverages/types/coverage.rb +185 -0
 - data/lib/candidhealth/pre_encounter/coverages/v_1/coverages/types/coverage_status.rb +22 -0
 - data/lib/candidhealth/pre_encounter/coverages/v_1/coverages/types/coverage_type.rb +18 -0
 - data/lib/candidhealth/pre_encounter/coverages/v_1/coverages/types/insurance_plan.rb +136 -0
 - data/lib/candidhealth/pre_encounter/coverages/v_1/coverages/types/mutable_coverage.rb +131 -0
 - data/lib/candidhealth/pre_encounter/coverages/v_1/coverages/types/subscriber.rb +90 -0
 - data/lib/candidhealth/pre_encounter/patients/client.rb +32 -0
 - data/lib/candidhealth/pre_encounter/patients/v_1/client.rb +34 -0
 - data/lib/candidhealth/pre_encounter/patients/v_1/patients/client.rb +590 -0
 - data/lib/candidhealth/pre_encounter/patients/v_1/patients/types/contact.rb +135 -0
 - data/lib/candidhealth/pre_encounter/patients/v_1/patients/types/external_provenance.rb +75 -0
 - data/lib/candidhealth/pre_encounter/patients/v_1/patients/types/external_provider.rb +116 -0
 - data/lib/candidhealth/pre_encounter/patients/v_1/patients/types/marital_status.rb +28 -0
 - data/lib/candidhealth/pre_encounter/patients/v_1/patients/types/mutable_patient.rb +242 -0
 - data/lib/candidhealth/pre_encounter/patients/v_1/patients/types/patient.rb +294 -0
 - data/lib/candidhealth/remits/v_1/types/payee.rb +59 -42
 - data/lib/candidhealth/remits/v_1/types/payee_identifier.rb +84 -80
 - data/lib/candidhealth/service_facility/client.rb +58 -27
 - data/lib/candidhealth/service_facility/types/encounter_service_facility.rb +87 -62
 - data/lib/candidhealth/service_facility/types/encounter_service_facility_base.rb +87 -57
 - data/lib/candidhealth/service_lines/v_2/types/denial_reason_content.rb +33 -31
 - data/lib/candidhealth/service_lines/v_2/types/drug_identification.rb +92 -68
 - data/lib/candidhealth/service_lines/v_2/types/measurement_unit_code.rb +8 -6
 - data/lib/candidhealth/service_lines/v_2/types/service_id_qualifier.rb +10 -8
 - data/lib/candidhealth/service_lines/v_2/types/service_line.rb +352 -222
 - data/lib/candidhealth/service_lines/v_2/types/service_line_adjustment.rb +85 -62
 - data/lib/candidhealth/service_lines/v_2/types/service_line_create.rb +235 -113
 - data/lib/candidhealth/service_lines/v_2/types/service_line_denial_reason.rb +49 -35
 - data/lib/candidhealth/service_lines/v_2/types/service_line_era_data.rb +60 -44
 - data/lib/candidhealth/tags/types/tag.rb +69 -51
 - data/lib/candidhealth/tags/types/tag_color_enum.rb +14 -12
 - data/lib/candidhealth/tags/types/tag_create.rb +62 -45
 - data/lib/candidhealth/tasks/client.rb +8 -6
 - data/lib/candidhealth/tasks/commons/types/task_category.rb +45 -43
 - data/lib/candidhealth/tasks/commons/types/task_status.rb +11 -9
 - data/lib/candidhealth/tasks/commons/types/task_type.rb +16 -14
 - data/lib/candidhealth/tasks/v_3/client.rb +208 -96
 - data/lib/candidhealth/tasks/v_3/types/task.rb +193 -146
 - data/lib/candidhealth/tasks/v_3/types/task_action.rb +66 -47
 - data/lib/candidhealth/tasks/v_3/types/task_action_execution_method.rb +65 -59
 - data/lib/candidhealth/tasks/v_3/types/task_action_type.rb +5 -3
 - data/lib/candidhealth/tasks/v_3/types/task_actions.rb +47 -35
 - data/lib/candidhealth/tasks/v_3/types/task_assignment.rb +59 -40
 - data/lib/candidhealth/tasks/v_3/types/task_create_v_3.rb +100 -77
 - data/lib/candidhealth/tasks/v_3/types/task_note.rb +83 -62
 - data/lib/candidhealth/tasks/v_3/types/task_page.rb +70 -47
 - data/lib/candidhealth/tasks/v_3/types/task_sort_options.rb +25 -23
 - data/lib/candidhealth/tasks/v_3/types/task_update_v_3.rb +68 -49
 - data/lib/candidhealth/tasks/v_3/types/task_updated_to_deprecated_status_error_type.rb +47 -33
 - data/lib/candidhealth/write_offs/client.rb +8 -6
 - data/lib/candidhealth/write_offs/v_1/client.rb +168 -83
 - data/lib/candidhealth/write_offs/v_1/types/create_write_offs_response.rb +47 -35
 - data/lib/candidhealth/write_offs/v_1/types/insurance_write_off.rb +127 -97
 - data/lib/candidhealth/write_offs/v_1/types/insurance_write_off_create.rb +103 -78
 - data/lib/candidhealth/write_offs/v_1/types/insurance_write_off_reason.rb +19 -17
 - data/lib/candidhealth/write_offs/v_1/types/insurance_write_off_target.rb +84 -81
 - data/lib/candidhealth/write_offs/v_1/types/patient_write_off.rb +111 -84
 - data/lib/candidhealth/write_offs/v_1/types/patient_write_off_create.rb +87 -65
 - data/lib/candidhealth/write_offs/v_1/types/patient_write_off_reason.rb +12 -10
 - data/lib/candidhealth/write_offs/v_1/types/write_off.rb +77 -71
 - data/lib/candidhealth/write_offs/v_1/types/write_off_create.rb +77 -71
 - data/lib/candidhealth/write_offs/v_1/types/write_off_sort_field.rb +6 -4
 - data/lib/candidhealth/write_offs/v_1/types/write_offs_page.rb +70 -47
 - data/lib/candidhealth/x_12/v_1/types/carc.rb +406 -404
 - data/lib/candidhealth/x_12/v_1/types/claim_adjustment_reason_code.rb +61 -44
 - data/lib/candidhealth/x_12/v_1/types/rarc.rb +1063 -1061
 - data/lib/candidhealth/x_12/v_1/types/remittance_advice_remark_code.rb +44 -33
 - data/lib/candidhealth.rb +189 -87
 - data/lib/core/oauth.rb +62 -0
 - data/lib/environment.rb +8 -2
 - data/lib/requests.rb +98 -48
 - data/lib/types_export.rb +30 -53
 - metadata +44 -57
 - data/lib/candidhealth/billing_notes/v_2/types/billing_note_id.rb +0 -9
 - data/lib/candidhealth/commons/types/claim_id.rb +0 -7
 - data/lib/candidhealth/commons/types/date.rb +0 -7
 - data/lib/candidhealth/commons/types/decimal.rb +0 -7
 - data/lib/candidhealth/commons/types/email.rb +0 -7
 - data/lib/candidhealth/commons/types/encounter_external_id.rb +0 -7
 - data/lib/candidhealth/commons/types/encounter_id.rb +0 -7
 - data/lib/candidhealth/commons/types/error_message.rb +0 -7
 - data/lib/candidhealth/commons/types/invoice_id.rb +0 -7
 - data/lib/candidhealth/commons/types/link_url.rb +0 -7
 - data/lib/candidhealth/commons/types/npi.rb +0 -7
 - data/lib/candidhealth/commons/types/organization_id.rb +0 -7
 - data/lib/candidhealth/commons/types/page_token.rb +0 -7
 - data/lib/candidhealth/commons/types/patient_external_id.rb +0 -7
 - data/lib/candidhealth/commons/types/provider_id.rb +0 -7
 - data/lib/candidhealth/commons/types/rate_id.rb +0 -7
 - data/lib/candidhealth/commons/types/service_line_id.rb +0 -7
 - data/lib/candidhealth/commons/types/task_assignment_id.rb +0 -7
 - data/lib/candidhealth/commons/types/task_id.rb +0 -7
 - data/lib/candidhealth/commons/types/task_note_id.rb +0 -7
 - data/lib/candidhealth/commons/types/tax_id.rb +0 -7
 - data/lib/candidhealth/commons/types/user_id.rb +0 -7
 - data/lib/candidhealth/commons/types/work_queue_id.rb +0 -7
 - data/lib/candidhealth/contracts/v_2/types/contract_id.rb +0 -9
 - data/lib/candidhealth/contracts/v_2/types/contracting_provider_id.rb +0 -9
 - data/lib/candidhealth/contracts/v_2/types/rendering_providerid.rb +0 -9
 - data/lib/candidhealth/diagnoses/types/diagnosis_id.rb +0 -7
 - data/lib/candidhealth/encounter_providers/v_2/types/provider_id.rb +0 -9
 - data/lib/candidhealth/encounters/v_4/types/intake_follow_up_id.rb +0 -9
 - data/lib/candidhealth/encounters/v_4/types/intake_question_id.rb +0 -9
 - data/lib/candidhealth/encounters/v_4/types/prior_authorization_number.rb +0 -9
 - data/lib/candidhealth/encounters/v_4/types/rx_cui.rb +0 -9
 - data/lib/candidhealth/era/types/era_id.rb +0 -7
 - data/lib/candidhealth/expected_network_status/v_2/types/network_status_check_id.rb +0 -9
 - data/lib/candidhealth/guarantor/v_1/types/guarantor_id.rb +0 -9
 - data/lib/candidhealth/identifiers/types/identifier_id.rb +0 -7
 - data/lib/candidhealth/individual/types/individual_id.rb +0 -7
 - data/lib/candidhealth/insurance_adjudications/v_1/types/insurance_adjudication_id.rb +0 -9
 - data/lib/candidhealth/insurance_adjudications/v_1/types/service_line_adjudication_id.rb +0 -9
 - data/lib/candidhealth/insurance_cards/v_2/types/insurance_card_id.rb +0 -9
 - data/lib/candidhealth/insurance_payments/v_1/types/insurance_payment_id.rb +0 -9
 - data/lib/candidhealth/insurance_refunds/v_1/types/insurance_refund_id.rb +0 -9
 - data/lib/candidhealth/organization_providers/v_2/types/organization_provider_id.rb +0 -9
 - data/lib/candidhealth/organization_service_facilities/v_2/types/organization_service_facility_id.rb +0 -9
 - data/lib/candidhealth/patient_payments/v_3/types/patient_payment_id.rb +0 -9
 - data/lib/candidhealth/patient_payments/v_4/types/patient_payment_id.rb +0 -9
 - data/lib/candidhealth/patient_refunds/v_1/types/patient_refund_id.rb +0 -9
 - data/lib/candidhealth/payers/v_3/types/payer_id.rb +0 -9
 - data/lib/candidhealth/payers/v_3/types/payer_name.rb +0 -9
 - data/lib/candidhealth/payers/v_3/types/payer_uuid.rb +0 -9
 - data/lib/candidhealth/service_facility/types/service_facility_id.rb +0 -7
 - data/lib/candidhealth/tags/types/tag_id.rb +0 -7
 - data/lib/candidhealth/write_offs/v_1/types/write_off_id.rb +0 -9
 
| 
         @@ -3,19 +3,12 @@ 
     | 
|
| 
       3 
3 
     | 
    
         
             
            require_relative "../../../requests"
         
     | 
| 
       4 
4 
     | 
    
         
             
            require_relative "../../claims/types/claim_status"
         
     | 
| 
       5 
5 
     | 
    
         
             
            require_relative "types/encounter_sort_options"
         
     | 
| 
       6 
     | 
    
         
            -
            require_relative "../../commons/types/page_token"
         
     | 
| 
       7 
     | 
    
         
            -
            require_relative "../../commons/types/date"
         
     | 
| 
       8 
     | 
    
         
            -
            require_relative "../../commons/types/encounter_external_id"
         
     | 
| 
       9 
6 
     | 
    
         
             
            require "date"
         
     | 
| 
       10 
     | 
    
         
            -
            require_relative "../../tags/types/tag_id"
         
     | 
| 
       11 
     | 
    
         
            -
            require_relative "../../commons/types/work_queue_id"
         
     | 
| 
       12 
7 
     | 
    
         
             
            require_relative "types/billable_status_type"
         
     | 
| 
       13 
8 
     | 
    
         
             
            require_relative "types/responsible_party_type"
         
     | 
| 
       14 
9 
     | 
    
         
             
            require_relative "types/encounter_owner_of_next_action_type"
         
     | 
| 
       15 
10 
     | 
    
         
             
            require_relative "types/encounter_page"
         
     | 
| 
       16 
     | 
    
         
            -
            require_relative "../../commons/types/encounter_id"
         
     | 
| 
       17 
11 
     | 
    
         
             
            require_relative "types/encounter"
         
     | 
| 
       18 
     | 
    
         
            -
            require_relative "types/prior_authorization_number"
         
     | 
| 
       19 
12 
     | 
    
         
             
            require_relative "types/medication"
         
     | 
| 
       20 
13 
     | 
    
         
             
            require_relative "types/vitals"
         
     | 
| 
       21 
14 
     | 
    
         
             
            require_relative "types/intervention"
         
     | 
| 
         @@ -23,10 +16,14 @@ require_relative "../../commons/types/street_address_long_zip" 
     | 
|
| 
       23 
16 
     | 
    
         
             
            require_relative "types/synchronicity_type"
         
     | 
| 
       24 
17 
     | 
    
         
             
            require_relative "types/service_authorization_exception_code"
         
     | 
| 
       25 
18 
     | 
    
         
             
            require_relative "../../commons/types/delay_reason_code"
         
     | 
| 
      
 19 
     | 
    
         
            +
            require "ostruct"
         
     | 
| 
       26 
20 
     | 
    
         
             
            require_relative "../../individual/types/patient_create"
         
     | 
| 
       27 
21 
     | 
    
         
             
            require_relative "../../encounter_providers/v_2/types/billing_provider"
         
     | 
| 
       28 
22 
     | 
    
         
             
            require_relative "../../encounter_providers/v_2/types/rendering_provider"
         
     | 
| 
       29 
23 
     | 
    
         
             
            require_relative "../../encounter_providers/v_2/types/referring_provider"
         
     | 
| 
      
 24 
     | 
    
         
            +
            require_relative "../../encounter_providers/v_2/types/initial_referring_provider"
         
     | 
| 
      
 25 
     | 
    
         
            +
            require_relative "../../encounter_providers/v_2/types/supervising_provider"
         
     | 
| 
      
 26 
     | 
    
         
            +
            require_relative "../../encounter_providers/v_2/types/ordering_provider"
         
     | 
| 
       30 
27 
     | 
    
         
             
            require_relative "../../service_facility/types/encounter_service_facility_base"
         
     | 
| 
       31 
28 
     | 
    
         
             
            require_relative "../../individual/types/subscriber_create"
         
     | 
| 
       32 
29 
     | 
    
         
             
            require_relative "../../diagnoses/types/diagnosis_create"
         
     | 
| 
         @@ -37,48 +34,72 @@ require_relative "types/patient_history_category" 
     | 
|
| 
       37 
34 
     | 
    
         
             
            require_relative "../../service_lines/v_2/types/service_line_create"
         
     | 
| 
       38 
35 
     | 
    
         
             
            require_relative "../../guarantor/v_1/types/guarantor_create"
         
     | 
| 
       39 
36 
     | 
    
         
             
            require_relative "../../claim_submission/v_1/types/external_claim_submission_create"
         
     | 
| 
       40 
     | 
    
         
            -
            require_relative "../../diagnoses/types/diagnosis_id"
         
     | 
| 
       41 
37 
     | 
    
         
             
            require "async"
         
     | 
| 
       42 
38 
     | 
    
         | 
| 
       43 
39 
     | 
    
         
             
            module CandidApiClient
         
     | 
| 
       44 
40 
     | 
    
         
             
              module Encounters
         
     | 
| 
       45 
41 
     | 
    
         
             
                module V4
         
     | 
| 
       46 
42 
     | 
    
         
             
                  class V4Client
         
     | 
| 
      
 43 
     | 
    
         
            +
                    # @return [CandidApiClient::RequestClient]
         
     | 
| 
       47 
44 
     | 
    
         
             
                    attr_reader :request_client
         
     | 
| 
       48 
45 
     | 
    
         | 
| 
       49 
     | 
    
         
            -
                    # @param request_client [RequestClient]
         
     | 
| 
       50 
     | 
    
         
            -
                    # @return [Encounters::V4::V4Client]
         
     | 
| 
      
 46 
     | 
    
         
            +
                    # @param request_client [CandidApiClient::RequestClient]
         
     | 
| 
      
 47 
     | 
    
         
            +
                    # @return [CandidApiClient::Encounters::V4::V4Client]
         
     | 
| 
       51 
48 
     | 
    
         
             
                    def initialize(request_client:)
         
     | 
| 
       52 
     | 
    
         
            -
                      # @type [RequestClient]
         
     | 
| 
       53 
49 
     | 
    
         
             
                      @request_client = request_client
         
     | 
| 
       54 
50 
     | 
    
         
             
                    end
         
     | 
| 
       55 
51 
     | 
    
         | 
| 
       56 
52 
     | 
    
         
             
                    # @param limit [Integer] Maximum number of entities per page, defaults to 100.
         
     | 
| 
       57 
     | 
    
         
            -
                    # @param claim_status [Claims::ClaimStatus] Indicates the current status of an insurance claim within the billing process.
         
     | 
| 
       58 
     | 
    
         
            -
                    # @param sort [Encounters::V4::EncounterSortOptions] Defaults to created_at:desc.
         
     | 
| 
       59 
     | 
    
         
            -
                    # @param page_token [ 
     | 
| 
       60 
     | 
    
         
            -
                    # @param date_of_service_min [ 
     | 
| 
       61 
     | 
    
         
            -
                    # @param date_of_service_max [ 
     | 
| 
      
 53 
     | 
    
         
            +
                    # @param claim_status [CandidApiClient::Claims::Types::ClaimStatus] Indicates the current status of an insurance claim within the billing process.
         
     | 
| 
      
 54 
     | 
    
         
            +
                    # @param sort [CandidApiClient::Encounters::V4::Types::EncounterSortOptions] Defaults to created_at:desc.
         
     | 
| 
      
 55 
     | 
    
         
            +
                    # @param page_token [String]
         
     | 
| 
      
 56 
     | 
    
         
            +
                    # @param date_of_service_min [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-25.
         
     | 
| 
      
 57 
     | 
    
         
            +
                    # @param date_of_service_max [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-25.
         
     | 
| 
       62 
58 
     | 
    
         
             
                    # @param primary_payer_names [String] Comma delimited string.
         
     | 
| 
       63 
     | 
    
         
            -
                    # @param search_term [String] Filter by any of the following fields: encounter_id, claim_id, patient 
     | 
| 
       64 
     | 
    
         
            -
                    # 
     | 
| 
       65 
     | 
    
         
            -
                    # 
     | 
| 
       66 
     | 
    
         
            -
                    #  
     | 
| 
       67 
     | 
    
         
            -
                    # @param  
     | 
| 
       68 
     | 
    
         
            -
                    # @param  
     | 
| 
       69 
     | 
    
         
            -
                    # 
     | 
| 
       70 
     | 
    
         
            -
                    # @param  
     | 
| 
       71 
     | 
    
         
            -
                    # @param  
     | 
| 
       72 
     | 
    
         
            -
                    # @param  
     | 
| 
      
 59 
     | 
    
         
            +
                    # @param search_term [String] Filter by any of the following fields: encounter_id, claim_id, patient
         
     | 
| 
      
 60 
     | 
    
         
            +
                    #  external_id,
         
     | 
| 
      
 61 
     | 
    
         
            +
                    #  patient date of birth, patient first name, patient last name,
         
     | 
| 
      
 62 
     | 
    
         
            +
                    #  or encounter external id.
         
     | 
| 
      
 63 
     | 
    
         
            +
                    # @param external_id [String] Filter to an exact match on encounter external_id, if one exists.
         
     | 
| 
      
 64 
     | 
    
         
            +
                    # @param diagnoses_updated_since [DateTime] ISO 8601 timestamp; ideally in UTC (although not required):
         
     | 
| 
      
 65 
     | 
    
         
            +
                    #  2019-08-24T14:15:22Z.
         
     | 
| 
      
 66 
     | 
    
         
            +
                    # @param tag_ids [String] Filter by name of tags on encounters.
         
     | 
| 
      
 67 
     | 
    
         
            +
                    # @param work_queue_id [String]
         
     | 
| 
      
 68 
     | 
    
         
            +
                    # @param billable_status [CandidApiClient::Encounters::V4::Types::BillableStatusType] Defines if the Encounter is to be billed by Candid to the responsible_party.
         
     | 
| 
      
 69 
     | 
    
         
            +
                    #  Examples for when this should be set to NOT_BILLABLE include if the Encounter
         
     | 
| 
      
 70 
     | 
    
         
            +
                    #  has not occurred yet or if there is no intention of ever billing the
         
     | 
| 
      
 71 
     | 
    
         
            +
                    #  responsible_party.
         
     | 
| 
      
 72 
     | 
    
         
            +
                    # @param responsible_party [CandidApiClient::Encounters::V4::Types::ResponsiblePartyType] Defines the party to be billed with the initial balance owed on the claim. Use
         
     | 
| 
      
 73 
     | 
    
         
            +
                    #  SELF_PAY if you intend to bill self pay/cash pay.
         
     | 
| 
      
 74 
     | 
    
         
            +
                    # @param owner_of_next_action [CandidApiClient::Encounters::V4::Types::EncounterOwnerOfNextActionType] The party who is responsible for taking the next action on an Encounter, as
         
     | 
| 
      
 75 
     | 
    
         
            +
                    #  defined by ownership of open Tasks.
         
     | 
| 
       73 
76 
     | 
    
         
             
                    # @param patient_external_id [String] The patient ID from the external EMR platform for the patient
         
     | 
| 
       74 
     | 
    
         
            -
                    # @param request_options [RequestOptions]
         
     | 
| 
       75 
     | 
    
         
            -
                    # @return [Encounters::V4::EncounterPage]
         
     | 
| 
      
 77 
     | 
    
         
            +
                    # @param request_options [CandidApiClient::RequestOptions]
         
     | 
| 
      
 78 
     | 
    
         
            +
                    # @return [CandidApiClient::Encounters::V4::Types::EncounterPage]
         
     | 
| 
      
 79 
     | 
    
         
            +
                    # @example
         
     | 
| 
      
 80 
     | 
    
         
            +
                    #  api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
         
     | 
| 
      
 81 
     | 
    
         
            +
                    #  api.encounters.v_4.get_all(
         
     | 
| 
      
 82 
     | 
    
         
            +
                    #    limit: 100,
         
     | 
| 
      
 83 
     | 
    
         
            +
                    #    claim_status: BILLER_RECEIVED,
         
     | 
| 
      
 84 
     | 
    
         
            +
                    #    sort: CREATED_AT_ASC,
         
     | 
| 
      
 85 
     | 
    
         
            +
                    #    page_token: "eyJ0b2tlbiI6IjEiLCJwYWdlX3Rva2VuIjoiMiJ9",
         
     | 
| 
      
 86 
     | 
    
         
            +
                    #    date_of_service_min: DateTime.parse(2019-08-24),
         
     | 
| 
      
 87 
     | 
    
         
            +
                    #    date_of_service_max: DateTime.parse(2019-08-25),
         
     | 
| 
      
 88 
     | 
    
         
            +
                    #    primary_payer_names: "Medicare,Medicaid",
         
     | 
| 
      
 89 
     | 
    
         
            +
                    #    search_term: "doe",
         
     | 
| 
      
 90 
     | 
    
         
            +
                    #    external_id: "123456",
         
     | 
| 
      
 91 
     | 
    
         
            +
                    #    diagnoses_updated_since: DateTime.parse(2019-08-24T14:15:22.000Z)
         
     | 
| 
      
 92 
     | 
    
         
            +
                    #  )
         
     | 
| 
       76 
93 
     | 
    
         
             
                    def get_all(limit: nil, claim_status: nil, sort: nil, page_token: nil, date_of_service_min: nil,
         
     | 
| 
       77 
94 
     | 
    
         
             
                                date_of_service_max: nil, primary_payer_names: nil, search_term: nil, external_id: nil, diagnoses_updated_since: nil, tag_ids: nil, work_queue_id: nil, billable_status: nil, responsible_party: nil, owner_of_next_action: nil, patient_external_id: nil, request_options: nil)
         
     | 
| 
       78 
     | 
    
         
            -
                      response = @request_client.conn.get 
     | 
| 
      
 95 
     | 
    
         
            +
                      response = @request_client.conn.get do |req|
         
     | 
| 
       79 
96 
     | 
    
         
             
                        req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
         
     | 
| 
       80 
97 
     | 
    
         
             
                        req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
         
     | 
| 
       81 
     | 
    
         
            -
                        req.headers = { 
     | 
| 
      
 98 
     | 
    
         
            +
                        req.headers = {
         
     | 
| 
      
 99 
     | 
    
         
            +
                      **(req.headers || {}),
         
     | 
| 
      
 100 
     | 
    
         
            +
                      **@request_client.get_headers,
         
     | 
| 
      
 101 
     | 
    
         
            +
                      **(request_options&.additional_headers || {})
         
     | 
| 
      
 102 
     | 
    
         
            +
                        }.compact
         
     | 
| 
       82 
103 
     | 
    
         
             
                        req.params = {
         
     | 
| 
       83 
104 
     | 
    
         
             
                          **(request_options&.additional_query_parameters || {}),
         
     | 
| 
       84 
105 
     | 
    
         
             
                          "limit": limit,
         
     | 
| 
         @@ -98,133 +119,170 @@ module CandidApiClient 
     | 
|
| 
       98 
119 
     | 
    
         
             
                          "owner_of_next_action": owner_of_next_action,
         
     | 
| 
       99 
120 
     | 
    
         
             
                          "patient_external_id": patient_external_id
         
     | 
| 
       100 
121 
     | 
    
         
             
                        }.compact
         
     | 
| 
      
 122 
     | 
    
         
            +
                        req.url "#{@request_client.get_url(environment: CandidApi,
         
     | 
| 
      
 123 
     | 
    
         
            +
                                                           request_options: request_options)}/api/encounters/v4"
         
     | 
| 
       101 
124 
     | 
    
         
             
                      end
         
     | 
| 
       102 
     | 
    
         
            -
                      Encounters::V4::EncounterPage.from_json(json_object: response.body)
         
     | 
| 
      
 125 
     | 
    
         
            +
                      CandidApiClient::Encounters::V4::Types::EncounterPage.from_json(json_object: response.body)
         
     | 
| 
       103 
126 
     | 
    
         
             
                    end
         
     | 
| 
       104 
127 
     | 
    
         | 
| 
       105 
     | 
    
         
            -
                    # @param encounter_id [ 
     | 
| 
       106 
     | 
    
         
            -
                    # @param request_options [RequestOptions]
         
     | 
| 
       107 
     | 
    
         
            -
                    # @return [Encounters::V4::Encounter]
         
     | 
| 
      
 128 
     | 
    
         
            +
                    # @param encounter_id [String]
         
     | 
| 
      
 129 
     | 
    
         
            +
                    # @param request_options [CandidApiClient::RequestOptions]
         
     | 
| 
      
 130 
     | 
    
         
            +
                    # @return [CandidApiClient::Encounters::V4::Types::Encounter]
         
     | 
| 
      
 131 
     | 
    
         
            +
                    # @example
         
     | 
| 
      
 132 
     | 
    
         
            +
                    #  api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
         
     | 
| 
      
 133 
     | 
    
         
            +
                    #  api.encounters.v_4.get(encounter_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32")
         
     | 
| 
       108 
134 
     | 
    
         
             
                    def get(encounter_id:, request_options: nil)
         
     | 
| 
       109 
     | 
    
         
            -
                      response = @request_client.conn.get 
     | 
| 
      
 135 
     | 
    
         
            +
                      response = @request_client.conn.get do |req|
         
     | 
| 
       110 
136 
     | 
    
         
             
                        req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
         
     | 
| 
       111 
137 
     | 
    
         
             
                        req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
         
     | 
| 
       112 
     | 
    
         
            -
                        req.headers = { 
     | 
| 
      
 138 
     | 
    
         
            +
                        req.headers = {
         
     | 
| 
      
 139 
     | 
    
         
            +
                      **(req.headers || {}),
         
     | 
| 
      
 140 
     | 
    
         
            +
                      **@request_client.get_headers,
         
     | 
| 
      
 141 
     | 
    
         
            +
                      **(request_options&.additional_headers || {})
         
     | 
| 
      
 142 
     | 
    
         
            +
                        }.compact
         
     | 
| 
      
 143 
     | 
    
         
            +
                        req.url "#{@request_client.get_url(environment: CandidApi,
         
     | 
| 
      
 144 
     | 
    
         
            +
                                                           request_options: request_options)}/api/encounters/v4/#{encounter_id}"
         
     | 
| 
       113 
145 
     | 
    
         
             
                      end
         
     | 
| 
       114 
     | 
    
         
            -
                      Encounters::V4::Encounter.from_json(json_object: response.body)
         
     | 
| 
      
 146 
     | 
    
         
            +
                      CandidApiClient::Encounters::V4::Types::Encounter.from_json(json_object: response.body)
         
     | 
| 
       115 
147 
     | 
    
         
             
                    end
         
     | 
| 
       116 
148 
     | 
    
         | 
| 
       117 
     | 
    
         
            -
                    # @param external_id [ 
     | 
| 
       118 
     | 
    
         
            -
                    # 
     | 
| 
       119 
     | 
    
         
            -
                    # 
     | 
| 
       120 
     | 
    
         
            -
                    # @param prior_authorization_number [ 
     | 
| 
      
 149 
     | 
    
         
            +
                    # @param external_id [String] A client-specified unique ID to associate with this encounter;
         
     | 
| 
      
 150 
     | 
    
         
            +
                    #  for example, your internal encounter ID or a Dr. Chrono encounter ID.
         
     | 
| 
      
 151 
     | 
    
         
            +
                    #  This field should not contain PHI.
         
     | 
| 
      
 152 
     | 
    
         
            +
                    # @param prior_authorization_number [String] Box 23 on the CMS-1500 claim form.
         
     | 
| 
       121 
153 
     | 
    
         
             
                    # @param patient_authorized_release [Boolean] Whether this patient has authorized the release of medical information
         
     | 
| 
       122 
     | 
    
         
            -
                    # 
     | 
| 
       123 
     | 
    
         
            -
                    # 
     | 
| 
      
 154 
     | 
    
         
            +
                    #  for billing purpose.
         
     | 
| 
      
 155 
     | 
    
         
            +
                    #  Box 12 on the CMS-1500 claim form.
         
     | 
| 
       124 
156 
     | 
    
         
             
                    # @param benefits_assigned_to_provider [Boolean] Whether this patient has authorized insurance payments to be made to you,
         
     | 
| 
       125 
     | 
    
         
            -
                    # 
     | 
| 
       126 
     | 
    
         
            -
                    # 
     | 
| 
      
 157 
     | 
    
         
            +
                    #  not them. If false, patient may receive reimbursement.
         
     | 
| 
      
 158 
     | 
    
         
            +
                    #  Box 13 on the CMS-1500 claim form.
         
     | 
| 
       127 
159 
     | 
    
         
             
                    # @param provider_accepts_assignment [Boolean] Whether you have accepted the patient's authorization for insurance payments
         
     | 
| 
       128 
     | 
    
         
            -
                    # 
     | 
| 
       129 
     | 
    
         
            -
                    # 
     | 
| 
       130 
     | 
    
         
            -
                    # @param appointment_type [String] Human-readable description of the appointment type (ex: "Acupuncture - 
     | 
| 
       131 
     | 
    
         
            -
                    # 
     | 
| 
      
 160 
     | 
    
         
            +
                    #  to be made to you, not them.
         
     | 
| 
      
 161 
     | 
    
         
            +
                    #  Box 27 on the CMS-1500 claim form.
         
     | 
| 
      
 162 
     | 
    
         
            +
                    # @param appointment_type [String] Human-readable description of the appointment type (ex: "Acupuncture -
         
     | 
| 
      
 163 
     | 
    
         
            +
                    #  Headaches").
         
     | 
| 
      
 164 
     | 
    
         
            +
                    # @param existing_medications [Array<Hash>] Request of type Array<CandidApiClient::Encounters::V4::Types::Medication>, as a Hash
         
     | 
| 
       132 
165 
     | 
    
         
             
                    #   * :name (String)
         
     | 
| 
       133 
     | 
    
         
            -
                    #   * :rx_cui ( 
     | 
| 
      
 166 
     | 
    
         
            +
                    #   * :rx_cui (String)
         
     | 
| 
       134 
167 
     | 
    
         
             
                    #   * :dosage (String)
         
     | 
| 
       135 
168 
     | 
    
         
             
                    #   * :dosage_form (String)
         
     | 
| 
       136 
169 
     | 
    
         
             
                    #   * :frequency (String)
         
     | 
| 
       137 
170 
     | 
    
         
             
                    #   * :as_needed (Boolean)
         
     | 
| 
       138 
     | 
    
         
            -
                    # @param vitals [Hash] Request of type Encounters::V4::Vitals, as a Hash
         
     | 
| 
      
 171 
     | 
    
         
            +
                    # @param vitals [Hash] Request of type CandidApiClient::Encounters::V4::Types::Vitals, as a Hash
         
     | 
| 
       139 
172 
     | 
    
         
             
                    #   * :height_in (Integer)
         
     | 
| 
       140 
173 
     | 
    
         
             
                    #   * :weight_lbs (Integer)
         
     | 
| 
       141 
174 
     | 
    
         
             
                    #   * :blood_pressure_systolic_mmhg (Integer)
         
     | 
| 
       142 
175 
     | 
    
         
             
                    #   * :blood_pressure_diastolic_mmhg (Integer)
         
     | 
| 
       143 
176 
     | 
    
         
             
                    #   * :body_temperature_f (Float)
         
     | 
| 
       144 
     | 
    
         
            -
                    # @param interventions [Array<Hash>] Request of type Array<Encounters::V4::Intervention>, as a Hash
         
     | 
| 
      
 177 
     | 
    
         
            +
                    # @param interventions [Array<Hash>] Request of type Array<CandidApiClient::Encounters::V4::Types::Intervention>, as a Hash
         
     | 
| 
       145 
178 
     | 
    
         
             
                    #   * :name (String)
         
     | 
| 
       146 
     | 
    
         
            -
                    #   * :category (Encounters::V4::InterventionCategory)
         
     | 
| 
      
 179 
     | 
    
         
            +
                    #   * :category (CandidApiClient::Encounters::V4::Types::InterventionCategory)
         
     | 
| 
       147 
180 
     | 
    
         
             
                    #   * :description (String)
         
     | 
| 
       148 
181 
     | 
    
         
             
                    #   * :medication (Hash)
         
     | 
| 
       149 
182 
     | 
    
         
             
                    #     * :name (String)
         
     | 
| 
       150 
     | 
    
         
            -
                    #     * :rx_cui ( 
     | 
| 
      
 183 
     | 
    
         
            +
                    #     * :rx_cui (String)
         
     | 
| 
       151 
184 
     | 
    
         
             
                    #     * :dosage (String)
         
     | 
| 
       152 
185 
     | 
    
         
             
                    #     * :dosage_form (String)
         
     | 
| 
       153 
186 
     | 
    
         
             
                    #     * :frequency (String)
         
     | 
| 
       154 
187 
     | 
    
         
             
                    #     * :as_needed (Boolean)
         
     | 
| 
       155 
     | 
    
         
            -
                    #   * :labs (Array<Encounters::V4::Lab>)
         
     | 
| 
       156 
     | 
    
         
            -
                    # @param pay_to_address [Hash] Specifies the address to which payments for the claim should be sent.Request of type Commons::StreetAddressLongZip, as a Hash
         
     | 
| 
      
 188 
     | 
    
         
            +
                    #   * :labs (Array<CandidApiClient::Encounters::V4::Types::Lab>)
         
     | 
| 
      
 189 
     | 
    
         
            +
                    # @param pay_to_address [Hash] Specifies the address to which payments for the claim should be sent.Request of type CandidApiClient::Commons::Types::StreetAddressLongZip, as a Hash
         
     | 
| 
       157 
190 
     | 
    
         
             
                    #   * :zip_plus_four_code (String)
         
     | 
| 
       158 
191 
     | 
    
         
             
                    #   * :address_1 (String)
         
     | 
| 
       159 
192 
     | 
    
         
             
                    #   * :address_2 (String)
         
     | 
| 
       160 
193 
     | 
    
         
             
                    #   * :city (String)
         
     | 
| 
       161 
     | 
    
         
            -
                    #   * :state (Commons::State)
         
     | 
| 
      
 194 
     | 
    
         
            +
                    #   * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       162 
195 
     | 
    
         
             
                    #   * :zip_code (String)
         
     | 
| 
       163 
     | 
    
         
            -
                    # @param synchronicity [Encounters::V4::SynchronicityType] Whether or not this was a synchronous or asynchronous encounter.
         
     | 
| 
       164 
     | 
    
         
            -
                    # 
     | 
| 
       165 
     | 
    
         
            -
                    # 
     | 
| 
       166 
     | 
    
         
            -
                    # 
     | 
| 
       167 
     | 
    
         
            -
                    # 
     | 
| 
       168 
     | 
    
         
            -
                    # 
     | 
| 
       169 
     | 
    
         
            -
                    # 
     | 
| 
       170 
     | 
    
         
            -
                    # 
     | 
| 
       171 
     | 
    
         
            -
                    #  
     | 
| 
      
 196 
     | 
    
         
            +
                    # @param synchronicity [CandidApiClient::Encounters::V4::Types::SynchronicityType] Whether or not this was a synchronous or asynchronous encounter.
         
     | 
| 
      
 197 
     | 
    
         
            +
                    #  Asynchronous encounters occur when providers and patients communicate online
         
     | 
| 
      
 198 
     | 
    
         
            +
                    #  using
         
     | 
| 
      
 199 
     | 
    
         
            +
                    #  forms, instant messaging, or other pre-recorded digital mediums.
         
     | 
| 
      
 200 
     | 
    
         
            +
                    #  Synchronous encounters occur in live, real-time settings where the patient
         
     | 
| 
      
 201 
     | 
    
         
            +
                    #  interacts
         
     | 
| 
      
 202 
     | 
    
         
            +
                    #  directly with the provider, such as over video or a phone call.
         
     | 
| 
      
 203 
     | 
    
         
            +
                    # @param billable_status [CandidApiClient::Encounters::V4::Types::BillableStatusType] Defines if the Encounter is to be billed by Candid to the responsible_party.
         
     | 
| 
      
 204 
     | 
    
         
            +
                    #  Examples for when this should be set to NOT_BILLABLE include
         
     | 
| 
      
 205 
     | 
    
         
            +
                    #  if the Encounter has not occurred yet or if there is no intention of ever
         
     | 
| 
      
 206 
     | 
    
         
            +
                    #  billing the responsible_party.
         
     | 
| 
      
 207 
     | 
    
         
            +
                    # @param responsible_party [CandidApiClient::Encounters::V4::Types::ResponsiblePartyType] Defines the party to be billed with the initial balance owed on the claim.
         
     | 
| 
       172 
208 
     | 
    
         
             
                    # @param additional_information [String] Defines additional information on the claim needed by the payer.
         
     | 
| 
       173 
     | 
    
         
            -
                    # 
     | 
| 
       174 
     | 
    
         
            -
                    # @param service_authorization_exception_code [Encounters::V4::ServiceAuthorizationExceptionCode] 837p Loop2300 REF\*4N
         
     | 
| 
       175 
     | 
    
         
            -
                    # 
     | 
| 
       176 
     | 
    
         
            -
                    # 
     | 
| 
       177 
     | 
    
         
            -
                    # 
     | 
| 
       178 
     | 
    
         
            -
                    #  
     | 
| 
       179 
     | 
    
         
            -
                    # 
     | 
| 
       180 
     | 
    
         
            -
                    # 
     | 
| 
       181 
     | 
    
         
            -
                    # 
     | 
| 
       182 
     | 
    
         
            -
                    #  
     | 
| 
       183 
     | 
    
         
            -
                    # 
     | 
| 
       184 
     | 
    
         
            -
                    #  
     | 
| 
       185 
     | 
    
         
            -
                    # 
     | 
| 
       186 
     | 
    
         
            -
                    # 
     | 
| 
       187 
     | 
    
         
            -
                    # 
     | 
| 
       188 
     | 
    
         
            -
                    # @param  
     | 
| 
       189 
     | 
    
         
            -
                    # 
     | 
| 
       190 
     | 
    
         
            -
                    #  
     | 
| 
       191 
     | 
    
         
            -
                    # 
     | 
| 
      
 209 
     | 
    
         
            +
                    #  Box 19 on the CMS-1500 claim form.
         
     | 
| 
      
 210 
     | 
    
         
            +
                    # @param service_authorization_exception_code [CandidApiClient::Encounters::V4::Types::ServiceAuthorizationExceptionCode] 837p Loop2300 REF\*4N
         
     | 
| 
      
 211 
     | 
    
         
            +
                    #  Required when mandated by government law or regulation to obtain authorization
         
     | 
| 
      
 212 
     | 
    
         
            +
                    #  for specific service(s) but, for the
         
     | 
| 
      
 213 
     | 
    
         
            +
                    #  reasons listed in one of the enum values of ServiceAuthorizationExceptionCode,
         
     | 
| 
      
 214 
     | 
    
         
            +
                    #  the service was performed without
         
     | 
| 
      
 215 
     | 
    
         
            +
                    #  obtaining the authorization.
         
     | 
| 
      
 216 
     | 
    
         
            +
                    # @param admission_date [Date] 837p Loop2300 DTP\*435, CMS-1500 Box 18
         
     | 
| 
      
 217 
     | 
    
         
            +
                    #  Required on all ambulance claims when the patient was known to be admitted to
         
     | 
| 
      
 218 
     | 
    
         
            +
                    #  the hospital.
         
     | 
| 
      
 219 
     | 
    
         
            +
                    #  OR
         
     | 
| 
      
 220 
     | 
    
         
            +
                    #  Required on all claims involving inpatient medical visits.
         
     | 
| 
      
 221 
     | 
    
         
            +
                    # @param discharge_date [Date] 837p Loop2300 DTP\*096, CMS-1500 Box 18
         
     | 
| 
      
 222 
     | 
    
         
            +
                    #  Required for inpatient claims when the patient was discharged from the facility
         
     | 
| 
      
 223 
     | 
    
         
            +
                    #  and the discharge date is known.
         
     | 
| 
      
 224 
     | 
    
         
            +
                    # @param onset_of_current_illness_or_symptom_date [Date] 837p Loop2300 DTP\*431, CMS-1500 Box 14
         
     | 
| 
      
 225 
     | 
    
         
            +
                    #  Required for the initial medical service or visit performed in response to a
         
     | 
| 
      
 226 
     | 
    
         
            +
                    #  medical emergency when the date is available and is different than the date of
         
     | 
| 
      
 227 
     | 
    
         
            +
                    #  service.
         
     | 
| 
      
 228 
     | 
    
         
            +
                    #  OR
         
     | 
| 
      
 229 
     | 
    
         
            +
                    #  This date is the onset of acute symptoms for the current illness or condition.
         
     | 
| 
      
 230 
     | 
    
         
            +
                    # @param last_menstrual_period_date [Date] 837p Loop2300 DTP\*484, CMS-1500 Box 14
         
     | 
| 
      
 231 
     | 
    
         
            +
                    #  Required when, in the judgment of the provider, the services on this claim are
         
     | 
| 
      
 232 
     | 
    
         
            +
                    #  related to the patient's pregnancy.
         
     | 
| 
      
 233 
     | 
    
         
            +
                    # @param delay_reason_code [CandidApiClient::Commons::Types::DelayReasonCode] 837i Loop2300, CLM-1300 Box 20
         
     | 
| 
      
 234 
     | 
    
         
            +
                    #  Code indicating the reason why a request was delayed
         
     | 
| 
       192 
235 
     | 
    
         
             
                    # @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
         
     | 
| 
       193 
     | 
    
         
            -
                    # @param  
     | 
| 
       194 
     | 
    
         
            -
                    # 
     | 
| 
       195 
     | 
    
         
            -
                    # 
     | 
| 
       196 
     | 
    
         
            -
                    # 
     | 
| 
       197 
     | 
    
         
            -
                    # 
     | 
| 
       198 
     | 
    
         
            -
                    # 
     | 
| 
       199 
     | 
    
         
            -
                    #  
     | 
| 
       200 
     | 
    
         
            -
                    # 
     | 
| 
       201 
     | 
    
         
            -
                    # 
     | 
| 
       202 
     | 
    
         
            -
                    # 
     | 
| 
       203 
     | 
    
         
            -
                    # 
     | 
| 
       204 
     | 
    
         
            -
                    #  
     | 
| 
       205 
     | 
    
         
            -
                    # 
     | 
| 
      
 236 
     | 
    
         
            +
                    # @param _field_set [Object]
         
     | 
| 
      
 237 
     | 
    
         
            +
                    # @param date_of_service [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-24.
         
     | 
| 
      
 238 
     | 
    
         
            +
                    #  This date must be the local date in the timezone where the service occurred.
         
     | 
| 
      
 239 
     | 
    
         
            +
                    #  Box 24a on the CMS-1500 claim form.
         
     | 
| 
      
 240 
     | 
    
         
            +
                    #  If service occurred over a range of dates, this should be the start date.
         
     | 
| 
      
 241 
     | 
    
         
            +
                    #  date_of_service must be defined on either the encounter or the service lines but
         
     | 
| 
      
 242 
     | 
    
         
            +
                    #  not both.
         
     | 
| 
      
 243 
     | 
    
         
            +
                    #  If there are greater than zero service lines, it is recommended to specify
         
     | 
| 
      
 244 
     | 
    
         
            +
                    #  date_of_service on the service_line instead of on the encounter to prepare for
         
     | 
| 
      
 245 
     | 
    
         
            +
                    #  future API versions.
         
     | 
| 
      
 246 
     | 
    
         
            +
                    # @param end_date_of_service [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-25.
         
     | 
| 
      
 247 
     | 
    
         
            +
                    #  This date must be the local date in the timezone where the service occurred.
         
     | 
| 
      
 248 
     | 
    
         
            +
                    #  If omitted, the Encounter is assumed to be for a single day.
         
     | 
| 
      
 249 
     | 
    
         
            +
                    #  Must not be temporally before the date_of_service field.
         
     | 
| 
      
 250 
     | 
    
         
            +
                    #  If there are greater than zero service lines, it is recommended to specify
         
     | 
| 
      
 251 
     | 
    
         
            +
                    #  end_date_of_service on the service_line instead of on the encounter to prepare
         
     | 
| 
      
 252 
     | 
    
         
            +
                    #  for future API versions.
         
     | 
| 
      
 253 
     | 
    
         
            +
                    # @param patient [Hash] Contains the identification information of the individual receiving medical
         
     | 
| 
      
 254 
     | 
    
         
            +
                    #  services.Request of type CandidApiClient::Individual::Types::PatientCreate, as a Hash
         
     | 
| 
      
 255 
     | 
    
         
            +
                    #   * :phone_numbers (Array<CandidApiClient::Commons::Types::PhoneNumber>)
         
     | 
| 
       206 
256 
     | 
    
         
             
                    #   * :phone_consent (Boolean)
         
     | 
| 
       207 
     | 
    
         
            -
                    #   * :email ( 
     | 
| 
      
 257 
     | 
    
         
            +
                    #   * :email (String)
         
     | 
| 
       208 
258 
     | 
    
         
             
                    #   * :email_consent (Boolean)
         
     | 
| 
       209 
259 
     | 
    
         
             
                    #   * :external_id (String)
         
     | 
| 
       210 
     | 
    
         
            -
                    #   * :date_of_birth ( 
     | 
| 
      
 260 
     | 
    
         
            +
                    #   * :date_of_birth (Date)
         
     | 
| 
       211 
261 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       212 
262 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       213 
263 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       214 
264 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       215 
265 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       216 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 266 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       217 
267 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       218 
268 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       219 
269 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       220 
     | 
    
         
            -
                    #   * :gender (Individual::Gender)
         
     | 
| 
       221 
     | 
    
         
            -
                    # @param billing_provider [Hash] The billing provider is the provider or business entity submitting the claim. 
     | 
| 
      
 270 
     | 
    
         
            +
                    #   * :gender (CandidApiClient::Individual::Types::Gender)
         
     | 
| 
      
 271 
     | 
    
         
            +
                    # @param billing_provider [Hash] The billing provider is the provider or business entity submitting the claim.
         
     | 
| 
      
 272 
     | 
    
         
            +
                    #  Billing provider may be, but is not necessarily, the same person/NPI as the
         
     | 
| 
      
 273 
     | 
    
         
            +
                    #  rendering provider. From a payer's perspective, this represents the person or
         
     | 
| 
      
 274 
     | 
    
         
            +
                    #  entity being reimbursed. When a contract exists with the target payer, the
         
     | 
| 
      
 275 
     | 
    
         
            +
                    #  billing provider should be the entity contracted with the payer. In some
         
     | 
| 
      
 276 
     | 
    
         
            +
                    #  circumstances, this will be an individual provider. In that case, submit that
         
     | 
| 
      
 277 
     | 
    
         
            +
                    #  provider's NPI and the tax ID (TIN) that the provider gave to the payer during
         
     | 
| 
      
 278 
     | 
    
         
            +
                    #  contracting. In other cases, the billing entity will be a medical group. If so,
         
     | 
| 
      
 279 
     | 
    
         
            +
                    #  submit the group NPI and the group's tax ID. Box 33 on the CMS-1500 claim form.Request of type CandidApiClient::EncounterProviders::V2::Types::BillingProvider, as a Hash
         
     | 
| 
       222 
280 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       223 
281 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       224 
282 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       225 
283 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       226 
284 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       227 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 285 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       228 
286 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       229 
287 
     | 
    
         
             
                    #   * :tax_id (String)
         
     | 
| 
       230 
288 
     | 
    
         
             
                    #   * :npi (String)
         
     | 
| 
         @@ -232,25 +290,77 @@ module CandidApiClient 
     | 
|
| 
       232 
290 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       233 
291 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       234 
292 
     | 
    
         
             
                    #   * :organization_name (String)
         
     | 
| 
       235 
     | 
    
         
            -
                    # @param rendering_provider [Hash] The rendering provider is the practitioner -- physician, nurse practitioner, 
     | 
| 
       236 
     | 
    
         
            -
                    # 
     | 
| 
      
 293 
     | 
    
         
            +
                    # @param rendering_provider [Hash] The rendering provider is the practitioner -- physician, nurse practitioner,
         
     | 
| 
      
 294 
     | 
    
         
            +
                    #  etc. -- performing the service.
         
     | 
| 
      
 295 
     | 
    
         
            +
                    #  For telehealth services, the rendering provider performs the visit, asynchronous
         
     | 
| 
      
 296 
     | 
    
         
            +
                    #  communication, or other service. The rendering provider address should generally
         
     | 
| 
      
 297 
     | 
    
         
            +
                    #  be the same as the service facility address.Request of type CandidApiClient::EncounterProviders::V2::Types::RenderingProvider, as a Hash
         
     | 
| 
      
 298 
     | 
    
         
            +
                    #   * :address (Hash)
         
     | 
| 
      
 299 
     | 
    
         
            +
                    #     * :zip_plus_four_code (String)
         
     | 
| 
      
 300 
     | 
    
         
            +
                    #     * :address_1 (String)
         
     | 
| 
      
 301 
     | 
    
         
            +
                    #     * :address_2 (String)
         
     | 
| 
      
 302 
     | 
    
         
            +
                    #     * :city (String)
         
     | 
| 
      
 303 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 304 
     | 
    
         
            +
                    #     * :zip_code (String)
         
     | 
| 
      
 305 
     | 
    
         
            +
                    #   * :npi (String)
         
     | 
| 
      
 306 
     | 
    
         
            +
                    #   * :taxonomy_code (String)
         
     | 
| 
      
 307 
     | 
    
         
            +
                    #   * :first_name (String)
         
     | 
| 
      
 308 
     | 
    
         
            +
                    #   * :last_name (String)
         
     | 
| 
      
 309 
     | 
    
         
            +
                    #   * :organization_name (String)
         
     | 
| 
      
 310 
     | 
    
         
            +
                    # @param referring_provider [Hash] The final provider who referred the services that were rendered.
         
     | 
| 
      
 311 
     | 
    
         
            +
                    #  All physicians who order services or refer Medicare beneficiaries must
         
     | 
| 
      
 312 
     | 
    
         
            +
                    #  report this data.Request of type CandidApiClient::EncounterProviders::V2::Types::ReferringProvider, as a Hash
         
     | 
| 
      
 313 
     | 
    
         
            +
                    #   * :npi (String)
         
     | 
| 
      
 314 
     | 
    
         
            +
                    #   * :taxonomy_code (String)
         
     | 
| 
      
 315 
     | 
    
         
            +
                    #   * :address (Hash)
         
     | 
| 
      
 316 
     | 
    
         
            +
                    #     * :zip_plus_four_code (String)
         
     | 
| 
      
 317 
     | 
    
         
            +
                    #     * :address_1 (String)
         
     | 
| 
      
 318 
     | 
    
         
            +
                    #     * :address_2 (String)
         
     | 
| 
      
 319 
     | 
    
         
            +
                    #     * :city (String)
         
     | 
| 
      
 320 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 321 
     | 
    
         
            +
                    #     * :zip_code (String)
         
     | 
| 
      
 322 
     | 
    
         
            +
                    #   * :first_name (String)
         
     | 
| 
      
 323 
     | 
    
         
            +
                    #   * :last_name (String)
         
     | 
| 
      
 324 
     | 
    
         
            +
                    #   * :organization_name (String)
         
     | 
| 
      
 325 
     | 
    
         
            +
                    # @param initial_referring_provider [Hash] The second iteration of Loop ID-2310. Use code "P3 - Primary Care Provider" in
         
     | 
| 
      
 326 
     | 
    
         
            +
                    #  this loop to
         
     | 
| 
      
 327 
     | 
    
         
            +
                    #  indicate the initial referral from the primary care provider or whatever
         
     | 
| 
      
 328 
     | 
    
         
            +
                    #  provider wrote the initial referral for this patient's episode of care being
         
     | 
| 
      
 329 
     | 
    
         
            +
                    #  billed/reported in this transaction.
         
     | 
| 
      
 330 
     | 
    
         
            +
                    #  Information in Loop ID-2310 applies to the entire claim unless overridden on a
         
     | 
| 
      
 331 
     | 
    
         
            +
                    #  service line by the presence of Loop ID-2420 with the same value in NM101.Request of type CandidApiClient::EncounterProviders::V2::Types::InitialReferringProvider, as a Hash
         
     | 
| 
      
 332 
     | 
    
         
            +
                    #   * :npi (String)
         
     | 
| 
      
 333 
     | 
    
         
            +
                    #   * :taxonomy_code (String)
         
     | 
| 
       237 
334 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       238 
335 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       239 
336 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       240 
337 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       241 
338 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       242 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 339 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       243 
340 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
      
 341 
     | 
    
         
            +
                    #   * :qualifier (CandidApiClient::Commons::Types::QualifierCode)
         
     | 
| 
      
 342 
     | 
    
         
            +
                    #   * :first_name (String)
         
     | 
| 
      
 343 
     | 
    
         
            +
                    #   * :last_name (String)
         
     | 
| 
      
 344 
     | 
    
         
            +
                    #   * :organization_name (String)
         
     | 
| 
      
 345 
     | 
    
         
            +
                    # @param supervising_provider [Hash] Required when the rendering provider is supervised by a physician. If not
         
     | 
| 
      
 346 
     | 
    
         
            +
                    #  required by this implementation guide, do not send.
         
     | 
| 
      
 347 
     | 
    
         
            +
                    #  Information in Loop ID-2310 applies to the entire claim unless overridden on a
         
     | 
| 
      
 348 
     | 
    
         
            +
                    #  service line by the presence of Loop ID-2420 with the same value in NM101.Request of type CandidApiClient::EncounterProviders::V2::Types::SupervisingProvider, as a Hash
         
     | 
| 
       244 
349 
     | 
    
         
             
                    #   * :npi (String)
         
     | 
| 
       245 
350 
     | 
    
         
             
                    #   * :taxonomy_code (String)
         
     | 
| 
      
 351 
     | 
    
         
            +
                    #   * :address (Hash)
         
     | 
| 
      
 352 
     | 
    
         
            +
                    #     * :zip_plus_four_code (String)
         
     | 
| 
      
 353 
     | 
    
         
            +
                    #     * :address_1 (String)
         
     | 
| 
      
 354 
     | 
    
         
            +
                    #     * :address_2 (String)
         
     | 
| 
      
 355 
     | 
    
         
            +
                    #     * :city (String)
         
     | 
| 
      
 356 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 357 
     | 
    
         
            +
                    #     * :zip_code (String)
         
     | 
| 
       246 
358 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       247 
359 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       248 
360 
     | 
    
         
             
                    #   * :organization_name (String)
         
     | 
| 
       249 
     | 
    
         
            -
                    # @param  
     | 
| 
       250 
     | 
    
         
            -
                    # 
     | 
| 
       251 
     | 
    
         
            -
                    # 
     | 
| 
       252 
     | 
    
         
            -
                    #   If a claim involves multiple referring physicians, create a separate
         
     | 
| 
       253 
     | 
    
         
            -
                    #   encounter for each physician.Request of type EncounterProviders::V2::ReferringProvider, as a Hash
         
     | 
| 
      
 361 
     | 
    
         
            +
                    # @param ordering_provider [Hash] Required when the service or supply was ordered by a provider who is different
         
     | 
| 
      
 362 
     | 
    
         
            +
                    #  than the rendering provider for this service line.
         
     | 
| 
      
 363 
     | 
    
         
            +
                    #  If not required by this implementation guide, do not send.Request of type CandidApiClient::EncounterProviders::V2::Types::OrderingProvider, as a Hash
         
     | 
| 
       254 
364 
     | 
    
         
             
                    #   * :npi (String)
         
     | 
| 
       255 
365 
     | 
    
         
             
                    #   * :taxonomy_code (String)
         
     | 
| 
       256 
366 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
         @@ -258,12 +368,20 @@ module CandidApiClient 
     | 
|
| 
       258 
368 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       259 
369 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       260 
370 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       261 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 371 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       262 
372 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       263 
373 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       264 
374 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       265 
375 
     | 
    
         
             
                    #   * :organization_name (String)
         
     | 
| 
       266 
     | 
    
         
            -
                    # @param service_facility [Hash] Encounter Service facility is typically the location a medical service was 
     | 
| 
      
 376 
     | 
    
         
            +
                    # @param service_facility [Hash] Encounter Service facility is typically the location a medical service was
         
     | 
| 
      
 377 
     | 
    
         
            +
                    #  rendered, such as a provider office or hospital. For telehealth, service
         
     | 
| 
      
 378 
     | 
    
         
            +
                    #  facility can represent the provider's location when the service was delivered
         
     | 
| 
      
 379 
     | 
    
         
            +
                    #  (e.g., home), or the location where an in-person visit would have taken place,
         
     | 
| 
      
 380 
     | 
    
         
            +
                    #  whichever is easier to identify. If the provider is in-network, service facility
         
     | 
| 
      
 381 
     | 
    
         
            +
                    #  may be defined in payer contracts. Box 32 on the CMS-1500 claim form. Note that
         
     | 
| 
      
 382 
     | 
    
         
            +
                    #  for an in-network claim to be successfully adjudicated, the service facility
         
     | 
| 
      
 383 
     | 
    
         
            +
                    #  address listed on claims must match what was provided to the payer during the
         
     | 
| 
      
 384 
     | 
    
         
            +
                    #  credentialing process.Request of type CandidApiClient::ServiceFacility::Types::EncounterServiceFacilityBase, as a Hash
         
     | 
| 
       267 
385 
     | 
    
         
             
                    #   * :organization_name (String)
         
     | 
| 
       268 
386 
     | 
    
         
             
                    #   * :npi (String)
         
     | 
| 
       269 
387 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
         @@ -271,12 +389,16 @@ module CandidApiClient 
     | 
|
| 
       271 
389 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       272 
390 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       273 
391 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       274 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 392 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       275 
393 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       276 
     | 
    
         
            -
                    # @param subscriber_primary [Hash] Subscriber_primary is required when responsible_party is INSURANCE_PAY (i.e. 
     | 
| 
       277 
     | 
    
         
            -
                    # 
     | 
| 
       278 
     | 
    
         
            -
                    # 
     | 
| 
       279 
     | 
    
         
            -
                    # 
     | 
| 
      
 394 
     | 
    
         
            +
                    # @param subscriber_primary [Hash] Subscriber_primary is required when responsible_party is INSURANCE_PAY (i.e.
         
     | 
| 
      
 395 
     | 
    
         
            +
                    #  when the claim should be billed to insurance).
         
     | 
| 
      
 396 
     | 
    
         
            +
                    #  These are not required fields when responsible_party is SELF_PAY (i.e. when the
         
     | 
| 
      
 397 
     | 
    
         
            +
                    #  claim should be billed to the patient).
         
     | 
| 
      
 398 
     | 
    
         
            +
                    #  However, if you collect this for patients, even self-pay, we recommend including
         
     | 
| 
      
 399 
     | 
    
         
            +
                    #  it when sending encounters to Candid.
         
     | 
| 
      
 400 
     | 
    
         
            +
                    #  Note: Cash Pay is no longer a valid payer_id in v4, please use responsible party
         
     | 
| 
      
 401 
     | 
    
         
            +
                    #  to define self-pay claims.Request of type CandidApiClient::Individual::Types::SubscriberCreate, as a Hash
         
     | 
| 
       280 
402 
     | 
    
         
             
                    #   * :insurance_card (Hash)
         
     | 
| 
       281 
403 
     | 
    
         
             
                    #     * :member_id (String)
         
     | 
| 
       282 
404 
     | 
    
         
             
                    #     * :payer_name (String)
         
     | 
| 
         @@ -285,24 +407,24 @@ module CandidApiClient 
     | 
|
| 
       285 
407 
     | 
    
         
             
                    #     * :rx_pcn (String)
         
     | 
| 
       286 
408 
     | 
    
         
             
                    #     * :image_url_front (String)
         
     | 
| 
       287 
409 
     | 
    
         
             
                    #     * :image_url_back (String)
         
     | 
| 
       288 
     | 
    
         
            -
                    #     * :emr_payer_crosswalk (Commons::EmrPayerCrosswalk)
         
     | 
| 
      
 410 
     | 
    
         
            +
                    #     * :emr_payer_crosswalk (CandidApiClient::Commons::Types::EmrPayerCrosswalk)
         
     | 
| 
       289 
411 
     | 
    
         
             
                    #     * :group_number (String)
         
     | 
| 
       290 
412 
     | 
    
         
             
                    #     * :plan_name (String)
         
     | 
| 
       291 
     | 
    
         
            -
                    #     * :plan_type (Commons::SourceOfPaymentCode)
         
     | 
| 
       292 
     | 
    
         
            -
                    #     * :insurance_type (Commons::InsuranceTypeCode)
         
     | 
| 
       293 
     | 
    
         
            -
                    #   * :patient_relationship_to_subscriber_code (Commons::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
       294 
     | 
    
         
            -
                    #   * :date_of_birth ( 
     | 
| 
      
 413 
     | 
    
         
            +
                    #     * :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)
         
     | 
| 
      
 414 
     | 
    
         
            +
                    #     * :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)
         
     | 
| 
      
 415 
     | 
    
         
            +
                    #   * :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
      
 416 
     | 
    
         
            +
                    #   * :date_of_birth (Date)
         
     | 
| 
       295 
417 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       296 
418 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       297 
419 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       298 
420 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       299 
421 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       300 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 422 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       301 
423 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       302 
424 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       303 
425 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       304 
     | 
    
         
            -
                    #   * :gender (Individual::Gender)
         
     | 
| 
       305 
     | 
    
         
            -
                    # @param subscriber_secondary [Hash] Please always include this when you have it, even for self-pay claims.Request of type Individual::SubscriberCreate, as a Hash
         
     | 
| 
      
 426 
     | 
    
         
            +
                    #   * :gender (CandidApiClient::Individual::Types::Gender)
         
     | 
| 
      
 427 
     | 
    
         
            +
                    # @param subscriber_secondary [Hash] Please always include this when you have it, even for self-pay claims.Request of type CandidApiClient::Individual::Types::SubscriberCreate, as a Hash
         
     | 
| 
       306 
428 
     | 
    
         
             
                    #   * :insurance_card (Hash)
         
     | 
| 
       307 
429 
     | 
    
         
             
                    #     * :member_id (String)
         
     | 
| 
       308 
430 
     | 
    
         
             
                    #     * :payer_name (String)
         
     | 
| 
         @@ -311,63 +433,121 @@ module CandidApiClient 
     | 
|
| 
       311 
433 
     | 
    
         
             
                    #     * :rx_pcn (String)
         
     | 
| 
       312 
434 
     | 
    
         
             
                    #     * :image_url_front (String)
         
     | 
| 
       313 
435 
     | 
    
         
             
                    #     * :image_url_back (String)
         
     | 
| 
       314 
     | 
    
         
            -
                    #     * :emr_payer_crosswalk (Commons::EmrPayerCrosswalk)
         
     | 
| 
      
 436 
     | 
    
         
            +
                    #     * :emr_payer_crosswalk (CandidApiClient::Commons::Types::EmrPayerCrosswalk)
         
     | 
| 
       315 
437 
     | 
    
         
             
                    #     * :group_number (String)
         
     | 
| 
       316 
438 
     | 
    
         
             
                    #     * :plan_name (String)
         
     | 
| 
       317 
     | 
    
         
            -
                    #     * :plan_type (Commons::SourceOfPaymentCode)
         
     | 
| 
       318 
     | 
    
         
            -
                    #     * :insurance_type (Commons::InsuranceTypeCode)
         
     | 
| 
       319 
     | 
    
         
            -
                    #   * :patient_relationship_to_subscriber_code (Commons::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
       320 
     | 
    
         
            -
                    #   * :date_of_birth ( 
     | 
| 
      
 439 
     | 
    
         
            +
                    #     * :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)
         
     | 
| 
      
 440 
     | 
    
         
            +
                    #     * :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)
         
     | 
| 
      
 441 
     | 
    
         
            +
                    #   * :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
      
 442 
     | 
    
         
            +
                    #   * :date_of_birth (Date)
         
     | 
| 
       321 
443 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       322 
444 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       323 
445 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       324 
446 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       325 
447 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       326 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 448 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       327 
449 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       328 
450 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       329 
451 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       330 
     | 
    
         
            -
                    #   * :gender (Individual::Gender)
         
     | 
| 
       331 
     | 
    
         
            -
                    # @param diagnoses [Array<Hash>] Ideally, this field should contain no more than 12 diagnoses. However, more 
     | 
| 
       332 
     | 
    
         
            -
                    # 
     | 
| 
       333 
     | 
    
         
            -
                    # 
     | 
| 
      
 452 
     | 
    
         
            +
                    #   * :gender (CandidApiClient::Individual::Types::Gender)
         
     | 
| 
      
 453 
     | 
    
         
            +
                    # @param diagnoses [Array<Hash>] Ideally, this field should contain no more than 12 diagnoses. However, more
         
     | 
| 
      
 454 
     | 
    
         
            +
                    #  diagnoses
         
     | 
| 
      
 455 
     | 
    
         
            +
                    #  may be submitted at this time, and coders will later prioritize the 12 that will
         
     | 
| 
      
 456 
     | 
    
         
            +
                    #  be
         
     | 
| 
      
 457 
     | 
    
         
            +
                    #  submitted to the payor.Request of type Array<CandidApiClient::Diagnoses::Types::DiagnosisCreate>, as a Hash
         
     | 
| 
       334 
458 
     | 
    
         
             
                    #   * :name (String)
         
     | 
| 
       335 
     | 
    
         
            -
                    #   * :code_type (Diagnoses::DiagnosisTypeCode)
         
     | 
| 
      
 459 
     | 
    
         
            +
                    #   * :code_type (CandidApiClient::Diagnoses::Types::DiagnosisTypeCode)
         
     | 
| 
       336 
460 
     | 
    
         
             
                    #   * :code (String)
         
     | 
| 
       337 
     | 
    
         
            -
                    # @param clinical_notes [Array<Hash>] Holds a collection of clinical observations made by healthcare providers during 
     | 
| 
       338 
     | 
    
         
            -
                    # 
     | 
| 
       339 
     | 
    
         
            -
                    #   * : 
     | 
| 
      
 461 
     | 
    
         
            +
                    # @param clinical_notes [Array<Hash>] Holds a collection of clinical observations made by healthcare providers during
         
     | 
| 
      
 462 
     | 
    
         
            +
                    #  patient encounters.Request of type Array<CandidApiClient::Encounters::V4::Types::ClinicalNoteCategoryCreate>, as a Hash
         
     | 
| 
      
 463 
     | 
    
         
            +
                    #   * :category (CandidApiClient::Encounters::V4::Types::NoteCategory)
         
     | 
| 
      
 464 
     | 
    
         
            +
                    #   * :notes (Array<CandidApiClient::Encounters::V4::Types::ClinicalNote>)
         
     | 
| 
       340 
465 
     | 
    
         
             
                    # @param billing_notes [Array<Hash>] Spot to store misc, human-readable, notes about this encounter to be used
         
     | 
| 
       341 
     | 
    
         
            -
                    # 
     | 
| 
      
 466 
     | 
    
         
            +
                    #  in the billing process.Request of type Array<CandidApiClient::BillingNotes::V2::Types::BillingNoteBase>, as a Hash
         
     | 
| 
       342 
467 
     | 
    
         
             
                    #   * :text (String)
         
     | 
| 
       343 
     | 
    
         
            -
                    # @param place_of_service_code [Commons::FacilityTypeCode] Box 24B on the CMS-1500 claim form. Line-level place of service is not currently 
     | 
| 
       344 
     | 
    
         
            -
                    #  
     | 
| 
       345 
     | 
    
         
            -
                    # 
     | 
| 
       346 
     | 
    
         
            -
                    # 
     | 
| 
      
 468 
     | 
    
         
            +
                    # @param place_of_service_code [CandidApiClient::Commons::Types::FacilityTypeCode] Box 24B on the CMS-1500 claim form. Line-level place of service is not currently
         
     | 
| 
      
 469 
     | 
    
         
            +
                    #  supported. 02 for telemedicine, 11 for in-person. Full list
         
     | 
| 
      
 470 
     | 
    
         
            +
                    #  //www.cms.gov/Medicare/Coding/place-of-service-codes/Place_of_Service_Code_Set).
         
     | 
| 
      
 471 
     | 
    
         
            +
                    # @param patient_histories [Array<Hash>] Request of type Array<CandidApiClient::Encounters::V4::Types::PatientHistoryCategory>, as a Hash
         
     | 
| 
      
 472 
     | 
    
         
            +
                    #   * :category (CandidApiClient::Encounters::V4::Types::PatientHistoryCategoryEnum)
         
     | 
| 
      
 473 
     | 
    
         
            +
                    #   * :questions (Array<CandidApiClient::Encounters::V4::Types::IntakeQuestion>)
         
     | 
| 
       347 
474 
     | 
    
         
             
                    # @param service_lines [Array<Hash>] Each service line must be linked to a diagnosis. Concretely,
         
     | 
| 
       348 
     | 
    
         
            -
                    # 
     | 
| 
       349 
     | 
    
         
            -
                    # 
     | 
| 
       350 
     | 
    
         
            -
                    #   * :modifiers (Array<Commons::ProcedureModifier>)
         
     | 
| 
      
 475 
     | 
    
         
            +
                    #  `service_line.diagnosis_pointers`must contain at least one entry which should be
         
     | 
| 
      
 476 
     | 
    
         
            +
                    #  in bounds of the diagnoses list field.Request of type Array<CandidApiClient::ServiceLines::V2::Types::ServiceLineCreate>, as a Hash
         
     | 
| 
      
 477 
     | 
    
         
            +
                    #   * :modifiers (Array<CandidApiClient::Commons::Types::ProcedureModifier>)
         
     | 
| 
       351 
478 
     | 
    
         
             
                    #   * :procedure_code (String)
         
     | 
| 
       352 
     | 
    
         
            -
                    #   * :quantity ( 
     | 
| 
       353 
     | 
    
         
            -
                    #   * :units (Commons::ServiceLineUnits)
         
     | 
| 
      
 479 
     | 
    
         
            +
                    #   * :quantity (String)
         
     | 
| 
      
 480 
     | 
    
         
            +
                    #   * :units (CandidApiClient::Commons::Types::ServiceLineUnits)
         
     | 
| 
       354 
481 
     | 
    
         
             
                    #   * :charge_amount_cents (Integer)
         
     | 
| 
       355 
482 
     | 
    
         
             
                    #   * :diagnosis_pointers (Array<Integer>)
         
     | 
| 
       356 
483 
     | 
    
         
             
                    #   * :drug_identification (Hash)
         
     | 
| 
       357 
     | 
    
         
            -
                    #     * :service_id_qualifier (ServiceLines::V2::ServiceIdQualifier)
         
     | 
| 
      
 484 
     | 
    
         
            +
                    #     * :service_id_qualifier (CandidApiClient::ServiceLines::V2::Types::ServiceIdQualifier)
         
     | 
| 
       358 
485 
     | 
    
         
             
                    #     * :national_drug_code (String)
         
     | 
| 
       359 
486 
     | 
    
         
             
                    #     * :national_drug_unit_count (String)
         
     | 
| 
       360 
     | 
    
         
            -
                    #     * :measurement_unit_code (ServiceLines::V2::MeasurementUnitCode)
         
     | 
| 
      
 487 
     | 
    
         
            +
                    #     * :measurement_unit_code (CandidApiClient::ServiceLines::V2::Types::MeasurementUnitCode)
         
     | 
| 
       361 
488 
     | 
    
         
             
                    #     * :link_sequence_number (String)
         
     | 
| 
       362 
489 
     | 
    
         
             
                    #     * :pharmacy_prescription_number (String)
         
     | 
| 
       363 
     | 
    
         
            -
                    #   * :place_of_service_code (Commons::FacilityTypeCode)
         
     | 
| 
      
 490 
     | 
    
         
            +
                    #   * :place_of_service_code (CandidApiClient::Commons::Types::FacilityTypeCode)
         
     | 
| 
       364 
491 
     | 
    
         
             
                    #   * :description (String)
         
     | 
| 
       365 
492 
     | 
    
         
             
                    #   * :date_of_service (Date)
         
     | 
| 
       366 
493 
     | 
    
         
             
                    #   * :end_date_of_service (Date)
         
     | 
| 
       367 
     | 
    
         
            -
                    #  
     | 
| 
       368 
     | 
    
         
            -
                    # 
     | 
| 
      
 494 
     | 
    
         
            +
                    #   * :referring_provider (Hash)
         
     | 
| 
      
 495 
     | 
    
         
            +
                    #     * :npi (String)
         
     | 
| 
      
 496 
     | 
    
         
            +
                    #     * :taxonomy_code (String)
         
     | 
| 
      
 497 
     | 
    
         
            +
                    #     * :address (Hash)
         
     | 
| 
      
 498 
     | 
    
         
            +
                    #       * :zip_plus_four_code (String)
         
     | 
| 
      
 499 
     | 
    
         
            +
                    #       * :address_1 (String)
         
     | 
| 
      
 500 
     | 
    
         
            +
                    #       * :address_2 (String)
         
     | 
| 
      
 501 
     | 
    
         
            +
                    #       * :city (String)
         
     | 
| 
      
 502 
     | 
    
         
            +
                    #       * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 503 
     | 
    
         
            +
                    #       * :zip_code (String)
         
     | 
| 
      
 504 
     | 
    
         
            +
                    #     * :first_name (String)
         
     | 
| 
      
 505 
     | 
    
         
            +
                    #     * :last_name (String)
         
     | 
| 
      
 506 
     | 
    
         
            +
                    #     * :organization_name (String)
         
     | 
| 
      
 507 
     | 
    
         
            +
                    #   * :initial_referring_provider (Hash)
         
     | 
| 
      
 508 
     | 
    
         
            +
                    #     * :npi (String)
         
     | 
| 
      
 509 
     | 
    
         
            +
                    #     * :taxonomy_code (String)
         
     | 
| 
      
 510 
     | 
    
         
            +
                    #     * :address (Hash)
         
     | 
| 
      
 511 
     | 
    
         
            +
                    #       * :zip_plus_four_code (String)
         
     | 
| 
      
 512 
     | 
    
         
            +
                    #       * :address_1 (String)
         
     | 
| 
      
 513 
     | 
    
         
            +
                    #       * :address_2 (String)
         
     | 
| 
      
 514 
     | 
    
         
            +
                    #       * :city (String)
         
     | 
| 
      
 515 
     | 
    
         
            +
                    #       * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 516 
     | 
    
         
            +
                    #       * :zip_code (String)
         
     | 
| 
      
 517 
     | 
    
         
            +
                    #     * :qualifier (CandidApiClient::Commons::Types::QualifierCode)
         
     | 
| 
      
 518 
     | 
    
         
            +
                    #     * :first_name (String)
         
     | 
| 
      
 519 
     | 
    
         
            +
                    #     * :last_name (String)
         
     | 
| 
      
 520 
     | 
    
         
            +
                    #     * :organization_name (String)
         
     | 
| 
      
 521 
     | 
    
         
            +
                    #   * :supervising_provider (Hash)
         
     | 
| 
      
 522 
     | 
    
         
            +
                    #     * :npi (String)
         
     | 
| 
      
 523 
     | 
    
         
            +
                    #     * :taxonomy_code (String)
         
     | 
| 
      
 524 
     | 
    
         
            +
                    #     * :address (Hash)
         
     | 
| 
      
 525 
     | 
    
         
            +
                    #       * :zip_plus_four_code (String)
         
     | 
| 
      
 526 
     | 
    
         
            +
                    #       * :address_1 (String)
         
     | 
| 
      
 527 
     | 
    
         
            +
                    #       * :address_2 (String)
         
     | 
| 
      
 528 
     | 
    
         
            +
                    #       * :city (String)
         
     | 
| 
      
 529 
     | 
    
         
            +
                    #       * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 530 
     | 
    
         
            +
                    #       * :zip_code (String)
         
     | 
| 
      
 531 
     | 
    
         
            +
                    #     * :first_name (String)
         
     | 
| 
      
 532 
     | 
    
         
            +
                    #     * :last_name (String)
         
     | 
| 
      
 533 
     | 
    
         
            +
                    #     * :organization_name (String)
         
     | 
| 
      
 534 
     | 
    
         
            +
                    #   * :ordering_provider (Hash)
         
     | 
| 
      
 535 
     | 
    
         
            +
                    #     * :npi (String)
         
     | 
| 
      
 536 
     | 
    
         
            +
                    #     * :taxonomy_code (String)
         
     | 
| 
      
 537 
     | 
    
         
            +
                    #     * :address (Hash)
         
     | 
| 
      
 538 
     | 
    
         
            +
                    #       * :zip_plus_four_code (String)
         
     | 
| 
      
 539 
     | 
    
         
            +
                    #       * :address_1 (String)
         
     | 
| 
      
 540 
     | 
    
         
            +
                    #       * :address_2 (String)
         
     | 
| 
      
 541 
     | 
    
         
            +
                    #       * :city (String)
         
     | 
| 
      
 542 
     | 
    
         
            +
                    #       * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 543 
     | 
    
         
            +
                    #       * :zip_code (String)
         
     | 
| 
      
 544 
     | 
    
         
            +
                    #     * :first_name (String)
         
     | 
| 
      
 545 
     | 
    
         
            +
                    #     * :last_name (String)
         
     | 
| 
      
 546 
     | 
    
         
            +
                    #     * :organization_name (String)
         
     | 
| 
      
 547 
     | 
    
         
            +
                    # @param guarantor [Hash] Personal and contact info for the guarantor of the patient responsibility.Request of type CandidApiClient::Guarantor::V1::Types::GuarantorCreate, as a Hash
         
     | 
| 
      
 548 
     | 
    
         
            +
                    #   * :phone_numbers (Array<CandidApiClient::Commons::Types::PhoneNumber>)
         
     | 
| 
       369 
549 
     | 
    
         
             
                    #   * :phone_consent (Boolean)
         
     | 
| 
       370 
     | 
    
         
            -
                    #   * :email ( 
     | 
| 
      
 550 
     | 
    
         
            +
                    #   * :email (String)
         
     | 
| 
       371 
551 
     | 
    
         
             
                    #   * :email_consent (Boolean)
         
     | 
| 
       372 
552 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       373 
553 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
         @@ -378,23 +558,53 @@ module CandidApiClient 
     | 
|
| 
       378 
558 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       379 
559 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       380 
560 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       381 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 561 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       382 
562 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       383 
563 
     | 
    
         
             
                    # @param external_claim_submission [Hash] ***This field is in beta.***
         
     | 
| 
       384 
     | 
    
         
            -
                    # 
     | 
| 
       385 
     | 
    
         
            -
                    # 
     | 
| 
      
 564 
     | 
    
         
            +
                    #  To be included for claims that have been submitted outside of Candid.
         
     | 
| 
      
 565 
     | 
    
         
            +
                    #  Candid supports posting remits and payments to these claims and working them
         
     | 
| 
      
 566 
     | 
    
         
            +
                    #  in-platform (e.g. editing, resubmitting).Request of type CandidApiClient::ClaimSubmission::V1::Types::ExternalClaimSubmissionCreate, as a Hash
         
     | 
| 
       386 
567 
     | 
    
         
             
                    #   * :claim_created_at (DateTime)
         
     | 
| 
       387 
568 
     | 
    
         
             
                    #   * :patient_control_number (String)
         
     | 
| 
       388 
     | 
    
         
            -
                    #   * :submission_records (Array<ClaimSubmission::V1::ClaimSubmissionRecordCreate>)
         
     | 
| 
       389 
     | 
    
         
            -
                    # @param tag_ids [Array< 
     | 
| 
       390 
     | 
    
         
            -
                    # @param request_options [RequestOptions]
         
     | 
| 
       391 
     | 
    
         
            -
                    # @return [Encounters::V4::Encounter]
         
     | 
| 
      
 569 
     | 
    
         
            +
                    #   * :submission_records (Array<CandidApiClient::ClaimSubmission::V1::Types::ClaimSubmissionRecordCreate>)
         
     | 
| 
      
 570 
     | 
    
         
            +
                    # @param tag_ids [Array<String>] Names of tags that should be on the encounter.
         
     | 
| 
      
 571 
     | 
    
         
            +
                    # @param request_options [CandidApiClient::RequestOptions]
         
     | 
| 
      
 572 
     | 
    
         
            +
                    # @return [CandidApiClient::Encounters::V4::Types::Encounter]
         
     | 
| 
      
 573 
     | 
    
         
            +
                    # @example
         
     | 
| 
      
 574 
     | 
    
         
            +
                    #  api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
         
     | 
| 
      
 575 
     | 
    
         
            +
                    #  api.encounters.v_4.create(
         
     | 
| 
      
 576 
     | 
    
         
            +
                    #    date_of_service: DateTime.parse(2023-01-15),
         
     | 
| 
      
 577 
     | 
    
         
            +
                    #    end_date_of_service: DateTime.parse(2023-01-15),
         
     | 
| 
      
 578 
     | 
    
         
            +
                    #    patient: { phone_numbers: [{ number: "1234567890", type: HOME }], phone_consent: true, email: "johndoe@joincandidhealth.com", email_consent: true, external_id: "string", date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", gender: MALE },
         
     | 
| 
      
 579 
     | 
    
         
            +
                    #    billing_provider: { address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, tax_id: "string", npi: "string", taxonomy_code: "string", first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 580 
     | 
    
         
            +
                    #    rendering_provider: { address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, npi: "string", taxonomy_code: "string", first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 581 
     | 
    
         
            +
                    #    referring_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 582 
     | 
    
         
            +
                    #    initial_referring_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, qualifier: DQ, first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 583 
     | 
    
         
            +
                    #    supervising_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 584 
     | 
    
         
            +
                    #    ordering_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 585 
     | 
    
         
            +
                    #    service_facility: { organization_name: "string", npi: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" } },
         
     | 
| 
      
 586 
     | 
    
         
            +
                    #    subscriber_primary: { insurance_card: { member_id: "string", payer_name: "string", payer_id: "string", rx_bin: "string", rx_pcn: "string", image_url_front: "string", image_url_back: "string", emr_payer_crosswalk: HEALTHIE, group_number: "string", plan_name: "string", plan_type: SELF_PAY, insurance_type: C_01 }, patient_relationship_to_subscriber_code: SPOUSE, date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", gender: MALE },
         
     | 
| 
      
 587 
     | 
    
         
            +
                    #    subscriber_secondary: { insurance_card: { member_id: "string", payer_name: "string", payer_id: "string", rx_bin: "string", rx_pcn: "string", image_url_front: "string", image_url_back: "string", emr_payer_crosswalk: HEALTHIE, group_number: "string", plan_name: "string", plan_type: SELF_PAY, insurance_type: C_01 }, patient_relationship_to_subscriber_code: SPOUSE, date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", gender: MALE },
         
     | 
| 
      
 588 
     | 
    
         
            +
                    #    diagnoses: [{ name: "string", code_type: ABF, code: "string" }],
         
     | 
| 
      
 589 
     | 
    
         
            +
                    #    clinical_notes: [{ category: CLINICAL, notes: [{  }] }],
         
     | 
| 
      
 590 
     | 
    
         
            +
                    #    billing_notes: [{ text: "string" }],
         
     | 
| 
      
 591 
     | 
    
         
            +
                    #    place_of_service_code: PHARMACY,
         
     | 
| 
      
 592 
     | 
    
         
            +
                    #    patient_histories: [{ category: PRESENT_ILLNESS, questions: [{ id: "6E7FBCE4-A8EA-46D0-A8D8-FF83CA3BB176", text: "Do you have any allergies?", responses: [{ response: "No allergies", follow_ups: [{ id: "4F3D57F9-AC94-49D6-87E4-E804B709917A", text: "Do you have any allergies?", response: "No allergies" }] }] }] }],
         
     | 
| 
      
 593 
     | 
    
         
            +
                    #    service_lines: [{ modifiers: [TWENTY_TWO], procedure_code: "string", quantity: "string", units: MJ, charge_amount_cents: 1, diagnosis_pointers: [1], drug_identification: {  }, place_of_service_code: PHARMACY, description: "string", date_of_service: DateTime.parse(2023-01-15), end_date_of_service: DateTime.parse(2023-01-15), referring_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" }, initial_referring_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, qualifier: DQ, first_name: "string", last_name: "string", organization_name: "string" }, supervising_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" }, ordering_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" } }],
         
     | 
| 
      
 594 
     | 
    
         
            +
                    #    guarantor: { phone_numbers: [{ number: "1234567890", type: HOME }], phone_consent: true, email: "johndoe@joincandidhealth.com", email_consent: true, first_name: "string", last_name: "string", external_id: "string", date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" } },
         
     | 
| 
      
 595 
     | 
    
         
            +
                    #    external_claim_submission: { claim_created_at: DateTime.parse(2023-01-01T12:00:00.000Z), patient_control_number: "PATIENT_CONTROL_NUMBER", submission_records: [{ submitted_at: DateTime.parse(2023-01-01T13:00:00.000Z), claim_frequency_code: ORIGINAL, payer_responsibility: PRIMARY, intended_submission_medium: ELECTRONIC }, { submitted_at: DateTime.parse(2023-01-04T12:00:00.000Z), claim_frequency_code: REPLACEMENT, payer_responsibility: PRIMARY, intended_submission_medium: PAPER }] },
         
     | 
| 
      
 596 
     | 
    
         
            +
                    #    tag_ids: ["string"]
         
     | 
| 
      
 597 
     | 
    
         
            +
                    #  )
         
     | 
| 
       392 
598 
     | 
    
         
             
                    def create(external_id:, patient_authorized_release:, benefits_assigned_to_provider:,
         
     | 
| 
       393 
     | 
    
         
            -
                               provider_accepts_assignment:, billable_status:, responsible_party:, patient:, billing_provider:, rendering_provider:, diagnoses:, place_of_service_code:, prior_authorization_number: nil, appointment_type: nil, existing_medications: nil, vitals: nil, interventions: nil, pay_to_address: nil, synchronicity: nil, additional_information: nil, service_authorization_exception_code: nil, admission_date: nil, discharge_date: nil, onset_of_current_illness_or_symptom_date: nil, last_menstrual_period_date: nil, delay_reason_code: nil, additional_properties: nil, date_of_service: nil, end_date_of_service: nil, referring_provider: nil, service_facility: nil, subscriber_primary: nil, subscriber_secondary: nil, clinical_notes: nil, billing_notes: nil, patient_histories: nil, service_lines: nil, guarantor: nil, external_claim_submission: nil, tag_ids: nil, request_options: nil)
         
     | 
| 
       394 
     | 
    
         
            -
                      response = @request_client.conn.post 
     | 
| 
      
 599 
     | 
    
         
            +
                               provider_accepts_assignment:, billable_status:, responsible_party:, patient:, billing_provider:, rendering_provider:, diagnoses:, place_of_service_code:, prior_authorization_number: nil, appointment_type: nil, existing_medications: nil, vitals: nil, interventions: nil, pay_to_address: nil, synchronicity: nil, additional_information: nil, service_authorization_exception_code: nil, admission_date: nil, discharge_date: nil, onset_of_current_illness_or_symptom_date: nil, last_menstrual_period_date: nil, delay_reason_code: nil, additional_properties: nil, _field_set: nil, date_of_service: nil, end_date_of_service: nil, referring_provider: nil, initial_referring_provider: nil, supervising_provider: nil, ordering_provider: nil, service_facility: nil, subscriber_primary: nil, subscriber_secondary: nil, clinical_notes: nil, billing_notes: nil, patient_histories: nil, service_lines: nil, guarantor: nil, external_claim_submission: nil, tag_ids: nil, request_options: nil)
         
     | 
| 
      
 600 
     | 
    
         
            +
                      response = @request_client.conn.post do |req|
         
     | 
| 
       395 
601 
     | 
    
         
             
                        req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
         
     | 
| 
       396 
602 
     | 
    
         
             
                        req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
         
     | 
| 
       397 
     | 
    
         
            -
                        req.headers = { 
     | 
| 
      
 603 
     | 
    
         
            +
                        req.headers = {
         
     | 
| 
      
 604 
     | 
    
         
            +
                      **(req.headers || {}),
         
     | 
| 
      
 605 
     | 
    
         
            +
                      **@request_client.get_headers,
         
     | 
| 
      
 606 
     | 
    
         
            +
                      **(request_options&.additional_headers || {})
         
     | 
| 
      
 607 
     | 
    
         
            +
                        }.compact
         
     | 
| 
       398 
608 
     | 
    
         
             
                        req.body = {
         
     | 
| 
       399 
609 
     | 
    
         
             
                          **(request_options&.additional_body_parameters || {}),
         
     | 
| 
       400 
610 
     | 
    
         
             
                          external_id: external_id,
         
     | 
| 
         @@ -418,12 +628,16 @@ module CandidApiClient 
     | 
|
| 
       418 
628 
     | 
    
         
             
                          last_menstrual_period_date: last_menstrual_period_date,
         
     | 
| 
       419 
629 
     | 
    
         
             
                          delay_reason_code: delay_reason_code,
         
     | 
| 
       420 
630 
     | 
    
         
             
                          additional_properties: additional_properties,
         
     | 
| 
      
 631 
     | 
    
         
            +
                          _field_set: _field_set,
         
     | 
| 
       421 
632 
     | 
    
         
             
                          date_of_service: date_of_service,
         
     | 
| 
       422 
633 
     | 
    
         
             
                          end_date_of_service: end_date_of_service,
         
     | 
| 
       423 
634 
     | 
    
         
             
                          patient: patient,
         
     | 
| 
       424 
635 
     | 
    
         
             
                          billing_provider: billing_provider,
         
     | 
| 
       425 
636 
     | 
    
         
             
                          rendering_provider: rendering_provider,
         
     | 
| 
       426 
637 
     | 
    
         
             
                          referring_provider: referring_provider,
         
     | 
| 
      
 638 
     | 
    
         
            +
                          initial_referring_provider: initial_referring_provider,
         
     | 
| 
      
 639 
     | 
    
         
            +
                          supervising_provider: supervising_provider,
         
     | 
| 
      
 640 
     | 
    
         
            +
                          ordering_provider: ordering_provider,
         
     | 
| 
       427 
641 
     | 
    
         
             
                          service_facility: service_facility,
         
     | 
| 
       428 
642 
     | 
    
         
             
                          subscriber_primary: subscriber_primary,
         
     | 
| 
       429 
643 
     | 
    
         
             
                          subscriber_secondary: subscriber_secondary,
         
     | 
| 
         @@ -437,47 +651,76 @@ module CandidApiClient 
     | 
|
| 
       437 
651 
     | 
    
         
             
                          external_claim_submission: external_claim_submission,
         
     | 
| 
       438 
652 
     | 
    
         
             
                          tag_ids: tag_ids
         
     | 
| 
       439 
653 
     | 
    
         
             
                        }.compact
         
     | 
| 
      
 654 
     | 
    
         
            +
                        req.url "#{@request_client.get_url(environment: CandidApi,
         
     | 
| 
      
 655 
     | 
    
         
            +
                                                           request_options: request_options)}/api/encounters/v4"
         
     | 
| 
       440 
656 
     | 
    
         
             
                      end
         
     | 
| 
       441 
     | 
    
         
            -
                      Encounters::V4::Encounter.from_json(json_object: response.body)
         
     | 
| 
      
 657 
     | 
    
         
            +
                      CandidApiClient::Encounters::V4::Types::Encounter.from_json(json_object: response.body)
         
     | 
| 
       442 
658 
     | 
    
         
             
                    end
         
     | 
| 
       443 
659 
     | 
    
         | 
| 
       444 
     | 
    
         
            -
                    # @param encounter_id [ 
     | 
| 
       445 
     | 
    
         
            -
                    # @param prior_authorization_number [ 
     | 
| 
       446 
     | 
    
         
            -
                    # @param external_id [ 
     | 
| 
       447 
     | 
    
         
            -
                    # 
     | 
| 
       448 
     | 
    
         
            -
                    # 
     | 
| 
       449 
     | 
    
         
            -
                    # @param date_of_service [ 
     | 
| 
       450 
     | 
    
         
            -
                    # 
     | 
| 
       451 
     | 
    
         
            -
                    # 
     | 
| 
       452 
     | 
    
         
            -
                    # 
     | 
| 
       453 
     | 
    
         
            -
                    # 
     | 
| 
       454 
     | 
    
         
            -
                    #  
     | 
| 
       455 
     | 
    
         
            -
                    # 
     | 
| 
       456 
     | 
    
         
            -
                    # 
     | 
| 
       457 
     | 
    
         
            -
                    # @param  
     | 
| 
       458 
     | 
    
         
            -
                    # 
     | 
| 
       459 
     | 
    
         
            -
                    # 
     | 
| 
       460 
     | 
    
         
            -
                    # 
     | 
| 
       461 
     | 
    
         
            -
                    #  
     | 
| 
      
 660 
     | 
    
         
            +
                    # @param encounter_id [String]
         
     | 
| 
      
 661 
     | 
    
         
            +
                    # @param prior_authorization_number [String] Box 23 on the CMS-1500 claim form.
         
     | 
| 
      
 662 
     | 
    
         
            +
                    # @param external_id [String] A client-specified unique ID to associate with this encounter;
         
     | 
| 
      
 663 
     | 
    
         
            +
                    #  for example, your internal encounter ID or a Dr. Chrono encounter ID.
         
     | 
| 
      
 664 
     | 
    
         
            +
                    #  This field should not contain PHI.
         
     | 
| 
      
 665 
     | 
    
         
            +
                    # @param date_of_service [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-24.
         
     | 
| 
      
 666 
     | 
    
         
            +
                    #  This date must be the local date in the timezone where the service occurred.
         
     | 
| 
      
 667 
     | 
    
         
            +
                    #  Box 24a on the CMS-1500 claim form.
         
     | 
| 
      
 668 
     | 
    
         
            +
                    #  If service occurred over a range of dates, this should be the start date.
         
     | 
| 
      
 669 
     | 
    
         
            +
                    #  If service lines have distinct date_of_service values, updating the encounter's
         
     | 
| 
      
 670 
     | 
    
         
            +
                    #  date_of_service will fail. If all service line date_of_service values are the
         
     | 
| 
      
 671 
     | 
    
         
            +
                    #  same, updating the encounter's date_of_service will update all service line
         
     | 
| 
      
 672 
     | 
    
         
            +
                    #  date_of_service values.
         
     | 
| 
      
 673 
     | 
    
         
            +
                    # @param diagnosis_ids [Array<String>] Ideally, this field should contain no more than 12 diagnoses. However, more
         
     | 
| 
      
 674 
     | 
    
         
            +
                    #  diagnoses
         
     | 
| 
      
 675 
     | 
    
         
            +
                    #  may be submitted at this time, and coders will later prioritize the 12 that will
         
     | 
| 
      
 676 
     | 
    
         
            +
                    #  be
         
     | 
| 
      
 677 
     | 
    
         
            +
                    #  submitted to the payor.
         
     | 
| 
      
 678 
     | 
    
         
            +
                    # @param tag_ids [Array<String>] Names of tags that should be on the encounter.  Note all tags on encounter will
         
     | 
| 
      
 679 
     | 
    
         
            +
                    #  be overriden with this list.
         
     | 
| 
      
 680 
     | 
    
         
            +
                    # @param clinical_notes [Array<Hash>] Holds a collection of clinical observations made by healthcare providers during
         
     | 
| 
      
 681 
     | 
    
         
            +
                    #  patient encounters.Request of type Array<CandidApiClient::Encounters::V4::Types::ClinicalNoteCategoryCreate>, as a Hash
         
     | 
| 
      
 682 
     | 
    
         
            +
                    #   * :category (CandidApiClient::Encounters::V4::Types::NoteCategory)
         
     | 
| 
      
 683 
     | 
    
         
            +
                    #   * :notes (Array<CandidApiClient::Encounters::V4::Types::ClinicalNote>)
         
     | 
| 
      
 684 
     | 
    
         
            +
                    # @param pay_to_address [Hash] Specifies the address to which payments for the claim should be sent.Request of type CandidApiClient::Commons::Types::StreetAddressLongZip, as a Hash
         
     | 
| 
       462 
685 
     | 
    
         
             
                    #   * :zip_plus_four_code (String)
         
     | 
| 
       463 
686 
     | 
    
         
             
                    #   * :address_1 (String)
         
     | 
| 
       464 
687 
     | 
    
         
             
                    #   * :address_2 (String)
         
     | 
| 
       465 
688 
     | 
    
         
             
                    #   * :city (String)
         
     | 
| 
       466 
     | 
    
         
            -
                    #   * :state (Commons::State)
         
     | 
| 
      
 689 
     | 
    
         
            +
                    #   * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       467 
690 
     | 
    
         
             
                    #   * :zip_code (String)
         
     | 
| 
       468 
     | 
    
         
            -
                    # @param billable_status [Encounters::V4::BillableStatusType] Defines if the Encounter is to be billed by Candid to the responsible_party. 
     | 
| 
       469 
     | 
    
         
            -
                    #  
     | 
| 
       470 
     | 
    
         
            -
                    #  
     | 
| 
       471 
     | 
    
         
            -
                    # 
     | 
| 
       472 
     | 
    
         
            -
                    # @param  
     | 
| 
       473 
     | 
    
         
            -
                    #  
     | 
| 
       474 
     | 
    
         
            -
                    # @param  
     | 
| 
       475 
     | 
    
         
            -
                    #  
     | 
| 
       476 
     | 
    
         
            -
                    # 
     | 
| 
       477 
     | 
    
         
            -
                    # 
     | 
| 
       478 
     | 
    
         
            -
                    # 
     | 
| 
       479 
     | 
    
         
            -
                    # 
     | 
| 
       480 
     | 
    
         
            -
                    #  
     | 
| 
      
 691 
     | 
    
         
            +
                    # @param billable_status [CandidApiClient::Encounters::V4::Types::BillableStatusType] Defines if the Encounter is to be billed by Candid to the responsible_party.
         
     | 
| 
      
 692 
     | 
    
         
            +
                    #  Examples for when this should be set to NOT_BILLABLE include if the Encounter
         
     | 
| 
      
 693 
     | 
    
         
            +
                    #  has not occurred yet or if there is no intention of ever billing the
         
     | 
| 
      
 694 
     | 
    
         
            +
                    #  responsible_party.
         
     | 
| 
      
 695 
     | 
    
         
            +
                    # @param responsible_party [CandidApiClient::Encounters::V4::Types::ResponsiblePartyType] Defines the party to be billed with the initial balance owed on the claim. Use
         
     | 
| 
      
 696 
     | 
    
         
            +
                    #  SELF_PAY if you intend to bill self pay/cash pay.
         
     | 
| 
      
 697 
     | 
    
         
            +
                    # @param provider_accepts_assignment [Boolean] Whether you have accepted the patient's authorization for insurance payments to
         
     | 
| 
      
 698 
     | 
    
         
            +
                    #  be made to you, not them. Box 27 on the CMS-1500 claim form.
         
     | 
| 
      
 699 
     | 
    
         
            +
                    # @param benefits_assigned_to_provider [Boolean] Whether this patient has authorized insurance payments to be made to you, not
         
     | 
| 
      
 700 
     | 
    
         
            +
                    #  them. If false, patient may receive reimbursement. Box 13 on the CMS-1500 claim
         
     | 
| 
      
 701 
     | 
    
         
            +
                    #  form.
         
     | 
| 
      
 702 
     | 
    
         
            +
                    # @param synchronicity [CandidApiClient::Encounters::V4::Types::SynchronicityType] Whether or not this was a synchronous or asynchronous encounter. Asynchronous
         
     | 
| 
      
 703 
     | 
    
         
            +
                    #  encounters occur when providers and patients communicate online using forms,
         
     | 
| 
      
 704 
     | 
    
         
            +
                    #  instant messaging, or other pre-recorded digital mediums. Synchronous encounters
         
     | 
| 
      
 705 
     | 
    
         
            +
                    #  occur in live, real-time settings where the patient interacts directly with the
         
     | 
| 
      
 706 
     | 
    
         
            +
                    #  provider, such as over video or a phone call.
         
     | 
| 
      
 707 
     | 
    
         
            +
                    # @param place_of_service_code [CandidApiClient::Commons::Types::FacilityTypeCode] Box 24B on the CMS-1500 claim form. Line-level place of service is not currently
         
     | 
| 
      
 708 
     | 
    
         
            +
                    #  supported. 02 for telemedicine, 11 for in-person. Full list
         
     | 
| 
      
 709 
     | 
    
         
            +
                    #  //www.cms.gov/Medicare/Coding/place-of-service-codes/Place_of_Service_Code_Set).
         
     | 
| 
      
 710 
     | 
    
         
            +
                    # @param place_of_service_code_as_submitted [CandidApiClient::Commons::Types::FacilityTypeCode] Box 24B on the CMS-1500 claim form. Line-level place of service is not currently
         
     | 
| 
      
 711 
     | 
    
         
            +
                    #  supported. 02 for telemedicine, 11 for in-person. Full list
         
     | 
| 
      
 712 
     | 
    
         
            +
                    #  //www.cms.gov/Medicare/Coding/place-of-service-codes/Place_of_Service_Code_Set).
         
     | 
| 
      
 713 
     | 
    
         
            +
                    # @param appointment_type [String] Human-readable description of the appointment type (ex: "Acupuncture -
         
     | 
| 
      
 714 
     | 
    
         
            +
                    #  Headaches").
         
     | 
| 
      
 715 
     | 
    
         
            +
                    # @param end_date_of_service [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-25.
         
     | 
| 
      
 716 
     | 
    
         
            +
                    #  This date must be the local date in the timezone where the service occurred.
         
     | 
| 
      
 717 
     | 
    
         
            +
                    #  If omitted, the Encounter is assumed to be for a single day.
         
     | 
| 
      
 718 
     | 
    
         
            +
                    #  Must not be temporally before the date_of_service field.
         
     | 
| 
      
 719 
     | 
    
         
            +
                    #  If service lines have distinct end_date_of_service values, updating the
         
     | 
| 
      
 720 
     | 
    
         
            +
                    #  encounter's end_date_of_service will fail. If all service line
         
     | 
| 
      
 721 
     | 
    
         
            +
                    #  end_date_of_service values are the same, updating the encounter's
         
     | 
| 
      
 722 
     | 
    
         
            +
                    #  end_date_of_service will update all service line date_of_service values.
         
     | 
| 
      
 723 
     | 
    
         
            +
                    # @param subscriber_primary [Hash] Contains details of the primary insurance subscriber.Request of type CandidApiClient::Individual::Types::SubscriberCreate, as a Hash
         
     | 
| 
       481 
724 
     | 
    
         
             
                    #   * :insurance_card (Hash)
         
     | 
| 
       482 
725 
     | 
    
         
             
                    #     * :member_id (String)
         
     | 
| 
       483 
726 
     | 
    
         
             
                    #     * :payer_name (String)
         
     | 
| 
         @@ -486,24 +729,24 @@ module CandidApiClient 
     | 
|
| 
       486 
729 
     | 
    
         
             
                    #     * :rx_pcn (String)
         
     | 
| 
       487 
730 
     | 
    
         
             
                    #     * :image_url_front (String)
         
     | 
| 
       488 
731 
     | 
    
         
             
                    #     * :image_url_back (String)
         
     | 
| 
       489 
     | 
    
         
            -
                    #     * :emr_payer_crosswalk (Commons::EmrPayerCrosswalk)
         
     | 
| 
      
 732 
     | 
    
         
            +
                    #     * :emr_payer_crosswalk (CandidApiClient::Commons::Types::EmrPayerCrosswalk)
         
     | 
| 
       490 
733 
     | 
    
         
             
                    #     * :group_number (String)
         
     | 
| 
       491 
734 
     | 
    
         
             
                    #     * :plan_name (String)
         
     | 
| 
       492 
     | 
    
         
            -
                    #     * :plan_type (Commons::SourceOfPaymentCode)
         
     | 
| 
       493 
     | 
    
         
            -
                    #     * :insurance_type (Commons::InsuranceTypeCode)
         
     | 
| 
       494 
     | 
    
         
            -
                    #   * :patient_relationship_to_subscriber_code (Commons::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
       495 
     | 
    
         
            -
                    #   * :date_of_birth ( 
     | 
| 
      
 735 
     | 
    
         
            +
                    #     * :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)
         
     | 
| 
      
 736 
     | 
    
         
            +
                    #     * :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)
         
     | 
| 
      
 737 
     | 
    
         
            +
                    #   * :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
      
 738 
     | 
    
         
            +
                    #   * :date_of_birth (Date)
         
     | 
| 
       496 
739 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       497 
740 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       498 
741 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       499 
742 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       500 
743 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       501 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 744 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       502 
745 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       503 
746 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       504 
747 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       505 
     | 
    
         
            -
                    #   * :gender (Individual::Gender)
         
     | 
| 
       506 
     | 
    
         
            -
                    # @param subscriber_secondary [Hash] Contains details of the secondary insurance subscriber.Request of type Individual::SubscriberCreate, as a Hash
         
     | 
| 
      
 748 
     | 
    
         
            +
                    #   * :gender (CandidApiClient::Individual::Types::Gender)
         
     | 
| 
      
 749 
     | 
    
         
            +
                    # @param subscriber_secondary [Hash] Contains details of the secondary insurance subscriber.Request of type CandidApiClient::Individual::Types::SubscriberCreate, as a Hash
         
     | 
| 
       507 
750 
     | 
    
         
             
                    #   * :insurance_card (Hash)
         
     | 
| 
       508 
751 
     | 
    
         
             
                    #     * :member_id (String)
         
     | 
| 
       509 
752 
     | 
    
         
             
                    #     * :payer_name (String)
         
     | 
| 
         @@ -512,54 +755,96 @@ module CandidApiClient 
     | 
|
| 
       512 
755 
     | 
    
         
             
                    #     * :rx_pcn (String)
         
     | 
| 
       513 
756 
     | 
    
         
             
                    #     * :image_url_front (String)
         
     | 
| 
       514 
757 
     | 
    
         
             
                    #     * :image_url_back (String)
         
     | 
| 
       515 
     | 
    
         
            -
                    #     * :emr_payer_crosswalk (Commons::EmrPayerCrosswalk)
         
     | 
| 
      
 758 
     | 
    
         
            +
                    #     * :emr_payer_crosswalk (CandidApiClient::Commons::Types::EmrPayerCrosswalk)
         
     | 
| 
       516 
759 
     | 
    
         
             
                    #     * :group_number (String)
         
     | 
| 
       517 
760 
     | 
    
         
             
                    #     * :plan_name (String)
         
     | 
| 
       518 
     | 
    
         
            -
                    #     * :plan_type (Commons::SourceOfPaymentCode)
         
     | 
| 
       519 
     | 
    
         
            -
                    #     * :insurance_type (Commons::InsuranceTypeCode)
         
     | 
| 
       520 
     | 
    
         
            -
                    #   * :patient_relationship_to_subscriber_code (Commons::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
       521 
     | 
    
         
            -
                    #   * :date_of_birth ( 
     | 
| 
      
 761 
     | 
    
         
            +
                    #     * :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)
         
     | 
| 
      
 762 
     | 
    
         
            +
                    #     * :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)
         
     | 
| 
      
 763 
     | 
    
         
            +
                    #   * :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
      
 764 
     | 
    
         
            +
                    #   * :date_of_birth (Date)
         
     | 
| 
       522 
765 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       523 
766 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       524 
767 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       525 
768 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       526 
769 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       527 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 770 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       528 
771 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       529 
772 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       530 
773 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       531 
     | 
    
         
            -
                    #   * :gender (Individual::Gender)
         
     | 
| 
      
 774 
     | 
    
         
            +
                    #   * :gender (CandidApiClient::Individual::Types::Gender)
         
     | 
| 
       532 
775 
     | 
    
         
             
                    # @param additional_information [String] Defines additional information on the claim needed by the payer.
         
     | 
| 
       533 
     | 
    
         
            -
                    # 
     | 
| 
       534 
     | 
    
         
            -
                    # @param service_authorization_exception_code [Encounters::V4::ServiceAuthorizationExceptionCode] 837p Loop2300 REF*4N
         
     | 
| 
       535 
     | 
    
         
            -
                    # 
     | 
| 
       536 
     | 
    
         
            -
                    # 
     | 
| 
       537 
     | 
    
         
            -
                    # 
     | 
| 
       538 
     | 
    
         
            -
                    #  
     | 
| 
       539 
     | 
    
         
            -
                    # 
     | 
| 
       540 
     | 
    
         
            -
                    # 
     | 
| 
       541 
     | 
    
         
            -
                    # 
     | 
| 
       542 
     | 
    
         
            -
                    #  
     | 
| 
       543 
     | 
    
         
            -
                    # 
     | 
| 
       544 
     | 
    
         
            -
                    #  
     | 
| 
       545 
     | 
    
         
            -
                    # 
     | 
| 
       546 
     | 
    
         
            -
                    # 
     | 
| 
       547 
     | 
    
         
            -
                    # 
     | 
| 
       548 
     | 
    
         
            -
                    # @param  
     | 
| 
       549 
     | 
    
         
            -
                    # 
     | 
| 
       550 
     | 
    
         
            -
                    #  
     | 
| 
       551 
     | 
    
         
            -
                    # 
     | 
| 
      
 776 
     | 
    
         
            +
                    #  Box 19 on the CMS-1500 claim form.
         
     | 
| 
      
 777 
     | 
    
         
            +
                    # @param service_authorization_exception_code [CandidApiClient::Encounters::V4::Types::ServiceAuthorizationExceptionCode] 837p Loop2300 REF*4N
         
     | 
| 
      
 778 
     | 
    
         
            +
                    #  Required when mandated by government law or regulation to obtain authorization
         
     | 
| 
      
 779 
     | 
    
         
            +
                    #  for specific service(s) but, for the
         
     | 
| 
      
 780 
     | 
    
         
            +
                    #  reasons listed in one of the enum values of ServiceAuthorizationExceptionCode,
         
     | 
| 
      
 781 
     | 
    
         
            +
                    #  the service was performed without
         
     | 
| 
      
 782 
     | 
    
         
            +
                    #  obtaining the authorization.
         
     | 
| 
      
 783 
     | 
    
         
            +
                    # @param admission_date [Date] 837p Loop2300 DTP*435, CMS-1500 Box 18
         
     | 
| 
      
 784 
     | 
    
         
            +
                    #  Required on all ambulance claims when the patient was known to be admitted to
         
     | 
| 
      
 785 
     | 
    
         
            +
                    #  the hospital.
         
     | 
| 
      
 786 
     | 
    
         
            +
                    #  OR
         
     | 
| 
      
 787 
     | 
    
         
            +
                    #  Required on all claims involving inpatient medical visits.
         
     | 
| 
      
 788 
     | 
    
         
            +
                    # @param discharge_date [Date] 837p Loop2300 DTP*096, CMS-1500 Box 18
         
     | 
| 
      
 789 
     | 
    
         
            +
                    #  Required for inpatient claims when the patient was discharged from the facility
         
     | 
| 
      
 790 
     | 
    
         
            +
                    #  and the discharge date is known.
         
     | 
| 
      
 791 
     | 
    
         
            +
                    # @param onset_of_current_illness_or_symptom_date [Date] 837p Loop2300 DTP*431, CMS-1500 Box 14
         
     | 
| 
      
 792 
     | 
    
         
            +
                    #  Required for the initial medical service or visit performed in response to a
         
     | 
| 
      
 793 
     | 
    
         
            +
                    #  medical emergency when the date is available and is different than the date of
         
     | 
| 
      
 794 
     | 
    
         
            +
                    #  service.
         
     | 
| 
      
 795 
     | 
    
         
            +
                    #  OR
         
     | 
| 
      
 796 
     | 
    
         
            +
                    #  This date is the onset of acute symptoms for the current illness or condition.
         
     | 
| 
      
 797 
     | 
    
         
            +
                    # @param last_menstrual_period_date [Date] 837p Loop2300 DTP*484, CMS-1500 Box 14
         
     | 
| 
      
 798 
     | 
    
         
            +
                    #  Required when, in the judgment of the provider, the services on this claim are
         
     | 
| 
      
 799 
     | 
    
         
            +
                    #  related to the patient's pregnancy.
         
     | 
| 
      
 800 
     | 
    
         
            +
                    # @param delay_reason_code [CandidApiClient::Commons::Types::DelayReasonCode] 837i Loop2300, CLM-1300 Box 20
         
     | 
| 
      
 801 
     | 
    
         
            +
                    #  Code indicating the reason why a request was delayed
         
     | 
| 
       552 
802 
     | 
    
         
             
                    # @param patient_authorized_release [Boolean] Whether this patient has authorized the release of medical information
         
     | 
| 
       553 
     | 
    
         
            -
                    # 
     | 
| 
       554 
     | 
    
         
            -
                    # 
     | 
| 
       555 
     | 
    
         
            -
                    # @param request_options [RequestOptions]
         
     | 
| 
       556 
     | 
    
         
            -
                    # @return [Encounters::V4::Encounter]
         
     | 
| 
      
 803 
     | 
    
         
            +
                    #  for billing purpose.
         
     | 
| 
      
 804 
     | 
    
         
            +
                    #  Box 12 on the CMS-1500 claim form.
         
     | 
| 
      
 805 
     | 
    
         
            +
                    # @param request_options [CandidApiClient::RequestOptions]
         
     | 
| 
      
 806 
     | 
    
         
            +
                    # @return [CandidApiClient::Encounters::V4::Types::Encounter]
         
     | 
| 
      
 807 
     | 
    
         
            +
                    # @example
         
     | 
| 
      
 808 
     | 
    
         
            +
                    #  api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
         
     | 
| 
      
 809 
     | 
    
         
            +
                    #  api.encounters.v_4.update(
         
     | 
| 
      
 810 
     | 
    
         
            +
                    #    encounter_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
         
     | 
| 
      
 811 
     | 
    
         
            +
                    #    prior_authorization_number: "string",
         
     | 
| 
      
 812 
     | 
    
         
            +
                    #    external_id: "string",
         
     | 
| 
      
 813 
     | 
    
         
            +
                    #    date_of_service: DateTime.parse(2023-01-15),
         
     | 
| 
      
 814 
     | 
    
         
            +
                    #    diagnosis_ids: ["d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"],
         
     | 
| 
      
 815 
     | 
    
         
            +
                    #    tag_ids: ["string"],
         
     | 
| 
      
 816 
     | 
    
         
            +
                    #    clinical_notes: [{ category: CLINICAL, notes: [{  }] }],
         
     | 
| 
      
 817 
     | 
    
         
            +
                    #    pay_to_address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" },
         
     | 
| 
      
 818 
     | 
    
         
            +
                    #    billable_status: BILLABLE,
         
     | 
| 
      
 819 
     | 
    
         
            +
                    #    responsible_party: INSURANCE_PAY,
         
     | 
| 
      
 820 
     | 
    
         
            +
                    #    provider_accepts_assignment: true,
         
     | 
| 
      
 821 
     | 
    
         
            +
                    #    benefits_assigned_to_provider: true,
         
     | 
| 
      
 822 
     | 
    
         
            +
                    #    synchronicity: SYNCHRONOUS,
         
     | 
| 
      
 823 
     | 
    
         
            +
                    #    place_of_service_code: PHARMACY,
         
     | 
| 
      
 824 
     | 
    
         
            +
                    #    place_of_service_code_as_submitted: PHARMACY,
         
     | 
| 
      
 825 
     | 
    
         
            +
                    #    appointment_type: "string",
         
     | 
| 
      
 826 
     | 
    
         
            +
                    #    end_date_of_service: DateTime.parse(2023-01-15),
         
     | 
| 
      
 827 
     | 
    
         
            +
                    #    subscriber_primary: { insurance_card: { member_id: "string", payer_name: "string", payer_id: "string", rx_bin: "string", rx_pcn: "string", image_url_front: "string", image_url_back: "string", emr_payer_crosswalk: HEALTHIE, group_number: "string", plan_name: "string", plan_type: SELF_PAY, insurance_type: C_01 }, patient_relationship_to_subscriber_code: SPOUSE, date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", gender: MALE },
         
     | 
| 
      
 828 
     | 
    
         
            +
                    #    subscriber_secondary: { insurance_card: { member_id: "string", payer_name: "string", payer_id: "string", rx_bin: "string", rx_pcn: "string", image_url_front: "string", image_url_back: "string", emr_payer_crosswalk: HEALTHIE, group_number: "string", plan_name: "string", plan_type: SELF_PAY, insurance_type: C_01 }, patient_relationship_to_subscriber_code: SPOUSE, date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", gender: MALE },
         
     | 
| 
      
 829 
     | 
    
         
            +
                    #    additional_information: "string",
         
     | 
| 
      
 830 
     | 
    
         
            +
                    #    service_authorization_exception_code: C_1,
         
     | 
| 
      
 831 
     | 
    
         
            +
                    #    admission_date: DateTime.parse(2023-01-15),
         
     | 
| 
      
 832 
     | 
    
         
            +
                    #    discharge_date: DateTime.parse(2023-01-15),
         
     | 
| 
      
 833 
     | 
    
         
            +
                    #    onset_of_current_illness_or_symptom_date: DateTime.parse(2023-01-15),
         
     | 
| 
      
 834 
     | 
    
         
            +
                    #    last_menstrual_period_date: DateTime.parse(2023-01-15),
         
     | 
| 
      
 835 
     | 
    
         
            +
                    #    delay_reason_code: C_1,
         
     | 
| 
      
 836 
     | 
    
         
            +
                    #    patient_authorized_release: true
         
     | 
| 
      
 837 
     | 
    
         
            +
                    #  )
         
     | 
| 
       557 
838 
     | 
    
         
             
                    def update(encounter_id:, prior_authorization_number: nil, external_id: nil, date_of_service: nil,
         
     | 
| 
       558 
     | 
    
         
            -
                               diagnosis_ids: nil, tag_ids: nil, clinical_notes: nil, pay_to_address: nil, billable_status: nil, responsible_party: nil, provider_accepts_assignment: nil, benefits_assigned_to_provider: nil, synchronicity: nil, place_of_service_code: nil, appointment_type: nil, end_date_of_service: nil, subscriber_primary: nil, subscriber_secondary: nil, additional_information: nil, service_authorization_exception_code: nil, admission_date: nil, discharge_date: nil, onset_of_current_illness_or_symptom_date: nil, last_menstrual_period_date: nil, delay_reason_code: nil, patient_authorized_release: nil, request_options: nil)
         
     | 
| 
       559 
     | 
    
         
            -
                      response = @request_client.conn.patch 
     | 
| 
      
 839 
     | 
    
         
            +
                               diagnosis_ids: nil, tag_ids: nil, clinical_notes: nil, pay_to_address: nil, billable_status: nil, responsible_party: nil, provider_accepts_assignment: nil, benefits_assigned_to_provider: nil, synchronicity: nil, place_of_service_code: nil, place_of_service_code_as_submitted: nil, appointment_type: nil, end_date_of_service: nil, subscriber_primary: nil, subscriber_secondary: nil, additional_information: nil, service_authorization_exception_code: nil, admission_date: nil, discharge_date: nil, onset_of_current_illness_or_symptom_date: nil, last_menstrual_period_date: nil, delay_reason_code: nil, patient_authorized_release: nil, request_options: nil)
         
     | 
| 
      
 840 
     | 
    
         
            +
                      response = @request_client.conn.patch do |req|
         
     | 
| 
       560 
841 
     | 
    
         
             
                        req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
         
     | 
| 
       561 
842 
     | 
    
         
             
                        req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
         
     | 
| 
       562 
     | 
    
         
            -
                        req.headers = { 
     | 
| 
      
 843 
     | 
    
         
            +
                        req.headers = {
         
     | 
| 
      
 844 
     | 
    
         
            +
                      **(req.headers || {}),
         
     | 
| 
      
 845 
     | 
    
         
            +
                      **@request_client.get_headers,
         
     | 
| 
      
 846 
     | 
    
         
            +
                      **(request_options&.additional_headers || {})
         
     | 
| 
      
 847 
     | 
    
         
            +
                        }.compact
         
     | 
| 
       563 
848 
     | 
    
         
             
                        req.body = {
         
     | 
| 
       564 
849 
     | 
    
         
             
                          **(request_options&.additional_body_parameters || {}),
         
     | 
| 
       565 
850 
     | 
    
         
             
                          prior_authorization_number: prior_authorization_number,
         
     | 
| 
         @@ -575,6 +860,7 @@ module CandidApiClient 
     | 
|
| 
       575 
860 
     | 
    
         
             
                          benefits_assigned_to_provider: benefits_assigned_to_provider,
         
     | 
| 
       576 
861 
     | 
    
         
             
                          synchronicity: synchronicity,
         
     | 
| 
       577 
862 
     | 
    
         
             
                          place_of_service_code: place_of_service_code,
         
     | 
| 
      
 863 
     | 
    
         
            +
                          place_of_service_code_as_submitted: place_of_service_code_as_submitted,
         
     | 
| 
       578 
864 
     | 
    
         
             
                          appointment_type: appointment_type,
         
     | 
| 
       579 
865 
     | 
    
         
             
                          end_date_of_service: end_date_of_service,
         
     | 
| 
       580 
866 
     | 
    
         
             
                          subscriber_primary: subscriber_primary,
         
     | 
| 
         @@ -588,48 +874,75 @@ module CandidApiClient 
     | 
|
| 
       588 
874 
     | 
    
         
             
                          delay_reason_code: delay_reason_code,
         
     | 
| 
       589 
875 
     | 
    
         
             
                          patient_authorized_release: patient_authorized_release
         
     | 
| 
       590 
876 
     | 
    
         
             
                        }.compact
         
     | 
| 
      
 877 
     | 
    
         
            +
                        req.url "#{@request_client.get_url(environment: CandidApi,
         
     | 
| 
      
 878 
     | 
    
         
            +
                                                           request_options: request_options)}/api/encounters/v4/#{encounter_id}"
         
     | 
| 
       591 
879 
     | 
    
         
             
                      end
         
     | 
| 
       592 
     | 
    
         
            -
                      Encounters::V4::Encounter.from_json(json_object: response.body)
         
     | 
| 
      
 880 
     | 
    
         
            +
                      CandidApiClient::Encounters::V4::Types::Encounter.from_json(json_object: response.body)
         
     | 
| 
       593 
881 
     | 
    
         
             
                    end
         
     | 
| 
       594 
882 
     | 
    
         
             
                  end
         
     | 
| 
       595 
883 
     | 
    
         | 
| 
       596 
884 
     | 
    
         
             
                  class AsyncV4Client
         
     | 
| 
      
 885 
     | 
    
         
            +
                    # @return [CandidApiClient::AsyncRequestClient]
         
     | 
| 
       597 
886 
     | 
    
         
             
                    attr_reader :request_client
         
     | 
| 
       598 
887 
     | 
    
         | 
| 
       599 
     | 
    
         
            -
                    # @param request_client [AsyncRequestClient]
         
     | 
| 
       600 
     | 
    
         
            -
                    # @return [Encounters::V4::AsyncV4Client]
         
     | 
| 
      
 888 
     | 
    
         
            +
                    # @param request_client [CandidApiClient::AsyncRequestClient]
         
     | 
| 
      
 889 
     | 
    
         
            +
                    # @return [CandidApiClient::Encounters::V4::AsyncV4Client]
         
     | 
| 
       601 
890 
     | 
    
         
             
                    def initialize(request_client:)
         
     | 
| 
       602 
     | 
    
         
            -
                      # @type [AsyncRequestClient]
         
     | 
| 
       603 
891 
     | 
    
         
             
                      @request_client = request_client
         
     | 
| 
       604 
892 
     | 
    
         
             
                    end
         
     | 
| 
       605 
893 
     | 
    
         | 
| 
       606 
894 
     | 
    
         
             
                    # @param limit [Integer] Maximum number of entities per page, defaults to 100.
         
     | 
| 
       607 
     | 
    
         
            -
                    # @param claim_status [Claims::ClaimStatus] Indicates the current status of an insurance claim within the billing process.
         
     | 
| 
       608 
     | 
    
         
            -
                    # @param sort [Encounters::V4::EncounterSortOptions] Defaults to created_at:desc.
         
     | 
| 
       609 
     | 
    
         
            -
                    # @param page_token [ 
     | 
| 
       610 
     | 
    
         
            -
                    # @param date_of_service_min [ 
     | 
| 
       611 
     | 
    
         
            -
                    # @param date_of_service_max [ 
     | 
| 
      
 895 
     | 
    
         
            +
                    # @param claim_status [CandidApiClient::Claims::Types::ClaimStatus] Indicates the current status of an insurance claim within the billing process.
         
     | 
| 
      
 896 
     | 
    
         
            +
                    # @param sort [CandidApiClient::Encounters::V4::Types::EncounterSortOptions] Defaults to created_at:desc.
         
     | 
| 
      
 897 
     | 
    
         
            +
                    # @param page_token [String]
         
     | 
| 
      
 898 
     | 
    
         
            +
                    # @param date_of_service_min [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-25.
         
     | 
| 
      
 899 
     | 
    
         
            +
                    # @param date_of_service_max [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-25.
         
     | 
| 
       612 
900 
     | 
    
         
             
                    # @param primary_payer_names [String] Comma delimited string.
         
     | 
| 
       613 
     | 
    
         
            -
                    # @param search_term [String] Filter by any of the following fields: encounter_id, claim_id, patient 
     | 
| 
       614 
     | 
    
         
            -
                    # 
     | 
| 
       615 
     | 
    
         
            -
                    # 
     | 
| 
       616 
     | 
    
         
            -
                    #  
     | 
| 
       617 
     | 
    
         
            -
                    # @param  
     | 
| 
       618 
     | 
    
         
            -
                    # @param  
     | 
| 
       619 
     | 
    
         
            -
                    # 
     | 
| 
       620 
     | 
    
         
            -
                    # @param  
     | 
| 
       621 
     | 
    
         
            -
                    # @param  
     | 
| 
       622 
     | 
    
         
            -
                    # @param  
     | 
| 
      
 901 
     | 
    
         
            +
                    # @param search_term [String] Filter by any of the following fields: encounter_id, claim_id, patient
         
     | 
| 
      
 902 
     | 
    
         
            +
                    #  external_id,
         
     | 
| 
      
 903 
     | 
    
         
            +
                    #  patient date of birth, patient first name, patient last name,
         
     | 
| 
      
 904 
     | 
    
         
            +
                    #  or encounter external id.
         
     | 
| 
      
 905 
     | 
    
         
            +
                    # @param external_id [String] Filter to an exact match on encounter external_id, if one exists.
         
     | 
| 
      
 906 
     | 
    
         
            +
                    # @param diagnoses_updated_since [DateTime] ISO 8601 timestamp; ideally in UTC (although not required):
         
     | 
| 
      
 907 
     | 
    
         
            +
                    #  2019-08-24T14:15:22Z.
         
     | 
| 
      
 908 
     | 
    
         
            +
                    # @param tag_ids [String] Filter by name of tags on encounters.
         
     | 
| 
      
 909 
     | 
    
         
            +
                    # @param work_queue_id [String]
         
     | 
| 
      
 910 
     | 
    
         
            +
                    # @param billable_status [CandidApiClient::Encounters::V4::Types::BillableStatusType] Defines if the Encounter is to be billed by Candid to the responsible_party.
         
     | 
| 
      
 911 
     | 
    
         
            +
                    #  Examples for when this should be set to NOT_BILLABLE include if the Encounter
         
     | 
| 
      
 912 
     | 
    
         
            +
                    #  has not occurred yet or if there is no intention of ever billing the
         
     | 
| 
      
 913 
     | 
    
         
            +
                    #  responsible_party.
         
     | 
| 
      
 914 
     | 
    
         
            +
                    # @param responsible_party [CandidApiClient::Encounters::V4::Types::ResponsiblePartyType] Defines the party to be billed with the initial balance owed on the claim. Use
         
     | 
| 
      
 915 
     | 
    
         
            +
                    #  SELF_PAY if you intend to bill self pay/cash pay.
         
     | 
| 
      
 916 
     | 
    
         
            +
                    # @param owner_of_next_action [CandidApiClient::Encounters::V4::Types::EncounterOwnerOfNextActionType] The party who is responsible for taking the next action on an Encounter, as
         
     | 
| 
      
 917 
     | 
    
         
            +
                    #  defined by ownership of open Tasks.
         
     | 
| 
       623 
918 
     | 
    
         
             
                    # @param patient_external_id [String] The patient ID from the external EMR platform for the patient
         
     | 
| 
       624 
     | 
    
         
            -
                    # @param request_options [RequestOptions]
         
     | 
| 
       625 
     | 
    
         
            -
                    # @return [Encounters::V4::EncounterPage]
         
     | 
| 
      
 919 
     | 
    
         
            +
                    # @param request_options [CandidApiClient::RequestOptions]
         
     | 
| 
      
 920 
     | 
    
         
            +
                    # @return [CandidApiClient::Encounters::V4::Types::EncounterPage]
         
     | 
| 
      
 921 
     | 
    
         
            +
                    # @example
         
     | 
| 
      
 922 
     | 
    
         
            +
                    #  api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
         
     | 
| 
      
 923 
     | 
    
         
            +
                    #  api.encounters.v_4.get_all(
         
     | 
| 
      
 924 
     | 
    
         
            +
                    #    limit: 100,
         
     | 
| 
      
 925 
     | 
    
         
            +
                    #    claim_status: BILLER_RECEIVED,
         
     | 
| 
      
 926 
     | 
    
         
            +
                    #    sort: CREATED_AT_ASC,
         
     | 
| 
      
 927 
     | 
    
         
            +
                    #    page_token: "eyJ0b2tlbiI6IjEiLCJwYWdlX3Rva2VuIjoiMiJ9",
         
     | 
| 
      
 928 
     | 
    
         
            +
                    #    date_of_service_min: DateTime.parse(2019-08-24),
         
     | 
| 
      
 929 
     | 
    
         
            +
                    #    date_of_service_max: DateTime.parse(2019-08-25),
         
     | 
| 
      
 930 
     | 
    
         
            +
                    #    primary_payer_names: "Medicare,Medicaid",
         
     | 
| 
      
 931 
     | 
    
         
            +
                    #    search_term: "doe",
         
     | 
| 
      
 932 
     | 
    
         
            +
                    #    external_id: "123456",
         
     | 
| 
      
 933 
     | 
    
         
            +
                    #    diagnoses_updated_since: DateTime.parse(2019-08-24T14:15:22.000Z)
         
     | 
| 
      
 934 
     | 
    
         
            +
                    #  )
         
     | 
| 
       626 
935 
     | 
    
         
             
                    def get_all(limit: nil, claim_status: nil, sort: nil, page_token: nil, date_of_service_min: nil,
         
     | 
| 
       627 
936 
     | 
    
         
             
                                date_of_service_max: nil, primary_payer_names: nil, search_term: nil, external_id: nil, diagnoses_updated_since: nil, tag_ids: nil, work_queue_id: nil, billable_status: nil, responsible_party: nil, owner_of_next_action: nil, patient_external_id: nil, request_options: nil)
         
     | 
| 
       628 
937 
     | 
    
         
             
                      Async do
         
     | 
| 
       629 
     | 
    
         
            -
                        response = @request_client.conn.get 
     | 
| 
      
 938 
     | 
    
         
            +
                        response = @request_client.conn.get do |req|
         
     | 
| 
       630 
939 
     | 
    
         
             
                          req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
         
     | 
| 
       631 
940 
     | 
    
         
             
                          req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
         
     | 
| 
       632 
     | 
    
         
            -
                          req.headers = { 
     | 
| 
      
 941 
     | 
    
         
            +
                          req.headers = {
         
     | 
| 
      
 942 
     | 
    
         
            +
                        **(req.headers || {}),
         
     | 
| 
      
 943 
     | 
    
         
            +
                        **@request_client.get_headers,
         
     | 
| 
      
 944 
     | 
    
         
            +
                        **(request_options&.additional_headers || {})
         
     | 
| 
      
 945 
     | 
    
         
            +
                          }.compact
         
     | 
| 
       633 
946 
     | 
    
         
             
                          req.params = {
         
     | 
| 
       634 
947 
     | 
    
         
             
                            **(request_options&.additional_query_parameters || {}),
         
     | 
| 
       635 
948 
     | 
    
         
             
                            "limit": limit,
         
     | 
| 
         @@ -649,136 +962,173 @@ module CandidApiClient 
     | 
|
| 
       649 
962 
     | 
    
         
             
                            "owner_of_next_action": owner_of_next_action,
         
     | 
| 
       650 
963 
     | 
    
         
             
                            "patient_external_id": patient_external_id
         
     | 
| 
       651 
964 
     | 
    
         
             
                          }.compact
         
     | 
| 
      
 965 
     | 
    
         
            +
                          req.url "#{@request_client.get_url(environment: CandidApi,
         
     | 
| 
      
 966 
     | 
    
         
            +
                                                             request_options: request_options)}/api/encounters/v4"
         
     | 
| 
       652 
967 
     | 
    
         
             
                        end
         
     | 
| 
       653 
     | 
    
         
            -
                        Encounters::V4::EncounterPage.from_json(json_object: response.body)
         
     | 
| 
      
 968 
     | 
    
         
            +
                        CandidApiClient::Encounters::V4::Types::EncounterPage.from_json(json_object: response.body)
         
     | 
| 
       654 
969 
     | 
    
         
             
                      end
         
     | 
| 
       655 
970 
     | 
    
         
             
                    end
         
     | 
| 
       656 
971 
     | 
    
         | 
| 
       657 
     | 
    
         
            -
                    # @param encounter_id [ 
     | 
| 
       658 
     | 
    
         
            -
                    # @param request_options [RequestOptions]
         
     | 
| 
       659 
     | 
    
         
            -
                    # @return [Encounters::V4::Encounter]
         
     | 
| 
      
 972 
     | 
    
         
            +
                    # @param encounter_id [String]
         
     | 
| 
      
 973 
     | 
    
         
            +
                    # @param request_options [CandidApiClient::RequestOptions]
         
     | 
| 
      
 974 
     | 
    
         
            +
                    # @return [CandidApiClient::Encounters::V4::Types::Encounter]
         
     | 
| 
      
 975 
     | 
    
         
            +
                    # @example
         
     | 
| 
      
 976 
     | 
    
         
            +
                    #  api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
         
     | 
| 
      
 977 
     | 
    
         
            +
                    #  api.encounters.v_4.get(encounter_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32")
         
     | 
| 
       660 
978 
     | 
    
         
             
                    def get(encounter_id:, request_options: nil)
         
     | 
| 
       661 
979 
     | 
    
         
             
                      Async do
         
     | 
| 
       662 
     | 
    
         
            -
                        response = @request_client.conn.get 
     | 
| 
      
 980 
     | 
    
         
            +
                        response = @request_client.conn.get do |req|
         
     | 
| 
       663 
981 
     | 
    
         
             
                          req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
         
     | 
| 
       664 
982 
     | 
    
         
             
                          req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
         
     | 
| 
       665 
     | 
    
         
            -
                          req.headers = { 
     | 
| 
      
 983 
     | 
    
         
            +
                          req.headers = {
         
     | 
| 
      
 984 
     | 
    
         
            +
                        **(req.headers || {}),
         
     | 
| 
      
 985 
     | 
    
         
            +
                        **@request_client.get_headers,
         
     | 
| 
      
 986 
     | 
    
         
            +
                        **(request_options&.additional_headers || {})
         
     | 
| 
      
 987 
     | 
    
         
            +
                          }.compact
         
     | 
| 
      
 988 
     | 
    
         
            +
                          req.url "#{@request_client.get_url(environment: CandidApi,
         
     | 
| 
      
 989 
     | 
    
         
            +
                                                             request_options: request_options)}/api/encounters/v4/#{encounter_id}"
         
     | 
| 
       666 
990 
     | 
    
         
             
                        end
         
     | 
| 
       667 
     | 
    
         
            -
                        Encounters::V4::Encounter.from_json(json_object: response.body)
         
     | 
| 
      
 991 
     | 
    
         
            +
                        CandidApiClient::Encounters::V4::Types::Encounter.from_json(json_object: response.body)
         
     | 
| 
       668 
992 
     | 
    
         
             
                      end
         
     | 
| 
       669 
993 
     | 
    
         
             
                    end
         
     | 
| 
       670 
994 
     | 
    
         | 
| 
       671 
     | 
    
         
            -
                    # @param external_id [ 
     | 
| 
       672 
     | 
    
         
            -
                    # 
     | 
| 
       673 
     | 
    
         
            -
                    # 
     | 
| 
       674 
     | 
    
         
            -
                    # @param prior_authorization_number [ 
     | 
| 
      
 995 
     | 
    
         
            +
                    # @param external_id [String] A client-specified unique ID to associate with this encounter;
         
     | 
| 
      
 996 
     | 
    
         
            +
                    #  for example, your internal encounter ID or a Dr. Chrono encounter ID.
         
     | 
| 
      
 997 
     | 
    
         
            +
                    #  This field should not contain PHI.
         
     | 
| 
      
 998 
     | 
    
         
            +
                    # @param prior_authorization_number [String] Box 23 on the CMS-1500 claim form.
         
     | 
| 
       675 
999 
     | 
    
         
             
                    # @param patient_authorized_release [Boolean] Whether this patient has authorized the release of medical information
         
     | 
| 
       676 
     | 
    
         
            -
                    # 
     | 
| 
       677 
     | 
    
         
            -
                    # 
     | 
| 
      
 1000 
     | 
    
         
            +
                    #  for billing purpose.
         
     | 
| 
      
 1001 
     | 
    
         
            +
                    #  Box 12 on the CMS-1500 claim form.
         
     | 
| 
       678 
1002 
     | 
    
         
             
                    # @param benefits_assigned_to_provider [Boolean] Whether this patient has authorized insurance payments to be made to you,
         
     | 
| 
       679 
     | 
    
         
            -
                    # 
     | 
| 
       680 
     | 
    
         
            -
                    # 
     | 
| 
      
 1003 
     | 
    
         
            +
                    #  not them. If false, patient may receive reimbursement.
         
     | 
| 
      
 1004 
     | 
    
         
            +
                    #  Box 13 on the CMS-1500 claim form.
         
     | 
| 
       681 
1005 
     | 
    
         
             
                    # @param provider_accepts_assignment [Boolean] Whether you have accepted the patient's authorization for insurance payments
         
     | 
| 
       682 
     | 
    
         
            -
                    # 
     | 
| 
       683 
     | 
    
         
            -
                    # 
     | 
| 
       684 
     | 
    
         
            -
                    # @param appointment_type [String] Human-readable description of the appointment type (ex: "Acupuncture - 
     | 
| 
       685 
     | 
    
         
            -
                    # 
     | 
| 
      
 1006 
     | 
    
         
            +
                    #  to be made to you, not them.
         
     | 
| 
      
 1007 
     | 
    
         
            +
                    #  Box 27 on the CMS-1500 claim form.
         
     | 
| 
      
 1008 
     | 
    
         
            +
                    # @param appointment_type [String] Human-readable description of the appointment type (ex: "Acupuncture -
         
     | 
| 
      
 1009 
     | 
    
         
            +
                    #  Headaches").
         
     | 
| 
      
 1010 
     | 
    
         
            +
                    # @param existing_medications [Array<Hash>] Request of type Array<CandidApiClient::Encounters::V4::Types::Medication>, as a Hash
         
     | 
| 
       686 
1011 
     | 
    
         
             
                    #   * :name (String)
         
     | 
| 
       687 
     | 
    
         
            -
                    #   * :rx_cui ( 
     | 
| 
      
 1012 
     | 
    
         
            +
                    #   * :rx_cui (String)
         
     | 
| 
       688 
1013 
     | 
    
         
             
                    #   * :dosage (String)
         
     | 
| 
       689 
1014 
     | 
    
         
             
                    #   * :dosage_form (String)
         
     | 
| 
       690 
1015 
     | 
    
         
             
                    #   * :frequency (String)
         
     | 
| 
       691 
1016 
     | 
    
         
             
                    #   * :as_needed (Boolean)
         
     | 
| 
       692 
     | 
    
         
            -
                    # @param vitals [Hash] Request of type Encounters::V4::Vitals, as a Hash
         
     | 
| 
      
 1017 
     | 
    
         
            +
                    # @param vitals [Hash] Request of type CandidApiClient::Encounters::V4::Types::Vitals, as a Hash
         
     | 
| 
       693 
1018 
     | 
    
         
             
                    #   * :height_in (Integer)
         
     | 
| 
       694 
1019 
     | 
    
         
             
                    #   * :weight_lbs (Integer)
         
     | 
| 
       695 
1020 
     | 
    
         
             
                    #   * :blood_pressure_systolic_mmhg (Integer)
         
     | 
| 
       696 
1021 
     | 
    
         
             
                    #   * :blood_pressure_diastolic_mmhg (Integer)
         
     | 
| 
       697 
1022 
     | 
    
         
             
                    #   * :body_temperature_f (Float)
         
     | 
| 
       698 
     | 
    
         
            -
                    # @param interventions [Array<Hash>] Request of type Array<Encounters::V4::Intervention>, as a Hash
         
     | 
| 
      
 1023 
     | 
    
         
            +
                    # @param interventions [Array<Hash>] Request of type Array<CandidApiClient::Encounters::V4::Types::Intervention>, as a Hash
         
     | 
| 
       699 
1024 
     | 
    
         
             
                    #   * :name (String)
         
     | 
| 
       700 
     | 
    
         
            -
                    #   * :category (Encounters::V4::InterventionCategory)
         
     | 
| 
      
 1025 
     | 
    
         
            +
                    #   * :category (CandidApiClient::Encounters::V4::Types::InterventionCategory)
         
     | 
| 
       701 
1026 
     | 
    
         
             
                    #   * :description (String)
         
     | 
| 
       702 
1027 
     | 
    
         
             
                    #   * :medication (Hash)
         
     | 
| 
       703 
1028 
     | 
    
         
             
                    #     * :name (String)
         
     | 
| 
       704 
     | 
    
         
            -
                    #     * :rx_cui ( 
     | 
| 
      
 1029 
     | 
    
         
            +
                    #     * :rx_cui (String)
         
     | 
| 
       705 
1030 
     | 
    
         
             
                    #     * :dosage (String)
         
     | 
| 
       706 
1031 
     | 
    
         
             
                    #     * :dosage_form (String)
         
     | 
| 
       707 
1032 
     | 
    
         
             
                    #     * :frequency (String)
         
     | 
| 
       708 
1033 
     | 
    
         
             
                    #     * :as_needed (Boolean)
         
     | 
| 
       709 
     | 
    
         
            -
                    #   * :labs (Array<Encounters::V4::Lab>)
         
     | 
| 
       710 
     | 
    
         
            -
                    # @param pay_to_address [Hash] Specifies the address to which payments for the claim should be sent.Request of type Commons::StreetAddressLongZip, as a Hash
         
     | 
| 
      
 1034 
     | 
    
         
            +
                    #   * :labs (Array<CandidApiClient::Encounters::V4::Types::Lab>)
         
     | 
| 
      
 1035 
     | 
    
         
            +
                    # @param pay_to_address [Hash] Specifies the address to which payments for the claim should be sent.Request of type CandidApiClient::Commons::Types::StreetAddressLongZip, as a Hash
         
     | 
| 
       711 
1036 
     | 
    
         
             
                    #   * :zip_plus_four_code (String)
         
     | 
| 
       712 
1037 
     | 
    
         
             
                    #   * :address_1 (String)
         
     | 
| 
       713 
1038 
     | 
    
         
             
                    #   * :address_2 (String)
         
     | 
| 
       714 
1039 
     | 
    
         
             
                    #   * :city (String)
         
     | 
| 
       715 
     | 
    
         
            -
                    #   * :state (Commons::State)
         
     | 
| 
      
 1040 
     | 
    
         
            +
                    #   * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       716 
1041 
     | 
    
         
             
                    #   * :zip_code (String)
         
     | 
| 
       717 
     | 
    
         
            -
                    # @param synchronicity [Encounters::V4::SynchronicityType] Whether or not this was a synchronous or asynchronous encounter.
         
     | 
| 
       718 
     | 
    
         
            -
                    # 
     | 
| 
       719 
     | 
    
         
            -
                    # 
     | 
| 
       720 
     | 
    
         
            -
                    # 
     | 
| 
       721 
     | 
    
         
            -
                    # 
     | 
| 
       722 
     | 
    
         
            -
                    # 
     | 
| 
       723 
     | 
    
         
            -
                    # 
     | 
| 
       724 
     | 
    
         
            -
                    # 
     | 
| 
       725 
     | 
    
         
            -
                    #  
     | 
| 
      
 1042 
     | 
    
         
            +
                    # @param synchronicity [CandidApiClient::Encounters::V4::Types::SynchronicityType] Whether or not this was a synchronous or asynchronous encounter.
         
     | 
| 
      
 1043 
     | 
    
         
            +
                    #  Asynchronous encounters occur when providers and patients communicate online
         
     | 
| 
      
 1044 
     | 
    
         
            +
                    #  using
         
     | 
| 
      
 1045 
     | 
    
         
            +
                    #  forms, instant messaging, or other pre-recorded digital mediums.
         
     | 
| 
      
 1046 
     | 
    
         
            +
                    #  Synchronous encounters occur in live, real-time settings where the patient
         
     | 
| 
      
 1047 
     | 
    
         
            +
                    #  interacts
         
     | 
| 
      
 1048 
     | 
    
         
            +
                    #  directly with the provider, such as over video or a phone call.
         
     | 
| 
      
 1049 
     | 
    
         
            +
                    # @param billable_status [CandidApiClient::Encounters::V4::Types::BillableStatusType] Defines if the Encounter is to be billed by Candid to the responsible_party.
         
     | 
| 
      
 1050 
     | 
    
         
            +
                    #  Examples for when this should be set to NOT_BILLABLE include
         
     | 
| 
      
 1051 
     | 
    
         
            +
                    #  if the Encounter has not occurred yet or if there is no intention of ever
         
     | 
| 
      
 1052 
     | 
    
         
            +
                    #  billing the responsible_party.
         
     | 
| 
      
 1053 
     | 
    
         
            +
                    # @param responsible_party [CandidApiClient::Encounters::V4::Types::ResponsiblePartyType] Defines the party to be billed with the initial balance owed on the claim.
         
     | 
| 
       726 
1054 
     | 
    
         
             
                    # @param additional_information [String] Defines additional information on the claim needed by the payer.
         
     | 
| 
       727 
     | 
    
         
            -
                    # 
     | 
| 
       728 
     | 
    
         
            -
                    # @param service_authorization_exception_code [Encounters::V4::ServiceAuthorizationExceptionCode] 837p Loop2300 REF\*4N
         
     | 
| 
       729 
     | 
    
         
            -
                    # 
     | 
| 
       730 
     | 
    
         
            -
                    # 
     | 
| 
       731 
     | 
    
         
            -
                    # 
     | 
| 
       732 
     | 
    
         
            -
                    #  
     | 
| 
       733 
     | 
    
         
            -
                    # 
     | 
| 
       734 
     | 
    
         
            -
                    # 
     | 
| 
       735 
     | 
    
         
            -
                    # 
     | 
| 
       736 
     | 
    
         
            -
                    #  
     | 
| 
       737 
     | 
    
         
            -
                    # 
     | 
| 
       738 
     | 
    
         
            -
                    #  
     | 
| 
       739 
     | 
    
         
            -
                    # 
     | 
| 
       740 
     | 
    
         
            -
                    # 
     | 
| 
       741 
     | 
    
         
            -
                    # 
     | 
| 
       742 
     | 
    
         
            -
                    # @param  
     | 
| 
       743 
     | 
    
         
            -
                    # 
     | 
| 
       744 
     | 
    
         
            -
                    #  
     | 
| 
       745 
     | 
    
         
            -
                    # 
     | 
| 
      
 1055 
     | 
    
         
            +
                    #  Box 19 on the CMS-1500 claim form.
         
     | 
| 
      
 1056 
     | 
    
         
            +
                    # @param service_authorization_exception_code [CandidApiClient::Encounters::V4::Types::ServiceAuthorizationExceptionCode] 837p Loop2300 REF\*4N
         
     | 
| 
      
 1057 
     | 
    
         
            +
                    #  Required when mandated by government law or regulation to obtain authorization
         
     | 
| 
      
 1058 
     | 
    
         
            +
                    #  for specific service(s) but, for the
         
     | 
| 
      
 1059 
     | 
    
         
            +
                    #  reasons listed in one of the enum values of ServiceAuthorizationExceptionCode,
         
     | 
| 
      
 1060 
     | 
    
         
            +
                    #  the service was performed without
         
     | 
| 
      
 1061 
     | 
    
         
            +
                    #  obtaining the authorization.
         
     | 
| 
      
 1062 
     | 
    
         
            +
                    # @param admission_date [Date] 837p Loop2300 DTP\*435, CMS-1500 Box 18
         
     | 
| 
      
 1063 
     | 
    
         
            +
                    #  Required on all ambulance claims when the patient was known to be admitted to
         
     | 
| 
      
 1064 
     | 
    
         
            +
                    #  the hospital.
         
     | 
| 
      
 1065 
     | 
    
         
            +
                    #  OR
         
     | 
| 
      
 1066 
     | 
    
         
            +
                    #  Required on all claims involving inpatient medical visits.
         
     | 
| 
      
 1067 
     | 
    
         
            +
                    # @param discharge_date [Date] 837p Loop2300 DTP\*096, CMS-1500 Box 18
         
     | 
| 
      
 1068 
     | 
    
         
            +
                    #  Required for inpatient claims when the patient was discharged from the facility
         
     | 
| 
      
 1069 
     | 
    
         
            +
                    #  and the discharge date is known.
         
     | 
| 
      
 1070 
     | 
    
         
            +
                    # @param onset_of_current_illness_or_symptom_date [Date] 837p Loop2300 DTP\*431, CMS-1500 Box 14
         
     | 
| 
      
 1071 
     | 
    
         
            +
                    #  Required for the initial medical service or visit performed in response to a
         
     | 
| 
      
 1072 
     | 
    
         
            +
                    #  medical emergency when the date is available and is different than the date of
         
     | 
| 
      
 1073 
     | 
    
         
            +
                    #  service.
         
     | 
| 
      
 1074 
     | 
    
         
            +
                    #  OR
         
     | 
| 
      
 1075 
     | 
    
         
            +
                    #  This date is the onset of acute symptoms for the current illness or condition.
         
     | 
| 
      
 1076 
     | 
    
         
            +
                    # @param last_menstrual_period_date [Date] 837p Loop2300 DTP\*484, CMS-1500 Box 14
         
     | 
| 
      
 1077 
     | 
    
         
            +
                    #  Required when, in the judgment of the provider, the services on this claim are
         
     | 
| 
      
 1078 
     | 
    
         
            +
                    #  related to the patient's pregnancy.
         
     | 
| 
      
 1079 
     | 
    
         
            +
                    # @param delay_reason_code [CandidApiClient::Commons::Types::DelayReasonCode] 837i Loop2300, CLM-1300 Box 20
         
     | 
| 
      
 1080 
     | 
    
         
            +
                    #  Code indicating the reason why a request was delayed
         
     | 
| 
       746 
1081 
     | 
    
         
             
                    # @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
         
     | 
| 
       747 
     | 
    
         
            -
                    # @param  
     | 
| 
       748 
     | 
    
         
            -
                    # 
     | 
| 
       749 
     | 
    
         
            -
                    # 
     | 
| 
       750 
     | 
    
         
            -
                    # 
     | 
| 
       751 
     | 
    
         
            -
                    # 
     | 
| 
       752 
     | 
    
         
            -
                    # 
     | 
| 
       753 
     | 
    
         
            -
                    #  
     | 
| 
       754 
     | 
    
         
            -
                    # 
     | 
| 
       755 
     | 
    
         
            -
                    # 
     | 
| 
       756 
     | 
    
         
            -
                    # 
     | 
| 
       757 
     | 
    
         
            -
                    # 
     | 
| 
       758 
     | 
    
         
            -
                    #  
     | 
| 
       759 
     | 
    
         
            -
                    # 
     | 
| 
      
 1082 
     | 
    
         
            +
                    # @param _field_set [Object]
         
     | 
| 
      
 1083 
     | 
    
         
            +
                    # @param date_of_service [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-24.
         
     | 
| 
      
 1084 
     | 
    
         
            +
                    #  This date must be the local date in the timezone where the service occurred.
         
     | 
| 
      
 1085 
     | 
    
         
            +
                    #  Box 24a on the CMS-1500 claim form.
         
     | 
| 
      
 1086 
     | 
    
         
            +
                    #  If service occurred over a range of dates, this should be the start date.
         
     | 
| 
      
 1087 
     | 
    
         
            +
                    #  date_of_service must be defined on either the encounter or the service lines but
         
     | 
| 
      
 1088 
     | 
    
         
            +
                    #  not both.
         
     | 
| 
      
 1089 
     | 
    
         
            +
                    #  If there are greater than zero service lines, it is recommended to specify
         
     | 
| 
      
 1090 
     | 
    
         
            +
                    #  date_of_service on the service_line instead of on the encounter to prepare for
         
     | 
| 
      
 1091 
     | 
    
         
            +
                    #  future API versions.
         
     | 
| 
      
 1092 
     | 
    
         
            +
                    # @param end_date_of_service [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-25.
         
     | 
| 
      
 1093 
     | 
    
         
            +
                    #  This date must be the local date in the timezone where the service occurred.
         
     | 
| 
      
 1094 
     | 
    
         
            +
                    #  If omitted, the Encounter is assumed to be for a single day.
         
     | 
| 
      
 1095 
     | 
    
         
            +
                    #  Must not be temporally before the date_of_service field.
         
     | 
| 
      
 1096 
     | 
    
         
            +
                    #  If there are greater than zero service lines, it is recommended to specify
         
     | 
| 
      
 1097 
     | 
    
         
            +
                    #  end_date_of_service on the service_line instead of on the encounter to prepare
         
     | 
| 
      
 1098 
     | 
    
         
            +
                    #  for future API versions.
         
     | 
| 
      
 1099 
     | 
    
         
            +
                    # @param patient [Hash] Contains the identification information of the individual receiving medical
         
     | 
| 
      
 1100 
     | 
    
         
            +
                    #  services.Request of type CandidApiClient::Individual::Types::PatientCreate, as a Hash
         
     | 
| 
      
 1101 
     | 
    
         
            +
                    #   * :phone_numbers (Array<CandidApiClient::Commons::Types::PhoneNumber>)
         
     | 
| 
       760 
1102 
     | 
    
         
             
                    #   * :phone_consent (Boolean)
         
     | 
| 
       761 
     | 
    
         
            -
                    #   * :email ( 
     | 
| 
      
 1103 
     | 
    
         
            +
                    #   * :email (String)
         
     | 
| 
       762 
1104 
     | 
    
         
             
                    #   * :email_consent (Boolean)
         
     | 
| 
       763 
1105 
     | 
    
         
             
                    #   * :external_id (String)
         
     | 
| 
       764 
     | 
    
         
            -
                    #   * :date_of_birth ( 
     | 
| 
      
 1106 
     | 
    
         
            +
                    #   * :date_of_birth (Date)
         
     | 
| 
       765 
1107 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       766 
1108 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       767 
1109 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       768 
1110 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       769 
1111 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       770 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 1112 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       771 
1113 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       772 
1114 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       773 
1115 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       774 
     | 
    
         
            -
                    #   * :gender (Individual::Gender)
         
     | 
| 
       775 
     | 
    
         
            -
                    # @param billing_provider [Hash] The billing provider is the provider or business entity submitting the claim. 
     | 
| 
      
 1116 
     | 
    
         
            +
                    #   * :gender (CandidApiClient::Individual::Types::Gender)
         
     | 
| 
      
 1117 
     | 
    
         
            +
                    # @param billing_provider [Hash] The billing provider is the provider or business entity submitting the claim.
         
     | 
| 
      
 1118 
     | 
    
         
            +
                    #  Billing provider may be, but is not necessarily, the same person/NPI as the
         
     | 
| 
      
 1119 
     | 
    
         
            +
                    #  rendering provider. From a payer's perspective, this represents the person or
         
     | 
| 
      
 1120 
     | 
    
         
            +
                    #  entity being reimbursed. When a contract exists with the target payer, the
         
     | 
| 
      
 1121 
     | 
    
         
            +
                    #  billing provider should be the entity contracted with the payer. In some
         
     | 
| 
      
 1122 
     | 
    
         
            +
                    #  circumstances, this will be an individual provider. In that case, submit that
         
     | 
| 
      
 1123 
     | 
    
         
            +
                    #  provider's NPI and the tax ID (TIN) that the provider gave to the payer during
         
     | 
| 
      
 1124 
     | 
    
         
            +
                    #  contracting. In other cases, the billing entity will be a medical group. If so,
         
     | 
| 
      
 1125 
     | 
    
         
            +
                    #  submit the group NPI and the group's tax ID. Box 33 on the CMS-1500 claim form.Request of type CandidApiClient::EncounterProviders::V2::Types::BillingProvider, as a Hash
         
     | 
| 
       776 
1126 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       777 
1127 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       778 
1128 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       779 
1129 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       780 
1130 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       781 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 1131 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       782 
1132 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       783 
1133 
     | 
    
         
             
                    #   * :tax_id (String)
         
     | 
| 
       784 
1134 
     | 
    
         
             
                    #   * :npi (String)
         
     | 
| 
         @@ -786,25 +1136,77 @@ module CandidApiClient 
     | 
|
| 
       786 
1136 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       787 
1137 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       788 
1138 
     | 
    
         
             
                    #   * :organization_name (String)
         
     | 
| 
       789 
     | 
    
         
            -
                    # @param rendering_provider [Hash] The rendering provider is the practitioner -- physician, nurse practitioner, 
     | 
| 
       790 
     | 
    
         
            -
                    # 
     | 
| 
      
 1139 
     | 
    
         
            +
                    # @param rendering_provider [Hash] The rendering provider is the practitioner -- physician, nurse practitioner,
         
     | 
| 
      
 1140 
     | 
    
         
            +
                    #  etc. -- performing the service.
         
     | 
| 
      
 1141 
     | 
    
         
            +
                    #  For telehealth services, the rendering provider performs the visit, asynchronous
         
     | 
| 
      
 1142 
     | 
    
         
            +
                    #  communication, or other service. The rendering provider address should generally
         
     | 
| 
      
 1143 
     | 
    
         
            +
                    #  be the same as the service facility address.Request of type CandidApiClient::EncounterProviders::V2::Types::RenderingProvider, as a Hash
         
     | 
| 
      
 1144 
     | 
    
         
            +
                    #   * :address (Hash)
         
     | 
| 
      
 1145 
     | 
    
         
            +
                    #     * :zip_plus_four_code (String)
         
     | 
| 
      
 1146 
     | 
    
         
            +
                    #     * :address_1 (String)
         
     | 
| 
      
 1147 
     | 
    
         
            +
                    #     * :address_2 (String)
         
     | 
| 
      
 1148 
     | 
    
         
            +
                    #     * :city (String)
         
     | 
| 
      
 1149 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 1150 
     | 
    
         
            +
                    #     * :zip_code (String)
         
     | 
| 
      
 1151 
     | 
    
         
            +
                    #   * :npi (String)
         
     | 
| 
      
 1152 
     | 
    
         
            +
                    #   * :taxonomy_code (String)
         
     | 
| 
      
 1153 
     | 
    
         
            +
                    #   * :first_name (String)
         
     | 
| 
      
 1154 
     | 
    
         
            +
                    #   * :last_name (String)
         
     | 
| 
      
 1155 
     | 
    
         
            +
                    #   * :organization_name (String)
         
     | 
| 
      
 1156 
     | 
    
         
            +
                    # @param referring_provider [Hash] The final provider who referred the services that were rendered.
         
     | 
| 
      
 1157 
     | 
    
         
            +
                    #  All physicians who order services or refer Medicare beneficiaries must
         
     | 
| 
      
 1158 
     | 
    
         
            +
                    #  report this data.Request of type CandidApiClient::EncounterProviders::V2::Types::ReferringProvider, as a Hash
         
     | 
| 
      
 1159 
     | 
    
         
            +
                    #   * :npi (String)
         
     | 
| 
      
 1160 
     | 
    
         
            +
                    #   * :taxonomy_code (String)
         
     | 
| 
      
 1161 
     | 
    
         
            +
                    #   * :address (Hash)
         
     | 
| 
      
 1162 
     | 
    
         
            +
                    #     * :zip_plus_four_code (String)
         
     | 
| 
      
 1163 
     | 
    
         
            +
                    #     * :address_1 (String)
         
     | 
| 
      
 1164 
     | 
    
         
            +
                    #     * :address_2 (String)
         
     | 
| 
      
 1165 
     | 
    
         
            +
                    #     * :city (String)
         
     | 
| 
      
 1166 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 1167 
     | 
    
         
            +
                    #     * :zip_code (String)
         
     | 
| 
      
 1168 
     | 
    
         
            +
                    #   * :first_name (String)
         
     | 
| 
      
 1169 
     | 
    
         
            +
                    #   * :last_name (String)
         
     | 
| 
      
 1170 
     | 
    
         
            +
                    #   * :organization_name (String)
         
     | 
| 
      
 1171 
     | 
    
         
            +
                    # @param initial_referring_provider [Hash] The second iteration of Loop ID-2310. Use code "P3 - Primary Care Provider" in
         
     | 
| 
      
 1172 
     | 
    
         
            +
                    #  this loop to
         
     | 
| 
      
 1173 
     | 
    
         
            +
                    #  indicate the initial referral from the primary care provider or whatever
         
     | 
| 
      
 1174 
     | 
    
         
            +
                    #  provider wrote the initial referral for this patient's episode of care being
         
     | 
| 
      
 1175 
     | 
    
         
            +
                    #  billed/reported in this transaction.
         
     | 
| 
      
 1176 
     | 
    
         
            +
                    #  Information in Loop ID-2310 applies to the entire claim unless overridden on a
         
     | 
| 
      
 1177 
     | 
    
         
            +
                    #  service line by the presence of Loop ID-2420 with the same value in NM101.Request of type CandidApiClient::EncounterProviders::V2::Types::InitialReferringProvider, as a Hash
         
     | 
| 
      
 1178 
     | 
    
         
            +
                    #   * :npi (String)
         
     | 
| 
      
 1179 
     | 
    
         
            +
                    #   * :taxonomy_code (String)
         
     | 
| 
       791 
1180 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       792 
1181 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       793 
1182 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       794 
1183 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       795 
1184 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       796 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 1185 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       797 
1186 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
      
 1187 
     | 
    
         
            +
                    #   * :qualifier (CandidApiClient::Commons::Types::QualifierCode)
         
     | 
| 
      
 1188 
     | 
    
         
            +
                    #   * :first_name (String)
         
     | 
| 
      
 1189 
     | 
    
         
            +
                    #   * :last_name (String)
         
     | 
| 
      
 1190 
     | 
    
         
            +
                    #   * :organization_name (String)
         
     | 
| 
      
 1191 
     | 
    
         
            +
                    # @param supervising_provider [Hash] Required when the rendering provider is supervised by a physician. If not
         
     | 
| 
      
 1192 
     | 
    
         
            +
                    #  required by this implementation guide, do not send.
         
     | 
| 
      
 1193 
     | 
    
         
            +
                    #  Information in Loop ID-2310 applies to the entire claim unless overridden on a
         
     | 
| 
      
 1194 
     | 
    
         
            +
                    #  service line by the presence of Loop ID-2420 with the same value in NM101.Request of type CandidApiClient::EncounterProviders::V2::Types::SupervisingProvider, as a Hash
         
     | 
| 
       798 
1195 
     | 
    
         
             
                    #   * :npi (String)
         
     | 
| 
       799 
1196 
     | 
    
         
             
                    #   * :taxonomy_code (String)
         
     | 
| 
      
 1197 
     | 
    
         
            +
                    #   * :address (Hash)
         
     | 
| 
      
 1198 
     | 
    
         
            +
                    #     * :zip_plus_four_code (String)
         
     | 
| 
      
 1199 
     | 
    
         
            +
                    #     * :address_1 (String)
         
     | 
| 
      
 1200 
     | 
    
         
            +
                    #     * :address_2 (String)
         
     | 
| 
      
 1201 
     | 
    
         
            +
                    #     * :city (String)
         
     | 
| 
      
 1202 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 1203 
     | 
    
         
            +
                    #     * :zip_code (String)
         
     | 
| 
       800 
1204 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       801 
1205 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       802 
1206 
     | 
    
         
             
                    #   * :organization_name (String)
         
     | 
| 
       803 
     | 
    
         
            -
                    # @param  
     | 
| 
       804 
     | 
    
         
            -
                    # 
     | 
| 
       805 
     | 
    
         
            -
                    # 
     | 
| 
       806 
     | 
    
         
            -
                    #   If a claim involves multiple referring physicians, create a separate
         
     | 
| 
       807 
     | 
    
         
            -
                    #   encounter for each physician.Request of type EncounterProviders::V2::ReferringProvider, as a Hash
         
     | 
| 
      
 1207 
     | 
    
         
            +
                    # @param ordering_provider [Hash] Required when the service or supply was ordered by a provider who is different
         
     | 
| 
      
 1208 
     | 
    
         
            +
                    #  than the rendering provider for this service line.
         
     | 
| 
      
 1209 
     | 
    
         
            +
                    #  If not required by this implementation guide, do not send.Request of type CandidApiClient::EncounterProviders::V2::Types::OrderingProvider, as a Hash
         
     | 
| 
       808 
1210 
     | 
    
         
             
                    #   * :npi (String)
         
     | 
| 
       809 
1211 
     | 
    
         
             
                    #   * :taxonomy_code (String)
         
     | 
| 
       810 
1212 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
         @@ -812,12 +1214,20 @@ module CandidApiClient 
     | 
|
| 
       812 
1214 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       813 
1215 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       814 
1216 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       815 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 1217 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       816 
1218 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       817 
1219 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       818 
1220 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       819 
1221 
     | 
    
         
             
                    #   * :organization_name (String)
         
     | 
| 
       820 
     | 
    
         
            -
                    # @param service_facility [Hash] Encounter Service facility is typically the location a medical service was 
     | 
| 
      
 1222 
     | 
    
         
            +
                    # @param service_facility [Hash] Encounter Service facility is typically the location a medical service was
         
     | 
| 
      
 1223 
     | 
    
         
            +
                    #  rendered, such as a provider office or hospital. For telehealth, service
         
     | 
| 
      
 1224 
     | 
    
         
            +
                    #  facility can represent the provider's location when the service was delivered
         
     | 
| 
      
 1225 
     | 
    
         
            +
                    #  (e.g., home), or the location where an in-person visit would have taken place,
         
     | 
| 
      
 1226 
     | 
    
         
            +
                    #  whichever is easier to identify. If the provider is in-network, service facility
         
     | 
| 
      
 1227 
     | 
    
         
            +
                    #  may be defined in payer contracts. Box 32 on the CMS-1500 claim form. Note that
         
     | 
| 
      
 1228 
     | 
    
         
            +
                    #  for an in-network claim to be successfully adjudicated, the service facility
         
     | 
| 
      
 1229 
     | 
    
         
            +
                    #  address listed on claims must match what was provided to the payer during the
         
     | 
| 
      
 1230 
     | 
    
         
            +
                    #  credentialing process.Request of type CandidApiClient::ServiceFacility::Types::EncounterServiceFacilityBase, as a Hash
         
     | 
| 
       821 
1231 
     | 
    
         
             
                    #   * :organization_name (String)
         
     | 
| 
       822 
1232 
     | 
    
         
             
                    #   * :npi (String)
         
     | 
| 
       823 
1233 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
         @@ -825,12 +1235,16 @@ module CandidApiClient 
     | 
|
| 
       825 
1235 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       826 
1236 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       827 
1237 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       828 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 1238 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       829 
1239 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       830 
     | 
    
         
            -
                    # @param subscriber_primary [Hash] Subscriber_primary is required when responsible_party is INSURANCE_PAY (i.e. 
     | 
| 
       831 
     | 
    
         
            -
                    # 
     | 
| 
       832 
     | 
    
         
            -
                    # 
     | 
| 
       833 
     | 
    
         
            -
                    # 
     | 
| 
      
 1240 
     | 
    
         
            +
                    # @param subscriber_primary [Hash] Subscriber_primary is required when responsible_party is INSURANCE_PAY (i.e.
         
     | 
| 
      
 1241 
     | 
    
         
            +
                    #  when the claim should be billed to insurance).
         
     | 
| 
      
 1242 
     | 
    
         
            +
                    #  These are not required fields when responsible_party is SELF_PAY (i.e. when the
         
     | 
| 
      
 1243 
     | 
    
         
            +
                    #  claim should be billed to the patient).
         
     | 
| 
      
 1244 
     | 
    
         
            +
                    #  However, if you collect this for patients, even self-pay, we recommend including
         
     | 
| 
      
 1245 
     | 
    
         
            +
                    #  it when sending encounters to Candid.
         
     | 
| 
      
 1246 
     | 
    
         
            +
                    #  Note: Cash Pay is no longer a valid payer_id in v4, please use responsible party
         
     | 
| 
      
 1247 
     | 
    
         
            +
                    #  to define self-pay claims.Request of type CandidApiClient::Individual::Types::SubscriberCreate, as a Hash
         
     | 
| 
       834 
1248 
     | 
    
         
             
                    #   * :insurance_card (Hash)
         
     | 
| 
       835 
1249 
     | 
    
         
             
                    #     * :member_id (String)
         
     | 
| 
       836 
1250 
     | 
    
         
             
                    #     * :payer_name (String)
         
     | 
| 
         @@ -839,24 +1253,24 @@ module CandidApiClient 
     | 
|
| 
       839 
1253 
     | 
    
         
             
                    #     * :rx_pcn (String)
         
     | 
| 
       840 
1254 
     | 
    
         
             
                    #     * :image_url_front (String)
         
     | 
| 
       841 
1255 
     | 
    
         
             
                    #     * :image_url_back (String)
         
     | 
| 
       842 
     | 
    
         
            -
                    #     * :emr_payer_crosswalk (Commons::EmrPayerCrosswalk)
         
     | 
| 
      
 1256 
     | 
    
         
            +
                    #     * :emr_payer_crosswalk (CandidApiClient::Commons::Types::EmrPayerCrosswalk)
         
     | 
| 
       843 
1257 
     | 
    
         
             
                    #     * :group_number (String)
         
     | 
| 
       844 
1258 
     | 
    
         
             
                    #     * :plan_name (String)
         
     | 
| 
       845 
     | 
    
         
            -
                    #     * :plan_type (Commons::SourceOfPaymentCode)
         
     | 
| 
       846 
     | 
    
         
            -
                    #     * :insurance_type (Commons::InsuranceTypeCode)
         
     | 
| 
       847 
     | 
    
         
            -
                    #   * :patient_relationship_to_subscriber_code (Commons::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
       848 
     | 
    
         
            -
                    #   * :date_of_birth ( 
     | 
| 
      
 1259 
     | 
    
         
            +
                    #     * :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)
         
     | 
| 
      
 1260 
     | 
    
         
            +
                    #     * :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)
         
     | 
| 
      
 1261 
     | 
    
         
            +
                    #   * :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
      
 1262 
     | 
    
         
            +
                    #   * :date_of_birth (Date)
         
     | 
| 
       849 
1263 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       850 
1264 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       851 
1265 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       852 
1266 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       853 
1267 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       854 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 1268 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       855 
1269 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       856 
1270 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       857 
1271 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       858 
     | 
    
         
            -
                    #   * :gender (Individual::Gender)
         
     | 
| 
       859 
     | 
    
         
            -
                    # @param subscriber_secondary [Hash] Please always include this when you have it, even for self-pay claims.Request of type Individual::SubscriberCreate, as a Hash
         
     | 
| 
      
 1272 
     | 
    
         
            +
                    #   * :gender (CandidApiClient::Individual::Types::Gender)
         
     | 
| 
      
 1273 
     | 
    
         
            +
                    # @param subscriber_secondary [Hash] Please always include this when you have it, even for self-pay claims.Request of type CandidApiClient::Individual::Types::SubscriberCreate, as a Hash
         
     | 
| 
       860 
1274 
     | 
    
         
             
                    #   * :insurance_card (Hash)
         
     | 
| 
       861 
1275 
     | 
    
         
             
                    #     * :member_id (String)
         
     | 
| 
       862 
1276 
     | 
    
         
             
                    #     * :payer_name (String)
         
     | 
| 
         @@ -865,63 +1279,121 @@ module CandidApiClient 
     | 
|
| 
       865 
1279 
     | 
    
         
             
                    #     * :rx_pcn (String)
         
     | 
| 
       866 
1280 
     | 
    
         
             
                    #     * :image_url_front (String)
         
     | 
| 
       867 
1281 
     | 
    
         
             
                    #     * :image_url_back (String)
         
     | 
| 
       868 
     | 
    
         
            -
                    #     * :emr_payer_crosswalk (Commons::EmrPayerCrosswalk)
         
     | 
| 
      
 1282 
     | 
    
         
            +
                    #     * :emr_payer_crosswalk (CandidApiClient::Commons::Types::EmrPayerCrosswalk)
         
     | 
| 
       869 
1283 
     | 
    
         
             
                    #     * :group_number (String)
         
     | 
| 
       870 
1284 
     | 
    
         
             
                    #     * :plan_name (String)
         
     | 
| 
       871 
     | 
    
         
            -
                    #     * :plan_type (Commons::SourceOfPaymentCode)
         
     | 
| 
       872 
     | 
    
         
            -
                    #     * :insurance_type (Commons::InsuranceTypeCode)
         
     | 
| 
       873 
     | 
    
         
            -
                    #   * :patient_relationship_to_subscriber_code (Commons::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
       874 
     | 
    
         
            -
                    #   * :date_of_birth ( 
     | 
| 
      
 1285 
     | 
    
         
            +
                    #     * :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)
         
     | 
| 
      
 1286 
     | 
    
         
            +
                    #     * :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)
         
     | 
| 
      
 1287 
     | 
    
         
            +
                    #   * :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
      
 1288 
     | 
    
         
            +
                    #   * :date_of_birth (Date)
         
     | 
| 
       875 
1289 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       876 
1290 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       877 
1291 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       878 
1292 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       879 
1293 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       880 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 1294 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       881 
1295 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       882 
1296 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       883 
1297 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       884 
     | 
    
         
            -
                    #   * :gender (Individual::Gender)
         
     | 
| 
       885 
     | 
    
         
            -
                    # @param diagnoses [Array<Hash>] Ideally, this field should contain no more than 12 diagnoses. However, more 
     | 
| 
       886 
     | 
    
         
            -
                    # 
     | 
| 
       887 
     | 
    
         
            -
                    # 
     | 
| 
      
 1298 
     | 
    
         
            +
                    #   * :gender (CandidApiClient::Individual::Types::Gender)
         
     | 
| 
      
 1299 
     | 
    
         
            +
                    # @param diagnoses [Array<Hash>] Ideally, this field should contain no more than 12 diagnoses. However, more
         
     | 
| 
      
 1300 
     | 
    
         
            +
                    #  diagnoses
         
     | 
| 
      
 1301 
     | 
    
         
            +
                    #  may be submitted at this time, and coders will later prioritize the 12 that will
         
     | 
| 
      
 1302 
     | 
    
         
            +
                    #  be
         
     | 
| 
      
 1303 
     | 
    
         
            +
                    #  submitted to the payor.Request of type Array<CandidApiClient::Diagnoses::Types::DiagnosisCreate>, as a Hash
         
     | 
| 
       888 
1304 
     | 
    
         
             
                    #   * :name (String)
         
     | 
| 
       889 
     | 
    
         
            -
                    #   * :code_type (Diagnoses::DiagnosisTypeCode)
         
     | 
| 
      
 1305 
     | 
    
         
            +
                    #   * :code_type (CandidApiClient::Diagnoses::Types::DiagnosisTypeCode)
         
     | 
| 
       890 
1306 
     | 
    
         
             
                    #   * :code (String)
         
     | 
| 
       891 
     | 
    
         
            -
                    # @param clinical_notes [Array<Hash>] Holds a collection of clinical observations made by healthcare providers during 
     | 
| 
       892 
     | 
    
         
            -
                    # 
     | 
| 
       893 
     | 
    
         
            -
                    #   * : 
     | 
| 
      
 1307 
     | 
    
         
            +
                    # @param clinical_notes [Array<Hash>] Holds a collection of clinical observations made by healthcare providers during
         
     | 
| 
      
 1308 
     | 
    
         
            +
                    #  patient encounters.Request of type Array<CandidApiClient::Encounters::V4::Types::ClinicalNoteCategoryCreate>, as a Hash
         
     | 
| 
      
 1309 
     | 
    
         
            +
                    #   * :category (CandidApiClient::Encounters::V4::Types::NoteCategory)
         
     | 
| 
      
 1310 
     | 
    
         
            +
                    #   * :notes (Array<CandidApiClient::Encounters::V4::Types::ClinicalNote>)
         
     | 
| 
       894 
1311 
     | 
    
         
             
                    # @param billing_notes [Array<Hash>] Spot to store misc, human-readable, notes about this encounter to be used
         
     | 
| 
       895 
     | 
    
         
            -
                    # 
     | 
| 
      
 1312 
     | 
    
         
            +
                    #  in the billing process.Request of type Array<CandidApiClient::BillingNotes::V2::Types::BillingNoteBase>, as a Hash
         
     | 
| 
       896 
1313 
     | 
    
         
             
                    #   * :text (String)
         
     | 
| 
       897 
     | 
    
         
            -
                    # @param place_of_service_code [Commons::FacilityTypeCode] Box 24B on the CMS-1500 claim form. Line-level place of service is not currently 
     | 
| 
       898 
     | 
    
         
            -
                    #  
     | 
| 
       899 
     | 
    
         
            -
                    # 
     | 
| 
       900 
     | 
    
         
            -
                    # 
     | 
| 
      
 1314 
     | 
    
         
            +
                    # @param place_of_service_code [CandidApiClient::Commons::Types::FacilityTypeCode] Box 24B on the CMS-1500 claim form. Line-level place of service is not currently
         
     | 
| 
      
 1315 
     | 
    
         
            +
                    #  supported. 02 for telemedicine, 11 for in-person. Full list
         
     | 
| 
      
 1316 
     | 
    
         
            +
                    #  //www.cms.gov/Medicare/Coding/place-of-service-codes/Place_of_Service_Code_Set).
         
     | 
| 
      
 1317 
     | 
    
         
            +
                    # @param patient_histories [Array<Hash>] Request of type Array<CandidApiClient::Encounters::V4::Types::PatientHistoryCategory>, as a Hash
         
     | 
| 
      
 1318 
     | 
    
         
            +
                    #   * :category (CandidApiClient::Encounters::V4::Types::PatientHistoryCategoryEnum)
         
     | 
| 
      
 1319 
     | 
    
         
            +
                    #   * :questions (Array<CandidApiClient::Encounters::V4::Types::IntakeQuestion>)
         
     | 
| 
       901 
1320 
     | 
    
         
             
                    # @param service_lines [Array<Hash>] Each service line must be linked to a diagnosis. Concretely,
         
     | 
| 
       902 
     | 
    
         
            -
                    # 
     | 
| 
       903 
     | 
    
         
            -
                    # 
     | 
| 
       904 
     | 
    
         
            -
                    #   * :modifiers (Array<Commons::ProcedureModifier>)
         
     | 
| 
      
 1321 
     | 
    
         
            +
                    #  `service_line.diagnosis_pointers`must contain at least one entry which should be
         
     | 
| 
      
 1322 
     | 
    
         
            +
                    #  in bounds of the diagnoses list field.Request of type Array<CandidApiClient::ServiceLines::V2::Types::ServiceLineCreate>, as a Hash
         
     | 
| 
      
 1323 
     | 
    
         
            +
                    #   * :modifiers (Array<CandidApiClient::Commons::Types::ProcedureModifier>)
         
     | 
| 
       905 
1324 
     | 
    
         
             
                    #   * :procedure_code (String)
         
     | 
| 
       906 
     | 
    
         
            -
                    #   * :quantity ( 
     | 
| 
       907 
     | 
    
         
            -
                    #   * :units (Commons::ServiceLineUnits)
         
     | 
| 
      
 1325 
     | 
    
         
            +
                    #   * :quantity (String)
         
     | 
| 
      
 1326 
     | 
    
         
            +
                    #   * :units (CandidApiClient::Commons::Types::ServiceLineUnits)
         
     | 
| 
       908 
1327 
     | 
    
         
             
                    #   * :charge_amount_cents (Integer)
         
     | 
| 
       909 
1328 
     | 
    
         
             
                    #   * :diagnosis_pointers (Array<Integer>)
         
     | 
| 
       910 
1329 
     | 
    
         
             
                    #   * :drug_identification (Hash)
         
     | 
| 
       911 
     | 
    
         
            -
                    #     * :service_id_qualifier (ServiceLines::V2::ServiceIdQualifier)
         
     | 
| 
      
 1330 
     | 
    
         
            +
                    #     * :service_id_qualifier (CandidApiClient::ServiceLines::V2::Types::ServiceIdQualifier)
         
     | 
| 
       912 
1331 
     | 
    
         
             
                    #     * :national_drug_code (String)
         
     | 
| 
       913 
1332 
     | 
    
         
             
                    #     * :national_drug_unit_count (String)
         
     | 
| 
       914 
     | 
    
         
            -
                    #     * :measurement_unit_code (ServiceLines::V2::MeasurementUnitCode)
         
     | 
| 
      
 1333 
     | 
    
         
            +
                    #     * :measurement_unit_code (CandidApiClient::ServiceLines::V2::Types::MeasurementUnitCode)
         
     | 
| 
       915 
1334 
     | 
    
         
             
                    #     * :link_sequence_number (String)
         
     | 
| 
       916 
1335 
     | 
    
         
             
                    #     * :pharmacy_prescription_number (String)
         
     | 
| 
       917 
     | 
    
         
            -
                    #   * :place_of_service_code (Commons::FacilityTypeCode)
         
     | 
| 
      
 1336 
     | 
    
         
            +
                    #   * :place_of_service_code (CandidApiClient::Commons::Types::FacilityTypeCode)
         
     | 
| 
       918 
1337 
     | 
    
         
             
                    #   * :description (String)
         
     | 
| 
       919 
1338 
     | 
    
         
             
                    #   * :date_of_service (Date)
         
     | 
| 
       920 
1339 
     | 
    
         
             
                    #   * :end_date_of_service (Date)
         
     | 
| 
       921 
     | 
    
         
            -
                    #  
     | 
| 
       922 
     | 
    
         
            -
                    # 
     | 
| 
      
 1340 
     | 
    
         
            +
                    #   * :referring_provider (Hash)
         
     | 
| 
      
 1341 
     | 
    
         
            +
                    #     * :npi (String)
         
     | 
| 
      
 1342 
     | 
    
         
            +
                    #     * :taxonomy_code (String)
         
     | 
| 
      
 1343 
     | 
    
         
            +
                    #     * :address (Hash)
         
     | 
| 
      
 1344 
     | 
    
         
            +
                    #       * :zip_plus_four_code (String)
         
     | 
| 
      
 1345 
     | 
    
         
            +
                    #       * :address_1 (String)
         
     | 
| 
      
 1346 
     | 
    
         
            +
                    #       * :address_2 (String)
         
     | 
| 
      
 1347 
     | 
    
         
            +
                    #       * :city (String)
         
     | 
| 
      
 1348 
     | 
    
         
            +
                    #       * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 1349 
     | 
    
         
            +
                    #       * :zip_code (String)
         
     | 
| 
      
 1350 
     | 
    
         
            +
                    #     * :first_name (String)
         
     | 
| 
      
 1351 
     | 
    
         
            +
                    #     * :last_name (String)
         
     | 
| 
      
 1352 
     | 
    
         
            +
                    #     * :organization_name (String)
         
     | 
| 
      
 1353 
     | 
    
         
            +
                    #   * :initial_referring_provider (Hash)
         
     | 
| 
      
 1354 
     | 
    
         
            +
                    #     * :npi (String)
         
     | 
| 
      
 1355 
     | 
    
         
            +
                    #     * :taxonomy_code (String)
         
     | 
| 
      
 1356 
     | 
    
         
            +
                    #     * :address (Hash)
         
     | 
| 
      
 1357 
     | 
    
         
            +
                    #       * :zip_plus_four_code (String)
         
     | 
| 
      
 1358 
     | 
    
         
            +
                    #       * :address_1 (String)
         
     | 
| 
      
 1359 
     | 
    
         
            +
                    #       * :address_2 (String)
         
     | 
| 
      
 1360 
     | 
    
         
            +
                    #       * :city (String)
         
     | 
| 
      
 1361 
     | 
    
         
            +
                    #       * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 1362 
     | 
    
         
            +
                    #       * :zip_code (String)
         
     | 
| 
      
 1363 
     | 
    
         
            +
                    #     * :qualifier (CandidApiClient::Commons::Types::QualifierCode)
         
     | 
| 
      
 1364 
     | 
    
         
            +
                    #     * :first_name (String)
         
     | 
| 
      
 1365 
     | 
    
         
            +
                    #     * :last_name (String)
         
     | 
| 
      
 1366 
     | 
    
         
            +
                    #     * :organization_name (String)
         
     | 
| 
      
 1367 
     | 
    
         
            +
                    #   * :supervising_provider (Hash)
         
     | 
| 
      
 1368 
     | 
    
         
            +
                    #     * :npi (String)
         
     | 
| 
      
 1369 
     | 
    
         
            +
                    #     * :taxonomy_code (String)
         
     | 
| 
      
 1370 
     | 
    
         
            +
                    #     * :address (Hash)
         
     | 
| 
      
 1371 
     | 
    
         
            +
                    #       * :zip_plus_four_code (String)
         
     | 
| 
      
 1372 
     | 
    
         
            +
                    #       * :address_1 (String)
         
     | 
| 
      
 1373 
     | 
    
         
            +
                    #       * :address_2 (String)
         
     | 
| 
      
 1374 
     | 
    
         
            +
                    #       * :city (String)
         
     | 
| 
      
 1375 
     | 
    
         
            +
                    #       * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 1376 
     | 
    
         
            +
                    #       * :zip_code (String)
         
     | 
| 
      
 1377 
     | 
    
         
            +
                    #     * :first_name (String)
         
     | 
| 
      
 1378 
     | 
    
         
            +
                    #     * :last_name (String)
         
     | 
| 
      
 1379 
     | 
    
         
            +
                    #     * :organization_name (String)
         
     | 
| 
      
 1380 
     | 
    
         
            +
                    #   * :ordering_provider (Hash)
         
     | 
| 
      
 1381 
     | 
    
         
            +
                    #     * :npi (String)
         
     | 
| 
      
 1382 
     | 
    
         
            +
                    #     * :taxonomy_code (String)
         
     | 
| 
      
 1383 
     | 
    
         
            +
                    #     * :address (Hash)
         
     | 
| 
      
 1384 
     | 
    
         
            +
                    #       * :zip_plus_four_code (String)
         
     | 
| 
      
 1385 
     | 
    
         
            +
                    #       * :address_1 (String)
         
     | 
| 
      
 1386 
     | 
    
         
            +
                    #       * :address_2 (String)
         
     | 
| 
      
 1387 
     | 
    
         
            +
                    #       * :city (String)
         
     | 
| 
      
 1388 
     | 
    
         
            +
                    #       * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
      
 1389 
     | 
    
         
            +
                    #       * :zip_code (String)
         
     | 
| 
      
 1390 
     | 
    
         
            +
                    #     * :first_name (String)
         
     | 
| 
      
 1391 
     | 
    
         
            +
                    #     * :last_name (String)
         
     | 
| 
      
 1392 
     | 
    
         
            +
                    #     * :organization_name (String)
         
     | 
| 
      
 1393 
     | 
    
         
            +
                    # @param guarantor [Hash] Personal and contact info for the guarantor of the patient responsibility.Request of type CandidApiClient::Guarantor::V1::Types::GuarantorCreate, as a Hash
         
     | 
| 
      
 1394 
     | 
    
         
            +
                    #   * :phone_numbers (Array<CandidApiClient::Commons::Types::PhoneNumber>)
         
     | 
| 
       923 
1395 
     | 
    
         
             
                    #   * :phone_consent (Boolean)
         
     | 
| 
       924 
     | 
    
         
            -
                    #   * :email ( 
     | 
| 
      
 1396 
     | 
    
         
            +
                    #   * :email (String)
         
     | 
| 
       925 
1397 
     | 
    
         
             
                    #   * :email_consent (Boolean)
         
     | 
| 
       926 
1398 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       927 
1399 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
         @@ -932,24 +1404,54 @@ module CandidApiClient 
     | 
|
| 
       932 
1404 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       933 
1405 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       934 
1406 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       935 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 1407 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       936 
1408 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       937 
1409 
     | 
    
         
             
                    # @param external_claim_submission [Hash] ***This field is in beta.***
         
     | 
| 
       938 
     | 
    
         
            -
                    # 
     | 
| 
       939 
     | 
    
         
            -
                    # 
     | 
| 
      
 1410 
     | 
    
         
            +
                    #  To be included for claims that have been submitted outside of Candid.
         
     | 
| 
      
 1411 
     | 
    
         
            +
                    #  Candid supports posting remits and payments to these claims and working them
         
     | 
| 
      
 1412 
     | 
    
         
            +
                    #  in-platform (e.g. editing, resubmitting).Request of type CandidApiClient::ClaimSubmission::V1::Types::ExternalClaimSubmissionCreate, as a Hash
         
     | 
| 
       940 
1413 
     | 
    
         
             
                    #   * :claim_created_at (DateTime)
         
     | 
| 
       941 
1414 
     | 
    
         
             
                    #   * :patient_control_number (String)
         
     | 
| 
       942 
     | 
    
         
            -
                    #   * :submission_records (Array<ClaimSubmission::V1::ClaimSubmissionRecordCreate>)
         
     | 
| 
       943 
     | 
    
         
            -
                    # @param tag_ids [Array< 
     | 
| 
       944 
     | 
    
         
            -
                    # @param request_options [RequestOptions]
         
     | 
| 
       945 
     | 
    
         
            -
                    # @return [Encounters::V4::Encounter]
         
     | 
| 
      
 1415 
     | 
    
         
            +
                    #   * :submission_records (Array<CandidApiClient::ClaimSubmission::V1::Types::ClaimSubmissionRecordCreate>)
         
     | 
| 
      
 1416 
     | 
    
         
            +
                    # @param tag_ids [Array<String>] Names of tags that should be on the encounter.
         
     | 
| 
      
 1417 
     | 
    
         
            +
                    # @param request_options [CandidApiClient::RequestOptions]
         
     | 
| 
      
 1418 
     | 
    
         
            +
                    # @return [CandidApiClient::Encounters::V4::Types::Encounter]
         
     | 
| 
      
 1419 
     | 
    
         
            +
                    # @example
         
     | 
| 
      
 1420 
     | 
    
         
            +
                    #  api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
         
     | 
| 
      
 1421 
     | 
    
         
            +
                    #  api.encounters.v_4.create(
         
     | 
| 
      
 1422 
     | 
    
         
            +
                    #    date_of_service: DateTime.parse(2023-01-15),
         
     | 
| 
      
 1423 
     | 
    
         
            +
                    #    end_date_of_service: DateTime.parse(2023-01-15),
         
     | 
| 
      
 1424 
     | 
    
         
            +
                    #    patient: { phone_numbers: [{ number: "1234567890", type: HOME }], phone_consent: true, email: "johndoe@joincandidhealth.com", email_consent: true, external_id: "string", date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", gender: MALE },
         
     | 
| 
      
 1425 
     | 
    
         
            +
                    #    billing_provider: { address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, tax_id: "string", npi: "string", taxonomy_code: "string", first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 1426 
     | 
    
         
            +
                    #    rendering_provider: { address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, npi: "string", taxonomy_code: "string", first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 1427 
     | 
    
         
            +
                    #    referring_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 1428 
     | 
    
         
            +
                    #    initial_referring_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, qualifier: DQ, first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 1429 
     | 
    
         
            +
                    #    supervising_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 1430 
     | 
    
         
            +
                    #    ordering_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" },
         
     | 
| 
      
 1431 
     | 
    
         
            +
                    #    service_facility: { organization_name: "string", npi: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" } },
         
     | 
| 
      
 1432 
     | 
    
         
            +
                    #    subscriber_primary: { insurance_card: { member_id: "string", payer_name: "string", payer_id: "string", rx_bin: "string", rx_pcn: "string", image_url_front: "string", image_url_back: "string", emr_payer_crosswalk: HEALTHIE, group_number: "string", plan_name: "string", plan_type: SELF_PAY, insurance_type: C_01 }, patient_relationship_to_subscriber_code: SPOUSE, date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", gender: MALE },
         
     | 
| 
      
 1433 
     | 
    
         
            +
                    #    subscriber_secondary: { insurance_card: { member_id: "string", payer_name: "string", payer_id: "string", rx_bin: "string", rx_pcn: "string", image_url_front: "string", image_url_back: "string", emr_payer_crosswalk: HEALTHIE, group_number: "string", plan_name: "string", plan_type: SELF_PAY, insurance_type: C_01 }, patient_relationship_to_subscriber_code: SPOUSE, date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", gender: MALE },
         
     | 
| 
      
 1434 
     | 
    
         
            +
                    #    diagnoses: [{ name: "string", code_type: ABF, code: "string" }],
         
     | 
| 
      
 1435 
     | 
    
         
            +
                    #    clinical_notes: [{ category: CLINICAL, notes: [{  }] }],
         
     | 
| 
      
 1436 
     | 
    
         
            +
                    #    billing_notes: [{ text: "string" }],
         
     | 
| 
      
 1437 
     | 
    
         
            +
                    #    place_of_service_code: PHARMACY,
         
     | 
| 
      
 1438 
     | 
    
         
            +
                    #    patient_histories: [{ category: PRESENT_ILLNESS, questions: [{ id: "6E7FBCE4-A8EA-46D0-A8D8-FF83CA3BB176", text: "Do you have any allergies?", responses: [{ response: "No allergies", follow_ups: [{ id: "4F3D57F9-AC94-49D6-87E4-E804B709917A", text: "Do you have any allergies?", response: "No allergies" }] }] }] }],
         
     | 
| 
      
 1439 
     | 
    
         
            +
                    #    service_lines: [{ modifiers: [TWENTY_TWO], procedure_code: "string", quantity: "string", units: MJ, charge_amount_cents: 1, diagnosis_pointers: [1], drug_identification: {  }, place_of_service_code: PHARMACY, description: "string", date_of_service: DateTime.parse(2023-01-15), end_date_of_service: DateTime.parse(2023-01-15), referring_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" }, initial_referring_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, qualifier: DQ, first_name: "string", last_name: "string", organization_name: "string" }, supervising_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" }, ordering_provider: { npi: "string", taxonomy_code: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", organization_name: "string" } }],
         
     | 
| 
      
 1440 
     | 
    
         
            +
                    #    guarantor: { phone_numbers: [{ number: "1234567890", type: HOME }], phone_consent: true, email: "johndoe@joincandidhealth.com", email_consent: true, first_name: "string", last_name: "string", external_id: "string", date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" } },
         
     | 
| 
      
 1441 
     | 
    
         
            +
                    #    external_claim_submission: { claim_created_at: DateTime.parse(2023-01-01T12:00:00.000Z), patient_control_number: "PATIENT_CONTROL_NUMBER", submission_records: [{ submitted_at: DateTime.parse(2023-01-01T13:00:00.000Z), claim_frequency_code: ORIGINAL, payer_responsibility: PRIMARY, intended_submission_medium: ELECTRONIC }, { submitted_at: DateTime.parse(2023-01-04T12:00:00.000Z), claim_frequency_code: REPLACEMENT, payer_responsibility: PRIMARY, intended_submission_medium: PAPER }] },
         
     | 
| 
      
 1442 
     | 
    
         
            +
                    #    tag_ids: ["string"]
         
     | 
| 
      
 1443 
     | 
    
         
            +
                    #  )
         
     | 
| 
       946 
1444 
     | 
    
         
             
                    def create(external_id:, patient_authorized_release:, benefits_assigned_to_provider:,
         
     | 
| 
       947 
     | 
    
         
            -
                               provider_accepts_assignment:, billable_status:, responsible_party:, patient:, billing_provider:, rendering_provider:, diagnoses:, place_of_service_code:, prior_authorization_number: nil, appointment_type: nil, existing_medications: nil, vitals: nil, interventions: nil, pay_to_address: nil, synchronicity: nil, additional_information: nil, service_authorization_exception_code: nil, admission_date: nil, discharge_date: nil, onset_of_current_illness_or_symptom_date: nil, last_menstrual_period_date: nil, delay_reason_code: nil, additional_properties: nil, date_of_service: nil, end_date_of_service: nil, referring_provider: nil, service_facility: nil, subscriber_primary: nil, subscriber_secondary: nil, clinical_notes: nil, billing_notes: nil, patient_histories: nil, service_lines: nil, guarantor: nil, external_claim_submission: nil, tag_ids: nil, request_options: nil)
         
     | 
| 
      
 1445 
     | 
    
         
            +
                               provider_accepts_assignment:, billable_status:, responsible_party:, patient:, billing_provider:, rendering_provider:, diagnoses:, place_of_service_code:, prior_authorization_number: nil, appointment_type: nil, existing_medications: nil, vitals: nil, interventions: nil, pay_to_address: nil, synchronicity: nil, additional_information: nil, service_authorization_exception_code: nil, admission_date: nil, discharge_date: nil, onset_of_current_illness_or_symptom_date: nil, last_menstrual_period_date: nil, delay_reason_code: nil, additional_properties: nil, _field_set: nil, date_of_service: nil, end_date_of_service: nil, referring_provider: nil, initial_referring_provider: nil, supervising_provider: nil, ordering_provider: nil, service_facility: nil, subscriber_primary: nil, subscriber_secondary: nil, clinical_notes: nil, billing_notes: nil, patient_histories: nil, service_lines: nil, guarantor: nil, external_claim_submission: nil, tag_ids: nil, request_options: nil)
         
     | 
| 
       948 
1446 
     | 
    
         
             
                      Async do
         
     | 
| 
       949 
     | 
    
         
            -
                        response = @request_client.conn.post 
     | 
| 
      
 1447 
     | 
    
         
            +
                        response = @request_client.conn.post do |req|
         
     | 
| 
       950 
1448 
     | 
    
         
             
                          req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
         
     | 
| 
       951 
1449 
     | 
    
         
             
                          req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
         
     | 
| 
       952 
     | 
    
         
            -
                          req.headers = { 
     | 
| 
      
 1450 
     | 
    
         
            +
                          req.headers = {
         
     | 
| 
      
 1451 
     | 
    
         
            +
                        **(req.headers || {}),
         
     | 
| 
      
 1452 
     | 
    
         
            +
                        **@request_client.get_headers,
         
     | 
| 
      
 1453 
     | 
    
         
            +
                        **(request_options&.additional_headers || {})
         
     | 
| 
      
 1454 
     | 
    
         
            +
                          }.compact
         
     | 
| 
       953 
1455 
     | 
    
         
             
                          req.body = {
         
     | 
| 
       954 
1456 
     | 
    
         
             
                            **(request_options&.additional_body_parameters || {}),
         
     | 
| 
       955 
1457 
     | 
    
         
             
                            external_id: external_id,
         
     | 
| 
         @@ -973,12 +1475,16 @@ module CandidApiClient 
     | 
|
| 
       973 
1475 
     | 
    
         
             
                            last_menstrual_period_date: last_menstrual_period_date,
         
     | 
| 
       974 
1476 
     | 
    
         
             
                            delay_reason_code: delay_reason_code,
         
     | 
| 
       975 
1477 
     | 
    
         
             
                            additional_properties: additional_properties,
         
     | 
| 
      
 1478 
     | 
    
         
            +
                            _field_set: _field_set,
         
     | 
| 
       976 
1479 
     | 
    
         
             
                            date_of_service: date_of_service,
         
     | 
| 
       977 
1480 
     | 
    
         
             
                            end_date_of_service: end_date_of_service,
         
     | 
| 
       978 
1481 
     | 
    
         
             
                            patient: patient,
         
     | 
| 
       979 
1482 
     | 
    
         
             
                            billing_provider: billing_provider,
         
     | 
| 
       980 
1483 
     | 
    
         
             
                            rendering_provider: rendering_provider,
         
     | 
| 
       981 
1484 
     | 
    
         
             
                            referring_provider: referring_provider,
         
     | 
| 
      
 1485 
     | 
    
         
            +
                            initial_referring_provider: initial_referring_provider,
         
     | 
| 
      
 1486 
     | 
    
         
            +
                            supervising_provider: supervising_provider,
         
     | 
| 
      
 1487 
     | 
    
         
            +
                            ordering_provider: ordering_provider,
         
     | 
| 
       982 
1488 
     | 
    
         
             
                            service_facility: service_facility,
         
     | 
| 
       983 
1489 
     | 
    
         
             
                            subscriber_primary: subscriber_primary,
         
     | 
| 
       984 
1490 
     | 
    
         
             
                            subscriber_secondary: subscriber_secondary,
         
     | 
| 
         @@ -992,48 +1498,77 @@ module CandidApiClient 
     | 
|
| 
       992 
1498 
     | 
    
         
             
                            external_claim_submission: external_claim_submission,
         
     | 
| 
       993 
1499 
     | 
    
         
             
                            tag_ids: tag_ids
         
     | 
| 
       994 
1500 
     | 
    
         
             
                          }.compact
         
     | 
| 
      
 1501 
     | 
    
         
            +
                          req.url "#{@request_client.get_url(environment: CandidApi,
         
     | 
| 
      
 1502 
     | 
    
         
            +
                                                             request_options: request_options)}/api/encounters/v4"
         
     | 
| 
       995 
1503 
     | 
    
         
             
                        end
         
     | 
| 
       996 
     | 
    
         
            -
                        Encounters::V4::Encounter.from_json(json_object: response.body)
         
     | 
| 
      
 1504 
     | 
    
         
            +
                        CandidApiClient::Encounters::V4::Types::Encounter.from_json(json_object: response.body)
         
     | 
| 
       997 
1505 
     | 
    
         
             
                      end
         
     | 
| 
       998 
1506 
     | 
    
         
             
                    end
         
     | 
| 
       999 
1507 
     | 
    
         | 
| 
       1000 
     | 
    
         
            -
                    # @param encounter_id [ 
     | 
| 
       1001 
     | 
    
         
            -
                    # @param prior_authorization_number [ 
     | 
| 
       1002 
     | 
    
         
            -
                    # @param external_id [ 
     | 
| 
       1003 
     | 
    
         
            -
                    # 
     | 
| 
       1004 
     | 
    
         
            -
                    # 
     | 
| 
       1005 
     | 
    
         
            -
                    # @param date_of_service [ 
     | 
| 
       1006 
     | 
    
         
            -
                    # 
     | 
| 
       1007 
     | 
    
         
            -
                    # 
     | 
| 
       1008 
     | 
    
         
            -
                    # 
     | 
| 
       1009 
     | 
    
         
            -
                    # 
     | 
| 
       1010 
     | 
    
         
            -
                    #  
     | 
| 
       1011 
     | 
    
         
            -
                    # 
     | 
| 
       1012 
     | 
    
         
            -
                    # 
     | 
| 
       1013 
     | 
    
         
            -
                    # @param  
     | 
| 
       1014 
     | 
    
         
            -
                    # 
     | 
| 
       1015 
     | 
    
         
            -
                    # 
     | 
| 
       1016 
     | 
    
         
            -
                    # 
     | 
| 
       1017 
     | 
    
         
            -
                    #  
     | 
| 
      
 1508 
     | 
    
         
            +
                    # @param encounter_id [String]
         
     | 
| 
      
 1509 
     | 
    
         
            +
                    # @param prior_authorization_number [String] Box 23 on the CMS-1500 claim form.
         
     | 
| 
      
 1510 
     | 
    
         
            +
                    # @param external_id [String] A client-specified unique ID to associate with this encounter;
         
     | 
| 
      
 1511 
     | 
    
         
            +
                    #  for example, your internal encounter ID or a Dr. Chrono encounter ID.
         
     | 
| 
      
 1512 
     | 
    
         
            +
                    #  This field should not contain PHI.
         
     | 
| 
      
 1513 
     | 
    
         
            +
                    # @param date_of_service [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-24.
         
     | 
| 
      
 1514 
     | 
    
         
            +
                    #  This date must be the local date in the timezone where the service occurred.
         
     | 
| 
      
 1515 
     | 
    
         
            +
                    #  Box 24a on the CMS-1500 claim form.
         
     | 
| 
      
 1516 
     | 
    
         
            +
                    #  If service occurred over a range of dates, this should be the start date.
         
     | 
| 
      
 1517 
     | 
    
         
            +
                    #  If service lines have distinct date_of_service values, updating the encounter's
         
     | 
| 
      
 1518 
     | 
    
         
            +
                    #  date_of_service will fail. If all service line date_of_service values are the
         
     | 
| 
      
 1519 
     | 
    
         
            +
                    #  same, updating the encounter's date_of_service will update all service line
         
     | 
| 
      
 1520 
     | 
    
         
            +
                    #  date_of_service values.
         
     | 
| 
      
 1521 
     | 
    
         
            +
                    # @param diagnosis_ids [Array<String>] Ideally, this field should contain no more than 12 diagnoses. However, more
         
     | 
| 
      
 1522 
     | 
    
         
            +
                    #  diagnoses
         
     | 
| 
      
 1523 
     | 
    
         
            +
                    #  may be submitted at this time, and coders will later prioritize the 12 that will
         
     | 
| 
      
 1524 
     | 
    
         
            +
                    #  be
         
     | 
| 
      
 1525 
     | 
    
         
            +
                    #  submitted to the payor.
         
     | 
| 
      
 1526 
     | 
    
         
            +
                    # @param tag_ids [Array<String>] Names of tags that should be on the encounter.  Note all tags on encounter will
         
     | 
| 
      
 1527 
     | 
    
         
            +
                    #  be overriden with this list.
         
     | 
| 
      
 1528 
     | 
    
         
            +
                    # @param clinical_notes [Array<Hash>] Holds a collection of clinical observations made by healthcare providers during
         
     | 
| 
      
 1529 
     | 
    
         
            +
                    #  patient encounters.Request of type Array<CandidApiClient::Encounters::V4::Types::ClinicalNoteCategoryCreate>, as a Hash
         
     | 
| 
      
 1530 
     | 
    
         
            +
                    #   * :category (CandidApiClient::Encounters::V4::Types::NoteCategory)
         
     | 
| 
      
 1531 
     | 
    
         
            +
                    #   * :notes (Array<CandidApiClient::Encounters::V4::Types::ClinicalNote>)
         
     | 
| 
      
 1532 
     | 
    
         
            +
                    # @param pay_to_address [Hash] Specifies the address to which payments for the claim should be sent.Request of type CandidApiClient::Commons::Types::StreetAddressLongZip, as a Hash
         
     | 
| 
       1018 
1533 
     | 
    
         
             
                    #   * :zip_plus_four_code (String)
         
     | 
| 
       1019 
1534 
     | 
    
         
             
                    #   * :address_1 (String)
         
     | 
| 
       1020 
1535 
     | 
    
         
             
                    #   * :address_2 (String)
         
     | 
| 
       1021 
1536 
     | 
    
         
             
                    #   * :city (String)
         
     | 
| 
       1022 
     | 
    
         
            -
                    #   * :state (Commons::State)
         
     | 
| 
      
 1537 
     | 
    
         
            +
                    #   * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       1023 
1538 
     | 
    
         
             
                    #   * :zip_code (String)
         
     | 
| 
       1024 
     | 
    
         
            -
                    # @param billable_status [Encounters::V4::BillableStatusType] Defines if the Encounter is to be billed by Candid to the responsible_party. 
     | 
| 
       1025 
     | 
    
         
            -
                    #  
     | 
| 
       1026 
     | 
    
         
            -
                    #  
     | 
| 
       1027 
     | 
    
         
            -
                    # 
     | 
| 
       1028 
     | 
    
         
            -
                    # @param  
     | 
| 
       1029 
     | 
    
         
            -
                    #  
     | 
| 
       1030 
     | 
    
         
            -
                    # @param  
     | 
| 
       1031 
     | 
    
         
            -
                    #  
     | 
| 
       1032 
     | 
    
         
            -
                    # 
     | 
| 
       1033 
     | 
    
         
            -
                    # 
     | 
| 
       1034 
     | 
    
         
            -
                    # 
     | 
| 
       1035 
     | 
    
         
            -
                    # 
     | 
| 
       1036 
     | 
    
         
            -
                    #  
     | 
| 
      
 1539 
     | 
    
         
            +
                    # @param billable_status [CandidApiClient::Encounters::V4::Types::BillableStatusType] Defines if the Encounter is to be billed by Candid to the responsible_party.
         
     | 
| 
      
 1540 
     | 
    
         
            +
                    #  Examples for when this should be set to NOT_BILLABLE include if the Encounter
         
     | 
| 
      
 1541 
     | 
    
         
            +
                    #  has not occurred yet or if there is no intention of ever billing the
         
     | 
| 
      
 1542 
     | 
    
         
            +
                    #  responsible_party.
         
     | 
| 
      
 1543 
     | 
    
         
            +
                    # @param responsible_party [CandidApiClient::Encounters::V4::Types::ResponsiblePartyType] Defines the party to be billed with the initial balance owed on the claim. Use
         
     | 
| 
      
 1544 
     | 
    
         
            +
                    #  SELF_PAY if you intend to bill self pay/cash pay.
         
     | 
| 
      
 1545 
     | 
    
         
            +
                    # @param provider_accepts_assignment [Boolean] Whether you have accepted the patient's authorization for insurance payments to
         
     | 
| 
      
 1546 
     | 
    
         
            +
                    #  be made to you, not them. Box 27 on the CMS-1500 claim form.
         
     | 
| 
      
 1547 
     | 
    
         
            +
                    # @param benefits_assigned_to_provider [Boolean] Whether this patient has authorized insurance payments to be made to you, not
         
     | 
| 
      
 1548 
     | 
    
         
            +
                    #  them. If false, patient may receive reimbursement. Box 13 on the CMS-1500 claim
         
     | 
| 
      
 1549 
     | 
    
         
            +
                    #  form.
         
     | 
| 
      
 1550 
     | 
    
         
            +
                    # @param synchronicity [CandidApiClient::Encounters::V4::Types::SynchronicityType] Whether or not this was a synchronous or asynchronous encounter. Asynchronous
         
     | 
| 
      
 1551 
     | 
    
         
            +
                    #  encounters occur when providers and patients communicate online using forms,
         
     | 
| 
      
 1552 
     | 
    
         
            +
                    #  instant messaging, or other pre-recorded digital mediums. Synchronous encounters
         
     | 
| 
      
 1553 
     | 
    
         
            +
                    #  occur in live, real-time settings where the patient interacts directly with the
         
     | 
| 
      
 1554 
     | 
    
         
            +
                    #  provider, such as over video or a phone call.
         
     | 
| 
      
 1555 
     | 
    
         
            +
                    # @param place_of_service_code [CandidApiClient::Commons::Types::FacilityTypeCode] Box 24B on the CMS-1500 claim form. Line-level place of service is not currently
         
     | 
| 
      
 1556 
     | 
    
         
            +
                    #  supported. 02 for telemedicine, 11 for in-person. Full list
         
     | 
| 
      
 1557 
     | 
    
         
            +
                    #  //www.cms.gov/Medicare/Coding/place-of-service-codes/Place_of_Service_Code_Set).
         
     | 
| 
      
 1558 
     | 
    
         
            +
                    # @param place_of_service_code_as_submitted [CandidApiClient::Commons::Types::FacilityTypeCode] Box 24B on the CMS-1500 claim form. Line-level place of service is not currently
         
     | 
| 
      
 1559 
     | 
    
         
            +
                    #  supported. 02 for telemedicine, 11 for in-person. Full list
         
     | 
| 
      
 1560 
     | 
    
         
            +
                    #  //www.cms.gov/Medicare/Coding/place-of-service-codes/Place_of_Service_Code_Set).
         
     | 
| 
      
 1561 
     | 
    
         
            +
                    # @param appointment_type [String] Human-readable description of the appointment type (ex: "Acupuncture -
         
     | 
| 
      
 1562 
     | 
    
         
            +
                    #  Headaches").
         
     | 
| 
      
 1563 
     | 
    
         
            +
                    # @param end_date_of_service [Date] Date formatted as YYYY-MM-DD; eg: 2019-08-25.
         
     | 
| 
      
 1564 
     | 
    
         
            +
                    #  This date must be the local date in the timezone where the service occurred.
         
     | 
| 
      
 1565 
     | 
    
         
            +
                    #  If omitted, the Encounter is assumed to be for a single day.
         
     | 
| 
      
 1566 
     | 
    
         
            +
                    #  Must not be temporally before the date_of_service field.
         
     | 
| 
      
 1567 
     | 
    
         
            +
                    #  If service lines have distinct end_date_of_service values, updating the
         
     | 
| 
      
 1568 
     | 
    
         
            +
                    #  encounter's end_date_of_service will fail. If all service line
         
     | 
| 
      
 1569 
     | 
    
         
            +
                    #  end_date_of_service values are the same, updating the encounter's
         
     | 
| 
      
 1570 
     | 
    
         
            +
                    #  end_date_of_service will update all service line date_of_service values.
         
     | 
| 
      
 1571 
     | 
    
         
            +
                    # @param subscriber_primary [Hash] Contains details of the primary insurance subscriber.Request of type CandidApiClient::Individual::Types::SubscriberCreate, as a Hash
         
     | 
| 
       1037 
1572 
     | 
    
         
             
                    #   * :insurance_card (Hash)
         
     | 
| 
       1038 
1573 
     | 
    
         
             
                    #     * :member_id (String)
         
     | 
| 
       1039 
1574 
     | 
    
         
             
                    #     * :payer_name (String)
         
     | 
| 
         @@ -1042,24 +1577,24 @@ module CandidApiClient 
     | 
|
| 
       1042 
1577 
     | 
    
         
             
                    #     * :rx_pcn (String)
         
     | 
| 
       1043 
1578 
     | 
    
         
             
                    #     * :image_url_front (String)
         
     | 
| 
       1044 
1579 
     | 
    
         
             
                    #     * :image_url_back (String)
         
     | 
| 
       1045 
     | 
    
         
            -
                    #     * :emr_payer_crosswalk (Commons::EmrPayerCrosswalk)
         
     | 
| 
      
 1580 
     | 
    
         
            +
                    #     * :emr_payer_crosswalk (CandidApiClient::Commons::Types::EmrPayerCrosswalk)
         
     | 
| 
       1046 
1581 
     | 
    
         
             
                    #     * :group_number (String)
         
     | 
| 
       1047 
1582 
     | 
    
         
             
                    #     * :plan_name (String)
         
     | 
| 
       1048 
     | 
    
         
            -
                    #     * :plan_type (Commons::SourceOfPaymentCode)
         
     | 
| 
       1049 
     | 
    
         
            -
                    #     * :insurance_type (Commons::InsuranceTypeCode)
         
     | 
| 
       1050 
     | 
    
         
            -
                    #   * :patient_relationship_to_subscriber_code (Commons::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
       1051 
     | 
    
         
            -
                    #   * :date_of_birth ( 
     | 
| 
      
 1583 
     | 
    
         
            +
                    #     * :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)
         
     | 
| 
      
 1584 
     | 
    
         
            +
                    #     * :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)
         
     | 
| 
      
 1585 
     | 
    
         
            +
                    #   * :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
      
 1586 
     | 
    
         
            +
                    #   * :date_of_birth (Date)
         
     | 
| 
       1052 
1587 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       1053 
1588 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       1054 
1589 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       1055 
1590 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       1056 
1591 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       1057 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 1592 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       1058 
1593 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       1059 
1594 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       1060 
1595 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       1061 
     | 
    
         
            -
                    #   * :gender (Individual::Gender)
         
     | 
| 
       1062 
     | 
    
         
            -
                    # @param subscriber_secondary [Hash] Contains details of the secondary insurance subscriber.Request of type Individual::SubscriberCreate, as a Hash
         
     | 
| 
      
 1596 
     | 
    
         
            +
                    #   * :gender (CandidApiClient::Individual::Types::Gender)
         
     | 
| 
      
 1597 
     | 
    
         
            +
                    # @param subscriber_secondary [Hash] Contains details of the secondary insurance subscriber.Request of type CandidApiClient::Individual::Types::SubscriberCreate, as a Hash
         
     | 
| 
       1063 
1598 
     | 
    
         
             
                    #   * :insurance_card (Hash)
         
     | 
| 
       1064 
1599 
     | 
    
         
             
                    #     * :member_id (String)
         
     | 
| 
       1065 
1600 
     | 
    
         
             
                    #     * :payer_name (String)
         
     | 
| 
         @@ -1068,55 +1603,97 @@ module CandidApiClient 
     | 
|
| 
       1068 
1603 
     | 
    
         
             
                    #     * :rx_pcn (String)
         
     | 
| 
       1069 
1604 
     | 
    
         
             
                    #     * :image_url_front (String)
         
     | 
| 
       1070 
1605 
     | 
    
         
             
                    #     * :image_url_back (String)
         
     | 
| 
       1071 
     | 
    
         
            -
                    #     * :emr_payer_crosswalk (Commons::EmrPayerCrosswalk)
         
     | 
| 
      
 1606 
     | 
    
         
            +
                    #     * :emr_payer_crosswalk (CandidApiClient::Commons::Types::EmrPayerCrosswalk)
         
     | 
| 
       1072 
1607 
     | 
    
         
             
                    #     * :group_number (String)
         
     | 
| 
       1073 
1608 
     | 
    
         
             
                    #     * :plan_name (String)
         
     | 
| 
       1074 
     | 
    
         
            -
                    #     * :plan_type (Commons::SourceOfPaymentCode)
         
     | 
| 
       1075 
     | 
    
         
            -
                    #     * :insurance_type (Commons::InsuranceTypeCode)
         
     | 
| 
       1076 
     | 
    
         
            -
                    #   * :patient_relationship_to_subscriber_code (Commons::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
       1077 
     | 
    
         
            -
                    #   * :date_of_birth ( 
     | 
| 
      
 1609 
     | 
    
         
            +
                    #     * :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)
         
     | 
| 
      
 1610 
     | 
    
         
            +
                    #     * :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)
         
     | 
| 
      
 1611 
     | 
    
         
            +
                    #   * :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)
         
     | 
| 
      
 1612 
     | 
    
         
            +
                    #   * :date_of_birth (Date)
         
     | 
| 
       1078 
1613 
     | 
    
         
             
                    #   * :address (Hash)
         
     | 
| 
       1079 
1614 
     | 
    
         
             
                    #     * :zip_plus_four_code (String)
         
     | 
| 
       1080 
1615 
     | 
    
         
             
                    #     * :address_1 (String)
         
     | 
| 
       1081 
1616 
     | 
    
         
             
                    #     * :address_2 (String)
         
     | 
| 
       1082 
1617 
     | 
    
         
             
                    #     * :city (String)
         
     | 
| 
       1083 
     | 
    
         
            -
                    #     * :state (Commons::State)
         
     | 
| 
      
 1618 
     | 
    
         
            +
                    #     * :state (CandidApiClient::Commons::Types::State)
         
     | 
| 
       1084 
1619 
     | 
    
         
             
                    #     * :zip_code (String)
         
     | 
| 
       1085 
1620 
     | 
    
         
             
                    #   * :first_name (String)
         
     | 
| 
       1086 
1621 
     | 
    
         
             
                    #   * :last_name (String)
         
     | 
| 
       1087 
     | 
    
         
            -
                    #   * :gender (Individual::Gender)
         
     | 
| 
      
 1622 
     | 
    
         
            +
                    #   * :gender (CandidApiClient::Individual::Types::Gender)
         
     | 
| 
       1088 
1623 
     | 
    
         
             
                    # @param additional_information [String] Defines additional information on the claim needed by the payer.
         
     | 
| 
       1089 
     | 
    
         
            -
                    # 
     | 
| 
       1090 
     | 
    
         
            -
                    # @param service_authorization_exception_code [Encounters::V4::ServiceAuthorizationExceptionCode] 837p Loop2300 REF*4N
         
     | 
| 
       1091 
     | 
    
         
            -
                    # 
     | 
| 
       1092 
     | 
    
         
            -
                    # 
     | 
| 
       1093 
     | 
    
         
            -
                    # 
     | 
| 
       1094 
     | 
    
         
            -
                    #  
     | 
| 
       1095 
     | 
    
         
            -
                    # 
     | 
| 
       1096 
     | 
    
         
            -
                    # 
     | 
| 
       1097 
     | 
    
         
            -
                    # 
     | 
| 
       1098 
     | 
    
         
            -
                    #  
     | 
| 
       1099 
     | 
    
         
            -
                    # 
     | 
| 
       1100 
     | 
    
         
            -
                    #  
     | 
| 
       1101 
     | 
    
         
            -
                    # 
     | 
| 
       1102 
     | 
    
         
            -
                    # 
     | 
| 
       1103 
     | 
    
         
            -
                    # 
     | 
| 
       1104 
     | 
    
         
            -
                    # @param  
     | 
| 
       1105 
     | 
    
         
            -
                    # 
     | 
| 
       1106 
     | 
    
         
            -
                    #  
     | 
| 
       1107 
     | 
    
         
            -
                    # 
     | 
| 
      
 1624 
     | 
    
         
            +
                    #  Box 19 on the CMS-1500 claim form.
         
     | 
| 
      
 1625 
     | 
    
         
            +
                    # @param service_authorization_exception_code [CandidApiClient::Encounters::V4::Types::ServiceAuthorizationExceptionCode] 837p Loop2300 REF*4N
         
     | 
| 
      
 1626 
     | 
    
         
            +
                    #  Required when mandated by government law or regulation to obtain authorization
         
     | 
| 
      
 1627 
     | 
    
         
            +
                    #  for specific service(s) but, for the
         
     | 
| 
      
 1628 
     | 
    
         
            +
                    #  reasons listed in one of the enum values of ServiceAuthorizationExceptionCode,
         
     | 
| 
      
 1629 
     | 
    
         
            +
                    #  the service was performed without
         
     | 
| 
      
 1630 
     | 
    
         
            +
                    #  obtaining the authorization.
         
     | 
| 
      
 1631 
     | 
    
         
            +
                    # @param admission_date [Date] 837p Loop2300 DTP*435, CMS-1500 Box 18
         
     | 
| 
      
 1632 
     | 
    
         
            +
                    #  Required on all ambulance claims when the patient was known to be admitted to
         
     | 
| 
      
 1633 
     | 
    
         
            +
                    #  the hospital.
         
     | 
| 
      
 1634 
     | 
    
         
            +
                    #  OR
         
     | 
| 
      
 1635 
     | 
    
         
            +
                    #  Required on all claims involving inpatient medical visits.
         
     | 
| 
      
 1636 
     | 
    
         
            +
                    # @param discharge_date [Date] 837p Loop2300 DTP*096, CMS-1500 Box 18
         
     | 
| 
      
 1637 
     | 
    
         
            +
                    #  Required for inpatient claims when the patient was discharged from the facility
         
     | 
| 
      
 1638 
     | 
    
         
            +
                    #  and the discharge date is known.
         
     | 
| 
      
 1639 
     | 
    
         
            +
                    # @param onset_of_current_illness_or_symptom_date [Date] 837p Loop2300 DTP*431, CMS-1500 Box 14
         
     | 
| 
      
 1640 
     | 
    
         
            +
                    #  Required for the initial medical service or visit performed in response to a
         
     | 
| 
      
 1641 
     | 
    
         
            +
                    #  medical emergency when the date is available and is different than the date of
         
     | 
| 
      
 1642 
     | 
    
         
            +
                    #  service.
         
     | 
| 
      
 1643 
     | 
    
         
            +
                    #  OR
         
     | 
| 
      
 1644 
     | 
    
         
            +
                    #  This date is the onset of acute symptoms for the current illness or condition.
         
     | 
| 
      
 1645 
     | 
    
         
            +
                    # @param last_menstrual_period_date [Date] 837p Loop2300 DTP*484, CMS-1500 Box 14
         
     | 
| 
      
 1646 
     | 
    
         
            +
                    #  Required when, in the judgment of the provider, the services on this claim are
         
     | 
| 
      
 1647 
     | 
    
         
            +
                    #  related to the patient's pregnancy.
         
     | 
| 
      
 1648 
     | 
    
         
            +
                    # @param delay_reason_code [CandidApiClient::Commons::Types::DelayReasonCode] 837i Loop2300, CLM-1300 Box 20
         
     | 
| 
      
 1649 
     | 
    
         
            +
                    #  Code indicating the reason why a request was delayed
         
     | 
| 
       1108 
1650 
     | 
    
         
             
                    # @param patient_authorized_release [Boolean] Whether this patient has authorized the release of medical information
         
     | 
| 
       1109 
     | 
    
         
            -
                    # 
     | 
| 
       1110 
     | 
    
         
            -
                    # 
     | 
| 
       1111 
     | 
    
         
            -
                    # @param request_options [RequestOptions]
         
     | 
| 
       1112 
     | 
    
         
            -
                    # @return [Encounters::V4::Encounter]
         
     | 
| 
      
 1651 
     | 
    
         
            +
                    #  for billing purpose.
         
     | 
| 
      
 1652 
     | 
    
         
            +
                    #  Box 12 on the CMS-1500 claim form.
         
     | 
| 
      
 1653 
     | 
    
         
            +
                    # @param request_options [CandidApiClient::RequestOptions]
         
     | 
| 
      
 1654 
     | 
    
         
            +
                    # @return [CandidApiClient::Encounters::V4::Types::Encounter]
         
     | 
| 
      
 1655 
     | 
    
         
            +
                    # @example
         
     | 
| 
      
 1656 
     | 
    
         
            +
                    #  api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
         
     | 
| 
      
 1657 
     | 
    
         
            +
                    #  api.encounters.v_4.update(
         
     | 
| 
      
 1658 
     | 
    
         
            +
                    #    encounter_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
         
     | 
| 
      
 1659 
     | 
    
         
            +
                    #    prior_authorization_number: "string",
         
     | 
| 
      
 1660 
     | 
    
         
            +
                    #    external_id: "string",
         
     | 
| 
      
 1661 
     | 
    
         
            +
                    #    date_of_service: DateTime.parse(2023-01-15),
         
     | 
| 
      
 1662 
     | 
    
         
            +
                    #    diagnosis_ids: ["d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"],
         
     | 
| 
      
 1663 
     | 
    
         
            +
                    #    tag_ids: ["string"],
         
     | 
| 
      
 1664 
     | 
    
         
            +
                    #    clinical_notes: [{ category: CLINICAL, notes: [{  }] }],
         
     | 
| 
      
 1665 
     | 
    
         
            +
                    #    pay_to_address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" },
         
     | 
| 
      
 1666 
     | 
    
         
            +
                    #    billable_status: BILLABLE,
         
     | 
| 
      
 1667 
     | 
    
         
            +
                    #    responsible_party: INSURANCE_PAY,
         
     | 
| 
      
 1668 
     | 
    
         
            +
                    #    provider_accepts_assignment: true,
         
     | 
| 
      
 1669 
     | 
    
         
            +
                    #    benefits_assigned_to_provider: true,
         
     | 
| 
      
 1670 
     | 
    
         
            +
                    #    synchronicity: SYNCHRONOUS,
         
     | 
| 
      
 1671 
     | 
    
         
            +
                    #    place_of_service_code: PHARMACY,
         
     | 
| 
      
 1672 
     | 
    
         
            +
                    #    place_of_service_code_as_submitted: PHARMACY,
         
     | 
| 
      
 1673 
     | 
    
         
            +
                    #    appointment_type: "string",
         
     | 
| 
      
 1674 
     | 
    
         
            +
                    #    end_date_of_service: DateTime.parse(2023-01-15),
         
     | 
| 
      
 1675 
     | 
    
         
            +
                    #    subscriber_primary: { insurance_card: { member_id: "string", payer_name: "string", payer_id: "string", rx_bin: "string", rx_pcn: "string", image_url_front: "string", image_url_back: "string", emr_payer_crosswalk: HEALTHIE, group_number: "string", plan_name: "string", plan_type: SELF_PAY, insurance_type: C_01 }, patient_relationship_to_subscriber_code: SPOUSE, date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", gender: MALE },
         
     | 
| 
      
 1676 
     | 
    
         
            +
                    #    subscriber_secondary: { insurance_card: { member_id: "string", payer_name: "string", payer_id: "string", rx_bin: "string", rx_pcn: "string", image_url_front: "string", image_url_back: "string", emr_payer_crosswalk: HEALTHIE, group_number: "string", plan_name: "string", plan_type: SELF_PAY, insurance_type: C_01 }, patient_relationship_to_subscriber_code: SPOUSE, date_of_birth: DateTime.parse(2023-01-15), address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, first_name: "string", last_name: "string", gender: MALE },
         
     | 
| 
      
 1677 
     | 
    
         
            +
                    #    additional_information: "string",
         
     | 
| 
      
 1678 
     | 
    
         
            +
                    #    service_authorization_exception_code: C_1,
         
     | 
| 
      
 1679 
     | 
    
         
            +
                    #    admission_date: DateTime.parse(2023-01-15),
         
     | 
| 
      
 1680 
     | 
    
         
            +
                    #    discharge_date: DateTime.parse(2023-01-15),
         
     | 
| 
      
 1681 
     | 
    
         
            +
                    #    onset_of_current_illness_or_symptom_date: DateTime.parse(2023-01-15),
         
     | 
| 
      
 1682 
     | 
    
         
            +
                    #    last_menstrual_period_date: DateTime.parse(2023-01-15),
         
     | 
| 
      
 1683 
     | 
    
         
            +
                    #    delay_reason_code: C_1,
         
     | 
| 
      
 1684 
     | 
    
         
            +
                    #    patient_authorized_release: true
         
     | 
| 
      
 1685 
     | 
    
         
            +
                    #  )
         
     | 
| 
       1113 
1686 
     | 
    
         
             
                    def update(encounter_id:, prior_authorization_number: nil, external_id: nil, date_of_service: nil,
         
     | 
| 
       1114 
     | 
    
         
            -
                               diagnosis_ids: nil, tag_ids: nil, clinical_notes: nil, pay_to_address: nil, billable_status: nil, responsible_party: nil, provider_accepts_assignment: nil, benefits_assigned_to_provider: nil, synchronicity: nil, place_of_service_code: nil, appointment_type: nil, end_date_of_service: nil, subscriber_primary: nil, subscriber_secondary: nil, additional_information: nil, service_authorization_exception_code: nil, admission_date: nil, discharge_date: nil, onset_of_current_illness_or_symptom_date: nil, last_menstrual_period_date: nil, delay_reason_code: nil, patient_authorized_release: nil, request_options: nil)
         
     | 
| 
      
 1687 
     | 
    
         
            +
                               diagnosis_ids: nil, tag_ids: nil, clinical_notes: nil, pay_to_address: nil, billable_status: nil, responsible_party: nil, provider_accepts_assignment: nil, benefits_assigned_to_provider: nil, synchronicity: nil, place_of_service_code: nil, place_of_service_code_as_submitted: nil, appointment_type: nil, end_date_of_service: nil, subscriber_primary: nil, subscriber_secondary: nil, additional_information: nil, service_authorization_exception_code: nil, admission_date: nil, discharge_date: nil, onset_of_current_illness_or_symptom_date: nil, last_menstrual_period_date: nil, delay_reason_code: nil, patient_authorized_release: nil, request_options: nil)
         
     | 
| 
       1115 
1688 
     | 
    
         
             
                      Async do
         
     | 
| 
       1116 
     | 
    
         
            -
                        response = @request_client.conn.patch 
     | 
| 
      
 1689 
     | 
    
         
            +
                        response = @request_client.conn.patch do |req|
         
     | 
| 
       1117 
1690 
     | 
    
         
             
                          req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
         
     | 
| 
       1118 
1691 
     | 
    
         
             
                          req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
         
     | 
| 
       1119 
     | 
    
         
            -
                          req.headers = { 
     | 
| 
      
 1692 
     | 
    
         
            +
                          req.headers = {
         
     | 
| 
      
 1693 
     | 
    
         
            +
                        **(req.headers || {}),
         
     | 
| 
      
 1694 
     | 
    
         
            +
                        **@request_client.get_headers,
         
     | 
| 
      
 1695 
     | 
    
         
            +
                        **(request_options&.additional_headers || {})
         
     | 
| 
      
 1696 
     | 
    
         
            +
                          }.compact
         
     | 
| 
       1120 
1697 
     | 
    
         
             
                          req.body = {
         
     | 
| 
       1121 
1698 
     | 
    
         
             
                            **(request_options&.additional_body_parameters || {}),
         
     | 
| 
       1122 
1699 
     | 
    
         
             
                            prior_authorization_number: prior_authorization_number,
         
     | 
| 
         @@ -1132,6 +1709,7 @@ module CandidApiClient 
     | 
|
| 
       1132 
1709 
     | 
    
         
             
                            benefits_assigned_to_provider: benefits_assigned_to_provider,
         
     | 
| 
       1133 
1710 
     | 
    
         
             
                            synchronicity: synchronicity,
         
     | 
| 
       1134 
1711 
     | 
    
         
             
                            place_of_service_code: place_of_service_code,
         
     | 
| 
      
 1712 
     | 
    
         
            +
                            place_of_service_code_as_submitted: place_of_service_code_as_submitted,
         
     | 
| 
       1135 
1713 
     | 
    
         
             
                            appointment_type: appointment_type,
         
     | 
| 
       1136 
1714 
     | 
    
         
             
                            end_date_of_service: end_date_of_service,
         
     | 
| 
       1137 
1715 
     | 
    
         
             
                            subscriber_primary: subscriber_primary,
         
     | 
| 
         @@ -1145,8 +1723,10 @@ module CandidApiClient 
     | 
|
| 
       1145 
1723 
     | 
    
         
             
                            delay_reason_code: delay_reason_code,
         
     | 
| 
       1146 
1724 
     | 
    
         
             
                            patient_authorized_release: patient_authorized_release
         
     | 
| 
       1147 
1725 
     | 
    
         
             
                          }.compact
         
     | 
| 
      
 1726 
     | 
    
         
            +
                          req.url "#{@request_client.get_url(environment: CandidApi,
         
     | 
| 
      
 1727 
     | 
    
         
            +
                                                             request_options: request_options)}/api/encounters/v4/#{encounter_id}"
         
     | 
| 
       1148 
1728 
     | 
    
         
             
                        end
         
     | 
| 
       1149 
     | 
    
         
            -
                        Encounters::V4::Encounter.from_json(json_object: response.body)
         
     | 
| 
      
 1729 
     | 
    
         
            +
                        CandidApiClient::Encounters::V4::Types::Encounter.from_json(json_object: response.body)
         
     | 
| 
       1150 
1730 
     | 
    
         
             
                      end
         
     | 
| 
       1151 
1731 
     | 
    
         
             
                    end
         
     | 
| 
       1152 
1732 
     | 
    
         
             
                  end
         
     |