comet_backup_ruby_sdk 2.8.0 → 2.9.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (51) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +11 -0
  3. data/Gemfile.lock +1 -1
  4. data/comet_backup_ruby_sdk.gemspec +1 -1
  5. data/lib/comet/definitions.rb +165 -42
  6. data/lib/comet/models/azure_destination_location.rb +2 -0
  7. data/lib/comet/models/b2destination_location.rb +2 -0
  8. data/lib/comet/models/backup_job_advanced_options.rb +3 -0
  9. data/lib/comet/models/backup_job_detail.rb +1 -0
  10. data/lib/comet/models/backup_job_progress.rb +4 -1
  11. data/lib/comet/models/backup_rule_config.rb +4 -0
  12. data/lib/comet/models/branding_options.rb +2 -0
  13. data/lib/comet/models/comet_destination_location.rb +1 -0
  14. data/lib/comet/models/constellation_check_report.rb +2 -0
  15. data/lib/comet/models/content_measurement.rb +2 -0
  16. data/lib/comet/models/content_measurement_component.rb +12 -0
  17. data/lib/comet/models/default_email_report_policy.rb +4 -0
  18. data/lib/comet/models/destination_config.rb +35 -1
  19. data/lib/comet/models/destination_location.rb +33 -1
  20. data/lib/comet/models/destination_statistics.rb +2 -0
  21. data/lib/comet/models/device_config.rb +1 -0
  22. data/lib/comet/models/file_option.rb +132 -0
  23. data/lib/comet/models/ftpdestination_location.rb +5 -1
  24. data/lib/comet/models/local_destination_location.rb +5 -0
  25. data/lib/comet/models/mac_oscode_sign_properties.rb +1 -0
  26. data/lib/comet/models/mssqllogin_args.rb +2 -0
  27. data/lib/comet/models/my_sqlconnection.rb +2 -0
  28. data/lib/comet/models/office_365custom_setting.rb +3 -0
  29. data/lib/comet/models/office_365custom_setting_v2.rb +9 -0
  30. data/lib/comet/models/organization.rb +85 -70
  31. data/lib/comet/models/restore_job_advanced_options.rb +1 -0
  32. data/lib/comet/models/search_result_file_info.rb +39 -17
  33. data/lib/comet/models/self_backup_export_options.rb +3 -0
  34. data/lib/comet/models/self_backup_target.rb +4 -0
  35. data/lib/comet/models/server_config_options.rb +23 -0
  36. data/lib/comet/models/session_options.rb +2 -0
  37. data/lib/comet/models/sftpdestination_location.rb +7 -0
  38. data/lib/comet/models/size_measurement.rb +3 -0
  39. data/lib/comet/models/source_basic_info.rb +1 -0
  40. data/lib/comet/models/source_config.rb +6 -4
  41. data/lib/comet/models/source_include_pattern.rb +5 -0
  42. data/lib/comet/models/spanned_destination_location.rb +11 -0
  43. data/lib/comet/models/sshconnection.rb +6 -0
  44. data/lib/comet/models/stored_object.rb +7 -0
  45. data/lib/comet/models/streamable_event.rb +42 -0
  46. data/lib/comet/models/user_profile_config.rb +9 -0
  47. data/lib/comet/models/user_profile_fragment.rb +1 -0
  48. data/lib/comet/models/web_interface_branding_properties.rb +2 -0
  49. data/lib/comet/models/webhook_option.rb +35 -16
  50. data/lib/comet_backup_ruby_sdk.rb +1 -0
  51. metadata +3 -2
@@ -12,12 +12,24 @@ module Comet
12
12
  # StreamableEvent is a typed class wrapper around the underlying Comet Server API data structure.
13
13
  class StreamableEvent
14
14
 
15
+ # @type [String] actor
16
+ attr_accessor :actor
17
+
15
18
  # @type [String] owner_organization_id
16
19
  attr_accessor :owner_organization_id
17
20
 
21
+ # @type [String] resource_id
22
+ attr_accessor :resource_id
23
+
18
24
  # @type [Number] type
19
25
  attr_accessor :type
20
26
 
27
+ # @type [Number] timestamp
28
+ attr_accessor :timestamp
29
+
30
+ # @type [String] type_string
31
+ attr_accessor :type_string
32
+
21
33
  # @type [Object] data
22
34
  attr_accessor :data
23
35
 
@@ -29,8 +41,12 @@ module Comet
29
41
  end
30
42
 
31
43
  def clear
44
+ @actor = ''
32
45
  @owner_organization_id = ''
46
+ @resource_id = ''
33
47
  @type = 0
48
+ @timestamp = 0
49
+ @type_string = ''
34
50
  @unknown_json_fields = {}
35
51
  end
36
52
 
@@ -47,14 +63,30 @@ module Comet
47
63
 
48
64
  obj.each do |k, v|
49
65
  case k
66
+ when 'Actor'
67
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
68
+
69
+ @actor = v
50
70
  when 'OwnerOrganizationID'
51
71
  raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
52
72
 
53
73
  @owner_organization_id = v
74
+ when 'ResourceID'
75
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
76
+
77
+ @resource_id = v
54
78
  when 'Type'
55
79
  raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
56
80
 
57
81
  @type = v
82
+ when 'Timestamp'
83
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
84
+
85
+ @timestamp = v
86
+ when 'TypeString'
87
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
88
+
89
+ @type_string = v
58
90
  when 'Data'
59
91
  @data = v
60
92
  else
@@ -66,8 +98,18 @@ module Comet
66
98
  # @return [Hash] The complete object as a Ruby hash
67
99
  def to_hash
68
100
  ret = {}
101
+ ret['Actor'] = @actor
69
102
  ret['OwnerOrganizationID'] = @owner_organization_id
103
+ unless @resource_id.nil?
104
+ ret['ResourceID'] = @resource_id
105
+ end
70
106
  ret['Type'] = @type
107
+ unless @timestamp.nil?
108
+ ret['Timestamp'] = @timestamp
109
+ end
110
+ unless @type_string.nil?
111
+ ret['TypeString'] = @type_string
112
+ end
71
113
  unless @data.nil?
72
114
  ret['Data'] = @data
73
115
  end
@@ -51,18 +51,23 @@ module Comet
51
51
  attr_accessor :send_email_reports
52
52
 
53
53
  # Storage Vaults
54
+ # The string keys can be any unique key. Using a GUID is recommended, but optional.
54
55
  # @type [Hash{String => Comet::DestinationConfig}] destinations
55
56
  attr_accessor :destinations
56
57
 
57
58
  # Protected Items
59
+ # The string keys can be any unique key. Using a GUID is recommended, but optional.
58
60
  # @type [Hash{String => Comet::SourceConfig}] sources
59
61
  attr_accessor :sources
60
62
 
61
63
  # Schedules
64
+ # The string keys can be any unique key. Using a GUID is recommended, but optional.
62
65
  # @type [Hash{String => Comet::BackupRuleConfig}] backup_rules
63
66
  attr_accessor :backup_rules
64
67
 
65
68
  # Devices
69
+ # The string keys are the device's ID. The device ID is generated automatically based on a mix of
70
+ # hardware and software identifiers on the installed PC.
66
71
  # To revoke a device, use the AdminRevokeDevice API instead of accessing these fields directly. This
67
72
  # API can also remove associated Protected Items, uninstall the remote device, and disconnect its
68
73
  # live connection.
@@ -107,6 +112,7 @@ module Comet
107
112
  # @type [Comet::UserPolicy] policy
108
113
  attr_accessor :policy
109
114
 
115
+ # One of the PASSWORD_FORMAT_ constants
110
116
  # To change the user's password, use the AdminResetUserPassword API instead of accessing these
111
117
  # fields directly. Otherwise, other encrypted fields in the user profile may become corrupted.
112
118
  # @type [Number] password_format
@@ -124,9 +130,12 @@ module Comet
124
130
  # @type [Boolean] allow_password_login
125
131
  attr_accessor :allow_password_login
126
132
 
133
+ # If true, then TOTP is required to open the desktop app or the Comet Server web interface with this
134
+ # user's credentials.
127
135
  # @type [Boolean] allow_password_and_totplogin
128
136
  attr_accessor :allow_password_and_totplogin
129
137
 
138
+ # One of the ENCRYPTIONMETHOD_ constants
130
139
  # @type [Number] totpkey_encryption_format
131
140
  attr_accessor :totpkey_encryption_format
132
141
 
@@ -10,6 +10,7 @@ require 'json'
10
10
  module Comet
11
11
 
12
12
  # UserProfileFragment is a typed class wrapper around the underlying Comet Server API data structure.
13
+ # @deprecated This type has been deprecated since Comet version 23.3.5
13
14
  class UserProfileFragment
14
15
 
15
16
  # @type [String] username
@@ -12,6 +12,8 @@ module Comet
12
12
  # WebInterfaceBrandingProperties is a typed class wrapper around the underlying Comet Server API data structure.
13
13
  class WebInterfaceBrandingProperties
14
14
 
15
+ # One of the BRANDINGSTYLETYPE_ constants
16
+ # This field is available in Comet 23.3.3 and later.
15
17
  # @type [Number] branding_style_type
16
18
  attr_accessor :branding_style_type
17
19
 
@@ -10,17 +10,30 @@ require 'json'
10
10
  module Comet
11
11
 
12
12
  # WebhookOption is a typed class wrapper around the underlying Comet Server API data structure.
13
+ # WebhookOption defines the configuration of a webhook target. The Comet Server will send a live
14
+ # HTTP POST event to the webhook URL when certain events happen.
13
15
  class WebhookOption
