class SimpleHubspot::Contact
Public Class Methods
create_or_update(email, params)
click to toggle source
# File lib/simple_hubspot/contact.rb, line 6 def create_or_update(email, params) ApiClient.do_post "/contacts/v1/contact/createOrUpdate/email/#{email}", { properties: Utils.hash_to_properties(params) } end
find_by_email(email)
click to toggle source
# File lib/simple_hubspot/contact.rb, line 10 def find_by_email(email) ApiClient.do_get "/contacts/v1/contact/email/#{email}/profile" end
update(vid, params = {})
click to toggle source
# File lib/simple_hubspot/contact.rb, line 14 def update(vid, params = {}) raise ArgumentError unless vid ApiClient.do_post "/contacts/v1/contact/vid/#{vid}/profile", { properties: Utils.hash_to_properties(params) } end