easypost 6.1.1 → 6.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/VERSION +1 -1
- data/lib/easypost/services/billing.rb +8 -8
- data/lib/easypost/services/insurance.rb +7 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ae0d691e3f798606f4153ba71f6d148e3d12eeade8dddec8ab8b06cbd9420173
|
4
|
+
data.tar.gz: 92ad3799e9d50460a99844d28c456050fe58ad78d3b440520a429623adc851a5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 417aea06119816b367ae0e7eeaada243b1c3a266fb784f36df681130a617bf37bfe6d80a02c0c6aa72c4b1e210f2a220ce67aec37803dc9b04735df08c073b78
|
7
|
+
data.tar.gz: 5f550b00033885606ac1f9438696549b40b5602368c39985dded593b666782eaaf05887cbbe3a28afe996e05163c2f30e1740825c27c14e08a1c46f591d01e2e
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,10 @@
|
|
1
1
|
# CHANGELOG
|
2
2
|
|
3
|
+
## v6.2.0 (2024-04-10)
|
4
|
+
|
5
|
+
- Fix payment method funding and deletion failures due to undetermined payment method type
|
6
|
+
- Add `refund` function in Insurance service for requesting a refund for standalone insurance.
|
7
|
+
|
3
8
|
## v6.1.1 (2024-01-23)
|
4
9
|
|
5
10
|
- Fix issues funding wallet due to invalid internal function call
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
6.
|
1
|
+
6.2.0
|
@@ -62,15 +62,15 @@ class EasyPost::Services::Billing < EasyPost::Services::Service
|
|
62
62
|
end
|
63
63
|
|
64
64
|
payment_method_id = payment_methods[payment_method_to_use]['id']
|
65
|
+
payment_method_object_type = payment_methods[payment_method_to_use]['object']
|
65
66
|
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
end
|
67
|
+
if payment_method_object_type == 'CreditCard'
|
68
|
+
|
69
|
+
endpoint = '/credit_cards'
|
70
|
+
elsif payment_method_object_type == 'BankAccount'
|
71
|
+
endpoint = '/bank_accounts'
|
72
|
+
else
|
73
|
+
raise EasyPost::Errors::InvalidObjectError.new(error_string)
|
74
74
|
end
|
75
75
|
|
76
76
|
[endpoint, payment_method_id]
|
@@ -34,4 +34,11 @@ class EasyPost::Services::Insurance < EasyPost::Services::Service
|
|
34
34
|
|
35
35
|
all(params)
|
36
36
|
end
|
37
|
+
|
38
|
+
# Refund an Insurance object
|
39
|
+
def refund(id)
|
40
|
+
response = @client.make_request(:post, "insurances/#{id}/refund")
|
41
|
+
|
42
|
+
EasyPost::InternalUtilities::Json.convert_json_to_object(response, MODEL_CLASS)
|
43
|
+
end
|
37
44
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: easypost
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 6.
|
4
|
+
version: 6.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- EasyPost Developers
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-04-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: brakeman
|