Module: Vayacondios::Client::HttpWrite
Instance Method Summary collapse
-
#announce(topic, event = {}, id = nil) ⇒ Object
Create an event.
-
#set(topic, id = nil, stash = {}) ⇒ Object
(also: #set!)
Create a stash.
Methods included from Connection
base_uri, #configure_connection, factory, #http_connection, #organization, #url
Instance Method Details
#announce(topic, event = {}, id = nil) ⇒ Object
Create an event
56 57 58 59 60 |
# File 'lib/vayacondios/client/http_methods.rb', line 56 def announce(topic, event = {}, id = nil) http_connection.post url('event', topic, id) do |req| req.body = event end end |
#set(topic, id = nil, stash = {}) ⇒ Object Also known as: set!
Create a stash
48 49 50 51 52 |
# File 'lib/vayacondios/client/http_methods.rb', line 48 def set(topic, id = nil, stash = {}) http_connection.post url('stash', topic, id) do |req| req.body = stash end end |