comet_backup_ruby_sdk 2.44.0 → 3.1.0

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.
Files changed (299) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/publish.yml +52 -0
  3. data/.gitignore +1 -0
  4. data/CHANGELOG.md +36 -0
  5. data/RELEASING.md +9 -7
  6. data/comet_backup_ruby_sdk.gemspec +2 -3
  7. data/lib/comet/api_response_error.rb +1 -1
  8. data/lib/comet/comet_server.rb +761 -95
  9. data/lib/comet/definitions.rb +400 -125
  10. data/lib/comet/models/add_bucket_response_message.rb +1 -1
  11. data/lib/comet/models/admin_account_apitoken_create_response.rb +102 -0
  12. data/lib/comet/models/admin_account_apitoken_list_response.rb +98 -0
  13. data/lib/comet/models/admin_account_properties_response.rb +38 -1
  14. data/lib/comet/models/admin_apitoken.rb +139 -0
  15. data/lib/comet/models/admin_apitoken_info.rb +117 -0
  16. data/lib/comet/models/admin_email_options.rb +1 -1
  17. data/lib/comet/models/admin_options.rb +1 -1
  18. data/lib/comet/models/admin_resource_response.rb +1 -1
  19. data/lib/comet/models/admin_security_options.rb +1 -1
  20. data/lib/comet/models/admin_u2fregistration.rb +1 -1
  21. data/lib/comet/models/admin_user_permissions.rb +20 -1
  22. data/lib/comet/models/admin_web_authn_registration.rb +1 -1
  23. data/lib/comet/models/allowed_admin_user.rb +19 -1
  24. data/lib/comet/models/amazon_awsvirtual_storage_role_settings.rb +1 -1
  25. data/lib/comet/models/attributed_content_measurement.rb +146 -0
  26. data/lib/comet/models/attributed_content_measurement_component.rb +105 -0
  27. data/lib/comet/models/authentication_role_options.rb +2 -4
  28. data/lib/comet/models/available_download.rb +1 -1
  29. data/lib/comet/models/azure_destination_location.rb +1 -1
  30. data/lib/comet/models/b2destination_location.rb +1 -1
  31. data/lib/comet/models/b2storage_extra_info.rb +1 -1
  32. data/lib/comet/models/b2transaction_totals.rb +1 -1
  33. data/lib/comet/models/b2virtual_storage_role_settings.rb +1 -1
  34. data/lib/comet/models/backup_job_advanced_options.rb +15 -1
  35. data/lib/comet/models/backup_job_detail.rb +14 -2
  36. data/lib/comet/models/backup_job_progress.rb +1 -1
  37. data/lib/comet/models/backup_rule_config.rb +43 -1
  38. data/lib/comet/models/backup_rule_event_triggers.rb +1 -1
  39. data/lib/comet/models/branding_options.rb +184 -1
  40. data/lib/comet/models/branding_properties.rb +184 -1
  41. data/lib/comet/models/browse_disk_drives_response.rb +1 -1
  42. data/lib/comet/models/browse_edbresponse.rb +1 -1
  43. data/lib/comet/models/browse_hvresponse.rb +1 -1
  44. data/lib/comet/models/browse_office_365list_virtual_accounts_response.rb +1 -1
  45. data/lib/comet/models/browse_office_365objects_response.rb +1 -1
  46. data/lib/comet/models/browse_proxmox_nodes_response.rb +1 -1
  47. data/lib/comet/models/browse_proxmox_response.rb +16 -1
  48. data/lib/comet/models/browse_proxmox_storage_response.rb +1 -1
  49. data/lib/comet/models/browse_sqlserver_response.rb +1 -1
  50. data/lib/comet/models/browse_vmware_datacenters_response.rb +1 -1
  51. data/lib/comet/models/browse_vmware_datastores_response.rb +1 -1
  52. data/lib/comet/models/browse_vmware_hosts_response.rb +1 -1
  53. data/lib/comet/models/browse_vmware_networks_response.rb +1 -1
  54. data/lib/comet/models/browse_vmware_response.rb +1 -1
  55. data/lib/comet/models/browse_vssresponse.rb +1 -1
  56. data/lib/comet/models/bucket_properties.rb +1 -1
  57. data/lib/comet/models/bucket_usage_info.rb +1 -1
  58. data/lib/comet/models/comet_apiresponse_message.rb +1 -1
  59. data/lib/comet/models/comet_destination_location.rb +1 -1
  60. data/lib/comet/models/constellation_check_report.rb +1 -1
  61. data/lib/comet/models/constellation_role_options.rb +1 -1
  62. data/lib/comet/models/constellation_stats.rb +1 -1
  63. data/lib/comet/models/constellation_status_apiresponse.rb +1 -1
  64. data/lib/comet/models/content_measurement.rb +1 -1
  65. data/lib/comet/models/content_measurement_component.rb +3 -3
  66. data/lib/comet/models/count_jobs_response.rb +1 -1
  67. data/lib/comet/models/create_group_policy_response.rb +1 -1
  68. data/lib/comet/models/create_user_group_response.rb +1 -1
  69. data/lib/comet/models/custom_branding_item.rb +143 -0
  70. data/lib/comet/models/custom_branding_options.rb +79 -0
  71. data/lib/comet/models/custom_branding_origin.rb +76 -0
  72. data/lib/comet/models/custom_remote_bucket_settings.rb +1 -1
  73. data/lib/comet/models/days_of_week_config.rb +1 -1
  74. data/lib/comet/models/default_email_report_policy.rb +1 -1
  75. data/lib/comet/models/default_source_with_osrestriction.rb +1 -1
  76. data/lib/comet/models/destination_config.rb +32 -5
  77. data/lib/comet/models/destination_location.rb +11 -2
  78. data/lib/comet/models/destination_statistics.rb +1 -1
  79. data/lib/comet/models/device_config.rb +42 -1
  80. data/lib/comet/models/device_identity_response.rb +82 -0
  81. data/lib/comet/models/disk_drive.rb +1 -1
  82. data/lib/comet/models/dispatch_with_job_idresponse.rb +1 -1
  83. data/lib/comet/models/dispatcher_admin_sources_response.rb +1 -1
  84. data/lib/comet/models/dispatcher_list_snapshot_virtual_machines_response.rb +1 -1
  85. data/lib/comet/models/dispatcher_stored_objects_response.rb +1 -1
  86. data/lib/comet/models/dispatcher_vault_snapshots_response.rb +1 -1
  87. data/lib/comet/models/dispatcher_windisk_snapshot_response.rb +1 -1
  88. data/lib/comet/models/dnscache_options.rb +94 -0
  89. data/lib/comet/models/edbfile_info.rb +1 -1
  90. data/lib/comet/models/email_options.rb +14 -1
  91. data/lib/comet/models/email_report_config.rb +15 -1
  92. data/lib/comet/models/email_report_generated_preview.rb +1 -1
  93. data/lib/comet/models/email_reporting_option.rb +1 -1
  94. data/lib/comet/models/external_authentication_source.rb +1 -1
  95. data/lib/comet/models/external_authentication_source_display.rb +1 -1
  96. data/lib/comet/models/external_authentication_source_response.rb +1 -1
  97. data/lib/comet/models/external_ldapauthentication_source_server.rb +1 -1
  98. data/lib/comet/models/external_ldapauthentication_source_settings.rb +1 -1
  99. data/lib/comet/models/extra_file_exclusion.rb +1 -1
  100. data/lib/comet/models/file_option.rb +1 -1
  101. data/lib/comet/models/ftpdestination_location.rb +1 -1
  102. data/lib/comet/models/get_group_policy_response.rb +1 -1
  103. data/lib/comet/models/get_profile_and_hash_response_message.rb +1 -1
  104. data/lib/comet/models/get_profile_hash_response_message.rb +1 -1
  105. data/lib/comet/models/get_shared_storage_quota_response.rb +1 -1
  106. data/lib/comet/models/get_user_group_response.rb +1 -1
  107. data/lib/comet/models/get_user_group_with_users_response.rb +1 -1
  108. data/lib/comet/models/global_override_options.rb +1 -1
  109. data/lib/comet/models/group_policy.rb +1 -1
  110. data/lib/comet/models/hour_sched_config.rb +1 -1
  111. data/lib/comet/models/httpconnector_options.rb +1 -1
  112. data/lib/comet/models/hyper_vmachine_info.rb +1 -1
  113. data/lib/comet/models/hyper_vrestore_target_options.rb +1 -1
  114. data/lib/comet/models/impossible_cloud_iamtemplate_settings.rb +1 -1
  115. data/lib/comet/models/impossible_cloud_partner_template_settings.rb +1 -1
  116. data/lib/comet/models/install_creds.rb +1 -1
  117. data/lib/comet/models/install_token.rb +8 -8
  118. data/lib/comet/models/install_token_response.rb +1 -1
  119. data/lib/comet/models/job_entry.rb +1 -1
  120. data/lib/comet/models/license_limits.rb +1 -1
  121. data/lib/comet/models/license_options.rb +1 -1
  122. data/lib/comet/models/linux_rpm_code_sign_properties.rb +115 -0
  123. data/lib/comet/models/list_shared_storage_quota_response.rb +1 -1
  124. data/lib/comet/models/live_user_connection.rb +1 -1
  125. data/lib/comet/models/local_destination_location.rb +2 -2
  126. data/lib/comet/models/local_storage_directory.rb +1 -1
  127. data/lib/comet/models/login_protection_options.rb +1 -1
  128. data/lib/comet/models/mac_oscode_sign_properties.rb +1 -1
  129. data/lib/comet/models/mongo_dbconnection.rb +4 -1
  130. data/lib/comet/models/mssqlconnection.rb +1 -1
  131. data/lib/comet/models/mssqllogin_args.rb +1 -1
  132. data/lib/comet/models/my_sqlconnection.rb +1 -1
  133. data/lib/comet/models/new_bucket_detail.rb +1 -1
  134. data/lib/comet/models/news_entry.rb +1 -1
  135. data/lib/comet/models/nfsdestination_location.rb +132 -0
  136. data/lib/comet/models/ninja_one_auth_callback_response.rb +82 -0
  137. data/lib/comet/models/ninja_one_config.rb +130 -0
  138. data/lib/comet/models/ninja_one_organization.rb +91 -0
  139. data/lib/comet/models/node.rb +80 -0
  140. data/lib/comet/models/object_lock_storage_template_settings.rb +1 -1
  141. data/lib/comet/models/office_365connection.rb +1 -1
  142. data/lib/comet/models/office_365convert_selection_response.rb +102 -0
  143. data/lib/comet/models/office_365credential.rb +1 -1
  144. data/lib/comet/models/office_365custom_setting.rb +1 -1
  145. data/lib/comet/models/office_365custom_setting_v2.rb +23 -1
  146. data/lib/comet/models/office_365effective_selection.rb +109 -0
  147. data/lib/comet/models/office_365effective_selection_account.rb +101 -0
  148. data/lib/comet/models/office_365evaluate_selection_rules_response.rb +95 -0
  149. data/lib/comet/models/office_365mixed_virtual_account.rb +1 -1
  150. data/lib/comet/models/office_365object_info.rb +1 -1
  151. data/lib/comet/models/office_365selection_rule.rb +182 -0
  152. data/lib/comet/models/office_365service_rule_decision.rb +93 -0
  153. data/lib/comet/models/oidc_claim.rb +1 -1
  154. data/lib/comet/models/oidc_config.rb +1 -1
  155. data/lib/comet/models/organization.rb +1 -1
  156. data/lib/comet/models/organization_login_urlresponse.rb +1 -1
  157. data/lib/comet/models/organization_response.rb +1 -1
  158. data/lib/comet/models/osinfo.rb +1 -1
  159. data/lib/comet/models/partition.rb +1 -1
  160. data/lib/comet/models/partition_conflict.rb +1 -1
  161. data/lib/comet/models/pkcs_11allowed_driver.rb +75 -0
  162. data/lib/comet/models/pkcs_11allowlist_options.rb +90 -0
  163. data/lib/comet/models/policy_options.rb +1 -1
  164. data/lib/comet/models/postgre_sqlconnection.rb +151 -0
  165. data/lib/comet/models/private_branding_properties.rb +184 -1
  166. data/lib/comet/models/protected_item_engine_type_policy.rb +1 -1
  167. data/lib/comet/models/protected_item_with_backup_rules_response.rb +1 -1
  168. data/lib/comet/models/proxmox_connection.rb +1 -1
  169. data/lib/comet/models/proxmox_restore_target_options.rb +1 -1
  170. data/lib/comet/models/psaconfig.rb +26 -1
  171. data/lib/comet/models/psaconfig_connect_wise.rb +130 -0
  172. data/lib/comet/models/psagrouped_by.rb +1 -1
  173. data/lib/comet/models/public_branding_properties.rb +1 -1
  174. data/lib/comet/models/pvebackup_disk.rb +1 -1
  175. data/lib/comet/models/pvebackup_node.rb +1 -1
  176. data/lib/comet/models/pvebackup_vm.rb +1 -1
  177. data/lib/comet/models/pvedisk.rb +1 -1
  178. data/lib/comet/models/pveparams.rb +2 -4
  179. data/lib/comet/models/pvestorage_name.rb +1 -1
  180. data/lib/comet/models/pvevm.rb +8 -1
  181. data/lib/comet/models/ratelimit_options.rb +1 -1
  182. data/lib/comet/models/ratelimit_rule.rb +1 -1
  183. data/lib/comet/models/register_office_application_begin_response.rb +1 -1
  184. data/lib/comet/models/register_office_application_check_response.rb +1 -1
  185. data/lib/comet/models/registration_lobby_connection.rb +1 -1
  186. data/lib/comet/models/remote_server_address.rb +1 -1
  187. data/lib/comet/models/remote_storage_option.rb +10 -1
  188. data/lib/comet/models/replica_server.rb +1 -1
  189. data/lib/comet/models/replicator_state_apiresponse.rb +1 -1
  190. data/lib/comet/models/request_storage_vault_response_message.rb +1 -1
  191. data/lib/comet/models/restore_job_advanced_options.rb +66 -10
  192. data/lib/comet/models/retention_policy.rb +1 -1
  193. data/lib/comet/models/retention_range.rb +1 -1
  194. data/lib/comet/models/s3destination_location.rb +1 -1
  195. data/lib/comet/models/s3generic_virtual_storage_role.rb +1 -1
  196. data/lib/comet/models/schedule_config.rb +1 -1
  197. data/lib/comet/models/search_clause.rb +1 -1
  198. data/lib/comet/models/search_result_file_info.rb +1 -1
  199. data/lib/comet/models/search_snapshots_response.rb +1 -1
  200. data/lib/comet/models/self_backup_event_data.rb +135 -0
  201. data/lib/comet/models/self_backup_export_options.rb +1 -1
  202. data/lib/comet/models/self_backup_options.rb +1 -1
  203. data/lib/comet/models/self_backup_statistics.rb +1 -1
  204. data/lib/comet/models/self_backup_target.rb +1 -1
  205. data/lib/comet/models/server_config_options.rb +76 -1
  206. data/lib/comet/models/server_config_options_and_hash_response.rb +103 -0
  207. data/lib/comet/models/server_config_options_branding_fragment.rb +1 -1
  208. data/lib/comet/models/server_config_options_hash_response.rb +95 -0
  209. data/lib/comet/models/server_config_options_software_build_role_fragment.rb +1 -1
  210. data/lib/comet/models/server_meta_branding_properties.rb +20 -1
  211. data/lib/comet/models/server_meta_version_info.rb +1 -1
  212. data/lib/comet/models/session_key_regenerated_response.rb +1 -1
  213. data/lib/comet/models/session_options.rb +1 -1
  214. data/lib/comet/models/set_shared_storage_quota_response.rb +1 -1
  215. data/lib/comet/models/sftpdestination_location.rb +1 -1
  216. data/lib/comet/models/shared_storage_quota.rb +1 -1
  217. data/lib/comet/models/single_field_source.rb +2 -2
  218. data/lib/comet/models/size_measurement.rb +1 -1
  219. data/lib/comet/models/smbdestination_location.rb +1 -1
  220. data/lib/comet/models/smtpoauth_options.rb +154 -0
  221. data/lib/comet/models/software_build_role_options.rb +1 -1
  222. data/lib/comet/models/software_update_news_response.rb +1 -1
  223. data/lib/comet/models/source_basic_info.rb +10 -1
  224. data/lib/comet/models/source_config.rb +69 -4
  225. data/lib/comet/models/source_include_pattern.rb +1 -1
  226. data/lib/comet/models/source_statistics.rb +1 -1
  227. data/lib/comet/models/spanned_destination_location.rb +1 -1
  228. data/lib/comet/models/spanned_storage_extra_info.rb +1 -1
  229. data/lib/comet/models/speed_limit_time_window.rb +114 -0
  230. data/lib/comet/models/sshconnection.rb +1 -1
  231. data/lib/comet/models/stat_result.rb +1 -1
  232. data/lib/comet/models/storage_free_space_info.rb +1 -1
  233. data/lib/comet/models/storage_role_options.rb +1 -1
  234. data/lib/comet/models/storage_vault_provider_policy.rb +1 -1
  235. data/lib/comet/models/stored_object.rb +1 -1
  236. data/lib/comet/models/storj_destination_location.rb +1 -1
  237. data/lib/comet/models/storj_virtual_storage_role_setting.rb +1 -1
  238. data/lib/comet/models/streamable_event.rb +1 -1
  239. data/lib/comet/models/swift_destination_location.rb +1 -1
  240. data/lib/comet/models/test_response.rb +1 -1
  241. data/lib/comet/models/time_span.rb +1 -1
  242. data/lib/comet/models/totp_regenerated_response.rb +1 -1
  243. data/lib/comet/models/u2fregister_request.rb +1 -1
  244. data/lib/comet/models/u2fregistered_key.rb +1 -1
  245. data/lib/comet/models/u2fregistration_challenge_response.rb +1 -1
  246. data/lib/comet/models/u2fsign_request.rb +1 -1
  247. data/lib/comet/models/u2fsign_response.rb +1 -1
  248. data/lib/comet/models/uninstall_config.rb +1 -1
  249. data/lib/comet/models/update_campaign_device_status.rb +9 -1
  250. data/lib/comet/models/update_campaign_options.rb +1 -1
  251. data/lib/comet/models/update_campaign_properties.rb +1 -1
  252. data/lib/comet/models/update_campaign_skip_detail.rb +100 -0
  253. data/lib/comet/models/update_campaign_status.rb +1 -1
  254. data/lib/comet/models/update_campaign_status_device_entry.rb +9 -1
  255. data/lib/comet/models/user_custom_email_settings.rb +1 -1
  256. data/lib/comet/models/user_group.rb +1 -1
  257. data/lib/comet/models/user_on_server.rb +1 -1
  258. data/lib/comet/models/user_policy.rb +18 -1
  259. data/lib/comet/models/user_profile_config.rb +82 -8
  260. data/lib/comet/models/user_profile_fragment.rb +1 -1
  261. data/lib/comet/models/user_server_config.rb +1 -1
  262. data/lib/comet/models/vault_snapshot.rb +1 -1
  263. data/lib/comet/models/vmdisk_info.rb +1 -1
  264. data/lib/comet/models/vmdksnapshot_view_options.rb +1 -1
  265. data/lib/comet/models/vminfo.rb +1 -1
  266. data/lib/comet/models/vminfo_list.rb +1 -1
  267. data/lib/comet/models/vmware_connection.rb +1 -1
  268. data/lib/comet/models/vmware_datacenter_info.rb +1 -1
  269. data/lib/comet/models/vmware_datastore_info.rb +1 -1
  270. data/lib/comet/models/vmware_host_info.rb +1 -1
  271. data/lib/comet/models/vmware_machine_info.rb +1 -1
  272. data/lib/comet/models/vmware_network_info.rb +1 -1
  273. data/lib/comet/models/vmware_restore_target_options.rb +1 -1
  274. data/lib/comet/models/vsphere_connection.rb +1 -1
  275. data/lib/comet/models/vsscomponent.rb +1 -1
  276. data/lib/comet/models/vsswriter_info.rb +1 -1
  277. data/lib/comet/models/wasabi_virtual_storage_role_settings.rb +1 -1
  278. data/lib/comet/models/web_authn_authenticator_selection.rb +1 -1
  279. data/lib/comet/models/web_authn_credential.rb +1 -1
  280. data/lib/comet/models/web_authn_credential_assertion.rb +1 -1
  281. data/lib/comet/models/web_authn_credential_descriptor.rb +1 -1
  282. data/lib/comet/models/web_authn_credential_entity.rb +1 -1
  283. data/lib/comet/models/web_authn_credential_parameter.rb +1 -1
  284. data/lib/comet/models/web_authn_public_key_credential_creation_options.rb +2 -4
  285. data/lib/comet/models/web_authn_public_key_credential_request_options.rb +1 -1
  286. data/lib/comet/models/web_authn_registration_challenge_response.rb +1 -1
  287. data/lib/comet/models/web_authn_relying_party_entity.rb +1 -1
  288. data/lib/comet/models/web_authn_sign_request.rb +1 -1
  289. data/lib/comet/models/web_authn_sign_response.rb +1 -1
  290. data/lib/comet/models/web_authn_user_entity.rb +1 -1
  291. data/lib/comet/models/web_dav_destination_location.rb +1 -1
  292. data/lib/comet/models/web_interface_branding_properties.rb +1 -1
  293. data/lib/comet/models/webhook_awsoptions.rb +96 -0
  294. data/lib/comet/models/webhook_option.rb +49 -2
  295. data/lib/comet/models/win_smbauth.rb +3 -3
  296. data/lib/comet/models/windows_code_sign_properties.rb +176 -1
  297. data/lib/comet_backup_ruby_sdk.rb +35 -1
  298. metadata +40 -23
  299. data/Gemfile.lock +0 -43
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- # Copyright (c) 2020-2025 Comet Licensing Ltd.
3
+ # Copyright (c) 2020-2026 Comet Licensing Ltd.
4
4
  # Please see the LICENSE file for usage information.
5
5
  #
6
6
  # SPDX-License-Identifier: MIT
@@ -22,6 +22,9 @@ module Comet
22
22
  # @type [String] Password to log in to the Comet Server API
23
23
  attr_accessor :password
24
24
 
25
+ # @type [String, nil] Admin personal API token. If set, it is used instead of the password
26
+ attr_accessor :token
27
+
25
28
  # Initialize a new CometServer class instance.
26
29
  def initialize(server_address, username, password)
27
30
  raise TypeError, "'server_address' expected String, got #{server_address.class}" unless server_address.is_a? String
@@ -33,17 +36,113 @@ module Comet
33
36
  @server_address = server_address
34
37
  @username = username
35
38
  @password = password
39
+ @token = nil
36
40
 
37
41
  # Ensure Comet Server URL has a trailing slash
38
42
  @server_address += '/' unless server_address.end_with?('/')
39
43
  end
40
44
 
45
+ # Initialize a new CometServer class instance that authenticates using an admin personal API token.
46
+ # A token is not asked for 2FA, but is only accepted by APIs documented as accepting it.
47
+ #
48
+ # Admin personal API tokens require Comet Server 26.8.3 or later. Since Comet Server 26.11.3, a
49
+ # token can also be passed as the password to new.
50
+ #
51
+ # @param [String] server_address The Comet Server URL
52
+ # @param [String] username Username of the admin that owns the token
53
+ # @param [String] token Admin personal API token
54
+ # @return [CometServer]
55
+ def self.with_token(server_address, username, token)
56
+ raise TypeError, "'token' expected String, got #{token.class}" unless token.is_a? String
57
+
58
+ server = new(server_address, username, '')
59
+ server.token = token
60
+ server
61
+ end
62
+
63
+ # AdminAccountApiTokenCreate
64
+ #
65
+ # Create a new personal API token for the current admin account.
66
+ # The response contains the plaintext token. It is shown exactly once and cannot be retrieved again - store it securely.
67
+ # The token inherits the current permissions of the admin account that created it, evaluated live on each request; it does not capture a fixed snapshot of permissions.
68
+ # To authenticate with the token, send it in the Token field with AuthType=Token, or in the Password field with AuthType=Password. The latter lets SDKs and integrations that only support password authentication use a token without needing to handle 2FA.
69
+ # Creating a token requires you to supply your current password, unless the request is already authenticated with a password, or the account is managed by an external authentication source. Check AdminAccountProperties.APITokenCreateRequiresPassword to know whether it is needed.
70
+ #
71
+ # You must supply administrator authentication credentials to use this API.
72
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
73
+ #
74
+ # @param [String] description Human-readable label for this token
75
+ # @param [Number] expire_time (Optional) Unix timestamp, in seconds, when the token stops working. Must be in the future. If this parameter is omitted entirely, the token expires after 90 days. Pass zero explicitly for a token that never expires
76
+ # @return [Comet::AdminAccountAPITokenCreateResponse]
77
+ def admin_account_api_token_create(description, expire_time = nil)
78
+ submit_params = {}
79
+ raise TypeError, "'description' expected String, got #{description.class}" unless description.is_a? String
80
+
81
+ submit_params['Description'] = description
82
+ unless expire_time.nil?
83
+ raise TypeError, "'expire_time' expected Numeric, got #{expire_time.class}" unless expire_time.is_a? Numeric
84
+
85
+ submit_params['ExpireTime'] = expire_time
86
+ end
87
+
88
+ body = perform_request('api/v1/admin/account/api-token/create', submit_params)
89
+ json_body = JSON.parse body
90
+ check_status json_body
91
+ ret = Comet::AdminAccountAPITokenCreateResponse.new
92
+ ret.from_hash(json_body)
93
+ ret
94
+ end
95
+
96
+ # AdminAccountApiTokenList
97
+ #
98
+ # List the metadata for all API tokens of the current admin account.
99
+ # This does not include the token itself, which is only returned once when the token is created.
100
+ #
101
+ # You must supply administrator authentication credentials to use this API.
102
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
103
+ #
104
+ # @return [Comet::AdminAccountAPITokenListResponse]
105
+ def admin_account_api_token_list
106
+ body = perform_request('api/v1/admin/account/api-token/list')
107
+ json_body = JSON.parse body
108
+ check_status json_body
109
+ ret = Comet::AdminAccountAPITokenListResponse.new
110
+ ret.from_hash(json_body)
111
+ ret
112
+ end
113
+
114
+ # AdminAccountApiTokenRevoke
115
+ #
116
+ # Revoke a personal API token of the current admin account.
117
+ # An admin may always revoke their own tokens, even if API tokens have since been disabled for their account or this server.
118
+ #
119
+ # You must supply administrator authentication credentials to use this API.
120
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
121
+ #
122
+ # @param [String] token_id The token identifier, as shown in the token list
123
+ # @return [Comet::CometAPIResponseMessage]
124
+ def admin_account_api_token_revoke(token_id)
125
+ submit_params = {}
126
+ raise TypeError, "'token_id' expected String, got #{token_id.class}" unless token_id.is_a? String
127
+
128
+ submit_params['TokenID'] = token_id
129
+
130
+ body = perform_request('api/v1/admin/account/api-token/revoke', submit_params)
131
+ json_body = JSON.parse body
132
+ check_status json_body
133
+ ret = Comet::CometAPIResponseMessage.new
134
+ ret.from_hash(json_body)
135
+ ret
136
+ end
137
+
41
138
  # AdminAccountProperties
42
139
  #
43
140
  # Retrieve properties about the current admin account.
44
141
  # Some key parameters are obscured, but the obscured values are safely recognised by the corresponding AdminAccountSetProperties API.
142
+ # In Comet 26.8.4 and later, when authenticating with an admin API token, the account's password hash is additionally obscured.
45
143
  #
46
144
  # You must supply administrator authentication credentials to use this API.
145
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
47
146
  #
48
147
  # @return [Comet::AdminAccountPropertiesResponse]
49
148
  def admin_account_properties
@@ -61,6 +160,7 @@ module Comet
61
160
  # The secret is returned as a `data-uri` image of a QR code. The new secret is immediately applied to the current admin account.
62
161
  #
63
162
  # You must supply administrator authentication credentials to use this API.
163
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
64
164
  #
65
165
  # @return [Comet::TotpRegeneratedResponse]
66
166
  def admin_account_regenerate_totp
@@ -77,6 +177,7 @@ module Comet
77
177
  # Revoke a session key (log out).
78
178
  #
79
179
  # You must supply administrator authentication credentials to use this API.
180
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
80
181
  #
81
182
  # @return [Comet::CometAPIResponseMessage]
82
183
  def admin_account_session_revoke
@@ -93,8 +194,9 @@ module Comet
93
194
  # Generate a session key (log in).
94
195
  #
95
196
  # You must supply administrator authentication credentials to use this API.
197
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
96
198
  #
97
- # @param [String] self_address (Optional) External URL of this server
199
+ # @param [String] self_address (Optional) External URL of this server (>= 18.9.9)
98
200
  # @return [Comet::SessionKeyRegeneratedResponse]
99
201
  def admin_account_session_start(self_address = nil)
100
202
  submit_params = {}
@@ -119,6 +221,7 @@ module Comet
119
221
  # Generate a session key for an end-user (log in as end-user).
120
222
  #
121
223
  # You must supply administrator authentication credentials to use this API.
224
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
122
225
  #
123
226
  # @param [String] target_user Target account username
124
227
  # @return [Comet::SessionKeyRegeneratedResponse]
@@ -138,22 +241,17 @@ module Comet
138
241
 
139
242
  # AdminAccountSessionUpgrade
140
243
  #
141
- # Upgrade a session key which is pending an MFA upgrade to a full session key.
244
+ # Exchange an SSO one-time token for a session key.
142
245
  #
143
246
  # You must supply administrator authentication credentials to use this API.
247
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
144
248
  #
145
- # @param [String] session_key The session key to upgrade
146
- # @return [Comet::CometAPIResponseMessage]
147
- def admin_account_session_upgrade(session_key)
148
- submit_params = {}
149
- raise TypeError, "'session_key' expected String, got #{session_key.class}" unless session_key.is_a? String
150
-
151
- submit_params['SessionKey'] = session_key
152
-
153
- body = perform_request('api/v1/admin/account/session-upgrade', submit_params)
249
+ # @return [Comet::SessionKeyRegeneratedResponse]
250
+ def admin_account_session_upgrade
251
+ body = perform_request('api/v1/admin/account/session-upgrade')
154
252
  json_body = JSON.parse body
155
253
  check_status json_body
156
- ret = Comet::CometAPIResponseMessage.new
254
+ ret = Comet::SessionKeyRegeneratedResponse.new
157
255
  ret.from_hash(json_body)
158
256
  ret
159
257
  end
@@ -167,6 +265,7 @@ module Comet
167
265
  # In Comet 24.12.2 and later, this API can change the IPWhitelist field. Prior to this, changes to the IPWhitelist field were ignored.
168
266
  #
169
267
  # You must supply administrator authentication credentials to use this API.
268
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
170
269
  #
171
270
  # @param [Comet::AdminSecurityOptions] security Updated account properties
172
271
  # @return [Comet::CometAPIResponseMessage]
@@ -192,6 +291,7 @@ module Comet
192
291
  # to allow their use with the WebAuthn endpoints.
193
292
  #
194
293
  # You must supply administrator authentication credentials to use this API.
294
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
195
295
  #
196
296
  # @param [String] self_address External URL of this server, used as U2F AppID and Facet
197
297
  # @return [Comet::U2FRegistrationChallengeResponse]
@@ -217,6 +317,7 @@ module Comet
217
317
  # to allow their use with the WebAuthn endpoints.
218
318
  #
219
319
  # You must supply administrator authentication credentials to use this API.
320
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
220
321
  #
221
322
  # @param [String] u2fchallenge_id Associated value from AdminAccountU2fRequestRegistrationChallenge API
222
323
  # @param [String] u2fclient_data U2F response data supplied by hardware token
@@ -257,6 +358,7 @@ module Comet
257
358
  # Validate the TOTP code before turning 2fa(TOTP) on.
258
359
  #
259
360
  # You must supply administrator authentication credentials to use this API.
361
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
260
362
  #
261
363
  # @param [String] totpcode Six-digit code after scanning barcode image
262
364
  # @return [Comet::CometAPIResponseMessage]
@@ -279,6 +381,7 @@ module Comet
279
381
  # Register a new FIDO2 WebAuthn token.
280
382
  #
281
383
  # You must supply administrator authentication credentials to use this API.
384
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
282
385
  #
283
386
  # @param [String] self_address External URL of this server, used as WebAuthn ID
284
387
  # @return [Comet::WebAuthnRegistrationChallengeResponse]
@@ -301,6 +404,7 @@ module Comet
301
404
  # Register a new FIDO2 WebAuthn token.
302
405
  #
303
406
  # You must supply administrator authentication credentials to use this API.
407
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
304
408
  #
305
409
  # @param [String] self_address External URL of this server, used as WebAuthn ID
306
410
  # @param [String] challenge_id Associated value from AdminAccountWebAuthnRequestRegistrationChallenge API
@@ -356,14 +460,16 @@ module Comet
356
460
  #
357
461
  # You must supply administrator authentication credentials to use this API.
358
462
  # This API requires the Auth Role to be enabled.
463
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
359
464
  #
360
- # @param [String] target_user New account username
361
- # @param [String] target_password New account password
465
+ # @param [String] target_user New account username (>= 17.2.0)
466
+ # @param [String] target_password New account password (>= 17.2.0)
362
467
  # @param [Number] store_recovery_code (Optional) If set to 1, store and keep a password recovery code for the generated user (>= 18.3.9)
363
468
  # @param [Number] require_password_change (Optional) If set to 1, require to reset password at the first login for the generated user (>= 20.3.4)
364
- # @param [String] target_organization (Optional) If present, create the user account on behalf of another organization. Only allowed for administrator accounts in the top-level organization. (>= 22.3.7)
469
+ # @param [String] target_organization (Optional) If present, create the user account on behalf of another organization. Only allowed for administrator accounts in the top-level organization. (>= 22.5.0)
470
+ # @param [Number] store_data_recovery_code (Optional) If set to 1, store and keep a data recovery code for the generated user (>= 26.8.10)
365
471
  # @return [Comet::CometAPIResponseMessage]
366
- def admin_add_user(target_user, target_password, store_recovery_code = nil, require_password_change = nil, target_organization = nil)
472
+ def admin_add_user(target_user, target_password, store_recovery_code = nil, require_password_change = nil, target_organization = nil, store_data_recovery_code = nil)
367
473
  submit_params = {}
368
474
  raise TypeError, "'target_user' expected String, got #{target_user.class}" unless target_user.is_a? String
369
475
 
@@ -386,6 +492,11 @@ module Comet
386
492
 
387
493
  submit_params['TargetOrganization'] = target_organization
388
494
  end
495
+ unless store_data_recovery_code.nil?
496
+ raise TypeError, "'store_data_recovery_code' expected Numeric, got #{store_data_recovery_code.class}" unless store_data_recovery_code.is_a? Numeric
497
+
498
+ submit_params['StoreDataRecoveryCode'] = store_data_recovery_code
499
+ end
389
500
 
390
501
  body = perform_request('api/v1/admin/add-user', submit_params)
391
502
  json_body = JSON.parse body
@@ -402,10 +513,11 @@ module Comet
402
513
  #
403
514
  # You must supply administrator authentication credentials to use this API.
404
515
  # This API requires the Auth Role to be enabled.
516
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
405
517
  #
406
- # @param [String] target_user New account username
407
- # @param [Comet::UserProfileConfig] profile_data New account profile
408
- # @param [String] target_organization (Optional) If present, create the user account on behalf of another organization. Only allowed for administrator accounts in the top-level organization. (>= 22.3.7)
518
+ # @param [String] target_user New account username (>= 17.2.0)
519
+ # @param [Comet::UserProfileConfig] profile_data New account profile (>= 17.2.0)
520
+ # @param [String] target_organization (Optional) If present, create the user account on behalf of another organization. Only allowed for administrator accounts in the top-level organization. (>= 22.5.0)
409
521
  # @return [Comet::CometAPIResponseMessage]
410
522
  def admin_add_user_from_profile(target_user, profile_data, target_organization = nil)
411
523
  submit_params = {}
@@ -436,14 +548,21 @@ module Comet
436
548
  # You must supply administrator authentication credentials to use this API.
437
549
  # Access to this API may be prevented on a per-administrator basis.
438
550
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
551
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
439
552
  #
440
553
  # @param [String] target_user the username of the admin to be deleted
554
+ # @param [String] target_org_id (Optional) the organization ID of the admin to be deleted. If omitted, defaults to the top-level organization. (>= 26.10.2)
441
555
  # @return [Comet::CometAPIResponseMessage]
442
- def admin_admin_user_delete(target_user)
556
+ def admin_admin_user_delete(target_user, target_org_id = nil)
443
557
  submit_params = {}
444
558
  raise TypeError, "'target_user' expected String, got #{target_user.class}" unless target_user.is_a? String
445
559
 
446
560
  submit_params['TargetUser'] = target_user
561
+ unless target_org_id.nil?
562
+ raise TypeError, "'target_org_id' expected String, got #{target_org_id.class}" unless target_org_id.is_a? String
563
+
564
+ submit_params['TargetOrgID'] = target_org_id
565
+ end
447
566
 
448
567
  body = perform_request('api/v1/admin/admin-user/delete', submit_params)
449
568
  json_body = JSON.parse body
@@ -460,10 +579,19 @@ module Comet
460
579
  # You must supply administrator authentication credentials to use this API.
461
580
  # Access to this API may be prevented on a per-administrator basis.
462
581
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
582
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
463
583
  #
584
+ # @param [String] target_org_id (Optional) If present, only list the administrators belonging to this organization. Otherwise, administrators from all organizations are listed. (>= 26.10.2)
464
585
  # @return [Array<Comet::AllowedAdminUser>]
465
- def admin_admin_user_list
466
- body = perform_request('api/v1/admin/admin-user/list')
586
+ def admin_admin_user_list(target_org_id = nil)
587
+ submit_params = {}
588
+ unless target_org_id.nil?
589
+ raise TypeError, "'target_org_id' expected String, got #{target_org_id.class}" unless target_org_id.is_a? String
590
+
591
+ submit_params['TargetOrgID'] = target_org_id
592
+ end
593
+
594
+ body = perform_request('api/v1/admin/admin-user/list', submit_params)
467
595
  json_body = JSON.parse body
468
596
  check_status json_body
469
597
  if json_body.nil?
@@ -485,10 +613,11 @@ module Comet
485
613
  # You must supply administrator authentication credentials to use this API.
486
614
  # Access to this API may be prevented on a per-administrator basis.
487
615
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
616
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
488
617
  #
489
618
  # @param [String] target_user the username for this new admin
490
619
  # @param [String] target_password the password for this new admin user
491
- # @param [String] target_org_id (Optional) provide the organization ID for this user, it will default to the org of the authenticating user otherwise
620
+ # @param [String] target_org_id (Optional) provide the organization ID for this user, it will default to the top-level organization otherwise.
492
621
  # @return [Comet::CometAPIResponseMessage]
493
622
  def admin_admin_user_new(target_user, target_password, target_org_id = nil)
494
623
  submit_params = {}
@@ -512,6 +641,47 @@ module Comet
512
641
  ret
513
642
  end
514
643
 
644
+ # AdminAdminUserSet
645
+ #
646
+ # Update another administrator.
647
+ # This API cannot update your own administrator account. Use the AdminAccountSetProperties API instead.
648
+ # The supplied Profile replaces the stored administrator account as-is, with the following exceptions:
649
+ # - The Username and OrganizationID fields must either be empty or match the target administrator. This API cannot rename an administrator or move it to another organization.
650
+ # - To set a new plaintext password, use a password format of 0 (PASSWORD_FORMAT_PLAINTEXT); it must be at least 8 characters. A password format of 4 (PASSWORD_FORMAT_UNVERIFIABLE) leaves the password unchanged.
651
+ # - APITokens may only be removed, or have their Description changed. New tokens must be created by the administrator themselves. Other fields of retained tokens are ignored.
652
+ # - IPWhitelist is cleared if the server license does not permit it.
653
+ #
654
+ # You must supply administrator authentication credentials to use this API.
655
+ # Access to this API may be prevented on a per-administrator basis.
656
+ # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
657
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
658
+ #
659
+ # @param [String] target_user the username of the admin to be updated (>= 26.10.2)
660
+ # @param [Comet::AllowedAdminUser] profile the updated administrator account (>= 26.10.2)
661
+ # @param [String] target_org_id (Optional) the organization ID of the admin to be updated. If omitted, defaults to the top-level organization. (>= 26.10.2)
662
+ # @return [Comet::CometAPIResponseMessage]
663
+ def admin_admin_user_set(target_user, profile, target_org_id = nil)
664
+ submit_params = {}
665
+ raise TypeError, "'target_user' expected String, got #{target_user.class}" unless target_user.is_a? String
666
+
667
+ submit_params['TargetUser'] = target_user
668
+ raise TypeError, "'profile' expected Comet::AllowedAdminUser, got #{profile.class}" unless profile.is_a? Comet::AllowedAdminUser
669
+
670
+ submit_params['Profile'] = profile.to_json
671
+ unless target_org_id.nil?
672
+ raise TypeError, "'target_org_id' expected String, got #{target_org_id.class}" unless target_org_id.is_a? String
673
+
674
+ submit_params['TargetOrgID'] = target_org_id
675
+ end
676
+
677
+ body = perform_request('api/v1/admin/admin-user/set', submit_params)
678
+ json_body = JSON.parse body
679
+ check_status json_body
680
+ ret = Comet::CometAPIResponseMessage.new
681
+ ret.from_hash(json_body)
682
+ ret
683
+ end
684
+
515
685
  # AdminBrandingAvailablePlatforms
516
686
  #
517
687
  # List available software download platforms.
@@ -595,7 +765,7 @@ module Comet
595
765
  # This API requires the Software Build Role to be enabled.
596
766
  # This API requires the Auth Role to be enabled.
597
767
  #
598
- # @param [String] self_address (Optional) The external URL of this server, used to resolve conflicts
768
+ # @param [String] self_address (Optional) The external URL of this server, used to resolve conflicts (>= 17.3.12)
599
769
  # @return [String]
600
770
  def admin_branding_generate_client_linuxgeneric(self_address = nil)
601
771
  submit_params = {}
@@ -884,9 +1054,10 @@ module Comet
884
1054
  #
885
1055
  # You must supply administrator authentication credentials to use this API.
886
1056
  # This API requires the Auth Role to be enabled.
1057
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
887
1058
  #
888
- # @param [String] subject Bulletin subject line
889
- # @param [String] content Bulletin message content
1059
+ # @param [String] subject Bulletin subject line (>= 17.3.5)
1060
+ # @param [String] content Bulletin message content (>= 17.3.5)
890
1061
  # @return [Comet::CometAPIResponseMessage]
891
1062
  def admin_bulletin_submit(subject, content)
892
1063
  submit_params = {}
@@ -911,6 +1082,7 @@ module Comet
911
1082
  #
912
1083
  # You must supply administrator authentication credentials to use this API.
913
1084
  # This API requires the Constellation Role to be enabled.
1085
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
914
1086
  #
915
1087
  # @return [Comet::ConstellationCheckReport]
916
1088
  def admin_constellation_last_report
@@ -928,6 +1100,7 @@ module Comet
928
1100
  #
929
1101
  # You must supply administrator authentication credentials to use this API.
930
1102
  # This API requires the Constellation Role to be enabled.
1103
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
931
1104
  #
932
1105
  # @return [Comet::ConstellationCheckReport]
933
1106
  def admin_constellation_new_report
@@ -946,6 +1119,7 @@ module Comet
946
1119
  # You must supply administrator authentication credentials to use this API.
947
1120
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
948
1121
  # This API requires the Constellation Role to be enabled.
1122
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
949
1123
  #
950
1124
  # @return [Comet::CometAPIResponseMessage]
951
1125
  def admin_constellation_prune_now
@@ -963,6 +1137,7 @@ module Comet
963
1137
  #
964
1138
  # You must supply administrator authentication credentials to use this API.
965
1139
  # This API requires the Constellation Role to be enabled.
1140
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
966
1141
  #
967
1142
  # @return [Comet::ConstellationStatusAPIResponse]
968
1143
  def admin_constellation_status
@@ -979,6 +1154,7 @@ module Comet
979
1154
  # Convert IAM Storage Role vault to its underlying S3 type.
980
1155
  #
981
1156
  # You must supply administrator authentication credentials to use this API.
1157
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
982
1158
  #
983
1159
  # @param [String] target_user The user to receive the new Storage Vault
984
1160
  # @param [String] destination_id The id of the old storage role destination to convert
@@ -1006,6 +1182,7 @@ module Comet
1006
1182
  #
1007
1183
  # You must supply administrator authentication credentials to use this API.
1008
1184
  # This API requires the Auth Role to be enabled.
1185
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1009
1186
  #
1010
1187
  # @param [Comet::SearchClause] query (No description available)
1011
1188
  # @return [Comet::CountJobsResponse]
@@ -1032,9 +1209,10 @@ module Comet
1032
1209
  #
1033
1210
  # You must supply administrator authentication credentials to use this API.
1034
1211
  # This API requires the Auth Role to be enabled.
1212
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1035
1213
  #
1036
1214
  # @param [String] target_user Selected account username
1037
- # @param [String] target_password Selected account password
1215
+ # @param [String] target_password Selected account password (>= 20.9.1)
1038
1216
  # @param [String] server (Optional) External URL of the authentication server that is different from the current server
1039
1217
  # @return [Comet::InstallTokenResponse]
1040
1218
  def admin_create_install_token(target_user, target_password, server = nil)
@@ -1065,6 +1243,7 @@ module Comet
1065
1243
  #
1066
1244
  # You must supply administrator authentication credentials to use this API.
1067
1245
  # This API requires the Auth Role to be enabled.
1246
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1068
1247
  #
1069
1248
  # @param [String] target_user Selected account username
1070
1249
  # @param [String] source_id Selected Protected Item GUID
@@ -1096,8 +1275,9 @@ module Comet
1096
1275
  #
1097
1276
  # You must supply administrator authentication credentials to use this API.
1098
1277
  # This API requires the Auth Role to be enabled.
1278
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1099
1279
  #
1100
- # @param [String] target_user Selected account username
1280
+ # @param [String] target_user Selected account username (>= 17.2.0)
1101
1281
  # @param [Comet::UninstallConfig] uninstall_config (Optional) Uninstall software configuration (>= 20.3.5)
1102
1282
  # @return [Comet::CometAPIResponseMessage]
1103
1283
  def admin_delete_user(target_user, uninstall_config = nil)
@@ -1125,6 +1305,7 @@ module Comet
1125
1305
  #
1126
1306
  # You must supply administrator authentication credentials to use this API.
1127
1307
  # This API requires the Auth Role to be enabled.
1308
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1128
1309
  #
1129
1310
  # @param [String] target_user Selected account username
1130
1311
  # @return [Comet::CometAPIResponseMessage]
@@ -1149,6 +1330,7 @@ module Comet
1149
1330
  #
1150
1331
  # You must supply administrator authentication credentials to use this API.
1151
1332
  # This API requires the Auth Role to be enabled.
1333
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1152
1334
  #
1153
1335
  # @param [String] target_id The live connection GUID
1154
1336
  # @param [String] destination The Storage Vault GUID
@@ -1176,6 +1358,7 @@ module Comet
1176
1358
  #
1177
1359
  # You must supply administrator authentication credentials to use this API.
1178
1360
  # This API requires the Auth Role to be enabled.
1361
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1179
1362
  #
1180
1363
  # @param [String] target_id The live connection GUID
1181
1364
  # @param [String] destination_id The Storage Vault GUID
@@ -1201,6 +1384,31 @@ module Comet
1201
1384
  ret
1202
1385
  end
1203
1386
 
1387
+ # AdminDispatcherClearLoginPassword
1388
+ #
1389
+ # Instruct a live connected device to discard its stored login password and return to the login screen.
1390
+ # The device keeps its username and server URL, so only the new password needs to be re-entered. Use this after a server-side password change when the device should not be given the new password automatically. Devices older than 26.11.3 cannot retain the login details and receive the force-login behavior instead, discarding all stored credentials.
1391
+ #
1392
+ # You must supply administrator authentication credentials to use this API.
1393
+ # This API requires the Auth Role to be enabled.
1394
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1395
+ #
1396
+ # @param [String] target_id The live connection GUID (>= 26.11.3)
1397
+ # @return [Comet::CometAPIResponseMessage]
1398
+ def admin_dispatcher_clear_login_password(target_id)
1399
+ submit_params = {}
1400
+ raise TypeError, "'target_id' expected String, got #{target_id.class}" unless target_id.is_a? String
1401
+
1402
+ submit_params['TargetID'] = target_id
1403
+
1404
+ body = perform_request('api/v1/admin/dispatcher/clear-login-password', submit_params)
1405
+ json_body = JSON.parse body
1406
+ check_status json_body
1407
+ ret = Comet::CometAPIResponseMessage.new
1408
+ ret.from_hash(json_body)
1409
+ ret
1410
+ end
1411
+
1204
1412
  # AdminDispatcherDeepverifyStorageVault
1205
1413
  #
1206
1414
  # Instruct a live connected device to deeply verify Storage Vault content.
@@ -1208,6 +1416,7 @@ module Comet
1208
1416
  #
1209
1417
  # You must supply administrator authentication credentials to use this API.
1210
1418
  # This API requires the Auth Role to be enabled.
1419
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1211
1420
  #
1212
1421
  # @param [String] target_id The live connection GUID
1213
1422
  # @param [String] destination The Storage Vault GUID
@@ -1235,6 +1444,7 @@ module Comet
1235
1444
  #
1236
1445
  # You must supply administrator authentication credentials to use this API.
1237
1446
  # This API requires the Auth Role to be enabled.
1447
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1238
1448
  #
1239
1449
  # @param [String] target_id The live connection GUID
1240
1450
  # @param [String] destination_id The Storage Vault GUID
@@ -1267,6 +1477,7 @@ module Comet
1267
1477
  #
1268
1478
  # You must supply administrator authentication credentials to use this API.
1269
1479
  # This API requires the Auth Role to be enabled.
1480
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1270
1481
  #
1271
1482
  # @param [String] target_id The live connection GUID
1272
1483
  # @param [String] destination_id The Storage Vault GUID
@@ -1299,8 +1510,9 @@ module Comet
1299
1510
  #
1300
1511
  # You must supply administrator authentication credentials to use this API.
1301
1512
  # This API requires the Auth Role to be enabled.
1513
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1302
1514
  #
1303
- # @param [String] target_id The live connection GUID
1515
+ # @param [String] target_id The live connection GUID (>= 17.2.0)
1304
1516
  # @return [Comet::CometAPIResponseMessage]
1305
1517
  def admin_dispatcher_drop_connection(target_id)
1306
1518
  submit_params = {}
@@ -1323,6 +1535,7 @@ module Comet
1323
1535
  #
1324
1536
  # You must supply administrator authentication credentials to use this API.
1325
1537
  # This API requires the Auth Role to be enabled.
1538
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1326
1539
  #
1327
1540
  # @param [String] target_id The live connection GUID
1328
1541
  # @param [String] snapshot where the email belongs to
@@ -1359,6 +1572,7 @@ module Comet
1359
1572
  #
1360
1573
  # You must supply administrator authentication credentials to use this API.
1361
1574
  # This API requires the Auth Role to be enabled.
1575
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1362
1576
  #
1363
1577
  # @param [String] target_id The live connection GUID
1364
1578
  # @return [Comet::CometAPIResponseMessage]
@@ -1383,6 +1597,7 @@ module Comet
1383
1597
  # You must supply administrator authentication credentials to use this API.
1384
1598
  # This API requires the Auth Role to be enabled.
1385
1599
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
1600
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1386
1601
  #
1387
1602
  # @param [String] organization_id Target organization
1388
1603
  # @return [Comet::OrganizationLoginURLResponse]
@@ -1407,6 +1622,7 @@ module Comet
1407
1622
  #
1408
1623
  # You must supply administrator authentication credentials to use this API.
1409
1624
  # This API requires the Auth Role to be enabled.
1625
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1410
1626
  #
1411
1627
  # @param [String] target_id The live connection GUID
1412
1628
  # @param [String] import_source_id The selected import source, as found by the AdminDispatcherRequestImportSources API
@@ -1435,8 +1651,9 @@ module Comet
1435
1651
  #
1436
1652
  # You must supply administrator authentication credentials to use this API.
1437
1653
  # This API requires the Auth Role to be enabled.
1654
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1438
1655
  #
1439
- # @param [String] target_id The live connection GUID
1656
+ # @param [String] target_id The live connection GUID (>= 17.2.0)
1440
1657
  # @return [Comet::CometAPIResponseMessage]
1441
1658
  def admin_dispatcher_kill_process(target_id)
1442
1659
  submit_params = {}
@@ -1458,8 +1675,9 @@ module Comet
1458
1675
  #
1459
1676
  # You must supply administrator authentication credentials to use this API.
1460
1677
  # This API requires the Auth Role to be enabled.
1678
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1461
1679
  #
