Skip to content

Commit be5903e

Browse files
authored
Merge pull request #12 from NarrativeScience/QPT-30465/google-analytics-models
QPT-30465: add Google Analytics source models
2 parents 574af45 + feb91cf commit be5903e

22 files changed

+1350
-43
lines changed

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ https://www.stitchdata.com/docs/developers/stitch-connect/api
77
This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
88

99
- API version: 0.3
10-
- Package version: 0.2.1
10+
- Package version: 0.2.2
1111
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
1212

1313
Table of Contents:
@@ -95,6 +95,8 @@ Class | Method | HTTP request | Description
9595
- [FieldLevelMetadata](docs/FieldLevelMetadata.md)
9696
- [ForcedReplicationMethod](docs/ForcedReplicationMethod.md)
9797
- [ForcedReplicationMethodObject](docs/ForcedReplicationMethodObject.md)
98+
- [GoogleAnalyticsSourceFormProperties](docs/GoogleAnalyticsSourceFormProperties.md)
99+
- [GoogleAnalyticsSourceFormPropertiesReportDefinitions](docs/GoogleAnalyticsSourceFormPropertiesReportDefinitions.md)
98100
- [HookNotification](docs/HookNotification.md)
99101
- [HookNotificationConfig](docs/HookNotificationConfig.md)
100102
- [Metadata](docs/Metadata.md)
@@ -147,6 +149,6 @@ npx openapi-generator generate \
147149
--package-name stitch_connect_client \
148150
--git-user-id NarrativeScience \
149151
--git-repo-id stitch-connect-python \
150-
-p packageVersion=0.2.1 \
152+
-p packageVersion=0.2.2 \
151153
-t templates
152154
```

docs/FieldLevelMetadata.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ Name | Type | Description | Notes
1010
**sql_datatype** | **str** | For database sources only. The data type of a column from a database. | [optional]
1111
**field_exclusions** | **object** | A list of arrays, each array containing an array of strings that correspond to fields that are incompatible when the current field is selected. For example: If the metadata for a DeviceOS field contains a fieldExclusion of [\"properties\":\"ImpressionLostToBidPercent\"], then the DeviceOS and ImpressionLostToBidPercent fields cannot be selected together in the stream. | [optional]
1212
**unsupported_description** | **str** | The reason a field is unsupported (`inclusion`: unsupported). Note: This is not available for all sources. | [optional]
13+
**tap_google_analytics_cubes** | **list[str]** | For Google Analytics sources only. An array of strings containing the ‘cubes’ the field is a part of. A cube is a group of metrics and dimensions that are compatible together. | [optional]
14+
**tap_google_analytics_group** | **list[str]** | For Google Analytics sources only. The group the field belongs to. Possible values are: - Ad Exchange - Adsense - Adwords - App Tracking - Audience - Channel Grouping - Content Experiments - Content Grouping - Custom Variables or Columns - DoubleClick Bid Manager - DoubleClick Campaign Manager - DoubleClick Search - DoubleClick for Publishers - DoubleClick for Publishers Backfill - Ecommerce - Event Tracking - Exceptions - Geo Network - Goal Conversions - Internal Search - Lifetime Value and Cohorts - Page Tracking - Platform or Device - Publisher - Report Fields - Session - Site Speed - Social Activities - Social Interactions - System - Time - Traffic Sources - User - User Timings | [optional]
15+
**behavior** | **str** | For Google Analytics and Google Ads sources only. The type of field. Possible values are: - ATTRIBUTE - Goolgle Ads sources only - METRIC - DIMENSION - Google Analytics sources only - SEGMENT - Goolgle Ads sources only Note: This property won’t be present for Google Analytics fields where tap_google_analytics.group: Report Fields. | [optional]
1316

1417
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
1518

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# GoogleAnalyticsSourceFormProperties
2+
3+
Google Analytics connections read data from the Google Analytics API and correspond to source type: platform.google-analytics.
4+
## Properties
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**anchor_time** | **str** | Defines the time that frequency_in_minutes is “anchored” to, which Stitch will use to create the integration’s replication schedule. In Stitch, this is referred to as Anchor Scheduling. This field must contain an ISO 8601-compliant date. Note: When Stitch stores this value, it will be in UTC. You should provide this value in UTC to ensure the desired anchor time is retained. For example: You want to create a schedule that is anchored to 1:00PM EST and runs every 6 hours (360 minutes). To do this, you can set anchor_time to something like 2018-04-30T17:00:00Z and frequency_in_minutes to 360. This means jobs would run at 23:00:00, 05:00:00, 11:00:00, and so on. | [optional]
8+
**client_id** | **str** | The secure OAuth 2.0 identifier for the client application. | [optional]
9+
**client_secret** | **str** | The secure OAuth 2.0 secret key for the client application. | [optional]
10+
**cron_expression** | **str** | Note: Advanced Scheduling using Cron is not yet supported for this source. A value may be submitted for this property if the account is on an Enterprise plan, but Stitch will not use the expression submitted. A valid Quartz cron expression representing the replication schedule for the integration. Refer to the Advanced Scheduling documentation for more info. Note: If neither a cron_expression or frequency_in_minutes property is provided, Stitch will use the source’s default frequency_in_minutes value (60). | [optional]
11+
**frequency_in_minutes** | **str** | Defines how often, in minutes, Stitch should attempt to replicate data from Google Analytics. Accepted values are: - 30 - 60 - 360 - 720 - 1440 | [optional]
12+
**quota_user** | **str** | Note: This is a read-only property and will be returned when the Google Analytics object is successfully created. Including it in POST or PUT requests will result in InvalidProperties errors. | [optional]
13+
**refresh_token** | **str** | The OAuth 2.0 refresh token used to access the Google API. | [optional]
14+
**report_definitions** | [**list[GoogleAnalyticsSourceFormPropertiesReportDefinitions]**](GoogleAnalyticsSourceFormPropertiesReportDefinitions.md) | An array of objects, each object pertaining to a custom report you want to create. Note: Metrics and dimensions for each report can be selected when the source proceeds to the field_selection step. | [optional]
15+
**start_date** | **str** | The date from which Stitch should begin replicating data from Salesforce. Data from this date forward will be replicated. This field must contain an ISO 8601-compliant date, and the timestamp must be midnight. For example: 2018-01-01T00:00:00Z | [optional]
16+
17+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
18+
19+
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# GoogleAnalyticsSourceFormPropertiesReportDefinitions
2+
3+
## Properties
4+
Name | Type | Description | Notes
5+
------------ | ------------- | ------------- | -------------
6+
**id** | **str** | A unique ID for the custom report. | [optional]
7+
**name** | **str** | The name of the custom report. This will be used to create the name of the corresponding table in the destination. | [optional]
8+
9+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
10+
11+

docs/MetadataObject.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,15 @@ Name | Type | Description | Notes
1515
**table_key_properties** | **list[str]** | An array of strings listing the fields that make up the key properties of the table. These are the table’s defined Primary Keys. | [optional]
1616
**valid_replication_keys** | **list[str]** | An array of strings indicating the fields valid for use as Replication Keys in Key-based Incremental Replication (replication-method: INCREMENTAL). Note: For SaaS sources, the fields listed in this array are pre-defined by Stitch and will be used as the Replication Keys for the stream. They cannot be modified. | [optional]
1717
**view_key_properties** | **list[str]** | For database sources only. An array of strings listing the fields that make up the key properties of the view. | [optional]
18+
**tap_google_analytics_all_cubes** | **list[str]** | For Google Analytics sources only. An array of strings listing all the ‘cubes’ available in the Google Analytics source. A cube is a group of metrics and dimensions that are compatible together. | [optional]
1819
**inclusion** | **str** | Indicates when a field will be included. Possible values are: automatic - The field is included all the time, regardless of selected-by-default and selected values available - The field is available for selection. The field will be included if selected-by-default or selected is true. unsupported - The field is unsupported and will not be included, regardless of selected-by-default and selected values If a field is unsupported, the `unsupported-description` attribute may provide additonal information. | [optional]
1920
**selected_by_default** | **bool** | Indicates if a field will be selected by default. Possible values are: null - The value has not been set true - The field is selected by default and is included regardless of the `selected` value false - The field is not selected by default. The field will be included if the `selected value` is true. | [optional]
2021
**sql_datatype** | **str** | For database sources only. The data type of a column from a database. | [optional]
2122
**field_exclusions** | **object** | A list of arrays, each array containing an array of strings that correspond to fields that are incompatible when the current field is selected. For example: If the metadata for a DeviceOS field contains a fieldExclusion of [\"properties\":\"ImpressionLostToBidPercent\"], then the DeviceOS and ImpressionLostToBidPercent fields cannot be selected together in the stream. | [optional]
2223
**unsupported_description** | **str** | The reason a field is unsupported (`inclusion`: unsupported). Note: This is not available for all sources. | [optional]
24+
**tap_google_analytics_cubes** | **list[str]** | For Google Analytics sources only. An array of strings containing the ‘cubes’ the field is a part of. A cube is a group of metrics and dimensions that are compatible together. | [optional]
25+
**tap_google_analytics_group** | **list[str]** | For Google Analytics sources only. The group the field belongs to. Possible values are: - Ad Exchange - Adsense - Adwords - App Tracking - Audience - Channel Grouping - Content Experiments - Content Grouping - Custom Variables or Columns - DoubleClick Bid Manager - DoubleClick Campaign Manager - DoubleClick Search - DoubleClick for Publishers - DoubleClick for Publishers Backfill - Ecommerce - Event Tracking - Exceptions - Geo Network - Goal Conversions - Internal Search - Lifetime Value and Cohorts - Page Tracking - Platform or Device - Publisher - Report Fields - Session - Site Speed - Social Activities - Social Interactions - System - Time - Traffic Sources - User - User Timings | [optional]
26+
**behavior** | **str** | For Google Analytics and Google Ads sources only. The type of field. Possible values are: - ATTRIBUTE - Goolgle Ads sources only - METRIC - DIMENSION - Google Analytics sources only - SEGMENT - Goolgle Ads sources only Note: This property won’t be present for Google Analytics fields where tap_google_analytics.group: Report Fields. | [optional]
2327

2428
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
2529

docs/SalesforceSourceFormProperties.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,18 @@ Salesforce connections read data from the Salesforce API and correspond to sourc
55
Name | Type | Description | Notes
66
------------ | ------------- | ------------- | -------------
77
**anchor_time** | **str** | Defines the time that frequency_in_minutes is “anchored” to, which Stitch will use to create the integration’s replication schedule. In Stitch, this is referred to as Anchor Scheduling. This field must contain an ISO 8601-compliant date. Note: When Stitch stores this value, it will be in UTC. You should provide this value in UTC to ensure the desired anchor time is retained. For example: You want to create a schedule that is anchored to 1:00PM EST and runs every 6 hours (360 minutes). To do this, you can set anchor_time to something like 2018-04-30T17:00:00Z and frequency_in_minutes to 360. This means jobs would run at 23:00:00, 05:00:00, 11:00:00, and so on. | [optional]
8-
**api_type** | **str** | The Salesforce API Stitch should use to extract data. Possible values are REST or BULK. |
8+
**api_type** | **str** | The Salesforce API Stitch should use to extract data. Possible values are REST or BULK. | [optional]
99
**client_id** | **str** | The secure OAuth 2.0 identifier for the client application. | [optional]
1010
**client_secret** | **str** | The secure OAuth 2.0 secret key for the client application. | [optional]
1111
**cron_expression** | **str** | Note: Advanced Scheduling using Cron is not yet supported for this source. A value may be submitted for this property if the account is on an Enterprise plan, but Stitch will not use the expression submitted. A valid Quartz cron expression representing the replication schedule for the integration. Refer to the Advanced Scheduling documentation for more info. Note: If neither a cron_expression or frequency_in_minutes property is provided, Stitch will use the source’s default frequency_in_minutes value (60). | [optional]
12-
**frequency_in_minutes** | **str** | Defines how often, in minutes, Stitch should attempt to replicate data from Salesforce. Accepted values are: - 30 - 60 - 360 - 720 - 1440 |
12+
**frequency_in_minutes** | **str** | Defines how often, in minutes, Stitch should attempt to replicate data from Salesforce. Accepted values are: - 30 - 60 - 360 - 720 - 1440 | [optional]
1313
**instance_url** | **str** | The url of the instance to connect to. | [optional]
1414
**is_sandbox** | **str** | If `true`, the Salesforce account being connected is a sandbox. | [optional]
1515
**quota_percent_per_run** | **str** | The maximum percentage of Salesforce API quota allowed per replication job. | [optional]
1616
**quota_percent_total** | **str** | The maximum percentage of Salesforce API quota allowed per day. | [optional]
1717
**refresh_token** | **str** | The OAuth 2.0 refresh token used to access the Salesforce API. | [optional]
18-
**select_fields_by_default** | **str** | If `true`, Stitch will automatically set new fields added in Salesforce to replicate. |
19-
**start_date** | **str** | The date from which Stitch should begin replicating data from Salesforce. Data from this date forward will be replicated. This field must contain an ISO 8601-compliant date, and the timestamp must be midnight. For example: 2018-01-01T00:00:00Z |
18+
**select_fields_by_default** | **str** | If `true`, Stitch will automatically set new fields added in Salesforce to replicate. | [optional]
19+
**start_date** | **str** | The date from which Stitch should begin replicating data from Salesforce. Data from this date forward will be replicated. This field must contain an ISO 8601-compliant date, and the timestamp must be midnight. For example: 2018-01-01T00:00:00Z | [optional]
2020

2121
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
2222

docs/SourceFormProperties.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,21 @@ Parameters for connecting to the source, excluding any sensitive credentials. Th
44
## Properties
55
Name | Type | Description | Notes
66
------------ | ------------- | ------------- | -------------
7+
**anchor_time** | **str** | Defines the time that frequency_in_minutes is “anchored” to, which Stitch will use to create the integration’s replication schedule. In Stitch, this is referred to as Anchor Scheduling. This field must contain an ISO 8601-compliant date. Note: When Stitch stores this value, it will be in UTC. You should provide this value in UTC to ensure the desired anchor time is retained. For example: You want to create a schedule that is anchored to 1:00PM EST and runs every 6 hours (360 minutes). To do this, you can set anchor_time to something like 2018-04-30T17:00:00Z and frequency_in_minutes to 360. This means jobs would run at 23:00:00, 05:00:00, 11:00:00, and so on. | [optional]
8+
**api_type** | **str** | The Salesforce API Stitch should use to extract data. Possible values are REST or BULK. | [optional]
9+
**client_id** | **str** | The secure OAuth 2.0 identifier for the client application. | [optional]
10+
**client_secret** | **str** | The secure OAuth 2.0 secret key for the client application. | [optional]
11+
**cron_expression** | **str** | Note: Advanced Scheduling using Cron is not yet supported for this source. A value may be submitted for this property if the account is on an Enterprise plan, but Stitch will not use the expression submitted. A valid Quartz cron expression representing the replication schedule for the integration. Refer to the Advanced Scheduling documentation for more info. Note: If neither a cron_expression or frequency_in_minutes property is provided, Stitch will use the source’s default frequency_in_minutes value (60). | [optional]
12+
**frequency_in_minutes** | **str** | Defines how often, in minutes, Stitch should attempt to replicate data from Google Analytics. Accepted values are: - 30 - 60 - 360 - 720 - 1440 | [optional]
13+
**instance_url** | **str** | The url of the instance to connect to. | [optional]
14+
**is_sandbox** | **str** | If `true`, the Salesforce account being connected is a sandbox. | [optional]
15+
**quota_percent_per_run** | **str** | The maximum percentage of Salesforce API quota allowed per replication job. | [optional]
16+
**quota_percent_total** | **str** | The maximum percentage of Salesforce API quota allowed per day. | [optional]
17+
**refresh_token** | **str** | The OAuth 2.0 refresh token used to access the Google API. | [optional]
18+
**select_fields_by_default** | **str** | If `true`, Stitch will automatically set new fields added in Salesforce to replicate. | [optional]
19+
**start_date** | **str** | The date from which Stitch should begin replicating data from Salesforce. Data from this date forward will be replicated. This field must contain an ISO 8601-compliant date, and the timestamp must be midnight. For example: 2018-01-01T00:00:00Z | [optional]
20+
**quota_user** | **str** | Note: This is a read-only property and will be returned when the Google Analytics object is successfully created. Including it in POST or PUT requests will result in InvalidProperties errors. | [optional]
21+
**report_definitions** | [**list[GoogleAnalyticsSourceFormPropertiesReportDefinitions]**](GoogleAnalyticsSourceFormPropertiesReportDefinitions.md) | An array of objects, each object pertaining to a custom report you want to create. Note: Metrics and dimensions for each report can be selected when the source proceeds to the field_selection step. | [optional]
722

823
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
924

docs/StreamLevelMetadata.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ Name | Type | Description | Notes
1515
**table_key_properties** | **list[str]** | An array of strings listing the fields that make up the key properties of the table. These are the table’s defined Primary Keys. | [optional]
1616
**valid_replication_keys** | **list[str]** | An array of strings indicating the fields valid for use as Replication Keys in Key-based Incremental Replication (replication-method: INCREMENTAL). Note: For SaaS sources, the fields listed in this array are pre-defined by Stitch and will be used as the Replication Keys for the stream. They cannot be modified. | [optional]
1717
**view_key_properties** | **list[str]** | For database sources only. An array of strings listing the fields that make up the key properties of the view. | [optional]
18+
**tap_google_analytics_all_cubes** | **list[str]** | For Google Analytics sources only. An array of strings listing all the ‘cubes’ available in the Google Analytics source. A cube is a group of metrics and dimensions that are compatible together. | [optional]
1819

1920
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
2021

0 commit comments

Comments
 (0)