class Hash
Public Instance Methods
to_options(base, text = nil)
click to toggle source
# File lib/contact-data.rb, line 11 def to_options(base, text = nil) o = { base: base } [:verbose, :url_base, :api_base, :format, :noformat].each { |k| o[k] = delete(k) if key?(k) } o[:payload] = { text: text } if text o[:params] = self unless empty? o end