1462
- # @param [String] user_name_filter (Optional) User name filter string
1680
+ # @param [String] user_name_filter (Optional) User name filter string (>= 22.6.5)
1463
1681
  # @return [Hash{String => Comet::LiveUserConnection}]
1464
1682
  def admin_dispatcher_list_active(user_name_filter = nil)
1465
1683
  submit_params = {}
@@ -1491,6 +1709,7 @@ module Comet
1491
1709
  #
1492
1710
  # You must supply administrator authentication credentials to use this API.
1493
1711
  # This API requires the Auth Role to be enabled.
1712
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1494
1713
  #
1495
1714
  # @param [String] target_id The live connection GUID
1496
1715
  # @param [Comet::Office365Credential] credentials The Office365 account credential
@@ -1518,6 +1737,7 @@ module Comet
1518
1737
  #
1519
1738
  # You must supply administrator authentication credentials to use this API.
1520
1739
  # This API requires the Auth Role to be enabled.
1740
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1521
1741
  #
1522
1742
  # @param [String] target_id The live connection GUID
1523
1743
  # @param [Comet::DestinationLocation] extra_data The destination location settings
@@ -1542,12 +1762,13 @@ module Comet
1542
1762
  # AdminDispatcherRefetchProfile
1543
1763
  #
1544
1764
  # Instruct a live connected device to refresh their profile.
1545
- # This command is understood by Comet Backup 17.12.0 and newer.
1765
+ # This command is understood by Comet Backup 17.2.0 and newer.
1546
1766
  #
1547
1767
  # You must supply administrator authentication credentials to use this API.
1548
1768
  # This API requires the Auth Role to be enabled.
1769
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1549
1770
  #
1550
- # @param [String] target_id The live connection GUID
1771
+ # @param [String] target_id The live connection GUID (>= 17.2.0)
1551
1772
  # @return [Comet::CometAPIResponseMessage]
1552
1773
  def admin_dispatcher_refetch_profile(target_id)
1553
1774
  submit_params = {}
@@ -1570,6 +1791,7 @@ module Comet
1570
1791
  #
1571
1792
  # You must supply administrator authentication credentials to use this API.
1572
1793
  # This API requires the Auth Role to be enabled.
1794
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1573
1795
  #
1574
1796
  # @param [String] target_id The live connection GUID
1575
1797
  # @param [String] email_address The email address of the Azure AD administrator
@@ -1598,6 +1820,7 @@ module Comet
1598
1820
  #
1599
1821
  # You must supply administrator authentication credentials to use this API.
1600
1822
  # This API requires the Auth Role to be enabled.
1823
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1601
1824
  #
1602
1825
  # @param [String] target_id The live connection GUID
1603
1826
  # @param [String] continuation The ID returned from the AdminDispatcherRegisterOfficeApplicationBegin endpoint
@@ -1626,6 +1849,7 @@ module Comet
1626
1849
  #
1627
1850
  # You must supply administrator authentication credentials to use this API.
1628
1851
  # This API requires the Auth Role to be enabled.
1852
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1629
1853
  #
1630
1854
  # @param [String] target_id The live connection GUID
1631
1855
  # @param [String] destination The Storage Vault GUID
@@ -1653,6 +1877,7 @@ module Comet
1653
1877
  #
1654
1878
  # You must supply administrator authentication credentials to use this API.
1655
1879
  # This API requires the Auth Role to be enabled.
1880
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1656
1881
  #
1657
1882
  # @param [String] target_id The live connection GUID
1658
1883
  # @return [Comet::BrowseDiskDrivesResponse]
@@ -1676,6 +1901,7 @@ module Comet
1676
1901
  #
1677
1902
  # You must supply administrator authentication credentials to use this API.
1678
1903
  # This API requires the Auth Role to be enabled.
1904
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1679
1905
  #
1680
1906
  # @param [String] target_id The live connection GUID
1681
1907
  # @return [Comet::BrowseEDBResponse]
@@ -1699,6 +1925,7 @@ module Comet
1699
1925
  #
1700
1926
  # You must supply administrator authentication credentials to use this API.
1701
1927
  # This API requires the Auth Role to be enabled.
1928
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1702
1929
  #
1703
1930
  # @param [String] target_id The live connection GUID
1704
1931
  # @return [Comet::BrowseHVResponse]
@@ -1723,6 +1950,7 @@ module Comet
1723
1950
  #
1724
1951
  # You must supply administrator authentication credentials to use this API.
1725
1952
  # This API requires the Auth Role to be enabled.
1953
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1726
1954
  #
1727
1955
  # @param [String] target_id The live connection GUID
1728
1956
  # @param [Comet::MongoDBConnection] credentials The Mongo database authentication settings
@@ -1751,6 +1979,7 @@ module Comet
1751
1979
  #
1752
1980
  # You must supply administrator authentication credentials to use this API.
1753
1981
  # This API requires the Auth Role to be enabled.
1982
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1754
1983
  #
1755
1984
  # @param [String] target_id The live connection GUID
1756
1985
  # @param [Comet::MSSQLConnection] credentials The MSSQL database authentication settings
@@ -1779,6 +2008,7 @@ module Comet
1779
2008
  #
1780
2009
  # You must supply administrator authentication credentials to use this API.
1781
2010
  # This API requires the Auth Role to be enabled.
2011
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1782
2012
  #
1783
2013
  # @param [String] target_id The live connection GUID
1784
2014
  # @param [Comet::MySQLConnection] credentials The MySQL database authentication settings
@@ -1800,12 +2030,42 @@ module Comet
1800
2030
  ret
1801
2031
  end
1802
2032
 
2033
+ # AdminDispatcherRequestBrowsePostgresql
2034
+ #
2035
+ # Request a list of databases in a PostgreSQL server.
2036
+ # The remote device must have given consent for an MSP to browse their files.
2037
+ #
2038
+ # You must supply administrator authentication credentials to use this API.
2039
+ # This API requires the Auth Role to be enabled.
2040
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2041
+ #
2042
+ # @param [String] target_id The live connection GUID (>= 26.11.0)
2043
+ # @param [Comet::PostgreSQLConnection] credentials The PostgreSQL database authentication settings (>= 26.11.0)
2044
+ # @return [Comet::BrowseSQLServerResponse]
2045
+ def admin_dispatcher_request_browse_postgresql(target_id, credentials)
2046
+ submit_params = {}
2047
+ raise TypeError, "'target_id' expected String, got #{target_id.class}" unless target_id.is_a? String
2048
+
2049
+ submit_params['TargetID'] = target_id
2050
+ raise TypeError, "'credentials' expected Comet::PostgreSQLConnection, got #{credentials.class}" unless credentials.is_a? Comet::PostgreSQLConnection
2051
+
2052
+ submit_params['Credentials'] = credentials.to_json
2053
+
2054
+ body = perform_request('api/v1/admin/dispatcher/request-browse-postgresql', submit_params)
2055
+ json_body = JSON.parse body
2056
+ check_status json_body
2057
+ ret = Comet::BrowseSQLServerResponse.new
2058
+ ret.from_hash(json_body)
2059
+ ret
2060
+ end
2061
+
1803
2062
  # AdminDispatcherRequestBrowseProxmox
1804
2063
  #
1805
2064
  # Request a list of Proxmox virtual machines and containers.
1806
2065
  #
1807
2066
  # You must supply administrator authentication credentials to use this API.
1808
2067
  # This API requires the Auth Role to be enabled.
2068
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1809
2069
  #
1810
2070
  # @param [String] target_id The live connection GUID
1811
2071
  # @param [Comet::ProxmoxConnection] credentials The Proxmox connection settings
@@ -1833,6 +2093,7 @@ module Comet
1833
2093
  #
1834
2094
  # You must supply administrator authentication credentials to use this API.
1835
2095
  # This API requires the Auth Role to be enabled.
2096
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1836
2097
  #
1837
2098
  # @param [String] target_id The live connection GUID
1838
2099
  # @param [Comet::SSHConnection] credentials The SSH connection settings
@@ -1860,10 +2121,11 @@ module Comet
1860
2121
  #
1861
2122
  # You must supply administrator authentication credentials to use this API.
1862
2123
  # This API requires the Auth Role to be enabled.
2124
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1863
2125
  #
1864
2126
  # @param [String] target_id The live connection GUID
1865
2127
  # @param [Comet::SSHConnection] credentials The SSH connection settings
1866
- # @param [String] node The target node
2128
+ # @param [String] node The target node (>= 25.9.7)
1867
2129
  # @return [Comet::BrowseProxmoxStorageResponse]
1868
2130
  def admin_dispatcher_request_browse_proxmox_storage(target_id, credentials, node)
1869
2131
  submit_params = {}
@@ -1892,6 +2154,7 @@ module Comet
1892
2154
  #
1893
2155
  # You must supply administrator authentication credentials to use this API.
1894
2156
  # This API requires the Auth Role to be enabled.
2157
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1895
2158
  #
1896
2159
  # @param [String] target_id The live connection GUID
1897
2160
  # @param [Comet::VMwareConnection] credentials The VMware vSphere connection settings
@@ -1920,6 +2183,7 @@ module Comet
1920
2183
  #
1921
2184
  # You must supply administrator authentication credentials to use this API.
1922
2185
  # This API requires the Auth Role to be enabled.
2186
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1923
2187
  #
1924
2188
  # @param [String] target_id The live connection GUID
1925
2189
  # @param [Comet::VMwareConnection] credentials The VMware vSphere connection settings
@@ -1948,6 +2212,7 @@ module Comet
1948
2212
  #
1949
2213
  # You must supply administrator authentication credentials to use this API.
1950
2214
  # This API requires the Auth Role to be enabled.
2215
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1951
2216
  #
1952
2217
  # @param [String] target_id The live connection GUID
1953
2218
  # @param [Comet::VMwareConnection] credentials The VMware vSphere connection settings
@@ -1980,6 +2245,7 @@ module Comet
1980
2245
  #
1981
2246
  # You must supply administrator authentication credentials to use this API.
1982
2247
  # This API requires the Auth Role to be enabled.
2248
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
1983
2249
  #
1984
2250
  # @param [String] target_id The live connection GUID
1985
2251
  # @param [Comet::VMwareConnection] credentials The VMware vSphere connection settings
@@ -2012,6 +2278,7 @@ module Comet
2012
2278
  #
2013
2279
  # You must supply administrator authentication credentials to use this API.
2014
2280
  # This API requires the Auth Role to be enabled.
2281
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2015
2282
  #
2016
2283
  # @param [String] target_id The live connection GUID
2017
2284
  # @param [Comet::VMwareConnection] credentials The VMware vSphere connection settings
@@ -2043,6 +2310,7 @@ module Comet
2043
2310
  #
2044
2311
  # You must supply administrator authentication credentials to use this API.
2045
2312
  # This API requires the Auth Role to be enabled.
2313
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2046
2314
  #
2047
2315
  # @param [String] target_id The live connection GUID
2048
2316
  # @return [Comet::BrowseVSSResponse]
@@ -2067,6 +2335,7 @@ module Comet
2067
2335
  #
2068
2336
  # You must supply administrator authentication credentials to use this API.
2069
2337
  # This API requires the Auth Role to be enabled.
2338
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2070
2339
  #
2071
2340
  # @param [String] target_id The live connection GUID
2072
2341
  # @param [String] path (Optional) Browse objects inside this path. If empty or not present, returns the top-level device paths
@@ -2096,6 +2365,7 @@ module Comet
2096
2365
  #
2097
2366
  # You must supply administrator authentication credentials to use this API.
2098
2367
  # This API requires the Auth Role to be enabled.
2368
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2099
2369
  #
2100
2370
  # @param [String] target_id The live connection GUID
2101
2371
  # @return [Comet::DispatcherAdminSourcesResponse]
@@ -2121,6 +2391,7 @@ module Comet
2121
2391
  #
2122
2392
  # You must supply administrator authentication credentials to use this API.
2123
2393
  # This API requires the Auth Role to be enabled.
2394
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2124
2395
  #
2125
2396
  # @param [String] target_id The live connection GUID
2126
2397
  # @param [Comet::Office365Credential] credentials The Office365 account credential
@@ -2149,6 +2420,7 @@ module Comet
2149
2420
  #
2150
2421
  # You must supply administrator authentication credentials to use this API.
2151
2422
  # This API requires the Auth Role to be enabled.
2423
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2152
2424
  #
2153
2425
  # @param [String] target_id The live connection GUID
2154
2426
  # @param [Comet::Office365Credential] credentials The Office365 account credential
@@ -2178,12 +2450,13 @@ module Comet
2178
2450
  #
2179
2451
  # You must supply administrator authentication credentials to use this API.
2180
2452
  # This API requires the Auth Role to be enabled.
2453
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2181
2454
  #
2182
2455
  # @param [String] target_id The live connection GUID
2183
2456
  # @param [String] destination The Storage Vault ID
2184
2457
  # @param [String] snapshot_id The selected backup job snapshot
2185
2458
  # @param [String] tree_id (Optional) Browse objects inside subdirectory of backup snapshot. If it is for VMDK single file restore, it should be the disk image's subtree ID.
2186
- # @param [Comet::VMDKSnapshotViewOptions] options (Optional) Request a list of stored objects in vmdk file
2459
+ # @param [Comet::VMDKSnapshotViewOptions] options (Optional) Request a list of stored objects in vmdk file (>= 21.12.5)
2187
2460
  # @return [Comet::DispatcherStoredObjectsResponse]
2188
2461
  def admin_dispatcher_request_stored_objects(target_id, destination, snapshot_id, tree_id = nil, options = nil)
2189
2462
  submit_params = {}
@@ -2221,6 +2494,7 @@ module Comet
2221
2494
  #
2222
2495
  # You must supply administrator authentication credentials to use this API.
2223
2496
  # This API requires the Auth Role to be enabled.
2497
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2224
2498
  #
2225
2499
  # @param [String] target_id The live connection GUID
2226
2500
  # @param [String] destination The Storage Vault ID
@@ -2248,6 +2522,7 @@ module Comet
2248
2522
  #
2249
2523
  # You must supply administrator authentication credentials to use this API.
2250
2524
  # This API requires the Auth Role to be enabled.
2525
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2251
2526
  #
2252
2527
  # @param [String] target_id The live connection GUID
2253
2528
  # @param [String] destination The Storage Vault ID
@@ -2279,8 +2554,9 @@ module Comet
2279
2554
  #
2280
2555
  # You must supply administrator authentication credentials to use this API.
2281
2556
  # This API requires the Auth Role to be enabled.
2557
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2282
2558
  #
2283
- # @param [String] target_id The live connection GUID
2559
+ # @param [String] target_id The live connection GUID (>= 17.2.0)
2284
2560
  # @param [String] backup_rule The schedule GUID
2285
2561
  # @return [Comet::DispatchWithJobIDResponse]
2286
2562
  def admin_dispatcher_run_backup(target_id, backup_rule)
@@ -2306,10 +2582,11 @@ module Comet
2306
2582
  #
2307
2583
  # You must supply administrator authentication credentials to use this API.
2308
2584
  # This API requires the Auth Role to be enabled.
2585
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2309
2586
  #
2310
- # @param [String] target_id The live connection GUID
2311
- # @param [String] source The Protected Item GUID
2312
- # @param [String] destination The Storage Vault GUID
2587
+ # @param [String] target_id The live connection GUID (>= 17.2.0)
2588
+ # @param [String] source The Protected Item GUID (>= 17.2.0)
2589
+ # @param [String] destination The Storage Vault GUID (>= 17.2.0)
2313
2590
  # @param [Comet::BackupJobAdvancedOptions] options (Optional) Extra job parameters (>= 19.3.6)
2314
2591
  # @return [Comet::DispatchWithJobIDResponse]
2315
2592
  def admin_dispatcher_run_backup_custom(target_id, source, destination, options = nil)
@@ -2344,6 +2621,7 @@ module Comet
2344
2621
  #
2345
2622
  # You must supply administrator authentication credentials to use this API.
2346
2623
  # This API requires the Auth Role to be enabled.
2624
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2347
2625
  #
2348
2626
  # @param [String] target_id The live connection GUID
2349
2627
  # @param [String] path The local path to restore to
@@ -2388,10 +2666,11 @@ module Comet
2388
2666
  # AdminDispatcherRunRestoreCustom
2389
2667
  #
2390
2668
  # Instruct a live connected device to perform a local restore.
2391
- # This command is understood by Comet Backup 18.6.0 and newer.
2669
+ # This command is understood by Comet Backup 19.6.0 and newer.
2392
2670
  #
2393
2671
  # You must supply administrator authentication credentials to use this API.
2394
2672
  # This API requires the Auth Role to be enabled.
2673
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2395
2674
  #
2396
2675
  # @param [String] target_id The live connection GUID
2397
2676
  # @param [String] source The Protected Item ID
@@ -2399,9 +2678,9 @@ module Comet
2399
2678
  # @param [Comet::RestoreJobAdvancedOptions] options Restore targets
2400
2679
  # @param [String] snapshot (Optional) If present, restore a specific snapshot. Otherwise, restore the latest snapshot for the selected Protected Item + Storage Vault pair
2401
2680
  # @param [Array<String>] paths (Optional) If present, restore these paths only. Otherwise, restore all data
2402
- # @param [Number] known_file_count (Optional) The number of files to restore, if known. Supplying this means we don't need to walk the entire tree just to find the file count and will speed up the restoration process.
2403
- # @param [Number] known_byte_count (Optional) The total size in bytes of files to restore, if known. Supplying this means we don't need to walk the entire tree just to find the total file size and will speed up the restoration process.
2404
- # @param [Number] known_dir_count (Optional) The number of directories to restore, if known. Supplying this means we don't need to walk the entire tree just to find the number of directories and will speed up the restoration process.
2681
+ # @param [Number] known_file_count (Optional) The number of files to restore, if known. Supplying this means we don't need to walk the entire tree just to find the file count and will speed up the restoration process. (>= 23.6.0)
2682
+ # @param [Number] known_byte_count (Optional) The total size in bytes of files to restore, if known. Supplying this means we don't need to walk the entire tree just to find the total file size and will speed up the restoration process. (>= 23.6.0)
2683
+ # @param [Number] known_dir_count (Optional) The number of directories to restore, if known. Supplying this means we don't need to walk the entire tree just to find the number of directories and will speed up the restoration process. (>= 23.6.0)
2405
2684
  # @return [Comet::DispatchWithJobIDResponse]
