class GraylogAPI::Extractors

class for manage Extractors of an input

Public Class Methods

new(client) click to toggle source
# File lib/graylogapi/extractors.rb, line 4
def initialize(client)
  @client = client
end

Public Instance Methods

create(input_id, params) click to toggle source

add key to an input

@param input_id [Integer] id of an input @param params [Hash] hash with key and value of new extractor @return [GraylogAPI::Client::Response]

# File lib/graylogapi/extractors.rb, line 13
def create(input_id, params)
  @client.request(:post, "/system/inputs/#{input_id}/extractors", params)
end
delete(input_id, key) click to toggle source

delete key of an input

@param input_id [Integer] id of an input @param key [String] key of extractor @return [GraylogAPI::Client::Response]

# File lib/graylogapi/extractors.rb, line 22
def delete(input_id, key)
  @client.request(:delete, "/system/inputs/#{input_id}/extractors/#{key}")
end