def register_script(check_id, name, notes, args, interval, options = {})
      unless args.is_a?(Array)
        raise(Diplomat::DeprecatedArgument, 'Script usage is deprecated, replace by an array of args')
      end

      definition = JSON.generate(
        'ID' => check_id,
        'Name' => name,
        'Notes' => notes,
        'Args' => args,
        'Interval' => interval
      )
      ret = send_put_request(@conn, ['/v1/agent/check/register'], options, definition)
      ret.status == 200
    end
def register_script(check_id, name, notes, args, interval, options = {})
      unless args.is_a?(Array)
        raise(Diplomat::DeprecatedArgument, 'Script usage is deprecated, replace by an array of args')
      end

      definition = JSON.generate(
        'ID' => check_id,
        'Name' => name,
        'Notes' => notes,
        'Args' => args,
        'Interval' => interval
      )
      ret = send_put_request(@conn, ['/v1/agent/check/register'], options, definition)
      ret.status == 200
    end
Register a check
 @param check_id [String] the unique id of the check
 @param name [String] the name
 @param notes [String] notes about the check
 @param args [String[]] command to be run for check
 @param interval [String] frequency (with units) of the check execution
 @param options [Hash] options parameter hash
 @return [Integer] Status code
 rubocop:disable ParameterLists