Class: MailSlurpClient::UserControllerApi
- Inherits:
-
Object
- Object
- MailSlurpClient::UserControllerApi
- Defined in:
- lib/mailslurp_client/api/user_controller_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#create_or_update_inbox_retention_policy_for_account(create_inbox_retention_policy_for_account_options, opts = {}) ⇒ InboxRetentionPolicyDto
Create inbox retention policy for your global account.
-
#create_or_update_inbox_retention_policy_for_account_with_http_info(create_inbox_retention_policy_for_account_options, opts = {}) ⇒ Array<(InboxRetentionPolicyDto, Integer, Hash)>
Create inbox retention policy for your global account.
-
#delete_inbox_retention_policy_for_account(opts = {}) ⇒ EmptyResponseDto
Delete inbox retention policy for your global account.
-
#delete_inbox_retention_policy_for_account_with_http_info(opts = {}) ⇒ Array<(EmptyResponseDto, Integer, Hash)>
Delete inbox retention policy for your global account.
- #get_entity_automations(opts = {}) ⇒ PageEntityAutomationItems
-
#get_entity_automations_with_http_info(opts = {}) ⇒ Array<(PageEntityAutomationItems, Integer, Hash)>
PageEntityAutomationItems data, response status code and response headers.
- #get_entity_events(opts = {}) ⇒ PageEntityEventItems
-
#get_entity_events_with_http_info(opts = {}) ⇒ Array<(PageEntityEventItems, Integer, Hash)>
PageEntityEventItems data, response status code and response headers.
- #get_entity_favorites(opts = {}) ⇒ PageEntityFavouriteItems
-
#get_entity_favorites_with_http_info(opts = {}) ⇒ Array<(PageEntityFavouriteItems, Integer, Hash)>
PageEntityFavouriteItems data, response status code and response headers.
-
#get_inbox_retention_policy_for_account(opts = {}) ⇒ InboxRetentionPolicyOptionalDto
Get inbox retention policy for your global account.
-
#get_inbox_retention_policy_for_account_with_http_info(opts = {}) ⇒ Array<(InboxRetentionPolicyOptionalDto, Integer, Hash)>
Get inbox retention policy for your global account.
-
#get_json_property_as_string(property, body, opts = {}) ⇒ String
Utility function to extract properties from JSON objects in language where this is cumbersome.
-
#get_json_property_as_string_with_http_info(property, body, opts = {}) ⇒ Array<(String, Integer, Hash)>
Utility function to extract properties from JSON objects in language where this is cumbersome.
-
#get_user_info(opts = {}) ⇒ UserInfoDto
Get account information for your user.
-
#get_user_info_with_http_info(opts = {}) ⇒ Array<(UserInfoDto, Integer, Hash)>
Get account information for your user.
-
#initialize(api_client = ApiClient.default) ⇒ UserControllerApi
constructor
A new instance of UserControllerApi.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ UserControllerApi
Returns a new instance of UserControllerApi.
19 20 21 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 19 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 17 def api_client @api_client end |
Instance Method Details
#create_or_update_inbox_retention_policy_for_account(create_inbox_retention_policy_for_account_options, opts = {}) ⇒ InboxRetentionPolicyDto
Create inbox retention policy for your global account
26 27 28 29 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 26 def create_or_update_inbox_retention_policy_for_account(, opts = {}) data, _status_code, _headers = create_or_update_inbox_retention_policy_for_account_with_http_info(, opts) data end |
#create_or_update_inbox_retention_policy_for_account_with_http_info(create_inbox_retention_policy_for_account_options, opts = {}) ⇒ Array<(InboxRetentionPolicyDto, Integer, Hash)>
Create inbox retention policy for your global account
35 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 81 82 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 35 def create_or_update_inbox_retention_policy_for_account_with_http_info(, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserControllerApi.create_or_update_inbox_retention_policy_for_account ...' end # verify the required parameter 'create_inbox_retention_policy_for_account_options' is set if @api_client.config.client_side_validation && .nil? fail ArgumentError, "Missing the required parameter 'create_inbox_retention_policy_for_account_options' when calling UserControllerApi.create_or_update_inbox_retention_policy_for_account" end # resource path local_var_path = '/user/inbox-retention-policies/account' # 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(['*/*']) # 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() # return_type return_type = opts[:return_type] || 'InboxRetentionPolicyDto' # auth_names auth_names = opts[:auth_names] || ['API_KEY'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserControllerApi#create_or_update_inbox_retention_policy_for_account\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_inbox_retention_policy_for_account(opts = {}) ⇒ EmptyResponseDto
Delete inbox retention policy for your global account
87 88 89 90 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 87 def delete_inbox_retention_policy_for_account(opts = {}) data, _status_code, _headers = delete_inbox_retention_policy_for_account_with_http_info(opts) data end |
#delete_inbox_retention_policy_for_account_with_http_info(opts = {}) ⇒ Array<(EmptyResponseDto, Integer, Hash)>
Delete inbox retention policy for your global account
95 96 97 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 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 95 def delete_inbox_retention_policy_for_account_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserControllerApi.delete_inbox_retention_policy_for_account ...' end # resource path local_var_path = '/user/inbox-retention-policies/account' # 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(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'EmptyResponseDto' # auth_names auth_names = opts[:auth_names] || ['API_KEY'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserControllerApi#delete_inbox_retention_policy_for_account\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_entity_automations(opts = {}) ⇒ PageEntityAutomationItems
148 149 150 151 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 148 def get_entity_automations(opts = {}) data, _status_code, _headers = get_entity_automations_with_http_info(opts) data end |
#get_entity_automations_with_http_info(opts = {}) ⇒ Array<(PageEntityAutomationItems, Integer, Hash)>
Returns PageEntityAutomationItems data, response status code and response headers.
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 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 163 def get_entity_automations_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserControllerApi.get_entity_automations ...' end if @api_client.config.client_side_validation && !opts[:'size'].nil? && opts[:'size'] > 100 fail ArgumentError, 'invalid value for "opts[:"size"]" when calling UserControllerApi.get_entity_automations, must be smaller than or equal to 100.' end allowable_values = ["ASC", "DESC"] if @api_client.config.client_side_validation && opts[:'sort'] && !allowable_values.include?(opts[:'sort']) fail ArgumentError, "invalid value for \"sort\", must be one of #{allowable_values}" end allowable_values = ["INBOX_FORWARDER", "INBOX_REPLIER", "INBOX_RULESET"] if @api_client.config.client_side_validation && opts[:'filter'] && !allowable_values.include?(opts[:'filter']) fail ArgumentError, "invalid value for \"filter\", must be one of #{allowable_values}" end # resource path local_var_path = '/user/automations' # 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'] = opts[:'sort'] if !opts[:'sort'].nil? query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil? query_params[:'before'] = opts[:'before'] if !opts[:'before'].nil? query_params[:'inboxId'] = opts[:'inbox_id'] if !opts[:'inbox_id'].nil? query_params[:'phoneId'] = opts[:'phone_id'] if !opts[:'phone_id'].nil? query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'PageEntityAutomationItems' # auth_names auth_names = opts[:auth_names] || ['API_KEY'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserControllerApi#get_entity_automations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_entity_events(opts = {}) ⇒ PageEntityEventItems
239 240 241 242 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 239 def get_entity_events(opts = {}) data, _status_code, _headers = get_entity_events_with_http_info(opts) data end |
#get_entity_events_with_http_info(opts = {}) ⇒ Array<(PageEntityEventItems, Integer, Hash)>
Returns PageEntityEventItems data, response status code and response headers.
257 258 259 260 261 262 263 264 265 266 267 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 309 310 311 312 313 314 315 316 317 318 319 320 321 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 257 def get_entity_events_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserControllerApi.get_entity_events ...' end if @api_client.config.client_side_validation && !opts[:'size'].nil? && opts[:'size'] > 100 fail ArgumentError, 'invalid value for "opts[:"size"]" when calling UserControllerApi.get_entity_events, must be smaller than or equal to 100.' end allowable_values = ["ASC", "DESC"] if @api_client.config.client_side_validation && opts[:'sort'] && !allowable_values.include?(opts[:'sort']) fail ArgumentError, "invalid value for \"sort\", must be one of #{allowable_values}" end allowable_values = ["WEBHOOK_EVENT", "INBOX_FORWARDER_EVENT", "INBOX_REPLIER_EVENT", "INBOX_RULESET_EVENT", "ALIAS_EVENT"] if @api_client.config.client_side_validation && opts[:'filter'] && !allowable_values.include?(opts[:'filter']) fail ArgumentError, "invalid value for \"filter\", must be one of #{allowable_values}" end # resource path local_var_path = '/user/events' # 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'] = opts[:'sort'] if !opts[:'sort'].nil? query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil? query_params[:'before'] = opts[:'before'] if !opts[:'before'].nil? query_params[:'inboxId'] = opts[:'inbox_id'] if !opts[:'inbox_id'].nil? query_params[:'emailId'] = opts[:'email_id'] if !opts[:'email_id'].nil? query_params[:'phoneId'] = opts[:'phone_id'] if !opts[:'phone_id'].nil? query_params[:'smsId'] = opts[:'sms_id'] if !opts[:'sms_id'].nil? query_params[:'attachmentId'] = opts[:'attachment_id'] if !opts[:'attachment_id'].nil? query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'PageEntityEventItems' # auth_names auth_names = opts[:auth_names] || ['API_KEY'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserControllerApi#get_entity_events\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_entity_favorites(opts = {}) ⇒ PageEntityFavouriteItems
331 332 333 334 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 331 def get_entity_favorites(opts = {}) data, _status_code, _headers = get_entity_favorites_with_http_info(opts) data end |
#get_entity_favorites_with_http_info(opts = {}) ⇒ Array<(PageEntityFavouriteItems, Integer, Hash)>
Returns PageEntityFavouriteItems data, response status code and response headers.
344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 344 def get_entity_favorites_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserControllerApi.get_entity_favorites ...' end if @api_client.config.client_side_validation && !opts[:'size'].nil? && opts[:'size'] > 100 fail ArgumentError, 'invalid value for "opts[:"size"]" when calling UserControllerApi.get_entity_favorites, must be smaller than or equal to 100.' end allowable_values = ["ASC", "DESC"] if @api_client.config.client_side_validation && opts[:'sort'] && !allowable_values.include?(opts[:'sort']) fail ArgumentError, "invalid value for \"sort\", must be one of #{allowable_values}" end allowable_values = ["INBOX", "EMAIL", "ATTACHMENT", "PHONE", "SMS"] if @api_client.config.client_side_validation && opts[:'filter'] && !allowable_values.include?(opts[:'filter']) fail ArgumentError, "invalid value for \"filter\", must be one of #{allowable_values}" end # resource path local_var_path = '/user/favorites' # 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'] = opts[:'sort'] if !opts[:'sort'].nil? query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil? query_params[:'before'] = opts[:'before'] if !opts[:'before'].nil? query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'PageEntityFavouriteItems' # auth_names auth_names = opts[:auth_names] || ['API_KEY'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserControllerApi#get_entity_favorites\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_inbox_retention_policy_for_account(opts = {}) ⇒ InboxRetentionPolicyOptionalDto
Get inbox retention policy for your global account
408 409 410 411 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 408 def get_inbox_retention_policy_for_account(opts = {}) data, _status_code, _headers = get_inbox_retention_policy_for_account_with_http_info(opts) data end |
#get_inbox_retention_policy_for_account_with_http_info(opts = {}) ⇒ Array<(InboxRetentionPolicyOptionalDto, Integer, Hash)>
Get inbox retention policy for your global account
416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 416 def get_inbox_retention_policy_for_account_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserControllerApi.get_inbox_retention_policy_for_account ...' end # resource path local_var_path = '/user/inbox-retention-policies/account' # 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(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'InboxRetentionPolicyOptionalDto' # auth_names auth_names = opts[:auth_names] || ['API_KEY'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserControllerApi#get_inbox_retention_policy_for_account\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_json_property_as_string(property, body, opts = {}) ⇒ String
Utility function to extract properties from JSON objects in language where this is cumbersome.
464 465 466 467 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 464 def get_json_property_as_string(property, body, opts = {}) data, _status_code, _headers = get_json_property_as_string_with_http_info(property, body, opts) data end |
#get_json_property_as_string_with_http_info(property, body, opts = {}) ⇒ Array<(String, Integer, Hash)>
Utility function to extract properties from JSON objects in language where this is cumbersome.
474 475 476 477 478 479 480 481 482 483 484 485 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 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 474 def get_json_property_as_string_with_http_info(property, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserControllerApi.get_json_property_as_string ...' end # verify the required parameter 'property' is set if @api_client.config.client_side_validation && property.nil? fail ArgumentError, "Missing the required parameter 'property' when calling UserControllerApi.get_json_property_as_string" end # resource path local_var_path = '/user/json/pluck' # query parameters query_params = opts[:query_params] || {} query_params[:'property'] = property # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # 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(body) # return_type return_type = opts[:return_type] || 'String' # auth_names auth_names = opts[:auth_names] || ['API_KEY'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserControllerApi#get_json_property_as_string\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_user_info(opts = {}) ⇒ UserInfoDto
Get account information for your user
527 528 529 530 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 527 def get_user_info(opts = {}) data, _status_code, _headers = get_user_info_with_http_info(opts) data end |
#get_user_info_with_http_info(opts = {}) ⇒ Array<(UserInfoDto, Integer, Hash)>
Get account information for your user
535 536 537 538 539 540 541 542 543 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 |
# File 'lib/mailslurp_client/api/user_controller_api.rb', line 535 def get_user_info_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: UserControllerApi.get_user_info ...' end # resource path local_var_path = '/user/info' # 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(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'UserInfoDto' # auth_names auth_names = opts[:auth_names] || ['API_KEY'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: UserControllerApi#get_user_info\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |