Class: SwaggerClient::UserApi
- Inherits:
-
Object
- Object
- SwaggerClient::UserApi
- Defined in:
- lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#add_user_asset_group(site_idte_id, asset_group_id, opts = {}) ⇒ Links
Asset Group Access Grants the user access to the asset group.
-
#add_user_asset_group_with_http_info(site_idte_id, asset_group_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Asset Group Access Grants the user access to the asset group.
-
#add_user_site(site_idte_id, site_id, opts = {}) ⇒ Links
Site Access Grants the user access to the site.
-
#add_user_site_with_http_info(site_idte_id, site_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Site Access Grants the user access to the site.
-
#create_user(opts = {}) ⇒ CreatedReferenceUserIDLink
Users Creates a new user.
-
#create_user_with_http_info(opts = {}) ⇒ Array<(CreatedReferenceUserIDLink, Integer, Hash)>
Users Creates a new user.
-
#delete_role(site_idte_id, opts = {}) ⇒ Links
Role Removes a role with the specified identifier.
-
#delete_role_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Role Removes a role with the specified identifier.
-
#delete_user(site_idte_id, opts = {}) ⇒ Links
User Deletes a user account.<span class="authorization">Global Administrator</span>.
-
#delete_user_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
User Deletes a user account.<span class="authorization">Global Administrator</span>.
-
#get_authentication_source(site_idte_id, opts = {}) ⇒ AuthenticationSource
Authentication Source Returns the details for an authentication source.
-
#get_authentication_source_users(site_idte_id, opts = {}) ⇒ ReferencesWithUserIDLink
Authentication Source Users Returns hypermedia links for the user accounts that use the authentication source to authenticate.
-
#get_authentication_source_users_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferencesWithUserIDLink, Integer, Hash)>
Authentication Source Users Returns hypermedia links for the user accounts that use the authentication source to authenticate.
-
#get_authentication_source_with_http_info(site_idte_id, opts = {}) ⇒ Array<(AuthenticationSource, Integer, Hash)>
Authentication Source Returns the details for an authentication source.
-
#get_authentication_sources(opts = {}) ⇒ ResourcesAuthenticationSource
Authentication Sources Returns all available sources of authentication for users.
-
#get_authentication_sources_with_http_info(opts = {}) ⇒ Array<(ResourcesAuthenticationSource, Integer, Hash)>
Authentication Sources Returns all available sources of authentication for users.
-
#get_privilege(site_idte_id, opts = {}) ⇒ Links
Privilege Returns the details for a privilege.
-
#get_privilege_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Privilege Returns the details for a privilege.
-
#get_privileges(opts = {}) ⇒ Privileges
Privileges Returns all privileges that may be granted to a role.
-
#get_privileges_with_http_info(opts = {}) ⇒ Array<(Privileges, Integer, Hash)>
Privileges Returns all privileges that may be granted to a role.
-
#get_role(site_idte_id, opts = {}) ⇒ Role
Role Retrieves the details of a role.
-
#get_role_users(site_idte_id, opts = {}) ⇒ ReferencesWithUserIDLink
Users With Role Returns hypermedia links for the the users currently assigned a role.
-
#get_role_users_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferencesWithUserIDLink, Integer, Hash)>
Users With Role Returns hypermedia links for the the users currently assigned a role.
-
#get_role_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Role, Integer, Hash)>
Role Retrieves the details of a role.
-
#get_roles(opts = {}) ⇒ ResourcesRole
Roles Returns all roles for which users may be assigned.
-
#get_roles_with_http_info(opts = {}) ⇒ Array<(ResourcesRole, Integer, Hash)>
Roles Returns all roles for which users may be assigned.
-
#get_two_factor_authentication_key(site_idte_id, opts = {}) ⇒ TokenResource
Two-Factor Authentication Retrieves the current authentication token seed (key) for the user, if configured.
-
#get_two_factor_authentication_key_with_http_info(site_idte_id, opts = {}) ⇒ Array<(TokenResource, Integer, Hash)>
Two-Factor Authentication Retrieves the current authentication token seed (key) for the user, if configured.
-
#get_user(site_idte_id, opts = {}) ⇒ User
User Returns the details for a user.<span class="authorization">Global Administrator, Current User</span>.
-
#get_user_asset_groups(site_idte_id, opts = {}) ⇒ ReferencesWithAssetGroupIDLink
Asset Groups Access Returns the asset groups to which the user has access.
-
#get_user_asset_groups_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferencesWithAssetGroupIDLink, Integer, Hash)>
Asset Groups Access Returns the asset groups to which the user has access.
-
#get_user_privileges(site_idte_id, opts = {}) ⇒ Privileges
User Privileges Returns the privileges granted to the user by their role.
-
#get_user_privileges_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Privileges, Integer, Hash)>
User Privileges Returns the privileges granted to the user by their role.
-
#get_user_sites(site_idte_id, opts = {}) ⇒ ReferencesWithSiteIDLink
Sites Access Returns the sites to which the user has access.
-
#get_user_sites_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferencesWithSiteIDLink, Integer, Hash)>
Sites Access Returns the sites to which the user has access.
-
#get_user_with_http_info(site_idte_id, opts = {}) ⇒ Array<(User, Integer, Hash)>
User Returns the details for a user.<span class="authorization">Global Administrator, Current User</span>.
-
#get_users(opts = {}) ⇒ PageOfUser
Users Returns all defined users.
-
#get_users_with_http_info(opts = {}) ⇒ Array<(PageOfUser, Integer, Hash)>
Users Returns all defined users.
-
#get_users_with_privilege(site_idte_id, opts = {}) ⇒ ReferencesWithUserIDLink
Users With Privilege Returns hypermedia links for all users granted the specified privilege by their role.
-
#get_users_with_privilege_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferencesWithUserIDLink, Integer, Hash)>
Users With Privilege Returns hypermedia links for all users granted the specified privilege by their role.
-
#initialize(api_client = ApiClient.default) ⇒ UserApi
constructor
A new instance of UserApi.
-
#regenerate_two_factor_authentication(site_idte_id, opts = {}) ⇒ TokenResource
Two-Factor Authentication Regenerates a new authentication token seed (key) and updates it for the user.
-
#regenerate_two_factor_authentication_with_http_info(site_idte_id, opts = {}) ⇒ Array<(TokenResource, Integer, Hash)>
Two-Factor Authentication Regenerates a new authentication token seed (key) and updates it for the user.
-
#remove_all_user_asset_groups(site_idte_id, opts = {}) ⇒ Links
Asset Groups Access Revokes access to all asset groups from the user.
-
#remove_all_user_asset_groups_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Asset Groups Access Revokes access to all asset groups from the user.
-
#remove_all_user_sites(site_idte_id, opts = {}) ⇒ Links
Sites Access Revokes access to all sites from the user.
-
#remove_all_user_sites_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Sites Access Revokes access to all sites from the user.
-
#remove_user_asset_group(site_idte_id, asset_group_id, opts = {}) ⇒ Links
Asset Group Access Grants the user access to the asset group.
-
#remove_user_asset_group_with_http_info(site_idte_id, asset_group_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Asset Group Access Grants the user access to the asset group.
-
#remove_user_site(site_idte_id, site_id, opts = {}) ⇒ Links
Site Access Grants the user access to the site.
-
#remove_user_site_with_http_info(site_idte_id, site_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Site Access Grants the user access to the site.
-
#reset_password(site_idte_id, opts = {}) ⇒ Links
Password Reset Changes the password for the user.
-
#reset_password_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Password Reset Changes the password for the user.
-
#set_two_factor_authentication(site_idte_id, opts = {}) ⇒ Links
Two-Factor Authentication Sets the authentication token seed (key) for the user.
-
#set_two_factor_authentication_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Two-Factor Authentication Sets the authentication token seed (key) for the user.
-
#set_user_asset_groups(site_idte_id, opts = {}) ⇒ Links
Asset Groups Access Updates the asset groups to which the user has access.
-
#set_user_asset_groups_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Asset Groups Access Updates the asset groups to which the user has access.
-
#set_user_sites(site_idte_id, opts = {}) ⇒ Links
Sites Access Updates the sites to which the user has access.
-
#set_user_sites_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Sites Access Updates the sites to which the user has access.
-
#unlock_user(site_idte_id, opts = {}) ⇒ Links
Unlock Account Unlocks a locked user account that has too many failed authentication attempts.
-
#unlock_user_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Unlock Account Unlocks a locked user account that has too many failed authentication attempts.
-
#update_role(site_idte_id, opts = {}) ⇒ Links
Role Updates the details of a role.
-
#update_role_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Role Updates the details of a role.
-
#update_user(site_idte_id, opts = {}) ⇒ Links
User Updates the details of a user.
-
#update_user_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
User Updates the details of a user.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ UserApi
Returns a new instance of UserApi.
16 17 18 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 16 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
14 15 16 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 14 def api_client @api_client end |
Instance Method Details
#add_user_asset_group(site_idte_id, asset_group_id, opts = {}) ⇒ Links
Asset Group Access Grants the user access to the asset group. Individual asset group access cannot be granted to users with the ‘allAssetGroups` permission. <span class="authorization">Global Administrator</span>
25 26 27 28 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 25 def add_user_asset_group(site_idte_id, asset_group_id, opts = {}) data, _status_code, _headers = add_user_asset_group_with_http_info(site_idte_id, asset_group_id, opts) data end |
#add_user_asset_group_with_http_info(site_idte_id, asset_group_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Asset Group Access Grants the user access to the asset group. Individual asset group access cannot be granted to users with the `allAssetGroups` permission. <span class="authorization">Global Administrator</span>
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 36 def add_user_asset_group_with_http_info(site_idte_id, asset_group_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.add_user_asset_group ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.add_user_asset_group" end # verify the required parameter 'asset_group_id' is set if @api_client.config.client_side_validation && asset_group_id.nil? fail ArgumentError, "Missing the required parameter 'asset_group_id' when calling UserApi.add_user_asset_group" end # resource path local_var_path = '/api/3/users/{id}/asset_groups/{assetGroupId}'.sub('{' + 'id' + '}', site_idte_id.to_s).sub('{' + 'assetGroupId' + '}', asset_group_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#add_user_asset_group\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#add_user_site(site_idte_id, site_id, opts = {}) ⇒ Links
Site Access Grants the user access to the site. Individual site access cannot be granted to users with the ‘allSites` permission. <span class="authorization">Global Administrator</span>
87 88 89 90 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 87 def add_user_site(site_idte_id, site_id, opts = {}) data, _status_code, _headers = add_user_site_with_http_info(site_idte_id, site_id, opts) data end |
#add_user_site_with_http_info(site_idte_id, site_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Site Access Grants the user access to the site. Individual site access cannot be granted to users with the `allSites` permission. <span class="authorization">Global Administrator</span>
98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 98 def add_user_site_with_http_info(site_idte_id, site_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.add_user_site ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.add_user_site" end # verify the required parameter 'site_id' is set if @api_client.config.client_side_validation && site_id.nil? fail ArgumentError, "Missing the required parameter 'site_id' when calling UserApi.add_user_site" end # resource path local_var_path = '/api/3/users/{id}/sites/{siteId}'.sub('{' + 'id' + '}', site_idte_id.to_s).sub('{' + 'siteId' + '}', site_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#add_user_site\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_user(opts = {}) ⇒ CreatedReferenceUserIDLink
Users Creates a new user. <span class="authorization">Global Administrator</span>
148 149 150 151 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 148 def create_user(opts = {}) data, _status_code, _headers = create_user_with_http_info(opts) data end |
#create_user_with_http_info(opts = {}) ⇒ Array<(CreatedReferenceUserIDLink, Integer, Hash)>
Users Creates a new user. <span class="authorization">Global Administrator</span>
158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 158 def create_user_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.create_user ...' end # resource path local_var_path = '/api/3/users' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body']) return_type = opts[:return_type] || 'CreatedReferenceUserIDLink' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#create_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_role(site_idte_id, opts = {}) ⇒ Links
Role Removes a role with the specified identifier. The role must not be built-in and cannot be currently assigned to any users.
202 203 204 205 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 202 def delete_role(site_idte_id, opts = {}) data, _status_code, _headers = delete_role_with_http_info(site_idte_id, opts) data end |
#delete_role_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Role Removes a role with the specified identifier. The role must not be built-in and cannot be currently assigned to any users.
212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 212 def delete_role_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.delete_role ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.delete_role" end # resource path local_var_path = '/api/3/roles/{id}'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#delete_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_user(site_idte_id, opts = {}) ⇒ Links
User Deletes a user account.<span class="authorization">Global Administrator</span>
258 259 260 261 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 258 def delete_user(site_idte_id, opts = {}) data, _status_code, _headers = delete_user_with_http_info(site_idte_id, opts) data end |
#delete_user_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
User Deletes a user account.<span class="authorization">Global Administrator</span>
268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 268 def delete_user_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.delete_user ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.delete_user" end # resource path local_var_path = '/api/3/users/{id}'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#delete_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_authentication_source(site_idte_id, opts = {}) ⇒ AuthenticationSource
Authentication Source Returns the details for an authentication source.
314 315 316 317 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 314 def get_authentication_source(site_idte_id, opts = {}) data, _status_code, _headers = get_authentication_source_with_http_info(site_idte_id, opts) data end |
#get_authentication_source_users(site_idte_id, opts = {}) ⇒ ReferencesWithUserIDLink
Authentication Source Users Returns hypermedia links for the user accounts that use the authentication source to authenticate.
370 371 372 373 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 370 def get_authentication_source_users(site_idte_id, opts = {}) data, _status_code, _headers = get_authentication_source_users_with_http_info(site_idte_id, opts) data end |
#get_authentication_source_users_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferencesWithUserIDLink, Integer, Hash)>
Authentication Source Users Returns hypermedia links for the user accounts that use the authentication source to authenticate.
380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 380 def get_authentication_source_users_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_authentication_source_users ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.get_authentication_source_users" end # resource path local_var_path = '/api/3/authentication_sources/{id}/users'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ReferencesWithUserIDLink' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_authentication_source_users\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_authentication_source_with_http_info(site_idte_id, opts = {}) ⇒ Array<(AuthenticationSource, Integer, Hash)>
Authentication Source Returns the details for an authentication source.
324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 324 def get_authentication_source_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_authentication_source ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.get_authentication_source" end # resource path local_var_path = '/api/3/authentication_sources/{id}'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'AuthenticationSource' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_authentication_source\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_authentication_sources(opts = {}) ⇒ ResourcesAuthenticationSource
Authentication Sources Returns all available sources of authentication for users.
425 426 427 428 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 425 def get_authentication_sources(opts = {}) data, _status_code, _headers = get_authentication_sources_with_http_info(opts) data end |
#get_authentication_sources_with_http_info(opts = {}) ⇒ Array<(ResourcesAuthenticationSource, Integer, Hash)>
Authentication Sources Returns all available sources of authentication for users.
434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 434 def get_authentication_sources_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_authentication_sources ...' end # resource path local_var_path = '/api/3/authentication_sources' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ResourcesAuthenticationSource' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_authentication_sources\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_privilege(site_idte_id, opts = {}) ⇒ Links
Privilege Returns the details for a privilege.
476 477 478 479 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 476 def get_privilege(site_idte_id, opts = {}) data, _status_code, _headers = get_privilege_with_http_info(site_idte_id, opts) data end |
#get_privilege_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Privilege Returns the details for a privilege.
486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 486 def get_privilege_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_privilege ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.get_privilege" end # verify enum value if @api_client.config.client_side_validation && !['all-permissions', 'create-reports', 'configure-global-settings', 'manage-sites', 'manage-tags', 'manage-static-asset-groups', 'manage-dynamic-asset-groups', 'manage-scan-templates', 'manage-report-templates', 'manage-scan-engines', 'submit-vulnerability-exceptions', 'approve-vulnerability-exceptions', 'delete-vulnerability-exceptions', 'manage-vuln-investigations', 'view-vuln-investigations', 'create-tickets', 'close-tickets', 'assign-ticket-assignee', 'manage-site-access', 'manage-asset-group-access', 'manage-report-access', 'use-restricted-report-sections', 'manage-policies', 'manage-advpolicies', 'view-asset-group-asset-data', 'manage-asset-group-assets', 'view-site-asset-data', 'specify-site-metadata', 'purge-site-asset-data', 'specify-scan-targets', 'assign-scan-engine', 'assign-scan-template', 'manage-site-credentials', 'manage-scan-alerts', 'schedule-automatic-scans', 'start-unscheduled-scans'].include?(site_idte_id) fail ArgumentError, "invalid value for 'id', must be one of all-permissions, create-reports, configure-global-settings, manage-sites, manage-tags, manage-static-asset-groups, manage-dynamic-asset-groups, manage-scan-templates, manage-report-templates, manage-scan-engines, submit-vulnerability-exceptions, approve-vulnerability-exceptions, delete-vulnerability-exceptions, manage-vuln-investigations, view-vuln-investigations, create-tickets, close-tickets, assign-ticket-assignee, manage-site-access, manage-asset-group-access, manage-report-access, use-restricted-report-sections, manage-policies, manage-advpolicies, view-asset-group-asset-data, manage-asset-group-assets, view-site-asset-data, specify-site-metadata, purge-site-asset-data, specify-scan-targets, assign-scan-engine, assign-scan-template, manage-site-credentials, manage-scan-alerts, schedule-automatic-scans, start-unscheduled-scans" end # resource path local_var_path = '/api/3/privileges/{id}'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_privilege\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_privileges(opts = {}) ⇒ Privileges
Privileges Returns all privileges that may be granted to a role.
535 536 537 538 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 535 def get_privileges(opts = {}) data, _status_code, _headers = get_privileges_with_http_info(opts) data end |
#get_privileges_with_http_info(opts = {}) ⇒ Array<(Privileges, Integer, Hash)>
Privileges Returns all privileges that may be granted to a role.
544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 544 def get_privileges_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_privileges ...' end # resource path local_var_path = '/api/3/privileges' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Privileges' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_privileges\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_role(site_idte_id, opts = {}) ⇒ Role
Role Retrieves the details of a role.
586 587 588 589 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 586 def get_role(site_idte_id, opts = {}) data, _status_code, _headers = get_role_with_http_info(site_idte_id, opts) data end |
#get_role_users(site_idte_id, opts = {}) ⇒ ReferencesWithUserIDLink
Users With Role Returns hypermedia links for the the users currently assigned a role.
642 643 644 645 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 642 def get_role_users(site_idte_id, opts = {}) data, _status_code, _headers = get_role_users_with_http_info(site_idte_id, opts) data end |
#get_role_users_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferencesWithUserIDLink, Integer, Hash)>
Users With Role Returns hypermedia links for the the users currently assigned a role.
652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 652 def get_role_users_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_role_users ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.get_role_users" end # resource path local_var_path = '/api/3/roles/{id}/users'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ReferencesWithUserIDLink' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_role_users\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_role_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Role, Integer, Hash)>
Role Retrieves the details of a role.
596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 596 def get_role_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_role ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.get_role" end # resource path local_var_path = '/api/3/roles/{id}'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Role' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_roles(opts = {}) ⇒ ResourcesRole
Roles Returns all roles for which users may be assigned.
697 698 699 700 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 697 def get_roles(opts = {}) data, _status_code, _headers = get_roles_with_http_info(opts) data end |
#get_roles_with_http_info(opts = {}) ⇒ Array<(ResourcesRole, Integer, Hash)>
Roles Returns all roles for which users may be assigned.
706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 706 def get_roles_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_roles ...' end # resource path local_var_path = '/api/3/roles' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ResourcesRole' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_roles\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_two_factor_authentication_key(site_idte_id, opts = {}) ⇒ TokenResource
Two-Factor Authentication Retrieves the current authentication token seed (key) for the user, if configured.
748 749 750 751 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 748 def get_two_factor_authentication_key(site_idte_id, opts = {}) data, _status_code, _headers = get_two_factor_authentication_key_with_http_info(site_idte_id, opts) data end |
#get_two_factor_authentication_key_with_http_info(site_idte_id, opts = {}) ⇒ Array<(TokenResource, Integer, Hash)>
Two-Factor Authentication Retrieves the current authentication token seed (key) for the user, if configured.
758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 758 def get_two_factor_authentication_key_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_two_factor_authentication_key ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.get_two_factor_authentication_key" end # resource path local_var_path = '/api/3/users/{id}/2FA'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'TokenResource' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_two_factor_authentication_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_user(site_idte_id, opts = {}) ⇒ User
User Returns the details for a user.<span class="authorization">Global Administrator, Current User</span>
804 805 806 807 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 804 def get_user(site_idte_id, opts = {}) data, _status_code, _headers = get_user_with_http_info(site_idte_id, opts) data end |
#get_user_asset_groups(site_idte_id, opts = {}) ⇒ ReferencesWithAssetGroupIDLink
Asset Groups Access Returns the asset groups to which the user has access.
860 861 862 863 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 860 def get_user_asset_groups(site_idte_id, opts = {}) data, _status_code, _headers = get_user_asset_groups_with_http_info(site_idte_id, opts) data end |
#get_user_asset_groups_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferencesWithAssetGroupIDLink, Integer, Hash)>
Asset Groups Access Returns the asset groups to which the user has access.
870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 870 def get_user_asset_groups_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_user_asset_groups ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.get_user_asset_groups" end # resource path local_var_path = '/api/3/users/{id}/asset_groups'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ReferencesWithAssetGroupIDLink' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_user_asset_groups\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_user_privileges(site_idte_id, opts = {}) ⇒ Privileges
User Privileges Returns the privileges granted to the user by their role. <span class="authorization">Global Administrator</span>
916 917 918 919 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 916 def get_user_privileges(site_idte_id, opts = {}) data, _status_code, _headers = get_user_privileges_with_http_info(site_idte_id, opts) data end |
#get_user_privileges_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Privileges, Integer, Hash)>
User Privileges Returns the privileges granted to the user by their role. <span class="authorization">Global Administrator</span>
926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 926 def get_user_privileges_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_user_privileges ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.get_user_privileges" end # resource path local_var_path = '/api/3/users/{id}/privileges'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Privileges' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_user_privileges\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_user_sites(site_idte_id, opts = {}) ⇒ ReferencesWithSiteIDLink
Sites Access Returns the sites to which the user has access.
972 973 974 975 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 972 def get_user_sites(site_idte_id, opts = {}) data, _status_code, _headers = get_user_sites_with_http_info(site_idte_id, opts) data end |
#get_user_sites_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferencesWithSiteIDLink, Integer, Hash)>
Sites Access Returns the sites to which the user has access.
982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 982 def get_user_sites_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_user_sites ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.get_user_sites" end # resource path local_var_path = '/api/3/users/{id}/sites'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ReferencesWithSiteIDLink' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_user_sites\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_user_with_http_info(site_idte_id, opts = {}) ⇒ Array<(User, Integer, Hash)>
User Returns the details for a user.<span class="authorization">Global Administrator, Current User</span>
814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 814 def get_user_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_user ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.get_user" end # resource path local_var_path = '/api/3/users/{id}'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'User' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_users(opts = {}) ⇒ PageOfUser
Users Returns all defined users. <span class="authorization">Global Administrator</span>
1030 1031 1032 1033 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1030 def get_users(opts = {}) data, _status_code, _headers = get_users_with_http_info(opts) data end |
#get_users_with_http_info(opts = {}) ⇒ Array<(PageOfUser, Integer, Hash)>
Users Returns all defined users. <span class="authorization">Global Administrator</span>
1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1042 def get_users_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_users ...' end # resource path local_var_path = '/api/3/users' # query parameters query_params = opts[:query_params] || {} query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil? query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil? query_params[:'sort'] = @api_client.build_collection_param(opts[:'sort'], :multi) if !opts[:'sort'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'PageOfUser' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_users\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_users_with_privilege(site_idte_id, opts = {}) ⇒ ReferencesWithUserIDLink
Users With Privilege Returns hypermedia links for all users granted the specified privilege by their role.
1087 1088 1089 1090 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1087 def get_users_with_privilege(site_idte_id, opts = {}) data, _status_code, _headers = get_users_with_privilege_with_http_info(site_idte_id, opts) data end |
#get_users_with_privilege_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferencesWithUserIDLink, Integer, Hash)>
Users With Privilege Returns hypermedia links for all users granted the specified privilege by their role.
1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1097 def get_users_with_privilege_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.get_users_with_privilege ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.get_users_with_privilege" end # verify enum value if @api_client.config.client_side_validation && !['all-permissions', 'create-reports', 'configure-global-settings', 'manage-sites', 'manage-tags', 'manage-static-asset-groups', 'manage-dynamic-asset-groups', 'manage-scan-templates', 'manage-report-templates', 'manage-scan-engines', 'submit-vulnerability-exceptions', 'approve-vulnerability-exceptions', 'delete-vulnerability-exceptions', 'manage-vuln-investigations', 'view-vuln-investigations', 'create-tickets', 'close-tickets', 'assign-ticket-assignee', 'manage-site-access', 'manage-asset-group-access', 'manage-report-access', 'use-restricted-report-sections', 'manage-policies', 'manage-advpolicies', 'view-asset-group-asset-data', 'manage-asset-group-assets', 'view-site-asset-data', 'specify-site-metadata', 'purge-site-asset-data', 'specify-scan-targets', 'assign-scan-engine', 'assign-scan-template', 'manage-site-credentials', 'manage-scan-alerts', 'schedule-automatic-scans', 'start-unscheduled-scans'].include?(site_idte_id) fail ArgumentError, "invalid value for 'id', must be one of all-permissions, create-reports, configure-global-settings, manage-sites, manage-tags, manage-static-asset-groups, manage-dynamic-asset-groups, manage-scan-templates, manage-report-templates, manage-scan-engines, submit-vulnerability-exceptions, approve-vulnerability-exceptions, delete-vulnerability-exceptions, manage-vuln-investigations, view-vuln-investigations, create-tickets, close-tickets, assign-ticket-assignee, manage-site-access, manage-asset-group-access, manage-report-access, use-restricted-report-sections, manage-policies, manage-advpolicies, view-asset-group-asset-data, manage-asset-group-assets, view-site-asset-data, specify-site-metadata, purge-site-asset-data, specify-scan-targets, assign-scan-engine, assign-scan-template, manage-site-credentials, manage-scan-alerts, schedule-automatic-scans, start-unscheduled-scans" end # resource path local_var_path = '/api/3/privileges/{id}/users'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ReferencesWithUserIDLink' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#get_users_with_privilege\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#regenerate_two_factor_authentication(site_idte_id, opts = {}) ⇒ TokenResource
Two-Factor Authentication Regenerates a new authentication token seed (key) and updates it for the user. This key may be then be used in the appropriate 2FA authenticator.
1147 1148 1149 1150 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1147 def regenerate_two_factor_authentication(site_idte_id, opts = {}) data, _status_code, _headers = regenerate_two_factor_authentication_with_http_info(site_idte_id, opts) data end |
#regenerate_two_factor_authentication_with_http_info(site_idte_id, opts = {}) ⇒ Array<(TokenResource, Integer, Hash)>
Two-Factor Authentication Regenerates a new authentication token seed (key) and updates it for the user. This key may be then be used in the appropriate 2FA authenticator.
1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1157 def regenerate_two_factor_authentication_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.regenerate_two_factor_authentication ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.regenerate_two_factor_authentication" end # resource path local_var_path = '/api/3/users/{id}/2FA'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'TokenResource' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#regenerate_two_factor_authentication\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#remove_all_user_asset_groups(site_idte_id, opts = {}) ⇒ Links
Asset Groups Access Revokes access to all asset groups from the user.
1203 1204 1205 1206 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1203 def remove_all_user_asset_groups(site_idte_id, opts = {}) data, _status_code, _headers = remove_all_user_asset_groups_with_http_info(site_idte_id, opts) data end |
#remove_all_user_asset_groups_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Asset Groups Access Revokes access to all asset groups from the user.
1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1213 def remove_all_user_asset_groups_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.remove_all_user_asset_groups ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.remove_all_user_asset_groups" end # resource path local_var_path = '/api/3/users/{id}/asset_groups'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#remove_all_user_asset_groups\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#remove_all_user_sites(site_idte_id, opts = {}) ⇒ Links
Sites Access Revokes access to all sites from the user.
1259 1260 1261 1262 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1259 def remove_all_user_sites(site_idte_id, opts = {}) data, _status_code, _headers = remove_all_user_sites_with_http_info(site_idte_id, opts) data end |
#remove_all_user_sites_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Sites Access Revokes access to all sites from the user.
1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1269 def remove_all_user_sites_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.remove_all_user_sites ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.remove_all_user_sites" end # resource path local_var_path = '/api/3/users/{id}/sites'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#remove_all_user_sites\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#remove_user_asset_group(site_idte_id, asset_group_id, opts = {}) ⇒ Links
Asset Group Access Grants the user access to the asset group. Individual asset group access cannot be granted to users with the ‘allAssetGroups` permission. <span class="authorization">Global Administrator</span>
1316 1317 1318 1319 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1316 def remove_user_asset_group(site_idte_id, asset_group_id, opts = {}) data, _status_code, _headers = remove_user_asset_group_with_http_info(site_idte_id, asset_group_id, opts) data end |
#remove_user_asset_group_with_http_info(site_idte_id, asset_group_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Asset Group Access Grants the user access to the asset group. Individual asset group access cannot be granted to users with the `allAssetGroups` permission. <span class="authorization">Global Administrator</span>
1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1327 def remove_user_asset_group_with_http_info(site_idte_id, asset_group_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.remove_user_asset_group ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.remove_user_asset_group" end # verify the required parameter 'asset_group_id' is set if @api_client.config.client_side_validation && asset_group_id.nil? fail ArgumentError, "Missing the required parameter 'asset_group_id' when calling UserApi.remove_user_asset_group" end # resource path local_var_path = '/api/3/users/{id}/asset_groups/{assetGroupId}'.sub('{' + 'id' + '}', site_idte_id.to_s).sub('{' + 'assetGroupId' + '}', asset_group_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#remove_user_asset_group\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#remove_user_site(site_idte_id, site_id, opts = {}) ⇒ Links
Site Access Grants the user access to the site. Individual site access cannot be granted to users with the ‘allSites` permission. <span class="authorization">Global Administrator</span>
1378 1379 1380 1381 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1378 def remove_user_site(site_idte_id, site_id, opts = {}) data, _status_code, _headers = remove_user_site_with_http_info(site_idte_id, site_id, opts) data end |
#remove_user_site_with_http_info(site_idte_id, site_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Site Access Grants the user access to the site. Individual site access cannot be granted to users with the `allSites` permission. <span class="authorization">Global Administrator</span>
1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1389 def remove_user_site_with_http_info(site_idte_id, site_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.remove_user_site ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.remove_user_site" end # verify the required parameter 'site_id' is set if @api_client.config.client_side_validation && site_id.nil? fail ArgumentError, "Missing the required parameter 'site_id' when calling UserApi.remove_user_site" end # resource path local_var_path = '/api/3/users/{id}/sites/{siteId}'.sub('{' + 'id' + '}', site_idte_id.to_s).sub('{' + 'siteId' + '}', site_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#remove_user_site\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#reset_password(site_idte_id, opts = {}) ⇒ Links
Password Reset Changes the password for the user. Users may only change their own password.
1440 1441 1442 1443 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1440 def reset_password(site_idte_id, opts = {}) data, _status_code, _headers = reset_password_with_http_info(site_idte_id, opts) data end |
#reset_password_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Password Reset Changes the password for the user. Users may only change their own password.
1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1451 def reset_password_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.reset_password ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.reset_password" end # resource path local_var_path = '/api/3/users/{id}/password'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body']) return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#reset_password\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#set_two_factor_authentication(site_idte_id, opts = {}) ⇒ Links
Two-Factor Authentication Sets the authentication token seed (key) for the user. This key may be then be used in the appropriate 2FA authenticator.
1500 1501 1502 1503 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1500 def set_two_factor_authentication(site_idte_id, opts = {}) data, _status_code, _headers = set_two_factor_authentication_with_http_info(site_idte_id, opts) data end |
#set_two_factor_authentication_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Two-Factor Authentication Sets the authentication token seed (key) for the user. This key may be then be used in the appropriate 2FA authenticator.
1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1511 def set_two_factor_authentication_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.set_two_factor_authentication ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.set_two_factor_authentication" end # resource path local_var_path = '/api/3/users/{id}/2FA'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body']) return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#set_two_factor_authentication\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#set_user_asset_groups(site_idte_id, opts = {}) ⇒ Links
Asset Groups Access Updates the asset groups to which the user has access. Individual asset group access cannot be granted to users with the ‘allAssetGroups` permission. <span class="authorization">Global Administrator</span>
1560 1561 1562 1563 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1560 def set_user_asset_groups(site_idte_id, opts = {}) data, _status_code, _headers = set_user_asset_groups_with_http_info(site_idte_id, opts) data end |
#set_user_asset_groups_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Asset Groups Access Updates the asset groups to which the user has access. Individual asset group access cannot be granted to users with the `allAssetGroups` permission. <span class="authorization">Global Administrator</span>
1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1571 def set_user_asset_groups_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.set_user_asset_groups ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.set_user_asset_groups" end # resource path local_var_path = '/api/3/users/{id}/asset_groups'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body']) return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#set_user_asset_groups\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#set_user_sites(site_idte_id, opts = {}) ⇒ Links
Sites Access Updates the sites to which the user has access. Individual site access cannot be granted to users with the ‘allSites` permission. <span class="authorization">Global Administrator</span>
1620 1621 1622 1623 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1620 def set_user_sites(site_idte_id, opts = {}) data, _status_code, _headers = set_user_sites_with_http_info(site_idte_id, opts) data end |
#set_user_sites_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Sites Access Updates the sites to which the user has access. Individual site access cannot be granted to users with the `allSites` permission. <span class="authorization">Global Administrator</span>
1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1631 def set_user_sites_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.set_user_sites ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.set_user_sites" end # resource path local_var_path = '/api/3/users/{id}/sites'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body']) return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#set_user_sites\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#unlock_user(site_idte_id, opts = {}) ⇒ Links
Unlock Account Unlocks a locked user account that has too many failed authentication attempts. Disabled accounts may not be unlocked.
1679 1680 1681 1682 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1679 def unlock_user(site_idte_id, opts = {}) data, _status_code, _headers = unlock_user_with_http_info(site_idte_id, opts) data end |
#unlock_user_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Unlock Account Unlocks a locked user account that has too many failed authentication attempts. Disabled accounts may not be unlocked.
1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1689 def unlock_user_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.unlock_user ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.unlock_user" end # resource path local_var_path = '/api/3/users/{id}/lock'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#unlock_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_role(site_idte_id, opts = {}) ⇒ Links
Role Updates the details of a role.
1736 1737 1738 1739 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1736 def update_role(site_idte_id, opts = {}) data, _status_code, _headers = update_role_with_http_info(site_idte_id, opts) data end |
#update_role_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Role Updates the details of a role.
1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1747 def update_role_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.update_role ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.update_role" end # resource path local_var_path = '/api/3/roles/{id}'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body']) return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#update_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_user(site_idte_id, opts = {}) ⇒ Links
User Updates the details of a user. <span class="authorization">Global Administrator</span>
1796 1797 1798 1799 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1796 def update_user(site_idte_id, opts = {}) data, _status_code, _headers = update_user_with_http_info(site_idte_id, opts) data end |
#update_user_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
User Updates the details of a user. <span class="authorization">Global Administrator</span>
1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/user_api.rb', line 1807 def update_user_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserApi.update_user ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling UserApi.update_user" end # resource path local_var_path = '/api/3/users/{id}'.sub('{' + 'id' + '}', site_idte_id.to_s) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body']) return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserApi#update_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |