Class: CandidApiClient::AsyncClient

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(client_id:, client_secret:, base_url: nil, environment: CandidApiClient::Environment::PRODUCTION, max_retries: nil, timeout_in_seconds: nil) ⇒ CandidApiClient::AsyncClient

Parameters:

  • base_url (String) (defaults to: nil)
  • environment (CandidApiClient::Environment) (defaults to: CandidApiClient::Environment::PRODUCTION)
  • max_retries (Long) (defaults to: nil)

    The number of times to retry a failed request, defaults to 2.

  • timeout_in_seconds (Long) (defaults to: nil)
  • client_id (String)
  • client_secret (String)


241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
# File 'lib/candidhealth.rb', line 241

def initialize(client_id:, client_secret:, base_url: nil, environment: CandidApiClient::Environment::PRODUCTION, max_retries: nil,
               timeout_in_seconds: nil)
  @oauth_provider = CandidApiClient::OauthTokenProvider.new(
    client_id: client_id,
    client_secret: client_secret,
    request_client: CandidApiClient::RequestClient.new(
      base_url: base_url,
      environment: environment,
      max_retries: max_retries,
      timeout_in_seconds: timeout_in_seconds
    )
  )
  @async_request_client = CandidApiClient::AsyncRequestClient.new(
    base_url: base_url,
    environment: environment,
    max_retries: max_retries,
    timeout_in_seconds: timeout_in_seconds,
    token: token
  )
  @auth = CandidApiClient::Auth::AsyncClient.new(request_client: @async_request_client)
  @billing_notes = CandidApiClient::BillingNotes::AsyncClient.new(request_client: @async_request_client)
  @contracts = CandidApiClient::Contracts::AsyncClient.new(request_client: @async_request_client)
  @credentialing = CandidApiClient::Credentialing::AsyncClient.new(request_client: @async_request_client)
  @custom_schemas = CandidApiClient::CustomSchemas::AsyncClient.new(request_client: @async_request_client)
  @eligibility = CandidApiClient::Eligibility::AsyncClient.new(request_client: @async_request_client)
  @encounter_providers = CandidApiClient::EncounterProviders::AsyncClient.new(request_client: @async_request_client)
  @encounters = CandidApiClient::Encounters::AsyncClient.new(request_client: @async_request_client)
  @expected_network_status = CandidApiClient::ExpectedNetworkStatus::AsyncClient.new(request_client: @async_request_client)
  @exports = CandidApiClient::Exports::AsyncClient.new(request_client: @async_request_client)
  @external_payment_account_config = CandidApiClient::ExternalPaymentAccountConfig::AsyncClient.new(request_client: @async_request_client)
  @fee_schedules = CandidApiClient::FeeSchedules::AsyncClient.new(request_client: @async_request_client)
  @guarantor = CandidApiClient::Guarantor::AsyncClient.new(request_client: @async_request_client)
  @import_invoice = CandidApiClient::ImportInvoice::AsyncClient.new(request_client: @async_request_client)
  @insurance_adjudications = CandidApiClient::InsuranceAdjudications::AsyncClient.new(request_client: @async_request_client)
  @insurance_payments = CandidApiClient::InsurancePayments::AsyncClient.new(request_client: @async_request_client)
  @insurance_refunds = CandidApiClient::InsuranceRefunds::AsyncClient.new(request_client: @async_request_client)
  @medication_dispense = CandidApiClient::MedicationDispense::AsyncClient.new(request_client: @async_request_client)
  @non_insurance_payer_payments = CandidApiClient::NonInsurancePayerPayments::AsyncClient.new(request_client: @async_request_client)
  @non_insurance_payer_refunds = CandidApiClient::NonInsurancePayerRefunds::AsyncClient.new(request_client: @async_request_client)
  @non_insurance_payers = CandidApiClient::NonInsurancePayers::AsyncClient.new(request_client: @async_request_client)
  @organization_service_facilities = CandidApiClient::OrganizationServiceFacilities::AsyncClient.new(request_client: @async_request_client)
  @organization_providers = CandidApiClient::OrganizationProviders::AsyncClient.new(request_client: @async_request_client)
  @patient_payments = CandidApiClient::PatientPayments::AsyncClient.new(request_client: @async_request_client)
  @patient_refunds = CandidApiClient::PatientRefunds::AsyncClient.new(request_client: @async_request_client)
  @payers = CandidApiClient::Payers::AsyncClient.new(request_client: @async_request_client)
  @service_lines = CandidApiClient::ServiceLines::AsyncClient.new(request_client: @async_request_client)
  @tasks = CandidApiClient::Tasks::AsyncClient.new(request_client: @async_request_client)
  @write_offs = CandidApiClient::WriteOffs::AsyncClient.new(request_client: @async_request_client)
  @pre_encounter = CandidApiClient::PreEncounter::AsyncClient.new(request_client: @async_request_client)
  @diagnoses = CandidApiClient::AsyncDiagnosesClient.new(request_client: @async_request_client)
  @service_facility = CandidApiClient::AsyncServiceFacilityClient.new(request_client: @async_request_client)
end

Instance Attribute Details

#authCandidApiClient::Auth::AsyncClient (readonly)



170
171
172
# File 'lib/candidhealth.rb', line 170

def auth
  @auth
end

#billing_notesCandidApiClient::BillingNotes::AsyncClient (readonly)



172
173
174
# File 'lib/candidhealth.rb', line 172

def billing_notes
  @billing_notes
end

#contractsCandidApiClient::Contracts::AsyncClient (readonly)



174
175
176
# File 'lib/candidhealth.rb', line 174

def contracts
  @contracts
end

#credentialingCandidApiClient::Credentialing::AsyncClient (readonly)



