analytics

package
v0.9.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 18, 2021 License: Apache-2.0 Imports: 8 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CalculatedMetric

type CalculatedMetric struct {
	ID              string                      `json:"id,omitempty"`
	Name            string                      `json:"name,omitempty"`
	Description     string                      `json:"description,omitempty"`
	RSID            string                      `json:"rsid,omitempty"`
	ReportSuiteName string                      `json:"reportSuiteName,omitempty"`
	Owner           *Owner                      `json:"owner,omitempty"`
	Polarity        string                      `json:"polarity,omitempty"`
	Precision       int                         `json:"precision"`
	Type            string                      `json:"type,omitempty"`
	Definition      *CalculatedMetricDefinition `json:"definition,omitempty"`
	Categories      []string                    `json:"categories,omitempty"`
	Tags            *[]Tag                      `json:"tags,omitempty"`
	SiteTitle       string                      `json:"siteTitle,omitempty"`
	Modified        string                      `json:"modified,omitempty"`
	Created         string                      `json:"created,omitempty"`
}

CalculatedMetric represents a calculated metric

type CalculatedMetricDefinition

type CalculatedMetricDefinition struct {
}

CalculatedMetricDefinition represents a calculated metric definition

type CalculatedMetrics

type CalculatedMetrics struct {
	Content          *[]CalculatedMetric `json:"content,omitempty"`
	Number           int                 `json:"number"`
	Size             int                 `json:"size"`
	NumberOfElements int                 `json:"numberOfElements"`
	TotalElements    int                 `json:"totalElements"`
	PreviousPage     bool                `json:"previousPage"`
	FirstPage        bool                `json:"firstPage"`
	NextPage         bool                `json:"nextPage"`
	LastPage         bool                `json:"lastPage"`
	Sort             *[]Sort             `json:"sort,omitempty"`
	TotalPages       int                 `json:"totalPages"`
}

CalculatedMetrics represents a page of calculated metrics

type CalculatedMetricsService

type CalculatedMetricsService struct {
	// contains filtered or unexported fields
}

CalculatedMetricsService handles calculated metrics. Analytics docs: https://adobedocs.github.io/analytics-2.0-apis/#/calculatedmetrics

func (*CalculatedMetricsService) GetAll

func (s *CalculatedMetricsService) GetAll(rsids, ownerID, filterByIds, toBeUsedInRsid, locale, name, tagNames string,
	favorite, approved bool,
	limit, page int64,
	sortDirection, sortProperty string,
	expansion, includeType []string) (*CalculatedMetrics, error)

GetAll returns a list of calculated metrics that match the given filters. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/calculatedmetrics/findCalculatedMetrics

func (*CalculatedMetricsService) GetByID

func (s *CalculatedMetricsService) GetByID(id, locale string, expansion []string) (*CalculatedMetric, error)

GetByID returns a single calculated metric by ID. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/calculatedmetrics/findOneCalculatedMetric

type Client

type Client struct {

	// Services used for communicating to different parts of the API.
	CalculatedMetrics *CalculatedMetricsService
	Collections       *CollectionsService
	DateRanges        *DateRangesService
	Dimensions        *DimensionsService
	Metrics           *MetricsService
	Reports           *ReportsService
	Segments          *SegmentsService
	Users             *UsersService
	// contains filtered or unexported fields
}

Client is used to make HTTP requests against the Analytics API 2.0. It wraps a HTTP client and handles authentication.

func NewClient

func NewClient(config *Config) (*Client, error)

NewClient returns a new Analytics API 2.0 client.

func (*Client) GetBaseURL

func (client *Client) GetBaseURL() string

GetBaseURL returns the API base URL.

type Collection

type Collection struct {
	Name               string                  `json:"name,omitempty"`
	TimezoneZoneInfo   string                  `json:"timezoneZoneInfo,omitempty"`
	ParentRSID         string                  `json:"parentRsid,omitempty"`
	CollectionItemType string                  `json:"collectionItemType,omitempty"`
	Currency           string                  `json:"currency,omitempty"`
	CalendarType       *CollectionCalendarType `json:"calendarType,omitempty"`
	RSID               string                  `json:"rsid,omitempty"`
}

Collection represents a collection

type CollectionCalendarType

type CollectionCalendarType struct {
	RSID       string `json:"rsid,omitempty"`
	Type       string `json:"type,omitempty"`
	AnchorDate string `json:"anchorDate,omitempty"`
}

CollectionCalendarType represents a collection calendar type

type Collections

type Collections struct {
	Content          *[]Collection `json:"content,omitempty"`
	Number           int           `json:"number"`
	Size             int           `json:"size"`
	NumberOfElements int           `json:"numberOfElements"`
	TotalElements    int           `json:"totalElements"`
	PreviousPage     bool          `json:"previousPage"`
	FirstPage        bool          `json:"firstPage"`
	NextPage         bool          `json:"nextPage"`
	LastPage         bool          `json:"lastPage"`
	Sort             *[]Sort       `json:"sort,omitempty"`
	TotalPages       int           `json:"totalPages"`
}

Collections represents a page of collections

type CollectionsService

type CollectionsService struct {
	// contains filtered or unexported fields
}

CollectionsService handles collections. Analytics docs: https://adobedocs.github.io/analytics-2.0-apis/#/collections

func (*CollectionsService) GetAll

func (s *CollectionsService) GetAll(rsids, rsidContains string, limit, page int64, expansion []string) (*Collections, error)

GetAll returns a list of report suites that match the given filters. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/collections/findAll

func (*CollectionsService) GetByID

func (s *CollectionsService) GetByID(id string, expansion []string) (*Collection, error)

GetByID returns a report suite by ID. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/collections/findOne

type Config

type Config struct {
	HTTPClient  *http.Client
	BaseURL     string
	ClientID    string
	OrgID       string
	AccessToken string
	CompanyID   string
}

Config holds configuration values

type DateRange

type DateRange struct {
	ID              string               `json:"id,omitempty"`
	Name            string               `json:"name,omitempty"`
	Description     string               `json:"description,omitempty"`
	RSID            string               `json:"rsid,omitempty"`
	ReportSuiteName string               `json:"reportSuiteName,omitempty"`
	Owner           *Owner               `json:"owner,omitempty"`
	Definition      *DateRangeDefinition `json:"definition,omitempty"`
	Tags            *[]Tag               `json:"tags,omitempty"`
	SiteTitle       string               `json:"siteTitle,omitempty"`
	Modified        string               `json:"modified,omitempty"`
	Created         string               `json:"created,omitempty"`
}

DateRange represents a date range

type DateRangeDefinition

type DateRangeDefinition struct {
}

DateRangeDefinition represents a date range definition

type DateRanges

type DateRanges struct {
	Content          *[]DateRange `json:"content,omitempty"`
	Number           int          `json:"number"`
	Size             int          `json:"size"`
	NumberOfElements int          `json:"numberOfElements"`
	TotalElements    int          `json:"totalElements"`
	PreviousPage     bool         `json:"previousPage"`
	FirstPage        bool         `json:"firstPage"`
	NextPage         bool         `json:"nextPage"`
	LastPage         bool         `json:"lastPage"`
	Sort             *[]Sort      `json:"sort,omitempty"`
	TotalPages       int          `json:"totalPages"`
}

DateRanges represents a page of date ranges

type DateRangesService

type DateRangesService struct {
	// contains filtered or unexported fields
}

DateRangesService handles date ranges. Analytics docs: https://adobedocs.github.io/analytics-2.0-apis/#/dateranges

func (*DateRangesService) GetAll

func (s *DateRangesService) GetAll(locale, filterByIDs string, limit, page int64, expansion, includeType []string) (*DateRanges, error)

GetAll returns a list of date ranges for the user. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/dateranges/getDateRanges

func (*DateRangesService) GetByID

func (s *DateRangesService) GetByID(id, locale string, expansion []string) (*DateRange, error)

GetByID returns configuration for a date range. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/dateranges/getDateRange

type Dimension

