Ziggeo 1.7 → 1.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +65 -4
- data/lib/Ziggeo.rb +25 -2
- data/lib/classes/ZiggeoAnalytics.rb +1 -1
- data/lib/classes/ZiggeoApplication.rb +19 -0
- data/lib/classes/ZiggeoAuthtokens.rb +4 -4
- data/lib/classes/ZiggeoConfig.rb +4 -1
- data/lib/classes/ZiggeoConnect.rb +3 -10
- data/lib/classes/ZiggeoEffectProfileProcess.rb +5 -5
- data/lib/classes/ZiggeoEffectProfiles.rb +8 -4
- data/lib/classes/ZiggeoMetaProfileProcess.rb +6 -6
- data/lib/classes/ZiggeoMetaProfiles.rb +4 -4
- data/lib/classes/ZiggeoStreams.rb +10 -10
- data/lib/classes/ZiggeoVideos.rb +16 -16
- data/lib/classes/ZiggeoWebhooks.rb +2 -2
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 23022f33986e7eed844f4effab99037c67a61047
|
4
|
+
data.tar.gz: 022ece5be7c7f59eac43ad31e044f20fc4849004
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bb1e0978a69afafa934ddfc1b1bbf438ab2e3a677e31650a192bd372b2733d35ed2284e4da6074718674547cab25326b8d5426a4d1257e59342185311f53ec6b
|
7
|
+
data.tar.gz: eb3141ec360e3117c67d0d444d9a82c7fa82356d4192444521d954a6f6c15e5487498f83ca25e49dcf83f442845677473b148abe8ca661074cf989ec983cfe9d
|
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
# Ziggeo Ruby Server SDK 1.
|
1
|
+
# Ziggeo Ruby Server SDK 1.8
|
2
2
|
|
3
3
|
Ziggeo API (https://ziggeo.com) allows you to integrate video recording and playback with only
|
4
4
|
two lines of code in your site, service or app. This is the Ruby Server SDK repository.
|
@@ -443,6 +443,54 @@ Arguments
|
|
443
443
|
- grants: *Permissions this tokens grants*
|
444
444
|
|
445
445
|
|
446
|
+
### Application
|
447
|
+
|
448
|
+
The application token resource allows you to manage your application.
|
449
|
+
|
450
|
+
|
451
|
+
#### Get
|
452
|
+
|
453
|
+
Read application.
|
454
|
+
|
455
|
+
```ruby
|
456
|
+
ziggeo.application().get()
|
457
|
+
```
|
458
|
+
|
459
|
+
|
460
|
+
|
461
|
+
#### Update
|
462
|
+
|
463
|
+
Update application.
|
464
|
+
|
465
|
+
```ruby
|
466
|
+
ziggeo.application().update(arguments = nil)
|
467
|
+
```
|
468
|
+
|
469
|
+
Arguments
|
470
|
+
- volatile: *Will this object automatically be deleted if it remains empty?*
|
471
|
+
- name: *Name of the application*
|
472
|
+
- auth_token_required_for_create: *Require auth token for creating videos*
|
473
|
+
- auth_token_required_for_update: *Require auth token for updating videos*
|
474
|
+
- auth_token_required_for_read: *Require auth token for reading videos*
|
475
|
+
- auth_token_required_for_destroy: *Require auth token for deleting videos*
|
476
|
+
- client_can_index_videos: *Client is allowed to perform the index operation*
|
477
|
+
- client_cannot_access_unaccepted_videos: *Client cannot view unaccepted videos*
|
478
|
+
- enable_video_subpages: *Enable hosted video pages*
|
479
|
+
- enable_facebook: *Enable Facebook Support for hosted video pages*
|
480
|
+
|
481
|
+
|
482
|
+
#### Get Stats
|
483
|
+
|
484
|
+
Read application stats
|
485
|
+
|
486
|
+
```ruby
|
487
|
+
ziggeo.application().get_stats(arguments = nil)
|
488
|
+
```
|
489
|
+
|
490
|
+
Arguments
|
491
|
+
- period: *Optional. Can be 'year' or 'month'.*
|
492
|
+
|
493
|
+
|
446
494
|
### EffectProfiles
|
447
495
|
|
448
496
|
The effect profiles resource allows you to access and create effect profiles for your app. Each effect profile may contain one process or more.
|
@@ -459,6 +507,7 @@ ziggeo.effectProfiles().create(arguments = nil)
|
|
459
507
|
Arguments
|
460
508
|
- key: *Effect profile key.*
|
461
509
|
- title: *Effect profile title.*
|
510
|
+
- default_effect: *Boolean. If TRUE, sets an effect profile as default. If FALSE, removes the default status for the given effect*
|
462
511
|
|
463
512
|
|
464
513
|
#### Index
|
@@ -495,6 +544,18 @@ ziggeo.effectProfiles().delete(token_or_key)
|
|
495
544
|
|
496
545
|
|
497
546
|
|
547
|
+
#### Update
|
548
|
+
|
549
|
+
Updates an effect profile.
|
550
|
+
|
551
|
+
```ruby
|
552
|
+
ziggeo.effectProfiles().update(token_or_key, arguments = nil)
|
553
|
+
```
|
554
|
+
|
555
|
+
Arguments
|
556
|
+
- default_effect: *Boolean. If TRUE, sets an effect profile as default. If FALSE, removes the default status for the given effect*
|
557
|
+
|
558
|
+
|
498
559
|
### EffectProfileProcess
|
499
560
|
|
500
561
|
The process resource allows you to directly access all process associated with a single effect profile.
|
@@ -554,9 +615,9 @@ ziggeo.effectProfileProcess().create_watermark_process(effect_token_or_key, argu
|
|
554
615
|
|
555
616
|
Arguments
|
556
617
|
- file: *Image file to be attached*
|
557
|
-
-
|
558
|
-
-
|
559
|
-
-
|
618
|
+
- vertical_position: *Specify the vertical position of your watermark (a value between 0.0 and 1.0)*
|
619
|
+
- horizontal_position: *Specify the horizontal position of your watermark (a value between 0.0 and 1.0)*
|
620
|
+
- video_scale: *Specify the image scale of your watermark (a value between 0.0 and 1.0)*
|
560
621
|
|
561
622
|
|
562
623
|
### MetaProfiles
|
data/lib/Ziggeo.rb
CHANGED
@@ -9,6 +9,7 @@ require_relative "classes/ZiggeoAuth"
|
|
9
9
|
require_relative "classes/ZiggeoVideos"
|
10
10
|
require_relative "classes/ZiggeoStreams"
|
11
11
|
require_relative "classes/ZiggeoAuthtokens"
|
12
|
+
require_relative "classes/ZiggeoApplication"
|
12
13
|
require_relative "classes/ZiggeoEffectProfiles"
|
13
14
|
require_relative "classes/ZiggeoEffectProfileProcess"
|
14
15
|
require_relative "classes/ZiggeoMetaProfiles"
|
@@ -18,18 +19,34 @@ require_relative "classes/ZiggeoAnalytics"
|
|
18
19
|
|
19
20
|
class Ziggeo
|
20
21
|
|
21
|
-
attr_accessor :token, :private_key, :encryption_key, :config, :connect
|
22
|
+
attr_accessor :token, :private_key, :encryption_key, :config, :connect, :api_connect
|
22
23
|
|
23
24
|
def initialize(token = nil, private_key = nil, encryption_key = nil)
|
24
25
|
@token = token
|
25
26
|
@private_key = private_key
|
26
27
|
@encryption_key = encryption_key
|
27
28
|
@config = ZiggeoConfig.new()
|
28
|
-
|
29
|
+
server_api_url = @config.server_api_url
|
30
|
+
regions = @config.regions
|
31
|
+
regions.each do |key, value|
|
32
|
+
if (@token.start_with?(key))
|
33
|
+
server_api_url = value
|
34
|
+
end
|
35
|
+
end
|
36
|
+
@connect = ZiggeoConnect.new(self, server_api_url)
|
37
|
+
api_url = @config.api_url
|
38
|
+
api_regions = @config.api_regions
|
39
|
+
api_regions.each do |key, value|
|
40
|
+
if (@token.start_with?(key))
|
41
|
+
api_url = value
|
42
|
+
end
|
43
|
+
end
|
44
|
+
@api_connect = ZiggeoConnect.new(self, api_url)
|
29
45
|
@auth = nil
|
30
46
|
@videos = nil
|
31
47
|
@streams = nil
|
32
48
|
@authtokens = nil
|
49
|
+
@application = nil
|
33
50
|
@effectProfiles = nil
|
34
51
|
@effectProfileProcess = nil
|
35
52
|
@metaProfiles = nil
|
@@ -70,6 +87,12 @@ class Ziggeo
|
|
70
87
|
end
|
71
88
|
return @authtokens end
|
72
89
|
|
90
|
+
def application()
|
91
|
+
if (@application == nil)
|
92
|
+
@application = ZiggeoApplication.new(self)
|
93
|
+
end
|
94
|
+
return @application end
|
95
|
+
|
73
96
|
def effectProfiles()
|
74
97
|
if (@effectProfiles == nil)
|
75
98
|
@effectProfiles = ZiggeoEffectProfiles.new(self)
|
@@ -0,0 +1,19 @@
|
|
1
|
+
class ZiggeoApplication
|
2
|
+
|
3
|
+
def initialize(application)
|
4
|
+
@application = application
|
5
|
+
end
|
6
|
+
|
7
|
+
def get()
|
8
|
+
return @application.connect.getJSON('/v1/application')
|
9
|
+
end
|
10
|
+
|
11
|
+
def update(data = nil)
|
12
|
+
return @application.connect.postJSON('/v1/application', data)
|
13
|
+
end
|
14
|
+
|
15
|
+
def get_stats(data = nil)
|
16
|
+
return @application.api_connect.getJSON('/server/v1/application/stats', data)
|
17
|
+
end
|
18
|
+
|
19
|
+
end
|
@@ -5,19 +5,19 @@ class ZiggeoAuthtokens
|
|
5
5
|
end
|
6
6
|
|
7
7
|
def get(token)
|
8
|
-
return @application.connect.getJSON('/authtokens/' + token + '')
|
8
|
+
return @application.connect.getJSON('/v1/authtokens/' + token + '')
|
9
9
|
end
|
10
10
|
|
11
11
|
def update(token_or_key, data = nil)
|
12
|
-
return @application.connect.postJSON('/authtokens/' + token_or_key + '', data)
|
12
|
+
return @application.connect.postJSON('/v1/authtokens/' + token_or_key + '', data)
|
13
13
|
end
|
14
14
|
|
15
15
|
def delete(token_or_key)
|
16
|
-
return @application.connect.delete('/authtokens/' + token_or_key + '')
|
16
|
+
return @application.connect.delete('/v1/authtokens/' + token_or_key + '')
|
17
17
|
end
|
18
18
|
|
19
19
|
def create(data = nil)
|
20
|
-
return @application.connect.postJSON('/authtokens/', data)
|
20
|
+
return @application.connect.postJSON('/v1/authtokens/', data)
|
21
21
|
end
|
22
22
|
|
23
23
|
end
|
data/lib/classes/ZiggeoConfig.rb
CHANGED
@@ -1,10 +1,13 @@
|
|
1
|
+
|
1
2
|
class ZiggeoConfig
|
2
|
-
attr_accessor :server_api_url, :request_timeout, :request_timeout_per_mb, :regions
|
3
|
+
attr_accessor :server_api_url, :api_url, :request_timeout, :request_timeout_per_mb, :regions, :api_regions
|
3
4
|
|
4
5
|
def initialize()
|
5
6
|
@request_timeout = 30 # seconds
|
6
7
|
@request_timeout_per_mb = 20 # seconds per MB of uploaded file
|
7
8
|
@server_api_url = "https://srvapi.ziggeo.com"
|
9
|
+
@api_url = "https://api-us-east-1.ziggeo.com"
|
8
10
|
@regions = {"r1" => "https://srvapi-eu-west-1.ziggeo.com", }
|
11
|
+
@api_regions = {"r1" => "https://api-eu-west-1.ziggeo.com", }
|
9
12
|
end
|
10
13
|
end
|
@@ -4,20 +4,13 @@ require 'httparty'
|
|
4
4
|
require 'httmultiparty'
|
5
5
|
|
6
6
|
class ZiggeoConnect
|
7
|
-
def initialize(application)
|
7
|
+
def initialize(application, baseuri)
|
8
8
|
@application = application
|
9
|
+
@baseuri = baseuri
|
9
10
|
end
|
10
11
|
|
11
12
|
def request(method, path, data = nil, file = nil)
|
12
|
-
|
13
|
-
regions = @application.config.regions
|
14
|
-
regions.each do |key, value|
|
15
|
-
if (@application.token.start_with?(key))
|
16
|
-
server_api_url = value
|
17
|
-
end
|
18
|
-
end
|
19
|
-
|
20
|
-
url = URI.parse(server_api_url + '/v1' + path)
|
13
|
+
url = URI.parse(@baseuri + path)
|
21
14
|
auth = { username: @application.token, password: @application.private_key }
|
22
15
|
timeout_in_seconds = @application.config.request_timeout.to_i
|
23
16
|
|
@@ -5,23 +5,23 @@ class ZiggeoEffectProfileProcess
|
|
5
5
|
end
|
6
6
|
|
7
7
|
def index(effect_token_or_key, data = nil)
|
8
|
-
return @application.connect.getJSON('/effects/' + effect_token_or_key + '/process', data)
|
8
|
+
return @application.connect.getJSON('/v1/effects/' + effect_token_or_key + '/process', data)
|
9
9
|
end
|
10
10
|
|
11
11
|
def get(effect_token_or_key, token_or_key)
|
12
|
-
return @application.connect.getJSON('/effects/' + effect_token_or_key + '/process/' + token_or_key + '')
|
12
|
+
return @application.connect.getJSON('/v1/effects/' + effect_token_or_key + '/process/' + token_or_key + '')
|
13
13
|
end
|
14
14
|
|
15
15
|
def delete(effect_token_or_key, token_or_key)
|
16
|
-
return @application.connect.delete('/effects/' + effect_token_or_key + '/process/' + token_or_key + '')
|
16
|
+
return @application.connect.delete('/v1/effects/' + effect_token_or_key + '/process/' + token_or_key + '')
|
17
17
|
end
|
18
18
|
|
19
19
|
def create_filter_process(effect_token_or_key, data = nil)
|
20
|
-
return @application.connect.postJSON('/effects/' + effect_token_or_key + '/process/filter', data)
|
20
|
+
return @application.connect.postJSON('/v1/effects/' + effect_token_or_key + '/process/filter', data)
|
21
21
|
end
|
22
22
|
|
23
23
|
def create_watermark_process(effect_token_or_key, data = nil, file = nil)
|
24
|
-
return @application.connect.postJSON('/effects/' + effect_token_or_key + '/process/watermark', data, file)
|
24
|
+
return @application.connect.postJSON('/v1/effects/' + effect_token_or_key + '/process/watermark', data, file)
|
25
25
|
end
|
26
26
|
|
27
27
|
end
|
@@ -5,19 +5,23 @@ class ZiggeoEffectProfiles
|
|
5
5
|
end
|
6
6
|
|
7
7
|
def create(data = nil)
|
8
|
-
return @application.connect.postJSON('/effects/', data)
|
8
|
+
return @application.connect.postJSON('/v1/effects/', data)
|
9
9
|
end
|
10
10
|
|
11
11
|
def index(data = nil)
|
12
|
-
return @application.connect.getJSON('/effects/', data)
|
12
|
+
return @application.connect.getJSON('/v1/effects/', data)
|
13
13
|
end
|
14
14
|
|
15
15
|
def get(token_or_key)
|
16
|
-
return @application.connect.getJSON('/effects/' + token_or_key + '')
|
16
|
+
return @application.connect.getJSON('/v1/effects/' + token_or_key + '')
|
17
17
|
end
|
18
18
|
|
19
19
|
def delete(token_or_key)
|
20
|
-
return @application.connect.delete('/effects/' + token_or_key + '')
|
20
|
+
return @application.connect.delete('/v1/effects/' + token_or_key + '')
|
21
|
+
end
|
22
|
+
|
23
|
+
def update(token_or_key, data = nil)
|
24
|
+
return @application.connect.postJSON('/v1/effects/' + token_or_key + '', data)
|
21
25
|
end
|
22
26
|
|
23
27
|
end
|
@@ -5,27 +5,27 @@ class ZiggeoMetaProfileProcess
|
|
5
5
|
end
|
6
6
|
|
7
7
|
def index(meta_token_or_key)
|
8
|
-
return @application.connect.getJSON('/metaprofiles/' + meta_token_or_key + '/process')
|
8
|
+
return @application.connect.getJSON('/v1/metaprofiles/' + meta_token_or_key + '/process')
|
9
9
|
end
|
10
10
|
|
11
11
|
def get(meta_token_or_key, token_or_key)
|
12
|
-
return @application.connect.getJSON('/metaprofiles/' + meta_token_or_key + '/process/' + token_or_key + '')
|
12
|
+
return @application.connect.getJSON('/v1/metaprofiles/' + meta_token_or_key + '/process/' + token_or_key + '')
|
13
13
|
end
|
14
14
|
|
15
15
|
def delete(meta_token_or_key, token_or_key)
|
16
|
-
return @application.connect.delete('/metaprofiles/' + meta_token_or_key + '/process/' + token_or_key + '')
|
16
|
+
return @application.connect.delete('/v1/metaprofiles/' + meta_token_or_key + '/process/' + token_or_key + '')
|
17
17
|
end
|
18
18
|
|
19
19
|
def create_video_analysis_process(meta_token_or_key)
|
20
|
-
return @application.connect.postJSON('/metaprofiles/' + meta_token_or_key + '/process/analysis')
|
20
|
+
return @application.connect.postJSON('/v1/metaprofiles/' + meta_token_or_key + '/process/analysis')
|
21
21
|
end
|
22
22
|
|
23
23
|
def create_audio_transcription_process(meta_token_or_key)
|
24
|
-
return @application.connect.postJSON('/metaprofiles/' + meta_token_or_key + '/process/transcription')
|
24
|
+
return @application.connect.postJSON('/v1/metaprofiles/' + meta_token_or_key + '/process/transcription')
|
25
25
|
end
|
26
26
|
|
27
27
|
def create_nsfw_process(meta_token_or_key, data = nil)
|
28
|
-
return @application.connect.postJSON('/metaprofiles/' + meta_token_or_key + '/process/nsfw', data)
|
28
|
+
return @application.connect.postJSON('/v1/metaprofiles/' + meta_token_or_key + '/process/nsfw', data)
|
29
29
|
end
|
30
30
|
|
31
31
|
end
|
@@ -5,19 +5,19 @@ class ZiggeoMetaProfiles
|
|
5
5
|
end
|
6
6
|
|
7
7
|
def create(data = nil)
|
8
|
-
return @application.connect.postJSON('/metaprofiles/', data)
|
8
|
+
return @application.connect.postJSON('/v1/metaprofiles/', data)
|
9
9
|
end
|
10
10
|
|
11
11
|
def index(data = nil)
|
12
|
-
return @application.connect.getJSON('/metaprofiles/', data)
|
12
|
+
return @application.connect.getJSON('/v1/metaprofiles/', data)
|
13
13
|
end
|
14
14
|
|
15
15
|
def get(token_or_key)
|
16
|
-
return @application.connect.getJSON('/metaprofiles/' + token_or_key + '')
|
16
|
+
return @application.connect.getJSON('/v1/metaprofiles/' + token_or_key + '')
|
17
17
|
end
|
18
18
|
|
19
19
|
def delete(token_or_key)
|
20
|
-
return @application.connect.delete('/metaprofiles/' + token_or_key + '')
|
20
|
+
return @application.connect.delete('/v1/metaprofiles/' + token_or_key + '')
|
21
21
|
end
|
22
22
|
|
23
23
|
end
|
@@ -5,43 +5,43 @@ class ZiggeoStreams
|
|
5
5
|
end
|
6
6
|
|
7
7
|
def index(video_token_or_key, data = nil)
|
8
|
-
return @application.connect.getJSON('/videos/' + video_token_or_key + '/streams', data)
|
8
|
+
return @application.connect.getJSON('/v1/videos/' + video_token_or_key + '/streams', data)
|
9
9
|
end
|
10
10
|
|
11
11
|
def get(video_token_or_key, token_or_key)
|
12
|
-
return @application.connect.getJSON('/videos/' + video_token_or_key + '/streams/' + token_or_key + '')
|
12
|
+
return @application.connect.getJSON('/v1/videos/' + video_token_or_key + '/streams/' + token_or_key + '')
|
13
13
|
end
|
14
14
|
|
15
15
|
def download_video(video_token_or_key, token_or_key)
|
16
|
-
return @application.connect.get('/videos/' + video_token_or_key + '/streams/' + token_or_key + '/video')
|
16
|
+
return @application.connect.get('/v1/videos/' + video_token_or_key + '/streams/' + token_or_key + '/video')
|
17
17
|
end
|
18
18
|
|
19
19
|
def download_image(video_token_or_key, token_or_key)
|
20
|
-
return @application.connect.get('/videos/' + video_token_or_key + '/streams/' + token_or_key + '/image')
|
20
|
+
return @application.connect.get('/v1/videos/' + video_token_or_key + '/streams/' + token_or_key + '/image')
|
21
21
|
end
|
22
22
|
|
23
23
|
def push_to_service(video_token_or_key, token_or_key, data = nil)
|
24
|
-
return @application.connect.postJSON('/videos/' + video_token_or_key + '/streams/' + token_or_key + '/push', data)
|
24
|
+
return @application.connect.postJSON('/v1/videos/' + video_token_or_key + '/streams/' + token_or_key + '/push', data)
|
25
25
|
end
|
26
26
|
|
27
27
|
def delete(video_token_or_key, token_or_key)
|
28
|
-
return @application.connect.delete('/videos/' + video_token_or_key + '/streams/' + token_or_key + '')
|
28
|
+
return @application.connect.delete('/v1/videos/' + video_token_or_key + '/streams/' + token_or_key + '')
|
29
29
|
end
|
30
30
|
|
31
31
|
def create(video_token_or_key, data = nil, file = nil)
|
32
|
-
return @application.connect.postJSON('/videos/' + video_token_or_key + '/streams', data, file)
|
32
|
+
return @application.connect.postJSON('/v1/videos/' + video_token_or_key + '/streams', data, file)
|
33
33
|
end
|
34
34
|
|
35
35
|
def attach_image(video_token_or_key, token_or_key, data = nil, file = nil)
|
36
|
-
return @application.connect.postJSON('/videos/' + video_token_or_key + '/streams/' + token_or_key + '/image', data, file)
|
36
|
+
return @application.connect.postJSON('/v1/videos/' + video_token_or_key + '/streams/' + token_or_key + '/image', data, file)
|
37
37
|
end
|
38
38
|
|
39
39
|
def attach_video(video_token_or_key, token_or_key, data = nil, file = nil)
|
40
|
-
return @application.connect.postJSON('/videos/' + video_token_or_key + '/streams/' + token_or_key + '/video', data, file)
|
40
|
+
return @application.connect.postJSON('/v1/videos/' + video_token_or_key + '/streams/' + token_or_key + '/video', data, file)
|
41
41
|
end
|
42
42
|
|
43
43
|
def bind(video_token_or_key, token_or_key)
|
44
|
-
return @application.connect.postJSON('/videos/' + video_token_or_key + '/streams/' + token_or_key + '/bind')
|
44
|
+
return @application.connect.postJSON('/v1/videos/' + video_token_or_key + '/streams/' + token_or_key + '/bind')
|
45
45
|
end
|
46
46
|
|
47
47
|
end
|
data/lib/classes/ZiggeoVideos.rb
CHANGED
@@ -5,67 +5,67 @@ class ZiggeoVideos
|
|
5
5
|
end
|
6
6
|
|
7
7
|
def index(data = nil)
|
8
|
-
return @application.connect.getJSON('/videos/', data)
|
8
|
+
return @application.connect.getJSON('/v1/videos/', data)
|
9
9
|
end
|
10
10
|
|
11
11
|
def count(data = nil)
|
12
|
-
return @application.connect.getJSON('/videos/count', data)
|
12
|
+
return @application.connect.getJSON('/v1/videos/count', data)
|
13
13
|
end
|
14
14
|
|
15
15
|
def get(token_or_key)
|
16
|
-
return @application.connect.getJSON('/videos/' + token_or_key + '')
|
16
|
+
return @application.connect.getJSON('/v1/videos/' + token_or_key + '')
|
17
17
|
end
|
18
18
|
|
19
19
|
def get_bulk(data = nil)
|
20
|
-
return @application.connect.postJSON('/videos/get_bulk', data)
|
20
|
+
return @application.connect.postJSON('/v1/videos/get_bulk', data)
|
21
21
|
end
|
22
22
|
|
23
23
|
def stats_bulk(data = nil)
|
24
|
-
return @application.connect.postJSON('/videos/stats_bulk', data)
|
24
|
+
return @application.connect.postJSON('/v1/videos/stats_bulk', data)
|
25
25
|
end
|
26
26
|
|
27
27
|
def download_video(token_or_key)
|
28
|
-
return @application.connect.get('/videos/' + token_or_key + '/video')
|
28
|
+
return @application.connect.get('/v1/videos/' + token_or_key + '/video')
|
29
29
|
end
|
30
30
|
|
31
31
|
def download_image(token_or_key)
|
32
|
-
return @application.connect.get('/videos/' + token_or_key + '/image')
|
32
|
+
return @application.connect.get('/v1/videos/' + token_or_key + '/image')
|
33
33
|
end
|
34
34
|
|
35
35
|
def get_stats(token_or_key)
|
36
|
-
return @application.connect.getJSON('/videos/' + token_or_key + '/stats')
|
36
|
+
return @application.connect.getJSON('/v1/videos/' + token_or_key + '/stats')
|
37
37
|
end
|
38
38
|
|
39
39
|
def push_to_service(token_or_key, data = nil)
|
40
|
-
return @application.connect.postJSON('/videos/' + token_or_key + '/push', data)
|
40
|
+
return @application.connect.postJSON('/v1/videos/' + token_or_key + '/push', data)
|
41
41
|
end
|
42
42
|
|
43
43
|
def apply_effect(token_or_key, data = nil)
|
44
|
-
return @application.connect.postJSON('/videos/' + token_or_key + '/effect', data)
|
44
|
+
return @application.connect.postJSON('/v1/videos/' + token_or_key + '/effect', data)
|
45
45
|
end
|
46
46
|
|
47
47
|
def apply_meta(token_or_key, data = nil)
|
48
|
-
return @application.connect.postJSON('/videos/' + token_or_key + '/metaprofile', data)
|
48
|
+
return @application.connect.postJSON('/v1/videos/' + token_or_key + '/metaprofile', data)
|
49
49
|
end
|
50
50
|
|
51
51
|
def update(token_or_key, data = nil)
|
52
|
-
return @application.connect.postJSON('/videos/' + token_or_key + '', data)
|
52
|
+
return @application.connect.postJSON('/v1/videos/' + token_or_key + '', data)
|
53
53
|
end
|
54
54
|
|
55
55
|
def update_bulk(data = nil)
|
56
|
-
return @application.connect.postJSON('/videos/update_bulk', data)
|
56
|
+
return @application.connect.postJSON('/v1/videos/update_bulk', data)
|
57
57
|
end
|
58
58
|
|
59
59
|
def delete(token_or_key)
|
60
|
-
return @application.connect.delete('/videos/' + token_or_key + '')
|
60
|
+
return @application.connect.delete('/v1/videos/' + token_or_key + '')
|
61
61
|
end
|
62
62
|
|
63
63
|
def create(data = nil, file = nil)
|
64
|
-
return @application.connect.postJSON('/videos/', data, file)
|
64
|
+
return @application.connect.postJSON('/v1/videos/', data, file)
|
65
65
|
end
|
66
66
|
|
67
67
|
def analytics(token_or_key, data = nil)
|
68
|
-
return @application.connect.postJSON('/videos/' + token_or_key + '/analytics', data)
|
68
|
+
return @application.connect.postJSON('/v1/videos/' + token_or_key + '/analytics', data)
|
69
69
|
end
|
70
70
|
|
71
71
|
end
|
@@ -5,11 +5,11 @@ class ZiggeoWebhooks
|
|
5
5
|
end
|
6
6
|
|
7
7
|
def create(data = nil)
|
8
|
-
return @application.connect.post('/api/hook', data)
|
8
|
+
return @application.connect.post('/v1/api/hook', data)
|
9
9
|
end
|
10
10
|
|
11
11
|
def delete(data = nil)
|
12
|
-
return @application.connect.post('/api/removehook', data)
|
12
|
+
return @application.connect.post('/v1/api/removehook', data)
|
13
13
|
end
|
14
14
|
|
15
15
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: Ziggeo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '1.
|
4
|
+
version: '1.8'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ziggeo, Inc
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-09-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: httparty
|
@@ -48,6 +48,7 @@ files:
|
|
48
48
|
- README.md
|
49
49
|
- lib/Ziggeo.rb
|
50
50
|
- lib/classes/ZiggeoAnalytics.rb
|
51
|
+
- lib/classes/ZiggeoApplication.rb
|
51
52
|
- lib/classes/ZiggeoAuth.rb
|
52
53
|
- lib/classes/ZiggeoAuthtokens.rb
|
53
54
|
- lib/classes/ZiggeoConfig.rb
|