Module: Agilix::Buzz::Commands::Domain
- Included in:
- Api
- Defined in:
- lib/agilix/buzz/commands/domain.rb
Instance Method Summary collapse
-
#create_domains(items = []) ⇒ Object
api.create_domains [“BuzzTest1”, userspace: ‘buzz-test-fc-1’, parentid: ‘57025’].
-
#delete_domain(options = {}) ⇒ Object
api.delete_domain domainid: ‘57031’.
-
#get_domain2(options = {}) ⇒ Object
(also: #get_domain)
api.get_domain domainid: ‘57025’.
-
#get_domain_content(options = {}) ⇒ Object
api.get_domain_content domainid: ‘57025’.
-
#get_domain_enrollment_metrics(options = {}) ⇒ Object
api.get_domain_enrollment_metrics domainid: ‘57025’.
-
#get_domain_parent_list(options = {}) ⇒ Object
api.get_domain_parent_list domainid: ‘57025’.
-
#get_domain_settings(options = {}) ⇒ Object
api.get_domain_settings domainid: ‘57025’, path: “AgilixBuzzSettings.xml”.
-
#get_domain_stats(options = {}) ⇒ Object
api.get_domain_stats domainid: ‘57025’, options: “users|courses”.
-
#list_domains(options = {}) ⇒ Object
api.list_domains domainid: ‘0’ # all domains for user api.list_domains domainid: ‘57025’.
-
#restore_domain(options = {}) ⇒ Object
api.restore_domain domainid: ‘57031’.
-
#update_domains(items) ⇒ Object
api.update_domains [{ domainid: “57031”, name: “BuzzTestUpdated1”, userspace: ‘buzz-test-fc-1’, parentid: ‘57025’}].
Instance Method Details
#create_domains(items = []) ⇒ Object
api.create_domains [“BuzzTest1”, userspace: ‘buzz-test-fc-1’, parentid: ‘57025’]
7 8 9 10 11 12 |
# File 'lib/agilix/buzz/commands/domain.rb', line 7 def create_domains(items = []) = items.map do |item| argument_cleaner(required_params: %i( name userspace parentid ), optional_params: %i( reference flags data ), options: item ) end authenticated_bulk_post cmd: "createdomains", root_node: 'domain', body: end |
#delete_domain(options = {}) ⇒ Object
api.delete_domain domainid: ‘57031’
15 16 17 18 |
# File 'lib/agilix/buzz/commands/domain.rb', line 15 def delete_domain( = {}) = argument_cleaner(required_params: %i( domainid ), optional_params: %i( ), options: ) authenticated_get cmd: "deletedomain", ** end |
#get_domain2(options = {}) ⇒ Object Also known as: get_domain
api.get_domain domainid: ‘57025’
21 22 23 24 |
# File 'lib/agilix/buzz/commands/domain.rb', line 21 def get_domain2( = {}) = argument_cleaner(required_params: %i( domainid ), optional_params: %i( select ), options: ) authenticated_get cmd: "getdomain2", ** end |
#get_domain_content(options = {}) ⇒ Object
api.get_domain_content domainid: ‘57025’
28 29 30 31 |
# File 'lib/agilix/buzz/commands/domain.rb', line 28 def get_domain_content( = {}) = argument_cleaner(required_params: %i( domainid ), optional_params: %i( ), options: ) authenticated_get cmd: "getdomaincontent", ** end |
#get_domain_enrollment_metrics(options = {}) ⇒ Object
api.get_domain_enrollment_metrics domainid: ‘57025’
34 35 36 37 |
# File 'lib/agilix/buzz/commands/domain.rb', line 34 def get_domain_enrollment_metrics( = {}) = argument_cleaner(required_params: %i( domainid ), optional_params: %i( skipempty ), options: ) authenticated_get cmd: "getdomainenrollmentmetrics", ** end |
#get_domain_parent_list(options = {}) ⇒ Object
api.get_domain_parent_list domainid: ‘57025’
40 41 42 43 |
# File 'lib/agilix/buzz/commands/domain.rb', line 40 def get_domain_parent_list( = {}) = argument_cleaner(required_params: %i( domainid ), optional_params: %i( ), options: ) authenticated_get cmd: "getdomainparentlist", ** end |
#get_domain_settings(options = {}) ⇒ Object
api.get_domain_settings domainid: ‘57025’, path: “AgilixBuzzSettings.xml”
46 47 48 49 |
# File 'lib/agilix/buzz/commands/domain.rb', line 46 def get_domain_settings( = {}) = argument_cleaner(required_params: %i( domainid path ), optional_params: %i( includesource ), options: ) authenticated_get cmd: "getdomainsettings", ** end |
#get_domain_stats(options = {}) ⇒ Object
api.get_domain_stats domainid: ‘57025’, options: “users|courses”
53 54 55 56 57 58 |
# File 'lib/agilix/buzz/commands/domain.rb', line 53 def get_domain_stats( = {}) # options = 'users|courses|activecourses|sections|enrollments|activeenrollments|activestudents' = argument_cleaner(required_params: %i( domainid options ), optional_params: %i( includesource ), options: ) authenticated_get cmd: "getdomainstats", ** end |
#list_domains(options = {}) ⇒ Object
api.list_domains domainid: ‘0’ # all domains for user api.list_domains domainid: ‘57025’
62 63 64 65 66 |
# File 'lib/agilix/buzz/commands/domain.rb', line 62 def list_domains( = {}) [:domainid] ||= 0 = argument_cleaner(required_params: %i( domainid ), optional_params: %i( includedescendantdomains limit show select text query ), options: ) authenticated_get cmd: "listdomains", ** end |
#restore_domain(options = {}) ⇒ Object
api.restore_domain domainid: ‘57031’
69 70 71 72 |
# File 'lib/agilix/buzz/commands/domain.rb', line 69 def restore_domain( = {}) = argument_cleaner(required_params: %i( domainid ), optional_params: %i( ), options: ) authenticated_get cmd: "restoredomain", ** end |
#update_domains(items) ⇒ Object
api.update_domains [{ domainid: “57031”, name: “BuzzTestUpdated1”, userspace: ‘buzz-test-fc-1’, parentid: ‘57025’}]
75 76 77 78 79 80 |
# File 'lib/agilix/buzz/commands/domain.rb', line 75 def update_domains(items) = items.map do |item| argument_cleaner(required_params: %i( domainid ), optional_params: %i( name userspace parentid reference flags data ), options: item ) end authenticated_bulk_post cmd: "updatedomains", root_node: 'domain', body: end |