Class: CandidApiClient::ChargeCapture::V1::AsyncV1Client

Inherits:
Object
  • Object
show all
Defined in:
lib/candidhealth/charge_capture/v_1/client.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(request_client:) ⇒ CandidApiClient::ChargeCapture::V1::AsyncV1Client

Parameters:



786
787
788
# File 'lib/candidhealth/charge_capture/v_1/client.rb', line 786

def initialize(request_client:)
  @request_client = request_client
end

Instance Attribute Details

#request_clientCandidApiClient::AsyncRequestClient (readonly)



782
783
784
# File 'lib/candidhealth/charge_capture/v_1/client.rb', line 782

def request_client
  @request_client
end

Instance Method Details

#create(data:, charge_external_id:, patient_external_id:, status:, ehr_source_url: nil, request_options: nil) ⇒ CandidApiClient::ChargeCapture::V1::Types::ChargeCapture

Examples:

api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
api.charge_capture.v_1.create(
  data: {  },
  charge_external_id: "charge_external_id",
  patient_external_id: "patient_external_id",
  status: PLANNED
)

Parameters:

  • data (Hash)

    Charge Capture data contains all the fields needed to create an encounter, but listed as optional. Candid will use this data when attempting to bundle multiple Charge Captures into a single encounter.Request of type CandidApiClient::ChargeCapture::V1::Types::ChargeCaptureData, as a Hash

    * :diagnoses (Array<CandidApiClient::Diagnoses::Types::DiagnosisCreate>)
    * :interventions (Array<CandidApiClient::Encounters::V4::Types::Intervention>)
    * :external_claim_submission (Hash)
      * :claim_created_at (DateTime)
      * :patient_control_number (String)
      * :submission_records (Array<CandidApiClient::ClaimSubmission::V1::Types::ClaimSubmissionRecordCreate>)
    * :service_lines (Array<CandidApiClient::ServiceLines::V2::Types::ServiceLineCreate>)
    * :patient_histories (Array<CandidApiClient::Encounters::V4::Types::PatientHistoryCategory>)
    * :billing_notes (Array<CandidApiClient::BillingNotes::V2::Types::BillingNoteBase>)
    * :patient (Hash)
      * :first_name (String)
      * :last_name (String)
      * :gender (CandidApiClient::Individual::Types::Gender)
      * :external_id (String)
      * :date_of_birth (Date)
      * :address (Hash)
        * :zip_plus_four_code (String)
        * :address_1 (String)
        * :address_2 (String)
        * :city (String)
        * :state (CandidApiClient::Commons::Types::State)
        * :zip_code (String)
      * :phone_numbers (Array<CandidApiClient::Commons::Types::PhoneNumber>)
      * :phone_consent (Boolean)
      * :email (String)
      * :email_consent (Boolean)
      * :non_insurance_payers (Array<String>)
      * :non_insurance_payers_info (Array<CandidApiClient::Individual::Types::PatientNonInsurancePayerInfoCreate>)
    * :service_facility (Hash)
      * :organization_name (String)
      * :npi (String)
      * :address (Hash)
        * :zip_plus_four_code (String)
        * :address_1 (String)
        * :address_2 (String)
        * :city (String)
        * :state (CandidApiClient::Commons::Types::State)
        * :zip_code (String)
      * :secondary_identification (String)
    * :rendering_provider (Hash)
      * :npi (String)
      * :taxonomy_code (String)
      * :address (Hash)
        * :zip_plus_four_code (String)
        * :address_1 (String)
        * :address_2 (String)
        * :city (String)
        * :state (CandidApiClient::Commons::Types::State)
        * :zip_code (String)
      * :first_name (String)
      * :last_name (String)
      * :organization_name (String)
    * :initial_referring_provider (Hash)
      * :npi (String)
      * :taxonomy_code (String)
      * :address (Hash)
        * :zip_plus_four_code (String)
        * :address_1 (String)
        * :address_2 (String)
        * :city (String)
        * :state (CandidApiClient::Commons::Types::State)
        * :zip_code (String)
      * :qualifier (CandidApiClient::Commons::Types::QualifierCode)
      * :first_name (String)
      * :last_name (String)
      * :organization_name (String)
    * :referring_provider (Hash)
      * :npi (String)
      * :taxonomy_code (String)
      * :address (Hash)
        * :zip_plus_four_code (String)
        * :address_1 (String)
        * :address_2 (String)
        * :city (String)
        * :state (CandidApiClient::Commons::Types::State)
        * :zip_code (String)
      * :first_name (String)
      * :last_name (String)
      * :organization_name (String)
    * :supervising_provider (Hash)
      * :npi (String)
      * :taxonomy_code (String)
      * :address (Hash)
        * :zip_plus_four_code (String)
        * :address_1 (String)
        * :address_2 (String)
        * :city (String)
        * :state (CandidApiClient::Commons::Types::State)
        * :zip_code (String)
      * :first_name (String)
      * :last_name (String)
      * :organization_name (String)
    * :billing_provider (Hash)
      * :address (Hash)
        * :zip_plus_four_code (String)
        * :address_1 (String)
        * :address_2 (String)
        * :city (String)
        * :state (CandidApiClient::Commons::Types::State)
        * :zip_code (String)
      * :tax_id (String)
      * :npi (String)
      * :taxonomy_code (String)
      * :provider_commercial_license_type (CandidApiClient::Commons::Types::BillingProviderCommercialLicenseType)
      * :first_name (String)
      * :last_name (String)
      * :organization_name (String)
    * :pay_to_address (Hash)
      * :zip_plus_four_code (String)
      * :address_1 (String)
      * :address_2 (String)
      * :city (String)
      * :state (CandidApiClient::Commons::Types::State)
      * :zip_code (String)
    * :benefits_assigned_to_provider (Boolean)
    * :prior_authorization_number (String)
    * :external_id (String)
    * :date_of_service (Date)
    * :tag_ids (Array<String>)
    * :clinical_notes (Array<CandidApiClient::Encounters::V4::Types::ClinicalNoteCategoryCreate>)
    * :billable_status (CandidApiClient::Encounters::V4::Types::BillableStatusType)
    * :responsible_party (CandidApiClient::Encounters::V4::Types::ResponsiblePartyType)
    * :provider_accepts_assignment (Boolean)
    * :synchronicity (CandidApiClient::Encounters::V4::Types::SynchronicityType)
    * :place_of_service_code (CandidApiClient::Commons::Types::FacilityTypeCode)
    * :appointment_type (String)
    * :end_date_of_service (Date)
    * :subscriber_primary (Hash)
      * :insurance_card (Hash)
        * :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 (CandidApiClient::Commons::Types::EmrPayerCrosswalk)
        * :group_number (String)
        * :plan_name (String)
        * :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)
        * :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)
        * :payer_plan_group_id (String)
      * :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)
      * :date_of_birth (Date)
      * :address (Hash)
        * :zip_plus_four_code (String)
        * :address_1 (String)
        * :address_2 (String)
        * :city (String)
        * :state (CandidApiClient::Commons::Types::State)
        * :zip_code (String)
      * :first_name (String)
      * :last_name (String)
      * :gender (CandidApiClient::Individual::Types::Gender)
    * :subscriber_secondary (Hash)
      * :insurance_card (Hash)
        * :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 (CandidApiClient::Commons::Types::EmrPayerCrosswalk)
        * :group_number (String)
        * :plan_name (String)
        * :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)
        * :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)
        * :payer_plan_group_id (String)
      * :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)
      * :date_of_birth (Date)
      * :address (Hash)
        * :zip_plus_four_code (String)
        * :address_1 (String)
        * :address_2 (String)
        * :city (String)
        * :state (CandidApiClient::Commons::Types::State)
        * :zip_code (String)
      * :first_name (String)
      * :last_name (String)
      * :gender (CandidApiClient::Individual::Types::Gender)
    * :subscriber_tertiary (Hash)
      * :insurance_card (Hash)
        * :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 (CandidApiClient::Commons::Types::EmrPayerCrosswalk)
        * :group_number (String)
        * :plan_name (String)
        * :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)
        * :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)
        * :payer_plan_group_id (String)
      * :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)
      * :date_of_birth (Date)
      * :address (Hash)
        * :zip_plus_four_code (String)
        * :address_1 (String)
        * :address_2 (String)
        * :city (String)
        * :state (CandidApiClient::Commons::Types::State)
        * :zip_code (String)
      * :first_name (String)
      * :last_name (String)
      * :gender (CandidApiClient::Individual::Types::Gender)
    * :additional_information (String)
    * :service_authorization_exception_code (CandidApiClient::Encounters::V4::Types::ServiceAuthorizationExceptionCode)
    * :admission_date (Date)
    * :discharge_date (Date)
    * :onset_of_current_illness_or_symptom_date (Date)
    * :last_menstrual_period_date (Date)
    * :delay_reason_code (CandidApiClient::Commons::Types::DelayReasonCode)
    * :patient_authorized_release (Boolean)
    * :schema_instances (Array<CandidApiClient::CustomSchemas::V1::Types::SchemaInstance>)
    * :vitals (Hash)
      * :height_in (Integer)
      * :weight_lbs (Integer)
      * :blood_pressure_systolic_mmhg (Integer)
      * :blood_pressure_diastolic_mmhg (Integer)
      * :body_temperature_f (Float)
      * :hemoglobin_gdl (Float)
      * :hematocrit_pct (Float)
    * :existing_medications (Array<CandidApiClient::Encounters::V4::Types::Medication>)
    * :guarantor (Hash)
      * :first_name (String)
      * :last_name (String)
      * :external_id (String)
      * :date_of_birth (Date)
      * :address (Hash)
        * :zip_plus_four_code (String)
        * :address_1 (String)
        * :address_2 (String)
        * :city (String)
        * :state (CandidApiClient::Commons::Types::State)
        * :zip_code (String)
      * :phone_numbers (Array<CandidApiClient::Commons::Types::PhoneNumber>)
      * :phone_consent (Boolean)
      * :email (String)
      * :email_consent (Boolean)
    * :referral_number (String)
    * :epsdt_referral (Hash)
      * :condition_indicator_1 (CandidApiClient::Commons::Types::EpsdtReferralConditionIndicatorCode)
      * :condition_indicator_2 (CandidApiClient::Commons::Types::EpsdtReferralConditionIndicatorCode)
      * :condition_indicator_3 (CandidApiClient::Commons::Types::EpsdtReferralConditionIndicatorCode)
    * :claim_supplemental_information (Array<CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation>)
    * :secondary_payer_carrier_code (String)
    
  • charge_external_id (String)

    A client-specified unique ID to associate with this encounter; for example, your internal encounter ID or a Dr. Chrono encounter ID. This field should not contain PHI.

  • ehr_source_url (String) (defaults to: nil)

    External URL reference that links to Charge Capture details within the external system (e.g. the EHR visit page). Send full URL format for the external link (e.g. emr_charge_capture_url.com/123).

  • patient_external_id (String)

    The patient ID from the external EMR platform for the patient

  • status (CandidApiClient::ChargeCapture::V1::Types::ChargeCaptureStatus)

    the status of the charge capture

  • request_options (CandidApiClient::RequestOptions) (defaults to: nil)

