customerio 4.1.0 → 4.2.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: b4effd60709e999b2530ceb0cdbd5125a163543d5f842657d13bb57b4cf10b92
4
- data.tar.gz: 6cb74d720acb7f4ac284c760cd92aa4a774d5762dd886ee7d68d8cacc42dd677
3
+ metadata.gz: e58bba756887e5c3ae6e7aa75b3e2c5bd08fc5733d45ee513b56895e35b58011
4
+ data.tar.gz: 912374a003fe636fc5837cbf030a64141218f83b63fb9e455efa033375a2a8bb
5
5
  SHA512:
6
- metadata.gz: 8004b7a1062fabdaa46378a5e9f9a14138ca6bd2c45d6cb246636e112207be11cb68b8a561ca9e507b11ff803ffd8e4f1e0765f6cbecac7dc413c36c9e58adcf
7
- data.tar.gz: cf8908e63e075e7a6989c777de2d5bb3f538025bfe6820d6c9d58848fea3ebc3f4a3b054ee94799671f71bf3b1b19678fd0f4051373fcf666c64020eb50b239f
6
+ metadata.gz: 1529f5cc20959ce9cdbe9e4103a29f5b5205594727b8951be18d61a6851520741e52150b20b20603b7d890f62ab56c3d391d9503d6c21e99a31032085da06557
7
+ data.tar.gz: '08adc273fd1d1cf2df0453788ac9c8889b8576aadf865cd9d587f029fe4de4a05b35d61dbcd845da2fdbba81b056bd7d3b92a9d7d2a3ad8800a3ad6b87ecb313'
@@ -44,6 +44,8 @@ module Customerio
44
44
 
45
45
  req = request_class(method).new(uri.path)
46
46
 
47
+ headers['User-Agent'] = "Customer.io Ruby Client/" + Customerio::VERSION
48
+
47
49
  if @auth.has_key?(:site_id) && @auth.has_key?(:api_key)
48
50
  req.initialize_http_header(headers)
49
51
  req.basic_auth @auth[:site_id], @auth[:api_key]
@@ -1,3 +1,3 @@
1
1
  module Customerio
2
- VERSION = "4.1.0"
2
+ VERSION = "4.2.0"
3
3
  end
@@ -14,7 +14,7 @@ describe Customerio::APIClient do
14
14
  end
15
15
 
16
16
  def request_headers
17
- { 'Authorization': "Bearer #{app_key}", 'Content-Type': 'application/json' }
17
+ { 'Authorization': "Bearer #{app_key}", 'Content-Type': 'application/json', 'User-Agent': 'Customer.io Ruby Client/' + Customerio::VERSION }
18
18
  end
19
19
 
20
20
  def json(data)
@@ -18,11 +18,11 @@ describe Customerio::BaseClient do
18
18
 
19
19
  def track_client_request_headers
20
20
  token = Base64.strict_encode64("#{site_id}:#{api_key}")
21
- { 'Authorization': "Basic #{token}", 'Content-Type': 'application/json' }
21
+ { 'Authorization': "Basic #{token}", 'Content-Type': 'application/json', 'User-Agent': 'Customer.io Ruby Client/' + Customerio::VERSION }
22
22
  end
23
23
 
24
24
  def api_client_request_headers
25
- { 'Authorization': "Bearer #{app_key}", 'Content-Type': 'application/json' }
25
+ { 'Authorization': "Bearer #{app_key}", 'Content-Type': 'application/json', 'User-Agent': 'Customer.io Ruby Client/' + Customerio::VERSION }
26
26
  end
27
27
 
28
28
  describe "with a site ID and API key" do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: customerio
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.0
4
+ version: 4.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - John Allison
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-09-27 00:00:00.000000000 Z
11
+ date: 2021-10-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: multi_json
@@ -140,7 +140,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
140
140
  - !ruby/object:Gem::Version
141
141
  version: '0'
142
142
  requirements: []
143
- rubygems_version: 3.2.22
143
+ rubygems_version: 3.0.3
144
144
  signing_key:
145
145
  specification_version: 4
146
146
  summary: A ruby client for the Customer.io event API.