14
16
 
17
+ # The target URL to POST the event data to
15
18
  # @type [String] url
16
19
  attr_accessor :url
17
20
 
18
- # @type [Array<Number>] white_listed_event_types
19
- attr_accessor :white_listed_event_types
20
-
21
+ # CustomHeaders allows specifying custom headers which are added to the outgoing POST request
22
+ # from Comet Server. Custom headers are specified as (header name, header value) pairs. If a
23
+ # custom header conflicts with a header required by HTTP or the Comet tracing ID header
24
+ # (`x-Comet-Tracing-Id`), it will be ignored.
21
25
  # @type [Hash{String => String}] custom_headers
22
26
  attr_accessor :custom_headers
23
27
 
28
+ # One of the STREAM_LEVEL_ constants. This controls how much data is sent in the webhook event.
29
+ # @type [String] level
30
+ attr_accessor :level
31
+
32
+ # Configure a subset of allowed event types (see SEVT_ constants). If the array is empty, all events
33
+ # will be sent
34
+ # @type [Array<Number>] white_listed_event_types
35
+ attr_accessor :white_listed_event_types
36
+
24
37
  # @type [Hash] Hidden storage to preserve future properties for non-destructive roundtrip operations
25
38
  attr_accessor :unknown_json_fields
26
39
 
@@ -30,8 +43,9 @@ module Comet
30
43
 
31
44
  def clear
32
45
  @url = ''
33
- @white_listed_event_types = []
34
46
  @custom_headers = {}
47
+ @level = ''
48
+ @white_listed_event_types = []
35
49
  @unknown_json_fields = {}
36
50
  end
37
51
 
@@ -52,17 +66,6 @@ module Comet
52
66
  raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
53
67
 
54
68
  @url = v
55
- when 'WhiteListedEventTypes'
56
- if v.nil?
57
- @white_listed_event_types = []
58
- else
59
- @white_listed_event_types = Array.new(v.length)
60
- v.each_with_index do |v1, i1|
61
- raise TypeError, "'v1' expected Numeric, got #{v1.class}" unless v1.is_a? Numeric
62
-
63
- @white_listed_event_types[i1] = v1
64
- end
65
- end
66
69
  when 'CustomHeaders'
67
70
  @custom_headers = {}
68
71
  if v.nil?
@@ -74,6 +77,21 @@ module Comet
74
77
  @custom_headers[k1] = v1
75
78
  end
76
79
  end
80
+ when 'Level'
81
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
82
+
83
+ @level = v
84
+ when 'WhiteListedEventTypes'
85
+ if v.nil?
86
+ @white_listed_event_types = []
87
+ else
88
+ @white_listed_event_types = Array.new(v.length)
89
+ v.each_with_index do |v1, i1|
90
+ raise TypeError, "'v1' expected Numeric, got #{v1.class}" unless v1.is_a? Numeric
91
+
92
+ @white_listed_event_types[i1] = v1
93
+ end
94
+ end
77
95
  else
78
96
  @unknown_json_fields[k] = v
79
97
  end
@@ -84,8 +102,9 @@ module Comet
84
102
  def to_hash
85
103
  ret = {}
86
104
  ret['URL'] = @url
87
- ret['WhiteListedEventTypes'] = @white_listed_event_types
88
105
  ret['CustomHeaders'] = @custom_headers
106
+ ret['Level'] = @level
107
+ ret['WhiteListedEventTypes'] = @white_listed_event_types
89
108
  @unknown_json_fields.each do |k, v|
90
109
  ret[k] = v
91
110
  end
@@ -73,6 +73,7 @@ require_relative 'comet/models/external_authentication_source'
73
73
  require_relative 'comet/models/external_ldapauthentication_source_server'
74
74
  require_relative 'comet/models/external_ldapauthentication_source_settings'
75
75
  require_relative 'comet/models/extra_file_exclusion'
76
+ require_relative 'comet/models/file_option'
76
77
  require_relative 'comet/models/ftpdestination_location'
77
78
  require_relative 'comet/models/get_group_policy_response'
78
79
  require_relative 'comet/models/get_profile_and_hash_response_message'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: comet_backup_ruby_sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.8.0
4
+ version: 2.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Comet Licensing Ltd.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-05-05 00:00:00.000000000 Z
11
+ date: 2023-06-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -151,6 +151,7 @@ files:
151
151
  - lib/comet/models/external_ldapauthentication_source_server.rb
152
152
  - lib/comet/models/external_ldapauthentication_source_settings.rb
153
153
  - lib/comet/models/extra_file_exclusion.rb
154
+ - lib/comet/models/file_option.rb
154
155
  - lib/comet/models/ftpdestination_location.rb
155
156
  - lib/comet/models/get_group_policy_response.rb
156
157
  - lib/comet/models/get_profile_and_hash_response_message.rb