Returns:



1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
# File 'lib/candidhealth/charge_capture/v_1/client.rb', line 1060

def create(data:, charge_external_id:, patient_external_id:, status:, ehr_source_url: nil, request_options: nil)
  Async do
    response = @request_client.conn.post do |req|
      req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
      req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
      req.headers = {
    **(req.headers || {}),
    **@request_client.get_headers,
    **(request_options&.additional_headers || {})
      }.compact
      req.body = {
        **(request_options&.additional_body_parameters || {}),
        data: data,
        charge_external_id: charge_external_id,
        ehr_source_url: ehr_source_url,
        patient_external_id: patient_external_id,
        status: status
      }.compact
      req.url "#{@request_client.get_url(environment: CandidApi,
                                         request_options: request_options)}/api/charge_captures/v1"
    end
    CandidApiClient::ChargeCapture::V1::Types::ChargeCapture.from_json(json_object: response.body)
  end
end

#get(charge_capture_id:, request_options: nil) ⇒ CandidApiClient::ChargeCapture::V1::Types::ChargeCapture

Examples:

api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
api.charge_capture.v_1.get(charge_capture_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32")

Parameters:

Returns:



1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
# File 'lib/candidhealth/charge_capture/v_1/client.rb', line 1382

def get(charge_capture_id:, request_options: nil)
  Async do
    response = @request_client.conn.get do |req|
      req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
      req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
      req.headers = {
    **(req.headers || {}),
    **@request_client.get_headers,
    **(request_options&.additional_headers || {})
      }.compact
      req.url "#{@request_client.get_url(environment: CandidApi,
                                         request_options: request_options)}/api/charge_captures/v1/#{charge_capture_id}"
    end
    CandidApiClient::ChargeCapture::V1::Types::ChargeCapture.from_json(json_object: response.body)
  end
