Class: BrickFTP::RESTfulAPI::RetrieveLoginHistory

Inherits:
Object
  • Object
show all
Includes:
Command, RetrieveHistory
Defined in:
lib/brick_ftp/restful_api/retrieve_login_history.rb

Overview

Retrieve login history

Params

PARAMETER TYPE DESCRIPTION
page integer Optional page number of items to return in this request.
per_page integer Optional requested number of items returned per request. Default: 1000, maximum: 10000. Leave blank for default (strongly recommended).
start_at datetime Optional date and time in the history to start from.

Constant Summary

Constants included from RetrieveHistory

BrickFTP::RESTfulAPI::RetrieveHistory::MAX_PER_PAGE

Instance Method Summary collapse

Methods included from RetrieveHistory

#build_query, #retrieve, #validate_page!, #validate_per_page!, #validate_start_at!

Methods included from Command

included, #initialize

Instance Method Details

#call(page: nil, per_page: nil, start_at: nil) ⇒ Array<BrickFTP::Types::History>

Returns login history only.

  • The history starts with the most recent entries and proceeds back in time.
  • There is a maximum number of records that will be returned with a single request (default 1000 or whatever value you provide as the per_page parameter, up to a maximum of 10,000).

Parameters:

  • page (Integer) (defaults to: nil)

    Optional page number of items to return in this request.

  • per_page (Integer) (defaults to: nil)

    Optional requested number of items returned per request. Default: 1000, maximum: 10000. Leave blank for default (strongly recommended).

  • start_at (Time) (defaults to: nil)

    Optional date and time in the history to start from.

Returns:



33
34
35
# File 'lib/brick_ftp/restful_api/retrieve_login_history.rb', line 33

def call(page: nil, per_page: nil, start_at: nil)
  retrieve('/api/rest/v1/history/login.json', page, per_page, start_at)
end