type Dimension struct {
	ID                  string                 `json:"id,omitempty"`
	Title               string                 `json:"title,omitempty"`
	Name                string                 `json:"name,omitempty"`
	Type                string                 `json:"type,omitempty"`
	Category            string                 `json:"category,omitempty"`
	Categories          []string               `json:"categories,omitempty"`
	Support             []string               `json:"support,omitempty"`
	Pathable            bool                   `json:"pathable"`
	Parent              string                 `json:"parent,omitempty"`
	ExtraTitleInfo      string                 `json:"extraTitleInfo,omitempty"`
	Segmentable         bool                   `json:"segmentable"`
	Reportable          []string               `json:"reportable,omitempty"`
	Description         string                 `json:"description,omitempty"`
	AllowedForReporting bool                   `json:"allowedForReporting"`
	NoneSettings        *DimensionNoneSettings `json:"noneSettings,omitempty"`
	Tags                *[]Tag                 `json:"tags,omitempty"`
}

Dimension represents a dimension

type DimensionNoneSettings

type DimensionNoneSettings struct {
	IncludeNoneByDefault bool `json:"includeNoneByDefault,omitempty"`
	NoneChangeable       bool `json:"noneChangeable,omitempty"`
}

DimensionNoneSettings represents dimension 'none' settings

type DimensionsService

type DimensionsService struct {
	// contains filtered or unexported fields
}

DimensionsService handles dimensions. Analytics docs: https://adobedocs.github.io/analytics-2.0-apis/#/dimensions

func (*DimensionsService) GetAll

func (s *DimensionsService) GetAll(rsID, locale string, segmentable, reportable, classifiable bool, expansion []string) (*[]Dimension, error)

GetAll returns a list of dimensions for a given report suite. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/dimensions/dimensions_getDimensions

func (*DimensionsService) GetByID

func (s *DimensionsService) GetByID(rsID, id, locale string, expansion []string) (*Dimension, error)

GetByID returns a dimension for a given report suite. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/dimensions/dimensions_getDimension

type Metric

type Metric struct {
	ID                  string   `json:"id,omitempty"`
	Title               string   `json:"title,omitempty"`
	Name                string   `json:"name,omitempty"`
	Type                string   `json:"type,omitempty"`
	ExtraTitleInfo      string   `json:"extraTitleInfo,omitempty"`
	Category            string   `json:"category,omitempty"`
	Categories          []string `json:"categories,omitempty"`
	Support             []string `json:"support,omitempty"`
	Allocation          bool     `json:"allocation"`
	Precision           int      `json:"precision"`
	Calculated          bool     `json:"calculated"`
	Segmentable         bool     `json:"segmentable"`
	Description         string   `json:"description,omitempty"`
	Polarity            string   `json:"polarity,omitempty"`
	HelpLink            string   `json:"helpLink,omitempty"`
	AllowedForReporting bool     `json:"allowedForReporting"`
	Tags                *[]Tag   `json:"tags,omitempty"`
}

Metric represents a metric

type MetricsService

type MetricsService struct {
	// contains filtered or unexported fields
}

MetricsService handles metrics. Analytics docs: https://adobedocs.github.io/analytics-2.0-apis/#/metrics

func (*MetricsService) GetAll

func (s *MetricsService) GetAll(rsID, locale string, segmentable bool, expansion []string) (*[]Metric, error)

GetAll returns a list of metrics for a given report suite. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/metrics/getMetrics

func (*MetricsService) GetByID

func (s *MetricsService) GetByID(rsID, id, locale string, expansion []string) (*Metric, error)

GetByID returns a metric for a given report suite. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/metrics/getMetric

type Owner

type Owner struct {
	ID    int    `json:"id"`
	Name  string `json:"name,omitempty"`
	Login string `json:"login,omitempty"`
}

Owner represents an owner

type RankedReportColumnError

type RankedReportColumnError struct {
	ColumnID         string `json:"columnId,omitempty"`
	ErrorCode        string `json:"errorCode,omitempty"`
	ErrorID          string `json:"errorId,omitempty"`
	ErrorDescription string `json:"errorDescription,omitempty"`
}

RankedReportColumnError represents the report column error

type RankedReportColumnMetaData

type RankedReportColumnMetaData struct {
	Dimension    *RankedReportDimension     `json:"dimension,omitempty"`
	ColumnIDs    []string                   `json:"columnIds,omitempty"`
	ColumnErrors *[]RankedReportColumnError `json:"columnErrors,omitempty"`
}

RankedReportColumnMetaData represents the report column meta data

