Module: AthenaHealth::Endpoints::Configurations
- Included in:
- Client
- Defined in:
- lib/athena_health/endpoints/configurations.rb
Instance Method Summary collapse
- #all_allergies(practice_id:, search_value:) ⇒ Object
- #all_facilities(practice_id:, department_id:, order_type:, params: {}) ⇒ Object
- #all_gender_identities(practice_id:, show2015edcehrtvalues: nil, limit: nil, offset: nil) ⇒ Object
- #all_insurances(practice_id:, plan_name:, member_id:, state:, params: {}) ⇒ Object
- #all_medications(practice_id:, search_value:) ⇒ Object
- #all_order_types(practice_id:, search_value:) ⇒ Object
Instance Method Details
#all_allergies(practice_id:, search_value:) ⇒ Object
24 25 26 27 28 29 30 31 32 |
# File 'lib/athena_health/endpoints/configurations.rb', line 24 def all_allergies(practice_id:, search_value:) response = @api.call( endpoint: "#{practice_id}/reference/allergies", method: :get, params: { searchvalue: search_value } ) response.map { |allergy| AthenaHealth::Allergy.new(allergy) } end |
#all_facilities(practice_id:, department_id:, order_type:, params: {}) ⇒ Object
4 5 6 7 8 9 10 11 12 |
# File 'lib/athena_health/endpoints/configurations.rb', line 4 def all_facilities(practice_id:, department_id:, order_type:, params: {}) response = @api.call( endpoint: "#{practice_id}/chart/configuration/facilities", method: :get, params: params.merge!(departmentid: department_id, ordertype: order_type) ) response.map { |facility| AthenaHealth::Facility.new(facility) } end |
#all_gender_identities(practice_id:, show2015edcehrtvalues: nil, limit: nil, offset: nil) ⇒ Object
58 59 60 61 62 63 64 65 66 67 68 69 70 |
# File 'lib/athena_health/endpoints/configurations.rb', line 58 def all_gender_identities(practice_id:, show2015edcehrtvalues: nil, limit: nil, offset: nil) params = { show2015edcehrtvalues: show2015edcehrtvalues, limit: limit, offset: offset }.reject { |_k, v| v.nil? } GenderIdentityFieldCollection.new( @api.call( endpoint: "#{practice_id}/configuration/patients/genderidentity", method: :get, params: params ) ) end |
#all_insurances(practice_id:, plan_name:, member_id:, state:, params: {}) ⇒ Object
34 35 36 37 38 39 40 41 42 43 44 45 46 |
# File 'lib/athena_health/endpoints/configurations.rb', line 34 def all_insurances(practice_id:, plan_name:, member_id:, state:, params: {}) response = @api.call( endpoint: "#{practice_id}/insurancepackages", method: :get, params: params.merge!( insuranceplanname: plan_name, memberid: member_id, stateofcoverage: state ) ) AthenaHealth::InsuranceCollection.new(response) end |
#all_medications(practice_id:, search_value:) ⇒ Object
14 15 16 17 18 19 20 21 22 |
# File 'lib/athena_health/endpoints/configurations.rb', line 14 def all_medications(practice_id:, search_value:) response = @api.call( endpoint: "#{practice_id}/reference/medications", method: :get, params: { searchvalue: search_value } ) response.map { |medication| AthenaHealth::Medication.new(medication) } end |
#all_order_types(practice_id:, search_value:) ⇒ Object
48 49 50 51 52 53 54 55 56 |
# File 'lib/athena_health/endpoints/configurations.rb', line 48 def all_order_types(practice_id:, search_value:) response = @api.call( endpoint: "#{practice_id}/reference/order/lab", method: :get, params: { searchvalue: search_value } ) response.map { |ordertype| AthenaHealth::OrderType.new(ordertype) } end |