Skip to content

Instantly share code, notes, and snippets.

@midu
Created May 7, 2014 21:02
Show Gist options
  • Save midu/a9d808e5830d8b96c90f to your computer and use it in GitHub Desktop.
Save midu/a9d808e5830d8b96c90f to your computer and use it in GitHub Desktop.
57: def create_event(url, event_name, attributes = {})
=> 58: binding.pry
59: body = { :name => event_name, :data => attributes }
60: body[:timestamp] = attributes[:timestamp] if valid_timestamp?(attributes[:timestamp])
61: verify_response(self.class.post(url, options.merge(:body => body)))
62: end
[1] pry(#<Customerio::Client>)> attributes
=> {:alphabet=>["a", "b", "c"]}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment