airbyte-source-google-search-console 1.5.16.dev202503142015__py3-none-any.whl → 1.6.0.dev202503282247__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: airbyte-source-google-search-console
3
- Version: 1.5.16.dev202503142015
3
+ Version: 1.6.0.dev202503282247
4
4
  Summary: Source implementation for Google Search Console.
5
5
  License: Elv2
6
6
  Author: Airbyte
@@ -9,18 +9,21 @@ source_google_search_console/schemas/search_analytics_by_device.json,sha256=VtoF
9
9
  source_google_search_console/schemas/search_analytics_by_page.json,sha256=KyUojZc4Lv3hPswxIJzUL5QDNsbvSugGjl_uHGF7Am4,1473
10
10
  source_google_search_console/schemas/search_analytics_by_query.json,sha256=mYc1Fu1A5TWLZCApZSjjfs_urW5BRUCPQI3rw3yQjt4,1439
11
11
  source_google_search_console/schemas/search_analytics_keyword_page_report.json,sha256=hCQZbpW9UNiCOrnUMkj4oQdzY0k8Hqoh1XkuKHvyvZw,1681
12
+ source_google_search_console/schemas/search_analytics_keyword_page_report_minimal_dimensions.json,sha256=hCQZbpW9UNiCOrnUMkj4oQdzY0k8Hqoh1XkuKHvyvZw,1681
12
13
  source_google_search_console/schemas/search_analytics_keyword_site_report_by_page.json,sha256=lFpbShmTQhFyySc_JCdIOqMP9RfOIA15fpQN9xNXtTI,1626
14
+ source_google_search_console/schemas/search_analytics_keyword_site_report_by_page_minimal_dimensions.json,sha256=lFpbShmTQhFyySc_JCdIOqMP9RfOIA15fpQN9xNXtTI,1626
13
15
  source_google_search_console/schemas/search_analytics_keyword_site_report_by_site.json,sha256=AVUl5x9jLL0FcStbTR-FMy-_A7uM-VlrJ-kdCBXWz_g,1755
16
+ source_google_search_console/schemas/search_analytics_keyword_site_report_by_site_minimal_dimensions.json,sha256=AVUl5x9jLL0FcStbTR-FMy-_A7uM-VlrJ-kdCBXWz_g,1755
14
17
  source_google_search_console/schemas/search_analytics_page_report.json,sha256=-b0Y0LenTchS0q9A2aQ4hIjUjXkYF8erOtyrTMhf6MM,1776
15
18
  source_google_search_console/schemas/search_analytics_site_report_by_page.json,sha256=hWKHkm1reqGGu1dNcWBe6_XkZ5tK-UaiymrYRVgxRxI,1515
16
19
  source_google_search_console/schemas/search_analytics_site_report_by_site.json,sha256=rAh6LuNy7nCrrNM9MTd0qxAVc886ecQaqWRgV63OfyA,1408
17
20
  source_google_search_console/schemas/sitemaps.json,sha256=coyPSZCAfzMheybfRp4WPAZCp5JF2KGRF2rWK8oC080,1775
18
21
  source_google_search_console/schemas/sites.json,sha256=WNiCRuStPL1YkJiFa8FEbNJmqaERAOf9Yow6ygIumvo,383
19
22
  source_google_search_console/service_account_authenticator.py,sha256=gjUxt0xFxj82uviCQNTsA1Jlee__UDhYNjE7bRO1G0U,1227
20
- source_google_search_console/source.py,sha256=8n10_agSa2rvPvEyBvOfOpmpEardbEhi3H0vlK2A4_g,10002
23
+ source_google_search_console/source.py,sha256=4UJW4KUVGo5WxH9ewWBVSemXH17Iqp-eaNRtUfLNET8,10431
21
24
  source_google_search_console/spec.json,sha256=WYtFvaSqWYGm1Dt2yV9G92U78Q94rh9oarbxJe3H7xo,8470
22
- source_google_search_console/streams.py,sha256=argw9ECCf7nInvrg_B5BgWa59gqL_ecvpFGbWf6tCsE,22275
23
- airbyte_source_google_search_console-1.5.16.dev202503142015.dist-info/METADATA,sha256=VPW3sTOMZUXbxtWilCnJ1rGS59MEmx5_orqs4Mh1fGM,5646
24
- airbyte_source_google_search_console-1.5.16.dev202503142015.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
25
- airbyte_source_google_search_console-1.5.16.dev202503142015.dist-info/entry_points.txt,sha256=DMcgc9bCX-Vt6hm_68pa77qS3eGdeMhg-UdlFc-XKUM,85
26
- airbyte_source_google_search_console-1.5.16.dev202503142015.dist-info/RECORD,,
25
+ source_google_search_console/streams.py,sha256=1rgtlcVUyAP3oKRNQ34qIh6rwTzvlr636GiEy0RPQLs,20508
26
+ airbyte_source_google_search_console-1.6.0.dev202503282247.dist-info/METADATA,sha256=YyTR_gsHe3OcxaiSStl2wtO8Wa5Vsfm16QJ6miZG8JA,5645
27
+ airbyte_source_google_search_console-1.6.0.dev202503282247.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
28
+ airbyte_source_google_search_console-1.6.0.dev202503282247.dist-info/entry_points.txt,sha256=DMcgc9bCX-Vt6hm_68pa77qS3eGdeMhg-UdlFc-XKUM,85
29
+ airbyte_source_google_search_console-1.6.0.dev202503282247.dist-info/RECORD,,
@@ -0,0 +1,54 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft-07/schema#",
3
+ "type": "object",
4
+ "additionalProperties": true,
5
+ "properties": {
6
+ "site_url": {
7
+ "description": "The URL of the website being monitored.",
8
+ "type": ["null", "string"]
9
+ },
10
+ "search_type": {
11
+ "description": "The type of search (e.g., web, image, video).",
12
+ "type": ["null", "string"]
13
+ },
14
+ "date": {
15
+ "description": "The date of the search data collected.",
16
+ "type": ["null", "string"],
17
+ "format": "date"
18
+ },
19
+ "country": {
20
+ "description": "The country where the search is made.",
21
+ "type": ["null", "string"]
22
+ },
23
+ "device": {
24
+ "description": "The device type used for the search (e.g., desktop, mobile).",
25
+ "type": ["null", "string"]
26
+ },
27
+ "page": {
28
+ "description": "The page URL on which the keyword appears in search results.",
29
+ "type": ["null", "string"]
30
+ },
31
+ "query": {
32
+ "description": "The search query used to find the site.",
33
+ "type": ["null", "string"]
34
+ },
35
+ "clicks": {
36
+ "description": "The number of clicks for the keyword on a specific page.",
37
+ "type": ["null", "integer"]
38
+ },
39
+ "impressions": {
40
+ "description": "The number of times the keyword appeared in search results.",
41
+ "type": ["null", "integer"]
42
+ },
43
+ "ctr": {
44
+ "description": "Click-through rate which is the percentage of clicks divided by impressions.",
45
+ "type": ["null", "number"],
46
+ "multipleOf": 1e-25
47
+ },
48
+ "position": {
49
+ "description": "The average position of the keyword on search results pages.",
50
+ "type": ["null", "number"],
51
+ "multipleOf": 1e-25
52
+ }
53
+ }
54
+ }
@@ -0,0 +1,50 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft-07/schema#",
3
+ "type": "object",
4
+ "additionalProperties": true,
5
+ "properties": {
6
+ "site_url": {
7
+ "description": "The URL of the website for which the search analytics data is retrieved.",
8
+ "type": ["null", "string"]
9
+ },
10
+ "search_type": {
11
+ "description": "The type of search conducted (e.g., web, image, video).",
12
+ "type": ["null", "string"]
13
+ },
14
+ "date": {
15
+ "description": "The date when the search data was recorded.",
16
+ "type": ["null", "string"],
17
+ "format": "date"
18
+ },
19
+ "country": {
20
+ "description": "The country from which the search query originated.",
21
+ "type": ["null", "string"]
22
+ },
23
+ "device": {
24
+ "description": "The device type used for the search query (e.g., desktop, mobile).",
25
+ "type": ["null", "string"]
26
+ },
27
+ "query": {
28
+ "description": "The search query used by the user.",
29
+ "type": ["null", "string"]
30
+ },
31
+ "clicks": {
32
+ "description": "The number of times users clicked on your website link in search results.",
33
+ "type": ["null", "integer"]
34
+ },
35
+ "impressions": {
36
+ "description": "The number of times your website link appeared in search results.",
37
+ "type": ["null", "integer"]
38
+ },
39
+ "ctr": {
40
+ "description": "Click-through rate: Number of clicks divided by the number of impressions.",
41
+ "type": ["null", "number"],
42
+ "multipleOf": 1e-25
43
+ },
44
+ "position": {
45
+ "description": "The average position of your website link in search results.",
46
+ "type": ["null", "number"],
47
+ "multipleOf": 1e-25
48
+ }
49
+ }
50
+ }
@@ -0,0 +1,50 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft-07/schema#",
3
+ "type": "object",
4
+ "additionalProperties": true,
5
+ "properties": {
6
+ "site_url": {
7
+ "description": "The URL of the site for which the search analytics data is recorded.",
8
+ "type": ["null", "string"]
9
+ },
10
+ "search_type": {
11
+ "description": "The type of search (e.g., web search, image search) that generated the analytics data.",
12
+ "type": ["null", "string"]
13
+ },
14
+ "date": {
15
+ "description": "The date for which the search analytics data is recorded.",
16
+ "type": ["null", "string"],
17
+ "format": "date"
18
+ },
19
+ "country": {
20
+ "description": "The country from which the search originated.",
21
+ "type": ["null", "string"]
22
+ },
23
+ "device": {
24
+ "description": "The type of device used by the user during the search (e.g., desktop, mobile).",
25
+ "type": ["null", "string"]
26
+ },
27
+ "query": {
28
+ "description": "The search query used by the user to find the site in search results.",
29
+ "type": ["null", "string"]
30
+ },
31
+ "clicks": {
32
+ "description": "The number of times users clicked on the search result linking to the site.",
33
+ "type": ["null", "integer"]
34
+ },
35
+ "impressions": {
36
+ "description": "The number of times the site was shown in search results to users.",
37
+ "type": ["null", "integer"]
38
+ },
39
+ "ctr": {
40
+ "description": "Click-through rate represents the percentage of users who clicked on the site's link after seeing it in search results.",
41
+ "type": ["null", "number"],
42
+ "multipleOf": 1e-25
43
+ },
44
+ "position": {
45
+ "description": "The average ranking position of the site in search results.",
46
+ "type": ["null", "number"],
47
+ "multipleOf": 1e-25
48
+ }
49
+ }
50
+ }
@@ -32,8 +32,11 @@ from source_google_search_console.streams import (
32
32
  SearchAnalyticsByPage,
33
33
  SearchAnalyticsByQuery,
34
34
  SearchAnalyticsKeywordPageReport,
35
+ SearchAnalyticsKeywordPageReportMinimalDimensions,
35
36
  SearchAnalyticsKeywordSiteReportByPage,
37
+ SearchAnalyticsKeywordSiteReportByPageMinimalDimensions,
36
38
  SearchAnalyticsKeywordSiteReportBySite,
39
+ SearchAnalyticsKeywordSiteReportBySiteMinimalDimensions,
37
40
  SearchAnalyticsPageReport,
38
41
  SearchAnalyticsSiteReportByPage,
39
42
  SearchAnalyticsSiteReportBySite,
@@ -182,11 +185,14 @@ class SourceGoogleSearchConsole(AbstractSource):
182
185
  SearchAnalyticsByPage(**stream_config),
183
186
  SearchAnalyticsAllFields(**stream_config),
184
187
  SearchAnalyticsKeywordPageReport(**stream_config),
188
+ SearchAnalyticsKeywordPageReportMinimalDimensions(**stream_config),
185
189
  SearchAnalyticsPageReport(**stream_config),
186
190
  SearchAnalyticsSiteReportBySite(**stream_config),
187
191
  SearchAnalyticsSiteReportByPage(**stream_config),
188
192
  SearchAnalyticsKeywordSiteReportByPage(**stream_config),
193
+ SearchAnalyticsKeywordSiteReportByPageMinimalDimensions(**stream_config),
189
194
  SearchAnalyticsKeywordSiteReportBySite(**stream_config),
195
+ SearchAnalyticsKeywordSiteReportBySiteMinimalDimensions(**stream_config),
190
196
  ]
191
197
 
192
198
  streams = streams + self.get_custom_reports(config=config, stream_config=stream_config)
@@ -371,20 +371,6 @@ class SearchAppearance(SearchAnalytics):
371
371
  primary_key = None
372
372
  dimensions = ["searchAppearance"]
373
373
 
374
- def request_body_json(
375
- self,
376
- stream_state: Mapping[str, Any] = None,
377
- stream_slice: Mapping[str, Any] = None,
378
- next_page_token: Mapping[str, Any] = None,
379
- ) -> Optional[Union[Dict[str, Any], str]]:
380
- data = super().request_body_json(stream_state, stream_slice, next_page_token)
381
-
382
- fields_to_remove = ["aggregationType", "startRow", "rowLimit", "dataState"]
383
- for field in fields_to_remove:
384
- data.pop(field, None)
385
-
386
- return data
387
-
388
374
 
389
375
  class SearchByKeyword(SearchAnalytics):
390
376
  """
@@ -395,14 +381,12 @@ class SearchByKeyword(SearchAnalytics):
395
381
  filters: {"dimension": "searchAppearance", "operator": "equals", "expression": keyword}
396
382
  """
397
383
 
398
- search_types = ["web", "news", "image", "video", "discover", "googleNews"]
399
-
400
384
  def stream_slices(
401
385
  self, sync_mode: SyncMode, cursor_field: List[str] = None, stream_state: Mapping[str, Any] = None
402
386
  ) -> Iterable[Optional[Mapping[str, Any]]]:
403
387
  search_appearance_stream = SearchAppearance(self._session.auth, self._site_urls, self._start_date, self._end_date)
404
388
 
405
- for stream_slice in super().stream_slices(sync_mode, cursor_field, stream_state):
389
+ for stream_slice in super().stream_slices(sync_mode, cursor_field, stream_state):
406
390
  keywords_records = search_appearance_stream.read_records(
407
391
  sync_mode=SyncMode.full_refresh, stream_state=stream_state, stream_slice=stream_slice
408
392
  )
@@ -411,8 +395,6 @@ class SearchByKeyword(SearchAnalytics):
411
395
  for keyword in keywords:
412
396
  filters = {"dimension": "searchAppearance", "operator": "equals", "expression": keyword}
413
397
  stream_slice["dimensionFilterGroups"] = [{"groupType": "and", "filters": filters}]
414
- stream_slice["dimensions"] = self.dimensions
415
-
416
398
  yield stream_slice
417
399
 
418
400
  def request_body_json(
@@ -429,18 +411,11 @@ class SearchByKeyword(SearchAnalytics):
429
411
  class SearchAnalyticsKeywordPageReport(SearchByKeyword):
430
412
  primary_key = ["site_url", "date", "country", "device", "query", "page", "search_type"]
431
413
  dimensions = ["date", "country", "device", "query", "page"]
432
- def stream_slices(
433
- self, sync_mode: SyncMode, cursor_field: List[str] = None, stream_state: Mapping[str, Any] = None
434
- ) -> Iterable[Optional[Mapping[str, Any]]]:
435
- return super(SearchByKeyword, self).stream_slices(sync_mode, cursor_field, stream_state)
436
414
 
437
- def request_body_json(
438
- self,
439
- stream_state: Mapping[str, Any] = None,
440
- stream_slice: Mapping[str, Any] = None,
441
- next_page_token: Mapping[str, Any] = None,
442
- ) -> Optional[Union[Dict[str, Any], str]]:
443
- return super(SearchByKeyword, self).request_body_json(stream_state, stream_slice, next_page_token)
415
+
416
+ class SearchAnalyticsKeywordPageReportMinimalDimensions(SearchByKeyword):
417
+ primary_key = ["site_url", "date", "country", "device", "query", "page", "search_type"]
418
+ dimensions = ["date"]
444
419
 
445
420
 
446
421
  class SearchAnalyticsKeywordSiteReportByPage(SearchByKeyword):
@@ -448,36 +423,24 @@ class SearchAnalyticsKeywordSiteReportByPage(SearchByKeyword):
448
423
  dimensions = ["date", "country", "device", "query"]
449
424
  aggregation_type = QueryAggregationType.by_page
450
425
 
451
- def stream_slices(self, sync_mode, cursor_field=None, stream_state=None):
452
- for stream_slice in super(SearchByKeyword, self).stream_slices(sync_mode, cursor_field, stream_state):
453
- yield stream_slice
454
426
 
455
- def request_body_json(
456
- self,
457
- stream_state: Mapping[str, Any] = None,
458
- stream_slice: Mapping[str, Any] = None,
459
- next_page_token: Mapping[str, Any] = None,
460
- ) -> Optional[Union[Dict[str, Any], str]]:
461
- return super(SearchByKeyword, self).request_body_json(stream_state, stream_slice, next_page_token)
427
+ class SearchAnalyticsKeywordSiteReportByPageMinimalDimensions(SearchByKeyword):
428
+ primary_key = ["site_url", "date", "country", "device", "query", "search_type"]
429
+ dimensions = ["date"]
430
+ aggregation_type = QueryAggregationType.by_page
431
+
462
432
 
463
433
  class SearchAnalyticsKeywordSiteReportBySite(SearchByKeyword):
464
434
  primary_key = ["site_url", "date", "country", "device", "query", "search_type"]
465
435
  dimensions = ["date", "country", "device", "query"]
466
436
  aggregation_type = QueryAggregationType.by_property
467
- def stream_slices(
468
- self, sync_mode: SyncMode, cursor_field: List[str] = None, stream_state: Mapping[str, Any] = None
469
- ) -> Iterable[Optional[Mapping[str, Any]]]:
470
- return super(SearchByKeyword, self).stream_slices(sync_mode, cursor_field, stream_state)
471
-
472
- def request_body_json(
473
- self,
474
- stream_state: Mapping[str, Any] = None,
475
- stream_slice: Mapping[str, Any] = None,
476
- next_page_token: Mapping[str, Any] = None,
477
- ) -> Optional[Union[Dict[str, Any], str]]:
478
- return super(SearchByKeyword, self).request_body_json(stream_state, stream_slice, next_page_token)
479
437
 
480
438
 
439
+ class SearchAnalyticsKeywordSiteReportBySiteMinimalDimensions(SearchByKeyword):
440
+ primary_key = ["site_url", "date", "country", "device", "query", "search_type"]
441
+ dimensions = ["date"]
442
+ aggregation_type = QueryAggregationType.by_property
443
+
481
444
 
482
445
  class SearchAnalyticsSiteReportBySite(SearchAnalytics):
483
446
  primary_key = ["site_url", "date", "country", "device", "search_type"]