The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Mojar::Google::Analytics::Response - Response object from GA reporting.

SYNOPSIS

  use Mojar::Google::Analytics::Response;
  $response = Mojar::Google::Analytics::Response->new(
    auth_user => q{1234@developer.gserviceaccount.com},
    private_key => $pk,
    profile_id => q{5678}
  );

DESCRIPTION

Container object returned from Google Analytics Core Reporting.

ATTRIBUTES

success

Boolean result status.

code

Error code.

message

Error message.

domain

Defaults to global.

error

String containing code and message.

start_index

Reported start index; should match your request.

items_per_page

Reported result set size; should match your request.

contains_sampled_data

Boolean.

profile_info

Summary of profile.

column_headers

Arrayref of headers records, including titles and types.

total_results

Reported total quantity of records available. (Can fluctuate from one response to the next.)

rows

Array ref containing the result set.

columns

Array ref containing the result set transposed into columns. This can be desirable for fast database insertion.

totals_for_all_results

Overall totals for your requested metrics.

METHODS

parse
  $success = $res->parse($tx->res)

Populates the Response using the supplied transaction response, returning a boolean denoting whether the transaction was successful.

SUPPORT

See Mojar.

SEE ALSO

Net::Google::Analytics is similar, main differences being dependencies and means of getting tokens.