Class: ForemanApi::Resources::SmartProxy

Inherits:
Base
  • Object
show all
Defined in:
lib/foreman_api/resources/smart_proxy.rb

Class Method Summary (collapse)

Instance Method Summary (collapse)

Class Method Details

+ (Object) doc



4
5
6
# File 'lib/foreman_api/resources/smart_proxy.rb', line 4

def self.doc
  @doc ||= ForemanApi.doc['resources']["smart_proxies"]
end

Instance Method Details

- (Array) create(params = {}, headers = {})

First item: parsed data; second item: raw body

Parameters:

  • params (Hash) (defaults to: {})

    a hash of params to be passed to the service

  • headers (Hash) (defaults to: {})

    additional http headers

Options Hash (params):

  • smart_proxy (Hash)

    allowed keys are:

    • name [String]
    • url [String]

Returns:

  • (Array)

    First item: parsed data; second item: raw body



36
37
38
# File 'lib/foreman_api/resources/smart_proxy.rb', line 36

def create(params = {}, headers = {})
  perform_call(__method__, params, headers)
end

- (Array) destroy(params = {}, headers = {})

First item: parsed data; second item: raw body

Parameters:

  • params (Hash) (defaults to: {})

    a hash of params to be passed to the service

  • headers (Hash) (defaults to: {})

    additional http headers

Options Hash (params):

  • id (String)

Returns:

  • (Array)

    First item: parsed data; second item: raw body



58
59
60
# File 'lib/foreman_api/resources/smart_proxy.rb', line 58

def destroy(params = {}, headers = {})
  perform_call(__method__, params, headers)
end

- (Array) index(params = {}, headers = {})

First item: parsed data; second item: raw body

Parameters:

  • params (Hash) (defaults to: {})

    a hash of params to be passed to the service

  • headers (Hash) (defaults to: {})

    additional http headers

Options Hash (params):

  • page (String)

    Paginate results

  • per_page (String)

    Number of entries per request

  • type (String)

    Filter by type

Returns:

  • (Array)

    First item: parsed data; second item: raw body



15
16
17
# File 'lib/foreman_api/resources/smart_proxy.rb', line 15

def index(params = {}, headers = {})
  perform_call(__method__, params, headers)
end

- (Array) show(params = {}, headers = {})

First item: parsed data; second item: raw body

Parameters:

  • params (Hash) (defaults to: {})

    a hash of params to be passed to the service

  • headers (Hash) (defaults to: {})

    additional http headers

Options Hash (params):

  • id (String)

Returns:

  • (Array)

    First item: parsed data; second item: raw body



24
25
26
# File 'lib/foreman_api/resources/smart_proxy.rb', line 24

def show(params = {}, headers = {})
  perform_call(__method__, params, headers)
end

- (Array) update(params = {}, headers = {})

First item: parsed data; second item: raw body

Parameters:

  • params (Hash) (defaults to: {})

    a hash of params to be passed to the service

  • headers (Hash) (defaults to: {})

    additional http headers

Options Hash (params):

  • id (String)
  • smart_proxy (Hash)

    allowed keys are:

    • name [String]
    • url [String]

Returns:

  • (Array)

    First item: parsed data; second item: raw body



49
50
51
# File 'lib/foreman_api/resources/smart_proxy.rb', line 49

def update(params = {}, headers = {})
  perform_call(__method__, params, headers)
end