type RankedReportData

type RankedReportData struct {
	TotalPages       int                         `json:"totalPages,omitempty"`
	FirstPage        bool                        `json:"firstPage"`
	LastPage         bool                        `json:"lastPage"`
	NumberOfElements int                         `json:"numberOfElements,omitempty"`
	Number           int                         `json:"number,omitempty"`
	TotalElements    int                         `json:"totalElements"`
	Message          string                      `json:"message,omitempty"`
	Request          *RankedRequest              `json:"request,omitempty"`
	Columns          *RankedReportColumnMetaData `json:"columns,omitempty"`
	Rows             *[]RankedReportRowData      `json:"rows,omitempty"`
	SummaryData      *RankedReportSummaryData    `json:"summaryData,omitempty"`
}

RankedReportData represents the report data

type RankedReportDimension

type RankedReportDimension struct {
	ID   string `json:"id,omitempty"`
	Type string `json:"type,omitempty"`
}

RankedReportDimension represents the report dimension

type RankedReportRowData

type RankedReportRowData struct {
	ItemID              string    `json:"itemId,omitempty"`
	Value               string    `json:"value,omitempty"`
	RowID               string    `json:"rowId,omitempty"`
	Data                []float32 `json:"data,omitempty"`
	DataExpected        []float32 `json:"dataExpected,omitempty"`
	DataUpperBound      []float32 `json:"dataUpperBound,omitempty"`
	DataLowerBound      []float32 `json:"dataLowerBound,omitempty"`
	DataAnomalyDetected bool      `json:"dataAnomalyDetected"`
	PercentChange       []float32 `json:"percentChange,omitempty"`
	Latitude            float32   `json:"latitude,omitempty"`
	Longitude           float32   `json:"longitude,omitempty"`
}

RankedReportRowData represents the report row data

type RankedReportSummaryData

type RankedReportSummaryData struct {
	*RankedReportSummaryDataTotals `json:"summaryData,omitempty"`
}

RankedReportSummaryData represents the report summary data

type RankedReportSummaryDataTotals

type RankedReportSummaryDataTotals struct {
	FilteredTotals []int `json:"filteredTotals,omitempty"`
	Totals         []int `json:"totals,omitempty"`
}

RankedReportSummaryDataTotals represents the report summary data totals

type RankedRequest

type RankedRequest struct {
	ReportSuiteID   string                       `json:"rsid"`
	Dimension       string                       `json:"dimension"`
	Locale          *RankedRequestLocale         `json:"locale,omitempty"`
	GlobalFilters   *[]RankedRequestReportFilter `json:"globalFilters,omitempty"`
	Search          *RankedRequestSearch         `json:"search,omitempty"`
	Settings        *RankedRequestSettings       `json:"settings,omitempty"`
	Statistics      *RankedRequestStatistics     `json:"statistics,omitempty"`
	MetricContainer *RankedRequestReportMetrics  `json:"metricContainer,omitempty"`
	RowContainer    *RankedRequestReportRows     `json:"rowContainer,omitempty"`
	AnchorDate      string                       `json:"anchorDate,omitempty"`
}

RankedRequest represents a ranked report request

type RankedRequestLocale

type RankedRequestLocale struct {
	Language                string   `json:"language,omitempty"`
	Script                  string   `json:"script,omitempty"`
	Country                 string   `json:"country,omitempty"`
	Variant                 string   `json:"variant,omitempty"`
	ExtensionKey            []string `json:"extensionKeys,omitempty"`
	UnicodeLocaleAttributes []string `json:"unicodeLocaleAttributes,omitempty"`
	UnicodeLocaleKeys       []string `json:"unicodeLocaleKeys,omitempty"`
	Iso3Language            string   `json:"iso3Language,omitempty"`
	Iso3Country             string   `json:"iso3Country,omitempty"`
	DisplayLanguage         string   `json:"displayLanguage,omitempty"`
	DisplayScript           string   `json:"displayScript,omitempty"`
	DisplayCountry          string   `json:"displayCountry,omitempty"`
	DisplayVariant          string   `json:"displayVariant,omitempty"`
	DisplayName             string   `json:"displayName,omitempty"`
}

RankedRequestLocale represents a ranked request locale

