change_health 4.14.0 → 5.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ad7028df0b8a556723c941162273ae8a9fda1c83a01dcc41939678afd631290f
4
- data.tar.gz: ae98a767647dd4ec1ec9803a547dee055c31336ef2f16829f59e23763c34c965
3
+ metadata.gz: 3cbaca8f7e482861192f0e0a7daa78bc124394839a92af7e8dc2a96b3f9f671e
4
+ data.tar.gz: 67661d3425dd13d95dfa718a274296b991b545f4014670116874718312d9a06a
5
5
  SHA512:
6
- metadata.gz: a8cecec460c7308627ea61d7f83ad6822a2e9f72ac2259c32083f6895409c5817c989ba0ec644fc01cebaf80009b9542600c1eafa26c92743098fd337d5dc01c
7
- data.tar.gz: 81fa3d7abb6763b96c6f3f2752d9cf93d2332d09994260cae131c0601640bf778eb1be7c9258d114af17f11f00cf4bcef4c42d099fa7d927bf2cc099f748ce39
6
+ metadata.gz: 1efdce11cbf9bf405c50e28d951b9a2490037604c55c177b5e8a50095cf67ccacf49a76791c661941b75f1ac153b71faffd8a3eab7cd7bca66847af7d025ca80
7
+ data.tar.gz: b81ad2344d269195e7fc92c33206126b03dfab3e871f081efc090ebf05143b257d5bb59be85f4efedc9ad8cf06c9a12d4b52c4c56083c66be08615069c032a89
data/CHANGELOG.md CHANGED
@@ -5,6 +5,22 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
6
6
  and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
7
7
 
8
+ # [5.0.0] - 2022-08-24
9
+
10
+ ### Changed
11
+
12
+ Endpoint for trading_partner request has changed.
13
+
14
+ * **breaking:** removed medical_eligibility_enabled from trading_partners_data
15
+ * **breaking:** removed medical_eligibility_service_id from trading_partner_data
16
+ * **breaking:** removed medical_eligibility_service from trading_partner_data
17
+ * **breaking:** removed services from trading_partner_data
18
+ * updated endpoint on trading_partner
19
+ * updated params on trading_partner to only return Eligibility service types
20
+ * updated mapping on trading_partner_data for new response from endpoint
21
+ * updated tests
22
+
23
+
8
24
  # [4.14.0] - 2023-08-24
9
25
 
10
26
  ### Added
@@ -535,6 +551,7 @@ Added the ability to hit professional claim submission API. For more details, se
535
551
  * Authentication
536
552
  * Configuration
537
553
 
554
+ [5.0.0]: https://github.com/WeInfuse/change_health/compare/v4.14.0...v5.0.0
538
555
  [4.14.0]: https://github.com/WeInfuse/change_health/compare/v4.13.1...v4.14.0
539
556
  [4.13.1]: https://github.com/WeInfuse/change_health/compare/v4.13.0...v4.13.1
540
557
  [4.13.0]: https://github.com/WeInfuse/change_health/compare/v4.12.0...v4.13.0
@@ -1,17 +1,17 @@
1
1
  module ChangeHealth
2
2
  module Request
3
3
  class TradingPartner < Hashie::Trash
4
- ENDPOINT = '/tradingpartners/v7/partners'.freeze
4
+ ENDPOINT = '/medicalnetwork/payerfinder/v1/payers'.freeze
5
5
 
6
6
  def self.query(term)
7
7
  params = {
8
- query: term,
9
- serviceName: 'medicalEligibility',
10
- strictFilters: true
8
+ businessName: term,
9
+ serviceName: 'Eligibility'
11
10
  }
11
+
12
12
  response = ChangeHealth::Connection.new.request(endpoint: ENDPOINT, verb: :get, query: params)
13
- trading_partners_data = ChangeHealth::Response::TradingPartnersData.new(response).medical_eligibility_enabled
14
- trading_partners_data.map {|partner| ChangeHealth::Models::TradingPartner.new(name: partner.name, service_id: partner.medical_eligibility_service_id) }
13
+ trading_partners_data = ChangeHealth::Response::TradingPartnersData.new(response['payers'])
14
+ trading_partners_data.map { |partner| ChangeHealth::Models::TradingPartner.new(name: partner.name, service_id: partner.service_id) }
15
15
  end
16
16
  end
17
17
  end
@@ -6,21 +6,15 @@ module ChangeHealth
6
6
  end
7
7
 
8
8
  def name
9
- @raw.dig('tradingPartnerName')
9
+ @raw['businessName']
10
10
  end
11
11
 
12
- def services
13
- @raw.dig('clearingHouses', 'legacyExchange')
12
+ def service_id
13
+ @raw['serviceId']
14
14
  end
15
15
 
16
- def medical_eligibility_service
17
- return nil unless services
18
- services.detect {|service| service.dig('serviceName') == 'medicalEligibility' }
19
- end
20
-
21
- def medical_eligibility_service_id
22
- return nil unless medical_eligibility_service
23
- medical_eligibility_service.dig('serviceConnections', 'direct', 'serviceId')
16
+ def service_name
17
+ @raw['serviceName']
24
18
  end
25
19
  end
26
20
  end
@@ -2,11 +2,7 @@ module ChangeHealth
2
2
  module Response
3
3
  class TradingPartnersData < Array
4
4
  def initialize(trading_partners)
5
- super(trading_partners.map {|trading_partner| ChangeHealth::Response::TradingPartnerData.new(trading_partner) })
6
- end
7
-
8
- def medical_eligibility_enabled
9
- self.reject {|partner| nil == partner.medical_eligibility_service_id }
5
+ super(trading_partners.map { |trading_partner| ChangeHealth::Response::TradingPartnerData.new(trading_partner) })
10
6
  end
11
7
  end
12
8
  end
@@ -1,3 +1,3 @@
1
1
  module ChangeHealth
2
- VERSION = '4.14.0'.freeze
2
+ VERSION = '5.0.0'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: change_health
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.14.0
4
+ version: 5.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Crockett
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-08-28 00:00:00.000000000 Z
11
+ date: 2023-08-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httparty
@@ -128,7 +128,7 @@ dependencies:
128
128
  - - "~>"
129
129
  - !ruby/object:Gem::Version
130
130
  version: '0.9'
131
- description:
131
+ description:
132
132
  email:
133
133
  - mike.crockett@weinfuse.com
134
134
  executables: []
@@ -205,7 +205,7 @@ licenses:
205
205
  - MIT
206
206
  metadata:
207
207
  allowed_push_host: https://rubygems.org
208
- post_install_message:
208
+ post_install_message:
209
209
  rdoc_options: []
210
210
  require_paths:
211
211
  - lib
@@ -220,8 +220,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
220
220
  - !ruby/object:Gem::Version
221
221
  version: '0'
222
222
  requirements: []
223
- rubygems_version: 3.1.6
224
- signing_key:
223
+ rubygems_version: 3.4.10
224
+ signing_key:
225
225
  specification_version: 4
226
226
  summary: Ruby wrapper for the ChangeHealth API
227
227
  test_files: []