2
0

feat(integration): Add Google Analytics integration

This commit is contained in:
Baptiste Arnaud
2022-01-19 14:25:15 +01:00
parent 44b478550f
commit 3506d86d50
21 changed files with 528 additions and 152 deletions

View File

@ -1,12 +1,15 @@
import { StepBase } from '.'
import { Table } from '../..'
export type IntegrationStep = GoogleSheetsStep
export type IntegrationStep = GoogleSheetsStep | GoogleAnalyticsStep
export type IntegrationStepOptions = GoogleSheetsOptions
export type IntegrationStepOptions =
| GoogleSheetsOptions
| GoogleAnalyticsOptions
export enum IntegrationStepType {
GOOGLE_SHEETS = 'Google Sheets',
GOOGLE_ANALYTICS = 'Google Analytics',
}
export type GoogleSheetsStep = StepBase & {
@ -14,6 +17,19 @@ export type GoogleSheetsStep = StepBase & {
options?: GoogleSheetsOptions
}
export type GoogleAnalyticsStep = StepBase & {
type: IntegrationStepType.GOOGLE_ANALYTICS
options?: GoogleAnalyticsOptions
}
export type GoogleAnalyticsOptions = {
trackingId?: string
category?: string
action?: string
label?: string
value?: number
}
export enum GoogleSheetsAction {
GET = 'Get data from sheet',
INSERT_ROW = 'Insert a row',