candidhealth 1.4.0 → 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/contracts/v_2/client.rb +4 -4
- data/lib/candidhealth/diagnoses/types/disallow_multiple_primary_diagnosis_error.rb +80 -0
- 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 +0 -14
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/eligibility_recommendation.rb +2 -2
- data/lib/candidhealth/pre_encounter/eligibility_checks/v_1/types/medicare_advantage_recommendation_payload.rb +14 -5
- data/lib/candidhealth/pre_encounter/images/v_1/types/image.rb +2 -2
- 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/types/tag.rb +2 -2
- data/lib/requests.rb +2 -2
- data/lib/types_export.rb +2 -0
- metadata +4 -2
@@ -115,7 +115,7 @@ module CandidApiClient
|
|
115
115
|
# @param contracting_provider_id [String] The UUID of the provider under agreement to the contract
|
116
116
|
# @param rendering_provider_ids [Set<String>] A rendering provider isn't contracted directly with the payer but can render
|
117
117
|
# services under the contract held by the contracting provider.
|
118
|
-
# Max items is
|
118
|
+
# Max items is 4000.
|
119
119
|
# @param payer_uuid [String] The UUID of the insurance company under agreement to the contract
|
120
120
|
# @param request_options [CandidApiClient::RequestOptions]
|
121
121
|
# @return [CandidApiClient::Contracts::V2::Types::ContractWithProviders]
|
@@ -181,7 +181,7 @@ module CandidApiClient
|
|
181
181
|
# @param contract_id [String]
|
182
182
|
# @param rendering_provider_ids [Set<String>] A rendering provider isn't contracted directly with the payer but can render
|
183
183
|
# services under the contract held by the contracting provider.
|
184
|
-
# Max items is
|
184
|
+
# Max items is 4000.
|
185
185
|
# @param effective_date [String] The starting day upon which the contract is effective
|
186
186
|
# @param expiration_date [CandidApiClient::Contracts::V2::Types::DateUpdate] An optional end day upon which the contract expires
|
187
187
|
# @param regions [CandidApiClient::Contracts::V2::Types::RegionsUpdate] If present, the contract's rendering providers will be patched to this exact
|
@@ -324,7 +324,7 @@ module CandidApiClient
|
|
324
324
|
# @param contracting_provider_id [String] The UUID of the provider under agreement to the contract
|
325
325
|
# @param rendering_provider_ids [Set<String>] A rendering provider isn't contracted directly with the payer but can render
|
326
326
|
# services under the contract held by the contracting provider.
|
327
|
-
# Max items is
|
327
|
+
# Max items is 4000.
|
328
328
|
# @param payer_uuid [String] The UUID of the insurance company under agreement to the contract
|
329
329
|
# @param request_options [CandidApiClient::RequestOptions]
|
330
330
|
# @return [CandidApiClient::Contracts::V2::Types::ContractWithProviders]
|
@@ -394,7 +394,7 @@ module CandidApiClient
|
|
394
394
|
# @param contract_id [String]
|
395
395
|
# @param rendering_provider_ids [Set<String>] A rendering provider isn't contracted directly with the payer but can render
|
396
396
|
# services under the contract held by the contracting provider.
|
397
|
-
# Max items is
|
397
|
+
# Max items is 4000.
|
398
398
|
# @param effective_date [String] The starting day upon which the contract is effective
|
399
399
|
# @param expiration_date [CandidApiClient::Contracts::V2::Types::DateUpdate] An optional end day upon which the contract expires
|
400
400
|
# @param regions [CandidApiClient::Contracts::V2::Types::RegionsUpdate] If present, the contract's rendering providers will be patched to this exact
|
@@ -0,0 +1,80 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "ostruct"
|
4
|
+
require "json"
|
5
|
+
|
6
|
+
module CandidApiClient
|
7
|
+
module Diagnoses
|
8
|
+
module Types
|
9
|
+
class DisallowMultiplePrimaryDiagnosisError
|
10
|
+
# @return [String]
|
11
|
+
attr_reader :existing_primary_diagnosis_id
|
12
|
+
# @return [String]
|
13
|
+
attr_reader :new_primary_diagnosis_id
|
14
|
+
# @return [String]
|
15
|
+
attr_reader :message
|
16
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
17
|
+
attr_reader :additional_properties
|
18
|
+
# @return [Object]
|
19
|
+
attr_reader :_field_set
|
20
|
+
protected :_field_set
|
21
|
+
|
22
|
+
OMIT = Object.new
|
23
|
+
|
24
|
+
# @param existing_primary_diagnosis_id [String]
|
25
|
+
# @param new_primary_diagnosis_id [String]
|
26
|
+
# @param message [String]
|
27
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
28
|
+
# @return [CandidApiClient::Diagnoses::Types::DisallowMultiplePrimaryDiagnosisError]
|
29
|
+
def initialize(existing_primary_diagnosis_id:, new_primary_diagnosis_id:, message:, additional_properties: nil)
|
30
|
+
@existing_primary_diagnosis_id = existing_primary_diagnosis_id
|
31
|
+
@new_primary_diagnosis_id = new_primary_diagnosis_id
|
32
|
+
@message = message
|
33
|
+
@additional_properties = additional_properties
|
34
|
+
@_field_set = {
|
35
|
+
"existing_primary_diagnosis_id": existing_primary_diagnosis_id,
|
36
|
+
"new_primary_diagnosis_id": new_primary_diagnosis_id,
|
37
|
+
"message": message
|
38
|
+
}
|
39
|
+
end
|
40
|
+
|
41
|
+
# Deserialize a JSON object to an instance of
|
42
|
+
# DisallowMultiplePrimaryDiagnosisError
|
43
|
+
#
|
44
|
+
# @param json_object [String]
|
45
|
+
# @return [CandidApiClient::Diagnoses::Types::DisallowMultiplePrimaryDiagnosisError]
|
46
|
+
def self.from_json(json_object:)
|
47
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
48
|
+
existing_primary_diagnosis_id = struct["existing_primary_diagnosis_id"]
|
49
|
+
new_primary_diagnosis_id = struct["new_primary_diagnosis_id"]
|
50
|
+
message = struct["message"]
|
51
|
+
new(
|
52
|
+
existing_primary_diagnosis_id: existing_primary_diagnosis_id,
|
53
|
+
new_primary_diagnosis_id: new_primary_diagnosis_id,
|
54
|
+
message: message,
|
55
|
+
additional_properties: struct
|
56
|
+
)
|
57
|
+
end
|
58
|
+
|
59
|
+
# Serialize an instance of DisallowMultiplePrimaryDiagnosisError to a JSON object
|
60
|
+
#
|
61
|
+
# @return [String]
|
62
|
+
def to_json(*_args)
|
63
|
+
@_field_set&.to_json
|
64
|
+
end
|
65
|
+
|
66
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
67
|
+
# hash and check each fields type against the current object's property
|
68
|
+
# definitions.
|
69
|
+
#
|
70
|
+
# @param obj [Object]
|
71
|
+
# @return [Void]
|
72
|
+
def self.validate_raw(obj:)
|
73
|
+
obj.existing_primary_diagnosis_id.is_a?(String) != false || raise("Passed value for field obj.existing_primary_diagnosis_id is not the expected type, validation failed.")
|
74
|
+
obj.new_primary_diagnosis_id.is_a?(String) != false || raise("Passed value for field obj.new_primary_diagnosis_id is not the expected type, validation failed.")
|
75
|
+
obj.message.is_a?(String) != false || raise("Passed value for field obj.message is not the expected type, validation failed.")
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
79
|
+
end
|
80
|
+
end
|
@@ -17,6 +17,7 @@ require "json"
|
|
17
17
|
require_relative "types/rate_upload"
|
18
18
|
require_relative "types/payer_threshold"
|
19
19
|
require_relative "types/payer_thresholds_page"
|
20
|
+
require_relative "types/optional_dimensions"
|
20
21
|
require "async"
|
21
22
|
|
22
23
|
module CandidApiClient
|
@@ -345,6 +346,45 @@ module CandidApiClient
|
|
345
346
|
end
|
346
347
|
CandidApiClient::FeeSchedules::V3::Types::PayerThreshold.from_json(json_object: response.body)
|
347
348
|
end
|
349
|
+
|
350
|
+
# Hard deletes rates from the system that match the provided dimensions. This is
|
351
|
+
# a destructive operation and cannot be undone. If an empty dimensions object is
|
352
|
+
# provided, all rates will be hard deleted. The maximum number of rates this API
|
353
|
+
# will delete at a time is 10000. Returns the number of rates deleted and if that
|
354
|
+
# number is the maximum, the caller should call this API again to continue
|
355
|
+
# deleting rates.
|
356
|
+
#
|
357
|
+
# @param request [Hash] Request of type CandidApiClient::FeeSchedules::V3::Types::OptionalDimensions, as a Hash
|
358
|
+
# * :payer_uuid (String)
|
359
|
+
# * :organization_billing_provider_id (String)
|
360
|
+
# * :states (Set<CandidApiClient::Commons::Types::State>)
|
361
|
+
# * :zip_codes (Set<String>)
|
362
|
+
# * :license_types (Set<CandidApiClient::OrganizationProviders::V2::Types::LicenseType>)
|
363
|
+
# * :facility_type_codes (Set<CandidApiClient::Commons::Types::FacilityTypeCode>)
|
364
|
+
# * :network_types (Set<CandidApiClient::Commons::Types::NetworkType>)
|
365
|
+
# * :payer_plan_group_ids (Set<String>)
|
366
|
+
# * :cpt_code (String)
|
367
|
+
# * :modifiers (Set<CandidApiClient::Commons::Types::ProcedureModifier>)
|
368
|
+
# @param request_options [CandidApiClient::RequestOptions]
|
369
|
+
# @return [Integer]
|
370
|
+
# @example
|
371
|
+
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
372
|
+
# api.fee_schedules.v_3.hard_delete_rates(request: { states: Set[AA], zip_codes: Set["zip_codes"], license_types: Set[MD], facility_type_codes: Set[PHARMACY], network_types: Set[PPO], payer_plan_group_ids: Set["d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"], modifiers: Set[AV] })
|
373
|
+
def hard_delete_rates(request:, request_options: nil)
|
374
|
+
response = @request_client.conn.post do |req|
|
375
|
+
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
376
|
+
req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
|
377
|
+
req.headers = {
|
378
|
+
**(req.headers || {}),
|
379
|
+
**@request_client.get_headers,
|
380
|
+
**(request_options&.additional_headers || {})
|
381
|
+
}.compact
|
382
|
+
req.body = { **(request || {}), **(request_options&.additional_body_parameters || {}) }.compact
|
383
|
+
req.url "#{@request_client.get_url(environment: CandidApi,
|
384
|
+
request_options: request_options)}/api/fee-schedules/v3/hard-delete"
|
385
|
+
end
|
386
|
+
JSON.parse(response.body)
|
387
|
+
end
|
348
388
|
end
|
349
389
|
|
350
390
|
class AsyncV3Client
|
@@ -697,6 +737,48 @@ module CandidApiClient
|
|
697
737
|
CandidApiClient::FeeSchedules::V3::Types::PayerThreshold.from_json(json_object: response.body)
|
698
738
|
end
|
699
739
|
end
|
740
|
+
|
741
|
+
# Hard deletes rates from the system that match the provided dimensions. This is
|
742
|
+
# a destructive operation and cannot be undone. If an empty dimensions object is
|
743
|
+
# provided, all rates will be hard deleted. The maximum number of rates this API
|
744
|
+
# will delete at a time is 10000. Returns the number of rates deleted and if that
|
745
|
+
# number is the maximum, the caller should call this API again to continue
|
746
|
+
# deleting rates.
|
747
|
+
#
|
748
|
+
# @param request [Hash] Request of type CandidApiClient::FeeSchedules::V3::Types::OptionalDimensions, as a Hash
|
749
|
+
# * :payer_uuid (String)
|
750
|
+
# * :organization_billing_provider_id (String)
|
751
|
+
# * :states (Set<CandidApiClient::Commons::Types::State>)
|
752
|
+
# * :zip_codes (Set<String>)
|
753
|
+
# * :license_types (Set<CandidApiClient::OrganizationProviders::V2::Types::LicenseType>)
|
754
|
+
# * :facility_type_codes (Set<CandidApiClient::Commons::Types::FacilityTypeCode>)
|
755
|
+
# * :network_types (Set<CandidApiClient::Commons::Types::NetworkType>)
|
756
|
+
# * :payer_plan_group_ids (Set<String>)
|
757
|
+
# * :cpt_code (String)
|
758
|
+
# * :modifiers (Set<CandidApiClient::Commons::Types::ProcedureModifier>)
|
759
|
+
# @param request_options [CandidApiClient::RequestOptions]
|
760
|
+
# @return [Integer]
|
761
|
+
# @example
|
762
|
+
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
763
|
+
# api.fee_schedules.v_3.hard_delete_rates(request: { states: Set[AA], zip_codes: Set["zip_codes"], license_types: Set[MD], facility_type_codes: Set[PHARMACY], network_types: Set[PPO], payer_plan_group_ids: Set["d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"], modifiers: Set[AV] })
|
764
|
+
def hard_delete_rates(request:, request_options: nil)
|
765
|
+
Async do
|
766
|
+
response = @request_client.conn.post do |req|
|
767
|
+
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
768
|
+
req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
|
769
|
+
req.headers = {
|
770
|
+
**(req.headers || {}),
|
771
|
+
**@request_client.get_headers,
|
772
|
+
**(request_options&.additional_headers || {})
|
773
|
+
}.compact
|
774
|
+
req.body = { **(request || {}), **(request_options&.additional_body_parameters || {}) }.compact
|
775
|
+
req.url "#{@request_client.get_url(environment: CandidApi,
|
776
|
+
request_options: request_options)}/api/fee-schedules/v3/hard-delete"
|
777
|
+
end
|
778
|
+
parsed_json = JSON.parse(response.body)
|
779
|
+
parsed_json
|
780
|
+
end
|
781
|
+
end
|
700
782
|
end
|
701
783
|
end
|
702
784
|
end
|
@@ -12,7 +12,9 @@ module CandidApiClient
|
|
12
12
|
module Individual
|
13
13
|
module Types
|
14
14
|
class SubscriberCreate
|
15
|
-
# @return [CandidApiClient::InsuranceCards::V2::Types::InsuranceCardCreate]
|
15
|
+
# @return [CandidApiClient::InsuranceCards::V2::Types::InsuranceCardCreate] Please reference our [Payer
|
16
|
+
# Information](https://docs.joincandidhealth.com/introduction/payer-information)
|
17
|
+
# documentation for more details on how to populate the `insurance_card` fields.
|
16
18
|
attr_reader :insurance_card
|
17
19
|
# @return [CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll]
|
18
20
|
attr_reader :patient_relationship_to_subscriber_code
|
@@ -34,7 +36,9 @@ module CandidApiClient
|
|
34
36
|
|
35
37
|
OMIT = Object.new
|
36
38
|
|
37
|
-
# @param insurance_card [CandidApiClient::InsuranceCards::V2::Types::InsuranceCardCreate]
|
39
|
+
# @param insurance_card [CandidApiClient::InsuranceCards::V2::Types::InsuranceCardCreate] Please reference our [Payer
|
40
|
+
# Information](https://docs.joincandidhealth.com/introduction/payer-information)
|
41
|
+
# documentation for more details on how to populate the `insurance_card` fields.
|
38
42
|
# @param patient_relationship_to_subscriber_code [CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll]
|
39
43
|
# @param date_of_birth [Date]
|
40
44
|
# @param address [CandidApiClient::Commons::Types::StreetAddressShortZip]
|
@@ -12,7 +12,9 @@ module CandidApiClient
|
|
12
12
|
module Individual
|
13
13
|
module Types
|
14
14
|
class SubscriberCreateOptional
|
15
|
-
# @return [CandidApiClient::InsuranceCards::V2::Types::InsuranceCardCreateOptional]
|
15
|
+
# @return [CandidApiClient::InsuranceCards::V2::Types::InsuranceCardCreateOptional] Please reference our [Payer
|
16
|
+
# Information](https://docs.joincandidhealth.com/introduction/payer-information)
|
17
|
+
# documentation for more details on how to populate the `insurance_card` fields.
|
16
18
|
attr_reader :insurance_card
|
17
19
|
# @return [CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll]
|
18
20
|
attr_reader :patient_relationship_to_subscriber_code
|
@@ -34,7 +36,9 @@ module CandidApiClient
|
|
34
36
|
|
35
37
|
OMIT = Object.new
|
36
38
|
|
37
|
-
# @param insurance_card [CandidApiClient::InsuranceCards::V2::Types::InsuranceCardCreateOptional]
|
39
|
+
# @param insurance_card [CandidApiClient::InsuranceCards::V2::Types::InsuranceCardCreateOptional] Please reference our [Payer
|
40
|
+
# Information](https://docs.joincandidhealth.com/introduction/payer-information)
|
41
|
+
# documentation for more details on how to populate the `insurance_card` fields.
|
38
42
|
# @param patient_relationship_to_subscriber_code [CandidApiClient::Commons::Types::PatientRelationshipToInsuredCodeAll]
|
39
43
|
# @param date_of_birth [Date]
|
40
44
|
# @param address [CandidApiClient::Commons::Types::StreetAddressShortZipOptional]
|
@@ -7,6 +7,7 @@ require_relative "types/toggle_non_insurance_payer_enablement_request"
|
|
7
7
|
require_relative "types/non_insurance_payer_sort_field"
|
8
8
|
require_relative "../../commons/types/sort_direction"
|
9
9
|
require_relative "types/non_insurance_payer_page"
|
10
|
+
require_relative "types/non_insurance_payer_categories_page"
|
10
11
|
require_relative "types/non_insurance_payer_update_request"
|
11
12
|
require "async"
|
12
13
|
|
@@ -81,7 +82,13 @@ module CandidApiClient
|
|
81
82
|
end
|
82
83
|
|
83
84
|
# @param name [String]
|
84
|
-
# @param category [String]
|
85
|
+
# @param category [String] Fuzzy-match category names of non-insurance payers.
|
86
|
+
# @param categories_exact [String] Filter by one or more categories by name.
|
87
|
+
# When multiple are present, non-insurance payers with any of the specified
|
88
|
+
# categories will be matched.
|
89
|
+
# @param clinical_trial_ids [String] Filter by one or more clinical trials by their `clinical_trial_id`.
|
90
|
+
# When multiple are present, non-insurance payers with any of the specified
|
91
|
+
# clinical trials will be matched.
|
85
92
|
# @param enabled [Boolean]
|
86
93
|
# @param sort [CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayerSortField]
|
87
94
|
# @param sort_direction [CandidApiClient::Commons::Types::SortDirection]
|
@@ -92,8 +99,8 @@ module CandidApiClient
|
|
92
99
|
# @example
|
93
100
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
94
101
|
# api.non_insurance_payers.v_1.get_multi
|
95
|
-
def get_multi(name: nil, category: nil,
|
96
|
-
page_token: nil, request_options: nil)
|
102
|
+
def get_multi(name: nil, category: nil, categories_exact: nil, clinical_trial_ids: nil, enabled: nil,
|
103
|
+
sort: nil, sort_direction: nil, limit: nil, page_token: nil, request_options: nil)
|
97
104
|
response = @request_client.conn.get do |req|
|
98
105
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
99
106
|
req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
|
@@ -106,6 +113,8 @@ module CandidApiClient
|
|
106
113
|
**(request_options&.additional_query_parameters || {}),
|
107
114
|
"name": name,
|
108
115
|
"category": category,
|
116
|
+
"categories_exact": categories_exact,
|
117
|
+
"clinical_trial_ids": clinical_trial_ids,
|
109
118
|
"enabled": enabled,
|
110
119
|
"sort": sort,
|
111
120
|
"sort_direction": sort_direction,
|
@@ -118,6 +127,41 @@ module CandidApiClient
|
|
118
127
|
CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayerPage.from_json(json_object: response.body)
|
119
128
|
end
|
120
129
|
|
130
|
+
# Returns a paginated list of all non-insurance payer categories.
|
131
|
+
# Non-insurance payer categories are simply strings and are not stored as a
|
132
|
+
# separate object in Candid. They are created when added to at least one
|
133
|
+
# non-insurance payer's `category` field and are deleted when there are no
|
134
|
+
# longer any non-insurance payers that contain them.
|
135
|
+
#
|
136
|
+
# @param search_term [String] Filters categories by fuzzy matching on name.
|
137
|
+
# @param limit [Integer] Limits the maximum number of categories that will be returned. Defaults to 100.
|
138
|
+
# @param page_token [String] The page token to continue paging through a previous request.
|
139
|
+
# @param request_options [CandidApiClient::RequestOptions]
|
140
|
+
# @return [CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayerCategoriesPage]
|
141
|
+
# @example
|
142
|
+
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
143
|
+
# api.non_insurance_payers.v_1.get_categories
|
144
|
+
def get_categories(search_term: nil, limit: nil, page_token: nil, request_options: nil)
|
145
|
+
response = @request_client.conn.get do |req|
|
146
|
+
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
147
|
+
req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
|
148
|
+
req.headers = {
|
149
|
+
**(req.headers || {}),
|
150
|
+
**@request_client.get_headers,
|
151
|
+
**(request_options&.additional_headers || {})
|
152
|
+
}.compact
|
153
|
+
req.params = {
|
154
|
+
**(request_options&.additional_query_parameters || {}),
|
155
|
+
"search_term": search_term,
|
156
|
+
"limit": limit,
|
157
|
+
"page_token": page_token
|
158
|
+
}.compact
|
159
|
+
req.url "#{@request_client.get_url(environment: CandidApi,
|
160
|
+
request_options: request_options)}/api/non-insurance-payers/v1/categories"
|
161
|
+
end
|
162
|
+
CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayerCategoriesPage.from_json(json_object: response.body)
|
163
|
+
end
|
164
|
+
|
121
165
|
# @param non_insurance_payer_id [String]
|
122
166
|
# @param request_options [CandidApiClient::RequestOptions]
|
123
167
|
# @return [CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayer]
|
@@ -259,7 +303,13 @@ module CandidApiClient
|
|
259
303
|
end
|
260
304
|
|
261
305
|
# @param name [String]
|
262
|
-
# @param category [String]
|
306
|
+
# @param category [String] Fuzzy-match category names of non-insurance payers.
|
307
|
+
# @param categories_exact [String] Filter by one or more categories by name.
|
308
|
+
# When multiple are present, non-insurance payers with any of the specified
|
309
|
+
# categories will be matched.
|
310
|
+
# @param clinical_trial_ids [String] Filter by one or more clinical trials by their `clinical_trial_id`.
|
311
|
+
# When multiple are present, non-insurance payers with any of the specified
|
312
|
+
# clinical trials will be matched.
|
263
313
|
# @param enabled [Boolean]
|
264
314
|
# @param sort [CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayerSortField]
|
265
315
|
# @param sort_direction [CandidApiClient::Commons::Types::SortDirection]
|
@@ -270,8 +320,8 @@ module CandidApiClient
|
|
270
320
|
# @example
|
271
321
|
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
272
322
|
# api.non_insurance_payers.v_1.get_multi
|
273
|
-
def get_multi(name: nil, category: nil,
|
274
|
-
page_token: nil, request_options: nil)
|
323
|
+
def get_multi(name: nil, category: nil, categories_exact: nil, clinical_trial_ids: nil, enabled: nil,
|
324
|
+
sort: nil, sort_direction: nil, limit: nil, page_token: nil, request_options: nil)
|
275
325
|
Async do
|
276
326
|
response = @request_client.conn.get do |req|
|
277
327
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -285,6 +335,8 @@ module CandidApiClient
|
|
285
335
|
**(request_options&.additional_query_parameters || {}),
|
286
336
|
"name": name,
|
287
337
|
"category": category,
|
338
|
+
"categories_exact": categories_exact,
|
339
|
+
"clinical_trial_ids": clinical_trial_ids,
|
288
340
|
"enabled": enabled,
|
289
341
|
"sort": sort,
|
290
342
|
"sort_direction": sort_direction,
|
@@ -298,6 +350,43 @@ module CandidApiClient
|
|
298
350
|
end
|
299
351
|
end
|
300
352
|
|
353
|
+
# Returns a paginated list of all non-insurance payer categories.
|
354
|
+
# Non-insurance payer categories are simply strings and are not stored as a
|
355
|
+
# separate object in Candid. They are created when added to at least one
|
356
|
+
# non-insurance payer's `category` field and are deleted when there are no
|
357
|
+
# longer any non-insurance payers that contain them.
|
358
|
+
#
|
359
|
+
# @param search_term [String] Filters categories by fuzzy matching on name.
|
360
|
+
# @param limit [Integer] Limits the maximum number of categories that will be returned. Defaults to 100.
|
361
|
+
# @param page_token [String] The page token to continue paging through a previous request.
|
362
|
+
# @param request_options [CandidApiClient::RequestOptions]
|
363
|
+
# @return [CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayerCategoriesPage]
|
364
|
+
# @example
|
365
|
+
# api = CandidApiClient::Client.new(base_url: "https://api.example.com", environment: CandidApiClient::Environment::PRODUCTION)
|
366
|
+
# api.non_insurance_payers.v_1.get_categories
|
367
|
+
def get_categories(search_term: nil, limit: nil, page_token: nil, request_options: nil)
|
368
|
+
Async do
|
369
|
+
response = @request_client.conn.get do |req|
|
370
|
+
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
371
|
+
req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
|
372
|
+
req.headers = {
|
373
|
+
**(req.headers || {}),
|
374
|
+
**@request_client.get_headers,
|
375
|
+
**(request_options&.additional_headers || {})
|
376
|
+
}.compact
|
377
|
+
req.params = {
|
378
|
+
**(request_options&.additional_query_parameters || {}),
|
379
|
+
"search_term": search_term,
|
380
|
+
"limit": limit,
|
381
|
+
"page_token": page_token
|
382
|
+
}.compact
|
383
|
+
req.url "#{@request_client.get_url(environment: CandidApi,
|
384
|
+
request_options: request_options)}/api/non-insurance-payers/v1/categories"
|
385
|
+
end
|
386
|
+
CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayerCategoriesPage.from_json(json_object: response.body)
|
387
|
+
end
|
388
|
+
end
|
389
|
+
|
301
390
|
# @param non_insurance_payer_id [String]
|
302
391
|
# @param request_options [CandidApiClient::RequestOptions]
|
303
392
|
# @return [CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayer]
|
@@ -0,0 +1,83 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "ostruct"
|
4
|
+
require "json"
|
5
|
+
|
6
|
+
module CandidApiClient
|
7
|
+
module NonInsurancePayers
|
8
|
+
module V1
|
9
|
+
module Types
|
10
|
+
class NonInsurancePayerCategoriesPage
|
11
|
+
# @return [Array<String>]
|
12
|
+
attr_reader :items
|
13
|
+
# @return [String]
|
14
|
+
attr_reader :prev_page_token
|
15
|
+
# @return [String]
|
16
|
+
attr_reader :next_page_token
|
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 items [Array<String>]
|
26
|
+
# @param prev_page_token [String]
|
27
|
+
# @param next_page_token [String]
|
28
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
29
|
+
# @return [CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayerCategoriesPage]
|
30
|
+
def initialize(items:, prev_page_token: OMIT, next_page_token: OMIT, additional_properties: nil)
|
31
|
+
@items = items
|
32
|
+
@prev_page_token = prev_page_token if prev_page_token != OMIT
|
33
|
+
@next_page_token = next_page_token if next_page_token != OMIT
|
34
|
+
@additional_properties = additional_properties
|
35
|
+
@_field_set = {
|
36
|
+
"items": items,
|
37
|
+
"prev_page_token": prev_page_token,
|
38
|
+
"next_page_token": next_page_token
|
39
|
+
}.reject do |_k, v|
|
40
|
+
v == OMIT
|
41
|
+
end
|
42
|
+
end
|
43
|
+
|
44
|
+
# Deserialize a JSON object to an instance of NonInsurancePayerCategoriesPage
|
45
|
+
#
|
46
|
+
# @param json_object [String]
|
47
|
+
# @return [CandidApiClient::NonInsurancePayers::V1::Types::NonInsurancePayerCategoriesPage]
|
48
|
+
def self.from_json(json_object:)
|
49
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
50
|
+
items = struct["items"]
|
51
|
+
prev_page_token = struct["prev_page_token"]
|
52
|
+
next_page_token = struct["next_page_token"]
|
53
|
+
new(
|
54
|
+
items: items,
|
55
|
+
prev_page_token: prev_page_token,
|
56
|
+
next_page_token: next_page_token,
|
57
|
+
additional_properties: struct
|
58
|
+
)
|
59
|
+
end
|
60
|
+
|
61
|
+
# Serialize an instance of NonInsurancePayerCategoriesPage to a JSON object
|
62
|
+
#
|
63
|
+
# @return [String]
|
64
|
+
def to_json(*_args)
|
65
|
+
@_field_set&.to_json
|
66
|
+
end
|
67
|
+
|
68
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
69
|
+
# hash and check each fields type against the current object's property
|
70
|
+
# definitions.
|
71
|
+
#
|
72
|
+
# @param obj [Object]
|
73
|
+
# @return [Void]
|
74
|
+
def self.validate_raw(obj:)
|
75
|
+
obj.items.is_a?(Array) != false || raise("Passed value for field obj.items is not the expected type, validation failed.")
|
76
|
+
obj.prev_page_token&.is_a?(String) != false || raise("Passed value for field obj.prev_page_token is not the expected type, validation failed.")
|
77
|
+
obj.next_page_token&.is_a?(String) != false || raise("Passed value for field obj.next_page_token is not the expected type, validation failed.")
|
78
|
+
end
|
79
|
+
end
|
80
|
+
end
|
81
|
+
end
|
82
|
+
end
|
83
|
+
end
|
@@ -47,6 +47,7 @@ module CandidApiClient
|
|
47
47
|
# @param npi [String] Filter to a specific NPI.
|
48
48
|
# @param is_rendering [Boolean] Filter to only rendering providers.
|
49
49
|
# @param is_billing [Boolean] Filter to only billing providers.
|
50
|
+
# @param organization_provider_ids [String] Filter to the provided organization provider IDs.
|
50
51
|
# @param page_token [String] The page token to continue paging through a previous request.
|
51
52
|
# @param sort [CandidApiClient::OrganizationProviders::V2::Types::OrganizationProviderSortOptions] Defaults to PROVIDER_NAME_ASC.
|
52
53
|
# @param request_options [CandidApiClient::RequestOptions]
|
@@ -62,8 +63,8 @@ module CandidApiClient
|
|
62
63
|
# page_token: "eyJ0b2tlbiI6IjEiLCJwYWdlX3Rva2VuIjoiMiJ9",
|
63
64
|
# sort: PROVIDER_NAME_ASC
|
64
65
|
# )
|
65
|
-
def get_multi(limit: nil, search_term: nil, npi: nil, is_rendering: nil, is_billing: nil,
|
66
|
-
sort: nil, request_options: nil)
|
66
|
+
def get_multi(limit: nil, search_term: nil, npi: nil, is_rendering: nil, is_billing: nil,
|
67
|
+
organization_provider_ids: nil, page_token: nil, sort: nil, request_options: nil)
|
67
68
|
response = @request_client.conn.get do |req|
|
68
69
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
69
70
|
req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
|
@@ -79,6 +80,7 @@ module CandidApiClient
|
|
79
80
|
"npi": npi,
|
80
81
|
"is_rendering": is_rendering,
|
81
82
|
"is_billing": is_billing,
|
83
|
+
"organization_provider_ids": organization_provider_ids,
|
82
84
|
"page_token": page_token,
|
83
85
|
"sort": sort
|
84
86
|
}.compact
|
@@ -200,6 +202,7 @@ module CandidApiClient
|
|
200
202
|
# @param npi [String] Filter to a specific NPI.
|
201
203
|
# @param is_rendering [Boolean] Filter to only rendering providers.
|
202
204
|
# @param is_billing [Boolean] Filter to only billing providers.
|
205
|
+
# @param organization_provider_ids [String] Filter to the provided organization provider IDs.
|
203
206
|
# @param page_token [String] The page token to continue paging through a previous request.
|
204
207
|
# @param sort [CandidApiClient::OrganizationProviders::V2::Types::OrganizationProviderSortOptions] Defaults to PROVIDER_NAME_ASC.
|
205
208
|
# @param request_options [CandidApiClient::RequestOptions]
|
@@ -215,8 +218,8 @@ module CandidApiClient
|
|
215
218
|
# page_token: "eyJ0b2tlbiI6IjEiLCJwYWdlX3Rva2VuIjoiMiJ9",
|
216
219
|
# sort: PROVIDER_NAME_ASC
|
217
220
|
# )
|
218
|
-
def get_multi(limit: nil, search_term: nil, npi: nil, is_rendering: nil, is_billing: nil,
|
219
|
-
sort: nil, request_options: nil)
|
221
|
+
def get_multi(limit: nil, search_term: nil, npi: nil, is_rendering: nil, is_billing: nil,
|
222
|
+
organization_provider_ids: nil, page_token: nil, sort: nil, request_options: nil)
|
220
223
|
Async do
|
221
224
|
response = @request_client.conn.get do |req|
|
222
225
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -233,6 +236,7 @@ module CandidApiClient
|
|
233
236
|
"npi": npi,
|
234
237
|
"is_rendering": is_rendering,
|
235
238
|
"is_billing": is_billing,
|
239
|
+
"organization_provider_ids": organization_provider_ids,
|
236
240
|
"page_token": page_token,
|
237
241
|
"sort": sort
|
238
242
|
}.compact
|
@@ -43,6 +43,7 @@ module CandidApiClient
|
|
43
43
|
|
44
44
|
# @param limit [Integer] Limit the number of results returned. Defaults to 100.
|
45
45
|
# @param name [String] Filter to a name or a part of a name.
|
46
|
+
# @param organization_service_facility_ids [String] Filter to the provided organization service facility IDs.
|
46
47
|
# @param page_token [String] The page token to continue paging through a previous request.
|
47
48
|
# @param request_options [CandidApiClient::RequestOptions]
|
48
49
|
# @return [CandidApiClient::OrganizationServiceFacilities::V2::Types::OrganizationServiceFacilityPage]
|
@@ -53,7 +54,8 @@ module CandidApiClient
|
|
53
54
|
# name: "Test Service Facility",
|
54
55
|
# page_token: "eyJ0b2tlbiI6IjEiLCJwYWdlX3Rva2VuIjoiMiJ9"
|
55
56
|
# )
|
56
|
-
def get_multi(limit: nil, name: nil,
|
57
|
+
def get_multi(limit: nil, name: nil, organization_service_facility_ids: nil, page_token: nil,
|
58
|
+
request_options: nil)
|
57
59
|
response = @request_client.conn.get do |req|
|
58
60
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
59
61
|
req.headers["Authorization"] = request_options.token unless request_options&.token.nil?
|
@@ -66,6 +68,7 @@ module CandidApiClient
|
|
66
68
|
**(request_options&.additional_query_parameters || {}),
|
67
69
|
"limit": limit,
|
68
70
|
"name": name,
|
71
|
+
"organization_service_facility_ids": organization_service_facility_ids,
|
69
72
|
"page_token": page_token
|
70
73
|
}.compact
|
71
74
|
req.url "#{@request_client.get_url(environment: CandidApi,
|
@@ -209,6 +212,7 @@ module CandidApiClient
|
|
209
212
|
|
210
213
|
# @param limit [Integer] Limit the number of results returned. Defaults to 100.
|
211
214
|
# @param name [String] Filter to a name or a part of a name.
|
215
|
+
# @param organization_service_facility_ids [String] Filter to the provided organization service facility IDs.
|
212
216
|
# @param page_token [String] The page token to continue paging through a previous request.
|
213
217
|
# @param request_options [CandidApiClient::RequestOptions]
|
214
218
|
# @return [CandidApiClient::OrganizationServiceFacilities::V2::Types::OrganizationServiceFacilityPage]
|
@@ -219,7 +223,8 @@ module CandidApiClient
|
|
219
223
|
# name: "Test Service Facility",
|
220
224
|
# page_token: "eyJ0b2tlbiI6IjEiLCJwYWdlX3Rva2VuIjoiMiJ9"
|
221
225
|
# )
|
222
|
-
def get_multi(limit: nil, name: nil,
|
226
|
+
def get_multi(limit: nil, name: nil, organization_service_facility_ids: nil, page_token: nil,
|
227
|
+
request_options: nil)
|
223
228
|
Async do
|
224
229
|
response = @request_client.conn.get do |req|
|
225
230
|
req.options.timeout = request_options.timeout_in_seconds unless request_options&.timeout_in_seconds.nil?
|
@@ -233,6 +238,7 @@ module CandidApiClient
|
|
233
238
|
**(request_options&.additional_query_parameters || {}),
|
234
239
|
"limit": limit,
|
235
240
|
"name": name,
|
241
|
+
"organization_service_facility_ids": organization_service_facility_ids,
|
236
242
|
"page_token": page_token
|
237
243
|
}.compact
|
238
244
|
req.url "#{@request_client.get_url(environment: CandidApi,
|