@gscdump/contracts 2.0.5 → 2.1.0

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.
@@ -15,12 +15,12 @@ declare const GSCDUMP_V1_ANALYTICS_DIMENSIONS: readonly ["page", "query", "query
15
15
  declare function createGscdumpV1BrowserSchemas(realtimeSchemas?: RealtimeV1Schemas): {
16
16
  analyticsRowsRequest: z.ZodObject<{
17
17
  dimensions: z.ZodArray<z.ZodEnum<{
18
- date: "date";
19
18
  page: "page";
20
19
  query: "query";
21
20
  queryCanonical: "queryCanonical";
22
21
  country: "country";
23
22
  device: "device";
23
+ date: "date";
24
24
  searchAppearance: "searchAppearance";
25
25
  hour: "hour";
26
26
  }>>;
@@ -736,12 +736,12 @@ declare function createGscdumpV1Protocol(): {
736
736
  googleNews: "googleNews";
737
737
  }>>;
738
738
  dimensions: z.ZodArray<z.ZodEnum<{
739
- date: "date";
740
739
  page: "page";
741
740
  query: "query";
742
741
  queryCanonical: "queryCanonical";
743
742
  country: "country";
744
743
  device: "device";
744
+ date: "date";
745
745
  searchAppearance: "searchAppearance";
746
746
  hour: "hour";
747
747
  }>>;
@@ -756,12 +756,12 @@ declare function createGscdumpV1Protocol(): {
756
756
  googleNews: "googleNews";
757
757
  }>>;
758
758
  dimensions: z.ZodArray<z.ZodEnum<{
759
- date: "date";
760
759
  page: "page";
761
760
  query: "query";
762
761
  queryCanonical: "queryCanonical";
763
762
  country: "country";
764
763
  device: "device";
764
+ date: "date";
765
765
  searchAppearance: "searchAppearance";
766
766
  hour: "hour";
767
767
  }>>;
@@ -893,12 +893,12 @@ declare function createGscdumpV1Protocol(): {
893
893
  googleNews: "googleNews";
894
894
  }>>;
895
895
  dimensions: z.ZodArray<z.ZodEnum<{
896
- date: "date";
897
896
  page: "page";
898
897
  query: "query";
899
898
  queryCanonical: "queryCanonical";
900
899
  country: "country";
901
900
  device: "device";
901
+ date: "date";
902
902
  searchAppearance: "searchAppearance";
903
903
  hour: "hour";
904
904
  }>>;
@@ -913,12 +913,12 @@ declare function createGscdumpV1Protocol(): {
913
913
  googleNews: "googleNews";
914
914
  }>>;
915
915
  dimensions: z.ZodArray<z.ZodEnum<{
916
- date: "date";
917
916
  page: "page";
918
917
  query: "query";
919
918
  queryCanonical: "queryCanonical";
920
919
  country: "country";
921
920
  device: "device";
921
+ date: "date";
922
922
  searchAppearance: "searchAppearance";
923
923
  hour: "hour";
924
924
  }>>;
@@ -1021,12 +1021,12 @@ declare function createGscdumpV1Protocol(): {
1021
1021
  }, z.core.$strip>>;
1022
1022
  analyticsRowsRequest: z.ZodObject<{
1023
1023
  dimensions: z.ZodArray<z.ZodEnum<{
1024
- date: "date";
1025
1024
  page: "page";
1026
1025
  query: "query";
1027
1026
  queryCanonical: "queryCanonical";
1028
1027
  country: "country";
1029
1028
  device: "device";
1029
+ date: "date";
1030
1030
  searchAppearance: "searchAppearance";
1031
1031
  hour: "hour";
1032
1032
  }>>;
@@ -1841,36 +1841,6 @@ declare function createGscdumpV1Protocol(): {
1841
1841
  readonly version: z.ZodLiteral<"1.0">;
1842
1842
  }, z.core.$strip>;
1843
1843
  }, z.core.$strip>>;
1844
- keywordEnrichmentRequest: z.ZodObject<{
1845
- keywords: z.ZodArray<z.ZodString>;
1846
- }, z.core.$strict>;
1847
- keywordEnrichmentResponse: CompatibleResponseSchema<z.ZodObject<{
1848
- data: z.ZodObject<{
1849
- readonly metrics: z.ZodRecord<z.ZodString, z.ZodObject<{
1850
- difficulty: z.ZodNullable<z.ZodNumber>;
1851
- searchVolume: z.ZodNullable<z.ZodNumber>;
1852
- cpc: z.ZodNullable<z.ZodNumber>;
1853
- }, z.core.$loose>>;
1854
- }, z.core.$strip>;
1855
- meta: z.ZodObject<{
1856
- readonly requestId: z.ZodString;
1857
- readonly surface: z.ZodLiteral<"partner">;
1858
- readonly version: z.ZodLiteral<"1.0">;
1859
- }, z.core.$strip>;
1860
- }, z.core.$strip>, z.ZodObject<{
1861
- data: z.ZodObject<{
1862
- readonly metrics: z.ZodRecord<z.ZodString, z.ZodObject<{
1863
- difficulty: z.ZodNullable<z.ZodNumber>;
1864
- searchVolume: z.ZodNullable<z.ZodNumber>;
1865
- cpc: z.ZodNullable<z.ZodNumber>;
1866
- }, z.core.$loose>>;
1867
- }, z.core.$strip>;
1868
- meta: z.ZodObject<{
1869
- readonly requestId: z.ZodString;
1870
- readonly surface: z.ZodLiteral<"partner">;
1871
- readonly version: z.ZodLiteral<"1.0">;
1872
- }, z.core.$strip>;
1873
- }, z.core.$strip>>;
1874
1844
  lifecycleResponse: CompatibleResponseSchema<z.ZodObject<{
1875
1845
  data: z.ZodObject<{
1876
1846
  readonly userId: z.ZodString;
@@ -9760,7 +9730,7 @@ declare function createGscdumpV1Protocol(): {
9760
9730
  };
9761
9731
  readonly request: {
9762
9732
  readonly params: z.ZodObject<{
9763
- teamId: z.ZodString;
9733
+ teamId: z.ZodUnion<readonly [z.ZodString, z.ZodUUID]>;
9764
9734
  }, z.core.$strict>;
9765
9735
  readonly query: null;
9766
9736
  readonly headers: z.ZodObject<{
@@ -9889,7 +9859,7 @@ declare function createGscdumpV1Protocol(): {
9889
9859
  };
9890
9860
  readonly request: {
9891
9861
  readonly params: z.ZodObject<{
9892
- teamId: z.ZodString;
9862
+ teamId: z.ZodUnion<readonly [z.ZodString, z.ZodUUID]>;
9893
9863
  }, z.core.$strict>;
9894
9864
  readonly query: null;
9895
9865
  readonly headers: z.ZodObject<{
@@ -10010,7 +9980,7 @@ declare function createGscdumpV1Protocol(): {
10010
9980
  };
10011
9981
  readonly request: {
10012
9982
  readonly params: z.ZodObject<{
10013
- teamId: z.ZodString;
9983
+ teamId: z.ZodUnion<readonly [z.ZodString, z.ZodUUID]>;
10014
9984
  }, z.core.$strict>;
10015
9985
  readonly query: null;
10016
9986
  readonly headers: z.ZodObject<{
@@ -10152,7 +10122,7 @@ declare function createGscdumpV1Protocol(): {
10152
10122
  };
10153
10123
  readonly request: {
10154
10124
  readonly params: z.ZodObject<{
10155
- teamId: z.ZodString;
10125
+ teamId: z.ZodUnion<readonly [z.ZodString, z.ZodUUID]>;
10156
10126
  }, z.core.$strict>;
10157
10127
  readonly query: null;
10158
10128
  readonly headers: z.ZodObject<{
@@ -10297,7 +10267,7 @@ declare function createGscdumpV1Protocol(): {
10297
10267
  };
10298
10268
  readonly request: {
10299
10269
  readonly params: z.ZodObject<{
10300
- teamId: z.ZodString;
10270
+ teamId: z.ZodUnion<readonly [z.ZodString, z.ZodUUID]>;
10301
10271
  userId: z.ZodString;
10302
10272
  }, z.core.$strict>;
10303
10273
  readonly query: null;
@@ -10446,7 +10416,7 @@ declare function createGscdumpV1Protocol(): {
10446
10416
  };
10447
10417
  readonly request: {
10448
10418
  readonly params: z.ZodObject<{
10449
- teamId: z.ZodString;
10419
+ teamId: z.ZodUnion<readonly [z.ZodString, z.ZodUUID]>;
10450
10420
  userId: z.ZodString;
10451
10421
  }, z.core.$strict>;
10452
10422
  readonly query: null;
@@ -10704,7 +10674,7 @@ declare function createGscdumpV1Protocol(): {
10704
10674
  };
10705
10675
  readonly request: {
10706
10676
  readonly params: z.ZodObject<{
10707
- teamId: z.ZodString;
10677
+ teamId: z.ZodUnion<readonly [z.ZodString, z.ZodUUID]>;
10708
10678
  }, z.core.$strict>;
10709
10679
  readonly query: null;
10710
10680
  readonly headers: z.ZodObject<{
@@ -10846,7 +10816,7 @@ declare function createGscdumpV1Protocol(): {
10846
10816
  };
10847
10817
  readonly request: {
10848
10818
  readonly params: z.ZodObject<{
10849
- teamId: z.ZodString;
10819
+ teamId: z.ZodUnion<readonly [z.ZodString, z.ZodUUID]>;
10850
10820
  }, z.core.$strict>;
10851
10821
  readonly query: null;
10852
10822
  readonly headers: z.ZodObject<{
@@ -11578,275 +11548,6 @@ declare function createGscdumpV1Protocol(): {
11578
11548
  };
11579
11549
  };
11580
11550
  };
11581
- readonly queryCrossSource: {
11582
- readonly id: "partner.sites.cross.source.query";
11583
- readonly method: "POST";
11584
- readonly path: "/sites/{siteId}/cross-source";
11585
- readonly visibility: "public";
11586
- readonly semantics: {
11587
- readonly kind: "query";
11588
- readonly sideEffects: "none";
11589
- readonly idempotent: true;
11590
- readonly retry: "idempotent";
11591
- readonly readConsistency: "primary";
11592
- };
11593
- readonly auth: {
11594
- readonly credentials: readonly ["partner_key"];
11595
- readonly scopes: readonly ["analytics:read"];
11596
- readonly ownership: readonly [{
11597
- readonly credential: "partner_key";
11598
- readonly rule: "authorized_site";
11599
- }];
11600
- };
11601
- readonly request: {
11602
- readonly params: z.ZodObject<{
11603
- siteId: z.ZodString;
11604
- }, z.core.$strict>;
11605
- readonly query: null;
11606
- readonly headers: z.ZodObject<{
11607
- 'x-request-id': z.ZodOptional<z.ZodString>;
11608
- }, z.core.$strict>;
11609
- readonly body: z.ZodObject<{
11610
- queryKey: z.ZodEnum<{
11611
- "crawl-error-losing-impressions": "crawl-error-losing-impressions";
11612
- "declining-clicks-poor-lcp": "declining-clicks-poor-lcp";
11613
- "striking-distance-slow-pages": "striking-distance-slow-pages";
11614
- "top-impressions-low-performance": "top-impressions-low-performance";
11615
- }>;
11616
- rangeDays: z.ZodOptional<z.ZodNumber>;
11617
- limit: z.ZodOptional<z.ZodNumber>;
11618
- }, z.core.$strict>;
11619
- };
11620
- readonly responses: {
11621
- readonly 200: CompatibleResponseSchema<z.ZodObject<{
11622
- data: z.ZodObject<{
11623
- readonly reason: z.ZodOptional<z.ZodString>;
11624
- readonly sources: z.ZodArray<z.ZodString>;
11625
- readonly rows: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
11626
- }, z.core.$strip>;
11627
- meta: z.ZodObject<{
11628
- readonly requestId: z.ZodString;
11629
- readonly surface: z.ZodLiteral<"partner">;
11630
- readonly version: z.ZodLiteral<"1.0">;
11631
- }, z.core.$strip>;
11632
- }, z.core.$strip>, z.ZodObject<{
11633
- data: z.ZodObject<{
11634
- readonly reason: z.ZodOptional<z.ZodString>;
11635
- readonly sources: z.ZodArray<z.ZodString>;
11636
- readonly rows: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
11637
- }, z.core.$strip>;
11638
- meta: z.ZodObject<{
11639
- readonly requestId: z.ZodString;
11640
- readonly surface: z.ZodLiteral<"partner">;
11641
- readonly version: z.ZodLiteral<"1.0">;
11642
- }, z.core.$strip>;
11643
- }, z.core.$strip>>;
11644
- };
11645
- readonly errors: readonly ["invalid_request", "unauthorized", "forbidden", "site_not_found", "rate_limited", "internal_error", "contract_violation"];
11646
- readonly errorResponse: CompatibleResponseSchema<z.ZodObject<{
11647
- readonly error: z.ZodObject<{
11648
- code: z.ZodEnum<{
11649
- internal_error: "internal_error";
11650
- invalid_request: "invalid_request";
11651
- unauthorized: "unauthorized";
11652
- forbidden: "forbidden";
11653
- site_not_found: "site_not_found";
11654
- rate_limited: "rate_limited";
11655
- contract_violation: "contract_violation";
11656
- }>;
11657
- message: z.ZodString;
11658
- requestId: z.ZodString;
11659
- retryable: z.ZodBoolean;
11660
- details: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
11661
- }, z.core.$strict>;
11662
- }, z.core.$strip>, z.ZodObject<{
11663
- readonly error: z.ZodObject<{
11664
- code: z.ZodEnum<{
11665
- internal_error: "internal_error";
11666
- invalid_request: "invalid_request";
11667
- unauthorized: "unauthorized";
11668
- forbidden: "forbidden";
11669
- site_not_found: "site_not_found";
11670
- rate_limited: "rate_limited";
11671
- contract_violation: "contract_violation";
11672
- }>;
11673
- message: z.ZodString;
11674
- requestId: z.ZodString;
11675
- retryable: z.ZodBoolean;
11676
- details: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
11677
- }, z.core.$loose>;
11678
- }, z.core.$strip>>;
11679
- readonly resources: {
11680
- readonly reads: readonly [{
11681
- readonly type: "site.analytics";
11682
- readonly idFrom: "params.siteId";
11683
- }];
11684
- readonly changes: readonly [];
11685
- };
11686
- readonly lifecycle: {
11687
- readonly introduced: "1.3.0";
11688
- };
11689
- readonly docs: {
11690
- readonly summary: "Query cross-source analysis";
11691
- readonly description: "Runs one predefined cross-source query joining crawl, CWV, and GSC signals for a site.";
11692
- readonly tags: readonly ["Analytics"];
11693
- readonly examples: {
11694
- readonly request: {
11695
- readonly params: {
11696
- readonly siteId: "s_01";
11697
- };
11698
- readonly body: {
11699
- readonly queryKey: "crawl-error-losing-impressions";
11700
- readonly rangeDays: 28;
11701
- readonly limit: 50;
11702
- };
11703
- };
11704
- readonly response: {
11705
- readonly data: {
11706
- readonly sources: readonly ["crawl", "gsc"];
11707
- readonly rows: readonly [];
11708
- };
11709
- readonly meta: {
11710
- readonly requestId: "req_01";
11711
- readonly surface: "partner";
11712
- readonly version: "1.0";
11713
- };
11714
- };
11715
- };
11716
- };
11717
- };
11718
- readonly enrichKeywords: {
11719
- readonly id: "partner.keywords.enrich.query";
11720
- readonly method: "POST";
11721
- readonly path: "/keywords/enrich";
11722
- readonly visibility: "public";
11723
- readonly semantics: {
11724
- readonly kind: "query";
11725
- readonly sideEffects: "none";
11726
- readonly idempotent: true;
11727
- readonly retry: "idempotent";
11728
- readonly readConsistency: "primary";
11729
- };
11730
- readonly auth: {
11731
- readonly credentials: readonly ["user_key", "partner_key"];
11732
- readonly scopes: readonly ["analytics:read"];
11733
- readonly ownership: readonly [{
11734
- readonly credential: "user_key";
11735
- readonly rule: "self";
11736
- }, {
11737
- readonly credential: "partner_key";
11738
- readonly rule: "partner_tenant";
11739
- }];
11740
- };
11741
- readonly request: {
11742
- readonly params: null;
11743
- readonly query: null;
11744
- readonly headers: z.ZodObject<{
11745
- 'x-request-id': z.ZodOptional<z.ZodString>;
11746
- }, z.core.$strict>;
11747
- readonly body: z.ZodObject<{
11748
- keywords: z.ZodArray<z.ZodString>;
11749
- }, z.core.$strict>;
11750
- };
11751
- readonly responses: {
11752
- readonly 200: CompatibleResponseSchema<z.ZodObject<{
11753
- data: z.ZodObject<{
11754
- readonly metrics: z.ZodRecord<z.ZodString, z.ZodObject<{
11755
- difficulty: z.ZodNullable<z.ZodNumber>;
11756
- searchVolume: z.ZodNullable<z.ZodNumber>;
11757
- cpc: z.ZodNullable<z.ZodNumber>;
11758
- }, z.core.$loose>>;
11759
- }, z.core.$strip>;
11760
- meta: z.ZodObject<{
11761
- readonly requestId: z.ZodString;
11762
- readonly surface: z.ZodLiteral<"partner">;
11763
- readonly version: z.ZodLiteral<"1.0">;
11764
- }, z.core.$strip>;
11765
- }, z.core.$strip>, z.ZodObject<{
11766
- data: z.ZodObject<{
11767
- readonly metrics: z.ZodRecord<z.ZodString, z.ZodObject<{
11768
- difficulty: z.ZodNullable<z.ZodNumber>;
11769
- searchVolume: z.ZodNullable<z.ZodNumber>;
11770
- cpc: z.ZodNullable<z.ZodNumber>;
11771
- }, z.core.$loose>>;
11772
- }, z.core.$strip>;
11773
- meta: z.ZodObject<{
11774
- readonly requestId: z.ZodString;
11775
- readonly surface: z.ZodLiteral<"partner">;
11776
- readonly version: z.ZodLiteral<"1.0">;
11777
- }, z.core.$strip>;
11778
- }, z.core.$strip>>;
11779
- };
11780
- readonly errors: readonly ["invalid_request", "unauthorized", "forbidden", "user_not_found", "rate_limited", "internal_error", "contract_violation"];
11781
- readonly errorResponse: CompatibleResponseSchema<z.ZodObject<{
11782
- readonly error: z.ZodObject<{
11783
- code: z.ZodEnum<{
11784
- internal_error: "internal_error";
11785
- invalid_request: "invalid_request";
11786
- unauthorized: "unauthorized";
11787
- forbidden: "forbidden";
11788
- user_not_found: "user_not_found";
11789
- rate_limited: "rate_limited";
11790
- contract_violation: "contract_violation";
11791
- }>;
11792
- message: z.ZodString;
11793
- requestId: z.ZodString;
11794
- retryable: z.ZodBoolean;
11795
- details: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
11796
- }, z.core.$strict>;
11797
- }, z.core.$strip>, z.ZodObject<{
11798
- readonly error: z.ZodObject<{
11799
- code: z.ZodEnum<{
11800
- internal_error: "internal_error";
11801
- invalid_request: "invalid_request";
11802
- unauthorized: "unauthorized";
11803
- forbidden: "forbidden";
11804
- user_not_found: "user_not_found";
11805
- rate_limited: "rate_limited";
11806
- contract_violation: "contract_violation";
11807
- }>;
11808
- message: z.ZodString;
11809
- requestId: z.ZodString;
11810
- retryable: z.ZodBoolean;
11811
- details: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
11812
- }, z.core.$loose>;
11813
- }, z.core.$strip>>;
11814
- readonly resources: {
11815
- readonly reads: readonly [];
11816
- readonly changes: readonly [];
11817
- };
11818
- readonly lifecycle: {
11819
- readonly introduced: "1.3.0";
11820
- };
11821
- readonly docs: {
11822
- readonly summary: "Enrich keywords with metrics";
11823
- readonly description: "Returns difficulty, search volume, and CPC estimates for up to 500 keywords.";
11824
- readonly tags: readonly ["Analytics"];
11825
- readonly examples: {
11826
- readonly request: {
11827
- readonly body: {
11828
- readonly keywords: readonly ["nuxt seo"];
11829
- };
11830
- };
11831
- readonly response: {
11832
- readonly data: {
11833
- readonly metrics: {
11834
- readonly 'nuxt seo': {
11835
- readonly difficulty: 40;
11836
- readonly searchVolume: 100;
11837
- readonly cpc: 1.2;
11838
- };
11839
- };
11840
- };
11841
- readonly meta: {
11842
- readonly requestId: "req_01";
11843
- readonly surface: "partner";
11844
- readonly version: "1.0";
11845
- };
11846
- };
11847
- };
11848
- };
11849
- };
11850
11551
  }>;
11851
11552
  analytics: HttpV1Surface<{
11852
11553
  readonly queryRows: {
@@ -11882,12 +11583,12 @@ declare function createGscdumpV1Protocol(): {
11882
11583
  }, z.core.$strict>;
11883
11584
  readonly body: z.ZodObject<{
11884
11585
  dimensions: z.ZodArray<z.ZodEnum<{
11885
- date: "date";
11886
11586
  page: "page";
11887
11587
  query: "query";
11888
11588
  queryCanonical: "queryCanonical";
11889
11589
  country: "country";
11890
11590
  device: "device";
11591
+ date: "date";
11891
11592
  searchAppearance: "searchAppearance";
11892
11593
  hour: "hour";
11893
11594
  }>>;
@@ -12085,12 +11786,12 @@ declare function createGscdumpV1Protocol(): {
12085
11786
  googleNews: "googleNews";
12086
11787
  }>>;
12087
11788
  dimensions: z.ZodArray<z.ZodEnum<{
12088
- date: "date";
12089
11789
  page: "page";
12090
11790
  query: "query";
12091
11791
  queryCanonical: "queryCanonical";
12092
11792
  country: "country";
12093
11793
  device: "device";
11794
+ date: "date";
12094
11795
  searchAppearance: "searchAppearance";
12095
11796
  hour: "hour";
12096
11797
  }>>;
@@ -12105,12 +11806,12 @@ declare function createGscdumpV1Protocol(): {
12105
11806
  googleNews: "googleNews";
12106
11807
  }>>;
12107
11808
  dimensions: z.ZodArray<z.ZodEnum<{
12108
- date: "date";
12109
11809
  page: "page";
12110
11810
  query: "query";
12111
11811
  queryCanonical: "queryCanonical";
12112
11812
  country: "country";
12113
11813
  device: "device";
11814
+ date: "date";
12114
11815
  searchAppearance: "searchAppearance";
12115
11816
  hour: "hour";
12116
11817
  }>>;
@@ -12346,12 +12047,12 @@ declare function createGscdumpV1Protocol(): {
12346
12047
  googleNews: "googleNews";
12347
12048
  }>>;
12348
12049
  dimensions: z.ZodArray<z.ZodEnum<{
12349
- date: "date";
12350
12050
  page: "page";
12351
12051
  query: "query";
12352
12052
  queryCanonical: "queryCanonical";
12353
12053
  country: "country";
12354
12054
  device: "device";
12055
+ date: "date";
12355
12056
  searchAppearance: "searchAppearance";
12356
12057
  hour: "hour";
12357
12058
  }>>;
@@ -12366,12 +12067,12 @@ declare function createGscdumpV1Protocol(): {
12366
12067
  googleNews: "googleNews";
12367
12068
  }>>;
12368
12069
  dimensions: z.ZodArray<z.ZodEnum<{
12369
- date: "date";
12370
12070
  page: "page";
12371
12071
  query: "query";
12372
12072
  queryCanonical: "queryCanonical";
12373
12073
  country: "country";
12374
12074
  device: "device";
12075
+ date: "date";
12375
12076
  searchAppearance: "searchAppearance";
12376
12077
  hour: "hour";
12377
12078
  }>>;
@@ -30,6 +30,7 @@ function createGscdumpV1Protocol() {
30
30
  "analytics",
31
31
  "realtime"
32
32
  ]);
33
+ const partnerTeamPathId = z.union([realtimeSchemas.publicTeamId, z.uuid()]);
33
34
  const responseMeta = defineResponseObject({
34
35
  requestId: realtimeSchemas.publicRequestId,
35
36
  surface: surfaceSchema,
@@ -52,7 +53,7 @@ function createGscdumpV1Protocol() {
52
53
  });
53
54
  const requestHeaders = z.strictObject({ "x-request-id": realtimeSchemas.publicRequestId.optional() });
54
55
  const errorEnvelope = errorEnvelopeSchemas(HTTP_V1_ERROR_CODES, realtimeSchemas.publicRequestId);
55
- const { analyticsRowsRequest, analyticsRowsResponse, keywordEnrichmentRequest, keywordEnrichmentResponse, lifecycleResponse } = browserSchemas;
56
+ const { analyticsRowsRequest, analyticsRowsResponse, lifecycleResponse } = browserSchemas;
56
57
  const dimensions = GSCDUMP_V1_ANALYTICS_DIMENSIONS;
57
58
  const analyticsMeta = defineResponseObject({
58
59
  requestId: realtimeSchemas.publicRequestId,
@@ -561,21 +562,6 @@ function createGscdumpV1Protocol() {
561
562
  verified: z.literal(true),
562
563
  owners: z.array(z.string()).optional()
563
564
  }), partnerResponseMeta);
564
- const crossSourceRequest = z.strictObject({
565
- queryKey: z.enum([
566
- "crawl-error-losing-impressions",
567
- "declining-clicks-poor-lcp",
568
- "striking-distance-slow-pages",
569
- "top-impressions-low-performance"
570
- ]),
571
- rangeDays: z.number().int().positive().max(180).optional(),
572
- limit: z.number().int().positive().max(500).optional()
573
- });
574
- const crossSourceResponse = defineSuccessResponse(defineResponseObject({
575
- reason: z.string().optional(),
576
- sources: z.array(z.string()),
577
- rows: z.array(z.record(z.string(), z.json()))
578
- }), partnerResponseMeta);
579
565
  const responseStreamHead = defineResponseObject({
580
566
  streamId: realtimeSchemas.streamId,
581
567
  sequence: realtimeSchemas.sequence
@@ -3024,7 +3010,7 @@ function createGscdumpV1Protocol() {
3024
3010
  }]
3025
3011
  },
3026
3012
  request: {
3027
- params: z.strictObject({ teamId: realtimeSchemas.publicTeamId }),
3013
+ params: z.strictObject({ teamId: partnerTeamPathId }),
3028
3014
  query: null,
3029
3015
  headers: requestHeaders,
3030
3016
  body: renameTeamRequest
@@ -3087,7 +3073,7 @@ function createGscdumpV1Protocol() {
3087
3073
  }]
3088
3074
  },
3089
3075
  request: {
3090
- params: z.strictObject({ teamId: realtimeSchemas.publicTeamId }),
3076
+ params: z.strictObject({ teamId: partnerTeamPathId }),
3091
3077
  query: null,
3092
3078
  headers: requestHeaders,
3093
3079
  body: null
@@ -3144,7 +3130,7 @@ function createGscdumpV1Protocol() {
3144
3130
  }]
3145
3131
  },
3146
3132
  request: {
3147
- params: z.strictObject({ teamId: realtimeSchemas.publicTeamId }),
3133
+ params: z.strictObject({ teamId: partnerTeamPathId }),
3148
3134
  query: null,
3149
3135
  headers: requestHeaders,
3150
3136
  body: null
@@ -3198,7 +3184,7 @@ function createGscdumpV1Protocol() {
3198
3184
  }]
3199
3185
  },
3200
3186
  request: {
3201
- params: z.strictObject({ teamId: realtimeSchemas.publicTeamId }),
3187
+ params: z.strictObject({ teamId: partnerTeamPathId }),
3202
3188
  query: null,
3203
3189
  headers: requestHeaders,
3204
3190
  body: addTeamMemberRequest
@@ -3265,7 +3251,7 @@ function createGscdumpV1Protocol() {
3265
3251
  },
3266
3252
  request: {
3267
3253
  params: z.strictObject({
3268
- teamId: realtimeSchemas.publicTeamId,
3254
+ teamId: partnerTeamPathId,
3269
3255
  userId: realtimeSchemas.publicUserId
3270
3256
  }),
3271
3257
  query: null,
@@ -3340,7 +3326,7 @@ function createGscdumpV1Protocol() {
3340
3326
  },
3341
3327
  request: {
3342
3328
  params: z.strictObject({
3343
- teamId: realtimeSchemas.publicTeamId,
3329
+ teamId: partnerTeamPathId,
3344
3330
  userId: realtimeSchemas.publicUserId
3345
3331
  }),
3346
3332
  query: null,
@@ -3471,7 +3457,7 @@ function createGscdumpV1Protocol() {
3471
3457
  }]
3472
3458
  },
3473
3459
  request: {
3474
- params: z.strictObject({ teamId: realtimeSchemas.publicTeamId }),
3460
+ params: z.strictObject({ teamId: partnerTeamPathId }),
3475
3461
  query: null,
3476
3462
  headers: requestHeaders,
3477
3463
  body: null
@@ -3535,7 +3521,7 @@ function createGscdumpV1Protocol() {
3535
3521
  }]
3536
3522
  },
3537
3523
  request: {
3538
- params: z.strictObject({ teamId: realtimeSchemas.publicTeamId }),
3524
+ params: z.strictObject({ teamId: partnerTeamPathId }),
3539
3525
  query: null,
3540
3526
  headers: requestHeaders,
3541
3527
  body: bindTeamCatalogRequest
@@ -3868,128 +3854,6 @@ function createGscdumpV1Protocol() {
3868
3854
  }
3869
3855
  }
3870
3856
  }
3871
- }),
3872
- queryCrossSource: defineHttpOperation({
3873
- id: "partner.sites.cross.source.query",
3874
- method: "POST",
3875
- path: "/sites/{siteId}/cross-source",
3876
- visibility: "public",
3877
- semantics: {
3878
- kind: "query",
3879
- sideEffects: "none",
3880
- idempotent: true,
3881
- retry: "idempotent",
3882
- readConsistency: "primary"
3883
- },
3884
- auth: {
3885
- credentials: ["partner_key"],
3886
- scopes: ["analytics:read"],
3887
- ownership: [{
3888
- credential: "partner_key",
3889
- rule: "authorized_site"
3890
- }]
3891
- },
3892
- request: {
3893
- params: z.strictObject({ siteId: realtimeSchemas.publicSiteId }),
3894
- query: null,
3895
- headers: requestHeaders,
3896
- body: crossSourceRequest
3897
- },
3898
- responses: { 200: crossSourceResponse },
3899
- errors: partnerSiteErrors,
3900
- errorResponse: errorEnvelopeSchemas(partnerSiteErrors, realtimeSchemas.publicRequestId),
3901
- resources: {
3902
- reads: [{
3903
- type: "site.analytics",
3904
- idFrom: "params.siteId"
3905
- }],
3906
- changes: []
3907
- },
3908
- lifecycle: { introduced: "1.3.0" },
3909
- docs: {
3910
- summary: "Query cross-source analysis",
3911
- description: "Runs one predefined cross-source query joining crawl, CWV, and GSC signals for a site.",
3912
- tags: ["Analytics"],
3913
- examples: {
3914
- request: {
3915
- params: { siteId: "s_01" },
3916
- body: {
3917
- queryKey: "crawl-error-losing-impressions",
3918
- rangeDays: 28,
3919
- limit: 50
3920
- }
3921
- },
3922
- response: {
3923
- data: {
3924
- sources: ["crawl", "gsc"],
3925
- rows: []
3926
- },
3927
- meta: {
3928
- requestId: "req_01",
3929
- surface: "partner",
3930
- version: "1.0"
3931
- }
3932
- }
3933
- }
3934
- }
3935
- }),
3936
- enrichKeywords: defineHttpOperation({
3937
- id: "partner.keywords.enrich.query",
3938
- method: "POST",
3939
- path: "/keywords/enrich",
3940
- visibility: "public",
3941
- semantics: {
3942
- kind: "query",
3943
- sideEffects: "none",
3944
- idempotent: true,
3945
- retry: "idempotent",
3946
- readConsistency: "primary"
3947
- },
3948
- auth: {
3949
- credentials: ["user_key", "partner_key"],
3950
- scopes: ["analytics:read"],
3951
- ownership: [{
3952
- credential: "user_key",
3953
- rule: "self"
3954
- }, {
3955
- credential: "partner_key",
3956
- rule: "partner_tenant"
3957
- }]
3958
- },
3959
- request: {
3960
- params: null,
3961
- query: null,
3962
- headers: requestHeaders,
3963
- body: keywordEnrichmentRequest
3964
- },
3965
- responses: { 200: keywordEnrichmentResponse },
3966
- errors: partnerUserErrors,
3967
- errorResponse: errorEnvelopeSchemas(partnerUserErrors, realtimeSchemas.publicRequestId),
3968
- resources: {
3969
- reads: [],
3970
- changes: []
3971
- },
3972
- lifecycle: { introduced: "1.3.0" },
3973
- docs: {
3974
- summary: "Enrich keywords with metrics",
3975
- description: "Returns difficulty, search volume, and CPC estimates for up to 500 keywords.",
3976
- tags: ["Analytics"],
3977
- examples: {
3978
- request: { body: { keywords: ["nuxt seo"] } },
3979
- response: {
3980
- data: { metrics: { "nuxt seo": {
3981
- difficulty: 40,
3982
- searchVolume: 100,
3983
- cpc: 1.2
3984
- } } },
3985
- meta: {
3986
- requestId: "req_01",
3987
- surface: "partner",
3988
- version: "1.0"
3989
- }
3990
- }
3991
- }
3992
- }
3993
3857
  })
3994
3858
  }
3995
3859
  });
@@ -4404,8 +4268,6 @@ function createGscdumpV1Protocol() {
4404
4268
  indexingTransitionsResponse,
4405
4269
  indexingUrlsQuery,
4406
4270
  indexingUrlsResponse,
4407
- keywordEnrichmentRequest,
4408
- keywordEnrichmentResponse,
4409
4271
  lifecycleResponse,
4410
4272
  registerSiteRequest,
4411
4273
  sitemapChangesQuery,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@gscdump/contracts",
3
3
  "type": "module",
4
- "version": "2.0.5",
4
+ "version": "2.1.0",
5
5
  "description": "Shared gscdump.com API, webhook, realtime, and lifecycle contracts.",
6
6
  "author": {
7
7
  "name": "Harlan Wilton",