Sha256: a270721c27fd8c258068946c5d04f0d01543c1876e5b795f8e4bd68e4026968d

Contents?: true

Size: 578 Bytes

Versions: 20

Compression:

Stored size: 578 Bytes

Contents

module Adparlor
  module Facebook
    module GraphApi
      class Insight < GraphObject
        include Fields::Insight
        include Traits::Methods
        field_attrs FIELDS
        allow_method :read

        def path
          raise FbError.new('required parameter account_id missing', 500) unless account_id
          body = instance_variables.each_with_object({}) { |var, hash| hash[var.to_s.sub(/@/, '').to_sym] = instance_variable_get(var) }
          "/act_#{account_id}/insights?#{Faraday::NestedParamsEncoder.encode(body)}"
        end
      end
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
adparlor-facebook-0.8.2 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.8.0 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.7.9 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.7.8 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.7.7 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.7.6 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.7.5 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.7.4 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.7.3 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.7.2 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.7.1 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.7.0 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.6.6 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.6.5 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.6.4 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.6.3 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.6.2 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.6.1 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.6.0 lib/adparlor/facebook/graph_api/insight.rb
adparlor-facebook-0.5.9 lib/adparlor/facebook/graph_api/insight.rb