end

#get_all(limit: nil, sort: nil, sort_direction: nil, page_token: nil, patient_external_id: nil, status: nil, charge_external_id: nil, date_of_service_min: nil, date_of_service_max: nil, claim_ids: nil, claim_creation_ids: nil, billing_provider_npis: nil, service_facility_name: nil, primary_payer_ids: nil, rendering_provider_npis: nil, rendering_provider_names: nil, supervising_provider_npis: nil, supervising_provider_names: nil, exclude_charges_linked_to_claims: nil, patient_external_id_ranked_sort: nil, status_ranked_sort: nil, charge_external_id_ranked_sort: nil, date_of_service_min_ranked_sort: nil, date_of_service_max_ranked_sort: nil, claim_ids_ranked_sort: nil, claim_creation_ids_ranked_sort: nil, billing_provider_npis_ranked_sort: nil, service_facility_name_ranked_sort: nil, primary_payer_ids_ranked_sort: nil, rendering_provider_npis_ranked_sort: nil, rendering_provider_names_ranked_sort: nil, supervising_provider_npis_ranked_sort: nil, supervising_provider_names_ranked_sort: nil, request_options: nil) ⇒ CandidApiClient::ChargeCapture::V1::Types::ChargeCapturePage

Examples:

api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
api.charge_capture.v_1.get_all

Parameters:

  • limit (Integer) (defaults to: nil)

    Maximum number of entities per page, defaults to 100.

  • sort (CandidApiClient::ChargeCapture::V1::Types::ChargeCaptureSortField) (defaults to: nil)

    Defaults to created_at

  • sort_direction (CandidApiClient::Commons::Types::SortDirection) (defaults to: nil)

    Sort direction. Defaults to descending order if not provided.

  • page_token (String) (defaults to: nil)
  • patient_external_id (String) (defaults to: nil)

    The patient ID from the external EMR platform for the patient

  • status (CandidApiClient::ChargeCapture::V1::Types::ChargeCaptureStatus) (defaults to: nil)

    the status of the charge captures

  • charge_external_id (String) (defaults to: nil)

    A client-specified unique ID to associate with this encounter; for example, your internal encounter ID or a Dr. Chrono encounter ID. This field should not contain PHI.

  • date_of_service_min (Date) (defaults to: nil)

    Date formatted as YYYY-MM-DD; eg: 2019-08-24. This date must be the local date in the timezone where the service occurred.

  • date_of_service_max (Date) (defaults to: nil)

    Date formatted as YYYY-MM-DD; eg: 2019-08-24. This date must be the local date in the timezone where the service occurred.

  • claim_ids (String) (defaults to: nil)

    A list of claim IDs to filter by. This will return all charge captures that have a resulting claim with one of the IDs in this list.

  • claim_creation_ids (String) (defaults to: nil)

    A list of Claim Creation IDs to filter by.

  • billing_provider_npis (String) (defaults to: nil)

    A list of billing provider NPIs to filter by. This will return all charge captures with one of the NPIs in this list.

  • service_facility_name (String) (defaults to: nil)

    A string to filter by. This will return all charge captures with this service facility name.

  • primary_payer_ids (String) (defaults to: nil)

    A list of primary payer IDs to filter by. This will return all charge captures with one of the primary payer IDs in this list.

  • rendering_provider_npis (String) (defaults to: nil)

    A list of rendering provider NPIs to filter by. This will return all charge captures with one of the NPIs in this list.

  • rendering_provider_names (String) (defaults to: nil)

    A list of rendering provider names to filter by. This will return all charge captures with one of the names in this list.

  • supervising_provider_npis (String) (defaults to: nil)

    A list of supervising provider NPIs to filter by. This will return all charge captures with one of the NPIs in this list.

  • supervising_provider_names (String) (defaults to: nil)

    A list of supervising provider names to filter by. This will return all charge captures with one of the names in this list.

  • exclude_charges_linked_to_claims (Boolean) (defaults to: nil)

    Whether to exclude charge captures which are part of a claim creation.

  • patient_external_id_ranked_sort (String) (defaults to: nil)

    The patient ID from the external EMR platform for the patient

  • status_ranked_sort (CandidApiClient::ChargeCapture::V1::Types::ChargeCaptureStatus) (defaults to: nil)

    The charge capture status to show first

  • charge_external_id_ranked_sort (String) (defaults to: nil)

    A client-specified unique ID to associate with this encounter; for example, your internal encounter ID or a Dr. Chrono encounter ID. This field should not contain PHI.

  • date_of_service_min_ranked_sort (Date) (defaults to: nil)

    Date formatted as YYYY-MM-DD; eg: 2019-08-24. This date must be the local date in the timezone where the service occurred.

  • date_of_service_max_ranked_sort (Date) (defaults to: nil)

    Date formatted as YYYY-MM-DD; eg: 2019-08-24. This date must be the local date in the timezone where the service occurred.

  • claim_ids_ranked_sort (String) (defaults to: nil)

    A list of claim IDs to show first. This will return all charge captures that have a resulting claim with one of the IDs in this list.

  • claim_creation_ids_ranked_sort (String) (defaults to: nil)

    A list of Claim Creation IDs to show first.

  • billing_provider_npis_ranked_sort (String) (defaults to: nil)

    A list of billing provider NPIs to show first. This will return all charge captures with one of the NPIs in this list.

  • service_facility_name_ranked_sort (String) (defaults to: nil)

    A string to show first. This will return all charge captures with this service facility name.

  • primary_payer_ids_ranked_sort (String) (defaults to: nil)

    A list of primary payer IDs to show first. This will return all charge captures with one of the primary payer IDs in this list.

  • rendering_provider_npis_ranked_sort (String) (defaults to: nil)

    A list of rendering provider NPIs to show first. This will return all charge captures with one of the NPIs in this list.

  • rendering_provider_names_ranked_sort (String) (defaults to: nil)

    A list of rendering provider names to show first. This will return all charge captures with one of the names in this list.

  • supervising_provider_npis_ranked_sort (String) (defaults to: nil)

    A list of supervising provider NPIs to show first. This will return all charge captures with one of the NPIs in this list.

  • supervising_provider_names_ranked_sort (String) (defaults to: nil)

    A list of supervising provider names to show first. This will return all charge captures with one of the names in this list.

  • request_options (CandidApiClient::RequestOptions) (defaults to: nil)

Returns:



1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
# File 'lib/candidhealth/charge_capture/v_1/client.rb', line 1461

def get_all(limit: nil, sort: nil, sort_direction: nil, page_token: nil, patient_external_id: nil, status: nil,
            charge_external_id: nil, date_of_service_min: nil, date_of_service_max: nil, claim_ids: nil, claim_creation_ids: nil, billing_provider_npis: nil, service_facility_name: nil, primary_payer_ids: nil, rendering_provider_npis: nil, rendering_provider_names: nil, supervising_provider_npis: nil, supervising_provider_names: nil, exclude_charges_linked_to_claims: nil, patient_external_id_ranked_sort: nil, status_ranked_sort: nil, charge_external_id_ranked_sort: nil, date_of_service_min_ranked_sort: nil, date_of_service_max_ranked_sort: nil, claim_ids_ranked_sort: nil, claim_creation_ids_ranked_sort: nil, billing_provider_npis_ranked_sort: nil, service_facility_name_ranked_sort: nil, primary_payer_ids_ranked_sort: nil, rendering_provider_npis_ranked_sort: nil, rendering_provider_names_ranked_sort: nil, supervising_provider_npis_ranked_sort: nil, supervising_provider_names_ranked_sort: nil, request_options: nil)
  Async do
    response = @request_client.conn.get do |req|
      req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
      req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
      req.headers = {
    **(req.headers || {}),
    **@request_client.get_headers,
    **(request_options&.additional_headers || {})
      }.compact
      req.params = {
        **(request_options&.additional_query_parameters || {}),
        "limit": limit,
        "sort": sort,
        "sort_direction": sort_direction,
        "page_token": page_token,
        "patient_external_id": patient_external_id,
        "status": status,
        "charge_external_id": charge_external_id,
        "date_of_service_min": date_of_service_min,
        "date_of_service_max": date_of_service_max,
        "claim_ids": claim_ids,
        "claim_creation_ids": claim_creation_ids,
        "billing_provider_npis": billing_provider_npis,
        "service_facility_name": service_facility_name,
        "primary_payer_ids": primary_payer_ids,
        "rendering_provider_npis": rendering_provider_npis,
        "rendering_provider_names": rendering_provider_names,
        "supervising_provider_npis": supervising_provider_npis,
        "supervising_provider_names": supervising_provider_names,
        "exclude_charges_linked_to_claims": exclude_charges_linked_to_claims,
        "patient_external_id_ranked_sort": patient_external_id_ranked_sort,
        "status_ranked_sort": status_ranked_sort,
        "charge_external_id_ranked_sort": charge_external_id_ranked_sort,
        "date_of_service_min_ranked_sort": date_of_service_min_ranked_sort,
        "date_of_service_max_ranked_sort": date_of_service_max_ranked_sort,
        "claim_ids_ranked_sort": claim_ids_ranked_sort,
        "claim_creation_ids_ranked_sort": claim_creation_ids_ranked_sort,
        "billing_provider_npis_ranked_sort": billing_provider_npis_ranked_sort,
        "service_facility_name_ranked_sort": service_facility_name_ranked_sort,
        "primary_payer_ids_ranked_sort": primary_payer_ids_ranked_sort,
        "rendering_provider_npis_ranked_sort": rendering_provider_npis_ranked_sort,
        "rendering_provider_names_ranked_sort": rendering_provider_names_ranked_sort,
        "supervising_provider_npis_ranked_sort": supervising_provider_npis_ranked_sort,
        "supervising_provider_names_ranked_sort": supervising_provider_names_ranked_sort
      }.compact
      req.url "#{@request_client.get_url(environment: CandidApi,
                                         request_options: request_options)}/api/charge_captures/v1"
    end
    CandidApiClient::ChargeCapture::V1::Types::ChargeCapturePage.from_json(json_object: response.body)
  end
end

#update(charge_capture_id:, data: nil, charge_external_id: nil, ehr_source_url: nil, patient_external_id: nil, status: nil, request_options: nil) ⇒ CandidApiClient::ChargeCapture::V1::Types::ChargeCapture

Examples:

api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
api.charge_capture.v_1.update(charge_capture_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32")

Parameters:

  • charge_capture_id (String)
  • data (Hash) (defaults to: nil)

    Request of type CandidApiClient::ChargeCapture::V1::Types::ChargeCaptureData, as a Hash

    • :diagnoses (Array<CandidApiClient::Diagnoses::Types::DiagnosisCreate>)

    • :interventions (Array<CandidApiClient::Encounters::V4::Types::Intervention>)

    • :external_claim_submission (Hash)

      • :claim_created_at (DateTime)

      • :patient_control_number (String)

      • :submission_records (Array<CandidApiClient::ClaimSubmission::V1::Types::ClaimSubmissionRecordCreate>)

    • :service_lines (Array<CandidApiClient::ServiceLines::V2::Types::ServiceLineCreate>)

    • :patient_histories (Array<CandidApiClient::Encounters::V4::Types::PatientHistoryCategory>)

    • :billing_notes (Array<CandidApiClient::BillingNotes::V2::Types::BillingNoteBase>)

    • :patient (Hash)

      • :first_name (String)

      • :last_name (String)

      • :gender (CandidApiClient::Individual::Types::Gender)

      • :external_id (String)

      • :date_of_birth (Date)

      • :address (Hash)

        • :zip_plus_four_code (String)

        • :address_1 (String)

        • :address_2 (String)

        • :city (String)

        • :state (CandidApiClient::Commons::Types::State)

        • :zip_code (String)

      • :phone_numbers (Array<CandidApiClient::Commons::Types::PhoneNumber>)

      • :phone_consent (Boolean)

      • :email (String)

      • :email_consent (Boolean)

      • :non_insurance_payers (Array<String>)

      • :non_insurance_payers_info (Array<CandidApiClient::Individual::Types::PatientNonInsurancePayerInfoCreate>)

    • :service_facility (Hash)

      • :organization_name (String)

      • :npi (String)

      • :address (Hash)

        • :zip_plus_four_code (String)

        • :address_1 (String)

        • :address_2 (String)

        • :city (String)

        • :state (CandidApiClient::Commons::Types::State)

        • :zip_code (String)

      • :secondary_identification (String)

    • :rendering_provider (Hash)

      • :npi (String)

      • :taxonomy_code (String)

      • :address (Hash)

        • :zip_plus_four_code (String)

        • :address_1 (String)

        • :address_2 (String)

        • :city (String)

        • :state (CandidApiClient::Commons::Types::State)

        • :zip_code (String)

      • :first_name (String)

      • :last_name (String)

      • :organization_name (String)

    • :initial_referring_provider (Hash)

      • :npi (String)

      • :taxonomy_code (String)

      • :address (Hash)

        • :zip_plus_four_code (String)

        • :address_1 (String)

        • :address_2 (String)

        • :city (String)

        • :state (CandidApiClient::Commons::Types::State)

        • :zip_code (String)

      • :qualifier (CandidApiClient::Commons::Types::QualifierCode)

      • :first_name (String)

      • :last_name (String)

      • :organization_name (String)

    • :referring_provider (Hash)

      • :npi (String)

      • :taxonomy_code (String)

      • :address (Hash)

        • :zip_plus_four_code (String)

        • :address_1 (String)

        • :address_2 (String)

        • :city (String)

        • :state (CandidApiClient::Commons::Types::State)

        • :zip_code (String)

      • :first_name (String)

      • :last_name (String)

      • :organization_name (String)

    • :supervising_provider (Hash)

      • :npi (String)

      • :taxonomy_code (String)

      • :address (Hash)

        • :zip_plus_four_code (String)

        • :address_1 (String)

        • :address_2 (String)

        • :city (String)

        • :state (CandidApiClient::Commons::Types::State)

        • :zip_code (String)

      • :first_name (String)

      • :last_name (String)

      • :organization_name (String)

    • :billing_provider (Hash)

      • :address (Hash)

        • :zip_plus_four_code (String)

        • :address_1 (String)

        • :address_2 (String)

        • :city (String)

        • :state (CandidApiClient::Commons::Types::State)

        • :zip_code (String)

      • :tax_id (String)

      • :npi (String)

      • :taxonomy_code (String)

      • :provider_commercial_license_type (CandidApiClient::Commons::Types::BillingProviderCommercialLicenseType)

      • :first_name (String)

      • :last_name (String)

      • :organization_name (String)

    • :pay_to_address (Hash)

      • :zip_plus_four_code (String)

      • :address_1 (String)

      • :address_2 (String)

      • :city (String)

      • :state (CandidApiClient::Commons::Types::State)

      • :zip_code (String)

    • :benefits_assigned_to_provider (Boolean)

    • :prior_authorization_number (String)

    • :external_id (String)

    • :date_of_service (Date)

    • :tag_ids (Array<String>)

    • :clinical_notes (Array<CandidApiClient::Encounters::V4::Types::ClinicalNoteCategoryCreate>)

    • :billable_status (CandidApiClient::Encounters::V4::Types::BillableStatusType)

    • :responsible_party (CandidApiClient::Encounters::V4::Types::ResponsiblePartyType)

    • :provider_accepts_assignment (Boolean)

    • :synchronicity (CandidApiClient::Encounters::V4::Types::SynchronicityType)

    • :place_of_service_code (CandidApiClient::Commons::Types::FacilityTypeCode)

    • :appointment_type (String)

    • :end_date_of_service (Date)

    • :subscriber_primary (Hash)

      • :insurance_card (Hash)

        • :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 (CandidApiClient::Commons::Types::EmrPayerCrosswalk)

        • :group_number (String)

        • :plan_name (String)

        • :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)

        • :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)

        • :payer_plan_group_id (String)

      • :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)

      • :date_of_birth (Date)

      • :address (Hash)

        • :zip_plus_four_code (String)

        • :address_1 (String)

        • :address_2 (String)

        • :city (String)

        • :state (CandidApiClient::Commons::Types::State)

        • :zip_code (String)

      • :first_name (String)

      • :last_name (String)

      • :gender (CandidApiClient::Individual::Types::Gender)

    • :subscriber_secondary (Hash)

      • :insurance_card (Hash)

        • :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 (CandidApiClient::Commons::Types::EmrPayerCrosswalk)

        • :group_number (String)

        • :plan_name (String)

        • :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)

        • :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)

        • :payer_plan_group_id (String)

      • :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)

      • :date_of_birth (Date)

      • :address (Hash)

        • :zip_plus_four_code (String)

        • :address_1 (String)

        • :address_2 (String)

        • :city (String)

        • :state (CandidApiClient::Commons::Types::State)

        • :zip_code (String)

      • :first_name (String)

      • :last_name (String)

      • :gender (CandidApiClient::Individual::Types::Gender)

    • :subscriber_tertiary (Hash)

      • :insurance_card (Hash)

        • :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 (CandidApiClient::Commons::Types::EmrPayerCrosswalk)

        • :group_number (String)

        • :plan_name (String)

        • :plan_type (CandidApiClient::Commons::Types::SourceOfPaymentCode)

        • :insurance_type (CandidApiClient::Commons::Types::InsuranceTypeCode)

        • :payer_plan_group_id (String)

      • :patient_relationship_to_subscriber_code (CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll)

      • :date_of_birth (Date)

      • :address (Hash)

        • :zip_plus_four_code (String)

        • :address_1 (String)

        • :address_2 (String)

        • :city (String)

        • :state (CandidApiClient::Commons::Types::State)

        • :zip_code (String)

      • :first_name (String)

      • :last_name (String)

      • :gender (CandidApiClient::Individual::Types::Gender)

    • :additional_information (String)

    • :service_authorization_exception_code (CandidApiClient::Encounters::V4::Types::ServiceAuthorizationExceptionCode)

    • :admission_date (Date)

    • :discharge_date (Date)

    • :onset_of_current_illness_or_symptom_date (Date)

    • :last_menstrual_period_date (Date)

    • :delay_reason_code (CandidApiClient::Commons::Types::DelayReasonCode)

    • :patient_authorized_release (Boolean)

    • :schema_instances (Array<CandidApiClient::CustomSchemas::V1::Types::SchemaInstance>)

    • :vitals (Hash)

      • :height_in (Integer)

      • :weight_lbs (Integer)

      • :blood_pressure_systolic_mmhg (Integer)

      • :blood_pressure_diastolic_mmhg (Integer)

      • :body_temperature_f (Float)

      • :hemoglobin_gdl (Float)

      • :hematocrit_pct (Float)

    • :existing_medications (Array<CandidApiClient::Encounters::V4::Types::Medication>)

    • :guarantor (Hash)

      • :first_name (String)

      • :last_name (String)

      • :external_id (String)

      • :date_of_birth (Date)

      • :address (Hash)

        • :zip_plus_four_code (String)

        • :address_1 (String)

        • :address_2 (String)

        • :city (String)

        • :state (CandidApiClient::Commons::Types::State)

        • :zip_code (String)

      • :phone_numbers (Array<CandidApiClient::Commons::Types::PhoneNumber>)

      • :phone_consent (Boolean)

      • :email (String)

      • :email_consent (Boolean)

    • :referral_number (String)

    • :epsdt_referral (Hash)

      • :condition_indicator_1 (CandidApiClient::Commons::Types::EpsdtReferralConditionIndicatorCode)

      • :condition_indicator_2 (CandidApiClient::Commons::Types::EpsdtReferralConditionIndicatorCode)

      • :condition_indicator_3 (CandidApiClient::Commons::Types::EpsdtReferralConditionIndicatorCode)

    • :claim_supplemental_information (Array<CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation>)

    • :secondary_payer_carrier_code (String)

  • charge_external_id (String) (defaults to: nil)

    A client-specified unique ID to associate with this encounter; for example, your internal encounter ID or a Dr. Chrono encounter ID. This field should not contain PHI.

  • ehr_source_url (String) (defaults to: nil)

    External URL reference that links to Charge Capture details within the external system (e.g. the EHR visit page). Send full URL format for the external link (e.g. emr_charge_capture_url.com/123).

  • patient_external_id (String) (defaults to: nil)

    The patient ID from the external EMR platform for the patient

  • status (CandidApiClient::ChargeCapture::V1::Types::ChargeCaptureStatus) (defaults to: nil)

    the status of the charge capture

  • request_options (CandidApiClient::RequestOptions) (defaults to: nil)

