attune 1.0.7 → 1.0.8

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: 55fd8fc4869a5683e96320760ec40769e6ad8eae
4
- data.tar.gz: 3670d480e007e4c3359f60aca54ccc358bfc5ebc
3
+ metadata.gz: 7be8348bda50301c2d67c55f04d974c616dd08c2
4
+ data.tar.gz: 2a6f630315d49c5a3148a163804e3f27774a7def
5
5
  SHA512:
6
- metadata.gz: 9f3791fa61216413b48d19ff413976fe20ae0d3268d139c36ea753922e990d7912dab40aaab568996a0d0f6e9ec224ca04d69212b4b09f84945e34f292a15dd8
7
- data.tar.gz: 76be0940a93b17b72dd30267214c63116c94d6b8a8173b79a7663a08987fe2f8842210f598b14e8613c6f3846dfb9b9647b4f850d3398ed7e6135c83b99c1655
6
+ metadata.gz: 8e8a3156494cef134484554b2b3973d37fd99d9da21513413ca54a1b2138a29f49b791d52792e4cfacadc1470d3d8a63301fb1078ebca5ce484b43b6ea313702
7
+ data.tar.gz: 38565796e45a9b63f8aa452442f19386a37d7a34aa430bfb0c4d298c9be9a60ba3a7c910b98abc8d5083e9748dd8a70a7f6e8088bfbbb28866d7b6a18039f6d0
@@ -24,6 +24,7 @@ module Attune
24
24
  r_id: SecureRandom.uuid,
25
25
  status: response.status,
26
26
  ua: env[:request_headers]['User-Agent'],
27
+ enc: env[:request_headers]['Content-Encoding'],
27
28
  method: env[:method],