type RankedRequestReportFilter

type RankedRequestReportFilter struct {
	ID                string                          `json:"id,omitempty"`
	Type              string                          `json:"type,omitempty"`
	Dimension         string                          `json:"dimension,omitempty"`
	ItemID            string                          `json:"itemId,omitempty"`
	ItemIDs           []string                        `json:"itemIds,omitempty"`
	SegmentID         string                          `json:"segmentId,omitempty"`
	SegmentDefinition *RankedRequestSegmentDefinition `json:"segmentDefinition,omitempty"`
	DateRange         string                          `json:"dateRange,omitempty"`
	ExcludeItemIDs    []string                        `json:"excludeItemIds,omitempty"`
}

RankedRequestReportFilter represents a ranked request report filter

type RankedRequestReportMetric

type RankedRequestReportMetric struct {
	ID               string                                       `json:"id,omitempty"`
	ColumnID         string                                       `json:"columnId,omitempty"`
	Filters          []string                                     `json:"filters,omitempty"`
	Sort             string                                       `json:"sort,omitempty"`
	MetricDefinition string                                       `json:"metricDefinition,omitempty"`
	Predictive       *RankedRequestReportMetricPredictiveSettings `json:"predictive,omitempty"`
}

RankedRequestReportMetric represents a report metric

type RankedRequestReportMetricPredictiveSettings

type RankedRequestReportMetricPredictiveSettings struct {
	AnomalyConfidence float64 `json:"anomalyConfidence,omitempty"`
}

RankedRequestReportMetricPredictiveSettings represents metric predictive settings

type RankedRequestReportMetrics

type RankedRequestReportMetrics struct {
	MetricFilters *[]RankedRequestReportFilter `json:"metricFilters,omitempty"`
	Metrics       *[]RankedRequestReportMetric `json:"metrics,omitempty"`
}

RankedRequestReportMetrics represents the report metrics

type RankedRequestReportRow

type RankedRequestReportRow struct {
	RowID   string   `json:"rowId,omitempty"`
	Filters []string `json:"filters,omitempty"`
}

RankedRequestReportRow represents a report row

type RankedRequestReportRows

type RankedRequestReportRows struct {
	RowFilters []RankedRequestReportFilter `json:"rowFilters,omitempty"`
	Rows       []RankedRequestReportRow    `json:"rows,omitempty"`
}

RankedRequestReportRows represents report rows

type RankedRequestSearch

type RankedRequestSearch struct {
	Clause             string   `json:"clause,omitempty"`
	ExcludeItemIDs     []string `json:"excludeItemIds,omitempty"`
	ItemIDs            []string `json:"itemIds,omitempty"`
	IncludeSearchTotal bool     `json:"includeSearchTotal"`
	Empty              bool     `json:"empty"`
}

RankedRequestSearch represents a request search

type RankedRequestSegmentDefinition

type RankedRequestSegmentDefinition struct {
	Container *RankedRequestSegmentDefinitionContainer `json:"container,omitempty"`
	Func      string                                   `json:"func,omitempty"`
	Version   []int                                    `json:"version,omitempty"`
}

RankedRequestSegmentDefinition represents a segment definition

type RankedRequestSegmentDefinitionContainer

type RankedRequestSegmentDefinitionContainer struct {
	Func    string                                   `json:"func,omitempty"`
	Context string                                   `json:"context,omitempty"`
	Pred    *RankedRequestSegmentDefinitionPredicate `json:"pred,omitempty"`
}

RankedRequestSegmentDefinitionContainer represents a segment definition container

type RankedRequestSegmentDefinitionPredicate

type RankedRequestSegmentDefinitionPredicate struct {
	Func        string                                        `json:"func,omitempty"`
	Val         *RankedRequestSegmentDefinitionPredicateValue `json:"val,omitempty"`
	Description string                                        `json:"description,omitempty"`
}

RankedRequestSegmentDefinitionPredicate represents a segment definition predicate

type RankedRequestSegmentDefinitionPredicateValue

type RankedRequestSegmentDefinitionPredicateValue struct {
	Func string `json:"func,omitempty"`
	Name string `json:"name,omitempty"`
}

