yt 0.32.1 → 0.32.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/CHANGELOG.md +5 -0
- data/lib/yt/collections/group_infos.rb +3 -2
- data/lib/yt/collections/group_items.rb +2 -1
- data/lib/yt/collections/reports.rb +7 -6
- data/lib/yt/collections/video_groups.rb +2 -1
- data/lib/yt/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 42cfba8fbb240b3272678d965ba64987563a9a2a2a8ae839a22df6a764722ae3
|
4
|
+
data.tar.gz: e81d7bb9c2cd64ae4fdc9d68dae7a39ae7ff2b0f3ffea3dc27a52103f8a21ec7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a2cbb015d4d363ca40d9238bffabd618edc534f250097ab58548a2f2676334a419dfe8cac893b282063fe03373a1b71f055f90f972d2489ce6e69e81237727f7
|
7
|
+
data.tar.gz: e0bb039d9acfbfb4d2403ffbad549dba4fa359ab9467a6faeed1ff6fe6137adf5dd8c307dbb025f8e4e7a8dc4cb3204a9ef78aff1ca8cfb77fc44ea4197b9fd2
|
data/CHANGELOG.md
CHANGED
@@ -6,6 +6,11 @@ For more information about changelogs, check
|
|
6
6
|
[Keep a Changelog](http://keepachangelog.com) and
|
7
7
|
[Vandamme](http://tech-angels.github.io/vandamme).
|
8
8
|
|
9
|
+
## 0.32.2 - 2018-05-25
|
10
|
+
|
11
|
+
* Use YouTube Analytics API v2 instead of v1. See announcement of v1 deprecation
|
12
|
+
https://developers.google.com/youtube/analytics/revision_history#april-26-2018
|
13
|
+
|
9
14
|
## 0.32.1 - 2017-08-14
|
10
15
|
|
11
16
|
* [FEATURE] Add `Yt::ContentOwner#bulk_report_jobs`
|
@@ -14,7 +14,8 @@ module Yt
|
|
14
14
|
|
15
15
|
def list_params
|
16
16
|
super.tap do |params|
|
17
|
-
params[:
|
17
|
+
params[:host] = 'youtubeanalytics.googleapis.com'
|
18
|
+
params[:path] = "/v2/groups"
|
18
19
|
params[:params] = {id: @parent.id}
|
19
20
|
if @auth.owner_name
|
20
21
|
params[:params][:on_behalf_of_content_owner] = @auth.owner_name
|
@@ -23,4 +24,4 @@ module Yt
|
|
23
24
|
end
|
24
25
|
end
|
25
26
|
end
|
26
|
-
end
|
27
|
+
end
|
@@ -16,7 +16,8 @@ module Yt
|
|
16
16
|
|
17
17
|
def list_params
|
18
18
|
super.tap do |params|
|
19
|
-
params[:
|
19
|
+
params[:host] = 'youtubeanalytics.googleapis.com'
|
20
|
+
params[:path] = "/v2/groupItems"
|
20
21
|
params[:params] = {group_id: @parent.id}
|
21
22
|
if @auth.owner_name
|
22
23
|
params[:params][:on_behalf_of_content_owner] = @auth.owner_name
|
@@ -177,7 +177,8 @@ module Yt
|
|
177
177
|
# @see https://developers.google.com/youtube/analytics/v1/content_owner_reports
|
178
178
|
def list_params
|
179
179
|
super.tap do |params|
|
180
|
-
params[:
|
180
|
+
params[:host] = 'youtubeanalytics.googleapis.com'
|
181
|
+
params[:path] = '/v2/reports'
|
181
182
|
params[:params] = reports_params
|
182
183
|
params[:camelize_params] = false
|
183
184
|
end
|
@@ -185,13 +186,13 @@ module Yt
|
|
185
186
|
|
186
187
|
def reports_params
|
187
188
|
@parent.reports_params.tap do |params|
|
188
|
-
params['
|
189
|
-
params['
|
189
|
+
params['startDate'] = @days_range.begin
|
190
|
+
params['endDate'] = @days_range.end
|
190
191
|
params['metrics'] = @metrics.keys.join(',').to_s.camelize(:lower)
|
191
192
|
params['dimensions'] = DIMENSIONS[@dimension][:name] unless @dimension == :range
|
192
|
-
params['
|
193
|
-
params['
|
194
|
-
params['
|
193
|
+
params['includeHistoricalChannelData'] = @historical if @historical
|
194
|
+
params['maxResults'] = 50 if @dimension.in? [:playlist, :video]
|
195
|
+
params['maxResults'] = 25 if @dimension.in? [:embedded_player_location, :related_video, :search_term, :referrer]
|
195
196
|
if @dimension.in? [:video, :playlist, :embedded_player_location, :related_video, :search_term, :referrer]
|
196
197
|
if @metrics.keys == [:estimated_revenue, :estimated_minutes_watched]
|
197
198
|
params['sort'] = '-estimatedRevenue'
|
data/lib/yt/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: yt
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.32.
|
4
|
+
version: 0.32.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Claudio Baccigalupo
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-05-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -342,7 +342,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
342
342
|
version: '0'
|
343
343
|
requirements: []
|
344
344
|
rubyforge_project:
|
345
|
-
rubygems_version: 2.6
|
345
|
+
rubygems_version: 2.7.6
|
346
346
|
signing_key:
|
347
347
|
specification_version: 4
|
348
348
|
summary: Yt makes it easy to interact with Youtube V3 API by providing a modular,
|