28
29
  perf: {
29
30
  total: elapsed_time * 1000
@@ -3,19 +3,19 @@ module Attune
3
3
  #
4
4
  #
5
5
  # @attr [String] id
6
- # @attr [Array<String>] ids
6
+ # @attr [Boolean] disabled
7
7
  # @attr [String] consumer
8
8
  # @attr [String] entity_type
9
9
  # @attr [String] start_date
10
10
  # @attr [String] end_date
11
11
  # @attr [String] created_at
12
- # @attr [Boolean] disabled
12
+ # @attr [Array<String>] ids
13
13
  # @attr [Array<String>] scope
14
14
  class Blacklist
15
15
  attr_accessor :id
16
16
 
17
17
 
18
- attr_accessor :ids
18
+ attr_accessor :disabled
19
19
 
20
20
 
21
21
  attr_accessor :consumer
@@ -33,7 +33,7 @@ module Attune
33
33
  attr_accessor :created_at
34
34
 
35
35
 
36
- attr_accessor :disabled
36
+ attr_accessor :ids
37
37
 
38
38
 
39
39
  attr_accessor :scope
@@ -43,11 +43,8 @@ module Attune
43
43
  return if attributes.empty?
44
44
  # Workaround since JSON.parse has accessors as strings rather than symbols
45
45
  @id = attributes["id"] || attributes[:"id"]
46
- value = attributes["ids"] || attributes[:"ids"]
47
- if value.is_a?(Array)
48
- @ids = value
49
-
50
- end
46
+ # Workaround since JSON.parse has accessors as strings rather than symbols
47
+ @disabled = attributes["disabled"] || attributes[:"disabled"]
51
48
  # Workaround since JSON.parse has accessors as strings rather than symbols
52
49
  @consumer = attributes["consumer"] || attributes[:"consumer"]
53
50
  # Workaround since JSON.parse has accessors as strings rather than symbols
@@ -58,8 +55,11 @@ module Attune
58
55
  @end_date = attributes["endDate"] || attributes[:"end_date"]
59
56
  # Workaround since JSON.parse has accessors as strings rather than symbols
60
57
  @created_at = attributes["createdAt"] || attributes[:"created_at"]
61
- # Workaround since JSON.parse has accessors as strings rather than symbols
62
- @disabled = attributes["disabled"] || attributes[:"disabled"]
58
+ value = attributes["ids"] || attributes[:"ids"]
59
+ if value.is_a?(Array)
60
+ @ids = value
61
+
62
+ end
63
63
  value = attributes["scope"] || attributes[:"scope"]
64
64
  if value.is_a?(Array)
65
65
  @scope = value
@@ -84,13 +84,13 @@ module Attune
84
84
  # :internal => :external
85
85
  ATTRIBUTE_MAP = {
86
86
  :id => :id,
87
- :ids => :ids,
87
+ :disabled => :disabled,
88
88
  :consumer => :consumer,
89
89
  :entity_type => :entityType,
90
90
  :start_date => :startDate,
91
91
  :end_date => :endDate,
92
92
  :created_at => :createdAt,
93
- :disabled => :disabled,
93
+ :ids => :ids,
94
94
  :scope => :scope
95
95
 
96
96
  }
@@ -2,13 +2,16 @@ module Attune
2
2
  module Model
3
3
  #
4
4
  #
5
+ # @attr [Array<String>] scope
5
6
  # @attr [String] entity_type
6
7
  # @attr [Array<String>] ids
7
8
  # @attr [Boolean] disabled
8
- # @attr [Array<String>] scope
9
9
  # @attr [String] active_from
10
10
  # @attr [String] active_to
11
11
  class BlacklistParams
12
+ attr_accessor :scope
13
+
14
+
12
15
  attr_accessor :entity_type
13
16
 
14
17
 
@@ -18,9 +21,6 @@ module Attune
18
21
  attr_accessor :disabled
19
22
 
20
23
 
21
- attr_accessor :scope
22
-
23
-
24
24
  attr_accessor :active_from
25
25
 
26
26
 
@@ -29,6 +29,11 @@ module Attune
29
29
 
30
30
  def initialize(attributes = {})
31
31
  return if attributes.empty?
32
+ value = attributes["scope"] || attributes[:"scope"]
33
+ if value.is_a?(Array)
34
+ @scope = value
35
+
36
+ end
32
37
  # Workaround since JSON.parse has accessors as strings rather than symbols
33
38
  @entity_type = attributes["entityType"] || attributes[:"entity_type"]
34
39
  value = attributes["ids"] || attributes[:"ids"]
@@ -38,11 +43,6 @@ module Attune
38
43
  end
39
44
  # Workaround since JSON.parse has accessors as strings rather than symbols
40
45
  @disabled = attributes["disabled"] || attributes[:"disabled"]
41
- value = attributes["scope"] || attributes[:"scope"]
42
- if value.is_a?(Array)
43
- @scope = value
44
-
45
- end
46
46
  # Workaround since JSON.parse has accessors as strings rather than symbols
47
47
  @active_from = attributes["activeFrom"] || attributes[:"active_from"]
48
48
  # Workaround since JSON.parse has accessors as strings rather than symbols
@@ -65,10 +65,10 @@ module Attune
65
65
  private
66
66
  # :internal => :external
67
67
  ATTRIBUTE_MAP = {
68
+ :scope => :scope,
68
69
  :entity_type => :entityType,
69
70
  :ids => :ids,
70
71
  :disabled => :disabled,
71
- :scope => :scope,
72
72
  :active_from => :activeFrom,
73
73
  :active_to => :activeTo
74
74
 
@@ -2,63 +2,63 @@ module Attune
2
2
  module Model
3
3
  # Inputs for ranking a set of ids for a particular user.
4
4
  #
5
- # @attr [String] entity_type
6
- # @attr [Array<String>] ids
7
5
  # @attr [Array<Attune::Model::ScopeEntry>] scope
8
- # @attr [String] user_agent
9
- # @attr [String] anonymous
6
+ # @attr [String] view
10
7
  # @attr [String] ip
8
+ # @attr [String] user_agent
9
+ # @attr [String] entity_type
10
+ # @attr [Array<String>] ids
11
11
  # @attr [String] customer
12
- # @attr [String] view
12
+ # @attr [String] anonymous
13
13
  class RankingParams
14
- attr_accessor :entity_type
14
+ attr_accessor :scope
15
15
 
16
16
 
17
- attr_accessor :ids
17
+ attr_accessor :view
18
18
 
19
19
 
20
- attr_accessor :scope
20
+ attr_accessor :ip
21
21
 
22
22
 
23
23
  attr_accessor :user_agent
24
24
 
25
25
 
26
- attr_accessor :anonymous
26
+ attr_accessor :entity_type
27
27
 
28
28
 
29
- attr_accessor :ip
29
+ attr_accessor :ids
30
30
 
31
31
 
32
32
  attr_accessor :customer
33
33
 
34
34
 
35
- attr_accessor :view
35
+ attr_accessor :anonymous
36
36
 
37
37
 
38
38
  def initialize(attributes = {})
39
39
  return if attributes.empty?
40
- # Workaround since JSON.parse has accessors as strings rather than symbols
41
- @entity_type = attributes["entityType"] || attributes[:"entity_type"]
42
- value = attributes["ids"] || attributes[:"ids"]
43
- if value.is_a?(Array)
44
- @ids = value
45
-
46
- end
47
40
  value = attributes["scope"] || attributes[:"scope"]
48
41
  if value.is_a?(Array)
49
42
  @scope = value.map{ |v| ScopeEntry.new(v) }
50
43
 
51
44
  end
52
45
  # Workaround since JSON.parse has accessors as strings rather than symbols
53
- @user_agent = attributes["userAgent"] || attributes[:"user_agent"]
54
- # Workaround since JSON.parse has accessors as strings rather than symbols
55
- @anonymous = attributes["anonymous"] || attributes[:"anonymous"]
46
+ @view = attributes["view"] || attributes[:"view"]
56
47
  # Workaround since JSON.parse has accessors as strings rather than symbols
57
48
  @ip = attributes["ip"] || attributes[:"ip"]
58
49
  # Workaround since JSON.parse has accessors as strings rather than symbols
50
+ @user_agent = attributes["userAgent"] || attributes[:"user_agent"]
51
+ # Workaround since JSON.parse has accessors as strings rather than symbols
52
+ @entity_type = attributes["entityType"] || attributes[:"entity_type"]
53
+ value = attributes["ids"] || attributes[:"ids"]
54
+ if value.is_a?(Array)
55
+ @ids = value
56
+
57
+ end
58
+ # Workaround since JSON.parse has accessors as strings rather than symbols
59
59
  @customer = attributes["customer"] || attributes[:"customer"]
60
60
  # Workaround since JSON.parse has accessors as strings rather than symbols
61
- @view = attributes["view"] || attributes[:"view"]
61
+ @anonymous = attributes["anonymous"] || attributes[:"anonymous"]
62
62
 
63
63
 
64
64
  end
@@ -77,14 +77,14 @@ module Attune
77
77
  private
78
78
  # :internal => :external
79
79
  ATTRIBUTE_MAP = {
80
- :entity_type => :entityType,
81
- :ids => :ids,
82
80
  :scope => :scope,
83
- :user_agent => :userAgent,
84
- :anonymous => :anonymous,
81
+ :view => :view,
85
82
  :ip => :ip,
83
+ :user_agent => :userAgent,
84
+ :entity_type => :entityType,
85
+ :ids => :ids,
86
86
  :customer => :customer,
87
- :view => :view
87
+ :anonymous => :anonymous
88
88
 
89
89
  }
90
90
  end
@@ -1,4 +1,4 @@
1
1
  module Attune
2
- VERSION = "1.0.7"
2
+ VERSION = "1.0.8"
3
3
  end
4
4
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: attune
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.7
4
+ version: 1.0.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - John Hawthorn
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-07-18 00:00:00.000000000 Z
12
+ date: 2014-07-21 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: faraday