RankedRequestSegmentDefinitionPredicateValue represents a segment definition predicate value

type RankedRequestSettings

type RankedRequestSettings struct {
	Limit                   int    `json:"limit"`
	Page                    int    `json:"page"`
	DimensionSort           string `json:"dimensionSort,omitempty"`
	CountRepeatInstances    bool   `json:"countRepeatInstances,omitempty"`
	ReflectRequest          bool   `json:"reflectRequest,omitempty"`
	IncludeAnomalyDetection bool   `json:"includeAnomalyDetection,omitempty"`
	IncludePercentChange    bool   `json:"includePercentChange,omitempty"`
	IncludeLatLong          bool   `json:"includeLatLong,omitempty"`
	NonesBehavior           string `json:"nonesBehavior,omitempty"`
}

RankedRequestSettings represents the request settings

type RankedRequestStatistics

type RankedRequestStatistics struct {
	Functions    []string `json:"functions,omitempty"`
	IngoreZeroes bool     `json:"ignoreZeroes"`
}

RankedRequestStatistics represents the request statistics

type ReportsService

type ReportsService struct {
	// contains filtered or unexported fields
}

ReportsService handles reports. Analytics docs: https://www.adobe.io/apis/experiencecloud/analytics/docs.html#!AdobeDocs/analytics-2.0-apis/master/reporting-guide.md

func (*ReportsService) Run

func (s *ReportsService) Run(rankedRequest *RankedRequest) (*RankedReportData, error)

Run runs a report for the passed RankedRequest. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/reports

type Segment

type Segment struct {
	ID                     string                `json:"id,omitempty"`
	Name                   string                `json:"name,omitempty"`
	Description            string                `json:"description,omitempty"`
	ReportSuiteID          string                `json:"rsid,omitempty"`
	ReportSuiteName        string                `json:"reportSuiteName,omitempty"`
	Owner                  *Owner                `json:"owner,omitempty"`
	Definition             *SegmentDefinition    `json:"definition,omitempty"`
	Compatibility          *SegmentCompatibility `json:"compatibility,omitempty"`
	DefinitionLastModified string                `json:"definitionLastModified,omitempty"`
	Categories             []string              `json:"categories,omitempty"`
	SiteTitle              string                `json:"siteTitle,omitempty"`
	Tags                   *[]Tag                `json:"tags,omitempty"`
	Modified               string                `json:"modified,omitempty"`
	Created                string                `json:"created,omitempty"`
}

Segment represents a segment

type SegmentCompatibility

type SegmentCompatibility struct {
	Valid              bool     `json:"valid"`
	Message            string   `json:"message,omitempty"`
	ValidatorVersion   string   `json:"validator_version,omitempty"`
	SupportedProducts  []string `json:"supported_products,omitempty"`
	SupportedSchema    []string `json:"supported_schema,omitempty"`
	SuppportedFeatures []string `json:"supported_features,omitempty"`
}

SegmentCompatibility represents segment compatibility settings

type SegmentDefinition

type SegmentDefinition struct {
	Container *SegmentDefinitionContainer `json:"container,omitempty"`
	Func      string                      `json:"func,omitempty"`
	Version   []int                       `json:"version"`
}

SegmentDefinition represents a segment definition

type SegmentDefinitionContainer

type SegmentDefinitionContainer struct {
	Context string `json:"context,omitempty"`
	Func    string `json:"func,omitempty"`
	Pred    string `json:"pred,omitempty"`
}

SegmentDefinitionContainer represents a segment definition container

type SegmentDefinitionContainerPredicate

type SegmentDefinitionContainerPredicate struct {
	Val  *SegmentDefinitionContainerPredicateValue `json:"val,omitempty"`
	Str  string                                    `json:"str,omitempty"`
	Func string                                    `json:"func,omitempty"`
}

SegmentDefinitionContainerPredicate represents a segment definition predicate

type SegmentDefinitionContainerPredicateValue

type SegmentDefinitionContainerPredicateValue struct {
	Description string `json:"description,omitempty"`
	Name        string `json:"name,omitempty"`
	Func        string `json:"func,omitempty"`
}

SegmentDefinitionContainerPredicateValue represents a segment definition predicate value

type Segments

