candidhealth 1.3.1 → 1.5.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 +885 -235
- data/lib/candidhealth/claim_submission/v_1/types/claim_submission_record_create.rb +4 -4
- data/lib/candidhealth/claim_submission/v_1/types/claim_submission_record_create_optional.rb +4 -4
- data/lib/candidhealth/contracts/v_2/client.rb +4 -4
- data/lib/candidhealth/diagnoses/types/disallow_multiple_primary_diagnosis_error.rb +80 -0
- data/lib/candidhealth/diagnoses/types/service_lines_must_have_at_least_one_diagnosis_error.rb +77 -0
- data/lib/candidhealth/encounters/v_4/types/encounter.rb +151 -2
- data/lib/candidhealth/encounters/v_4/types/encounter_submission_expectation.rb +23 -0
- data/lib/candidhealth/exports/v_3/client.rb +16 -10
- data/lib/candidhealth/fee_schedules/v_3/client.rb +82 -0
- data/lib/candidhealth/individual/types/subscriber_create.rb +6 -2
- data/lib/candidhealth/individual/types/subscriber_create_optional.rb +6 -2
- data/lib/candidhealth/non_insurance_payers/v_1/client.rb +95 -6
- data/lib/candidhealth/non_insurance_payers/v_1/types/non_insurance_payer_categories_page.rb +83 -0
- data/lib/candidhealth/organization_providers/v_3/client.rb +8 -4
- data/lib/candidhealth/organization_service_facilities/v_2/client.rb +8 -2
- data/lib/candidhealth/pre_encounter/appointments/v_1/client.rb +12 -4
- data/lib/candidhealth/pre_encounter/appointments/v_1/types/appointment.rb +11 -3
- data/lib/candidhealth/pre_encounter/appointments/v_1/types/mutable_appointment.rb +9 -1
- data/lib/candidhealth/pre_encounter/appointments/v_1/types/visit.rb +24 -2
- data/lib/candidhealth/pre_encounter/common/types/base_model.rb +2 -2
- data/lib/candidhealth/pre_encounter/coverages/v_1/client.rb +8 -4
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/coverage.rb +6 -4
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/mutable_coverage.rb +4 -2
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/client.rb +205 -16
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/coordination_of_benefits_recommendation.rb +63 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/eligibility_recommendation.rb +144 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/eligibility_recommendation_patient_info.rb +124 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/eligibility_recommendation_payload.rb +102 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/medicare_advantage_recommendation.rb +70 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/medicare_advantage_recommendation_payload.rb +96 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/payer_search_response.rb +107 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/post_eligibility_recommendation_request.rb +96 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/stedi_payer.rb +144 -0
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/stedi_payer_item.rb +79 -0
- data/lib/candidhealth/pre_encounter/images/v_1/types/image.rb +2 -2
- data/lib/candidhealth/pre_encounter/lists/v_1/types/patient_list_item.rb +28 -1
- data/lib/candidhealth/pre_encounter/notes/v_1/types/note.rb +2 -2
- data/lib/candidhealth/pre_encounter/patients/v_1/client.rb +8 -4
- data/lib/candidhealth/pre_encounter/patients/v_1/types/patient.rb +2 -2
- data/lib/candidhealth/pre_encounter/tags/v_1/client.rb +8 -0
- data/lib/candidhealth/pre_encounter/tags/v_1/types/mutable_tag.rb +22 -3
- data/lib/candidhealth/pre_encounter/tags/v_1/types/tag.rb +23 -5
- data/lib/candidhealth/service_lines/v_2/types/service_line.rb +9 -1
- data/lib/candidhealth/x_12/v_1/types/patient_discharge_status_code.rb +52 -0
- data/lib/candidhealth/x_12/v_1/types/point_of_origin_for_admission_or_visit_code.rb +23 -0
- data/lib/candidhealth/x_12/v_1/types/type_of_admission_or_visit_code.rb +18 -0
- data/lib/candidhealth/x_12/v_1/types/type_of_bill_composite.rb +98 -0
- data/lib/candidhealth/x_12/v_1/types/type_of_bill_frequency_code.rb +39 -0
- data/lib/candidhealth/x_12/v_1/types/type_of_care_code.rb +21 -0
- data/lib/candidhealth/x_12/v_1/types/type_of_facility_code.rb +19 -0
- data/lib/requests.rb +2 -2
- data/lib/types_export.rb +21 -1
- metadata +23 -3
- data/lib/candidhealth/claim_submission/v_1/types/claim_frequency_type_code.rb +0 -15
@@ -0,0 +1,96 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "eligibility_recommendation_patient_info"
|
4
|
+
require_relative "eligibility_recommendation_payload"
|
5
|
+
require "ostruct"
|
6
|
+
require "json"
|
7
|
+
|
8
|
+
module CandidApiClient
|
9
|
+
module PreEncounter
|
10
|
+
module EligibilityChecks
|
11
|
+
module V1
|
12
|
+
module Types
|
13
|
+
class PostEligibilityRecommendationRequest
|
14
|
+
# @return [String]
|
15
|
+
attr_reader :eligibility_check_id
|
16
|
+
# @return [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::EligibilityRecommendationPatientInfo]
|
17
|
+
attr_reader :patient
|
18
|
+
# @return [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::EligibilityRecommendationPayload]
|
19
|
+
attr_reader :recommendation
|
20
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
21
|
+
attr_reader :additional_properties
|
22
|
+
# @return [Object]
|
23
|
+
attr_reader :_field_set
|
24
|
+
protected :_field_set
|
25
|
+
|
26
|
+
OMIT = Object.new
|
27
|
+
|
28
|
+
# @param eligibility_check_id [String]
|
29
|
+
# @param patient [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::EligibilityRecommendationPatientInfo]
|
30
|
+
# @param recommendation [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::EligibilityRecommendationPayload]
|
31
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
32
|
+
# @return [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::PostEligibilityRecommendationRequest]
|
33
|
+
def initialize(eligibility_check_id:, patient:, recommendation:, additional_properties: nil)
|
34
|
+
@eligibility_check_id = eligibility_check_id
|
35
|
+
@patient = patient
|
36
|
+
@recommendation = recommendation
|
37
|
+
@additional_properties = additional_properties
|
38
|
+
@_field_set = {
|
39
|
+
"eligibility_check_id": eligibility_check_id,
|
40
|
+
"patient": patient,
|
41
|
+
"recommendation": recommendation
|
42
|
+
}
|
43
|
+
end
|
44
|
+
|
45
|
+
# Deserialize a JSON object to an instance of PostEligibilityRecommendationRequest
|
46
|
+
#
|
47
|
+
# @param json_object [String]
|
48
|
+
# @return [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::PostEligibilityRecommendationRequest]
|
49
|
+
def self.from_json(json_object:)
|
50
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
51
|
+
parsed_json = JSON.parse(json_object)
|
52
|
+
eligibility_check_id = struct["eligibility_check_id"]
|
53
|
+
if parsed_json["patient"].nil?
|
54
|
+
patient = nil
|
55
|
+
else
|
56
|
+
patient = parsed_json["patient"].to_json
|
57
|
+
patient = CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::EligibilityRecommendationPatientInfo.from_json(json_object: patient)
|
58
|
+
end
|
59
|
+
if parsed_json["recommendation"].nil?
|
60
|
+
recommendation = nil
|
61
|
+
else
|
62
|
+
recommendation = parsed_json["recommendation"].to_json
|
63
|
+
recommendation = CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::EligibilityRecommendationPayload.from_json(json_object: recommendation)
|
64
|
+
end
|
65
|
+
new(
|
66
|
+
eligibility_check_id: eligibility_check_id,
|
67
|
+
patient: patient,
|
68
|
+
recommendation: recommendation,
|
69
|
+
additional_properties: struct
|
70
|
+
)
|
71
|
+
end
|
72
|
+
|
73
|
+
# Serialize an instance of PostEligibilityRecommendationRequest to a JSON object
|
74
|
+
#
|
75
|
+
# @return [String]
|
76
|
+
def to_json(*_args)
|
77
|
+
@_field_set&.to_json
|
78
|
+
end
|
79
|
+
|
80
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
81
|
+
# hash and check each fields type against the current object's property
|
82
|
+
# definitions.
|
83
|
+
#
|
84
|
+
# @param obj [Object]
|
85
|
+
# @return [Void]
|
86
|
+
def self.validate_raw(obj:)
|
87
|
+
obj.eligibility_check_id.is_a?(String) != false || raise("Passed value for field obj.eligibility_check_id is not the expected type, validation failed.")
|
88
|
+
CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::EligibilityRecommendationPatientInfo.validate_raw(obj: obj.patient)
|
89
|
+
CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::EligibilityRecommendationPayload.validate_raw(obj: obj.recommendation)
|
90
|
+
end
|
91
|
+
end
|
92
|
+
end
|
93
|
+
end
|
94
|
+
end
|
95
|
+
end
|
96
|
+
end
|
@@ -0,0 +1,144 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "ostruct"
|
4
|
+
require "json"
|
5
|
+
|
6
|
+
module CandidApiClient
|
7
|
+
module PreEncounter
|
8
|
+
module EligibilityChecks
|
9
|
+
module V1
|
10
|
+
module Types
|
11
|
+
class StediPayer
|
12
|
+
# @return [String]
|
13
|
+
attr_reader :stedi_id
|
14
|
+
# @return [String]
|
15
|
+
attr_reader :display_name
|
16
|
+
# @return [String]
|
17
|
+
attr_reader :primary_payer_id
|
18
|
+
# @return [Array<String>]
|
19
|
+
attr_reader :aliases
|
20
|
+
# @return [Array<String>]
|
21
|
+
attr_reader :names
|
22
|
+
# @return [Object]
|
23
|
+
attr_reader :transaction_support
|
24
|
+
# @return [Array<String>]
|
25
|
+
attr_reader :employer_identification_numbers
|
26
|
+
# @return [Object]
|
27
|
+
attr_reader :payer_enrollment
|
28
|
+
# @return [String]
|
29
|
+
attr_reader :parent_payer_group
|
30
|
+
# @return [Array<String>]
|
31
|
+
attr_reader :coverage_types
|
32
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
33
|
+
attr_reader :additional_properties
|
34
|
+
# @return [Object]
|
35
|
+
attr_reader :_field_set
|
36
|
+
protected :_field_set
|
37
|
+
|
38
|
+
OMIT = Object.new
|
39
|
+
|
40
|
+
# @param stedi_id [String]
|
41
|
+
# @param display_name [String]
|
42
|
+
# @param primary_payer_id [String]
|
43
|
+
# @param aliases [Array<String>]
|
44
|
+
# @param names [Array<String>]
|
45
|
+
# @param transaction_support [Object]
|
46
|
+
# @param employer_identification_numbers [Array<String>]
|
47
|
+
# @param payer_enrollment [Object]
|
48
|
+
# @param parent_payer_group [String]
|
49
|
+
# @param coverage_types [Array<String>]
|
50
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
51
|
+
# @return [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::StediPayer]
|
52
|
+
def initialize(stedi_id:, display_name:, primary_payer_id:, aliases:, names:, transaction_support:, payer_enrollment:,
|
53
|
+
employer_identification_numbers: OMIT, parent_payer_group: OMIT, coverage_types: OMIT, additional_properties: nil)
|
54
|
+
@stedi_id = stedi_id
|
55
|
+
@display_name = display_name
|
56
|
+
@primary_payer_id = primary_payer_id
|
57
|
+
@aliases = aliases
|
58
|
+
@names = names
|
59
|
+
@transaction_support = transaction_support
|
60
|
+
if employer_identification_numbers != OMIT
|
61
|
+
@employer_identification_numbers = employer_identification_numbers
|
62
|
+
end
|
63
|
+
@payer_enrollment = payer_enrollment
|
64
|
+
@parent_payer_group = parent_payer_group if parent_payer_group != OMIT
|
65
|
+
@coverage_types = coverage_types if coverage_types != OMIT
|
66
|
+
@additional_properties = additional_properties
|
67
|
+
@_field_set = {
|
68
|
+
"stedi_id": stedi_id,
|
69
|
+
"display_name": display_name,
|
70
|
+
"primary_payer_id": primary_payer_id,
|
71
|
+
"aliases": aliases,
|
72
|
+
"names": names,
|
73
|
+
"transaction_support": transaction_support,
|
74
|
+
"employer_identification_numbers": employer_identification_numbers,
|
75
|
+
"payer_enrollment": payer_enrollment,
|
76
|
+
"parent_payer_group": parent_payer_group,
|
77
|
+
"coverage_types": coverage_types
|
78
|
+
}.reject do |_k, v|
|
79
|
+
v == OMIT
|
80
|
+
end
|
81
|
+
end
|
82
|
+
|
83
|
+
# Deserialize a JSON object to an instance of StediPayer
|
84
|
+
#
|
85
|
+
# @param json_object [String]
|
86
|
+
# @return [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::StediPayer]
|
87
|
+
def self.from_json(json_object:)
|
88
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
89
|
+
stedi_id = struct["stedi_id"]
|
90
|
+
display_name = struct["display_name"]
|
91
|
+
primary_payer_id = struct["primary_payer_id"]
|
92
|
+
aliases = struct["aliases"]
|
93
|
+
names = struct["names"]
|
94
|
+
transaction_support = struct["transaction_support"]
|
95
|
+
employer_identification_numbers = struct["employer_identification_numbers"]
|
96
|
+
payer_enrollment = struct["payer_enrollment"]
|
97
|
+
parent_payer_group = struct["parent_payer_group"]
|
98
|
+
coverage_types = struct["coverage_types"]
|
99
|
+
new(
|
100
|
+
stedi_id: stedi_id,
|
101
|
+
display_name: display_name,
|
102
|
+
primary_payer_id: primary_payer_id,
|
103
|
+
aliases: aliases,
|
104
|
+
names: names,
|
105
|
+
transaction_support: transaction_support,
|
106
|
+
employer_identification_numbers: employer_identification_numbers,
|
107
|
+
payer_enrollment: payer_enrollment,
|
108
|
+
parent_payer_group: parent_payer_group,
|
109
|
+
coverage_types: coverage_types,
|
110
|
+
additional_properties: struct
|
111
|
+
)
|
112
|
+
end
|
113
|
+
|
114
|
+
# Serialize an instance of StediPayer to a JSON object
|
115
|
+
#
|
116
|
+
# @return [String]
|
117
|
+
def to_json(*_args)
|
118
|
+
@_field_set&.to_json
|
119
|
+
end
|
120
|
+
|
121
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
122
|
+
# hash and check each fields type against the current object's property
|
123
|
+
# definitions.
|
124
|
+
#
|
125
|
+
# @param obj [Object]
|
126
|
+
# @return [Void]
|
127
|
+
def self.validate_raw(obj:)
|
128
|
+
obj.stedi_id.is_a?(String) != false || raise("Passed value for field obj.stedi_id is not the expected type, validation failed.")
|
129
|
+
obj.display_name.is_a?(String) != false || raise("Passed value for field obj.display_name is not the expected type, validation failed.")
|
130
|
+
obj.primary_payer_id.is_a?(String) != false || raise("Passed value for field obj.primary_payer_id is not the expected type, validation failed.")
|
131
|
+
obj.aliases.is_a?(Array) != false || raise("Passed value for field obj.aliases is not the expected type, validation failed.")
|
132
|
+
obj.names.is_a?(Array) != false || raise("Passed value for field obj.names is not the expected type, validation failed.")
|
133
|
+
obj.transaction_support.is_a?(Object) != false || raise("Passed value for field obj.transaction_support is not the expected type, validation failed.")
|
134
|
+
obj.employer_identification_numbers&.is_a?(Array) != false || raise("Passed value for field obj.employer_identification_numbers is not the expected type, validation failed.")
|
135
|
+
obj.payer_enrollment.is_a?(Object) != false || raise("Passed value for field obj.payer_enrollment is not the expected type, validation failed.")
|
136
|
+
obj.parent_payer_group&.is_a?(String) != false || raise("Passed value for field obj.parent_payer_group is not the expected type, validation failed.")
|
137
|
+
obj.coverage_types&.is_a?(Array) != false || raise("Passed value for field obj.coverage_types is not the expected type, validation failed.")
|
138
|
+
end
|
139
|
+
end
|
140
|
+
end
|
141
|
+
end
|
142
|
+
end
|
143
|
+
end
|
144
|
+
end
|
@@ -0,0 +1,79 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "stedi_payer"
|
4
|
+
require "ostruct"
|
5
|
+
require "json"
|
6
|
+
|
7
|
+
module CandidApiClient
|
8
|
+
module PreEncounter
|
9
|
+
module EligibilityChecks
|
10
|
+
module V1
|
11
|
+
module Types
|
12
|
+
class StediPayerItem
|
13
|
+
# @return [Integer]
|
14
|
+
attr_reader :score
|
15
|
+
# @return [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::StediPayer]
|
16
|
+
attr_reader :payer
|
17
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
18
|
+
attr_reader :additional_properties
|
19
|
+
# @return [Object]
|
20
|
+
attr_reader :_field_set
|
21
|
+
protected :_field_set
|
22
|
+
|
23
|
+
OMIT = Object.new
|
24
|
+
|
25
|
+
# @param score [Integer]
|
26
|
+
# @param payer [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::StediPayer]
|
27
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
28
|
+
# @return [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::StediPayerItem]
|
29
|
+
def initialize(score:, payer:, additional_properties: nil)
|
30
|
+
@score = score
|
31
|
+
@payer = payer
|
32
|
+
@additional_properties = additional_properties
|
33
|
+
@_field_set = { "score": score, "payer": payer }
|
34
|
+
end
|
35
|
+
|
36
|
+
# Deserialize a JSON object to an instance of StediPayerItem
|
37
|
+
#
|
38
|
+
# @param json_object [String]
|
39
|
+
# @return [CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::StediPayerItem]
|
40
|
+
def self.from_json(json_object:)
|
41
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
42
|
+
parsed_json = JSON.parse(json_object)
|
43
|
+
score = struct["score"]
|
44
|
+
if parsed_json["payer"].nil?
|
45
|
+
payer = nil
|
46
|
+
else
|
47
|
+
payer = parsed_json["payer"].to_json
|
48
|
+
payer = CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::StediPayer.from_json(json_object: payer)
|
49
|
+
end
|
50
|
+
new(
|
51
|
+
score: score,
|
52
|
+
payer: payer,
|
53
|
+
additional_properties: struct
|
54
|
+
)
|
55
|
+
end
|
56
|
+
|
57
|
+
# Serialize an instance of StediPayerItem to a JSON object
|
58
|
+
#
|
59
|
+
# @return [String]
|
60
|
+
def to_json(*_args)
|
61
|
+
@_field_set&.to_json
|
62
|
+
end
|
63
|
+
|
64
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
65
|
+
# hash and check each fields type against the current object's property
|
66
|
+
# definitions.
|
67
|
+
#
|
68
|
+
# @param obj [Object]
|
69
|
+
# @return [Void]
|
70
|
+
def self.validate_raw(obj:)
|
71
|
+
obj.score.is_a?(Integer) != false || raise("Passed value for field obj.score is not the expected type, validation failed.")
|
72
|
+
CandidApiClient::PreEncounter::EligibilityChecks::V1::Types::StediPayer.validate_raw(obj: obj.payer)
|
73
|
+
end
|
74
|
+
end
|
75
|
+
end
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
79
|
+
end
|
@@ -24,7 +24,7 @@ module CandidApiClient
|
|
24
24
|
# @return [Boolean] True if the object is deactivated. Deactivated objects are not returned in
|
25
25
|
# search results but are returned in all other endpoints including scan.
|
26
26
|
attr_reader :deactivated
|
27
|
-
# @return [Integer] The version of the object.
|
27
|
+
# @return [Integer] The version of the object. Any update to any property of an object object will
|
28
28
|
# create a new version.
|
29
29
|
attr_reader :version
|
30
30
|
# @return [DateTime]
|
@@ -57,7 +57,7 @@ module CandidApiClient
|
|
57
57
|
# @param organization_id [String] The organization that owns this object.
|
58
58
|
# @param deactivated [Boolean] True if the object is deactivated. Deactivated objects are not returned in
|
59
59
|
# search results but are returned in all other endpoints including scan.
|
60
|
-
# @param version [Integer] The version of the object.
|
60
|
+
# @param version [Integer] The version of the object. Any update to any property of an object object will
|
61
61
|
# create a new version.
|
62
62
|
# @param updated_at [DateTime]
|
63
63
|
# @param updating_user_id [String] The user ID of the user who last updated the object.
|
@@ -16,6 +16,10 @@ module CandidApiClient
|
|
16
16
|
attr_reader :patient
|
17
17
|
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage]
|
18
18
|
attr_reader :primary_coverage
|
19
|
+
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage]
|
20
|
+
attr_reader :secondary_coverage
|
21
|
+
# @return [CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage]
|
22
|
+
attr_reader :tertiary_coverage
|
19
23
|
# @return [CandidApiClient::PreEncounter::Appointments::V1::Types::MutableAppointment]
|
20
24
|
attr_reader :next_appointment
|
21
25
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
@@ -28,17 +32,24 @@ module CandidApiClient
|
|
28
32
|
|
29
33
|
# @param patient [CandidApiClient::PreEncounter::Patients::V1::Types::Patient]
|
30
34
|
# @param primary_coverage [CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage]
|
35
|
+
# @param secondary_coverage [CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage]
|
36
|
+
# @param tertiary_coverage [CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage]
|
31
37
|
# @param next_appointment [CandidApiClient::PreEncounter::Appointments::V1::Types::MutableAppointment]
|
32
38
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
33
39
|
# @return [CandidApiClient::PreEncounter::Lists::V1::Types::PatientListItem]
|
34
|
-
def initialize(patient:, primary_coverage: OMIT,
|
40
|
+
def initialize(patient:, primary_coverage: OMIT, secondary_coverage: OMIT, tertiary_coverage: OMIT,
|
41
|
+
next_appointment: OMIT, additional_properties: nil)
|
35
42
|
@patient = patient
|
36
43
|
@primary_coverage = primary_coverage if primary_coverage != OMIT
|
44
|
+
@secondary_coverage = secondary_coverage if secondary_coverage != OMIT
|
45
|
+
@tertiary_coverage = tertiary_coverage if tertiary_coverage != OMIT
|
37
46
|
@next_appointment = next_appointment if next_appointment != OMIT
|
38
47
|
@additional_properties = additional_properties
|
39
48
|
@_field_set = {
|
40
49
|
"patient": patient,
|
41
50
|
"primary_coverage": primary_coverage,
|
51
|
+
"secondary_coverage": secondary_coverage,
|
52
|
+
"tertiary_coverage": tertiary_coverage,
|
42
53
|
"next_appointment": next_appointment
|
43
54
|
}.reject do |_k, v|
|
44
55
|
v == OMIT
|
@@ -64,6 +75,18 @@ module CandidApiClient
|
|
64
75
|
primary_coverage = parsed_json["primary_coverage"].to_json
|
65
76
|
primary_coverage = CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage.from_json(json_object: primary_coverage)
|
66
77
|
end
|
78
|
+
if parsed_json["secondary_coverage"].nil?
|
79
|
+
secondary_coverage = nil
|
80
|
+
else
|
81
|
+
secondary_coverage = parsed_json["secondary_coverage"].to_json
|
82
|
+
secondary_coverage = CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage.from_json(json_object: secondary_coverage)
|
83
|
+
end
|
84
|
+
if parsed_json["tertiary_coverage"].nil?
|
85
|
+
tertiary_coverage = nil
|
86
|
+
else
|
87
|
+
tertiary_coverage = parsed_json["tertiary_coverage"].to_json
|
88
|
+
tertiary_coverage = CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage.from_json(json_object: tertiary_coverage)
|
89
|
+
end
|
67
90
|
if parsed_json["next_appointment"].nil?
|
68
91
|
next_appointment = nil
|
69
92
|
else
|
@@ -73,6 +96,8 @@ module CandidApiClient
|
|
73
96
|
new(
|
74
97
|
patient: patient,
|
75
98
|
primary_coverage: primary_coverage,
|
99
|
+
secondary_coverage: secondary_coverage,
|
100
|
+
tertiary_coverage: tertiary_coverage,
|
76
101
|
next_appointment: next_appointment,
|
77
102
|
additional_properties: struct
|
78
103
|
)
|
@@ -94,6 +119,8 @@ module CandidApiClient
|
|
94
119
|
def self.validate_raw(obj:)
|
95
120
|
CandidApiClient::PreEncounter::Patients::V1::Types::Patient.validate_raw(obj: obj.patient)
|
96
121
|
obj.primary_coverage.nil? || CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage.validate_raw(obj: obj.primary_coverage)
|
122
|
+
obj.secondary_coverage.nil? || CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage.validate_raw(obj: obj.secondary_coverage)
|
123
|
+
obj.tertiary_coverage.nil? || CandidApiClient::PreEncounter::Coverages::V1::Types::MutableCoverage.validate_raw(obj: obj.tertiary_coverage)
|
97
124
|
obj.next_appointment.nil? || CandidApiClient::PreEncounter::Appointments::V1::Types::MutableAppointment.validate_raw(obj: obj.next_appointment)
|
98
125
|
end
|
99
126
|
end
|
@@ -20,7 +20,7 @@ module CandidApiClient
|
|
20
20
|
# @return [Boolean] True if the object is deactivated. Deactivated objects are not returned in
|
21
21
|
# search results but are returned in all other endpoints including scan.
|
22
22
|
attr_reader :deactivated
|
23
|
-
# @return [Integer] The version of the object.
|
23
|
+
# @return [Integer] The version of the object. Any update to any property of an object object will
|
24
24
|
# create a new version.
|
25
25
|
attr_reader :version
|
26
26
|
# @return [DateTime]
|
@@ -46,7 +46,7 @@ module CandidApiClient
|
|
46
46
|
# @param organization_id [String] The organization that owns this object.
|
47
47
|
# @param deactivated [Boolean] True if the object is deactivated. Deactivated objects are not returned in
|
48
48
|
# search results but are returned in all other endpoints including scan.
|
49
|
-
# @param version [Integer] The version of the object.
|
49
|
+
# @param version [Integer] The version of the object. Any update to any property of an object object will
|
50
50
|
# create a new version.
|
51
51
|
# @param updated_at [DateTime]
|
52
52
|
# @param updating_user_id [String] The user ID of the user who last updated the object.
|
@@ -383,8 +383,10 @@ module CandidApiClient
|
|
383
383
|
end
|
384
384
|
end
|
385
385
|
|
386
|
-
# Updates a patient.
|
387
|
-
#
|
386
|
+
# Updates a patient. The path must contain the next version number to prevent race
|
387
|
+
# conditions. For example, if the current version of the patient is n, you will
|
388
|
+
# need to send a request to this endpoint with `/{id}/n+1` to update the patient.
|
389
|
+
# Updating historic versions is not supported.
|
388
390
|
#
|
389
391
|
# @param id [String]
|
390
392
|
# @param version [String]
|
@@ -994,8 +996,10 @@ module CandidApiClient
|
|
994
996
|
end
|
995
997
|
end
|
996
998
|
|
997
|
-
# Updates a patient.
|
998
|
-
#
|
999
|
+
# Updates a patient. The path must contain the next version number to prevent race
|
1000
|
+
# conditions. For example, if the current version of the patient is n, you will
|
1001
|
+
# need to send a request to this endpoint with `/{id}/n+1` to update the patient.
|
1002
|
+
# Updating historic versions is not supported.
|
999
1003
|
#
|
1000
1004
|
# @param id [String]
|
1001
1005
|
# @param version [String]
|
@@ -43,7 +43,7 @@ module CandidApiClient
|
|
43
43
|
# @return [Boolean] True if the object is deactivated. Deactivated objects are not returned in
|
44
44
|
# search results but are returned in all other endpoints including scan.
|
45
45
|
attr_reader :deactivated
|
46
|
-
# @return [Integer] The version of the object.
|
46
|
+
# @return [Integer] The version of the object. Any update to any property of an object object will
|
47
47
|
# create a new version.
|
48
48
|
attr_reader :version
|
49
49
|
# @return [DateTime]
|
@@ -144,7 +144,7 @@ module CandidApiClient
|
|
144
144
|
# @param organization_id [String] The organization that owns this object.
|
145
145
|
# @param deactivated [Boolean] True if the object is deactivated. Deactivated objects are not returned in
|
146
146
|
# search results but are returned in all other endpoints including scan.
|
147
|
-
# @param version [Integer] The version of the object.
|
147
|
+
# @param version [Integer] The version of the object. Any update to any property of an object object will
|
148
148
|
# create a new version.
|
149
149
|
# @param updated_at [DateTime]
|
150
150
|
# @param updating_user_id [String] The user ID of the user who last updated the object.
|
@@ -76,6 +76,8 @@ module CandidApiClient
|
|
76
76
|
#
|
77
77
|
# @param request [Hash] Request of type CandidApiClient::PreEncounter::Tags::V1::Types::MutableTag, as a Hash
|
78
78
|
# * :value (String)
|
79
|
+
# * :description (String)
|
80
|
+
# * :alert (Boolean)
|
79
81
|
# @param request_options [CandidApiClient::RequestOptions]
|
80
82
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::Tag]
|
81
83
|
# @example
|
@@ -102,6 +104,8 @@ module CandidApiClient
|
|
102
104
|
# @param version [String]
|
103
105
|
# @param request [Hash] Request of type CandidApiClient::PreEncounter::Tags::V1::Types::MutableTag, as a Hash
|
104
106
|
# * :value (String)
|
107
|
+
# * :description (String)
|
108
|
+
# * :alert (Boolean)
|
105
109
|
# @param request_options [CandidApiClient::RequestOptions]
|
106
110
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::Tag]
|
107
111
|
# @example
|
@@ -223,6 +227,8 @@ module CandidApiClient
|
|
223
227
|
#
|
224
228
|
# @param request [Hash] Request of type CandidApiClient::PreEncounter::Tags::V1::Types::MutableTag, as a Hash
|
225
229
|
# * :value (String)
|
230
|
+
# * :description (String)
|
231
|
+
# * :alert (Boolean)
|
226
232
|
# @param request_options [CandidApiClient::RequestOptions]
|
227
233
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::Tag]
|
228
234
|
# @example
|
@@ -252,6 +258,8 @@ module CandidApiClient
|
|
252
258
|
# @param version [String]
|
253
259
|
# @param request [Hash] Request of type CandidApiClient::PreEncounter::Tags::V1::Types::MutableTag, as a Hash
|
254
260
|
# * :value (String)
|
261
|
+
# * :description (String)
|
262
|
+
# * :alert (Boolean)
|
255
263
|
# @param request_options [CandidApiClient::RequestOptions]
|
256
264
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::Tag]
|
257
265
|
# @example
|
@@ -12,6 +12,10 @@ module CandidApiClient
|
|
12
12
|
class MutableTag
|
13
13
|
# @return [String]
|
14
14
|
attr_reader :value
|
15
|
+
# @return [String]
|
16
|
+
attr_reader :description
|
17
|
+
# @return [Boolean]
|
18
|
+
attr_reader :alert
|
15
19
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
16
20
|
attr_reader :additional_properties
|
17
21
|
# @return [Object]
|
@@ -21,12 +25,18 @@ module CandidApiClient
|
|
21
25
|
OMIT = Object.new
|
22
26
|
|
23
27
|
# @param value [String]
|
28
|
+
# @param description [String]
|
29
|
+
# @param alert [Boolean]
|
24
30
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
25
31
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::MutableTag]
|
26
|
-
def initialize(value:, additional_properties: nil)
|
32
|
+
def initialize(value:, description: OMIT, alert: OMIT, additional_properties: nil)
|
27
33
|
@value = value
|
34
|
+
@description = description if description != OMIT
|
35
|
+
@alert = alert if alert != OMIT
|
28
36
|
@additional_properties = additional_properties
|
29
|
-
@_field_set = { "value": value }
|
37
|
+
@_field_set = { "value": value, "description": description, "alert": alert }.reject do |_k, v|
|
38
|
+
v == OMIT
|
39
|
+
end
|
30
40
|
end
|
31
41
|
|
32
42
|
# Deserialize a JSON object to an instance of MutableTag
|
@@ -36,7 +46,14 @@ module CandidApiClient
|
|
36
46
|
def self.from_json(json_object:)
|
37
47
|
struct = JSON.parse(json_object, object_class: OpenStruct)
|
38
48
|
value = struct["value"]
|
39
|
-
|
49
|
+
description = struct["description"]
|
50
|
+
alert = struct["alert"]
|
51
|
+
new(
|
52
|
+
value: value,
|
53
|
+
description: description,
|
54
|
+
alert: alert,
|
55
|
+
additional_properties: struct
|
56
|
+
)
|
40
57
|
end
|
41
58
|
|
42
59
|
# Serialize an instance of MutableTag to a JSON object
|
@@ -54,6 +71,8 @@ module CandidApiClient
|
|
54
71
|
# @return [Void]
|
55
72
|
def self.validate_raw(obj:)
|
56
73
|
obj.value.is_a?(String) != false || raise("Passed value for field obj.value is not the expected type, validation failed.")
|
74
|
+
obj.description&.is_a?(String) != false || raise("Passed value for field obj.description is not the expected type, validation failed.")
|
75
|
+
obj.alert&.is_a?(Boolean) != false || raise("Passed value for field obj.alert is not the expected type, validation failed.")
|
57
76
|
end
|
58
77
|
end
|
59
78
|
end
|
@@ -18,7 +18,7 @@ module CandidApiClient
|
|
18
18
|
# @return [Boolean] True if the object is deactivated. Deactivated objects are not returned in
|
19
19
|
# search results but are returned in all other endpoints including scan.
|
20
20
|
attr_reader :deactivated
|
21
|
-
# @return [Integer] The version of the object.
|
21
|
+
# @return [Integer] The version of the object. Any update to any property of an object object will
|
22
22
|
# create a new version.
|
23
23
|
attr_reader :version
|
24
24
|
# @return [DateTime]
|
@@ -27,6 +27,10 @@ module CandidApiClient
|
|
27
27
|
attr_reader :updating_user_id
|
28
28
|
# @return [String]
|
29
29
|
attr_reader :value
|
30
|
+
# @return [String]
|
31
|
+
attr_reader :description
|
32
|
+
# @return [Boolean]
|
33
|
+
attr_reader :alert
|
30
34
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
31
35
|
attr_reader :additional_properties
|
32
36
|
# @return [Object]
|
@@ -39,15 +43,17 @@ module CandidApiClient
|
|
39
43
|
# @param organization_id [String] The organization that owns this object.
|
40
44
|
# @param deactivated [Boolean] True if the object is deactivated. Deactivated objects are not returned in
|
41
45
|
# search results but are returned in all other endpoints including scan.
|
42
|
-
# @param version [Integer] The version of the object.
|
46
|
+
# @param version [Integer] The version of the object. Any update to any property of an object object will
|
43
47
|
# create a new version.
|
44
48
|
# @param updated_at [DateTime]
|
45
49
|
# @param updating_user_id [String] The user ID of the user who last updated the object.
|
46
50
|
# @param value [String]
|
51
|
+
# @param description [String]
|
52
|
+
# @param alert [Boolean]
|
47
53
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
48
54
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::Tag]
|
49
55
|
def initialize(id:, organization_id:, deactivated:, version:, updated_at:, updating_user_id:, value:,
|
50
|
-
additional_properties: nil)
|
56
|
+
description: OMIT, alert: OMIT, additional_properties: nil)
|
51
57
|
@id = id
|
52
58
|
@organization_id = organization_id
|
53
59
|
@deactivated = deactivated
|
@@ -55,6 +61,8 @@ module CandidApiClient
|
|
55
61
|
@updated_at = updated_at
|
56
62
|
@updating_user_id = updating_user_id
|
57
63
|
@value = value
|
64
|
+
@description = description if description != OMIT
|
65
|
+
@alert = alert if alert != OMIT
|
58
66
|
@additional_properties = additional_properties
|
59
67
|
@_field_set = {
|
60
68
|
"id": id,
|
@@ -63,8 +71,12 @@ module CandidApiClient
|
|
63
71
|
"version": version,
|
64
72
|
"updated_at": updated_at,
|
65
73
|
"updating_user_id": updating_user_id,
|
66
|
-
"value": value
|
67
|
-
|
74
|
+
"value": value,
|
75
|
+
"description": description,
|
76
|
+
"alert": alert
|
77
|
+
}.reject do |_k, v|
|
78
|
+
v == OMIT
|
79
|
+
end
|
68
80
|
end
|
69
81
|
|
70
82
|
# Deserialize a JSON object to an instance of Tag
|
@@ -81,6 +93,8 @@ module CandidApiClient
|
|
81
93
|
updated_at = (DateTime.parse(parsed_json["updated_at"]) unless parsed_json["updated_at"].nil?)
|
82
94
|
updating_user_id = struct["updating_user_id"]
|
83
95
|
value = struct["value"]
|
96
|
+
description = struct["description"]
|
97
|
+
alert = struct["alert"]
|
84
98
|
new(
|
85
99
|
id: id,
|
86
100
|
organization_id: organization_id,
|
@@ -89,6 +103,8 @@ module CandidApiClient
|
|
89
103
|
updated_at: updated_at,
|
90
104
|
updating_user_id: updating_user_id,
|
91
105
|
value: value,
|
106
|
+
description: description,
|
107
|
+
alert: alert,
|
92
108
|
additional_properties: struct
|
93
109
|
)
|
94
110
|
end
|
@@ -114,6 +130,8 @@ module CandidApiClient
|
|
114
130
|
obj.updated_at.is_a?(DateTime) != false || raise("Passed value for field obj.updated_at is not the expected type, validation failed.")
|
115
131
|
obj.updating_user_id.is_a?(String) != false || raise("Passed value for field obj.updating_user_id is not the expected type, validation failed.")
|
116
132
|
obj.value.is_a?(String) != false || raise("Passed value for field obj.value is not the expected type, validation failed.")
|
133
|
+
obj.description&.is_a?(String) != false || raise("Passed value for field obj.description is not the expected type, validation failed.")
|
134
|
+
obj.alert&.is_a?(Boolean) != false || raise("Passed value for field obj.alert is not the expected type, validation failed.")
|
117
135
|
end
|
118
136
|
end
|
119
137
|
end
|