176
177
178
# File 'lib/candidhealth.rb', line 176

def credentialing
  @credentialing
end

#custom_schemasCandidApiClient::CustomSchemas::AsyncClient (readonly)



178
179
180
# File 'lib/candidhealth.rb', line 178

def custom_schemas
  @custom_schemas
end

#diagnosesCandidApiClient::AsyncDiagnosesClient (readonly)



230
231
232
# File 'lib/candidhealth.rb', line 230

def diagnoses
  @diagnoses
end

#eligibilityCandidApiClient::Eligibility::AsyncClient (readonly)



180
181
182
# File 'lib/candidhealth.rb', line 180

def eligibility
  @eligibility
end

#encounter_providersCandidApiClient::EncounterProviders::AsyncClient (readonly)



182
183
184
# File 'lib/candidhealth.rb', line 182

def encounter_providers
  @encounter_providers
end

#encountersCandidApiClient::Encounters::AsyncClient (readonly)



184
185
186
# File 'lib/candidhealth.rb', line 184

def encounters
  @encounters
end

#expected_network_statusCandidApiClient::ExpectedNetworkStatus::AsyncClient (readonly)



186
187
188
# File 'lib/candidhealth.rb', line 186

def expected_network_status
  @expected_network_status
end

#exportsCandidApiClient::Exports::AsyncClient (readonly)



188
189
190
# File 'lib/candidhealth.rb', line 188

def exports
  @exports
end

#external_payment_account_configCandidApiClient::ExternalPaymentAccountConfig::AsyncClient (readonly)



190
191
192
# File 'lib/candidhealth.rb', line 190

def 
  @external_payment_account_config
end

#fee_schedulesCandidApiClient::FeeSchedules::AsyncClient (readonly)



192
193
194
# File 'lib/candidhealth.rb', line 192

def fee_schedules
  @fee_schedules
end

#guarantorCandidApiClient::Guarantor::AsyncClient (readonly)



194
195
196
# File 'lib/candidhealth.rb', line 194

def guarantor
  @guarantor
end

#import_invoiceCandidApiClient::ImportInvoice::AsyncClient (readonly)



196
197
198
# File 'lib/candidhealth.rb', line 196

def import_invoice
  @import_invoice
end

#insurance_adjudicationsCandidApiClient::InsuranceAdjudications::AsyncClient (readonly)



198
199
200
# File 'lib/candidhealth.rb', line 198

def insurance_adjudications
  @insurance_adjudications
end

#insurance_paymentsCandidApiClient::InsurancePayments::AsyncClient (readonly)



200
201
202
# File 'lib/candidhealth.rb', line 200

def insurance_payments
  @insurance_payments
end

#insurance_refundsCandidApiClient::InsuranceRefunds::AsyncClient (readonly)



202
203
204
# File 'lib/candidhealth.rb', line 202

def insurance_refunds
  @insurance_refunds
end

#medication_dispenseCandidApiClient::MedicationDispense::AsyncClient (readonly)



204
205
206
# File 'lib/candidhealth.rb', line 204

def medication_dispense
  @medication_dispense
end

#non_insurance_payer_paymentsCandidApiClient::NonInsurancePayerPayments::AsyncClient (readonly)



206
207
208
# File 'lib/candidhealth.rb', line 206

def non_insurance_payer_payments
  @non_insurance_payer_payments
end

#non_insurance_payer_refundsCandidApiClient::NonInsurancePayerRefunds::AsyncClient (readonly)



208
209
210
# File 'lib/candidhealth.rb', line 208

def non_insurance_payer_refunds
  @non_insurance_payer_refunds
end

#non_insurance_payersCandidApiClient::NonInsurancePayers::AsyncClient (readonly)



210
211
212
# File 'lib/candidhealth.rb', line 210

def non_insurance_payers
  @non_insurance_payers
end

#organization_providersCandidApiClient::OrganizationProviders::AsyncClient (readonly)



214
215
216
# File 'lib/candidhealth.rb', line 214

def organization_providers
  @organization_providers
end

#organization_service_facilitiesCandidApiClient::OrganizationServiceFacilities::AsyncClient (readonly)



212
213
214
# File 'lib/candidhealth.rb', line 212

def organization_service_facilities
  @organization_service_facilities
end

#patient_paymentsCandidApiClient::PatientPayments::AsyncClient (readonly)



216
217
218
# File 'lib/candidhealth.rb', line 216

def patient_payments
  @patient_payments
end

#patient_refundsCandidApiClient::PatientRefunds::AsyncClient (readonly)



218
219
220
# File 'lib/candidhealth.rb', line 218

def patient_refunds
  @patient_refunds
end

#payersCandidApiClient::Payers::AsyncClient (readonly)



220
221
222
# File 'lib/candidhealth.rb', line 220

def payers
  @payers
end

#pre_encounterCandidApiClient::PreEncounter::AsyncClient (readonly)



228
229
230
# File 'lib/candidhealth.rb', line 228

def pre_encounter
  @pre_encounter
end

#service_facilityCandidApiClient::AsyncServiceFacilityClient (readonly)



232
233
234
# File 'lib/candidhealth.rb', line 232

def service_facility
  @service_facility
end

#service_linesCandidApiClient::ServiceLines::AsyncClient (readonly)



222
223
224
# File 'lib/candidhealth.rb', line 222

def service_lines
  @service_lines
end

#tasksCandidApiClient::Tasks::AsyncClient (readonly)



224
225
226
# File 'lib/candidhealth.rb', line 224

def tasks
  @tasks
end

#write_offsCandidApiClient::WriteOffs::AsyncClient (readonly)



226
227
228
# File 'lib/candidhealth.rb', line 226

def write_offs
  @write_offs
end