type Segments struct {
	Content          *[]Segment `json:"content,omitempty"`
	Number           int        `json:"number"`
	Size             int        `json:"size"`
	NumberOfElements int        `json:"numberOfElements"`
	TotalElements    int        `json:"totalElements"`
	PreviousPage     bool       `json:"previousPage"`
	FirstPage        bool       `json:"firstPage"`
	NextPage         bool       `json:"nextPage"`
	LastPage         bool       `json:"lastPage"`
	Sort             *[]Sort    `json:"sort,omitempty"`
	TotalPages       int        `json:"totalPages"`
}

Segments represents a page of segments

type SegmentsService

type SegmentsService struct {
	// contains filtered or unexported fields
}

SegmentsService handles segments. Analytics docs: https://adobedocs.github.io/analytics-2.0-apis/#/segments

func (*SegmentsService) GetAll

func (s *SegmentsService) GetAll(rsids, segmentFilter, locale, name, tagNames, filterByPublishedSegments string,
	limit, page int64, sortDirection, sortProperty string,
	expansion []string, includeType []string) (*Segments, error)

GetAll returns all segments. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/segments/segments_getSegments

func (*SegmentsService) GetByID

func (s *SegmentsService) GetByID(id, locale string, expansion []string) (*Segment, error)

GetByID returns a single segment. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/segments/segments_getSegment

type Sort

type Sort struct {
	Direction  string `json:"direction,omitempty"`
	Property   string `json:"property,omitempty"`
	IgnoreCase bool   `json:"ignoreCase"`
	Ascending  bool   `json:"ascending"`
}

Sort represents sorting properties

type Tag

type Tag struct {
	ID          string             `json:"id,omitempty"`
	Name        string             `json:"name,omitempty"`
	Description string             `json:"description,omitempty"`
	Components  *[]TaggedComponent `json:"components,omitempty"`
}

Tag represents a tag

type TaggedComponent

type TaggedComponent struct {
	ComponentType string `json:"componentType,omitempty"`
	ComponentID   string `json:"componentId,omitempty"`
	Tags          *[]Tag `json:"tags,omitempty"`
}

TaggedComponent represents a tagged component

type User

type User struct {
	CompanyID      int    `json:"companyId"`
	LoginID        int    `json:"loginId"`
	Login          string `json:"login,omitempty"`
	ChangePassword bool   `json:"changePassword"`
	CreateDate     string `json:"createDate,omitempty"`
	Disabled       bool   `json:"disabled"`
	Email          string `json:"email,omitempty"`
	FirstName      string `json:"firstName,omitempty"`
	FullName       string `json:"fullName,omitempty"`
	IMSUserID      string `json:"imsUserId,omitempty"`
	LastName       string `json:"lastName,omitempty"`
	LastAccess     string `json:"lastAccess,omitempty"`
	PhoneNumber    string `json:"phoneNumber,omitempty"`
	TempLoginEnd   string `json:"tempLoginEnd,omitempty"`
	Title          string `json:"title,omitempty"`
}

User represents an Analytics user

type Users

type Users struct {
	Content          *[]User `json:"content,omitempty"`
	Number           int     `json:"number"`
	Size             int     `json:"size"`
	NumberOfElements int     `json:"numberOfElements"`
	TotalElements    int     `json:"totalElements"`
	PreviousPage     bool    `json:"previousPage"`
	FirstPage        bool    `json:"firstPage"`
	NextPage         bool    `json:"nextPage"`
	LastPage         bool    `json:"lastPage"`
	Sort             *[]Sort `json:"sort,omitempty"`
	TotalPages       int     `json:"totalPages"`
}

Users represents a page of Analytics users

type UsersService

type UsersService struct {
	// contains filtered or unexported fields
}

UsersService handles users. Analytics docs: https://adobedocs.github.io/analytics-2.0-apis/#/users

func (*UsersService) GetAll

func (s *UsersService) GetAll(limit, page int64) (*Users, error)

GetAll returns a list of users for the current users login company. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/users/findAll

func (*UsersService) GetCurrent

func (s *UsersService) GetCurrent() (*User, error)

GetCurrent returns the current user. API docs: https://adobedocs.github.io/analytics-2.0-apis/#/users/getCurrentUser

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL