candidhealth 0.39.10 → 0.40.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/candidhealth/charge_capture/v_1/client.rb +4 -0
- data/lib/candidhealth/charge_capture/v_1/types/charge_capture_data.rb +16 -2
- data/lib/candidhealth/clinical_trials/v_1/types/clinical_trial.rb +109 -0
- data/lib/candidhealth/clinical_trials/v_1/types/clinical_trial_phase.rb +15 -0
- data/lib/candidhealth/clinical_trials/v_1/types/mutable_clinical_trial.rb +84 -0
- data/lib/candidhealth/commons/types/procedure_modifier.rb +4 -0
- data/lib/candidhealth/encounters/v_4/client.rb +37 -10
- data/lib/candidhealth/encounters/v_4/types/claim_supplemental_information.rb +86 -0
- data/lib/candidhealth/encounters/v_4/types/encounter.rb +23 -1
- data/lib/candidhealth/encounters/v_4/types/encounter_optional.rb +16 -2
- data/lib/candidhealth/encounters/v_4/types/report_transmission_code.rb +14 -0
- data/lib/candidhealth/encounters/v_4/types/report_type_code.rb +73 -0
- data/lib/candidhealth/exports/v_3/client.rb +8 -0
- data/lib/candidhealth/individual/types/patient_clinical_trial_info.rb +80 -0
- data/lib/candidhealth/individual/types/patient_clinical_trial_info_create.rb +73 -0
- data/lib/candidhealth/individual/types/patient_non_insurance_payer_info.rb +17 -2
- data/lib/candidhealth/individual/types/patient_non_insurance_payer_info_create.rb +18 -2
- data/lib/candidhealth/non_insurance_payers/v_1/client.rb +4 -2
- data/lib/candidhealth/non_insurance_payers/v_1/types/create_non_insurance_payer_request.rb +15 -2
- data/lib/candidhealth/non_insurance_payers/v_1/types/non_insurance_payer.rb +15 -3
- data/lib/candidhealth/organization_providers/v_2/types/license_type.rb +3 -0
- data/lib/candidhealth/pre_encounter/appointments/v_1/client.rb +8 -4
- data/lib/candidhealth/pre_encounter/common/types/canonical_clinical_trial_association.rb +86 -0
- data/lib/candidhealth/pre_encounter/common/types/canonical_non_insurance_payer_association.rb +18 -2
- data/lib/candidhealth/pre_encounter/common/types/human_name.rb +15 -2
- data/lib/candidhealth/pre_encounter/coverages/v_1/client.rb +8 -4
- data/lib/candidhealth/pre_encounter/images/client.rb +32 -0
- data/lib/candidhealth/pre_encounter/images/v_1/client.rb +359 -0
- data/lib/candidhealth/pre_encounter/images/v_1/types/coverage_association.rb +74 -0
- data/lib/candidhealth/pre_encounter/images/v_1/types/coverage_image_side.rb +16 -0
- data/lib/candidhealth/pre_encounter/images/v_1/types/image.rb +188 -0
- data/lib/candidhealth/pre_encounter/images/v_1/types/image_status.rb +17 -0
- data/lib/candidhealth/pre_encounter/images/v_1/types/mutable_image.rb +125 -0
- data/lib/candidhealth/pre_encounter/images/v_1/types/patient_association.rb +75 -0
- data/lib/candidhealth/pre_encounter/patients/v_1/client.rb +89 -6
- data/lib/candidhealth/pre_encounter/patients/v_1/types/authorization.rb +11 -1
- data/lib/candidhealth/service_lines/v_2/types/service_line.rb +6 -4
- data/lib/candidhealth/service_lines/v_2/types/service_line_create.rb +6 -4
- data/lib/candidhealth/service_lines/v_2/types/service_line_create_standalone.rb +6 -4
- data/lib/candidhealth/service_lines/v_2/types/service_line_update.rb +10 -8
- data/lib/candidhealth/service_lines/v_2/types/test_result_type.rb +1 -0
- data/lib/candidhealth/write_offs/v_1/client.rb +98 -0
- data/lib/candidhealth/write_offs/v_1/types/non_insurance_payer_write_off.rb +143 -0
- data/lib/candidhealth/write_offs/v_1/types/non_insurance_payer_write_off_create.rb +113 -0
- data/lib/candidhealth/write_offs/v_1/types/write_off.rb +13 -0
- data/lib/candidhealth/write_offs/v_1/types/write_off_create.rb +13 -0
- data/lib/candidhealth/x_12/v_1/types/rarc.rb +114 -0
- data/lib/requests.rb +2 -2
- data/lib/types_export.rb +17 -0
- metadata +21 -2
@@ -20,6 +20,7 @@ require_relative "encounter_owner_of_next_action_type"
|
|
20
20
|
require_relative "encounter_submission_origin_type"
|
21
21
|
require_relative "../../../custom_schemas/v_1/types/schema_instance"
|
22
22
|
require_relative "epsdt_referral"
|
23
|
+
require_relative "claim_supplemental_information"
|
23
24
|
require_relative "medication"
|
24
25
|
require_relative "vitals"
|
25
26
|
require_relative "intervention"
|
@@ -147,8 +148,13 @@ module CandidApiClient
|
|
147
148
|
# @return [CandidApiClient::Encounters::V4::Types::EpsdtReferral] Refers Box 24H on the CMS1500 form and Loop 2300 CRC - EPSDT Referral on the
|
148
149
|
# 837P form
|
149
150
|
attr_reader :epsdt_referral
|
151
|
+
# @return [Array<CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation>] Refers to Loop 2300 - Segment PWK on the 837P form. No more than 10 entries are
|
152
|
+
# permitted.
|
153
|
+
attr_reader :claim_supplemental_information
|
150
154
|
# @return [DateTime] The date and time the encounter was last submitted to a payer.
|
151
155
|
attr_reader :last_submitted_at
|
156
|
+
# @return [DateTime] The date and time the encounter was created.
|
157
|
+
attr_reader :created_at
|
152
158
|
# @return [String] A client-specified unique ID to associate with this encounter;
|
153
159
|
# for example, your internal encounter ID or a Dr. Chrono encounter ID.
|
154
160
|
# This field should not contain PHI.
|
@@ -328,7 +334,10 @@ module CandidApiClient
|
|
328
334
|
# @param referral_number [String] Refers to REF\*9F on the 837p. Value cannot be greater than 50 characters.
|
329
335
|
# @param epsdt_referral [CandidApiClient::Encounters::V4::Types::EpsdtReferral] Refers Box 24H on the CMS1500 form and Loop 2300 CRC - EPSDT Referral on the
|
330
336
|
# 837P form
|
337
|
+
# @param claim_supplemental_information [Array<CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation>] Refers to Loop 2300 - Segment PWK on the 837P form. No more than 10 entries are
|
338
|
+
# permitted.
|
331
339
|
# @param last_submitted_at [DateTime] The date and time the encounter was last submitted to a payer.
|
340
|
+
# @param created_at [DateTime] The date and time the encounter was created.
|
332
341
|
# @param external_id [String] A client-specified unique ID to associate with this encounter;
|
333
342
|
# for example, your internal encounter ID or a Dr. Chrono encounter ID.
|
334
343
|
# This field should not contain PHI.
|
@@ -404,7 +413,7 @@ module CandidApiClient
|
|
404
413
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
405
414
|
# @return [CandidApiClient::Encounters::V4::Types::Encounter]
|
406
415
|
def initialize(encounter_id:, claims:, patient:, billing_provider:, rendering_provider:, service_facility:,
|
407
|
-
responsible_party:, url:, diagnoses:, clinical_notes:, patient_histories:, patient_payments:, tags:, owner_of_next_action:, submission_origin:, schema_instances:, external_id:, patient_authorized_release:, benefits_assigned_to_provider:, provider_accepts_assignment:, billable_status:, patient_control_number: OMIT, guarantor: OMIT, referring_provider: OMIT, initial_referring_provider: OMIT, supervising_provider: OMIT, subscriber_primary: OMIT, subscriber_secondary: OMIT, prior_authorization_number: OMIT, billing_notes: OMIT, place_of_service_code: OMIT, place_of_service_code_as_submitted: OMIT, coding_attribution: OMIT, work_queue_id: OMIT, work_queue_membership_activated_at: OMIT, referral_number: OMIT, epsdt_referral: OMIT, last_submitted_at: OMIT, date_of_service: OMIT, end_date_of_service: OMIT, appointment_type: OMIT, existing_medications: OMIT, vitals: OMIT, interventions: OMIT, pay_to_address: OMIT, synchronicity: OMIT, additional_information: OMIT, service_authorization_exception_code: OMIT, admission_date: OMIT, discharge_date: OMIT, onset_of_current_illness_or_symptom_date: OMIT, last_menstrual_period_date: OMIT, delay_reason_code: OMIT, additional_properties: nil)
|
416
|
+
responsible_party:, url:, diagnoses:, clinical_notes:, patient_histories:, patient_payments:, tags:, owner_of_next_action:, submission_origin:, schema_instances:, created_at:, external_id:, patient_authorized_release:, benefits_assigned_to_provider:, provider_accepts_assignment:, billable_status:, patient_control_number: OMIT, guarantor: OMIT, referring_provider: OMIT, initial_referring_provider: OMIT, supervising_provider: OMIT, subscriber_primary: OMIT, subscriber_secondary: OMIT, prior_authorization_number: OMIT, billing_notes: OMIT, place_of_service_code: OMIT, place_of_service_code_as_submitted: OMIT, coding_attribution: OMIT, work_queue_id: OMIT, work_queue_membership_activated_at: OMIT, referral_number: OMIT, epsdt_referral: OMIT, claim_supplemental_information: OMIT, last_submitted_at: OMIT, date_of_service: OMIT, end_date_of_service: OMIT, appointment_type: OMIT, existing_medications: OMIT, vitals: OMIT, interventions: OMIT, pay_to_address: OMIT, synchronicity: OMIT, additional_information: OMIT, service_authorization_exception_code: OMIT, admission_date: OMIT, discharge_date: OMIT, onset_of_current_illness_or_symptom_date: OMIT, last_menstrual_period_date: OMIT, delay_reason_code: OMIT, additional_properties: nil)
|
408
417
|
@patient_control_number = patient_control_number if patient_control_number != OMIT
|
409
418
|
@encounter_id = encounter_id
|
410
419
|
@claims = claims
|
@@ -441,7 +450,9 @@ module CandidApiClient
|
|
441
450
|
@schema_instances = schema_instances
|
442
451
|
@referral_number = referral_number if referral_number != OMIT
|
443
452
|
@epsdt_referral = epsdt_referral if epsdt_referral != OMIT
|
453
|
+
@claim_supplemental_information = claim_supplemental_information if claim_supplemental_information != OMIT
|
444
454
|
@last_submitted_at = last_submitted_at if last_submitted_at != OMIT
|
455
|
+
@created_at = created_at
|
445
456
|
@external_id = external_id
|
446
457
|
@date_of_service = date_of_service if date_of_service != OMIT
|
447
458
|
@end_date_of_service = end_date_of_service if end_date_of_service != OMIT
|
@@ -500,7 +511,9 @@ module CandidApiClient
|
|
500
511
|
"schema_instances": schema_instances,
|
501
512
|
"referral_number": referral_number,
|
502
513
|
"epsdt_referral": epsdt_referral,
|
514
|
+
"claim_supplemental_information": claim_supplemental_information,
|
503
515
|
"last_submitted_at": last_submitted_at,
|
516
|
+
"created_at": created_at,
|
504
517
|
"external_id": external_id,
|
505
518
|
"date_of_service": date_of_service,
|
506
519
|
"end_date_of_service": end_date_of_service,
|
@@ -646,9 +659,14 @@ module CandidApiClient
|
|
646
659
|
epsdt_referral = parsed_json["epsdt_referral"].to_json
|
647
660
|
epsdt_referral = CandidApiClient::Encounters::V4::Types::EpsdtReferral.from_json(json_object: epsdt_referral)
|
648
661
|
end
|
662
|
+
claim_supplemental_information = parsed_json["claim_supplemental_information"]&.map do |item|
|
663
|
+
item = item.to_json
|
664
|
+
CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation.from_json(json_object: item)
|
665
|
+
end
|
649
666
|
last_submitted_at = unless parsed_json["last_submitted_at"].nil?
|
650
667
|
DateTime.parse(parsed_json["last_submitted_at"])
|
651
668
|
end
|
669
|
+
created_at = (DateTime.parse(parsed_json["created_at"]) unless parsed_json["created_at"].nil?)
|
652
670
|
external_id = struct["external_id"]
|
653
671
|
date_of_service = (Date.parse(parsed_json["date_of_service"]) unless parsed_json["date_of_service"].nil?)
|
654
672
|
end_date_of_service = unless parsed_json["end_date_of_service"].nil?
|
@@ -724,7 +742,9 @@ module CandidApiClient
|
|
724
742
|
schema_instances: schema_instances,
|
725
743
|
referral_number: referral_number,
|
726
744
|
epsdt_referral: epsdt_referral,
|
745
|
+
claim_supplemental_information: claim_supplemental_information,
|
727
746
|
last_submitted_at: last_submitted_at,
|
747
|
+
created_at: created_at,
|
728
748
|
external_id: external_id,
|
729
749
|
date_of_service: date_of_service,
|
730
750
|
end_date_of_service: end_date_of_service,
|
@@ -795,7 +815,9 @@ module CandidApiClient
|
|
795
815
|
obj.schema_instances.is_a?(Array) != false || raise("Passed value for field obj.schema_instances is not the expected type, validation failed.")
|
796
816
|
obj.referral_number&.is_a?(String) != false || raise("Passed value for field obj.referral_number is not the expected type, validation failed.")
|
797
817
|
obj.epsdt_referral.nil? || CandidApiClient::Encounters::V4::Types::EpsdtReferral.validate_raw(obj: obj.epsdt_referral)
|
818
|
+
obj.claim_supplemental_information&.is_a?(Array) != false || raise("Passed value for field obj.claim_supplemental_information is not the expected type, validation failed.")
|
798
819
|
obj.last_submitted_at&.is_a?(DateTime) != false || raise("Passed value for field obj.last_submitted_at is not the expected type, validation failed.")
|
820
|
+
obj.created_at.is_a?(DateTime) != false || raise("Passed value for field obj.created_at is not the expected type, validation failed.")
|
799
821
|
obj.external_id.is_a?(String) != false || raise("Passed value for field obj.external_id is not the expected type, validation failed.")
|
800
822
|
obj.date_of_service&.is_a?(Date) != false || raise("Passed value for field obj.date_of_service is not the expected type, validation failed.")
|
801
823
|
obj.end_date_of_service&.is_a?(Date) != false || raise("Passed value for field obj.end_date_of_service is not the expected type, validation failed.")
|
@@ -22,6 +22,7 @@ require_relative "../../../encounter_providers/v_2/types/supervising_provider_up
|
|
22
22
|
require_relative "../../../encounter_providers/v_2/types/referring_provider_update"
|
23
23
|
require_relative "../../../encounter_providers/v_2/types/initial_referring_provider_update"
|
24
24
|
require_relative "epsdt_referral"
|
25
|
+
require_relative "claim_supplemental_information"
|
25
26
|
require "ostruct"
|
26
27
|
require "json"
|
27
28
|
|
@@ -197,6 +198,9 @@ module CandidApiClient
|
|
197
198
|
# @return [CandidApiClient::Encounters::V4::Types::EpsdtReferral] Refers Box 24H on the CMS1500 form and Loop 2300 CRC - EPSDT Referral on the
|
198
199
|
# 837P form
|
199
200
|
attr_reader :epsdt_referral
|
201
|
+
# @return [Array<CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation>] Refers to Loop 2300 - Segment PWK on the 837P form. No more than 10 entries are
|
202
|
+
# permitted.
|
203
|
+
attr_reader :claim_supplemental_information
|
200
204
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
201
205
|
attr_reader :additional_properties
|
202
206
|
# @return [Object]
|
@@ -335,10 +339,12 @@ module CandidApiClient
|
|
335
339
|
# @param referral_number [String] Refers to REF\*9F on the 837p. Value cannot be greater than 50 characters.
|
336
340
|
# @param epsdt_referral [CandidApiClient::Encounters::V4::Types::EpsdtReferral] Refers Box 24H on the CMS1500 form and Loop 2300 CRC - EPSDT Referral on the
|
337
341
|
# 837P form
|
342
|
+
# @param claim_supplemental_information [Array<CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation>] Refers to Loop 2300 - Segment PWK on the 837P form. No more than 10 entries are
|
343
|
+
# permitted.
|
338
344
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
339
345
|
# @return [CandidApiClient::Encounters::V4::Types::EncounterOptional]
|
340
346
|
def initialize(benefits_assigned_to_provider: OMIT, prior_authorization_number: OMIT, external_id: OMIT,
|
341
|
-
date_of_service: OMIT, tag_ids: OMIT, clinical_notes: OMIT, pay_to_address: OMIT, billable_status: OMIT, responsible_party: OMIT, provider_accepts_assignment: OMIT, synchronicity: OMIT, place_of_service_code: OMIT, appointment_type: OMIT, end_date_of_service: OMIT, subscriber_primary: OMIT, subscriber_secondary: OMIT, additional_information: OMIT, service_authorization_exception_code: OMIT, admission_date: OMIT, discharge_date: OMIT, onset_of_current_illness_or_symptom_date: OMIT, last_menstrual_period_date: OMIT, delay_reason_code: OMIT, patient: OMIT, patient_authorized_release: OMIT, schema_instances: OMIT, vitals: OMIT, existing_medications: OMIT, rendering_provider: OMIT, service_facility: OMIT, guarantor: OMIT, billing_provider: OMIT, supervising_provider: OMIT, referring_provider: OMIT, initial_referring_provider: OMIT, referral_number: OMIT, epsdt_referral: OMIT, additional_properties: nil)
|
347
|
+
date_of_service: OMIT, tag_ids: OMIT, clinical_notes: OMIT, pay_to_address: OMIT, billable_status: OMIT, responsible_party: OMIT, provider_accepts_assignment: OMIT, synchronicity: OMIT, place_of_service_code: OMIT, appointment_type: OMIT, end_date_of_service: OMIT, subscriber_primary: OMIT, subscriber_secondary: OMIT, additional_information: OMIT, service_authorization_exception_code: OMIT, admission_date: OMIT, discharge_date: OMIT, onset_of_current_illness_or_symptom_date: OMIT, last_menstrual_period_date: OMIT, delay_reason_code: OMIT, patient: OMIT, patient_authorized_release: OMIT, schema_instances: OMIT, vitals: OMIT, existing_medications: OMIT, rendering_provider: OMIT, service_facility: OMIT, guarantor: OMIT, billing_provider: OMIT, supervising_provider: OMIT, referring_provider: OMIT, initial_referring_provider: OMIT, referral_number: OMIT, epsdt_referral: OMIT, claim_supplemental_information: OMIT, additional_properties: nil)
|
342
348
|
@benefits_assigned_to_provider = benefits_assigned_to_provider if benefits_assigned_to_provider != OMIT
|
343
349
|
@prior_authorization_number = prior_authorization_number if prior_authorization_number != OMIT
|
344
350
|
@external_id = external_id if external_id != OMIT
|
@@ -380,6 +386,7 @@ module CandidApiClient
|
|
380
386
|
@initial_referring_provider = initial_referring_provider if initial_referring_provider != OMIT
|
381
387
|
@referral_number = referral_number if referral_number != OMIT
|
382
388
|
@epsdt_referral = epsdt_referral if epsdt_referral != OMIT
|
389
|
+
@claim_supplemental_information = claim_supplemental_information if claim_supplemental_information != OMIT
|
383
390
|
@additional_properties = additional_properties
|
384
391
|
@_field_set = {
|
385
392
|
"benefits_assigned_to_provider": benefits_assigned_to_provider,
|
@@ -418,7 +425,8 @@ module CandidApiClient
|
|
418
425
|
"referring_provider": referring_provider,
|
419
426
|
"initial_referring_provider": initial_referring_provider,
|
420
427
|
"referral_number": referral_number,
|
421
|
-
"epsdt_referral": epsdt_referral
|
428
|
+
"epsdt_referral": epsdt_referral,
|
429
|
+
"claim_supplemental_information": claim_supplemental_information
|
422
430
|
}.reject do |_k, v|
|
423
431
|
v == OMIT
|
424
432
|
end
|
@@ -548,6 +556,10 @@ module CandidApiClient
|
|
548
556
|
epsdt_referral = parsed_json["epsdt_referral"].to_json
|
549
557
|
epsdt_referral = CandidApiClient::Encounters::V4::Types::EpsdtReferral.from_json(json_object: epsdt_referral)
|
550
558
|
end
|
559
|
+
claim_supplemental_information = parsed_json["claim_supplemental_information"]&.map do |item|
|
560
|
+
item = item.to_json
|
561
|
+
CandidApiClient::Encounters::V4::Types::ClaimSupplementalInformation.from_json(json_object: item)
|
562
|
+
end
|
551
563
|
new(
|
552
564
|
benefits_assigned_to_provider: benefits_assigned_to_provider,
|
553
565
|
prior_authorization_number: prior_authorization_number,
|
@@ -586,6 +598,7 @@ module CandidApiClient
|
|
586
598
|
initial_referring_provider: initial_referring_provider,
|
587
599
|
referral_number: referral_number,
|
588
600
|
epsdt_referral: epsdt_referral,
|
601
|
+
claim_supplemental_information: claim_supplemental_information,
|
589
602
|
additional_properties: struct
|
590
603
|
)
|
591
604
|
end
|
@@ -641,6 +654,7 @@ module CandidApiClient
|
|
641
654
|
obj.initial_referring_provider.nil? || CandidApiClient::EncounterProviders::V2::Types::InitialReferringProviderUpdate.validate_raw(obj: obj.initial_referring_provider)
|
642
655
|
obj.referral_number&.is_a?(String) != false || raise("Passed value for field obj.referral_number is not the expected type, validation failed.")
|
643
656
|
obj.epsdt_referral.nil? || CandidApiClient::Encounters::V4::Types::EpsdtReferral.validate_raw(obj: obj.epsdt_referral)
|
657
|
+
obj.claim_supplemental_information&.is_a?(Array) != false || raise("Passed value for field obj.claim_supplemental_information is not the expected type, validation failed.")
|
644
658
|
end
|
645
659
|
end
|
646
660
|
end
|
@@ -0,0 +1,73 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module CandidApiClient
|
4
|
+
module Encounters
|
5
|
+
module V4
|
6
|
+
module Types
|
7
|
+
class ReportTypeCode
|
8
|
+
C_03 = "03"
|
9
|
+
C_04 = "04"
|
10
|
+
C_05 = "05"
|
11
|
+
C_06 = "06"
|
12
|
+
C_07 = "07"
|
13
|
+
C_08 = "08"
|
14
|
+
C_09 = "09"
|
15
|
+
C_10 = "10"
|
16
|
+
C_11 = "11"
|
17
|
+
C_13 = "13"
|
18
|
+
C_15 = "15"
|
19
|
+
C_21 = "21"
|
20
|
+
CA_3 = "A3"
|
21
|
+
CA_4 = "A4"
|
22
|
+
CAM = "AM"
|
23
|
+
CAS = "AS"
|
24
|
+
CB_2 = "B2"
|
25
|
+
CB_3 = "B3"
|
26
|
+
CB_4 = "B4"
|
27
|
+
CBR = "BR"
|
28
|
+
CBS = "BS"
|
29
|
+
CBT = "BT"
|
30
|
+
CCB = "CB"
|
31
|
+
CCK = "CK"
|
32
|
+
CCT = "CT"
|
33
|
+
CD_2 = "D2"
|
34
|
+
CDA = "DA"
|
35
|
+
CDB = "DB"
|
36
|
+
CDG = "DG"
|
37
|
+
CDJ = "DJ"
|
38
|
+
CDS = "DS"
|
39
|
+
CEB = "EB"
|
40
|
+
CHC = "HC"
|
41
|
+
CHR = "HR"
|
42
|
+
CI_5 = "I5"
|
43
|
+
CIR = "IR"
|
44
|
+
CLA = "LA"
|
45
|
+
CM_1 = "M1"
|
46
|
+
CMT = "MT"
|
47
|
+
CNN = "NN"
|
48
|
+
COB = "OB"
|
49
|
+
COC = "OC"
|
50
|
+
COD = "OD"
|
51
|
+
COE = "OE"
|
52
|
+
COX = "OX"
|
53
|
+
COZ = "OZ"
|
54
|
+
CP_4 = "P4"
|
55
|
+
CP_5 = "P5"
|
56
|
+
CPE = "PE"
|
57
|
+
CPN = "PN"
|
58
|
+
CPO = "PO"
|
59
|
+
CPQ = "PQ"
|
60
|
+
CPY = "PY"
|
61
|
+
CPZ = "PZ"
|
62
|
+
CRB = "RB"
|
63
|
+
CRR = "RR"
|
64
|
+
CRT = "RT"
|
65
|
+
CRX = "RX"
|
66
|
+
CSG = "SG"
|
67
|
+
CV_5 = "V5"
|
68
|
+
CXP = "XP"
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
72
|
+
end
|
73
|
+
end
|
@@ -40,6 +40,10 @@ module CandidApiClient
|
|
40
40
|
# up to 90 days in the past by default. Please email our [Support
|
41
41
|
# team](mailto:support@joincandidhealth.com) with any data requests
|
42
42
|
# outside of these stated guarantees.
|
43
|
+
# **New Customers:** This endpoint is not enabled by default for new Candid
|
44
|
+
# customers. To have this endpoint enabled for your organization,
|
45
|
+
# please email our [Support team](mailto:support@joincandidhealth.com) with the
|
46
|
+
# request.
|
43
47
|
#
|
44
48
|
# @param start_date [Date] Beginning date of claim versions returned in the export, ISO 8601 date e.g.
|
45
49
|
# 2019-08-24.
|
@@ -105,6 +109,10 @@ module CandidApiClient
|
|
105
109
|
# up to 90 days in the past by default. Please email our [Support
|
106
110
|
# team](mailto:support@joincandidhealth.com) with any data requests
|
107
111
|
# outside of these stated guarantees.
|
112
|
+
# **New Customers:** This endpoint is not enabled by default for new Candid
|
113
|
+
# customers. To have this endpoint enabled for your organization,
|
114
|
+
# please email our [Support team](mailto:support@joincandidhealth.com) with the
|
115
|
+
# request.
|
108
116
|
#
|
109
117
|
# @param start_date [Date] Beginning date of claim versions returned in the export, ISO 8601 date e.g.
|
110
118
|
# 2019-08-24.
|
@@ -0,0 +1,80 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "../../clinical_trials/v_1/types/clinical_trial"
|
4
|
+
require "ostruct"
|
5
|
+
require "json"
|
6
|
+
|
7
|
+
module CandidApiClient
|
8
|
+
module Individual
|
9
|
+
module Types
|
10
|
+
class PatientClinicalTrialInfo
|
11
|
+
# @return [String]
|
12
|
+
attr_reader :clinical_trial_arm
|
13
|
+
# @return [CandidApiClient::ClinicalTrials::V1::Types::ClinicalTrial]
|
14
|
+
attr_reader :clinical_trial
|
15
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
16
|
+
attr_reader :additional_properties
|
17
|
+
# @return [Object]
|
18
|
+
attr_reader :_field_set
|
19
|
+
protected :_field_set
|
20
|
+
|
21
|
+
OMIT = Object.new
|
22
|
+
|
23
|
+
# @param clinical_trial_arm [String]
|
24
|
+
# @param clinical_trial [CandidApiClient::ClinicalTrials::V1::Types::ClinicalTrial]
|
25
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
26
|
+
# @return [CandidApiClient::Individual::Types::PatientClinicalTrialInfo]
|
27
|
+
def initialize(clinical_trial:, clinical_trial_arm: OMIT, additional_properties: nil)
|
28
|
+
@clinical_trial_arm = clinical_trial_arm if clinical_trial_arm != OMIT
|
29
|
+
@clinical_trial = clinical_trial
|
30
|
+
@additional_properties = additional_properties
|
31
|
+
@_field_set = {
|
32
|
+
"clinical_trial_arm": clinical_trial_arm,
|
33
|
+
"clinical_trial": clinical_trial
|
34
|
+
}.reject do |_k, v|
|
35
|
+
v == OMIT
|
36
|
+
end
|
37
|
+
end
|
38
|
+
|
39
|
+
# Deserialize a JSON object to an instance of PatientClinicalTrialInfo
|
40
|
+
#
|
41
|
+
# @param json_object [String]
|
42
|
+
# @return [CandidApiClient::Individual::Types::PatientClinicalTrialInfo]
|
43
|
+
def self.from_json(json_object:)
|
44
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
45
|
+
parsed_json = JSON.parse(json_object)
|
46
|
+
clinical_trial_arm = struct["clinical_trial_arm"]
|
47
|
+
if parsed_json["clinical_trial"].nil?
|
48
|
+
clinical_trial = nil
|
49
|
+
else
|
50
|
+
clinical_trial = parsed_json["clinical_trial"].to_json
|
51
|
+
clinical_trial = CandidApiClient::ClinicalTrials::V1::Types::ClinicalTrial.from_json(json_object: clinical_trial)
|
52
|
+
end
|
53
|
+
new(
|
54
|
+
clinical_trial_arm: clinical_trial_arm,
|
55
|
+
clinical_trial: clinical_trial,
|
56
|
+
additional_properties: struct
|
57
|
+
)
|
58
|
+
end
|
59
|
+
|
60
|
+
# Serialize an instance of PatientClinicalTrialInfo to a JSON object
|
61
|
+
#
|
62
|
+
# @return [String]
|
63
|
+
def to_json(*_args)
|
64
|
+
@_field_set&.to_json
|
65
|
+
end
|
66
|
+
|
67
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
68
|
+
# hash and check each fields type against the current object's property
|
69
|
+
# definitions.
|
70
|
+
#
|
71
|
+
# @param obj [Object]
|
72
|
+
# @return [Void]
|
73
|
+
def self.validate_raw(obj:)
|
74
|
+
obj.clinical_trial_arm&.is_a?(String) != false || raise("Passed value for field obj.clinical_trial_arm is not the expected type, validation failed.")
|
75
|
+
CandidApiClient::ClinicalTrials::V1::Types::ClinicalTrial.validate_raw(obj: obj.clinical_trial)
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
79
|
+
end
|
80
|
+
end
|
@@ -0,0 +1,73 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "ostruct"
|
4
|
+
require "json"
|
5
|
+
|
6
|
+
module CandidApiClient
|
7
|
+
module Individual
|
8
|
+
module Types
|
9
|
+
class PatientClinicalTrialInfoCreate
|
10
|
+
# @return [String]
|
11
|
+
attr_reader :clinical_trial_arm
|
12
|
+
# @return [String]
|
13
|
+
attr_reader :clinical_trial_id
|
14
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
15
|
+
attr_reader :additional_properties
|
16
|
+
# @return [Object]
|
17
|
+
attr_reader :_field_set
|
18
|
+
protected :_field_set
|
19
|
+
|
20
|
+
OMIT = Object.new
|
21
|
+
|
22
|
+
# @param clinical_trial_arm [String]
|
23
|
+
# @param clinical_trial_id [String]
|
24
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
25
|
+
# @return [CandidApiClient::Individual::Types::PatientClinicalTrialInfoCreate]
|
26
|
+
def initialize(clinical_trial_id:, clinical_trial_arm: OMIT, additional_properties: nil)
|
27
|
+
@clinical_trial_arm = clinical_trial_arm if clinical_trial_arm != OMIT
|
28
|
+
@clinical_trial_id = clinical_trial_id
|
29
|
+
@additional_properties = additional_properties
|
30
|
+
@_field_set = {
|
31
|
+
"clinical_trial_arm": clinical_trial_arm,
|
32
|
+
"clinical_trial_id": clinical_trial_id
|
33
|
+
}.reject do |_k, v|
|
34
|
+
v == OMIT
|
35
|
+
end
|
36
|
+
end
|
37
|
+
|
38
|
+
# Deserialize a JSON object to an instance of PatientClinicalTrialInfoCreate
|
39
|
+
#
|
40
|
+
# @param json_object [String]
|
41
|
+
# @return [CandidApiClient::Individual::Types::PatientClinicalTrialInfoCreate]
|
42
|
+
def self.from_json(json_object:)
|
43
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
44
|
+
clinical_trial_arm = struct["clinical_trial_arm"]
|
45
|
+
clinical_trial_id = struct["clinical_trial_id"]
|
46
|
+
new(
|
47
|
+
clinical_trial_arm: clinical_trial_arm,
|
48
|
+
clinical_trial_id: clinical_trial_id,
|
49
|
+
additional_properties: struct
|
50
|
+
)
|
51
|
+
end
|
52
|
+
|
53
|
+
# Serialize an instance of PatientClinicalTrialInfoCreate to a JSON object
|
54
|
+
#
|
55
|
+
# @return [String]
|
56
|
+
def to_json(*_args)
|
57
|
+
@_field_set&.to_json
|
58
|
+
end
|
59
|
+
|
60
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
61
|
+
# hash and check each fields type against the current object's property
|
62
|
+
# definitions.
|
63
|
+
#
|
64
|
+
# @param obj [Object]
|
65
|
+
# @return [Void]
|
66
|
+
def self.validate_raw(obj:)
|
67
|
+
obj.clinical_trial_arm&.is_a?(String) != false || raise("Passed value for field obj.clinical_trial_arm is not the expected type, validation failed.")
|
68
|
+
obj.clinical_trial_id.is_a?(String) != false || raise("Passed value for field obj.clinical_trial_id is not the expected type, validation failed.")
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
72
|
+
end
|
73
|
+
end
|
@@ -1,6 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
require_relative "../../non_insurance_payers/v_1/types/non_insurance_payer"
|
4
|
+
require_relative "patient_clinical_trial_info"
|
4
5
|
require "ostruct"
|
5
6
|
require "json"
|
6
7
|
|
@@ -12,6 +13,8 @@ module CandidApiClient
|
|
12
13
|
attr_reader :non_insurance_payer
|
13
14
|
# @return [String]
|
14
15
|
attr_reader :member_id
|
16
|
+
# @return [Array<CandidApiClient::Individual::Types::PatientClinicalTrialInfo>] A patient cannot be associated with a given trial more than once
|
17
|
+
attr_reader :clinical_trial_info
|
15
18
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
16
19
|
attr_reader :additional_properties
|
17
20
|
# @return [Object]
|
@@ -22,13 +25,19 @@ module CandidApiClient
|
|
22
25
|
|
23
26
|
# @param non_insurance_payer [CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayer]
|
24
27
|
# @param member_id [String]
|
28
|
+
# @param clinical_trial_info [Array<CandidApiClient::Individual::Types::PatientClinicalTrialInfo>] A patient cannot be associated with a given trial more than once
|
25
29
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
26
30
|
# @return [CandidApiClient::Individual::Types::PatientNonInsurancePayerInfo]
|
27
|
-
def initialize(non_insurance_payer:, member_id: OMIT, additional_properties: nil)
|
31
|
+
def initialize(non_insurance_payer:, clinical_trial_info:, member_id: OMIT, additional_properties: nil)
|
28
32
|
@non_insurance_payer = non_insurance_payer
|
29
33
|
@member_id = member_id if member_id != OMIT
|
34
|
+
@clinical_trial_info = clinical_trial_info
|
30
35
|
@additional_properties = additional_properties
|
31
|
-
@_field_set = {
|
36
|
+
@_field_set = {
|
37
|
+
"non_insurance_payer": non_insurance_payer,
|
38
|
+
"member_id": member_id,
|
39
|
+
"clinical_trial_info": clinical_trial_info
|
40
|
+
}.reject do |_k, v|
|
32
41
|
v == OMIT
|
33
42
|
end
|
34
43
|
end
|
@@ -47,9 +56,14 @@ module CandidApiClient
|
|
47
56
|
non_insurance_payer = CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayer.from_json(json_object: non_insurance_payer)
|
48
57
|
end
|
49
58
|
member_id = struct["member_id"]
|
59
|
+
clinical_trial_info = parsed_json["clinical_trial_info"]&.map do |item|
|
60
|
+
item = item.to_json
|
61
|
+
CandidApiClient::Individual::Types::PatientClinicalTrialInfo.from_json(json_object: item)
|
62
|
+
end
|
50
63
|
new(
|
51
64
|
non_insurance_payer: non_insurance_payer,
|
52
65
|
member_id: member_id,
|
66
|
+
clinical_trial_info: clinical_trial_info,
|
53
67
|
additional_properties: struct
|
54
68
|
)
|
55
69
|
end
|
@@ -70,6 +84,7 @@ module CandidApiClient
|
|
70
84
|
def self.validate_raw(obj:)
|
71
85
|
CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayer.validate_raw(obj: obj.non_insurance_payer)
|
72
86
|
obj.member_id&.is_a?(String) != false || raise("Passed value for field obj.member_id is not the expected type, validation failed.")
|
87
|
+
obj.clinical_trial_info.is_a?(Array) != false || raise("Passed value for field obj.clinical_trial_info is not the expected type, validation failed.")
|
73
88
|
end
|
74
89
|
end
|
75
90
|
end
|
@@ -1,5 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
+
require_relative "patient_clinical_trial_info_create"
|
3
4
|
require "ostruct"
|
4
5
|
require "json"
|
5
6
|
|
@@ -11,6 +12,8 @@ module CandidApiClient
|
|
11
12
|
attr_reader :non_insurance_payer_id
|
12
13
|
# @return [String]
|
13
14
|
attr_reader :member_id
|
15
|
+
# @return [Array<CandidApiClient::Individual::Types::PatientClinicalTrialInfoCreate>]
|
16
|
+
attr_reader :clinical_trial_info
|
14
17
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
15
18
|
attr_reader :additional_properties
|
16
19
|
# @return [Object]
|
@@ -21,13 +24,19 @@ module CandidApiClient
|
|
21
24
|
|
22
25
|
# @param non_insurance_payer_id [String]
|
23
26
|
# @param member_id [String]
|
27
|
+
# @param clinical_trial_info [Array<CandidApiClient::Individual::Types::PatientClinicalTrialInfoCreate>]
|
24
28
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
25
29
|
# @return [CandidApiClient::Individual::Types::PatientNonInsurancePayerInfoCreate]
|
26
|
-
def initialize(non_insurance_payer_id:, member_id: OMIT, additional_properties: nil)
|
30
|
+
def initialize(non_insurance_payer_id:, member_id: OMIT, clinical_trial_info: OMIT, additional_properties: nil)
|
27
31
|
@non_insurance_payer_id = non_insurance_payer_id
|
28
32
|
@member_id = member_id if member_id != OMIT
|
33
|
+
@clinical_trial_info = clinical_trial_info if clinical_trial_info != OMIT
|
29
34
|
@additional_properties = additional_properties
|
30
|
-
@_field_set = {
|
35
|
+
@_field_set = {
|
36
|
+
"non_insurance_payer_id": non_insurance_payer_id,
|
37
|
+
"member_id": member_id,
|
38
|
+
"clinical_trial_info": clinical_trial_info
|
39
|
+
}.reject do |_k, v|
|
31
40
|
v == OMIT
|
32
41
|
end
|
33
42
|
end
|
@@ -38,11 +47,17 @@ module CandidApiClient
|
|
38
47
|
# @return [CandidApiClient::Individual::Types::PatientNonInsurancePayerInfoCreate]
|
39
48
|
def self.from_json(json_object:)
|
40
49
|
struct = JSON.parse(json_object, object_class: OpenStruct)
|
50
|
+
parsed_json = JSON.parse(json_object)
|
41
51
|
non_insurance_payer_id = struct["non_insurance_payer_id"]
|
42
52
|
member_id = struct["member_id"]
|
53
|
+
clinical_trial_info = parsed_json["clinical_trial_info"]&.map do |item|
|
54
|
+
item = item.to_json
|
55
|
+
CandidApiClient::Individual::Types::PatientClinicalTrialInfoCreate.from_json(json_object: item)
|
56
|
+
end
|
43
57
|
new(
|
44
58
|
non_insurance_payer_id: non_insurance_payer_id,
|
45
59
|
member_id: member_id,
|
60
|
+
clinical_trial_info: clinical_trial_info,
|
46
61
|
additional_properties: struct
|
47
62
|
)
|
48
63
|
end
|
@@ -63,6 +78,7 @@ module CandidApiClient
|
|
63
78
|
def self.validate_raw(obj:)
|
64
79
|
obj.non_insurance_payer_id.is_a?(String) != false || raise("Passed value for field obj.non_insurance_payer_id is not the expected type, validation failed.")
|
65
80
|
obj.member_id&.is_a?(String) != false || raise("Passed value for field obj.member_id is not the expected type, validation failed.")
|
81
|
+
obj.clinical_trial_info&.is_a?(Array) != false || raise("Passed value for field obj.clinical_trial_info is not the expected type, validation failed.")
|
66
82
|
end
|
67
83
|
end
|
68
84
|
end
|
@@ -34,11 +34,12 @@ module CandidApiClient
|
|
34
34
|
# * :city (String)
|
35
35
|
# * :state (CandidApiClient::Commons::Types::State)
|
36
36
|
# * :zip_code (String)
|
37
|
+
# * :clinical_trials (Array<CandidApiClient::ClinicalTrials::V1::Types::MutableClinicalTrial>)
|
37
38
|
# @param request_options [CandidApiClient::RequestOptions]
|
38
39
|
# @return [CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayer]
|
39
40
|
# @example
|
40
41
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
41
|
-
# api.non_insurance_payers.v_1.create(request: { name: "string", description: "string", category: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" } })
|
42
|
+
# api.non_insurance_payers.v_1.create(request: { name: "string", description: "string", category: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, clinical_trials: [{ name: "string", clinical_trial_number: "string", clinical_trial_phase: PHASE_ONE }] })
|
42
43
|
def create(request:, request_options: nil)
|
43
44
|
response = @request_client.conn.post do |req|
|
44
45
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -215,11 +216,12 @@ module CandidApiClient
|
|
215
216
|
# * :city (String)
|
216
217
|
# * :state (CandidApiClient::Commons::Types::State)
|
217
218
|
# * :zip_code (String)
|
219
|
+
# * :clinical_trials (Array<CandidApiClient::ClinicalTrials::V1::Types::MutableClinicalTrial>)
|
218
220
|
# @param request_options [CandidApiClient::RequestOptions]
|
219
221
|
# @return [CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayer]
|
220
222
|
# @example
|
221
223
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
222
|
-
# api.non_insurance_payers.v_1.create(request: { name: "string", description: "string", category: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" } })
|
224
|
+
# api.non_insurance_payers.v_1.create(request: { name: "string", description: "string", category: "string", address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }, clinical_trials: [{ name: "string", clinical_trial_number: "string", clinical_trial_phase: PHASE_ONE }] })
|
223
225
|
def create(request:, request_options: nil)
|
224
226
|
Async do
|
225
227
|
response = @request_client.conn.post do |req|
|