Class: VoucherifySdk::EventsApi

Inherits:
Object
  • Object
show all
Defined in:
lib/VoucherifySdk/api/events_api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ EventsApi

Returns a new instance of EventsApi.



19
20
21
# File 'lib/VoucherifySdk/api/events_api.rb', line 19

def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



17
18
19
# File 'lib/VoucherifySdk/api/events_api.rb', line 17

def api_client
  @api_client
end

Instance Method Details

#track_custom_event(opts = {}) ⇒ EventsCreateResponseBody

Track Custom Event To track a custom event, you create an event object. The event object must be linked to the customer who performs the action. If a customer doesnt exist in Voucherify, the customer will be created.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:



27
28
29
30
# File 'lib/VoucherifySdk/api/events_api.rb', line 27

def track_custom_event(opts = {})
  data, _status_code, _headers = track_custom_event_with_http_info(opts)
  data
end