Returns:



1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
# File 'lib/candidhealth/charge_capture/v_1/client.rb', line 1350

def update(charge_capture_id:, data: nil, charge_external_id: nil, ehr_source_url: nil,
           patient_external_id: nil, status: nil, request_options: nil)
  Async do
    response = @request_client.conn.patch do |req|
      req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
      req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
      req.headers = {
    **(req.headers || {}),
    **@request_client.get_headers,
    **(request_options&.additional_headers || {})
      }.compact
      req.body = {
        **(request_options&.additional_body_parameters || {}),
        data: data,
        charge_external_id: charge_external_id,
        ehr_source_url: ehr_source_url,
        patient_external_id: patient_external_id,
        status: status
      }.compact
      req.url "#{@request_client.get_url(environment: CandidApi,
                                         request_options: request_options)}/api/charge_captures/v1/#{charge_capture_id}"
    end
    CandidApiClient::ChargeCapture::V1::Types::ChargeCapture.from_json(json_object: response.body)
  end
end

#update_post_billed_changes(charge_capture_change_ids:, resolved:, request_options: nil) ⇒ Array<CandidApiClient::ChargeCapture::V1::Types::ChargeCapturePostBilledChange>

Examples:

api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
api.charge_capture.v_1.update_post_billed_changes(charge_capture_change_ids: ["d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"], resolved: true)

Parameters:

  • charge_capture_change_ids (Array<String>)

    A list of UUIDs corresponding to ChargeCapturePostBilledChanges. All of the charges sent will be marked as resolved

  • resolved (Boolean)

    Whether the change has been resolved. If true, the change will be marked as resolved. If false, the change will be marked as unresolved.

  • request_options (CandidApiClient::RequestOptions) (defaults to: nil)

Returns:



1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
# File 'lib/candidhealth/charge_capture/v_1/client.rb', line 1525

def update_post_billed_changes(charge_capture_change_ids:, resolved:, request_options: nil)
  Async do
    response = @request_client.conn.patch do |req|
      req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
      req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
      req.headers = {
    **(req.headers || {}),
    **@request_client.get_headers,
    **(request_options&.additional_headers || {})
      }.compact
      req.body = {
        **(request_options&.additional_body_parameters || {}),
        charge_capture_change_ids: charge_capture_change_ids,
        resolved: resolved
      }.compact
      req.url "#{@request_client.get_url(environment: CandidApi,
                                         request_options: request_options)}/api/charge_captures/v1/changes"
    end
    parsed_json = JSON.parse(response.body)
    parsed_json&.map do |item|
      item = item.to_json
      CandidApiClient::ChargeCapture::V1::Types::ChargeCapturePostBilledChange.from_json(json_object: item)
    end
  end
end