candidhealth 0.43.1 → 0.46.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/billing_notes/v_2/client.rb +2 -2
- data/lib/candidhealth/charge_capture/v_1/client.rb +479 -559
- data/lib/candidhealth/charge_capture/v_1/types/charge_capture_data.rb +200 -190
- data/lib/candidhealth/charge_capture_bundles/v_1/client.rb +2 -44
- data/lib/candidhealth/commons/types/street_address_optional_base.rb +99 -0
- data/lib/candidhealth/commons/types/street_address_short_zip_optional.rb +107 -0
- data/lib/candidhealth/contracts/v_2/client.rb +18 -34
- data/lib/candidhealth/contracts/v_2/types/contract_sort_field.rb +18 -0
- data/lib/candidhealth/credentialing/v_2/client.rb +6 -44
- data/lib/candidhealth/diagnoses/client.rb +4 -14
- data/lib/candidhealth/eligibility/v_2/client.rb +4 -4
- data/lib/candidhealth/encounter_attachments/v_1/client.rb +0 -6
- data/lib/candidhealth/encounter_providers/v_2/client.rb +16 -16
- data/lib/candidhealth/encounter_providers/v_2/types/billing_provider_update_with_optional_address.rb +160 -0
- data/lib/candidhealth/encounter_providers/v_2/types/initial_referring_provider_update_with_optional_address.rb +134 -0
- data/lib/candidhealth/encounter_providers/v_2/types/referring_provider_update_with_optional_address.rb +125 -0
- data/lib/candidhealth/encounter_providers/v_2/types/rendering_provider_update_with_optional_address.rb +125 -0
- data/lib/candidhealth/encounter_providers/v_2/types/supervising_provider_update_with_optional_address.rb +125 -0
- data/lib/candidhealth/encounters/v_4/client.rb +259 -293
- data/lib/candidhealth/encounters/v_4/types/encounter.rb +23 -13
- data/lib/candidhealth/encounters/v_4/types/encounter_base.rb +10 -10
- data/lib/candidhealth/encounters/v_4/types/encounter_create_from_pre_encounter.rb +10 -10
- data/lib/candidhealth/encounters/v_4/types/encounter_optional.rb +26 -184
- data/lib/candidhealth/expected_network_status/v_1/client.rb +12 -18
- data/lib/candidhealth/expected_network_status/v_2/client.rb +4 -4
- data/lib/candidhealth/expected_network_status/v_2/types/empty_object.rb +53 -0
- data/lib/candidhealth/expected_network_status/v_2/types/insurance_type_codes.rb +13 -10
- data/lib/candidhealth/external_payment_account_config/v_1/client.rb +2 -2
- data/lib/candidhealth/fee_schedules/v_3/client.rb +12 -68
- data/lib/candidhealth/fee_schedules/v_3/types/payer_threshold.rb +3 -3
- data/lib/candidhealth/fee_schedules/v_3/types/rate_entry.rb +2 -2
- data/lib/candidhealth/guarantor/v_1/client.rb +4 -4
- data/lib/candidhealth/import_invoice/v_1/client.rb +6 -28
- data/lib/candidhealth/individual/types/patient_update_with_optional_address.rb +179 -0
- data/lib/candidhealth/insurance_adjudications/v_1/client.rb +2 -2
- data/lib/candidhealth/insurance_payments/v_1/client.rb +2 -20
- data/lib/candidhealth/insurance_refunds/v_1/client.rb +6 -24
- data/lib/candidhealth/medication_dispense/v_1/client.rb +2 -2
- data/lib/candidhealth/non_insurance_payer_payments/v_1/client.rb +6 -22
- data/lib/candidhealth/non_insurance_payer_refunds/v_1/client.rb +6 -22
- data/lib/candidhealth/non_insurance_payers/v_1/client.rb +6 -22
- data/lib/candidhealth/organization_providers/v_3/client.rb +4 -4
- data/lib/candidhealth/organization_service_facilities/v_2/client.rb +2 -2
- data/lib/candidhealth/patient_payments/v_4/client.rb +8 -38
- data/lib/candidhealth/patient_refunds/v_1/client.rb +8 -40
- data/lib/candidhealth/payer_plan_groups/v_1/client.rb +6 -30
- data/lib/candidhealth/pre_encounter/appointments/v_1/client.rb +32 -44
- data/lib/candidhealth/pre_encounter/appointments/v_1/types/appointment.rb +4 -4
- data/lib/candidhealth/pre_encounter/common/types/base_model.rb +4 -4
- data/lib/candidhealth/pre_encounter/coverages/v_1/client.rb +24 -34
- data/lib/candidhealth/pre_encounter/coverages/v_1/types/coverage.rb +4 -4
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/client.rb +2 -2
- data/lib/candidhealth/pre_encounter/images/v_1/client.rb +20 -20
- data/lib/candidhealth/pre_encounter/images/v_1/types/image.rb +6 -6
- data/lib/candidhealth/pre_encounter/lists/v_1/client.rb +4 -28
- data/lib/candidhealth/pre_encounter/notes/v_1/client.rb +14 -14
- data/lib/candidhealth/pre_encounter/notes/v_1/types/note.rb +4 -4
- data/lib/candidhealth/pre_encounter/patients/v_1/client.rb +56 -68
- data/lib/candidhealth/pre_encounter/patients/v_1/types/mutable_patient.rb +8 -8
- data/lib/candidhealth/pre_encounter/patients/v_1/types/mutable_patient_with_mrn.rb +8 -8
- data/lib/candidhealth/pre_encounter/patients/v_1/types/patient.rb +16 -16
- data/lib/candidhealth/pre_encounter/tags/v_1/client.rb +16 -16
- data/lib/candidhealth/pre_encounter/tags/v_1/types/tag.rb +4 -4
- data/lib/candidhealth/service_facility/client.rb +2 -2
- data/lib/candidhealth/service_facility/types/encounter_service_facility_update_with_optional_address.rb +113 -0
- data/lib/candidhealth/service_lines/v_2/client.rb +4 -4
- data/lib/candidhealth/superbills/v_1/client.rb +4 -6
- data/lib/candidhealth/tasks/v_3/client.rb +6 -34
- data/lib/candidhealth/write_offs/v_1/client.rb +2 -24
- data/lib/environment.rb +4 -0
- data/lib/requests.rb +2 -2
- data/lib/types_export.rb +11 -1
- metadata +13 -3
- data/lib/candidhealth/billing_notes/v_2/types/billing_note_optional.rb +0 -112
@@ -31,19 +31,19 @@ module CandidApiClient
|
|
31
31
|
module Types
|
32
32
|
# A patient object with immutable server-owned properties.
|
33
33
|
class Patient
|
34
|
-
# @return [String] The unique UUID identifier for a Patient.
|
34
|
+
# @return [String] The unique UUID identifier for a Patient. Patient ID is used in machine
|
35
35
|
# contexts.
|
36
36
|
attr_reader :id
|
37
|
-
# @return [String] The medical record number for the patient.
|
37
|
+
# @return [String] The medical record number for the patient. Human-friendly Candid generated MRNs
|
38
38
|
# are of the form "YYMMDDXXXX", where "YYYYMMDD" is the date of patient creation
|
39
39
|
# and "XXXX" is a zero-padded incrementing integer.
|
40
40
|
attr_reader :mrn
|
41
41
|
# @return [String] The organization that owns this object.
|
42
42
|
attr_reader :organization_id
|
43
|
-
# @return [Boolean] True if the object is deactivated.
|
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]
|
@@ -78,10 +78,10 @@ module CandidApiClient
|
|
78
78
|
attr_reader :disability_status
|
79
79
|
# @return [CandidApiClient::PreEncounter::Patients::V1::Types::MaritalStatus]
|
80
80
|
attr_reader :marital_status
|
81
|
-
# @return [DateTime] Time of death for the patient.
|
81
|
+
# @return [DateTime] Time of death for the patient. Leave unset if the patient is not deceased.
|
82
82
|
attr_reader :deceased
|
83
|
-
# @return [Integer] The number of siblings the patient was born with.
|
84
|
-
# not part of a multiple birth.
|
83
|
+
# @return [Integer] The number of siblings the patient was born with. Leave unset if the patient
|
84
|
+
# was not part of a multiple birth.
|
85
85
|
attr_reader :multiple_birth
|
86
86
|
# @return [CandidApiClient::PreEncounter::Common::Types::Address] The primary address for the patient.
|
87
87
|
attr_reader :primary_address
|
@@ -99,7 +99,7 @@ module CandidApiClient
|
|
99
99
|
attr_reader :photo
|
100
100
|
# @return [String]
|
101
101
|
attr_reader :language
|
102
|
-
# @return [CandidApiClient::PreEncounter::Patients::V1::Types::ExternalProvenance] Information about the upstream system that owns this patient data.
|
102
|
+
# @return [CandidApiClient::PreEncounter::Patients::V1::Types::ExternalProvenance] Information about the upstream system that owns this patient data. Leave unset
|
103
103
|
# if Candid owns patient data.
|
104
104
|
attr_reader :external_provenance
|
105
105
|
# @return [Array<CandidApiClient::PreEncounter::Patients::V1::Types::Contact>] Contacts for the patient.
|
@@ -136,15 +136,15 @@ module CandidApiClient
|
|
136
136
|
|
137
137
|
OMIT = Object.new
|
138
138
|
|
139
|
-
# @param id [String] The unique UUID identifier for a Patient.
|
139
|
+
# @param id [String] The unique UUID identifier for a Patient. Patient ID is used in machine
|
140
140
|
# contexts.
|
141
|
-
# @param mrn [String] The medical record number for the patient.
|
141
|
+
# @param mrn [String] The medical record number for the patient. Human-friendly Candid generated MRNs
|
142
142
|
# are of the form "YYMMDDXXXX", where "YYYYMMDD" is the date of patient creation
|
143
143
|
# and "XXXX" is a zero-padded incrementing integer.
|
144
144
|
# @param organization_id [String] The organization that owns this object.
|
145
|
-
# @param deactivated [Boolean] True if the object is deactivated.
|
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.
|
@@ -163,9 +163,9 @@ module CandidApiClient
|
|
163
163
|
# @param ethnicity [CandidApiClient::PreEncounter::Common::Types::Ethnicity]
|
164
164
|
# @param disability_status [CandidApiClient::PreEncounter::Common::Types::DisabilityStatus]
|
165
165
|
# @param marital_status [CandidApiClient::PreEncounter::Patients::V1::Types::MaritalStatus]
|
166
|
-
# @param deceased [DateTime] Time of death for the patient.
|
167
|
-
# @param multiple_birth [Integer] The number of siblings the patient was born with.
|
168
|
-
# not part of a multiple birth.
|
166
|
+
# @param deceased [DateTime] Time of death for the patient. Leave unset if the patient is not deceased.
|
167
|
+
# @param multiple_birth [Integer] The number of siblings the patient was born with. Leave unset if the patient
|
168
|
+
# was not part of a multiple birth.
|
169
169
|
# @param primary_address [CandidApiClient::PreEncounter::Common::Types::Address] The primary address for the patient.
|
170
170
|
# @param other_addresses [Array<CandidApiClient::PreEncounter::Common::Types::Address>] Other addresses for the patient.
|
171
171
|
# @param primary_telecom [CandidApiClient::PreEncounter::Common::Types::ContactPoint] The primary phone number for the patient.
|
@@ -174,7 +174,7 @@ module CandidApiClient
|
|
174
174
|
# @param electronic_communication_opt_in [Boolean]
|
175
175
|
# @param photo [String]
|
176
176
|
# @param language [String]
|
177
|
-
# @param external_provenance [CandidApiClient::PreEncounter::Patients::V1::Types::ExternalProvenance] Information about the upstream system that owns this patient data.
|
177
|
+
# @param external_provenance [CandidApiClient::PreEncounter::Patients::V1::Types::ExternalProvenance] Information about the upstream system that owns this patient data. Leave unset
|
178
178
|
# if Candid owns patient data.
|
179
179
|
# @param contacts [Array<CandidApiClient::PreEncounter::Patients::V1::Types::Contact>] Contacts for the patient.
|
180
180
|
# @param general_practitioners [Array<CandidApiClient::PreEncounter::Common::Types::ExternalProvider>]
|
@@ -27,7 +27,7 @@ module CandidApiClient
|
|
27
27
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::Tag]
|
28
28
|
# @example
|
29
29
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
30
|
-
# api.pre_encounter.tags.v_1.get(id: "
|
30
|
+
# api.pre_encounter.tags.v_1.get(id: "id")
|
31
31
|
def get(id:, request_options: nil)
|
32
32
|
response = @request_client.conn.get do |req|
|
33
33
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -51,7 +51,7 @@ module CandidApiClient
|
|
51
51
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::TagPage]
|
52
52
|
# @example
|
53
53
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
54
|
-
# api.pre_encounter.tags.v_1.get_all
|
54
|
+
# api.pre_encounter.tags.v_1.get_all
|
55
55
|
def get_all(limit: nil, page_token: nil, request_options: nil)
|
56
56
|
response = @request_client.conn.get do |req|
|
57
57
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -80,7 +80,7 @@ module CandidApiClient
|
|
80
80
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::Tag]
|
81
81
|
# @example
|
82
82
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
83
|
-
# api.pre_encounter.tags.v_1.create(request: { value: "
|
83
|
+
# api.pre_encounter.tags.v_1.create(request: { value: "value" })
|
84
84
|
def create(request:, request_options: nil)
|
85
85
|
response = @request_client.conn.post do |req|
|
86
86
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -107,9 +107,9 @@ module CandidApiClient
|
|
107
107
|
# @example
|
108
108
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
109
109
|
# api.pre_encounter.tags.v_1.update(
|
110
|
-
# id: "
|
111
|
-
# version: "
|
112
|
-
# request: { value: "
|
110
|
+
# id: "id",
|
111
|
+
# version: "version",
|
112
|
+
# request: { value: "value" }
|
113
113
|
# )
|
114
114
|
def update(id:, version:, request:, request_options: nil)
|
115
115
|
response = @request_client.conn.put do |req|
|
@@ -127,7 +127,7 @@ module CandidApiClient
|
|
127
127
|
CandidApiClient::PreEncounter::Tags::V1::Types::Tag.from_json(json_object: response.body)
|
128
128
|
end
|
129
129
|
|
130
|
-
# Sets a tag as deactivated.
|
130
|
+
# Sets a tag as deactivated. The path must contain the most recent version to
|
131
131
|
# prevent races.
|
132
132
|
#
|
133
133
|
# @param id [String]
|
@@ -136,7 +136,7 @@ module CandidApiClient
|
|
136
136
|
# @return [Void]
|
137
137
|
# @example
|
138
138
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
139
|
-
# api.pre_encounter.tags.v_1.deactivate(id: "
|
139
|
+
# api.pre_encounter.tags.v_1.deactivate(id: "id", version: "version")
|
140
140
|
def deactivate(id:, version:, request_options: nil)
|
141
141
|
@request_client.conn.delete do |req|
|
142
142
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -169,7 +169,7 @@ module CandidApiClient
|
|
169
169
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::Tag]
|
170
170
|
# @example
|
171
171
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
172
|
-
# api.pre_encounter.tags.v_1.get(id: "
|
172
|
+
# api.pre_encounter.tags.v_1.get(id: "id")
|
173
173
|
def get(id:, request_options: nil)
|
174
174
|
Async do
|
175
175
|
response = @request_client.conn.get do |req|
|
@@ -195,7 +195,7 @@ module CandidApiClient
|
|
195
195
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::TagPage]
|
196
196
|
# @example
|
197
197
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
198
|
-
# api.pre_encounter.tags.v_1.get_all
|
198
|
+
# api.pre_encounter.tags.v_1.get_all
|
199
199
|
def get_all(limit: nil, page_token: nil, request_options: nil)
|
200
200
|
Async do
|
201
201
|
response = @request_client.conn.get do |req|
|
@@ -227,7 +227,7 @@ module CandidApiClient
|
|
227
227
|
# @return [CandidApiClient::PreEncounter::Tags::V1::Types::Tag]
|
228
228
|
# @example
|
229
229
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
230
|
-
# api.pre_encounter.tags.v_1.create(request: { value: "
|
230
|
+
# api.pre_encounter.tags.v_1.create(request: { value: "value" })
|
231
231
|
def create(request:, request_options: nil)
|
232
232
|
Async do
|
233
233
|
response = @request_client.conn.post do |req|
|
@@ -257,9 +257,9 @@ module CandidApiClient
|
|
257
257
|
# @example
|
258
258
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
259
259
|
# api.pre_encounter.tags.v_1.update(
|
260
|
-
# id: "
|
261
|
-
# version: "
|
262
|
-
# request: { value: "
|
260
|
+
# id: "id",
|
261
|
+
# version: "version",
|
262
|
+
# request: { value: "value" }
|
263
263
|
# )
|
264
264
|
def update(id:, version:, request:, request_options: nil)
|
265
265
|
Async do
|
@@ -279,7 +279,7 @@ module CandidApiClient
|
|
279
279
|
end
|
280
280
|
end
|
281
281
|
|
282
|
-
# Sets a tag as deactivated.
|
282
|
+
# Sets a tag as deactivated. The path must contain the most recent version to
|
283
283
|
# prevent races.
|
284
284
|
#
|
285
285
|
# @param id [String]
|
@@ -288,7 +288,7 @@ module CandidApiClient
|
|
288
288
|
# @return [Void]
|
289
289
|
# @example
|
290
290
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
291
|
-
# api.pre_encounter.tags.v_1.deactivate(id: "
|
291
|
+
# api.pre_encounter.tags.v_1.deactivate(id: "id", version: "version")
|
292
292
|
def deactivate(id:, version:, request_options: nil)
|
293
293
|
Async do
|
294
294
|
@request_client.conn.delete do |req|
|
@@ -15,10 +15,10 @@ module CandidApiClient
|
|
15
15
|
attr_reader :id
|
16
16
|
# @return [String] The organization that owns this object.
|
17
17
|
attr_reader :organization_id
|
18
|
-
# @return [Boolean] True if the object is deactivated.
|
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]
|
@@ -37,9 +37,9 @@ module CandidApiClient
|
|
37
37
|
|
38
38
|
# @param id [String]
|
39
39
|
# @param organization_id [String] The organization that owns this object.
|
40
|
-
# @param deactivated [Boolean] True if the object is deactivated.
|
40
|
+
# @param deactivated [Boolean] True if the object is deactivated. Deactivated objects are not returned in
|
41
41
|
# search results but are returned in all other endpoints including scan.
|
42
|
-
# @param version [Integer] The version of the object.
|
42
|
+
# @param version [Integer] The version of the object. Any update to any property of an object object will
|
43
43
|
# create a new version.
|
44
44
|
# @param updated_at [DateTime]
|
45
45
|
# @param updating_user_id [String] The user ID of the user who last updated the object.
|
@@ -32,7 +32,7 @@ module CandidApiClient
|
|
32
32
|
# @return [CandidApiClient::ServiceFacility::Types::EncounterServiceFacility]
|
33
33
|
# @example
|
34
34
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
35
|
-
# api.service_facility.update(service_facility_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: {
|
35
|
+
# api.service_facility.update(service_facility_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: { })
|
36
36
|
def update(service_facility_id:, request:, request_options: nil)
|
37
37
|
response = @request_client.conn.patch do |req|
|
38
38
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -76,7 +76,7 @@ module CandidApiClient
|
|
76
76
|
# @return [CandidApiClient::ServiceFacility::Types::EncounterServiceFacility]
|
77
77
|
# @example
|
78
78
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
79
|
-
# api.service_facility.update(service_facility_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: {
|
79
|
+
# api.service_facility.update(service_facility_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: { })
|
80
80
|
def update(service_facility_id:, request:, request_options: nil)
|
81
81
|
Async do
|
82
82
|
response = @request_client.conn.patch do |req|
|
@@ -0,0 +1,113 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "../../commons/types/street_address_short_zip_optional"
|
4
|
+
require "ostruct"
|
5
|
+
require "json"
|
6
|
+
|
7
|
+
module CandidApiClient
|
8
|
+
module ServiceFacility
|
9
|
+
module Types
|
10
|
+
class EncounterServiceFacilityUpdateWithOptionalAddress
|
11
|
+
# @return [String]
|
12
|
+
attr_reader :organization_name
|
13
|
+
# @return [String] An NPI specific to the service facility if applicable, i.e. if it has one and is
|
14
|
+
# not under the billing provider's NPI.
|
15
|
+
# Box 32 section (a) of the CMS-1500 claim form.
|
16
|
+
attr_reader :npi
|
17
|
+
# @return [CandidApiClient::Commons::Types::StreetAddressShortZipOptional] zip_plus_four_code is required for service facility address. When the
|
18
|
+
# zip_plus_four_code is not available use "9998" as per CMS documentation.
|
19
|
+
attr_reader :address
|
20
|
+
# @return [String] An additional identifier for the service facility other than the facility's NPI.
|
21
|
+
# Some payers may require this field.
|
22
|
+
# Potential examples: state license number, provider commercial number, or
|
23
|
+
# location number.
|
24
|
+
# Box 32 section (b) of the CMS-1500 claim form.
|
25
|
+
attr_reader :secondary_identification
|
26
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
27
|
+
attr_reader :additional_properties
|
28
|
+
# @return [Object]
|
29
|
+
attr_reader :_field_set
|
30
|
+
protected :_field_set
|
31
|
+
|
32
|
+
OMIT = Object.new
|
33
|
+
|
34
|
+
# @param organization_name [String]
|
35
|
+
# @param npi [String] An NPI specific to the service facility if applicable, i.e. if it has one and is
|
36
|
+
# not under the billing provider's NPI.
|
37
|
+
# Box 32 section (a) of the CMS-1500 claim form.
|
38
|
+
# @param address [CandidApiClient::Commons::Types::StreetAddressShortZipOptional] zip_plus_four_code is required for service facility address. When the
|
39
|
+
# zip_plus_four_code is not available use "9998" as per CMS documentation.
|
40
|
+
# @param secondary_identification [String] An additional identifier for the service facility other than the facility's NPI.
|
41
|
+
# Some payers may require this field.
|
42
|
+
# Potential examples: state license number, provider commercial number, or
|
43
|
+
# location number.
|
44
|
+
# Box 32 section (b) of the CMS-1500 claim form.
|
45
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
46
|
+
# @return [CandidApiClient::ServiceFacility::Types::EncounterServiceFacilityUpdateWithOptionalAddress]
|
47
|
+
def initialize(organization_name: OMIT, npi: OMIT, address: OMIT, secondary_identification: OMIT,
|
48
|
+
additional_properties: nil)
|
49
|
+
@organization_name = organization_name if organization_name != OMIT
|
50
|
+
@npi = npi if npi != OMIT
|
51
|
+
@address = address if address != OMIT
|
52
|
+
@secondary_identification = secondary_identification if secondary_identification != OMIT
|
53
|
+
@additional_properties = additional_properties
|
54
|
+
@_field_set = {
|
55
|
+
"organization_name": organization_name,
|
56
|
+
"npi": npi,
|
57
|
+
"address": address,
|
58
|
+
"secondary_identification": secondary_identification
|
59
|
+
}.reject do |_k, v|
|
60
|
+
v == OMIT
|
61
|
+
end
|
62
|
+
end
|
63
|
+
|
64
|
+
# Deserialize a JSON object to an instance of
|
65
|
+
# EncounterServiceFacilityUpdateWithOptionalAddress
|
66
|
+
#
|
67
|
+
# @param json_object [String]
|
68
|
+
# @return [CandidApiClient::ServiceFacility::Types::EncounterServiceFacilityUpdateWithOptionalAddress]
|
69
|
+
def self.from_json(json_object:)
|
70
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
71
|
+
parsed_json = JSON.parse(json_object)
|
72
|
+
organization_name = struct["organization_name"]
|
73
|
+
npi = struct["npi"]
|
74
|
+
if parsed_json["address"].nil?
|
75
|
+
address = nil
|
76
|
+
else
|
77
|
+
address = parsed_json["address"].to_json
|
78
|
+
address = CandidApiClient::Commons::Types::StreetAddressShortZipOptional.from_json(json_object: address)
|
79
|
+
end
|
80
|
+
secondary_identification = struct["secondary_identification"]
|
81
|
+
new(
|
82
|
+
organization_name: organization_name,
|
83
|
+
npi: npi,
|
84
|
+
address: address,
|
85
|
+
secondary_identification: secondary_identification,
|
86
|
+
additional_properties: struct
|
87
|
+
)
|
88
|
+
end
|
89
|
+
|
90
|
+
# Serialize an instance of EncounterServiceFacilityUpdateWithOptionalAddress to a
|
91
|
+
# JSON object
|
92
|
+
#
|
93
|
+
# @return [String]
|
94
|
+
def to_json(*_args)
|
95
|
+
@_field_set&.to_json
|
96
|
+
end
|
97
|
+
|
98
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
99
|
+
# hash and check each fields type against the current object's property
|
100
|
+
# definitions.
|
101
|
+
#
|
102
|
+
# @param obj [Object]
|
103
|
+
# @return [Void]
|
104
|
+
def self.validate_raw(obj:)
|
105
|
+
obj.organization_name&.is_a?(String) != false || raise("Passed value for field obj.organization_name is not the expected type, validation failed.")
|
106
|
+
obj.npi&.is_a?(String) != false || raise("Passed value for field obj.npi is not the expected type, validation failed.")
|
107
|
+
obj.address.nil? || CandidApiClient::Commons::Types::StreetAddressShortZipOptional.validate_raw(obj: obj.address)
|
108
|
+
obj.secondary_identification&.is_a?(String) != false || raise("Passed value for field obj.secondary_identification is not the expected type, validation failed.")
|
109
|
+
end
|
110
|
+
end
|
111
|
+
end
|
112
|
+
end
|
113
|
+
end
|
@@ -65,7 +65,7 @@ module CandidApiClient
|
|
65
65
|
# @return [CandidApiClient::ServiceLines::V2::Types::ServiceLine]
|
66
66
|
# @example
|
67
67
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
68
|
-
# api.service_lines.v_2.create(request: {
|
68
|
+
# api.service_lines.v_2.create(request: { procedure_code: "procedure_code", quantity: "quantity", units: MJ, claim_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32" })
|
69
69
|
def create(request:, request_options: nil)
|
70
70
|
response = @request_client.conn.post do |req|
|
71
71
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -116,7 +116,7 @@ module CandidApiClient
|
|
116
116
|
# @return [CandidApiClient::ServiceLines::V2::Types::ServiceLine]
|
117
117
|
# @example
|
118
118
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
119
|
-
# api.service_lines.v_2.update(service_line_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: {
|
119
|
+
# api.service_lines.v_2.update(service_line_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: { })
|
120
120
|
def update(service_line_id:, request:, request_options: nil)
|
121
121
|
response = @request_client.conn.patch do |req|
|
122
122
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -210,7 +210,7 @@ module CandidApiClient
|
|
210
210
|
# @return [CandidApiClient::ServiceLines::V2::Types::ServiceLine]
|
211
211
|
# @example
|
212
212
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
213
|
-
# api.service_lines.v_2.create(request: {
|
213
|
+
# api.service_lines.v_2.create(request: { procedure_code: "procedure_code", quantity: "quantity", units: MJ, claim_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32" })
|
214
214
|
def create(request:, request_options: nil)
|
215
215
|
Async do
|
216
216
|
response = @request_client.conn.post do |req|
|
@@ -263,7 +263,7 @@ module CandidApiClient
|
|
263
263
|
# @return [CandidApiClient::ServiceLines::V2::Types::ServiceLine]
|
264
264
|
# @example
|
265
265
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
266
|
-
# api.service_lines.v_2.update(service_line_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: {
|
266
|
+
# api.service_lines.v_2.update(service_line_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: { })
|
267
267
|
def update(service_line_id:, request:, request_options: nil)
|
268
268
|
Async do
|
269
269
|
response = @request_client.conn.patch do |req|
|
@@ -35,10 +35,9 @@ module CandidApiClient
|
|
35
35
|
# @example
|
36
36
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
37
37
|
# api.superbills.v_1.create_superbill(
|
38
|
-
# patient_external_id: "
|
38
|
+
# patient_external_id: "patient_external_id",
|
39
39
|
# date_range_min: DateTime.parse(2023-01-15),
|
40
|
-
# date_range_max: DateTime.parse(2023-01-15)
|
41
|
-
# pay_to_address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }
|
40
|
+
# date_range_max: DateTime.parse(2023-01-15)
|
42
41
|
# )
|
43
42
|
def create_superbill(patient_external_id:, date_range_min:, date_range_max:, pay_to_address: nil,
|
44
43
|
request_options: nil)
|
@@ -90,10 +89,9 @@ module CandidApiClient
|
|
90
89
|
# @example
|
91
90
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
92
91
|
# api.superbills.v_1.create_superbill(
|
93
|
-
# patient_external_id: "
|
92
|
+
# patient_external_id: "patient_external_id",
|
94
93
|
# date_range_min: DateTime.parse(2023-01-15),
|
95
|
-
# date_range_max: DateTime.parse(2023-01-15)
|
96
|
-
# pay_to_address: { address_1: "123 Main St", address_2: "Apt 1", city: "New York", state: NY, zip_code: "10001", zip_plus_four_code: "1234" }
|
94
|
+
# date_range_max: DateTime.parse(2023-01-15)
|
97
95
|
# )
|
98
96
|
def create_superbill(patient_external_id:, date_range_min:, date_range_max:, pay_to_address: nil,
|
99
97
|
request_options: nil)
|
@@ -63,21 +63,7 @@ module CandidApiClient
|
|
63
63
|
# @return [CandidApiClient::Tasks::V3::Types::TaskPage]
|
64
64
|
# @example
|
65
65
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
66
|
-
# api.tasks.v_3.get_multi
|
67
|
-
# limit: 1,
|
68
|
-
# page_token: "eyJ0b2tlbiI6IjEiLCJwYWdlX3Rva2VuIjoiMiJ9",
|
69
|
-
# status: FINISHED,
|
70
|
-
# task_type: CUSTOMER_DATA_REQUEST,
|
71
|
-
# categories: "string",
|
72
|
-
# updated_since: DateTime.parse(2024-01-15T09:30:00.000Z),
|
73
|
-
# encounter_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
74
|
-
# search_term: "string",
|
75
|
-
# assigned_to_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
76
|
-
# date_of_service_min: DateTime.parse(2023-01-15),
|
77
|
-
# date_of_service_max: DateTime.parse(2023-01-15),
|
78
|
-
# billing_provider_npi: "string",
|
79
|
-
# sort: UPDATED_AT_ASC
|
80
|
-
# )
|
66
|
+
# api.tasks.v_3.get_multi
|
81
67
|
def get_multi(limit: nil, page_token: nil, status: nil, task_type: nil, categories: nil, updated_since: nil,
|
82
68
|
encounter_id: nil, search_term: nil, assigned_to_id: nil, date_of_service_min: nil, date_of_service_max: nil, billing_provider_npi: nil, sort: nil, request_options: nil)
|
83
69
|
response = @request_client.conn.get do |req|
|
@@ -142,7 +128,7 @@ module CandidApiClient
|
|
142
128
|
# @return [CandidApiClient::Tasks::V3::Types::Task]
|
143
129
|
# @example
|
144
130
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
145
|
-
# api.tasks.v_3.create(request: { encounter_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", task_type: CUSTOMER_DATA_REQUEST, description: "
|
131
|
+
# api.tasks.v_3.create(request: { encounter_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", task_type: CUSTOMER_DATA_REQUEST, description: "description", work_queue_id: "work_queue_id" })
|
146
132
|
def create(request:, request_options: nil)
|
147
133
|
response = @request_client.conn.post do |req|
|
148
134
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -167,7 +153,7 @@ module CandidApiClient
|
|
167
153
|
# @return [CandidApiClient::Tasks::V3::Types::Task]
|
168
154
|
# @example
|
169
155
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
170
|
-
# api.tasks.v_3.update(task_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: {
|
156
|
+
# api.tasks.v_3.update(task_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: { })
|
171
157
|
def update(task_id:, request:, request_options: nil)
|
172
158
|
response = @request_client.conn.patch do |req|
|
173
159
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -235,21 +221,7 @@ module CandidApiClient
|
|
235
221
|
# @return [CandidApiClient::Tasks::V3::Types::TaskPage]
|
236
222
|
# @example
|
237
223
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
238
|
-
# api.tasks.v_3.get_multi
|
239
|
-
# limit: 1,
|
240
|
-
# page_token: "eyJ0b2tlbiI6IjEiLCJwYWdlX3Rva2VuIjoiMiJ9",
|
241
|
-
# status: FINISHED,
|
242
|
-
# task_type: CUSTOMER_DATA_REQUEST,
|
243
|
-
# categories: "string",
|
244
|
-
# updated_since: DateTime.parse(2024-01-15T09:30:00.000Z),
|
245
|
-
# encounter_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
246
|
-
# search_term: "string",
|
247
|
-
# assigned_to_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
248
|
-
# date_of_service_min: DateTime.parse(2023-01-15),
|
249
|
-
# date_of_service_max: DateTime.parse(2023-01-15),
|
250
|
-
# billing_provider_npi: "string",
|
251
|
-
# sort: UPDATED_AT_ASC
|
252
|
-
# )
|
224
|
+
# api.tasks.v_3.get_multi
|
253
225
|
def get_multi(limit: nil, page_token: nil, status: nil, task_type: nil, categories: nil, updated_since: nil,
|
254
226
|
encounter_id: nil, search_term: nil, assigned_to_id: nil, date_of_service_min: nil, date_of_service_max: nil, billing_provider_npi: nil, sort: nil, request_options: nil)
|
255
227
|
Async do
|
@@ -319,7 +291,7 @@ module CandidApiClient
|
|
319
291
|
# @return [CandidApiClient::Tasks::V3::Types::Task]
|
320
292
|
# @example
|
321
293
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
322
|
-
# api.tasks.v_3.create(request: { encounter_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", task_type: CUSTOMER_DATA_REQUEST, description: "
|
294
|
+
# api.tasks.v_3.create(request: { encounter_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", task_type: CUSTOMER_DATA_REQUEST, description: "description", work_queue_id: "work_queue_id" })
|
323
295
|
def create(request:, request_options: nil)
|
324
296
|
Async do
|
325
297
|
response = @request_client.conn.post do |req|
|
@@ -347,7 +319,7 @@ module CandidApiClient
|
|
347
319
|
# @return [CandidApiClient::Tasks::V3::Types::Task]
|
348
320
|
# @example
|
349
321
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
350
|
-
# api.tasks.v_3.update(task_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: {
|
322
|
+
# api.tasks.v_3.update(task_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", request: { })
|
351
323
|
def update(task_id:, request:, request_options: nil)
|
352
324
|
Async do
|
353
325
|
response = @request_client.conn.patch do |req|
|
@@ -40,18 +40,7 @@ module CandidApiClient
|
|
40
40
|
# @return [CandidApiClient::WriteOffs::V1::Types::WriteOffsPage]
|
41
41
|
# @example
|
42
42
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
43
|
-
# api.write_offs.v_1.get_multi
|
44
|
-
# limit: 1,
|
45
|
-
# patient_external_id: "string",
|
46
|
-
# payer_uuid: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
47
|
-
# service_line_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
48
|
-
# claim_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
49
|
-
# billing_provider_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
50
|
-
# sort: AMOUNT_CENTS,
|
51
|
-
# sort_direction: ASC,
|
52
|
-
# page_token: "eyJ0b2tlbiI6IjEiLCJwYWdlX3Rva2VuIjoiMiJ9",
|
53
|
-
# account_types: PATIENT
|
54
|
-
# )
|
43
|
+
# api.write_offs.v_1.get_multi
|
55
44
|
def get_multi(limit: nil, patient_external_id: nil, payer_uuid: nil, service_line_id: nil, claim_id: nil,
|
56
45
|
billing_provider_id: nil, sort: nil, sort_direction: nil, page_token: nil, account_types: nil, request_options: nil)
|
57
46
|
response = @request_client.conn.get do |req|
|
@@ -225,18 +214,7 @@ module CandidApiClient
|
|
225
214
|
# @return [CandidApiClient::WriteOffs::V1::Types::WriteOffsPage]
|
226
215
|
# @example
|
227
216
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
228
|
-
# api.write_offs.v_1.get_multi
|
229
|
-
# limit: 1,
|
230
|
-
# patient_external_id: "string",
|
231
|
-
# payer_uuid: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
232
|
-
# service_line_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
233
|
-
# claim_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
234
|
-
# billing_provider_id: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32",
|
235
|
-
# sort: AMOUNT_CENTS,
|
236
|
-
# sort_direction: ASC,
|
237
|
-
# page_token: "eyJ0b2tlbiI6IjEiLCJwYWdlX3Rva2VuIjoiMiJ9",
|
238
|
-
# account_types: PATIENT
|
239
|
-
# )
|
217
|
+
# api.write_offs.v_1.get_multi
|
240
218
|
def get_multi(limit: nil, patient_external_id: nil, payer_uuid: nil, service_line_id: nil, claim_id: nil,
|
241
219
|
billing_provider_id: nil, sort: nil, sort_direction: nil, page_token: nil, account_types: nil, request_options: nil)
|
242
220
|
Async do
|
data/lib/environment.rb
CHANGED
@@ -10,5 +10,9 @@ module CandidApiClient
|
|
10
10
|
CandidApi: "https://api-staging.joincandidhealth.com",
|
11
11
|
PreEncounter: "https://pre-api-staging.joincandidhealth.com"
|
12
12
|
}.freeze
|
13
|
+
CANDID_STAGING = {
|
14
|
+
CandidApi: "https://staging-api.joincandidhealth.com",
|
15
|
+
PreEncounter: "https://staging-pre-api.joincandidhealth.com"
|
16
|
+
}.freeze
|
13
17
|
end
|
14
18
|
end
|
data/lib/requests.rb
CHANGED
@@ -45,7 +45,7 @@ module CandidApiClient
|
|
45
45
|
|
46
46
|
# @return [Hash{String => String}]
|
47
47
|
def get_headers
|
48
|
-
headers = { "X-Fern-Language": "Ruby", "X-Fern-SDK-Name": "candidhealth", "X-Fern-SDK-Version": "0.
|
48
|
+
headers = { "X-Fern-Language": "Ruby", "X-Fern-SDK-Name": "candidhealth", "X-Fern-SDK-Version": "0.46.0" }
|
49
49
|
headers["Authorization"] = ((@token.is_a? Method) ? @token.call : @token) unless token.nil?
|
50
50
|
headers
|
51
51
|
end
|
@@ -90,7 +90,7 @@ module CandidApiClient
|
|
90
90
|
|
91
91
|
# @return [Hash{String => String}]
|
92
92
|
def get_headers
|
93
|
-
headers = { "X-Fern-Language": "Ruby", "X-Fern-SDK-Name": "candidhealth", "X-Fern-SDK-Version": "0.
|
93
|
+
headers = { "X-Fern-Language": "Ruby", "X-Fern-SDK-Name": "candidhealth", "X-Fern-SDK-Version": "0.46.0" }
|
94
94
|
headers["Authorization"] = ((@token.is_a? Method) ? @token.call : @token) unless token.nil?
|
95
95
|
headers
|
96
96
|
end
|