Class: Drip::Client

Inherits:
Object
  • Object
show all
Includes:
Accounts, Broadcasts, CampaignSubscriptions, Campaigns, Conversions, CustomFields, Events, Forms, Orders, ShopperActivity, Subscribers, Tags, Webhooks, WorkflowTriggers, Workflows
Defined in:
lib/drip/client.rb,
lib/drip/client/tags.rb,
lib/drip/client/forms.rb,
lib/drip/client/events.rb,
lib/drip/client/orders.rb,
lib/drip/client/accounts.rb,
lib/drip/client/webhooks.rb,
lib/drip/client/campaigns.rb,
lib/drip/client/workflows.rb,
lib/drip/client/broadcasts.rb,
lib/drip/client/conversions.rb,
lib/drip/client/http_client.rb,
lib/drip/client/subscribers.rb,
lib/drip/client/configuration.rb,
lib/drip/client/custom_fields.rb,
lib/drip/client/shopper_activity.rb,
lib/drip/client/workflow_triggers.rb,
lib/drip/client/campaign_subscriptions.rb

Defined Under Namespace

Modules: Accounts, Broadcasts, CampaignSubscriptions, Campaigns, Conversions, CustomFields, Events, Forms, Orders, ShopperActivity, Subscribers, Tags, Webhooks, WorkflowTriggers, Workflows Classes: Configuration, HTTPClient

Instance Method Summary collapse

Methods included from WorkflowTriggers

#create_workflow_trigger, #update_workflow_trigger, #workflow_triggers

Methods included from Workflows

#activate_workflow, #pause_workflow, #remove_subscriber_workflow, #start_subscriber_workflow, #workflow, #workflows

Methods included from Webhooks

#create_webhook, #delete_webhook, #webhook, #webhooks

Methods included from Tags

#apply_tag, #remove_tag, #tags

Methods included from Subscribers

#create_or_update_subscriber, #create_or_update_subscribers, #delete_subscriber, #subscribe, #subscriber, #subscribers, #unsubscribe, #unsubscribe_from_all, #unsubscribe_subscribers

Methods included from ShopperActivity

#create_cart_activity_event, #create_order_activity_event, #create_order_activity_events, #create_product_activity_event

Methods included from Orders

#create_or_update_order, #create_or_update_orders, #create_or_update_refund

Methods included from Forms

#form, #forms

Methods included from Events

#event_actions, #track_event, #track_events

Methods included from CustomFields

#custom_fields

Methods included from Conversions

#conversion, #conversions

Methods included from CampaignSubscriptions

#campaign_subscriptions

Methods included from Campaigns

#activate_campaign, #campaign, #campaign_subscribers, #campaigns, #pause_campaign

Methods included from Broadcasts

#broadcast, #broadcasts

Methods included from Accounts

#account, #accounts

Constructor Details

#initialize(options = {}) {|@config| ... } ⇒ Client

Returns a new instance of Client.

Yields:

  • (@config)


61
62
63
64
# File 'lib/drip/client.rb', line 61

def initialize(options = {})
  @config = Drip::Client::Configuration.new(options)
  yield(@config) if block_given?
end

Instance Method Details

#content_typeObject



71
72
73
74
# File 'lib/drip/client.rb', line 71

def content_type
  warn "[DEPRECATED] Drip::Client#content_type is deprecated and will be removed in a future version"
  JSON_API_CONTENT_TYPE
end

#generate_resource(key, *args) ⇒ Object



66
67
68
69
# File 'lib/drip/client.rb', line 66

def generate_resource(key, *args)
  warn "[DEPRECATED] Drip::Client#generate_resource is deprecated and will be removed in a future version"
  private_generate_resource(key, *args)
end