candidhealth 0.17.1
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 +7 -0
- data/lib/candidhealth/auth/client.rb +28 -0
- data/lib/candidhealth/auth/v_2/client.rb +90 -0
- data/lib/candidhealth/auth/v_2/types/auth_get_token_request.rb +54 -0
- data/lib/candidhealth/auth/v_2/types/auth_get_token_response.rb +59 -0
- data/lib/candidhealth/auth/v_2/types/too_many_requests_error_type.rb +49 -0
- data/lib/candidhealth/billing_notes/client.rb +28 -0
- data/lib/candidhealth/billing_notes/v_2/client.rb +76 -0
- data/lib/candidhealth/billing_notes/v_2/types/billing_note.rb +89 -0
- data/lib/candidhealth/billing_notes/v_2/types/billing_note_base.rb +49 -0
- data/lib/candidhealth/billing_notes/v_2/types/billing_note_id.rb +9 -0
- data/lib/candidhealth/claim_submission/v_1/types/claim_frequency_type_code.rb +14 -0
- data/lib/candidhealth/claim_submission/v_1/types/claim_submission_record_create.rb +68 -0
- data/lib/candidhealth/claim_submission/v_1/types/external_claim_submission_create.rb +75 -0
- data/lib/candidhealth/claims/types/claim.rb +98 -0
- data/lib/candidhealth/claims/types/claim_status.rb +23 -0
- data/lib/candidhealth/commons/types/claim_adjustment_group_codes.rb +17 -0
- data/lib/candidhealth/commons/types/claim_id.rb +7 -0
- data/lib/candidhealth/commons/types/claim_submission_payer_responsibility_type.rb +10 -0
- data/lib/candidhealth/commons/types/date.rb +7 -0
- data/lib/candidhealth/commons/types/date_range_optional_end.rb +53 -0
- data/lib/candidhealth/commons/types/decimal.rb +7 -0
- data/lib/candidhealth/commons/types/delay_reason_code.rb +23 -0
- data/lib/candidhealth/commons/types/email.rb +7 -0
- data/lib/candidhealth/commons/types/emr_payer_crosswalk.rb +10 -0
- data/lib/candidhealth/commons/types/encounter_external_id.rb +7 -0
- data/lib/candidhealth/commons/types/encounter_id.rb +7 -0
- data/lib/candidhealth/commons/types/entity_not_found_error_message.rb +47 -0
- data/lib/candidhealth/commons/types/error_message.rb +7 -0
- data/lib/candidhealth/commons/types/facility_type_code.rb +61 -0
- data/lib/candidhealth/commons/types/http_service_unavailable_error_message.rb +47 -0
- data/lib/candidhealth/commons/types/insurance_type_code.rb +79 -0
- data/lib/candidhealth/commons/types/invoice_id.rb +7 -0
- data/lib/candidhealth/commons/types/link_url.rb +7 -0
- data/lib/candidhealth/commons/types/npi.rb +7 -0
- data/lib/candidhealth/commons/types/organization_id.rb +7 -0
- data/lib/candidhealth/commons/types/organization_not_authorized_error_message.rb +47 -0
- data/lib/candidhealth/commons/types/page_token.rb +7 -0
- data/lib/candidhealth/commons/types/patient_external_id.rb +7 -0
- data/lib/candidhealth/commons/types/patient_relationship_to_insured_code_all.rb +32 -0
- data/lib/candidhealth/commons/types/phone_number.rb +53 -0
- data/lib/candidhealth/commons/types/phone_number_type.rb +11 -0
- data/lib/candidhealth/commons/types/procedure_modifier.rb +395 -0
- data/lib/candidhealth/commons/types/provider_id.rb +7 -0
- data/lib/candidhealth/commons/types/region_national.rb +41 -0
- data/lib/candidhealth/commons/types/region_states.rb +48 -0
- data/lib/candidhealth/commons/types/regions.rb +92 -0
- data/lib/candidhealth/commons/types/removable_date_range_optional_end.rb +90 -0
- data/lib/candidhealth/commons/types/request_validation_error.rb +52 -0
- data/lib/candidhealth/commons/types/resource_page.rb +53 -0
- data/lib/candidhealth/commons/types/service_line_id.rb +7 -0
- data/lib/candidhealth/commons/types/service_line_units.rb +10 -0
- data/lib/candidhealth/commons/types/sort_direction.rb +10 -0
- data/lib/candidhealth/commons/types/source_of_payment_code.rb +31 -0
- data/lib/candidhealth/commons/types/state.rb +70 -0
- data/lib/candidhealth/commons/types/street_address_base.rb +75 -0
- data/lib/candidhealth/commons/types/street_address_long_zip.rb +82 -0
- data/lib/candidhealth/commons/types/street_address_short_zip.rb +82 -0
- data/lib/candidhealth/commons/types/task_assignment_id.rb +7 -0
- data/lib/candidhealth/commons/types/task_id.rb +7 -0
- data/lib/candidhealth/commons/types/task_note_id.rb +7 -0
- data/lib/candidhealth/commons/types/tax_id.rb +7 -0
- data/lib/candidhealth/commons/types/unauthorized_error_message.rb +47 -0
- data/lib/candidhealth/commons/types/unprocessable_entity_error_message.rb +47 -0
- data/lib/candidhealth/commons/types/updates_disabled_due_to_external_system_integration_error_message.rb +47 -0
- data/lib/candidhealth/commons/types/user_id.rb +7 -0
- data/lib/candidhealth/commons/types/work_queue_id.rb +7 -0
- data/lib/candidhealth/contracts/client.rb +28 -0
- data/lib/candidhealth/contracts/v_2/client.rb +336 -0
- data/lib/candidhealth/contracts/v_2/types/authorized_signatory.rb +83 -0
- data/lib/candidhealth/contracts/v_2/types/authorized_signatory_update.rb +92 -0
- data/lib/candidhealth/contracts/v_2/types/contract.rb +165 -0
- data/lib/candidhealth/contracts/v_2/types/contract_base.rb +128 -0
- data/lib/candidhealth/contracts/v_2/types/contract_id.rb +9 -0
- data/lib/candidhealth/contracts/v_2/types/contract_is_linked_to_fee_schedule_error.rb +49 -0
- data/lib/candidhealth/contracts/v_2/types/contract_status.rb +13 -0
- data/lib/candidhealth/contracts/v_2/types/contract_with_providers.rb +177 -0
- data/lib/candidhealth/contracts/v_2/types/contracting_provider_id.rb +9 -0
- data/lib/candidhealth/contracts/v_2/types/contracts_page.rb +65 -0
- data/lib/candidhealth/contracts/v_2/types/date_update.rb +92 -0
- data/lib/candidhealth/contracts/v_2/types/insurance_types.rb +103 -0
- data/lib/candidhealth/contracts/v_2/types/regions_update.rb +92 -0
- data/lib/candidhealth/contracts/v_2/types/rendering_providerid.rb +9 -0
- data/lib/candidhealth/diagnoses/types/diagnosis.rb +106 -0
- data/lib/candidhealth/diagnoses/types/diagnosis_create.rb +72 -0
- data/lib/candidhealth/diagnoses/types/diagnosis_id.rb +7 -0
- data/lib/candidhealth/diagnoses/types/diagnosis_type_code.rb +18 -0
- data/lib/candidhealth/diagnoses/types/standalone_diagnosis_create.rb +78 -0
- data/lib/candidhealth/eligibility/client.rb +28 -0
- data/lib/candidhealth/eligibility/v_2/client.rb +136 -0
- data/lib/candidhealth/encounter_providers/v_2/types/billing_provider.rb +104 -0
- data/lib/candidhealth/encounter_providers/v_2/types/encounter_provider.rb +103 -0
- data/lib/candidhealth/encounter_providers/v_2/types/encounter_provider_base.rb +60 -0
- data/lib/candidhealth/encounter_providers/v_2/types/provider_id.rb +9 -0
- data/lib/candidhealth/encounter_providers/v_2/types/referring_provider.rb +91 -0
- data/lib/candidhealth/encounter_providers/v_2/types/rendering_provider.rb +91 -0
- data/lib/candidhealth/encounters/client.rb +28 -0
- data/lib/candidhealth/encounters/v_4/client.rb +1125 -0
- data/lib/candidhealth/encounters/v_4/types/billable_status_type.rb +12 -0
- data/lib/candidhealth/encounters/v_4/types/cash_pay_payer_error_message.rb +49 -0
- data/lib/candidhealth/encounters/v_4/types/clinical_note.rb +67 -0
- data/lib/candidhealth/encounters/v_4/types/clinical_note_category.rb +64 -0
- data/lib/candidhealth/encounters/v_4/types/clinical_note_category_create.rb +59 -0
- data/lib/candidhealth/encounters/v_4/types/coding_attribution_type.rb +14 -0
- data/lib/candidhealth/encounters/v_4/types/encounter.rb +515 -0
- data/lib/candidhealth/encounters/v_4/types/encounter_base.rb +274 -0
- data/lib/candidhealth/encounters/v_4/types/encounter_external_id_uniqueness_error_type.rb +50 -0
- data/lib/candidhealth/encounters/v_4/types/encounter_guarantor_missing_contact_info_error_type.rb +49 -0
- data/lib/candidhealth/encounters/v_4/types/encounter_owner_of_next_action_type.rb +14 -0
- data/lib/candidhealth/encounters/v_4/types/encounter_page.rb +65 -0
- data/lib/candidhealth/encounters/v_4/types/encounter_patient_control_number_uniqueness_error_type.rb +49 -0
- data/lib/candidhealth/encounters/v_4/types/encounter_sort_options.rb +14 -0
- data/lib/candidhealth/encounters/v_4/types/encounter_submission_origin_type.rb +12 -0
- data/lib/candidhealth/encounters/v_4/types/intake_follow_up.rb +60 -0
- data/lib/candidhealth/encounters/v_4/types/intake_follow_up_id.rb +9 -0
- data/lib/candidhealth/encounters/v_4/types/intake_question.rb +64 -0
- data/lib/candidhealth/encounters/v_4/types/intake_question_id.rb +9 -0
- data/lib/candidhealth/encounters/v_4/types/intake_response_and_follow_ups.rb +58 -0
- data/lib/candidhealth/encounters/v_4/types/intervention.rb +87 -0
- data/lib/candidhealth/encounters/v_4/types/intervention_category.rb +14 -0
- data/lib/candidhealth/encounters/v_4/types/lab.rb +60 -0
- data/lib/candidhealth/encounters/v_4/types/lab_code_type.rb +12 -0
- data/lib/candidhealth/encounters/v_4/types/medication.rb +84 -0
- data/lib/candidhealth/encounters/v_4/types/note_category.rb +24 -0
- data/lib/candidhealth/encounters/v_4/types/patient_history_category.rb +59 -0
- data/lib/candidhealth/encounters/v_4/types/patient_history_category_enum.rb +14 -0
- data/lib/candidhealth/encounters/v_4/types/prior_authorization_number.rb +9 -0
- data/lib/candidhealth/encounters/v_4/types/responsible_party_type.rb +13 -0
- data/lib/candidhealth/encounters/v_4/types/rx_cui.rb +9 -0
- data/lib/candidhealth/encounters/v_4/types/service_authorization_exception_code.rb +19 -0
- data/lib/candidhealth/encounters/v_4/types/synchronicity_type.rb +12 -0
- data/lib/candidhealth/encounters/v_4/types/vitals.rb +78 -0
- data/lib/candidhealth/era/types/era.rb +59 -0
- data/lib/candidhealth/era/types/era_base.rb +53 -0
- data/lib/candidhealth/era/types/era_id.rb +7 -0
- data/lib/candidhealth/era/types/era_not_fully_processed_error_message.rb +53 -0
- data/lib/candidhealth/era_commons/types/claim_status_code_create.rb +18 -0
- data/lib/candidhealth/expected_network_status/client.rb +31 -0
- data/lib/candidhealth/expected_network_status/v_1/client.rb +112 -0
- data/lib/candidhealth/expected_network_status/v_1/types/expected_network_status.rb +13 -0
- data/lib/candidhealth/expected_network_status/v_1/types/expected_network_status_response.rb +66 -0
- data/lib/candidhealth/expected_network_status/v_2/client.rb +183 -0
- data/lib/candidhealth/expected_network_status/v_2/types/compute_all_in_network_providers_request.rb +119 -0
- data/lib/candidhealth/expected_network_status/v_2/types/compute_all_in_network_providers_response.rb +65 -0
- data/lib/candidhealth/expected_network_status/v_2/types/compute_all_in_network_rendering_providers_result.rb +107 -0
- data/lib/candidhealth/expected_network_status/v_2/types/expected_network_status_check_error_message.rb +49 -0
- data/lib/candidhealth/expected_network_status/v_2/types/expected_network_status_request_v_2.rb +119 -0
- data/lib/candidhealth/expected_network_status/v_2/types/expected_network_status_response_v_2.rb +62 -0
- data/lib/candidhealth/expected_network_status/v_2/types/expected_network_status_subscriber_information.rb +67 -0
- data/lib/candidhealth/expected_network_status/v_2/types/expected_network_status_v_2.rb +107 -0
- data/lib/candidhealth/expected_network_status/v_2/types/explanation.rb +18 -0
- data/lib/candidhealth/expected_network_status/v_2/types/in_network_rendering_providers_detail.rb +67 -0
- data/lib/candidhealth/expected_network_status/v_2/types/in_network_status.rb +57 -0
- data/lib/candidhealth/expected_network_status/v_2/types/indeterminate_network_status.rb +74 -0
- data/lib/candidhealth/expected_network_status/v_2/types/insurance_type.rb +62 -0
- data/lib/candidhealth/expected_network_status/v_2/types/insurance_type_codes.rb +103 -0
- data/lib/candidhealth/expected_network_status/v_2/types/line_of_business.rb +13 -0
- data/lib/candidhealth/expected_network_status/v_2/types/network_status_check_id.rb +9 -0
- data/lib/candidhealth/expected_network_status/v_2/types/out_of_network_status.rb +67 -0
- data/lib/candidhealth/expected_network_status/v_2/types/service_type.rb +51 -0
- data/lib/candidhealth/exports/client.rb +28 -0
- data/lib/candidhealth/exports/v_3/client.rb +102 -0
- data/lib/candidhealth/exports/v_3/types/get_exports_response.rb +75 -0
- data/lib/candidhealth/financials/types/account_type.rb +10 -0
- data/lib/candidhealth/financials/types/allocation.rb +58 -0
- data/lib/candidhealth/financials/types/allocation_create.rb +60 -0
- data/lib/candidhealth/financials/types/allocation_target.rb +118 -0
- data/lib/candidhealth/financials/types/allocation_target_create.rb +118 -0
- data/lib/candidhealth/financials/types/billing_provider_allocation_target.rb +48 -0
- data/lib/candidhealth/financials/types/claim_allocation_target.rb +54 -0
- data/lib/candidhealth/financials/types/invoice_update.rb +90 -0
- data/lib/candidhealth/financials/types/note_update.rb +89 -0
- data/lib/candidhealth/financials/types/patient_transaction_source.rb +15 -0
- data/lib/candidhealth/financials/types/refund_reason.rb +9 -0
- data/lib/candidhealth/financials/types/refund_reason_update.rb +90 -0
- data/lib/candidhealth/financials/types/service_line_allocation_target.rb +61 -0
- data/lib/candidhealth/guarantor/client.rb +28 -0
- data/lib/candidhealth/guarantor/v_1/client.rb +224 -0
- data/lib/candidhealth/guarantor/v_1/types/encounter_has_existing_guarantor_error_type.rb +49 -0
- data/lib/candidhealth/guarantor/v_1/types/guarantor.rb +121 -0
- data/lib/candidhealth/guarantor/v_1/types/guarantor_base.rb +84 -0
- data/lib/candidhealth/guarantor/v_1/types/guarantor_create.rb +114 -0
- data/lib/candidhealth/guarantor/v_1/types/guarantor_id.rb +9 -0
- data/lib/candidhealth/identifiers/types/identifier.rb +82 -0
- data/lib/candidhealth/identifiers/types/identifier_base.rb +71 -0
- data/lib/candidhealth/identifiers/types/identifier_code.rb +10 -0
- data/lib/candidhealth/identifiers/types/identifier_create.rb +71 -0
- data/lib/candidhealth/identifiers/types/identifier_id.rb +7 -0
- data/lib/candidhealth/identifiers/types/identifier_update.rb +83 -0
- data/lib/candidhealth/identifiers/types/identifier_value.rb +92 -0
- data/lib/candidhealth/identifiers/types/medicaid_provider_identifier.rb +53 -0
- data/lib/candidhealth/identifiers/types/medicare_provider_identifier.rb +53 -0
- data/lib/candidhealth/identifiers/types/updatable_identifier.rb +105 -0
- data/lib/candidhealth/individual/types/gender.rb +13 -0
- data/lib/candidhealth/individual/types/individual_base.rb +58 -0
- data/lib/candidhealth/individual/types/individual_id.rb +7 -0
- data/lib/candidhealth/individual/types/patient.rb +126 -0
- data/lib/candidhealth/individual/types/patient_base.rb +89 -0
- data/lib/candidhealth/individual/types/patient_create.rb +119 -0
- data/lib/candidhealth/individual/types/subscriber.rb +110 -0
- data/lib/candidhealth/individual/types/subscriber_base.rb +91 -0
- data/lib/candidhealth/individual/types/subscriber_create.rb +103 -0
- data/lib/candidhealth/insurance_adjudications/client.rb +28 -0
- data/lib/candidhealth/insurance_adjudications/v_1/client.rb +143 -0
- data/lib/candidhealth/insurance_adjudications/v_1/types/claim_adjudication.rb +101 -0
- data/lib/candidhealth/insurance_adjudications/v_1/types/claim_adjudication_create.rb +95 -0
- data/lib/candidhealth/insurance_adjudications/v_1/types/insurance_adjudication.rb +99 -0
- data/lib/candidhealth/insurance_adjudications/v_1/types/insurance_adjudication_create.rb +109 -0
- data/lib/candidhealth/insurance_adjudications/v_1/types/insurance_adjudication_id.rb +9 -0
- data/lib/candidhealth/insurance_adjudications/v_1/types/service_line_adjudication.rb +112 -0
- data/lib/candidhealth/insurance_adjudications/v_1/types/service_line_adjudication_create.rb +105 -0
- data/lib/candidhealth/insurance_adjudications/v_1/types/service_line_adjudication_id.rb +9 -0
- data/lib/candidhealth/insurance_cards/v_2/types/insurance_card.rb +123 -0
- data/lib/candidhealth/insurance_cards/v_2/types/insurance_card_base.rb +73 -0
- data/lib/candidhealth/insurance_cards/v_2/types/insurance_card_create.rb +123 -0
- data/lib/candidhealth/insurance_cards/v_2/types/insurance_card_id.rb +9 -0
- data/lib/candidhealth/insurance_payments/client.rb +28 -0
- data/lib/candidhealth/insurance_payments/v_1/client.rb +269 -0
- data/lib/candidhealth/insurance_payments/v_1/types/insurance_payment.rb +98 -0
- data/lib/candidhealth/insurance_payments/v_1/types/insurance_payment_create.rb +91 -0
- data/lib/candidhealth/insurance_payments/v_1/types/insurance_payment_id.rb +9 -0
- data/lib/candidhealth/insurance_payments/v_1/types/insurance_payment_sort_field.rb +13 -0
- data/lib/candidhealth/insurance_payments/v_1/types/insurance_payments_page.rb +65 -0
- data/lib/candidhealth/insurance_refunds/client.rb +28 -0
- data/lib/candidhealth/insurance_refunds/v_1/client.rb +280 -0
- data/lib/candidhealth/insurance_refunds/v_1/types/insurance_refund.rb +105 -0
- data/lib/candidhealth/insurance_refunds/v_1/types/insurance_refund_create.rb +98 -0
- data/lib/candidhealth/insurance_refunds/v_1/types/insurance_refund_id.rb +9 -0
- data/lib/candidhealth/insurance_refunds/v_1/types/insurance_refund_sort_field.rb +14 -0
- data/lib/candidhealth/insurance_refunds/v_1/types/insurance_refunds_page.rb +65 -0
- data/lib/candidhealth/invoices/types/invoice.rb +134 -0
- data/lib/candidhealth/invoices/types/invoice_item.rb +53 -0
- data/lib/candidhealth/invoices/types/invoice_status.rb +13 -0
- data/lib/candidhealth/organization_providers/client.rb +28 -0
- data/lib/candidhealth/organization_providers/v_2/types/address_type.rb +11 -0
- data/lib/candidhealth/organization_providers/v_2/types/employment_status.rb +12 -0
- data/lib/candidhealth/organization_providers/v_2/types/license_type.rb +78 -0
- data/lib/candidhealth/organization_providers/v_2/types/organization_provider.rb +159 -0
- data/lib/candidhealth/organization_providers/v_2/types/organization_provider_address.rb +61 -0
- data/lib/candidhealth/organization_providers/v_2/types/organization_provider_base.rb +132 -0
- data/lib/candidhealth/organization_providers/v_2/types/organization_provider_id.rb +9 -0
- data/lib/candidhealth/organization_providers/v_2/types/organization_provider_sort_options.rb +14 -0
- data/lib/candidhealth/organization_providers/v_2/types/provider_type.rb +12 -0
- data/lib/candidhealth/organization_providers/v_3/client.rb +239 -0
- data/lib/candidhealth/organization_providers/v_3/types/organization_provider_create_v_2.rb +147 -0
- data/lib/candidhealth/organization_providers/v_3/types/organization_provider_page_v_2.rb +65 -0
- data/lib/candidhealth/organization_providers/v_3/types/organization_provider_update_v_2.rb +143 -0
- data/lib/candidhealth/organization_providers/v_3/types/organization_provider_v_2.rb +154 -0
- data/lib/candidhealth/organization_service_facilities/client.rb +28 -0
- data/lib/candidhealth/organization_service_facilities/v_2/client.rb +256 -0
- data/lib/candidhealth/organization_service_facilities/v_2/types/organization_service_facility.rb +134 -0
- data/lib/candidhealth/organization_service_facilities/v_2/types/organization_service_facility_create.rb +127 -0
- data/lib/candidhealth/organization_service_facilities/v_2/types/organization_service_facility_id.rb +9 -0
- data/lib/candidhealth/organization_service_facilities/v_2/types/organization_service_facility_page.rb +65 -0
- data/lib/candidhealth/organization_service_facilities/v_2/types/organization_service_facility_update.rb +127 -0
- data/lib/candidhealth/organization_service_facilities/v_2/types/service_facility_mode.rb +12 -0
- data/lib/candidhealth/organization_service_facilities/v_2/types/service_facility_operational_status.rb +16 -0
- data/lib/candidhealth/organization_service_facilities/v_2/types/service_facility_physical_type.rb +24 -0
- data/lib/candidhealth/organization_service_facilities/v_2/types/service_facility_status.rb +13 -0
- data/lib/candidhealth/organization_service_facilities/v_2/types/service_facility_type.rb +133 -0
- data/lib/candidhealth/patient_payments/client.rb +28 -0
- data/lib/candidhealth/patient_payments/v_3/types/patient_payment.rb +130 -0
- data/lib/candidhealth/patient_payments/v_3/types/patient_payment_id.rb +9 -0
- data/lib/candidhealth/patient_payments/v_3/types/patient_payment_source.rb +19 -0
- data/lib/candidhealth/patient_payments/v_3/types/patient_payment_status.rb +21 -0
- data/lib/candidhealth/patient_payments/v_4/client.rb +304 -0
- data/lib/candidhealth/patient_payments/v_4/types/patient_payment.rb +120 -0
- data/lib/candidhealth/patient_payments/v_4/types/patient_payment_id.rb +9 -0
- data/lib/candidhealth/patient_payments/v_4/types/patient_payment_sort_field.rb +14 -0
- data/lib/candidhealth/patient_payments/v_4/types/patient_payments_page.rb +65 -0
- data/lib/candidhealth/patient_refunds/client.rb +28 -0
- data/lib/candidhealth/patient_refunds/v_1/client.rb +316 -0
- data/lib/candidhealth/patient_refunds/v_1/types/patient_refund.rb +127 -0
- data/lib/candidhealth/patient_refunds/v_1/types/patient_refund_id.rb +9 -0
- data/lib/candidhealth/patient_refunds/v_1/types/patient_refund_sort_field.rb +15 -0
- data/lib/candidhealth/patient_refunds/v_1/types/patient_refunds_page.rb +65 -0
- data/lib/candidhealth/payers/client.rb +28 -0
- data/lib/candidhealth/payers/v_3/client.rb +104 -0
- data/lib/candidhealth/payers/v_3/types/payer.rb +60 -0
- data/lib/candidhealth/payers/v_3/types/payer_id.rb +9 -0
- data/lib/candidhealth/payers/v_3/types/payer_identifier.rb +94 -0
- data/lib/candidhealth/payers/v_3/types/payer_info.rb +56 -0
- data/lib/candidhealth/payers/v_3/types/payer_name.rb +9 -0
- data/lib/candidhealth/payers/v_3/types/payer_page.rb +65 -0
- data/lib/candidhealth/payers/v_3/types/payer_uuid.rb +9 -0
- data/lib/candidhealth/remits/v_1/types/payee.rb +60 -0
- data/lib/candidhealth/remits/v_1/types/payee_identifier.rb +102 -0
- data/lib/candidhealth/service_facility/client.rb +89 -0
- data/lib/candidhealth/service_facility/types/encounter_service_facility.rb +77 -0
- data/lib/candidhealth/service_facility/types/encounter_service_facility_base.rb +72 -0
- data/lib/candidhealth/service_facility/types/service_facility_id.rb +7 -0
- data/lib/candidhealth/service_lines/v_2/types/denial_reason_content.rb +40 -0
- data/lib/candidhealth/service_lines/v_2/types/drug_identification.rb +86 -0
- data/lib/candidhealth/service_lines/v_2/types/measurement_unit_code.rb +15 -0
- data/lib/candidhealth/service_lines/v_2/types/service_id_qualifier.rb +17 -0
- data/lib/candidhealth/service_lines/v_2/types/service_line.rb +225 -0
- data/lib/candidhealth/service_lines/v_2/types/service_line_adjustment.rb +79 -0
- data/lib/candidhealth/service_lines/v_2/types/service_line_create.rb +120 -0
- data/lib/candidhealth/service_lines/v_2/types/service_line_denial_reason.rb +52 -0
- data/lib/candidhealth/service_lines/v_2/types/service_line_era_data.rb +62 -0
- data/lib/candidhealth/tags/types/tag.rb +65 -0
- data/lib/candidhealth/tags/types/tag_color_enum.rb +18 -0
- data/lib/candidhealth/tags/types/tag_create.rb +59 -0
- data/lib/candidhealth/tags/types/tag_id.rb +7 -0
- data/lib/candidhealth/tasks/client.rb +28 -0
- data/lib/candidhealth/tasks/commons/types/task_category.rb +50 -0
- data/lib/candidhealth/tasks/commons/types/task_status.rb +17 -0
- data/lib/candidhealth/tasks/commons/types/task_type.rb +22 -0
- data/lib/candidhealth/tasks/v_3/client.rb +259 -0
- data/lib/candidhealth/tasks/v_3/types/task.rb +170 -0
- data/lib/candidhealth/tasks/v_3/types/task_action.rb +66 -0
- data/lib/candidhealth/tasks/v_3/types/task_action_execution_method.rb +79 -0
- data/lib/candidhealth/tasks/v_3/types/task_action_type.rb +12 -0
- data/lib/candidhealth/tasks/v_3/types/task_actions.rb +53 -0
- data/lib/candidhealth/tasks/v_3/types/task_assignment.rb +56 -0
- data/lib/candidhealth/tasks/v_3/types/task_create_v_3.rb +95 -0
- data/lib/candidhealth/tasks/v_3/types/task_note.rb +79 -0
- data/lib/candidhealth/tasks/v_3/types/task_page.rb +65 -0
- data/lib/candidhealth/tasks/v_3/types/task_sort_options.rb +32 -0
- data/lib/candidhealth/tasks/v_3/types/task_update_v_3.rb +66 -0
- data/lib/candidhealth/tasks/v_3/types/task_updated_to_deprecated_status_error_type.rb +50 -0
- data/lib/candidhealth/write_offs/client.rb +28 -0
- data/lib/candidhealth/write_offs/v_1/client.rb +218 -0
- data/lib/candidhealth/write_offs/v_1/types/create_write_offs_response.rb +53 -0
- data/lib/candidhealth/write_offs/v_1/types/insurance_write_off.rb +119 -0
- data/lib/candidhealth/write_offs/v_1/types/insurance_write_off_create.rb +100 -0
- data/lib/candidhealth/write_offs/v_1/types/insurance_write_off_reason.rb +25 -0
- data/lib/candidhealth/write_offs/v_1/types/insurance_write_off_target.rb +103 -0
- data/lib/candidhealth/write_offs/v_1/types/patient_write_off.rb +102 -0
- data/lib/candidhealth/write_offs/v_1/types/patient_write_off_create.rb +83 -0
- data/lib/candidhealth/write_offs/v_1/types/patient_write_off_reason.rb +19 -0
- data/lib/candidhealth/write_offs/v_1/types/write_off.rb +94 -0
- data/lib/candidhealth/write_offs/v_1/types/write_off_create.rb +94 -0
- data/lib/candidhealth/write_offs/v_1/types/write_off_id.rb +9 -0
- data/lib/candidhealth/write_offs/v_1/types/write_off_sort_field.rb +13 -0
- data/lib/candidhealth/write_offs/v_1/types/write_offs_page.rb +65 -0
- data/lib/candidhealth/x_12/v_1/types/carc.rb +412 -0
- data/lib/candidhealth/x_12/v_1/types/claim_adjustment_reason_code.rb +62 -0
- data/lib/candidhealth/x_12/v_1/types/rarc.rb +1070 -0
- data/lib/candidhealth/x_12/v_1/types/remittance_advice_remark_code.rb +50 -0
- data/lib/candidhealth.rb +129 -0
- data/lib/environment.rb +8 -0
- data/lib/gemconfig.rb +14 -0
- data/lib/requests.rb +113 -0
- data/lib/types_export.rb +303 -0
- metadata +468 -0
@@ -0,0 +1,72 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "../../commons/types/street_address_long_zip"
|
4
|
+
require "json"
|
5
|
+
|
6
|
+
module CandidApiClient
|
7
|
+
class ServiceFacility
|
8
|
+
# Encounter Service facility is typically the location a medical service was rendered, such as a provider office or hospital.
|
9
|
+
# For telehealth, service facility can represent the provider's location when the service was delivered (e.g., home),
|
10
|
+
# or the location where an in-person visit would have taken place, whichever is easier to identify.
|
11
|
+
# If the provider is in-network, service facility may be defined in payer contracts.
|
12
|
+
# Box 32 on the CMS-1500 claim form.
|
13
|
+
# Note that for an in-network claim to be successfully adjudicated, the service facility address listed on claims
|
14
|
+
# must match what was provided to the payer during the credentialing process.
|
15
|
+
class EncounterServiceFacilityBase
|
16
|
+
attr_reader :organization_name, :npi, :address, :additional_properties
|
17
|
+
|
18
|
+
# @param organization_name [String]
|
19
|
+
# @param npi [String] An NPI specific to the service facility if applicable, i.e. if it has one and is not under the billing provider's NPI.
|
20
|
+
# Box 32 section (a) of the CMS-1500 claim form.
|
21
|
+
# @param address [Commons::StreetAddressLongZip] zip_plus_four_code is required for service facility address. When the zip_plus_four_code is not available use "9998" as per CMS documentation.
|
22
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
23
|
+
# @return [ServiceFacility::EncounterServiceFacilityBase]
|
24
|
+
def initialize(organization_name:, address:, npi: nil, additional_properties: nil)
|
25
|
+
# @type [String]
|
26
|
+
@organization_name = organization_name
|
27
|
+
# @type [String] An NPI specific to the service facility if applicable, i.e. if it has one and is not under the billing provider's NPI.
|
28
|
+
# Box 32 section (a) of the CMS-1500 claim form.
|
29
|
+
@npi = npi
|
30
|
+
# @type [Commons::StreetAddressLongZip] zip_plus_four_code is required for service facility address. When the zip_plus_four_code is not available use "9998" as per CMS documentation.
|
31
|
+
@address = address
|
32
|
+
# @type [OpenStruct] Additional properties unmapped to the current class definition
|
33
|
+
@additional_properties = additional_properties
|
34
|
+
end
|
35
|
+
|
36
|
+
# Deserialize a JSON object to an instance of EncounterServiceFacilityBase
|
37
|
+
#
|
38
|
+
# @param json_object [JSON]
|
39
|
+
# @return [ServiceFacility::EncounterServiceFacilityBase]
|
40
|
+
def self.from_json(json_object:)
|
41
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
42
|
+
parsed_json = JSON.parse(json_object)
|
43
|
+
organization_name = struct.organization_name
|
44
|
+
npi = struct.npi
|
45
|
+
if parsed_json["address"].nil?
|
46
|
+
address = nil
|
47
|
+
else
|
48
|
+
address = parsed_json["address"].to_json
|
49
|
+
address = Commons::StreetAddressLongZip.from_json(json_object: address)
|
50
|
+
end
|
51
|
+
new(organization_name: organization_name, npi: npi, address: address, additional_properties: struct)
|
52
|
+
end
|
53
|
+
|
54
|
+
# Serialize an instance of EncounterServiceFacilityBase to a JSON object
|
55
|
+
#
|
56
|
+
# @return [JSON]
|
57
|
+
def to_json(*_args)
|
58
|
+
{ "organization_name": @organization_name, "npi": @npi, "address": @address }.to_json
|
59
|
+
end
|
60
|
+
|
61
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given hash and check each fields type against the current object's property definitions.
|
62
|
+
#
|
63
|
+
# @param obj [Object]
|
64
|
+
# @return [Void]
|
65
|
+
def self.validate_raw(obj:)
|
66
|
+
obj.organization_name.is_a?(String) != false || raise("Passed value for field obj.organization_name is not the expected type, validation failed.")
|
67
|
+
obj.npi&.is_a?(String) != false || raise("Passed value for field obj.npi is not the expected type, validation failed.")
|
68
|
+
Commons::StreetAddressLongZip.validate_raw(obj: obj.address)
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
72
|
+
end
|
@@ -0,0 +1,40 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module CandidApiClient
|
4
|
+
module ServiceLines
|
5
|
+
module V2
|
6
|
+
class DenialReasonContent
|
7
|
+
AUTHORIZATION_REQUIRED = "Authorization Required"
|
8
|
+
REFERRAL_REQUIRED = "Referral Required"
|
9
|
+
MEDICAL_RECORDS_REQUESTED = "Medical Records Requested"
|
10
|
+
TIMELY_FILING = "Timely Filing"
|
11
|
+
DUPLICATE_CLAIM = "Duplicate Claim"
|
12
|
+
INCORRECT_PLACE_OF_SERVICE = "Incorrect Place of Service"
|
13
|
+
INCORRECT_PATIENT_GENDER = "Incorrect Patient Gender"
|
14
|
+
BUNDLED = "Bundled"
|
15
|
+
EXCEEDED_BILLABLE_TIME = "Exceeded Billable Time"
|
16
|
+
INVALID_PROVIDER_INFORMATION = "Invalid Provider Information"
|
17
|
+
INVALID_DIAGNOSIS_CODE = "Invalid Diagnosis Code"
|
18
|
+
INCORRECT_PROCEDURE_CODE = "Incorrect Procedure Code"
|
19
|
+
INVALID_MODIFIER = "Invalid Modifier"
|
20
|
+
MISSING_NDC_CODE = "Missing NDC Code"
|
21
|
+
INVALID_INSURANCE_DATA = "Invalid Insurance Data"
|
22
|
+
NO_ACTIVE_COVERAGE = "No Active Coverage"
|
23
|
+
COORDINATION_OF_BENEFITS = "Coordination of Benefits"
|
24
|
+
INCORRECT_PAYER = "Incorrect Payer"
|
25
|
+
CREDENTIALING = "Credentialing"
|
26
|
+
NO_EFFECTIVE_CONTRACT = "No Effective Contract"
|
27
|
+
MISSING_W_9 = "Missing W-9"
|
28
|
+
MISSING_CONTRACT_LINKAGE = "Missing Contract Linkage"
|
29
|
+
NON_COVERED_BENEFIT = "Non-Covered Benefit"
|
30
|
+
EXPERIMENTAL_PROCEDURE = "Experimental Procedure"
|
31
|
+
NOT_MEDICALLY_NECESSARY = "Not Medically Necessary"
|
32
|
+
INFO_REQUESTED_FROM_PROVIDER = "Info Requested from Provider"
|
33
|
+
INFO_REQUESTED_FROM_PATIENT = "Info Requested from Patient"
|
34
|
+
BILLING_ERROR = "Billing Error"
|
35
|
+
UNKNOWN = "Unknown"
|
36
|
+
MAX_BENEFIT_REACHED = "Max Benefit Reached"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
@@ -0,0 +1,86 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "service_id_qualifier"
|
4
|
+
require_relative "measurement_unit_code"
|
5
|
+
require "json"
|
6
|
+
|
7
|
+
module CandidApiClient
|
8
|
+
module ServiceLines
|
9
|
+
module V2
|
10
|
+
class DrugIdentification
|
11
|
+
attr_reader :service_id_qualifier, :national_drug_code, :national_drug_unit_count, :measurement_unit_code,
|
12
|
+
:link_sequence_number, :pharmacy_prescription_number, :additional_properties
|
13
|
+
|
14
|
+
# @param service_id_qualifier [ServiceLines::V2::ServiceIdQualifier]
|
15
|
+
# @param national_drug_code [String]
|
16
|
+
# @param national_drug_unit_count [String]
|
17
|
+
# @param measurement_unit_code [ServiceLines::V2::MeasurementUnitCode]
|
18
|
+
# @param link_sequence_number [String]
|
19
|
+
# @param pharmacy_prescription_number [String]
|
20
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
21
|
+
# @return [ServiceLines::V2::DrugIdentification]
|
22
|
+
def initialize(service_id_qualifier:, national_drug_code:, national_drug_unit_count:, measurement_unit_code:,
|
23
|
+
link_sequence_number: nil, pharmacy_prescription_number: nil, additional_properties: nil)
|
24
|
+
# @type [ServiceLines::V2::ServiceIdQualifier]
|
25
|
+
@service_id_qualifier = service_id_qualifier
|
26
|
+
# @type [String]
|
27
|
+
@national_drug_code = national_drug_code
|
28
|
+
# @type [String]
|
29
|
+
@national_drug_unit_count = national_drug_unit_count
|
30
|
+
# @type [ServiceLines::V2::MeasurementUnitCode]
|
31
|
+
@measurement_unit_code = measurement_unit_code
|
32
|
+
# @type [String]
|
33
|
+
@link_sequence_number = link_sequence_number
|
34
|
+
# @type [String]
|
35
|
+
@pharmacy_prescription_number = pharmacy_prescription_number
|
36
|
+
# @type [OpenStruct] Additional properties unmapped to the current class definition
|
37
|
+
@additional_properties = additional_properties
|
38
|
+
end
|
39
|
+
|
40
|
+
# Deserialize a JSON object to an instance of DrugIdentification
|
41
|
+
#
|
42
|
+
# @param json_object [JSON]
|
43
|
+
# @return [ServiceLines::V2::DrugIdentification]
|
44
|
+
def self.from_json(json_object:)
|
45
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
46
|
+
JSON.parse(json_object)
|
47
|
+
service_id_qualifier = struct.service_id_qualifier
|
48
|
+
national_drug_code = struct.national_drug_code
|
49
|
+
national_drug_unit_count = struct.national_drug_unit_count
|
50
|
+
measurement_unit_code = struct.measurement_unit_code
|
51
|
+
link_sequence_number = struct.link_sequence_number
|
52
|
+
pharmacy_prescription_number = struct.pharmacy_prescription_number
|
53
|
+
new(service_id_qualifier: service_id_qualifier, national_drug_code: national_drug_code,
|
54
|
+
national_drug_unit_count: national_drug_unit_count, measurement_unit_code: measurement_unit_code, link_sequence_number: link_sequence_number, pharmacy_prescription_number: pharmacy_prescription_number, additional_properties: struct)
|
55
|
+
end
|
56
|
+
|
57
|
+
# Serialize an instance of DrugIdentification to a JSON object
|
58
|
+
#
|
59
|
+
# @return [JSON]
|
60
|
+
def to_json(*_args)
|
61
|
+
{
|
62
|
+
"service_id_qualifier": @service_id_qualifier,
|
63
|
+
"national_drug_code": @national_drug_code,
|
64
|
+
"national_drug_unit_count": @national_drug_unit_count,
|
65
|
+
"measurement_unit_code": @measurement_unit_code,
|
66
|
+
"link_sequence_number": @link_sequence_number,
|
67
|
+
"pharmacy_prescription_number": @pharmacy_prescription_number
|
68
|
+
}.to_json
|
69
|
+
end
|
70
|
+
|
71
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given hash and check each fields type against the current object's property definitions.
|
72
|
+
#
|
73
|
+
# @param obj [Object]
|
74
|
+
# @return [Void]
|
75
|
+
def self.validate_raw(obj:)
|
76
|
+
obj.service_id_qualifier.is_a?(ServiceLines::V2::ServiceIdQualifier) != false || raise("Passed value for field obj.service_id_qualifier is not the expected type, validation failed.")
|
77
|
+
obj.national_drug_code.is_a?(String) != false || raise("Passed value for field obj.national_drug_code is not the expected type, validation failed.")
|
78
|
+
obj.national_drug_unit_count.is_a?(String) != false || raise("Passed value for field obj.national_drug_unit_count is not the expected type, validation failed.")
|
79
|
+
obj.measurement_unit_code.is_a?(ServiceLines::V2::MeasurementUnitCode) != false || raise("Passed value for field obj.measurement_unit_code is not the expected type, validation failed.")
|
80
|
+
obj.link_sequence_number&.is_a?(String) != false || raise("Passed value for field obj.link_sequence_number is not the expected type, validation failed.")
|
81
|
+
obj.pharmacy_prescription_number&.is_a?(String) != false || raise("Passed value for field obj.pharmacy_prescription_number is not the expected type, validation failed.")
|
82
|
+
end
|
83
|
+
end
|
84
|
+
end
|
85
|
+
end
|
86
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module CandidApiClient
|
4
|
+
module ServiceLines
|
5
|
+
module V2
|
6
|
+
class ServiceIdQualifier
|
7
|
+
EAN_UCC_13 = "EN"
|
8
|
+
EAN_UCC_8 = "EO"
|
9
|
+
HIBC = "HI"
|
10
|
+
NDC_5_4_2_FORMAT = "N4"
|
11
|
+
CUSTOMER_ORDER_NUMBER = "ON"
|
12
|
+
GTIN = "UK"
|
13
|
+
UCC_12 = "UP"
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
@@ -0,0 +1,225 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "../../../commons/types/procedure_modifier"
|
4
|
+
require_relative "../../../diagnoses/types/diagnosis_id"
|
5
|
+
require_relative "service_line_era_data"
|
6
|
+
require_relative "service_line_adjustment"
|
7
|
+
require_relative "../../../invoices/types/invoice"
|
8
|
+
require_relative "service_line_denial_reason"
|
9
|
+
require_relative "../../../commons/types/facility_type_code"
|
10
|
+
require_relative "../../../commons/types/service_line_id"
|
11
|
+
require_relative "../../../commons/types/decimal"
|
12
|
+
require_relative "../../../commons/types/service_line_units"
|
13
|
+
require_relative "../../../commons/types/claim_id"
|
14
|
+
require_relative "../../../commons/types/date_range_optional_end"
|
15
|
+
require "json"
|
16
|
+
|
17
|
+
module CandidApiClient
|
18
|
+
module ServiceLines
|
19
|
+
module V2
|
20
|
+
class ServiceLine
|
21
|
+
attr_reader :modifiers, :charge_amount_cents, :allowed_amount_cents, :insurance_balance_cents,
|
22
|
+
:patient_balance_cents, :paid_amount_cents, :patient_responsibility_cents, :diagnosis_id_zero, :diagnosis_id_one, :diagnosis_id_two, :diagnosis_id_three, :service_line_era_data, :service_line_manual_adjustments, :related_invoices, :denial_reason, :place_of_service_code, :service_line_id, :procedure_code, :quantity, :units, :claim_id, :date_of_service_range, :description, :additional_properties
|
23
|
+
|
24
|
+
# @param modifiers [Array<Commons::ProcedureModifier>]
|
25
|
+
# @param charge_amount_cents [Integer]
|
26
|
+
# @param allowed_amount_cents [Integer]
|
27
|
+
# @param insurance_balance_cents [Integer]
|
28
|
+
# @param patient_balance_cents [Integer]
|
29
|
+
# @param paid_amount_cents [Integer]
|
30
|
+
# @param patient_responsibility_cents [Integer]
|
31
|
+
# @param diagnosis_id_zero [Diagnoses::DIAGNOSIS_ID]
|
32
|
+
# @param diagnosis_id_one [Diagnoses::DIAGNOSIS_ID]
|
33
|
+
# @param diagnosis_id_two [Diagnoses::DIAGNOSIS_ID]
|
34
|
+
# @param diagnosis_id_three [Diagnoses::DIAGNOSIS_ID]
|
35
|
+
# @param service_line_era_data [ServiceLines::V2::ServiceLineEraData]
|
36
|
+
# @param service_line_manual_adjustments [Array<ServiceLines::V2::ServiceLineAdjustment>]
|
37
|
+
# @param related_invoices [Array<Invoices::Invoice>]
|
38
|
+
# @param denial_reason [ServiceLines::V2::ServiceLineDenialReason]
|
39
|
+
# @param place_of_service_code [Commons::FacilityTypeCode]
|
40
|
+
# @param service_line_id [Commons::SERVICE_LINE_ID]
|
41
|
+
# @param procedure_code [String]
|
42
|
+
# @param quantity [Commons::DECIMAL] String representation of a Decimal that can be parsed by most libraries.
|
43
|
+
# A ServiceLine quantity cannot contain more than one digit of precision.
|
44
|
+
# Example: 1.1 is valid, 1.11 is not.
|
45
|
+
# @param units [Commons::ServiceLineUnits]
|
46
|
+
# @param claim_id [Commons::CLAIM_ID]
|
47
|
+
# @param date_of_service_range [Commons::DateRangeOptionalEnd] A range of dates of service for this service line. If the service line is for a single date, the end date
|
48
|
+
# will be empty.
|
49
|
+
# @param description [String] A free-form description to clarify the related data elements and their content. Maps to SV1-01, C003-07 on the 837-P.
|
50
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
51
|
+
# @return [ServiceLines::V2::ServiceLine]
|
52
|
+
def initialize(service_line_id:, procedure_code:, quantity:, units:, claim_id:, date_of_service_range:, modifiers: nil, charge_amount_cents: nil, allowed_amount_cents: nil,
|
53
|
+
insurance_balance_cents: nil, patient_balance_cents: nil, paid_amount_cents: nil, patient_responsibility_cents: nil, diagnosis_id_zero: nil, diagnosis_id_one: nil, diagnosis_id_two: nil, diagnosis_id_three: nil, service_line_era_data: nil, service_line_manual_adjustments: nil, related_invoices: nil, denial_reason: nil, place_of_service_code: nil, description: nil, additional_properties: nil)
|
54
|
+
# @type [Array<Commons::ProcedureModifier>]
|
55
|
+
@modifiers = modifiers
|
56
|
+
# @type [Integer]
|
57
|
+
@charge_amount_cents = charge_amount_cents
|
58
|
+
# @type [Integer]
|
59
|
+
@allowed_amount_cents = allowed_amount_cents
|
60
|
+
# @type [Integer]
|
61
|
+
@insurance_balance_cents = insurance_balance_cents
|
62
|
+
# @type [Integer]
|
63
|
+
@patient_balance_cents = patient_balance_cents
|
64
|
+
# @type [Integer]
|
65
|
+
@paid_amount_cents = paid_amount_cents
|
66
|
+
# @type [Integer]
|
67
|
+
@patient_responsibility_cents = patient_responsibility_cents
|
68
|
+
# @type [Diagnoses::DIAGNOSIS_ID]
|
69
|
+
@diagnosis_id_zero = diagnosis_id_zero
|
70
|
+
# @type [Diagnoses::DIAGNOSIS_ID]
|
71
|
+
@diagnosis_id_one = diagnosis_id_one
|
72
|
+
# @type [Diagnoses::DIAGNOSIS_ID]
|
73
|
+
@diagnosis_id_two = diagnosis_id_two
|
74
|
+
# @type [Diagnoses::DIAGNOSIS_ID]
|
75
|
+
@diagnosis_id_three = diagnosis_id_three
|
76
|
+
# @type [ServiceLines::V2::ServiceLineEraData]
|
77
|
+
@service_line_era_data = service_line_era_data
|
78
|
+
# @type [Array<ServiceLines::V2::ServiceLineAdjustment>]
|
79
|
+
@service_line_manual_adjustments = service_line_manual_adjustments
|
80
|
+
# @type [Array<Invoices::Invoice>]
|
81
|
+
@related_invoices = related_invoices
|
82
|
+
# @type [ServiceLines::V2::ServiceLineDenialReason]
|
83
|
+
@denial_reason = denial_reason
|
84
|
+
# @type [Commons::FacilityTypeCode]
|
85
|
+
@place_of_service_code = place_of_service_code
|
86
|
+
# @type [Commons::SERVICE_LINE_ID]
|
87
|
+
@service_line_id = service_line_id
|
88
|
+
# @type [String]
|
89
|
+
@procedure_code = procedure_code
|
90
|
+
# @type [Commons::DECIMAL] String representation of a Decimal that can be parsed by most libraries.
|
91
|
+
# A ServiceLine quantity cannot contain more than one digit of precision.
|
92
|
+
# Example: 1.1 is valid, 1.11 is not.
|
93
|
+
@quantity = quantity
|
94
|
+
# @type [Commons::ServiceLineUnits]
|
95
|
+
@units = units
|
96
|
+
# @type [Commons::CLAIM_ID]
|
97
|
+
@claim_id = claim_id
|
98
|
+
# @type [Commons::DateRangeOptionalEnd] A range of dates of service for this service line. If the service line is for a single date, the end date
|
99
|
+
# will be empty.
|
100
|
+
@date_of_service_range = date_of_service_range
|
101
|
+
# @type [String] A free-form description to clarify the related data elements and their content. Maps to SV1-01, C003-07 on the 837-P.
|
102
|
+
@description = description
|
103
|
+
# @type [OpenStruct] Additional properties unmapped to the current class definition
|
104
|
+
@additional_properties = additional_properties
|
105
|
+
end
|
106
|
+
|
107
|
+
# Deserialize a JSON object to an instance of ServiceLine
|
108
|
+
#
|
109
|
+
# @param json_object [JSON]
|
110
|
+
# @return [ServiceLines::V2::ServiceLine]
|
111
|
+
def self.from_json(json_object:)
|
112
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
113
|
+
parsed_json = JSON.parse(json_object)
|
114
|
+
modifiers = struct.modifiers
|
115
|
+
charge_amount_cents = struct.charge_amount_cents
|
116
|
+
allowed_amount_cents = struct.allowed_amount_cents
|
117
|
+
insurance_balance_cents = struct.insurance_balance_cents
|
118
|
+
patient_balance_cents = struct.patient_balance_cents
|
119
|
+
paid_amount_cents = struct.paid_amount_cents
|
120
|
+
patient_responsibility_cents = struct.patient_responsibility_cents
|
121
|
+
diagnosis_id_zero = struct.diagnosis_id_zero
|
122
|
+
diagnosis_id_one = struct.diagnosis_id_one
|
123
|
+
diagnosis_id_two = struct.diagnosis_id_two
|
124
|
+
diagnosis_id_three = struct.diagnosis_id_three
|
125
|
+
if parsed_json["service_line_era_data"].nil?
|
126
|
+
service_line_era_data = nil
|
127
|
+
else
|
128
|
+
service_line_era_data = parsed_json["service_line_era_data"].to_json
|
129
|
+
service_line_era_data = ServiceLines::V2::ServiceLineEraData.from_json(json_object: service_line_era_data)
|
130
|
+
end
|
131
|
+
service_line_manual_adjustments = parsed_json["service_line_manual_adjustments"]&.map do |v|
|
132
|
+
v = v.to_json
|
133
|
+
ServiceLines::V2::ServiceLineAdjustment.from_json(json_object: v)
|
134
|
+
end
|
135
|
+
related_invoices = parsed_json["related_invoices"]&.map do |v|
|
136
|
+
v = v.to_json
|
137
|
+
Invoices::Invoice.from_json(json_object: v)
|
138
|
+
end
|
139
|
+
if parsed_json["denial_reason"].nil?
|
140
|
+
denial_reason = nil
|
141
|
+
else
|
142
|
+
denial_reason = parsed_json["denial_reason"].to_json
|
143
|
+
denial_reason = ServiceLines::V2::ServiceLineDenialReason.from_json(json_object: denial_reason)
|
144
|
+
end
|
145
|
+
place_of_service_code = struct.place_of_service_code
|
146
|
+
service_line_id = struct.service_line_id
|
147
|
+
procedure_code = struct.procedure_code
|
148
|
+
quantity = struct.quantity
|
149
|
+
units = struct.units
|
150
|
+
claim_id = struct.claim_id
|
151
|
+
if parsed_json["date_of_service_range"].nil?
|
152
|
+
date_of_service_range = nil
|
153
|
+
else
|
154
|
+
date_of_service_range = parsed_json["date_of_service_range"].to_json
|
155
|
+
date_of_service_range = Commons::DateRangeOptionalEnd.from_json(json_object: date_of_service_range)
|
156
|
+
end
|
157
|
+
description = struct.description
|
158
|
+
new(modifiers: modifiers, charge_amount_cents: charge_amount_cents,
|
159
|
+
allowed_amount_cents: allowed_amount_cents, insurance_balance_cents: insurance_balance_cents, patient_balance_cents: patient_balance_cents, paid_amount_cents: paid_amount_cents, patient_responsibility_cents: patient_responsibility_cents, diagnosis_id_zero: diagnosis_id_zero, diagnosis_id_one: diagnosis_id_one, diagnosis_id_two: diagnosis_id_two, diagnosis_id_three: diagnosis_id_three, service_line_era_data: service_line_era_data, service_line_manual_adjustments: service_line_manual_adjustments, related_invoices: related_invoices, denial_reason: denial_reason, place_of_service_code: place_of_service_code, service_line_id: service_line_id, procedure_code: procedure_code, quantity: quantity, units: units, claim_id: claim_id, date_of_service_range: date_of_service_range, description: description, additional_properties: struct)
|
160
|
+
end
|
161
|
+
|
162
|
+
# Serialize an instance of ServiceLine to a JSON object
|
163
|
+
#
|
164
|
+
# @return [JSON]
|
165
|
+
def to_json(*_args)
|
166
|
+
{
|
167
|
+
"modifiers": @modifiers,
|
168
|
+
"charge_amount_cents": @charge_amount_cents,
|
169
|
+
"allowed_amount_cents": @allowed_amount_cents,
|
170
|
+
"insurance_balance_cents": @insurance_balance_cents,
|
171
|
+
"patient_balance_cents": @patient_balance_cents,
|
172
|
+
"paid_amount_cents": @paid_amount_cents,
|
173
|
+
"patient_responsibility_cents": @patient_responsibility_cents,
|
174
|
+
"diagnosis_id_zero": @diagnosis_id_zero,
|
175
|
+
"diagnosis_id_one": @diagnosis_id_one,
|
176
|
+
"diagnosis_id_two": @diagnosis_id_two,
|
177
|
+
"diagnosis_id_three": @diagnosis_id_three,
|
178
|
+
"service_line_era_data": @service_line_era_data,
|
179
|
+
"service_line_manual_adjustments": @service_line_manual_adjustments,
|
180
|
+
"related_invoices": @related_invoices,
|
181
|
+
"denial_reason": @denial_reason,
|
182
|
+
"place_of_service_code": @place_of_service_code,
|
183
|
+
"service_line_id": @service_line_id,
|
184
|
+
"procedure_code": @procedure_code,
|
185
|
+
"quantity": @quantity,
|
186
|
+
"units": @units,
|
187
|
+
"claim_id": @claim_id,
|
188
|
+
"date_of_service_range": @date_of_service_range,
|
189
|
+
"description": @description
|
190
|
+
}.to_json
|
191
|
+
end
|
192
|
+
|
193
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given hash and check each fields type against the current object's property definitions.
|
194
|
+
#
|
195
|
+
# @param obj [Object]
|
196
|
+
# @return [Void]
|
197
|
+
def self.validate_raw(obj:)
|
198
|
+
obj.modifiers&.is_a?(Array) != false || raise("Passed value for field obj.modifiers is not the expected type, validation failed.")
|
199
|
+
obj.charge_amount_cents&.is_a?(Integer) != false || raise("Passed value for field obj.charge_amount_cents is not the expected type, validation failed.")
|
200
|
+
obj.allowed_amount_cents&.is_a?(Integer) != false || raise("Passed value for field obj.allowed_amount_cents is not the expected type, validation failed.")
|
201
|
+
obj.insurance_balance_cents&.is_a?(Integer) != false || raise("Passed value for field obj.insurance_balance_cents is not the expected type, validation failed.")
|
202
|
+
obj.patient_balance_cents&.is_a?(Integer) != false || raise("Passed value for field obj.patient_balance_cents is not the expected type, validation failed.")
|
203
|
+
obj.paid_amount_cents&.is_a?(Integer) != false || raise("Passed value for field obj.paid_amount_cents is not the expected type, validation failed.")
|
204
|
+
obj.patient_responsibility_cents&.is_a?(Integer) != false || raise("Passed value for field obj.patient_responsibility_cents is not the expected type, validation failed.")
|
205
|
+
obj.diagnosis_id_zero&.is_a?(String) != false || raise("Passed value for field obj.diagnosis_id_zero is not the expected type, validation failed.")
|
206
|
+
obj.diagnosis_id_one&.is_a?(String) != false || raise("Passed value for field obj.diagnosis_id_one is not the expected type, validation failed.")
|
207
|
+
obj.diagnosis_id_two&.is_a?(String) != false || raise("Passed value for field obj.diagnosis_id_two is not the expected type, validation failed.")
|
208
|
+
obj.diagnosis_id_three&.is_a?(String) != false || raise("Passed value for field obj.diagnosis_id_three is not the expected type, validation failed.")
|
209
|
+
obj.service_line_era_data.nil? || ServiceLines::V2::ServiceLineEraData.validate_raw(obj: obj.service_line_era_data)
|
210
|
+
obj.service_line_manual_adjustments&.is_a?(Array) != false || raise("Passed value for field obj.service_line_manual_adjustments is not the expected type, validation failed.")
|
211
|
+
obj.related_invoices&.is_a?(Array) != false || raise("Passed value for field obj.related_invoices is not the expected type, validation failed.")
|
212
|
+
obj.denial_reason.nil? || ServiceLines::V2::ServiceLineDenialReason.validate_raw(obj: obj.denial_reason)
|
213
|
+
obj.place_of_service_code&.is_a?(Commons::FacilityTypeCode) != false || raise("Passed value for field obj.place_of_service_code is not the expected type, validation failed.")
|
214
|
+
obj.service_line_id.is_a?(String) != false || raise("Passed value for field obj.service_line_id is not the expected type, validation failed.")
|
215
|
+
obj.procedure_code.is_a?(String) != false || raise("Passed value for field obj.procedure_code is not the expected type, validation failed.")
|
216
|
+
obj.quantity.is_a?(String) != false || raise("Passed value for field obj.quantity is not the expected type, validation failed.")
|
217
|
+
obj.units.is_a?(Commons::ServiceLineUnits) != false || raise("Passed value for field obj.units is not the expected type, validation failed.")
|
218
|
+
obj.claim_id.is_a?(String) != false || raise("Passed value for field obj.claim_id is not the expected type, validation failed.")
|
219
|
+
Commons::DateRangeOptionalEnd.validate_raw(obj: obj.date_of_service_range)
|
220
|
+
obj.description&.is_a?(String) != false || raise("Passed value for field obj.description is not the expected type, validation failed.")
|
221
|
+
end
|
222
|
+
end
|
223
|
+
end
|
224
|
+
end
|
225
|
+
end
|
@@ -0,0 +1,79 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "date"
|
4
|
+
require "json"
|
5
|
+
|
6
|
+
module CandidApiClient
|
7
|
+
module ServiceLines
|
8
|
+
module V2
|
9
|
+
class ServiceLineAdjustment
|
10
|
+
attr_reader :created_at, :adjustment_group_code, :adjustment_reason_code, :adjustment_amount_cents,
|
11
|
+
:adjustment_note, :additional_properties
|
12
|
+
|
13
|
+
# @param created_at [DateTime]
|
14
|
+
# @param adjustment_group_code [String]
|
15
|
+
# @param adjustment_reason_code [String]
|
16
|
+
# @param adjustment_amount_cents [Integer]
|
17
|
+
# @param adjustment_note [String]
|
18
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
19
|
+
# @return [ServiceLines::V2::ServiceLineAdjustment]
|
20
|
+
def initialize(created_at:, adjustment_group_code: nil, adjustment_reason_code: nil,
|
21
|
+
adjustment_amount_cents: nil, adjustment_note: nil, additional_properties: nil)
|
22
|
+
# @type [DateTime]
|
23
|
+
@created_at = created_at
|
24
|
+
# @type [String]
|
25
|
+
@adjustment_group_code = adjustment_group_code
|
26
|
+
# @type [String]
|
27
|
+
@adjustment_reason_code = adjustment_reason_code
|
28
|
+
# @type [Integer]
|
29
|
+
@adjustment_amount_cents = adjustment_amount_cents
|
30
|
+
# @type [String]
|
31
|
+
@adjustment_note = adjustment_note
|
32
|
+
# @type [OpenStruct] Additional properties unmapped to the current class definition
|
33
|
+
@additional_properties = additional_properties
|
34
|
+
end
|
35
|
+
|
36
|
+
# Deserialize a JSON object to an instance of ServiceLineAdjustment
|
37
|
+
#
|
38
|
+
# @param json_object [JSON]
|
39
|
+
# @return [ServiceLines::V2::ServiceLineAdjustment]
|
40
|
+
def self.from_json(json_object:)
|
41
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
42
|
+
parsed_json = JSON.parse(json_object)
|
43
|
+
created_at = (DateTime.parse(parsed_json["created_at"]) unless parsed_json["created_at"].nil?)
|
44
|
+
adjustment_group_code = struct.adjustment_group_code
|
45
|
+
adjustment_reason_code = struct.adjustment_reason_code
|
46
|
+
adjustment_amount_cents = struct.adjustment_amount_cents
|
47
|
+
adjustment_note = struct.adjustment_note
|
48
|
+
new(created_at: created_at, adjustment_group_code: adjustment_group_code,
|
49
|
+
adjustment_reason_code: adjustment_reason_code, adjustment_amount_cents: adjustment_amount_cents, adjustment_note: adjustment_note, additional_properties: struct)
|
50
|
+
end
|
51
|
+
|
52
|
+
# Serialize an instance of ServiceLineAdjustment to a JSON object
|
53
|
+
#
|
54
|
+
# @return [JSON]
|
55
|
+
def to_json(*_args)
|
56
|
+
{
|
57
|
+
"created_at": @created_at,
|
58
|
+
"adjustment_group_code": @adjustment_group_code,
|
59
|
+
"adjustment_reason_code": @adjustment_reason_code,
|
60
|
+
"adjustment_amount_cents": @adjustment_amount_cents,
|
61
|
+
"adjustment_note": @adjustment_note
|
62
|
+
}.to_json
|
63
|
+
end
|
64
|
+
|
65
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given hash and check each fields type against the current object's property definitions.
|
66
|
+
#
|
67
|
+
# @param obj [Object]
|
68
|
+
# @return [Void]
|
69
|
+
def self.validate_raw(obj:)
|
70
|
+
obj.created_at.is_a?(DateTime) != false || raise("Passed value for field obj.created_at is not the expected type, validation failed.")
|
71
|
+
obj.adjustment_group_code&.is_a?(String) != false || raise("Passed value for field obj.adjustment_group_code is not the expected type, validation failed.")
|
72
|
+
obj.adjustment_reason_code&.is_a?(String) != false || raise("Passed value for field obj.adjustment_reason_code is not the expected type, validation failed.")
|
73
|
+
obj.adjustment_amount_cents&.is_a?(Integer) != false || raise("Passed value for field obj.adjustment_amount_cents is not the expected type, validation failed.")
|
74
|
+
obj.adjustment_note&.is_a?(String) != false || raise("Passed value for field obj.adjustment_note is not the expected type, validation failed.")
|
75
|
+
end
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
79
|
+
end
|