easyship-rates-ruby-api 0.6.6 → 0.6.7

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
  SHA1:
3
- metadata.gz: 58757210cfdc667b5a1204e3e4dae3aca59c1c0c
4
- data.tar.gz: 7ca4058f86defec99e3292a0cf467ccfbedce0a9
3
+ metadata.gz: ddc9ffa627b82a01cb95d3dafae8225f24380b5c
4
+ data.tar.gz: ac0b9bf9f8733267ec1f30bee76eea215147f73f
5
5
  SHA512:
6
- metadata.gz: 11cec373c46c7f26612b88c03ec1319dacfa4fa543a5b3ba233bbced05f7b7dc5c47f0d6206adfb8a5beba0d1cf826e9ae91e3dd1543472fe287819c6963ea69
7
- data.tar.gz: a959de9ccca0c9e5af6168c711bcaff827f0a58649f64259adf9302871141ac4d2e4542d205f1b9559a6679edf4bc41c2842cf017b21360e23d6324d01a0755b
6
+ metadata.gz: 99b9088d353b36708209eee97e75c4627d4e7e469c674dede48fd9ae57afcf9158513085981191922db89d53f52fca898134a8f17fc9bc88ef4347d65030f44f
7
+ data.tar.gz: f5740facfd28a208e5508335bea1d2749a36602f31f7b73b9e456fb47ef60fbc4a2bb1490fd78f970af1afe53da4718684922e73aa3c3bf5f1f99aa8ffa18be5
@@ -40,6 +40,15 @@ module EasyshipRatesRubyApi
40
40
  defaults = {}
41
41
  Mash.from_json(delete(path, defaults.merge(options)).body)
42
42
  end
43
+
44
+ # Update user's API key and secret
45
+ # only used by internal service
46
+ # @return [Easyship::Rates::Ruby::Mash]
47
+ def update_api_key_and_secret(options = {})
48
+ path = '/users/update_api_key_and_secret'
49
+ defaults = {}
50
+ Mash.from_json(patch(path, defaults.merge(options)).body)
51
+ end
43
52
  end
44
53
  end
45
54
  end
@@ -26,6 +26,12 @@ module EasyshipRatesRubyApi
26
26
  response
27
27
  end
28
28
 
29
+ def update(path, options = {})
30
+ response = access_token.patch("#{API_PATH}#{path}", { body: options })
31
+ raise_errors(response)
32
+ response
33
+ end
34
+
29
35
  private
30
36
 
31
37
  def raise_errors(response)
@@ -2,7 +2,7 @@ module EasyshipRatesRubyApi
2
2
  module Version #:nodoc:
3
3
  MAJOR = 0
4
4
  MINOR = 6
5
- PATCH = 6
5
+ PATCH = 7
6
6
  PRE = nil
7
7
  STRING = [MAJOR, MINOR, PATCH, PRE].compact.join('.')
8
8
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: easyship-rates-ruby-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.6
4
+ version: 0.6.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - aloha
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-01-24 00:00:00.000000000 Z
11
+ date: 2017-03-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: oauth2