2406
2685
  def admin_dispatcher_run_restore_custom(target_id, source, destination, options, snapshot = nil, paths = nil, known_file_count = nil, known_byte_count = nil, known_dir_count = nil)
2407
2686
  submit_params = {}
@@ -2457,6 +2736,7 @@ module Comet
2457
2736
  #
2458
2737
  # You must supply administrator authentication credentials to use this API.
2459
2738
  # This API requires the Auth Role to be enabled.
2739
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2460
2740
  #
2461
2741
  # @param [String] target_id The live connection GUID
2462
2742
  # @param [String] destination_id The Storage Vault GUID
@@ -2486,12 +2766,41 @@ module Comet
2486
2766
  ret
2487
2767
  end
2488
2768
 
2769
+ # AdminDispatcherTestProxmoxConnection
2770
+ #
2771
+ # Test the connection to a Proxmox cluster node over SSH.
2772
+ #
2773
+ # You must supply administrator authentication credentials to use this API.
2774
+ # This API requires the Auth Role to be enabled.
2775
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2776
+ #
2777
+ # @param [String] target_id The live connection GUID
2778
+ # @param [Comet::SSHConnection] credentials The SSH connection settings
2779
+ # @return [Comet::CometAPIResponseMessage]
2780
+ def admin_dispatcher_test_proxmox_connection(target_id, credentials)
2781
+ submit_params = {}
2782
+ raise TypeError, "'target_id' expected String, got #{target_id.class}" unless target_id.is_a? String
2783
+
2784
+ submit_params['TargetID'] = target_id
2785
+ raise TypeError, "'credentials' expected Comet::SSHConnection, got #{credentials.class}" unless credentials.is_a? Comet::SSHConnection
2786
+
2787
+ submit_params['Credentials'] = credentials.to_json
2788
+
2789
+ body = perform_request('api/v1/admin/dispatcher/test-proxmox-connection', submit_params)
2790
+ json_body = JSON.parse body
2791
+ check_status json_body
2792
+ ret = Comet::CometAPIResponseMessage.new
2793
+ ret.from_hash(json_body)
2794
+ ret
2795
+ end
2796
+
2489
2797
  # AdminDispatcherTestSmbAuth
2490
2798
  #
2491
2799
  # Test a set of Windows SMB credentials.
2492
2800
  #
2493
2801
  # You must supply administrator authentication credentials to use this API.
2494
2802
  # This API requires the Auth Role to be enabled.
2803
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2495
2804
  #
2496
2805
  # @param [String] target_id The live connection GUID
2497
2806
  # @param [Comet::WinSMBAuth] wsa The target credentials to test
@@ -2519,6 +2828,7 @@ module Comet
2519
2828
  #
2520
2829
  # You must supply administrator authentication credentials to use this API.
2521
2830
  # This API requires the Auth Role to be enabled.
2831
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2522
2832
  #
2523
2833
  # @param [String] target_id The live connection GUID
2524
2834
  # @param [Boolean] remove_config_file Determine if the config.dat file will be deleted at the same time
@@ -2546,10 +2856,11 @@ module Comet
2546
2856
  #
2547
2857
  # You must supply administrator authentication credentials to use this API.
2548
2858
  # This API requires the Auth Role to be enabled.
2859
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2549
2860
  #
2550
2861
  # @param [String] target_id The live connection GUID
2551
2862
  # @param [String] destination The Storage Vault GUID
2552
- # @param [Boolean] allow_unsafe (Optional) Allow legacy Storage Vault unlocking, which is unsafe in some cases.
2863
+ # @param [Boolean] allow_unsafe (Optional) Allow legacy Storage Vault unlocking, which is unsafe in some cases. (>= 25.3.0)
2553
2864
  # @return [Comet::CometAPIResponseMessage]
2554
2865
  def admin_dispatcher_unlock(target_id, destination, allow_unsafe = nil)
2555
2866
  submit_params = {}
@@ -2574,9 +2885,11 @@ module Comet
2574
2885
  # AdminDispatcherUpdateLoginPassword
2575
2886
  #
2576
2887
  # Instruct a live connected device to update its login password.
2888
+ # This does not change the user profile password, it only tells the device to use an updated password.
2577
2889
  #
2578
2890
  # You must supply administrator authentication credentials to use this API.
2579
2891
  # This API requires the Auth Role to be enabled.
2892
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2580
2893
  #
2581
2894
  # @param [String] target_id The live connection GUID
2582
2895
  # @param [String] new_password The new password of this user
@@ -2605,10 +2918,11 @@ module Comet
2605
2918
  #
2606
2919
  # You must supply administrator authentication credentials to use this API.
2607
2920
  # This API requires the Auth Role to be enabled.
2921
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2608
2922
  #
2609
2923
  # @param [String] target_id The live connection GUID
2610
2924
  # @param [String] new_url The new external URL of this server
2611
- # @param [Boolean] force (Optional) No checks will be done using previous URL
2925
+ # @param [Boolean] force (Optional) No checks will be done using previous URL (>= 22.9.3)
2612
2926
  # @return [Comet::CometAPIResponseMessage]
2613
2927
  def admin_dispatcher_update_login_url(target_id, new_url, force = nil)
2614
2928
  submit_params = {}
@@ -2633,15 +2947,18 @@ module Comet
2633
2947
  # AdminDispatcherUpdateSoftware
2634
2948
  #
2635
2949
  # Instruct a live connected device to download a software update.
2950
+ # By default the request is queued for delivery and this API returns immediately, without waiting for the device. If WaitForConfirmation is true and the device supports confirming update requests, this API instead waits up to ten seconds for the device to confirm that it has accepted the request, and reports the device's response. A device that does not support it is sent the request without waiting, as if WaitForConfirmation were false.
2636
2951
  #
2637
2952
  # You must supply administrator authentication credentials to use this API.
2638
2953
  # This API requires the Auth Role to be enabled.
2639
2954
  # This API requires the Software Build Role to be enabled.
2955
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2640
2956
  #
2641
- # @param [String] target_id The live connection GUID
2957
+ # @param [String] target_id The live connection GUID (>= 17.2.0)
2642
2958
  # @param [String] self_address (Optional) The external URL of this server, used to resolve conflicts (>= 19.3.11)
2959
+ # @param [Boolean] wait_for_confirmation (Optional) If true, wait for the device to confirm that it accepted the request (>= 26.11.2)
2643
2960
  # @return [Comet::CometAPIResponseMessage]
2644
- def admin_dispatcher_update_software(target_id, self_address = nil)
2961
+ def admin_dispatcher_update_software(target_id, self_address = nil, wait_for_confirmation = nil)
2645
2962
  submit_params = {}
2646
2963
  raise TypeError, "'target_id' expected String, got #{target_id.class}" unless target_id.is_a? String
2647
2964
 
@@ -2653,6 +2970,9 @@ module Comet
2653
2970
 
2654
2971
  submit_params['SelfAddress'] = self_address
2655
2972
  end
2973
+ unless wait_for_confirmation.nil?
2974
+ submit_params['WaitForConfirmation'] = (wait_for_confirmation ? 1 : 0)
2975
+ end
2656
2976
 
2657
2977
  body = perform_request('api/v1/admin/dispatcher/update-software', submit_params)
2658
2978
  json_body = JSON.parse body
@@ -2667,6 +2987,7 @@ module Comet
2667
2987
  # Delete an external admin authentication source.
2668
2988
  #
2669
2989
  # You must supply administrator authentication credentials to use this API.
2990
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2670
2991
  #
2671
2992
  # @param [String] source_id (No description available)
2672
2993
  # @return [Comet::CometAPIResponseMessage]
@@ -2689,6 +3010,7 @@ module Comet
2689
3010
  # Get a map of all external admin authentication sources.
2690
3011
  #
2691
3012
  # You must supply administrator authentication credentials to use this API.
3013
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2692
3014
  #
2693
3015
  # @return [Hash{String => Comet::ExternalAuthenticationSource}]
2694
3016
  def admin_external_auth_sources_get
@@ -2712,6 +3034,7 @@ module Comet
2712
3034
  # Create an external admin authentication source.
2713
3035
  #
2714
3036
  # You must supply administrator authentication credentials to use this API.
3037
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2715
3038
  #
2716
3039
  # @param [Comet::ExternalAuthenticationSource] source (No description available)
2717
3040
  # @param [String] source_id (Optional) (No description available)
@@ -2741,6 +3064,7 @@ module Comet
2741
3064
  # sources for the tenant; none will be preserved.
2742
3065
  #
2743
3066
  # You must supply administrator authentication credentials to use this API.
3067
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2744
3068
  #
2745
3069
  # @param [Hash{String => Comet::ExternalAuthenticationSource}] sources (No description available)
2746
3070
  # @return [Comet::CometAPIResponseMessage]
@@ -2764,8 +3088,9 @@ module Comet
2764
3088
  #
2765
3089
  # You must supply administrator authentication credentials to use this API.
2766
3090
  # This API requires the Auth Role to be enabled.
3091
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2767
3092
  #
2768
- # @param [String] job_id Selected job ID
3093
+ # @param [String] job_id Selected job ID (>= 17.2.0)
2769
3094
  # @return [String]
2770
3095
  def admin_get_job_log(job_id)
2771
3096
  submit_params = {}
@@ -2782,10 +3107,11 @@ module Comet
2782
3107
  #
2783
3108
  # You must supply administrator authentication credentials to use this API.
2784
3109
  # This API requires the Auth Role to be enabled.
3110
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2785
3111
  #
2786
3112
  # @param [String] job_id Selected job ID
2787
- # @param [String] min_severity (Optional) Return only job log entries with equal or higher severity
2788
- # @param [String] message_contains (Optional) Return only job log entries that contain exact string
3113
+ # @param [String] min_severity (Optional) Return only job log entries with equal or higher severity (>= 23.3.1)
3114
+ # @param [String] message_contains (Optional) Return only job log entries that contain exact string (>= 23.3.1)
2789
3115
  # @return [Array<Comet::JobEntry>]
2790
3116
  def admin_get_job_log_entries(job_id, min_severity = nil, message_contains = nil)
2791
3117
  submit_params = {}
@@ -2824,8 +3150,9 @@ module Comet
2824
3150
  #
2825
3151
  # You must supply administrator authentication credentials to use this API.
2826
3152
  # This API requires the Auth Role to be enabled.
3153
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2827
3154
  #
2828
- # @param [String] job_id Selected job ID
3155
+ # @param [String] job_id Selected job ID (>= 17.2.0)
2829
3156
  # @return [Comet::BackupJobDetail]
2830
3157
  def admin_get_job_properties(job_id)
2831
3158
  submit_params = {}
@@ -2848,6 +3175,7 @@ module Comet
2848
3175
  #
2849
3176
  # You must supply administrator authentication credentials to use this API.
2850
3177
  # This API requires the Auth Role to be enabled.
3178
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2851
3179
  #
2852
3180
  # @return [Array<Comet::BackupJobDetail>]
2853
3181
  def admin_get_jobs_all
@@ -2873,6 +3201,7 @@ module Comet
2873
3201
  #
2874
3202
  # You must supply administrator authentication credentials to use this API.
2875
3203
  # This API requires the Auth Role to be enabled.
3204
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2876
3205
  #
2877
3206
  # @param [Comet::SearchClause] query (No description available)
2878
3207
  # @return [Array<Comet::BackupJobDetail>]
@@ -2912,6 +3241,7 @@ module Comet
2912
3241
  #
2913
3242
  # You must supply administrator authentication credentials to use this API.
2914
3243
  # This API requires the Auth Role to be enabled.
3244
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2915
3245
  #
2916
3246
  # @param [Number] start_value Timestamp (Unix)
2917
3247
  # @param [Number] end_value Timestamp (Unix)
@@ -2947,8 +3277,9 @@ module Comet
2947
3277
  #
2948
3278
  # You must supply administrator authentication credentials to use this API.
2949
3279
  # This API requires the Auth Role to be enabled.
3280
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2950
3281
  #
2951
- # @param [String] target_user Selected username
3282
+ # @param [String] target_user Selected username (>= 17.2.0)
2952
3283
  # @return [Array<Comet::BackupJobDetail>]
2953
3284
  def admin_get_jobs_for_user(target_user)
2954
3285
  submit_params = {}
@@ -2978,6 +3309,7 @@ module Comet
2978
3309
  #
2979
3310
  # You must supply administrator authentication credentials to use this API.
2980
3311
  # This API requires the Auth Role to be enabled.
3312
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
2981
3313
  #
2982
3314
  # @return [Array<Comet::BackupJobDetail>]
2983
3315
  def admin_get_jobs_recent
@@ -3002,6 +3334,7 @@ module Comet
3002
3334
  #
3003
3335
  # You must supply administrator authentication credentials to use this API.
3004
3336
  # This API requires the Auth Role to be enabled.
3337
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3005
3338
  #
3006
3339
  # @param [String] target_user Selected account username
3007
3340
  # @param [String] source_id Selected Protected Item GUID
@@ -3029,8 +3362,9 @@ module Comet
3029
3362
  #
3030
3363
  # You must supply administrator authentication credentials to use this API.
3031
3364
  # This API requires the Auth Role to be enabled.
3365
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3032
3366
  #
3033
- # @param [String] target_user Selected account username
3367
+ # @param [String] target_user Selected account username (>= 17.2.0)
3034
3368
  # @return [Comet::UserProfileConfig]
3035
3369
  def admin_get_user_profile(target_user)
3036
3370
  submit_params = {}
@@ -3054,8 +3388,9 @@ module Comet
3054
3388
  #
3055
3389
  # You must supply administrator authentication credentials to use this API.
3056
3390
  # This API requires the Auth Role to be enabled.
3391
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3057
3392
  #
3058
- # @param [String] target_user Selected account username
3393
+ # @param [String] target_user Selected account username (>= 17.2.0)
3059
3394
  # @return [Comet::GetProfileAndHashResponseMessage]
3060
3395
  def admin_get_user_profile_and_hash(target_user)
3061
3396
  submit_params = {}
@@ -3079,8 +3414,9 @@ module Comet
3079
3414
  #
3080
3415
  # You must supply administrator authentication credentials to use this API.
3081
3416
  # This API requires the Auth Role to be enabled.
3417
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3082
3418
  #
3083
- # @param [String] target_user Selected account username
3419
+ # @param [String] target_user Selected account username (>= 17.2.0)
3084
3420
  # @return [Comet::GetProfileHashResponseMessage]
3085
3421
  def admin_get_user_profile_hash(target_user)
3086
3422
  submit_params = {}
@@ -3103,6 +3439,7 @@ module Comet
3103
3439
  #
3104
3440
  # You must supply administrator authentication credentials to use this API.
3105
3441
  # This API requires the Auth Role to be enabled.
3442
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3106
3443
  #
3107
3444
  # @param [String] device_id The live connection Device GUID
3108
3445
  # @return [Comet::CometAPIResponseMessage]
@@ -3126,13 +3463,13 @@ module Comet
3126
3463
  #
3127
3464
  # You must supply administrator authentication credentials to use this API.
3128
3465
  # This API requires the Auth Role to be enabled.
3466
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3129
3467
  #
3130
3468
  # @param [String] device_id The live connection Device GUID
3131
3469
  # @param [String] target_user Selected account username
3132
3470
  # @param [String] target_password Selected account password
3133
- # @param [String] target_totpcode (Optional) Selected account TOTP code
3134
3471
  # @return [String]
3135
- def admin_installation_dispatch_register_device(device_id, target_user, target_password, target_totpcode = nil)
3472
+ def admin_installation_dispatch_register_device(device_id, target_user, target_password)
3136
3473
  submit_params = {}
3137
3474
  raise TypeError, "'device_id' expected String, got #{device_id.class}" unless device_id.is_a? String
3138
3475
 
@@ -3143,11 +3480,6 @@ module Comet
3143
3480
  raise TypeError, "'target_password' expected String, got #{target_password.class}" unless target_password.is_a? String
3144
3481
 
3145
3482
  submit_params['TargetPassword'] = target_password
3146
- unless target_totpcode.nil?
3147
- raise TypeError, "'target_totpcode' expected String, got #{target_totpcode.class}" unless target_totpcode.is_a? String
3148
-
3149
- submit_params['TargetTOTPCode'] = target_totpcode
3150
- end
3151
3483
 
3152
3484
  body = perform_request('api/v1/admin/installation/dispatch/register-device', submit_params)
3153
3485
  json_body = JSON.parse body
@@ -3164,6 +3496,7 @@ module Comet
3164
3496
  #
3165
3497
  # You must supply administrator authentication credentials to use this API.
3166
3498
  # This API requires the Auth Role to be enabled.
3499
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3167
3500
  #
3168
3501
  # @return [Hash{String => Comet::RegistrationLobbyConnection}]
3169
3502
  def admin_installation_list_active
@@ -3190,6 +3523,7 @@ module Comet
3190
3523
  #
3191
3524
  # You must supply administrator authentication credentials to use this API.
3192
3525
  # This API requires the Auth Role to be enabled.
3526
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3193
3527
  #
3194
3528
  # @param [String] target_user Username
3195
3529
  # @param [String] job_id Job ID
@@ -3220,6 +3554,7 @@ module Comet
3220
3554
  #
3221
3555
  # You must supply administrator authentication credentials to use this API.
3222
3556
  # This API requires the Auth Role to be enabled.
3557
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3223
3558
  #
3224
3559
  # @param [String] target_user Username
3225
3560
  # @param [String] job_id Job ID
@@ -3247,6 +3582,7 @@ module Comet
3247
3582
  #
3248
3583
  # You must supply administrator authentication credentials to use this API.
3249
3584
  # This API requires the Auth Role to be enabled.
3585
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3250
3586
  #
3251
3587
  # @return [Array<String>]
3252
3588
  def admin_list_users
@@ -3272,6 +3608,7 @@ module Comet
3272
3608
  #
3273
3609
  # You must supply administrator authentication credentials to use this API.
3274
3610
  # This API requires the Auth Role to be enabled.
3611
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3275
3612
  #
3276
3613
  # @return [Hash{String => Comet::UserProfileConfig}]
3277
3614
  def admin_list_users_full
@@ -3296,6 +3633,7 @@ module Comet
3296
3633
  #
3297
3634
  # You must supply administrator authentication credentials to use this API.
3298
3635
  # Access to this API may be prevented on a per-administrator basis.
3636
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3299
3637
  #
3300
3638
  # @return [Comet::ServerConfigOptionsBrandingFragment]
3301
3639
  def admin_meta_branding_config_get
@@ -3314,6 +3652,7 @@ module Comet
3314
3652
  #
3315
3653
  # You must supply administrator authentication credentials to use this API.
3316
3654
  # Access to this API may be prevented on a per-administrator basis.
3655
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3317
3656
  #
3318
3657
  # @param [Comet::BrandingOptions] branding_config Updated configuration content
3319
3658
  # @return [Comet::CometAPIResponseMessage]
@@ -3337,6 +3676,7 @@ module Comet
3337
3676
  #
3338
3677
  # You must supply administrator authentication credentials to use this API.
3339
3678
  # Access to this API may be prevented on a per-administrator basis.
3679
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3340
3680
  #
3341
3681
  # @return [Comet::ServerConfigOptionsSoftwareBuildRoleFragment]
3342
3682
  def admin_meta_build_config_get
@@ -3354,6 +3694,7 @@ module Comet
3354
3694
  #
3355
3695
  # You must supply administrator authentication credentials to use this API.
3356
3696
  # Access to this API may be prevented on a per-administrator basis.
3697
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3357
3698
  #
3358
3699
  # @param [Comet::SoftwareBuildRoleOptions] software_build_role_config Updated configuration content
3359
3700
  # @return [Comet::CometAPIResponseMessage]
@@ -3377,6 +3718,7 @@ module Comet
3377
3718
  #
3378
3719
  # You must supply administrator authentication credentials to use this API.
3379
3720
  # This API requires the Constellation Role to be enabled.
3721
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3380
3722
  #
3381
3723
  # @return [Comet::ConstellationRoleOptions]
3382
3724
  def admin_meta_constellation_config_get
@@ -3394,6 +3736,7 @@ module Comet
3394
3736
  #
3395
3737
  # You must supply administrator authentication credentials to use this API.
3396
3738
  # This API requires the Constellation Role to be enabled.
3739
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3397
3740
  #
3398
3741
  # @param [Comet::ConstellationRoleOptions] constellation_role_options Constellation role options to set
3399
3742
  # @return [Comet::CometAPIResponseMessage]
@@ -3417,6 +3760,7 @@ module Comet
3417
3760
  #
3418
3761
  # You must supply administrator authentication credentials to use this API.
3419
3762
  # Access to this API may be prevented on a per-administrator basis.
3763
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3420
3764
  #
3421
3765
  # @return [Comet::EmailOptions]
3422
3766
  def admin_meta_email_options_get
@@ -3428,12 +3772,46 @@ module Comet
3428
3772
  ret
3429
3773
  end
3430
3774
 
3775
+ # AdminMetaEmailOptionsOauthCallback
3776
+ #
3777
+ # Exchange an OAuth 2.0 authorization code for an encrypted SMTP refresh token.
3778
+ # The web interface calls this after the mailbox user grants consent. The response is the supplied SMTPOAuth with the refresh token added and secrets encrypted; store it in EmailOptions.SMTPOAuth and save it with the AdminMetaEmailOptionsSet API.
3779
+ #
3780
+ # You must supply administrator authentication credentials to use this API.
3781
+ # Access to this API may be prevented on a per-administrator basis.
3782
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3783
+ #
3784
+ # @param [Comet::SMTPOAuthOptions] smtpoauth The app registration that requested the authorization code. Flow must be SMTP_OAUTH_FLOW_AUTHORIZATION_CODE. The RefreshToken field is ignored. (>= 26.11.0)
3785
+ # @param [String] code The authorization code returned to the redirect URI (>= 26.11.0)
3786
+ # @param [String] redirect_uri The redirect URI used in the authorization request (>= 26.11.0)
3787
+ # @return [Comet::SMTPOAuthOptions]
3788
+ def admin_meta_email_options_oauth_callback(smtpoauth, code, redirect_uri)
3789
+ submit_params = {}
3790
+ raise TypeError, "'smtpoauth' expected Comet::SMTPOAuthOptions, got #{smtpoauth.class}" unless smtpoauth.is_a? Comet::SMTPOAuthOptions
3791
+
3792
+ submit_params['SMTPOAuth'] = smtpoauth.to_json
3793
+ raise TypeError, "'code' expected String, got #{code.class}" unless code.is_a? String
3794
+
3795
+ submit_params['Code'] = code
3796
+ raise TypeError, "'redirect_uri' expected String, got #{redirect_uri.class}" unless redirect_uri.is_a? String
3797
+
3798
+ submit_params['RedirectURI'] = redirect_uri
3799
+
3800
+ body = perform_request('api/v1/admin/meta/email-options/oauth-callback', submit_params)
3801
+ json_body = JSON.parse body
3802
+ check_status json_body
3803
+ ret = Comet::SMTPOAuthOptions.new
3804
+ ret.from_hash(json_body)
3805
+ ret
3806
+ end
3807
+
3431
3808
  # AdminMetaEmailOptionsSet
3432
3809
  #
3433
3810
  # Set the email options.
3434
3811
  #
3435
3812
  # You must supply administrator authentication credentials to use this API.
3436
3813
  # Access to this API may be prevented on a per-administrator basis.
3814
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3437
3815
  #
3438
3816
  # @param [Comet::EmailOptions] email_options The replacement email reporting options.
3439
3817
  # @return [Comet::CometAPIResponseMessage]
@@ -3457,6 +3835,7 @@ module Comet
3457
3835
  #
3458
3836
  # You must supply administrator authentication credentials to use this API.
3459
3837
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
3838
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3460
3839
  #
3461
3840
  # @return [Array<Number>]
3462
3841
  def admin_meta_list_available_log_days
@@ -3481,6 +3860,7 @@ module Comet
3481
3860
  # Get the server PSA configuration.
3482
3861
  #
3483
3862
  # You must supply administrator authentication credentials to use this API.
3863
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3484
3864
  #
3485
3865
  # @return [Array<Comet::PSAConfig>]
3486
3866
  def admin_meta_psa_config_list_get
@@ -3504,6 +3884,7 @@ module Comet
3504
3884
  # Update the server PSA configuration.
3505
3885
  #
3506
3886
  # You must supply administrator authentication credentials to use this API.
3887
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3507
3888
  #
3508
3889
  # @param [Array<Comet::PSAConfig>] psaconfig_list The replacement PSA configuration list
3509
3890
  # @return [Comet::CometAPIResponseMessage]
@@ -3528,6 +3909,7 @@ module Comet
3528
3909
  #
3529
3910
  # You must supply administrator authentication credentials to use this API.
3530
3911
  # This API requires the Auth Role to be enabled.
3912
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3531
3913
  #
3532
3914
  # @return [Comet::CometAPIResponseMessage]
3533
3915
  def admin_meta_psa_config_list_sync_now
@@ -3539,6 +3921,77 @@ module Comet
3539
3921
  ret
3540
3922
  end
3541
3923
 
3924
+ # AdminMetaPsaNinjaoneAuthCallback
3925
+ #
3926
+ # Exchange a NinjaOne OAuth authorization code for an encrypted refresh token.
3927
+ # The frontend should store the returned token on the NinjaOneConfig and persist it via the normal PSA config save flow.
3928
+ #
3929
+ # You must supply administrator authentication credentials to use this API.
3930
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3931
+ #
3932
+ # @param [String] code The authorization code from NinjaOne
3933
+ # @param [String] redirect_uri The callback URI used in the authorization request
3934
+ # @param [String] base_url The NinjaOne base URL
3935
+ # @param [String] client_id The OAuth Client ID
3936
+ # @param [String] client_secret The OAuth Client Secret
3937
+ # @return [Comet::NinjaOneAuthCallbackResponse]
3938
+ def admin_meta_psa_ninjaone_auth_callback(code, redirect_uri, base_url, client_id, client_secret)
3939
+ submit_params = {}
3940
+ raise TypeError, "'code' expected String, got #{code.class}" unless code.is_a? String
3941
+
3942
+ submit_params['Code'] = code
3943
+ raise TypeError, "'redirect_uri' expected String, got #{redirect_uri.class}" unless redirect_uri.is_a? String
3944
+
3945
+ submit_params['RedirectURI'] = redirect_uri
3946
+ raise TypeError, "'base_url' expected String, got #{base_url.class}" unless base_url.is_a? String
3947
+
3948
+ submit_params['BaseURL'] = base_url
3949
+ raise TypeError, "'client_id' expected String, got #{client_id.class}" unless client_id.is_a? String
3950
+
3951
+ submit_params['ClientID'] = client_id
3952
+ raise TypeError, "'client_secret' expected String, got #{client_secret.class}" unless client_secret.is_a? String
3953
+
3954
+ submit_params['ClientSecret'] = client_secret
3955
+
3956
+ body = perform_request('api/v1/admin/meta/psa/ninjaone/auth-callback', submit_params)
3957
+ json_body = JSON.parse body
3958
+ check_status json_body
3959
+ ret = Comet::NinjaOneAuthCallbackResponse.new
3960
+ ret.from_hash(json_body)
3961
+ ret
3962
+ end
3963
+
3964
+ # AdminMetaPsaNinjaoneOrganizations
3965
+ #
3966
+ # List NinjaOne organizations for a given PSA configuration.
3967
+ # Used to populate the NinjaOne Client ID dropdown in the admin UI.
3968
+ #
3969
+ # You must supply administrator authentication credentials to use this API.
3970
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3971
+ #
3972
+ # @param [Comet::PSAConfig] psaconfig The PSA configuration containing NinjaOne credentials
3973
+ # @return [Array<Comet::NinjaOneOrganization>]
3974
+ def admin_meta_psa_ninjaone_organizations(psaconfig)
3975
+ submit_params = {}
3976
+ raise TypeError, "'psaconfig' expected Comet::PSAConfig, got #{psaconfig.class}" unless psaconfig.is_a? Comet::PSAConfig
3977
+
3978
+ submit_params['PSAConfig'] = psaconfig.to_json
3979
+
3980
+ body = perform_request('api/v1/admin/meta/psa/ninjaone/organizations', submit_params)
3981
+ json_body = JSON.parse body
3982
+ check_status json_body
3983
+ if json_body.nil?
3984
+ ret = []
3985
+ else
3986
+ ret = Array.new(json_body.length)
3987
+ json_body.each_with_index do |v, i|
3988
+ ret[i] = Comet::NinjaOneOrganization.new
3989
+ ret[i].from_hash(v)
3990
+ end
3991
+ end
3992
+ ret
3993
+ end
3994
+
3542
3995
  # AdminMetaReadAllLogs
3543
3996
  #
3544
3997
  # Get a ZIP file of all of the server's log files.
@@ -3547,6 +4000,7 @@ module Comet
3547
4000
  #
3548
4001
  # You must supply administrator authentication credentials to use this API.
3549
4002
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4003
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3550
4004
  #
3551
4005
  # @return [String]
3552
4006
  def admin_meta_read_all_logs
@@ -3561,8 +4015,9 @@ module Comet
3561
4015
  #
3562
4016
  # You must supply administrator authentication credentials to use this API.
3563
4017
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4018
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3564
4019
  #
3565
- # @param [Number] log A log day, selected from the options returned by the Get Log Files API
4020
+ # @param [Number] log A log day, selected from the options returned by the Get Log Files API (>= 17.2.0)
3566
4021
  # @return [String]
3567
4022
  def admin_meta_read_logs(log)
3568
4023
  submit_params = {}
@@ -3581,6 +4036,7 @@ module Comet
3581
4036
  #
3582
4037
  # You must supply administrator authentication credentials to use this API.
3583
4038
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4039
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3584
4040
  #
3585
4041
  # @param [Array<Number>] logs An array of log days, selected from the options returned by the Get Log Files API
3586
4042
  # @return [String]
@@ -3599,6 +4055,7 @@ module Comet
3599
4055
  #
3600
4056
  # You must supply administrator authentication credentials to use this API.
3601
4057
  # Access to this API may be prevented on a per-administrator basis.
4058
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3602
4059
  #
3603
4060
  # @return [Array<Comet::RemoteStorageOption>]
3604
4061
  def admin_meta_remote_storage_vault_get
@@ -3623,9 +4080,10 @@ module Comet
3623
4080
  #
3624
4081
  # You must supply administrator authentication credentials to use this API.
3625
4082
  # Access to this API may be prevented on a per-administrator basis.
4083
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3626
4084
  #
3627
4085
  # @param [Array<Comet::RemoteStorageOption>] remote_storage_options Updated configuration content
3628
- # @param [String] replacement_auto_vault_id (Optional) Replacement Storage Template ID for auto Storage Vault configurations that use deleted Storage Templates
4086
+ # @param [String] replacement_auto_vault_id (Optional) Replacement Storage Template ID for auto Storage Vault configurations that use deleted Storage Templates (>= 24.12.0)
3629
4087
  # @return [Comet::CometAPIResponseMessage]
3630
4088
  def admin_meta_remote_storage_vault_set(remote_storage_options, replacement_auto_vault_id = nil)
3631
4089
  submit_params = {}
@@ -3652,6 +4110,7 @@ module Comet
3652
4110
  #
3653
4111
  # You must supply administrator authentication credentials to use this API.
3654
4112
  # Access to this API may be prevented on a per-administrator basis.
4113
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3655
4114
  #
3656
4115
  # @param [Comet::RemoteStorageOption] template_options Storage Template Vault Options
3657
4116
  # @return [Comet::CometAPIResponseMessage]
@@ -3675,6 +4134,7 @@ module Comet
3675
4134
  # Resources are used to upload files within the server configuration.
3676
4135
  #
3677
4136
  # You must supply administrator authentication credentials to use this API.
4137
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3678
4138
  #
3679
4139
  # @param [String] hash The resource identifier
3680
4140
  # @return [String]
@@ -3695,8 +4155,9 @@ module Comet
3695
4155
  # The lifespan of an uploaded resource is undefined. Resources may be deleted automatically, but it should remain available until the next call to AdminMetaServerConfigSet, and will remain available for as long as it is referenced by the server configuration.
3696
4156
  #
3697
4157
  # You must supply administrator authentication credentials to use this API.
4158
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3698
4159
  #
3699
- # @param [String] upload The uploaded file contents, as a multipart/form-data part.
4160
+ # @param [String] upload The uploaded file contents, as a multipart/form-data part. (>= 20.11.0)
3700
4161
  # @return [Comet::AdminResourceResponse]
3701
4162
  def admin_meta_resource_new(upload)
3702
4163
  submit_params = {}
@@ -3722,6 +4183,7 @@ module Comet
3722
4183
  # You must supply administrator authentication credentials to use this API.
3723
4184
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
3724
4185
  # Access to this API may be prevented on a per-administrator basis.
4186
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3725
4187
  #
3726
4188
  # @return [Comet::CometAPIResponseMessage]
3727
4189
  def admin_meta_restart_service
@@ -3740,6 +4202,7 @@ module Comet
3740
4202
  #
3741
4203
  # You must supply administrator authentication credentials to use this API.
3742
4204
  # Access to this API may be prevented on a per-administrator basis.
4205
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3743
4206
  #
3744
4207
  # @param [Comet::EmailOptions] email_options Updated configuration content
3745
4208
  # @param [String] recipient Target email address to send test email
@@ -3768,6 +4231,7 @@ module Comet
3768
4231
  #
3769
4232
  # You must supply administrator authentication credentials to use this API.
3770
4233
  # Access to this API may be prevented on a per-administrator basis.
4234
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3771
4235
  #
3772
4236
  # @param [Comet::EmailReportingOption] email_reporting_option Test email reporting option for sending
3773
4237
  # @param [String] target_organization (Optional) If present, Testing email with a target organization. Only allowed for top-level admins. (>= 24.3.0)
@@ -3797,6 +4261,7 @@ module Comet
3797
4261
  #
3798
4262
  # You must supply administrator authentication credentials to use this API.
3799
4263
  # Access to this API may be prevented on a per-administrator basis.
4264
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3800
4265
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
3801
4266
  #
3802
4267
  # @return [Comet::ServerConfigOptions]
@@ -3809,6 +4274,48 @@ module Comet
3809
4274
  ret
3810
4275
  end
3811
4276
 
