zammad_api 0.9.1 → 0.9.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 1430cf67f29761e9852ef05ae2e47dec4b8f6848
4
- data.tar.gz: 71da04439cbcbcb0fba11d01d3af82336250a78e
3
+ metadata.gz: 3f1066dec474bcc211a86ca8979f74f02eef179f
4
+ data.tar.gz: 42a205c2f54d155d09094921803bdca1a86d0757
5
5
  SHA512:
6
- metadata.gz: 9e141f9947064e2d7995fa458969af5ed35228c985fe56b42538887b1e226267ee371a21de4afaa34a30438717624d8f1a7e8f47aa733c6ddc3eba9f1c349ea2
7
- data.tar.gz: 48fc482034cc42bdde3636de3c1208ee698e9882b229b6102fd5aa9e6a0aec67d83a4fd11ba16527743a902b519b44a33b15800661fcb29eabbea1eccf5e5e54
6
+ metadata.gz: 292b8cd24f2551c6b3e455e6f29e3089218630cb40f34ac28cd0c3affc8891a5d68735a10198ebf7254981a4c859a7e761e79ffd9868ef06d02a3bb14c3b97fc
7
+ data.tar.gz: 697698a15ea1c857934b8b04b283e7bef83196c0c556d7b93514a7ad0574a41726f38b654cd0630526503166f1e017bc91008e0cf4e6b75d6f9a636a4daf8438
@@ -33,6 +33,7 @@ module ZammadAPI
33
33
 
34
34
  # check for token auth
35
35
  return if @config[:http_token] && !@config[:http_token].empty?
36
+ return if @config[:oauth2_token] && !@config[:oauth2_token].empty?
36
37
 
37
38
  if !@config[:user] || @config[:user].empty?
38
39
  raise 'missing user in config'
@@ -17,6 +17,8 @@ module ZammadAPI
17
17
  @conn.headers[:user_agent] = 'Zammad API Ruby'
18
18
  if config[:http_token] && !config[:http_token].empty?
19
19
  @conn.token_auth(config[:http_token])
20
+ elsif config[:oauth2_token] && !config[:oauth2_token].empty?
21
+ @conn.authorization :Bearer, config[:oauth2_token]
20
22
  else
21
23
  @conn.basic_auth(config[:user], config[:password])
22
24
  end
@@ -1,3 +1,3 @@
1
1
  module ZammadAPI
2
- VERSION = '0.9.1'.freeze
2
+ VERSION = '0.9.2'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zammad_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.1
4
+ version: 0.9.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Martin Edenhofer
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-10-28 00:00:00.000000000 Z
12
+ date: 2016-11-11 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: faraday
@@ -106,7 +106,7 @@ files:
106
106
  - lib/zammad_api/resources/user.rb
107
107
  - lib/zammad_api/transport.rb
108
108
  - lib/zammad_api/version.rb
109
- homepage: https://github.com/zammad/zammad_api_client_ruby
109
+ homepage: https://github.com/zammad/zammad-api-client-ruby
110
110
  licenses: []
111
111
  metadata: {}
112
112
  post_install_message: