Class: GrowsurfRuby::Models::CampaignRetrieveAnalyticsParams

Inherits:
Internal::Type::BaseModel show all
Extended by:
Internal::Type::RequestParameters::Converter
Includes:
Internal::Type::RequestParameters
Defined in:
lib/growsurf_ruby/models/campaign_retrieve_analytics_params.rb,
sig/growsurf_ruby/models/campaign_retrieve_analytics_params.rbs

Overview

See Also:

  • GrowsurfRuby::Resources::Campaign#retrieve_analytics

Defined Under Namespace

Modules: Interval

Constant Summary

Constants included from Internal::Type::RequestParameters

Internal::Type::RequestParameters::GrowsurfRuby

Instance Attribute Summary collapse

Attributes included from Internal::Type::RequestParameters

#request_options

Instance Method Summary collapse

Methods included from Internal::Type::RequestParameters::Converter

dump_request

Methods included from Internal::Type::RequestParameters

included

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(id:, days: nil, end_date: nil, include: nil, interval: nil, start_date: nil, request_options: {}) ⇒ Object

Some parameter documentations has been truncated, see GrowsurfRuby::Models::CampaignRetrieveAnalyticsParams for more details.

Parameters:

  • id (String)
  • days (Integer) (defaults to: nil)

    Last number of days to retrieve analytics for. Defaults to 365. Maximum 1825.

  • end_date (Integer) (defaults to: nil)

    End date of the analytics timeframe as a Unix timestamp in milliseconds. Require

  • include (String) (defaults to: nil)

    Comma-separated list of optional data to include: previousPeriod adds totals for

  • interval (Symbol, GrowsurfRuby::Models::CampaignRetrieveAnalyticsParams::Interval) (defaults to: nil)

    When set to day, week, or month, the response also includes a series array

  • start_date (Integer) (defaults to: nil)

    Start date of the analytics timeframe as a Unix timestamp in milliseconds. Requi

  • request_options (GrowsurfRuby::RequestOptions, Hash{Symbol=>Object}) (defaults to: {})


# File 'lib/growsurf_ruby/models/campaign_retrieve_analytics_params.rb', line 55

Instance Attribute Details

#daysInteger?

Last number of days to retrieve analytics for. Defaults to 365. Maximum 1825.

Parameters:

  • (Integer)

Returns:

  • (Integer, nil)


19
# File 'lib/growsurf_ruby/models/campaign_retrieve_analytics_params.rb', line 19

optional :days, Integer

#end_dateInteger?

End date of the analytics timeframe as a Unix timestamp in milliseconds. Required if days is not set.

Parameters:

  • (Integer)

Returns:

  • (Integer, nil)


26
# File 'lib/growsurf_ruby/models/campaign_retrieve_analytics_params.rb', line 26

optional :end_date, Integer

#idString

Parameters:

  • value (String)

Returns:

  • (String)


13
# File 'lib/growsurf_ruby/models/campaign_retrieve_analytics_params.rb', line 13

required :id, String

#includeString?

Comma-separated list of optional data to include: previousPeriod adds totals for the equal-length window immediately before the requested one; statusCounts adds reward (and, for affiliate programs, affiliate/commission/payout) status breakdowns; rates adds derived referral rates; email adds sent, delivered, opened, clicked, bounced, spamComplaints, and per-email-type metrics. When email and an interval are both requested, each series item also contains counts for emails sent during that period. Combine email with previousPeriod to include the same email metrics in both windows.

Parameters:

  • (String)

Returns:

  • (String, nil)


39
# File 'lib/growsurf_ruby/models/campaign_retrieve_analytics_params.rb', line 39

optional :include, String

#intervalSymbol, ...

When set to day, week, or month, the response also includes a series array with per-period totals. Defaults to total (no series).



46
# File 'lib/growsurf_ruby/models/campaign_retrieve_analytics_params.rb', line 46

optional :interval, enum: -> { GrowsurfRuby::CampaignRetrieveAnalyticsParams::Interval }

#start_dateInteger?

Start date of the analytics timeframe as a Unix timestamp in milliseconds. Required if days is not set.

Parameters:

  • (Integer)

Returns:

  • (Integer, nil)


53
# File 'lib/growsurf_ruby/models/campaign_retrieve_analytics_params.rb', line 53

optional :start_date, Integer

Instance Method Details

#to_hash{

Returns:

  • ({)


52
# File 'sig/growsurf_ruby/models/campaign_retrieve_analytics_params.rbs', line 52

def to_hash: -> {