4277
+ # AdminMetaServerConfigGetAndHash
4278
+ #
4279
+ # Get server configuration (atomic).
4280
+ # The resulting hash parameter can be passed to the AdminMetaServerConfigSet API, to atomically ensure that no changes occur between get/set operations.
4281
+ # The hash format is not publicly documented and may change in a future server version. Use server APIs to retrieve current hash values.
4282
+ #
4283
+ # You must supply administrator authentication credentials to use this API.
4284
+ # Access to this API may be prevented on a per-administrator basis.
4285
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4286
+ # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4287
+ #
4288
+ # @return [Comet::ServerConfigOptionsAndHashResponse]
4289
+ def admin_meta_server_config_get_and_hash
4290
+ body = perform_request('api/v1/admin/meta/server-config/get-and-hash')
4291
+ json_body = JSON.parse body
4292
+ check_status json_body
4293
+ ret = Comet::ServerConfigOptionsAndHashResponse.new
4294
+ ret.from_hash(json_body)
4295
+ ret
4296
+ end
4297
+
4298
+ # AdminMetaServerConfigGetHash
4299
+ #
4300
+ # Get server configuration (hash).
4301
+ # The hash can be used to determine if the server configuration has changed.
4302
+ # The hash format is not publicly documented and may change in a future server version. Use server APIs to retrieve current hash values.
4303
+ #
4304
+ # You must supply administrator authentication credentials to use this API.
4305
+ # Access to this API may be prevented on a per-administrator basis.
4306
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4307
+ # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4308
+ #
4309
+ # @return [Comet::ServerConfigOptionsHashResponse]
4310
+ def admin_meta_server_config_get_hash
4311
+ body = perform_request('api/v1/admin/meta/server-config/get-hash')
4312
+ json_body = JSON.parse body
4313
+ check_status json_body
4314
+ ret = Comet::ServerConfigOptionsHashResponse.new
4315
+ ret.from_hash(json_body)
4316
+ ret
4317
+ end
4318
+
3812
4319
  # AdminMetaServerConfigNetworkInterfaces
3813
4320
  #
3814
4321
  # List the available network interfaces on the PC running Comet Server.
@@ -3816,6 +4323,7 @@ module Comet
3816
4323
  #
3817
4324
  # You must supply administrator authentication credentials to use this API.
3818
4325
  # Access to this API may be prevented on a per-administrator basis.
4326
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3819
4327
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
3820
4328
  #
3821
4329
  # @return [Array<String>]
@@ -3845,15 +4353,22 @@ module Comet
3845
4353
  #
3846
4354
  # You must supply administrator authentication credentials to use this API.
3847
4355
  # Access to this API may be prevented on a per-administrator basis.
4356
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3848
4357
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
3849
4358
  #
3850
- # @param [Comet::ServerConfigOptions] config Updated configuration content
4359
+ # @param [Comet::ServerConfigOptions] config Updated configuration content (>= 17.3.8)
4360
+ # @param [String] require_hash (Optional) If present, the change is only applied if the server configuration is unchanged since this hash was retrieved from the AdminMetaServerConfigGetAndHash API. Otherwise, the change is rejected with status 409 and the server does not restart. (>= 26.10.2)
3851
4361
  # @return [Comet::CometAPIResponseMessage]
3852
- def admin_meta_server_config_set(config)
4362
+ def admin_meta_server_config_set(config, require_hash = nil)
3853
4363
  submit_params = {}
3854
4364
  raise TypeError, "'config' expected Comet::ServerConfigOptions, got #{config.class}" unless config.is_a? Comet::ServerConfigOptions
3855
4365
 
3856
4366
  submit_params['Config'] = config.to_json
4367
+ unless require_hash.nil?
4368
+ raise TypeError, "'require_hash' expected String, got #{require_hash.class}" unless require_hash.is_a? String
4369
+
4370
+ submit_params['RequireHash'] = require_hash
4371
+ end
3857
4372
 
3858
4373
  body = perform_request('api/v1/admin/meta/server-config/set', submit_params)
3859
4374
  json_body = JSON.parse body
@@ -3873,6 +4388,7 @@ module Comet
3873
4388
  # You must supply administrator authentication credentials to use this API.
3874
4389
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
3875
4390
  # Access to this API may be prevented on a per-administrator basis.
4391
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3876
4392
  #
3877
4393
  # @return [Comet::CometAPIResponseMessage]
3878
4394
  def admin_meta_shutdown_service
@@ -3889,6 +4405,7 @@ module Comet
3889
4405
  # Get software update news from the software provider.
3890
4406
  #
3891
4407
  # You must supply administrator authentication credentials to use this API.
4408
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3892
4409
  #
3893
4410
  # @return [Comet::SoftwareUpdateNewsResponse]
3894
4411
  def admin_meta_software_update_news
@@ -3906,8 +4423,9 @@ module Comet
3906
4423
  # The returned key-value map is not necessarily ordered. Client-side code should sort the result before display.
3907
4424
  #
3908
4425
  # You must supply administrator authentication credentials to use this API.
4426
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3909
4427
  #
3910
- # @param [Boolean] simple Remove redundant statistics
4428
+ # @param [Boolean] simple Remove redundant statistics (>= 18.9.1)
3911
4429
  # @return [Hash{Number => Comet::StatResult}]
3912
4430
  def admin_meta_stats(simple)
3913
4431
  submit_params = {}
@@ -3934,6 +4452,7 @@ module Comet
3934
4452
  # Retrieve the version number and basic properties about the server.
3935
4453
  #
3936
4454
  # You must supply administrator authentication credentials to use this API.
4455
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3937
4456
  #
3938
4457
  # @return [Comet::ServerMetaVersionInfo]
3939
4458
  def admin_meta_version
@@ -3951,6 +4470,7 @@ module Comet
3951
4470
  #
3952
4471
  # You must supply administrator authentication credentials to use this API.
3953
4472
  # Access to this API may be prevented on a per-administrator basis.
4473
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3954
4474
  #
3955
4475
  # @return [Hash{String => Comet::WebhookOption}]
3956
4476
  def admin_meta_webhook_options_get
@@ -3976,8 +4496,9 @@ module Comet
3976
4496
  #
3977
4497
  # You must supply administrator authentication credentials to use this API.
3978
4498
  # Access to this API may be prevented on a per-administrator basis.
4499
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
3979
4500
  #
3980
- # @param [Hash{String => Comet::WebhookOption}] webhook_options The replacement webhook target options.
4501
+ # @param [Hash{String => Comet::WebhookOption}] webhook_options The replacement webhook target options. (>= 20.6.8)
3981
4502
  # @return [Comet::CometAPIResponseMessage]
3982
4503
  def admin_meta_webhook_options_set(webhook_options)
3983
4504
  submit_params = {}
@@ -3999,6 +4520,7 @@ module Comet
3999
4520
  #
4000
4521
  # You must supply administrator authentication credentials to use this API.
4001
4522
  # This API requires the Auth Role to be enabled.
4523
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4002
4524
  #
4003
4525
  # @return [Hash{String => Comet::NewsEntry}]
4004
4526
  def admin_news_get_all
@@ -4023,8 +4545,9 @@ module Comet
4023
4545
  #
4024
4546
  # You must supply administrator authentication credentials to use this API.
4025
4547
  # This API requires the Auth Role to be enabled.
4548
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4026
4549
  #
4027
- # @param [String] news_item Selected news item GUID
4550
+ # @param [String] news_item Selected news item GUID (>= 17.2.0)
4028
4551
  # @return [Comet::CometAPIResponseMessage]
4029
4552
  def admin_news_remove(news_item)
4030
4553
  submit_params = {}
@@ -4046,8 +4569,9 @@ module Comet
4046
4569
  #
4047
4570
  # You must supply administrator authentication credentials to use this API.
4048
4571
  # This API requires the Auth Role to be enabled.
4572
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4049
4573
  #
4050
- # @param [String] news_content Content of news item
4574
+ # @param [String] news_content Content of news item (>= 17.2.0)
4051
4575
  # @return [Comet::CometAPIResponseMessage]
4052
4576
  def admin_news_submit(news_content)
4053
4577
  submit_params = {}
@@ -4063,6 +4587,64 @@ module Comet
4063
4587
  ret
4064
4588
  end
4065
4589
 
4590
+ # AdminOffice365ConvertLegacySelection
4591
+ #
4592
+ # Convert a legacy Office 365 Protected Item selection into an equivalent ordered rule list.
4593
+ # This is a pure computation with no device round-trip. The optional Accounts list is used only to enrich the generated rules' display metadata.
4594
+ #
4595
+ # You must supply administrator authentication credentials to use this API.
4596
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4597
+ #
4598
+ # @param [Comet::Office365CustomSettingV2] selection The legacy selection to convert
4599
+ # @param [Array<Comet::Office365MixedVirtualAccount>] accounts (Optional) The organization's account list, for display-name enrichment
4600
+ # @return [Comet::Office365ConvertSelectionResponse]
4601
+ def admin_office_365convert_legacy_selection(selection, accounts = nil)
4602
+ submit_params = {}
4603
+ raise TypeError, "'selection' expected Comet::Office365CustomSettingV2, got #{selection.class}" unless selection.is_a? Comet::Office365CustomSettingV2
4604
+
4605
+ submit_params['Selection'] = selection.to_json
4606
+ unless accounts.nil?
4607
+ raise TypeError, "'accounts' expected Array, got #{accounts.class}" unless accounts.is_a? Array
4608
+
4609
+ submit_params['Accounts'] = accounts.to_json
4610
+ end
4611
+
4612
+ body = perform_request('api/v1/admin/office365/convert-legacy-selection', submit_params)
4613
+ json_body = JSON.parse body
4614
+ check_status json_body
4615
+ ret = Comet::Office365ConvertSelectionResponse.new
4616
+ ret.from_hash(json_body)
4617
+ ret
4618
+ end
4619
+
4620
+ # AdminOffice365EvaluateSelectionRules
4621
+ #
4622
+ # Evaluate an ordered Office 365 rule list against an organization's accounts.
4623
+ # Returns the effective selection for every account, including per-service rule attribution. This is a pure computation with no device round-trip.
4624
+ #
4625
+ # You must supply administrator authentication credentials to use this API.
4626
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4627
+ #
4628
+ # @param [Array<Comet::Office365SelectionRule>] rules The ordered rule list to evaluate
4629
+ # @param [Array<Comet::Office365MixedVirtualAccount>] accounts The organization's account list
4630
+ # @return [Comet::Office365EvaluateSelectionRulesResponse]
4631
+ def admin_office_365evaluate_selection_rules(rules, accounts)
4632
+ submit_params = {}
4633
+ raise TypeError, "'rules' expected Array, got #{rules.class}" unless rules.is_a? Array
4634
+
4635
+ submit_params['Rules'] = rules.to_json
4636
+ raise TypeError, "'accounts' expected Array, got #{accounts.class}" unless accounts.is_a? Array
4637
+
4638
+ submit_params['Accounts'] = accounts.to_json
4639
+
4640
+ body = perform_request('api/v1/admin/office365/evaluate-selection-rules', submit_params)
4641
+ json_body = JSON.parse body
4642
+ check_status json_body
4643
+ ret = Comet::Office365EvaluateSelectionRulesResponse.new
4644
+ ret.from_hash(json_body)
4645
+ ret
4646
+ end
4647
+
4066
4648
  # AdminOrganizationDelete
4067
4649
  #
4068
4650
  # Delete an organization and all related users.
@@ -4071,6 +4653,7 @@ module Comet
4071
4653
  #
4072
4654
  # You must supply administrator authentication credentials to use this API.
4073
4655
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4656
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4074
4657
  #
4075
4658
  # @param [String] organization_id (Optional) (No description available)
4076
4659
  # @param [Comet::UninstallConfig] uninstall_config (Optional) Uninstall software configuration
@@ -4102,6 +4685,7 @@ module Comet
4102
4685
  #
4103
4686
  # You must supply administrator authentication credentials to use this API.
4104
4687
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4688
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4105
4689
  #
4106
4690
  # @param [Comet::SelfBackupExportOptions] options The export config options
4107
4691
  # @return [Comet::CometAPIResponseMessage]
@@ -4125,6 +4709,7 @@ module Comet
4125
4709
  #
4126
4710
  # You must supply administrator authentication credentials to use this API.
4127
4711
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4712
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4128
4713
  #
4129
4714
  # @return [Hash{String => Comet::Organization}]
4130
4715
  def admin_organization_list
@@ -4151,6 +4736,7 @@ module Comet
4151
4736
  #
4152
4737
  # You must supply administrator authentication credentials to use this API.
4153
4738
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4739
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4154
4740
  #
4155
4741
  # @param [String] organization_id (Optional) (No description available)
4156
4742
  # @param [Comet::Organization] organization (Optional) (No description available)
@@ -4182,6 +4768,7 @@ module Comet
4182
4768
  #
4183
4769
  # You must supply administrator authentication credentials to use this API.
4184
4770
  # This API requires the Auth Role to be enabled.
4771
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4185
4772
  #
4186
4773
  # @param [String] policy_id The policy ID to update or create
4187
4774
  # @return [Comet::CometAPIResponseMessage]
@@ -4206,6 +4793,7 @@ module Comet
4206
4793
  #
4207
4794
  # You must supply administrator authentication credentials to use this API.
4208
4795
  # This API requires the Auth Role to be enabled.
4796
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4209
4797
  #
4210
4798
  # @param [String] policy_id The policy ID to retrieve
4211
4799
  # @return [Comet::GetGroupPolicyResponse]
@@ -4230,8 +4818,9 @@ module Comet
4230
4818
  #
4231
4819
  # You must supply administrator authentication credentials to use this API.
4232
4820
  # This API requires the Auth Role to be enabled.
4821
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4233
4822
  #
4234
- # @param [String] target_organization (Optional) If present, list the policies belonging to another organization. Only allowed for administrator accounts in the top-level organization. (>= 22.3.7)
4823
+ # @param [String] target_organization (Optional) If present, list the policies belonging to another organization. Only allowed for administrator accounts in the top-level organization. (>= 22.5.0)
4235
4824
  # @return [Hash{String => String}]
4236
4825
  def admin_policies_list(target_organization = nil)
4237
4826
  submit_params = {}
@@ -4264,8 +4853,9 @@ module Comet
4264
4853
  #
4265
4854
  # You must supply administrator authentication credentials to use this API.
4266
4855
  # This API requires the Auth Role to be enabled.
4856
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4267
4857
  #
4268
- # @param [String] target_organization (Optional) If present, list the policies belonging to another organization. Only allowed for administrator accounts in the top-level organization. (>= 22.3.7)
4858
+ # @param [String] target_organization (Optional) If present, list the policies belonging to another organization. Only allowed for administrator accounts in the top-level organization. (>= 22.5.0)
4269
4859
  # @return [Hash{String => Comet::GroupPolicy}]
4270
4860
  def admin_policies_list_full(target_organization = nil)
4271
4861
  submit_params = {}
@@ -4296,6 +4886,7 @@ module Comet
4296
4886
  #
4297
4887
  # You must supply administrator authentication credentials to use this API.
4298
4888
  # This API requires the Auth Role to be enabled.
4889
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4299
4890
  #
4300
4891
  # @param [Comet::GroupPolicy] policy The policy data
4301
4892
  # @return [Comet::CreateGroupPolicyResponse]
@@ -4321,11 +4912,12 @@ module Comet
4321
4912
  #
4322
4913
  # You must supply administrator authentication credentials to use this API.
4323
4914
  # This API requires the Auth Role to be enabled.
4915
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4324
4916
  #
4325
4917
  # @param [String] policy_id The policy ID to update or create
4326
4918
  # @param [Comet::GroupPolicy] policy The policy data
4327
4919
  # @param [String] check_policy_hash (Optional) An atomic verification hash as supplied by the AdminPoliciesGet API
4328
- # @param [Comet::PolicyOptions] options (Optional) An array of PolicySourceID that will be explicitly deleted.
4920
+ # @param [Comet::PolicyOptions] options (Optional) An array of PolicySourceID that will be explicitly deleted. (>= 24.12.5)
4329
4921
  # @return [Comet::CometAPIResponseMessage]
4330
4922
  def admin_policies_set(policy_id, policy, check_policy_hash = nil, options = nil)
4331
4923
  submit_params = {}
@@ -4360,6 +4952,7 @@ module Comet
4360
4952
  #
4361
4953
  # You must supply administrator authentication credentials to use this API.
4362
4954
  # This API requires the Auth Role to be enabled.
4955
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4363
4956
  #
4364
4957
  # @param [String] target_user Selected account username
4365
4958
  # @param [Comet::EmailReportConfig] email_report_config Email report configuration to preview
@@ -4393,6 +4986,7 @@ module Comet
4393
4986
  #
4394
4987
  # You must supply administrator authentication credentials to use this API.
4395
4988
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4989
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4396
4990
  #
4397
4991
  # @return [Array<Comet::ReplicatorStateAPIResponse>]
4398
4992
  def admin_replication_state
@@ -4420,12 +5014,13 @@ module Comet
4420
5014
  #
4421
5015
  # You must supply administrator authentication credentials to use this API.
4422
5016
  # This API requires the Auth Role to be enabled.
5017
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4423
5018
  #
4424
5019
  # @param [String] target_user The user to receive the new Storage Vault
4425
5020
  # @param [String] storage_provider ID for the storage template destination
4426
5021
  # @param [String] self_address (Optional) The external URL for this server. Used to resolve conflicts
4427
- # @param [String] device_id (Optional) The ID of the device to be added as a associated device of the Storage Vault
4428
- # @param [String] profile_hash (Optional) The profile hash of the user profile
5022
+ # @param [String] device_id (Optional) The ID of the device to be added as a associated device of the Storage Vault (>= 24.12.0)
5023
+ # @param [String] profile_hash (Optional) The profile hash of the user profile (>= 25.3.2)
4429
5024
  # @return [Comet::RequestStorageVaultResponseMessage]
4430
5025
  def admin_request_storage_vault(target_user, storage_provider, self_address = nil, device_id = nil, profile_hash = nil)
4431
5026
  submit_params = {}
@@ -4467,8 +5062,9 @@ module Comet
4467
5062
  #
4468
5063
  # You must supply administrator authentication credentials to use this API.
4469
5064
  # This API requires the Auth Role to be enabled.
5065
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4470
5066
  #
4471
- # @param [String] target_organization (Optional) If present, list the storage template options belonging to another organization. Only allowed for administrator accounts in the top-level organization. (>= 22.3.7)
5067
+ # @param [String] target_organization (Optional) If present, list the storage template options belonging to another organization. Only allowed for administrator accounts in the top-level organization. (>= 22.5.0)
4472
5068
  # @return [Hash{String => String}]
4473
5069
  def admin_request_storage_vault_providers(target_organization = nil)
