strongmind-agilix-buzz-client 0.8.3
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 +7 -0
- data/.coveralls.yml +1 -0
- data/.env.sample +5 -0
- data/.github/workflows/dependabot-auto-merge.yml +0 -0
- data/.github/workflows/publish-gem.yml +51 -0
- data/.github/workflows/velocityCheckin.yml +45 -0
- data/.gitignore +25 -0
- data/.idea/.gitignore +8 -0
- data/.idea/agilix-buzz-client.iml +61 -0
- data/.idea/misc.xml +4 -0
- data/.idea/modules.xml +8 -0
- data/.idea/vcs.xml +6 -0
- data/CODE_OF_CONDUCT.md +74 -0
- data/Gemfile +6 -0
- data/LICENSE.txt +21 -0
- data/README.md +955 -0
- data/Rakefile +10 -0
- data/agilix.gemspec +40 -0
- data/bin/console +16 -0
- data/bin/setup +8 -0
- data/lib/agilix/buzz/api.rb +175 -0
- data/lib/agilix/buzz/commands/authentication.rb +153 -0
- data/lib/agilix/buzz/commands/course.rb +91 -0
- data/lib/agilix/buzz/commands/domain.rb +85 -0
- data/lib/agilix/buzz/commands/enrollment.rb +140 -0
- data/lib/agilix/buzz/commands/general.rb +70 -0
- data/lib/agilix/buzz/commands/library.rb +43 -0
- data/lib/agilix/buzz/commands/report.rb +37 -0
- data/lib/agilix/buzz/commands/resource.rb +124 -0
- data/lib/agilix/buzz/commands/right.rb +234 -0
- data/lib/agilix/buzz/commands/user.rb +85 -0
- data/lib/agilix/version.rb +3 -0
- data/lib/agilix.rb +31 -0
- data/stats.html +1 -0
- metadata +205 -0
@@ -0,0 +1,85 @@
|
|
1
|
+
module Agilix
|
2
|
+
module Buzz
|
3
|
+
module Commands
|
4
|
+
module User
|
5
|
+
|
6
|
+
# api.create_users [{ domainid: '57025', username: "BuzzUserTest1", email: 'buzzusertest1@agilix.com', password: 'testpassword1234', firstname: 'Buzz', lastname: "Man", passwordquestion: "Who's your best friend?", passwordanswer: "Me"}]
|
7
|
+
def create_users2(items = [])
|
8
|
+
options = items.map do |item|
|
9
|
+
argument_cleaner(required_params: %i( domainid username email password firstname lastname ), optional_params: %i( passwordquestion passwordanswer reference flags rights roleid data ), options: item )
|
10
|
+
end
|
11
|
+
authenticated_bulk_post cmd: "createusers2", root_node: 'user', body: options
|
12
|
+
end
|
13
|
+
alias_method :create_users, :create_users2
|
14
|
+
|
15
|
+
# api.delete_users [userid: '57181']
|
16
|
+
def delete_users(items = {})
|
17
|
+
options = items.map do |item|
|
18
|
+
argument_cleaner(required_params: %i( userid ), optional_params: %i( ), options: item )
|
19
|
+
end
|
20
|
+
authenticated_bulk_post cmd: "deleteusers", root_node: 'user', body: options
|
21
|
+
end
|
22
|
+
|
23
|
+
# api.get_active_user_count domainid: '57025'
|
24
|
+
# api.get_active_user_count domainid: '5', includedescendantdomains: true, bymonth:true, startdate: '2018-01-01', enddate: '2019-03-01'
|
25
|
+
def get_active_user_count(options = {})
|
26
|
+
options = argument_cleaner(required_params: %i( domainid ), optional_params: %i(includedescendantdomains persona startdate enddate byday bymonth byyear ), options: options)
|
27
|
+
authenticated_get cmd: "getactiveusercount", **options
|
28
|
+
end
|
29
|
+
|
30
|
+
# api.get_domain_activity domainid: '57025'
|
31
|
+
def get_domain_activity(options = {})
|
32
|
+
options = argument_cleaner(required_params: %i( domainid ), optional_params: %i( startdate enddate maxusers select ), options: options)
|
33
|
+
authenticated_get cmd: "getdomainactivity", **options
|
34
|
+
end
|
35
|
+
|
36
|
+
# api.get_profile_picture entityid: 57026
|
37
|
+
# api.get_profile_picture entityid: 57025, default: "https://www.gravatar.com/avatar/00000000000000000000000000000000?d=mm"
|
38
|
+
def get_profile_picture(options = {})
|
39
|
+
options = argument_cleaner(required_params: %i( entityid ), optional_params: %i( default ), options: options)
|
40
|
+
authenticated_get cmd: "getprofilepicture", **options
|
41
|
+
end
|
42
|
+
|
43
|
+
# api.get_user2 userid: 57026
|
44
|
+
def get_user2(options = {})
|
45
|
+
options = argument_cleaner(required_params: %i( userid ), optional_params: %i( select ), options: options)
|
46
|
+
authenticated_get cmd: "getuser2", **options
|
47
|
+
end
|
48
|
+
alias_method :get_user, :get_user2
|
49
|
+
|
50
|
+
# api.get_user_activity userid: 57026
|
51
|
+
def get_user_activity(options = {})
|
52
|
+
options = argument_cleaner(required_params: %i( userid ), optional_params: %i( startdate enddate ), options: options)
|
53
|
+
authenticated_get cmd: "getuseractivity", **options
|
54
|
+
end
|
55
|
+
|
56
|
+
# api.get_user_activity_stream userid: 57026
|
57
|
+
def get_user_activity_stream(options = {})
|
58
|
+
options = argument_cleaner(required_params: %i( userid ), optional_params: %i( enrollmentid startkey limit types ), options: options)
|
59
|
+
authenticated_get cmd: "getuseractivitystream", **options
|
60
|
+
end
|
61
|
+
|
62
|
+
# api.list_users domainid: 57025
|
63
|
+
def list_users(options = {})
|
64
|
+
options = argument_cleaner(required_params: %i( domainid ), optional_params: %i( includedescendantdomains limit show select text query ), options: options)
|
65
|
+
authenticated_get cmd: "listusers", **options
|
66
|
+
end
|
67
|
+
|
68
|
+
# api.restore_user userid: 57026
|
69
|
+
def restore_user(options = {})
|
70
|
+
options = argument_cleaner(required_params: %i( userid ), optional_params: %i( ), options: options)
|
71
|
+
authenticated_get cmd: "restoreuser", **options
|
72
|
+
end
|
73
|
+
|
74
|
+
# api.update_users [{ userid: '57026', username: "BuzzUserTestUpdated1", email: 'buzzusertest1@agilix.com',firstname: 'Buzz', lastname: "ManUpdated"}]
|
75
|
+
def update_users(items)
|
76
|
+
options = items.map do |item|
|
77
|
+
argument_cleaner(required_params: %i( userid ), optional_params: %i( domainid username firstname lastname email reference flags data ), options: item)
|
78
|
+
end
|
79
|
+
authenticated_bulk_post cmd: "updateusers", root_node: 'user', body: options
|
80
|
+
end
|
81
|
+
|
82
|
+
end
|
83
|
+
end
|
84
|
+
end
|
85
|
+
end
|
data/lib/agilix.rb
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
|
2
|
+
# require "active_support/all"
|
3
|
+
require "httparty"
|
4
|
+
require "ostruct"
|
5
|
+
|
6
|
+
require "agilix/buzz/commands/authentication"
|
7
|
+
require "agilix/buzz/commands/course"
|
8
|
+
require "agilix/buzz/commands/domain"
|
9
|
+
require "agilix/buzz/commands/enrollment"
|
10
|
+
require "agilix/buzz/commands/general"
|
11
|
+
require "agilix/buzz/commands/library"
|
12
|
+
require "agilix/buzz/commands/report"
|
13
|
+
require "agilix/buzz/commands/resource"
|
14
|
+
require "agilix/buzz/commands/right"
|
15
|
+
require "agilix/buzz/commands/user"
|
16
|
+
|
17
|
+
require "agilix/buzz/api"
|
18
|
+
require "agilix/version"
|
19
|
+
|
20
|
+
|
21
|
+
|
22
|
+
module Agilix
|
23
|
+
module Buzz
|
24
|
+
class Api::AuthenticationError < StandardError
|
25
|
+
def initialize(msg="Could not Authenticate")
|
26
|
+
super
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
30
|
+
end
|
31
|
+
end
|
data/stats.html
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
<div style=\"text-indent:0em\"><h1>certificates: <div style=\"display:inline;color:#F0F000\">Acceptable</div></h1><div style=\"text-indent:1em\"><h2>certificate (BLOCKEDMACHINE)</h2><div style=\"text-indent:2em\">The certificate is expiring soon. If it is still in use, renew the certificate and replace it. If it is not still in use, remove the certificate.</div></div></div><div style=\"text-indent:0em\"><h1>databaseaccess: <div style=\"display:inline;color:#009900\">Ideal</div></h1></div><div style=\"text-indent:0em\"><h1>emailaccess (BLOCKEDMACHINE/587): <div style=\"display:inline;color:#009900\">Ideal</div></h1></div><div style=\"text-indent:0em\"><h1>fileaccess: <div style=\"display:inline;color:#009900\">Ideal</div></h1></div><div style=\"text-indent:0em\"><h1>localdisk: <div style=\"display:inline;color:#009900\">Ideal</div></h1></div><div style=\"text-indent:0em\"><h1>mediastreaming: <div style=\"display:inline;color:#009900\">Ideal</div></h1></div><div style=\"text-indent:0em\"><h1>misc: <div style=\"display:inline;color:#009900\">Ideal</div></h1></div><div style=\"text-indent:0em\"><h1>networkaccess: <div style=\"display:inline;color:#009900\">Ideal</div></h1></div><div style=\"text-indent:0em\"><h1>queueaccess: <div style=\"display:inline;color:#009900\">Ideal</div></h1></div><div style=\"text-indent:0em\"><h1>search: <div style=\"display:inline;color:#009900\">Ideal</div></h1></div><div style=\"text-indent:0em\"><h1>sharedcacheaccess: <div style=\"display:inline;color:#009900\">Ideal</div></h1></div>4
|
metadata
ADDED
@@ -0,0 +1,205 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: strongmind-agilix-buzz-client
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.8.3
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Strongmind
|
8
|
+
autorequire:
|
9
|
+
bindir: exe
|
10
|
+
cert_chain: []
|
11
|
+
date: 2023-06-29 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: minitest
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: vcr
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: pry
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: dotenv
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '0'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: httparty
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - ">="
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0'
|
104
|
+
type: :runtime
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - ">="
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0'
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: builder
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - ">="
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '0'
|
118
|
+
type: :runtime
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - ">="
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '0'
|
125
|
+
- !ruby/object:Gem::Dependency
|
126
|
+
name: webmock
|
127
|
+
requirement: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - ">="
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: '0'
|
132
|
+
type: :runtime
|
133
|
+
prerelease: false
|
134
|
+
version_requirements: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - ">="
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: '0'
|
139
|
+
description: Fully implements Agilix Buzz API in Ruby
|
140
|
+
email:
|
141
|
+
- qwertytalk@strongmind.com
|
142
|
+
executables: []
|
143
|
+
extensions: []
|
144
|
+
extra_rdoc_files: []
|
145
|
+
files:
|
146
|
+
- ".coveralls.yml"
|
147
|
+
- ".env.sample"
|
148
|
+
- ".github/workflows/dependabot-auto-merge.yml"
|
149
|
+
- ".github/workflows/publish-gem.yml"
|
150
|
+
- ".github/workflows/velocityCheckin.yml"
|
151
|
+
- ".gitignore"
|
152
|
+
- ".idea/.gitignore"
|
153
|
+
- ".idea/agilix-buzz-client.iml"
|
154
|
+
- ".idea/misc.xml"
|
155
|
+
- ".idea/modules.xml"
|
156
|
+
- ".idea/vcs.xml"
|
157
|
+
- CODE_OF_CONDUCT.md
|
158
|
+
- Gemfile
|
159
|
+
- LICENSE.txt
|
160
|
+
- README.md
|
161
|
+
- Rakefile
|
162
|
+
- agilix.gemspec
|
163
|
+
- bin/console
|
164
|
+
- bin/setup
|
165
|
+
- lib/agilix.rb
|
166
|
+
- lib/agilix/buzz/api.rb
|
167
|
+
- lib/agilix/buzz/commands/authentication.rb
|
168
|
+
- lib/agilix/buzz/commands/course.rb
|
169
|
+
- lib/agilix/buzz/commands/domain.rb
|
170
|
+
- lib/agilix/buzz/commands/enrollment.rb
|
171
|
+
- lib/agilix/buzz/commands/general.rb
|
172
|
+
- lib/agilix/buzz/commands/library.rb
|
173
|
+
- lib/agilix/buzz/commands/report.rb
|
174
|
+
- lib/agilix/buzz/commands/resource.rb
|
175
|
+
- lib/agilix/buzz/commands/right.rb
|
176
|
+
- lib/agilix/buzz/commands/user.rb
|
177
|
+
- lib/agilix/version.rb
|
178
|
+
- stats.html
|
179
|
+
homepage: https://github.com/Strongmind/agilix-buzz-client
|
180
|
+
licenses: []
|
181
|
+
metadata:
|
182
|
+
allowed_push_host: https://rubygems.org/
|
183
|
+
homepage_uri: https://github.com/Strongmind/agilix-buzz-client
|
184
|
+
source_code_uri: https://github.com/Strongmind/agilix-buzz-client
|
185
|
+
changelog_uri: https://github.com/Strongmind/agilix-buzz-client
|
186
|
+
post_install_message:
|
187
|
+
rdoc_options: []
|
188
|
+
require_paths:
|
189
|
+
- lib
|
190
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
191
|
+
requirements:
|
192
|
+
- - ">="
|
193
|
+
- !ruby/object:Gem::Version
|
194
|
+
version: '0'
|
195
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
196
|
+
requirements:
|
197
|
+
- - ">="
|
198
|
+
- !ruby/object:Gem::Version
|
199
|
+
version: '0'
|
200
|
+
requirements: []
|
201
|
+
rubygems_version: 3.3.5
|
202
|
+
signing_key:
|
203
|
+
specification_version: 4
|
204
|
+
summary: Agilix Buzz API wrapper
|
205
|
+
test_files: []
|