4474
5070
  submit_params = {}
@@ -4501,10 +5097,11 @@ module Comet
4501
5097
  #
4502
5098
  # You must supply administrator authentication credentials to use this API.
4503
5099
  # This API requires the Auth Role to be enabled.
5100
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4504
5101
  #
4505
5102
  # @param [String] target_user Selected account username
4506
5103
  # @param [String] new_password New account password
4507
- # @param [String] old_password (Optional) Old account password. Required if no recovery code is present for the user account.
5104
+ # @param [String] old_password (Optional) Old account password. Required if no recovery code is present for the user account. (>= 20.3.2)
4508
5105
  # @return [Comet::CometAPIResponseMessage]
4509
5106
  def admin_reset_user_password(target_user, new_password, old_password = nil)
4510
5107
  submit_params = {}
@@ -4535,6 +5132,7 @@ module Comet
4535
5132
  #
4536
5133
  # You must supply administrator authentication credentials to use this API.
4537
5134
  # This API requires the Auth Role to be enabled.
5135
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4538
5136
  #
4539
5137
  # @param [String] target_user Selected account username
4540
5138
  # @param [String] target_device Selected Device ID
@@ -4562,6 +5160,7 @@ module Comet
4562
5160
  #
4563
5161
  # You must supply administrator authentication credentials to use this API.
4564
5162
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
5163
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4565
5164
  #
4566
5165
  # @return [Comet::CometAPIResponseMessage]
4567
5166
  def admin_self_backup_start
@@ -4579,6 +5178,7 @@ module Comet
4579
5178
  #
4580
5179
  # You must supply administrator authentication credentials to use this API.
4581
5180
  # This API requires the Auth Role to be enabled.
5181
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4582
5182
  #
4583
5183
  # @param [String] target_user Selected account username
4584
5184
  # @param [String] source_id Selected Protected Item GUID
@@ -4624,11 +5224,13 @@ module Comet
4624
5224
  #
4625
5225
  # You must supply administrator authentication credentials to use this API.
4626
5226
  # This API requires the Auth Role to be enabled.
5227
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4627
5228
  #
4628
- # @param [String] target_user Selected account username
4629
- # @param [Comet::UserProfileConfig] profile_data Modified user profile
5229
+ # @param [String] target_user Selected account username (>= 17.2.0)
5230
+ # @param [Comet::UserProfileConfig] profile_data Modified user profile (>= 17.2.0)
5231
+ # @param [Comet::AdminOptions] admin_options (Optional) Instructions for modifying user profile (>= 24.12.5)
4630
5232
  # @return [Comet::CometAPIResponseMessage]
4631
- def admin_set_user_profile(target_user, profile_data)
5233
+ def admin_set_user_profile(target_user, profile_data, admin_options = nil)
4632
5234
  submit_params = {}
4633
5235
  raise TypeError, "'target_user' expected String, got #{target_user.class}" unless target_user.is_a? String
4634
5236
 
@@ -4636,6 +5238,11 @@ module Comet
4636
5238
  raise TypeError, "'profile_data' expected Comet::UserProfileConfig, got #{profile_data.class}" unless profile_data.is_a? Comet::UserProfileConfig
4637
5239
 
4638
5240
  submit_params['ProfileData'] = profile_data.to_json
5241
+ unless admin_options.nil?
5242
+ raise TypeError, "'admin_options' expected Comet::AdminOptions, got #{admin_options.class}" unless admin_options.is_a? Comet::AdminOptions
5243
+
5244
+ submit_params['AdminOptions'] = admin_options.to_json
5245
+ end
4639
5246
 
4640
5247
  body = perform_request('api/v1/admin/set-user-profile', submit_params)
4641
5248
  json_body = JSON.parse body
@@ -4653,11 +5260,12 @@ module Comet
4653
5260
  #
4654
5261
  # You must supply administrator authentication credentials to use this API.
4655
5262
  # This API requires the Auth Role to be enabled.
5263
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4656
5264
  #
4657
- # @param [String] target_user Selected account username
4658
- # @param [Comet::UserProfileConfig] profile_data Modified user profile
4659
- # @param [String] require_hash Previous hash parameter
4660
- # @param [Comet::AdminOptions] admin_options (Optional) Instructions for modifying user profile
5265
+ # @param [String] target_user Selected account username (>= 17.2.0)
5266
+ # @param [Comet::UserProfileConfig] profile_data Modified user profile (>= 17.2.0)
5267
+ # @param [String] require_hash Previous hash parameter (>= 17.2.0)
5268
+ # @param [Comet::AdminOptions] admin_options (Optional) Instructions for modifying user profile (>= 24.12.5)
4661
5269
  # @return [Comet::GetProfileAndHashResponseMessage]
4662
5270
  def admin_set_user_profile_hash(target_user, profile_data, require_hash, admin_options = nil)
4663
5271
  submit_params = {}
@@ -4690,6 +5298,7 @@ module Comet
4690
5298
  #
4691
5299
  # You must supply administrator authentication credentials to use this API.
4692
5300
  # This API requires the Auth Role to be enabled.
5301
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4693
5302
  #
4694
5303
  # @param [String] shared_storage_quota_id (No description available)
4695
5304
  # @return [Comet::CometAPIResponseMessage]
@@ -4713,6 +5322,7 @@ module Comet
4713
5322
  #
4714
5323
  # You must supply administrator authentication credentials to use this API.
4715
5324
  # This API requires the Auth Role to be enabled.
5325
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4716
5326
  #
4717
5327
  # @param [String] shared_storage_quota_id (No description available)
4718
5328
  # @return [Comet::GetSharedStorageQuotaResponse]
@@ -4736,6 +5346,7 @@ module Comet
4736
5346
  #
4737
5347
  # You must supply administrator authentication credentials to use this API.
4738
5348
  # This API requires the Auth Role to be enabled.
5349
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4739
5350
  #
4740
5351
  # @return [Comet::ListSharedStorageQuotaResponse]
4741
5352
  def admin_squota_list_all
@@ -4753,6 +5364,7 @@ module Comet
4753
5364
  #
4754
5365
  # You must supply administrator authentication credentials to use this API.
4755
5366
  # This API requires the Auth Role to be enabled.
5367
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4756
5368
  #
4757
5369
  # @param [String] shared_storage_quota_id (No description available)
4758
5370
  # @param [Comet::SharedStorageQuota] shared_storage_quota (No description available)
@@ -4787,6 +5399,7 @@ module Comet
4787
5399
  #
4788
5400
  # You must supply administrator authentication credentials to use this API.
4789
5401
  # This API requires the Storage Role to be enabled.
5402
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4790
5403
  #
4791
5404
  # @param [String] bucket_id Bucket ID
4792
5405
  # @param [Number] after_timestamp (Optional) Allow a stale size measurement if it is at least as new as the supplied Unix timestamp. Timestamps in the future may produce a result clamped down to the Comet Server's current time. If not present, the size measurement may be arbitrarily stale.
@@ -4817,8 +5430,9 @@ module Comet
4817
5430
  #
4818
5431
  # You must supply administrator authentication credentials to use this API.
4819
5432
  # This API requires the Storage Role to be enabled.
5433
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4820
5434
  #
4821
- # @param [String] bucket_id Selected bucket name
5435
+ # @param [String] bucket_id Selected bucket name (>= 17.2.0)
4822
5436
  # @return [Comet::CometAPIResponseMessage]
4823
5437
  def admin_storage_delete_bucket(bucket_id)
4824
5438
  submit_params = {}
@@ -4841,6 +5455,7 @@ module Comet
4841
5455
  # You must supply administrator authentication credentials to use this API.
4842
5456
  # Access to this API may be prevented on a per-administrator basis.
4843
5457
  # This API requires the Storage Role to be enabled.
5458
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4844
5459
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4845
5460
  #
4846
5461
  # @param [String] bucket_id (Optional) (This parameter is not used)
@@ -4867,6 +5482,7 @@ module Comet
4867
5482
  #
4868
5483
  # You must supply administrator authentication credentials to use this API.
4869
5484
  # This API requires the Storage Role to be enabled.
5485
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4870
5486
  #
4871
5487
  # @return [Hash{String => Comet::BucketProperties}]
4872
5488
  def admin_storage_list_buckets
@@ -4891,6 +5507,7 @@ module Comet
4891
5507
  #
4892
5508
  # You must supply administrator authentication credentials to use this API.
4893
5509
  # Access to this API may be prevented on a per-administrator basis.
5510
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4894
5511
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4895
5512
  #
4896
5513
  # @param [Comet::DestinationLocation] extra_data The destination location settings
@@ -4917,10 +5534,11 @@ module Comet
4917
5534
  #
4918
5535
  # You must supply administrator authentication credentials to use this API.
4919
5536
  # This API requires the Storage Role to be enabled.
5537
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4920
5538
  #
4921
- # @param [String] set_bucket_value (Optional) Bucket ID
4922
- # @param [String] set_key_hash_format (Optional) Bucket key hashing format
4923
- # @param [String] set_key_hash_value (Optional) Bucket key hash
5539
+ # @param [String] set_bucket_value (Optional) Bucket ID (>= 17.2.0)
5540
+ # @param [String] set_key_hash_format (Optional) Bucket key hashing format (>= 17.2.0)
5541
+ # @param [String] set_key_hash_value (Optional) Bucket key hash (>= 17.2.0)
4924
5542
  # @param [String] set_organization_id (Optional) Target organization ID (>= 20.9.0)
4925
5543
  # @return [Comet::AddBucketResponseMessage]
4926
5544
  def admin_storage_register_bucket(set_bucket_value = nil, set_key_hash_format = nil, set_key_hash_value = nil, set_organization_id = nil)
@@ -4954,6 +5572,32 @@ module Comet
4954
5572
  ret
4955
5573
  end
4956
5574
 
5575
+ # AdminStorageRotateBucketKey
5576
+ #
5577
+ # Issue a new key for an existing bucket, replacing the previous one.
5578
+ # The previous key stops working immediately. Any device or Storage Vault still using it loses access to the bucket until it is given the new key, so this can be used to cut off a backup job that is no longer supposed to be writing.
5579
+ # The new key is returned in the response message. It is not recoverable afterwards; if it is lost, issue another one.
5580
+ #
5581
+ # You must supply administrator authentication credentials to use this API.
5582
+ # This API requires the Storage Role to be enabled.
5583
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
5584
+ #
5585
+ # @param [String] bucket_id Selected bucket name
5586
+ # @return [Comet::AddBucketResponseMessage]
5587
+ def admin_storage_rotate_bucket_key(bucket_id)
5588
+ submit_params = {}
5589
+ raise TypeError, "'bucket_id' expected String, got #{bucket_id.class}" unless bucket_id.is_a? String
5590
+
5591
+ submit_params['BucketID'] = bucket_id
5592
+
5593
+ body = perform_request('api/v1/admin/storage/rotate-bucket-key', submit_params)
5594
+ json_body = JSON.parse body
5595
+ check_status json_body
5596
+ ret = Comet::AddBucketResponseMessage.new
5597
+ ret.from_hash(json_body)
5598
+ ret
5599
+ end
5600
+
4957
5601
  # AdminUpdateCampaignStart
4958
5602
  #
4959
5603
  # Start a new software update campaign.
@@ -4961,6 +5605,7 @@ module Comet
4961
5605
  # You must supply administrator authentication credentials to use this API.
4962
5606
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4963
5607
  # This API requires the Software Build Role to be enabled.
5608
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4964
5609
  # This API requires the Auth Role to be enabled.
4965
5610
  #
4966
5611
  # @param [Comet::UpdateCampaignOptions] options Configure targets for the software update campaign
@@ -4986,6 +5631,7 @@ module Comet
4986
5631
  # You must supply administrator authentication credentials to use this API.
4987
5632
  # This API is only available for top-level administrator accounts, not for Tenant administrator accounts.
4988
5633
  # This API requires the Software Build Role to be enabled.
5634
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
4989
5635
  # This API requires the Auth Role to be enabled.
4990
5636
  #
4991
5637
  # @return [Comet::UpdateCampaignStatus]
@@ -5004,6 +5650,7 @@ module Comet
5004
5650
  #
5005
5651
  # You must supply administrator authentication credentials to use this API.
5006
5652
  # This API requires the Auth Role to be enabled.
5653
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
5007
5654
  #
5008
5655
  # @param [String] group_id The user group ID to delete
5009
5656
  # @return [Comet::CometAPIResponseMessage]
@@ -5027,6 +5674,7 @@ module Comet
5027
5674
  #
5028
5675
  # You must supply administrator authentication credentials to use this API.
5029
5676
  # This API requires the Auth Role to be enabled.
5677
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
5030
5678
  #
5031
5679
  # @param [String] group_id The user group ID to retrieve
5032
5680
  # @param [Boolean] include_users (Optional) If present, includes the users array in the response.
@@ -5055,6 +5703,7 @@ module Comet
5055
5703
  #
5056
5704
  # You must supply administrator authentication credentials to use this API.
5057
5705
  # This API requires the Auth Role to be enabled.
5706
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
5058
5707
  #
5059
5708
  # @param [String] target_organization (Optional) If present, list the user groups belonging to another organization. Only allowed for administrator accounts in the top-level organization.
5060
5709
  # @return [Hash{String => String}]
@@ -5089,6 +5738,7 @@ module Comet
5089
5738
  #
5090
5739
  # You must supply administrator authentication credentials to use this API.
5091
5740
  # This API requires the Auth Role to be enabled.
5741
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
5092
5742
  #
5093
5743
  # @param [String] target_organization (Optional) If present, list the user groups belonging to the specified organization. Only allowed for administrator accounts in the top-level organization.
5094
5744
  # @return [Hash{String => Comet::UserGroup}]
@@ -5121,6 +5771,7 @@ module Comet
5121
5771
  #
5122
5772
  # You must supply administrator authentication credentials to use this API.
5123
5773
  # This API requires the Auth Role to be enabled.
5774
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
5124
5775
  #
5125
5776
  # @param [String] name this is the name of the group.
5126
5777
  # @param [String] target_organization (Optional) If present, list the policies belonging to another organization. Only allowed for administrator accounts in the top-level organization.
@@ -5150,6 +5801,7 @@ module Comet
5150
5801
  #
5151
5802
  # You must supply administrator authentication credentials to use this API.
5152
5803
  # This API requires the Auth Role to be enabled.
5804
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
5153
5805
  #
5154
5806
  # @param [String] group_id The user group ID to update or create
5155
5807
  # @param [Comet::UserGroup] group The user group data
@@ -5179,6 +5831,7 @@ module Comet
5179
5831
  #
5180
5832
  # You must supply administrator authentication credentials to use this API.
5181
5833
  # This API requires the Auth Role to be enabled.
5834
+ # This API accepts admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
5182
5835
  #
5183
5836
  # @param [String] group_id The user group ID to update
5184
5837
  # @param [Array<String>] users An array of usernames.
@@ -5206,6 +5859,8 @@ module Comet
5206
5859
  # This hybrid API allows you to log in to the Comet Server as either an administrator or end-user account.
5207
5860
  # This API behaves like either AdminAccountSessionStart or UserWebSessionStart, depending on what the supplied credentials were valid for.
5208
5861
  #
5862
+ # This API does not accept admin personal API token authentication (AuthType=Token, or the token supplied as the password with AuthType=Password).
5863
+ #
5209
5864
  # @return [Comet::SessionKeyRegeneratedResponse]
5210
5865
  def hybrid_session_start
5211
5866
  body = perform_request('api/v1/hybrid/session/start')
@@ -5258,7 +5913,7 @@ module Comet
5258
5913
  return unless obj.is_a? Hash
5259
5914
  return unless obj.key?('Status')
5260
5915
  return unless obj.key?('Message')
5261
- return unless obj['Status'] != 200 && obj['Status'] != 201
5916
+ return if (200..299).cover?(obj['Status'])
5262
5917
 
5263
5918
  ret_error = Comet::CometAPIResponseMessage.new
5264
5919
  ret_error.from_hash(obj)
@@ -5273,8 +5928,13 @@ module Comet
5273
5928
  def perform_request(endpoint, params = {})
5274
5929
  full_uri = URI(@server_address + endpoint)
5275
5930
  params['Username'] = @username
5276
- params['AuthType'] = 'Password'
5277
- params['Password'] = @password
5931
+ if @token.nil? || @token.empty?
5932
+ params['AuthType'] = 'Password'
5933
+ params['Password'] = @password
5934
+ else
5935
+ params['AuthType'] = 'Token'
5936
+ params['Token'] = @token
5937
+ end
5278
5938
 
5279
5939
  res = Net::HTTP.post_form(full_uri, params)
5280
5940
  unless res.is_a?(Net::HTTPSuccess)
@@ -5294,8 +5954,13 @@ module Comet
5294
5954
 
5295
5955
  req = Net::HTTP::Post.new(full_uri)
5296
5956
  req['X-Comet-Admin-Username'] = @username
5297
- req['X-Comet-Admin-AuthType'] = 'Password'
5298
- req['X-Comet-Admin-Password'] = @password
5957
+ if @token.nil? || @token.empty?
5958
+ req['X-Comet-Admin-AuthType'] = 'Password'
5959
+ req['X-Comet-Admin-Password'] = @password
5960
+ else
5961
+ req['X-Comet-Admin-AuthType'] = 'Token'
5962
+ req['X-Comet-Admin-Token'] = @token
5963
+ end
5299
5964
 
5300
5965
  form_params = []
5301
5966
  params.each do |k, v|
@@ -5304,6 +5969,7 @@ module Comet
5304
5969
  req.set_form(form_params, 'multipart/form-data')
5305
5970
 
5306
5971
  http = Net::HTTP.new(full_uri.hostname, full_uri.port)
5972
+ http.use_ssl = (full_uri.scheme == 'https')
5307
5973
  res = http.request(req)
5308
5974
 
5309
5975
  unless res.is_a?(Net::HTTPSuccess)