@gscdump/sdk 0.22.4 → 0.23.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.
@@ -0,0 +1,25 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __exportAll = (all, no_symbols) => {
6
+ let target = {};
7
+ for (var name in all) __defProp(target, name, {
8
+ get: all[name],
9
+ enumerable: true
10
+ });
11
+ if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
12
+ return target;
13
+ };
14
+ var __copyProps = (to, from, except, desc) => {
15
+ if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
16
+ key = keys[i];
17
+ if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
18
+ get: ((k) => from[k]).bind(null, key),
19
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
20
+ });
21
+ }
22
+ return to;
23
+ };
24
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
25
+ export { __exportAll, __reExport };
@@ -0,0 +1,2 @@
1
+ import * as import_gscdump_query from "gscdump/query";
2
+ export { import_gscdump_query as query_d_exports };
package/dist/index.d.mts CHANGED
@@ -1,5 +1,8 @@
1
+ import { query_d_exports } from "./_chunks/query.mjs";
1
2
  import { AddPartnerTeamMemberParams, AnalyticsClient, AnalyticsClient as AnalyticsClient$1, BackfillRange, BackfillResponse, BindPartnerSiteTeamParams, BuilderState, BulkRegisterPartnerSiteResult, BulkRegisterPartnerSitesParams, BulkRegisterPartnerSitesResponse, CANONICAL_WEBHOOK_EVENTS, CanonicalWebhookEventType, CreatePartnerTeamParams, CreateWebhookEnvelopeOptions, DataDetailOptions, DataQueryOptions, DeletePartnerUserResponse, GscComparisonFilter, GscdumpAnalysisParams, GscdumpAnalysisPreset, GscdumpAnalysisResponse, GscdumpAnalysisSourcesResponse, GscdumpAvailableSite, GscdumpCanonicalMismatchesResponse, GscdumpDataDetailResponse, GscdumpDataResponse, GscdumpDataRow, GscdumpDateRangeParams, GscdumpIndexPercentResponse, GscdumpIndexingDiagnosticsResponse, GscdumpIndexingResponse, GscdumpIndexingUrlStatus, GscdumpIndexingUrlsResponse, GscdumpKeywordSparklinesParams, GscdumpKeywordSparklinesResponse, GscdumpMeta, GscdumpPermissionRecovery, GscdumpQueryTrendParams, GscdumpQueryTrendResponse, GscdumpSiteRegistration, GscdumpSitemap, GscdumpSitemapChangesResponse, GscdumpSitemapHistory, GscdumpSitemapsResponse, GscdumpSyncStatusResponse, GscdumpSyncStatusResponse as GscdumpSyncStatusResponse$1, GscdumpTeamMemberRow, GscdumpTeamRow, GscdumpTopAssociationParams, GscdumpTopAssociationResponse, GscdumpTotals, GscdumpUserRegistration, GscdumpUserSettings, GscdumpUserSite, GscdumpUserSite as GscdumpUserSite$1, GscdumpUserStatus, GscdumpUserTokenUpdate, IndexingUrlsParams, InspectionHistoryResponse, InspectionIndex, PartnerClient, PartnerClient as PartnerClient$1, PartnerLifecycleAccount, PartnerLifecycleResponse, PartnerLifecycleResponse as PartnerLifecycleResponse$1, PartnerLifecycleSite, PartnerLifecycleSite as PartnerLifecycleSite$1, PartnerRealtimeEvent, PartnerRealtimeEvent as PartnerRealtimeEvent$1, PartnerRealtimeEventType, PartnerRealtimeMessage, PartnerRealtimeMessage as PartnerRealtimeMessage$1, PartnerWebhookData, PartnerWebhookHeaders, PartnerWebhookHeaders as PartnerWebhookHeaders$1, RealtimeAuthFailedEvent, RealtimeAuthRequiredMessage, RealtimeConnectedMessage, RealtimeEnrichmentCompleteEvent, RealtimeErrorMessage, RealtimeJobFailedEvent, RealtimeNeedsReauthEvent, RealtimePongMessage, RealtimeSiteAddedEvent, RealtimeSiteRemovedEvent, RealtimeSubscribedMessage, RealtimeSyncCompleteEvent, RealtimeSyncFailedEvent, RealtimeSyncJobCompleteEvent, RealtimeSyncProgressEvent, RealtimeSyncSiteCompleteEvent, RegisterPartnerSiteParams, RegisterPartnerUserParams, RollupEnvelope, UpdatePartnerUserTokensParams, VALID_WEBHOOK_EVENTS, WEBHOOK_CONTRACT_VERSION, WEBHOOK_CONTRACT_VERSION_HEADER, WEBHOOK_DELIVERY_HEADER, WEBHOOK_EVENT_HEADER, WEBHOOK_SIGNATURE_HEADER, WEBHOOK_TIMESTAMP_HEADER, WebhookEnvelope, WebhookEnvelope as WebhookEnvelope$1, WebhookEventType, WhoamiResponse } from "@gscdump/contracts";
2
3
  import { BuilderState as BuilderState$1, Dimension, Metric, SearchType } from "gscdump/query";
4
+ import { ActionSource } from "@gscdump/analysis";
5
+ import { AnalysisTool } from "@gscdump/engine/analysis-types";
3
6
  export * from "@gscdump/contracts";
4
7
  type PartnerFetch = <T = unknown>(request: string, options?: PartnerFetchOptions) => Promise<T>;
5
8
  type PartnerHeaders = HeadersInit | (() => HeadersInit | Promise<HeadersInit>);
@@ -37,6 +40,81 @@ interface AnalyticsClientOptions {
37
40
  validate?: boolean | 'request' | 'response';
38
41
  }
39
42
  declare function createAnalyticsClient(options?: AnalyticsClientOptions): AnalyticsClient$1;
43
+ type GscAnalyzerKind = 'analyzer' | 'semantic' | 'action';
44
+ type GscAnalyzerAccent = 'primary' | 'warning' | 'success' | 'error' | 'neutral';
45
+ interface GscAnalyzerInsightCard {
46
+ icon: string;
47
+ accent: GscAnalyzerAccent;
48
+ description: string;
49
+ summarize: (res: {
50
+ results: unknown[];
51
+ meta: Record<string, unknown>;
52
+ }) => {
53
+ headline: string;
54
+ tagline: string;
55
+ };
56
+ }
57
+ interface GscAnalyzerStatTile {
58
+ label: string;
59
+ value: string | number;
60
+ /** Optional CSS color for the value (e.g. improved/worsened in change-points). */
61
+ valueColor?: string;
62
+ }
63
+ interface GscAnalyzerPanelResult {
64
+ results: unknown[];
65
+ meta: Record<string, unknown>;
66
+ queryMs?: number | null;
67
+ }
68
+ interface GscAnalyzerPanelSpec<TComponent = unknown> {
69
+ /**
70
+ * Body component. Receives `{ rows, meta, range }` as props. Lazy-import
71
+ * to preserve route-level codesplitting.
72
+ *
73
+ * Typed `unknown` in the SDK; consumers can narrow via generic
74
+ * (`GscAnalyzerDefinition<VueComponent>`).
75
+ */
76
+ component: TComponent;
77
+ /** Project a result to the header stat tiles. Empty array = no tiles. */
78
+ summarize?: (res: GscAnalyzerPanelResult) => GscAnalyzerStatTile[];
79
+ /** Italic footer caption explaining the underlying method. */
80
+ caption?: string;
81
+ /**
82
+ * When true, the shell skips its loading/error/empty gating and renders
83
+ * the body component immediately (pipeline panels: action priority, content gap).
84
+ */
85
+ ownsLifecycle?: boolean;
86
+ }
87
+ interface GscAnalyzerCapabilities<TComponent = unknown> {
88
+ /** Opt into the `/insights` curated grid by providing a card config. */
89
+ insightCard?: GscAnalyzerInsightCard;
90
+ /** Opt into `useActionPriority`. The value is the typed `ActionSource` slug. */
91
+ actionPriority?: ActionSource;
92
+ /**
93
+ * Opt into the unified `/analyze` panel renderer. Without this, the tab
94
+ * falls back to the generic table renderer.
95
+ */
96
+ panel?: GscAnalyzerPanelSpec<TComponent>;
97
+ }
98
+ type GscAnalyzerCapability = keyof GscAnalyzerCapabilities;
99
+ interface GscAnalyzerDefinition<TComponent = unknown> {
100
+ /** Stable analyzer id. Must match an `AnalysisTool` slug for built-in analyzers. */
101
+ id: AnalysisTool | (string & {});
102
+ label: string;
103
+ kind: GscAnalyzerKind;
104
+ /** Reads the per-query table; sums silently drop GSC-anonymized impressions. */
105
+ isQueryGrained?: boolean;
106
+ /** Capability opt-ins. Each key gates a downstream consumer. */
107
+ capabilities?: GscAnalyzerCapabilities<TComponent>;
108
+ }
109
+ type GscAnalyzerDefinitionWithCapability<K extends GscAnalyzerCapability, TComponent = unknown> = GscAnalyzerDefinition<TComponent> & {
110
+ capabilities: { [P in K]: NonNullable<GscAnalyzerCapabilities<TComponent>[P]> };
111
+ };
112
+ declare function defineGscAnalyzer<TComponent = unknown>(def: GscAnalyzerDefinition<TComponent>): GscAnalyzerDefinition<TComponent>;
113
+ interface DailyAnonInput {
114
+ impressions: number;
115
+ anonymizedImpressionsPct: number;
116
+ }
117
+ declare function weightedAnonPct(days: readonly DailyAnonInput[] | null | undefined, window?: number): number | null;
40
118
  /** The 10 archetype identifiers. */
41
119
  type QueryArchetype = 'site-daily-timeseries' | 'entity-daily-timeseries' | 'entity-daily-sparkline' | 'top-n-breakdown' | 'single-row-lookup' | 'multi-series-stacked-daily' | 'preset-analyzer' | 'two-dimension-detail' | 'arbitrary-sql' | 'aux-cloud-only';
42
120
  /**
@@ -228,6 +306,28 @@ interface ResolvedArchetypeQuery {
228
306
  builder?: BuilderState$1;
229
307
  executionClass: ArchetypeExecutionClass;
230
308
  }
309
+ declare const COUNTRY_NAMES: Record<string, string>;
310
+ declare const countryName: (code: string) => string;
311
+ declare const CWV_GOOD_LCP = 2500;
312
+ declare const CWV_POOR_LCP = 4000;
313
+ declare const CWV_GOOD_INP = 200;
314
+ declare const CWV_POOR_INP = 500;
315
+ declare const CWV_GOOD_CLS = 0.1;
316
+ declare const CWV_POOR_CLS = 0.25;
317
+ type CwvBucket = 'good' | 'ni' | 'poor';
318
+ declare function cwvBucket(metric: 'lcp' | 'inp' | 'cls', v: number): CwvBucket;
319
+ /** Trim long query strings for table cells / chart tooltips. */
320
+ declare function truncateQuery(q: string, max?: number): string;
321
+ /** Best-effort extract a hostname; returns undefined if the URL is unparseable. */
322
+ declare function siteUrlToHostname(url: string | undefined | null): string | undefined;
323
+ /**
324
+ * Split a title with `"quoted"` segments into highlight runs for inline
325
+ * emphasis (e.g. opportunity cards rendering keywords in a stronger weight).
326
+ */
327
+ declare function splitOpportunityTitle(title: string): Array<{
328
+ text: string;
329
+ highlight: boolean;
330
+ }>;
231
331
  type PartnerErrorKind = 'auth' | 'rate-limit' | 'provisioning' | 'permission' | 'network' | 'validation' | 'not-found' | 'server' | 'unknown';
232
332
  interface PartnerErrorInfo {
233
333
  kind: PartnerErrorKind;
@@ -242,6 +342,216 @@ declare class PartnerApiError extends Error {
242
342
  constructor(info: PartnerErrorInfo);
243
343
  }
244
344
  declare function toPartnerError(error: unknown): PartnerApiError;
345
+ interface GscConsoleUrlOpts {
346
+ /** The GSC property — either `sc-domain:example.com` or a URL-prefix. */
347
+ siteLabel: string;
348
+ /** Optional page to open Performance drilldown for. */
349
+ page?: string;
350
+ /** Optional query filter. */
351
+ query?: string;
352
+ /** Resource: `performance`, `url-inspection`, `sitemaps`, … */
353
+ resource?: 'performance' | 'url-inspection' | 'sitemaps' | 'index';
354
+ }
355
+ declare function gscConsoleUrl(opts: GscConsoleUrlOpts): string;
356
+ /**
357
+ * Google Search Console data is considered "unstable" for this many days from
358
+ * today (PST). Rows within the window may still shift as GSC finalizes clicks/
359
+ * impressions; charts render those points under a dimmed / striped overlay so
360
+ * users don't misread last-day dips as trends.
361
+ */
362
+ declare const GSC_STABLE_LATENCY_DAYS = 3;
363
+ type GscErrorStatus = 'auth-missing' | 'rate-limited' | 'network' | 'error';
364
+ interface GscClassifiedError {
365
+ status: GscErrorStatus;
366
+ /** HTTP status code if the error came from a response, otherwise undefined. */
367
+ code?: number;
368
+ /** Best-effort human message: server-supplied `message`, then `data.message`, then the error's own message. */
369
+ message?: string;
370
+ /** Seconds the server suggested waiting (429 with `retryAfter` payload). */
371
+ retryAfter?: number;
372
+ }
373
+ declare function classifyGscError(e: unknown): GscClassifiedError;
374
+ /**
375
+ * Partner-API BETWEEN filter on the `date` column — the ubiquitous date
376
+ * window every query carries.
377
+ */
378
+ declare function dateFilter(r: {
379
+ start: string;
380
+ end: string;
381
+ }): query_d_exports.Filter<any>;
382
+ /** Partner-API AND combinator — wraps filters in the wire-format `and` group. */
383
+ declare function andFilter(...filters: unknown[]): query_d_exports.Filter<any>;
384
+ type RollingPeriod = '7d' | '28d' | '3m' | '6m' | '12m';
385
+ type CalendarPeriod = 'this-week' | 'this-month' | 'last-month' | 'this-quarter' | 'this-year';
386
+ /**
387
+ * Custom date range from drag-to-zoom.
388
+ * - `custom:CS:CE` - current range only; prev range resolved by compareMode.
389
+ * - `custom:CS:CE:PS:PE` - explicit prev range.
390
+ */
391
+ type CustomPeriod = `custom:${string}:${string}` | `custom:${string}:${string}:${string}:${string}`;
392
+ type Period = RollingPeriod | CalendarPeriod | CustomPeriod;
393
+ type CompareMode = 'previous' | 'year' | 'none';
394
+ interface DateRangeResult {
395
+ start: string;
396
+ end: string;
397
+ prevStart: string;
398
+ prevEnd: string;
399
+ yearStart: string;
400
+ yearEnd: string;
401
+ days: number;
402
+ }
403
+ declare function isCustomPeriod(p: Period | string): p is CustomPeriod;
404
+ declare function parseCustomPeriod(p: Period | string): {
405
+ start: string;
406
+ end: string;
407
+ prevStart?: string;
408
+ prevEnd?: string;
409
+ } | null;
410
+ declare function periodToDateRange(period: Period | string, stableData?: boolean): DateRangeResult;
411
+ declare function periodToDays(period: Period | string): number;
412
+ declare function compareRange(range: DateRangeResult, mode: CompareMode): {
413
+ start: string;
414
+ end: string;
415
+ } | null;
416
+ /**
417
+ * GSC data within the last `GSC_STABLE_LATENCY_DAYS` (PST) is potentially
418
+ * incomplete. Returns the cutoff date (YYYY-MM-DD); compare row dates against
419
+ * this to dim/strike unstable points in charts.
420
+ *
421
+ * Uses YYYY-MM-DD string math directly to avoid UTC/local timezone shifts.
422
+ */
423
+ declare function getGscUnstableCutoffDate(): string;
424
+ type GscColumn = 'clicks' | 'impressions' | 'ctr' | 'position';
425
+ interface GscColumnOption {
426
+ key: GscColumn;
427
+ label: string;
428
+ icon: string;
429
+ color: string;
430
+ }
431
+ interface PeriodPreset {
432
+ value: Period;
433
+ label: string;
434
+ shortLabel: string;
435
+ group: 'rolling' | 'calendar';
436
+ }
437
+ declare const PERIOD_PRESETS: PeriodPreset[];
438
+ declare const COMPARE_OPTIONS: {
439
+ value: CompareMode;
440
+ label: string;
441
+ description: string;
442
+ }[];
443
+ declare const GSC_PERIOD_OPTIONS: {
444
+ label: string;
445
+ value: Period;
446
+ longLabel: string;
447
+ }[];
448
+ declare const GSC_PERIOD_OPTIONS_LONG: {
449
+ label: string;
450
+ value: Period;
451
+ }[];
452
+ declare const GSC_COLUMN_OPTIONS: GscColumnOption[];
453
+ interface RawDailyRow {
454
+ date: string;
455
+ clicks: number;
456
+ impressions: number;
457
+ sum_position?: number;
458
+ position?: number;
459
+ }
460
+ interface CanonicalDailyRow {
461
+ date: string;
462
+ clicks: number;
463
+ impressions: number;
464
+ sum_position: number;
465
+ }
466
+ interface GscRowTotals {
467
+ clicks: number;
468
+ impressions: number;
469
+ ctr: number;
470
+ position: number;
471
+ }
472
+ interface GscDailySummary {
473
+ daily: CanonicalDailyRow[];
474
+ totals: GscRowTotals;
475
+ chartData: Array<{
476
+ date: string;
477
+ clicks: number;
478
+ impressions: number;
479
+ }>;
480
+ }
481
+ /** Fill `sum_position` from `position * impressions` when the row only carries `position`. */
482
+ declare function coerceRowMetrics<T extends {
483
+ impressions: number;
484
+ sum_position?: number;
485
+ position?: number;
486
+ }>(row: T): T & {
487
+ sum_position: number;
488
+ };
489
+ /** Sort daily rows by date asc, coerce `sum_position`, reduce totals, derive chartData. */
490
+ declare function summarizeDailyRows(raw: readonly RawDailyRow[]): GscDailySummary;
491
+ /**
492
+ * Rollup-row position helper. `sum_position` is GSC's average-position sum
493
+ * across impressions; dividing back out (+1 because GSC is 1-indexed) gives
494
+ * the impression-weighted average position. Returns 0 when there were no
495
+ * impressions so the column renders blank rather than NaN.
496
+ */
497
+ declare function positionFor(r: {
498
+ impressions: number;
499
+ sum_position: number;
500
+ }): number;
501
+ interface IndexingIssueDetail {
502
+ description: string;
503
+ fix: string;
504
+ }
505
+ type IssueSeverity = 'error' | 'warning' | 'info';
506
+ interface IndexingIssue {
507
+ type: string;
508
+ label: string;
509
+ severity: IssueSeverity;
510
+ count: number;
511
+ }
512
+ declare const issueDetails: Record<string, IndexingIssueDetail>;
513
+ /**
514
+ * Nuxt-SEO-specific fix supplements. Activated by `enrichIssueDetails` when the
515
+ * caller passes a module list that includes the relevant Nuxt module.
516
+ */
517
+ declare const nuxtSeoTips: Record<string, {
518
+ modules: string[];
519
+ tip: string;
520
+ }>;
521
+ declare const severityOrder: IssueSeverity[];
522
+ declare const investigationStatusConfig: Record<string, {
523
+ label: string;
524
+ icon: string;
525
+ color: 'success' | 'info' | 'warning' | 'neutral' | 'error';
526
+ }>;
527
+ declare const coverageLabels: Record<string, {
528
+ short: string;
529
+ color: string;
530
+ }>;
531
+ declare function coverageLabel(state: string): {
532
+ short: string;
533
+ color: string;
534
+ };
535
+ interface IssueGroup {
536
+ id: string;
537
+ label: string;
538
+ icon: string;
539
+ description: string;
540
+ /** How hard are these to fix? Shown as a badge */
541
+ effort: 'quick' | 'moderate' | 'involved';
542
+ /** Does the user have direct control over these? */
543
+ controlLevel: 'full' | 'partial' | 'none';
544
+ /** Educational explanation shown in the group header */
545
+ education: string;
546
+ /** Issue types belonging to this group */
547
+ issueTypes: string[];
548
+ }
549
+ declare const issueGroups: IssueGroup[];
550
+ /** Map from issue type to its group id */
551
+ declare const issueTypeToGroup: Record<string, string>;
552
+ declare function enrichIssueDetails(modules?: {
553
+ name: string;
554
+ }[]): Record<string, IndexingIssueDetail>;
245
555
  declare function analyticsStatusToSyncStatus(status: PartnerLifecycleSite$1['analytics']['status']): GscdumpUserSite$1['syncStatus'];
246
556
  declare function lifecycleSiteToUserSite(site: PartnerLifecycleSite$1): GscdumpUserSite$1;
247
557
  declare function lifecycleSiteToSyncStatus(site: PartnerLifecycleSite$1): GscdumpSyncStatusResponse$1;
@@ -296,6 +606,59 @@ interface PartnerRealtimeClient {
296
606
  }
297
607
  declare function createPartnerRealtimeClient(options: PartnerRealtimeOptions): PartnerRealtimeClient;
298
608
  declare const createGscdumpRealtimeClient: typeof createPartnerRealtimeClient;
609
+ type SearchConsoleStageKey = 'not_connected' | 'waiting_for_data' | 'weak_discovery' | 'discovery_backlog' | 'crawl_blocked' | 'indexability_blocked' | 'index_rejection' | 'partially_indexed' | 'indexed_invisible' | 'visible_not_clicked' | 'ranking_stalled' | 'declining_visibility' | 'healthy_growth_ready';
610
+ type SearchConsoleStageSeverity = 'success' | 'error' | 'warning' | 'info' | 'neutral';
611
+ interface SearchConsoleStageEvidence {
612
+ label: string;
613
+ value: string;
614
+ source: 'connection' | 'indexing' | 'sitemap' | 'performance' | 'inspection' | 'canonical';
615
+ }
616
+ interface SearchConsoleStage {
617
+ key: SearchConsoleStageKey;
618
+ label: string;
619
+ severity: SearchConsoleStageSeverity;
620
+ summary: string;
621
+ primaryAction: string;
622
+ nextStage: SearchConsoleStageKey | null;
623
+ evidence: SearchConsoleStageEvidence[];
624
+ sprintFindingTypes: string[];
625
+ }
626
+ interface SearchConsoleStageIssue {
627
+ type: string;
628
+ label: string;
629
+ severity?: 'error' | 'warning' | 'info';
630
+ count: number;
631
+ }
632
+ interface SearchConsoleStageSummary {
633
+ totalUrls: number;
634
+ indexed: number;
635
+ indexedPercent: number;
636
+ change7d?: number | null;
637
+ change28d?: number | null;
638
+ }
639
+ interface SearchConsoleStageSitemap {
640
+ errors?: number | null;
641
+ warnings?: number | null;
642
+ lastError?: string | null;
643
+ urlCount?: number | null;
644
+ }
645
+ interface SearchConsoleStagePage {
646
+ impressions: number;
647
+ clicks: number;
648
+ position?: number | null;
649
+ }
650
+ interface ClassifySearchConsoleStageInput {
651
+ connected: boolean;
652
+ indexingStatus?: 'pending' | 'partial' | 'complete' | 'unknown' | string | null;
653
+ summary?: SearchConsoleStageSummary | null;
654
+ issues?: SearchConsoleStageIssue[] | null;
655
+ sitemaps?: SearchConsoleStageSitemap[] | null;
656
+ canonicalMismatchCount?: number | null;
657
+ pageInventory?: SearchConsoleStagePage[] | null;
658
+ ctrOutlierCount?: number | null;
659
+ pageMoverDropCount?: number | null;
660
+ }
661
+ declare function classifySearchConsoleStage(input: ClassifySearchConsoleStageInput): SearchConsoleStage;
299
662
  declare function serializeWebhookPayload(payload: string | object): string;
300
663
  declare function verifyWebhookSignature(payload: string | object, signature: string | null | undefined, secret: string): Promise<boolean>;
301
664
  declare function parseWebhookPayload<TData extends Record<string, unknown> = Record<string, unknown>>(payload: string | object, options?: {
@@ -305,4 +668,4 @@ declare function parseWebhookPayload<TData extends Record<string, unknown> = Rec
305
668
  validateSignature?: boolean;
306
669
  }): Promise<WebhookEnvelope$1<TData>>;
307
670
  declare function readWebhookHeaders(headers: Headers | PartnerWebhookHeaders$1 | null | undefined): Required<PartnerWebhookHeaders$1>;
308
- export { ARCHETYPE_EXECUTION_CLASS, type AddPartnerTeamMemberParams, type AnalyticsClient, type AnalyticsClientOptions, type AnalyticsFetch, type AnalyticsFetchOptions, type AnalyticsHeaders, type ArbitrarySqlQuery, type ArchetypeExecutionClass, type ArchetypeQuery, type ArchetypeQueryBase, type ArchetypeResult, type ArchetypeResultRow, type ArchetypeResultSource, type AuxCloudOnlyQuery, type BackfillRange, type BackfillResponse, type BindPartnerSiteTeamParams, type BuilderState, type BulkRegisterPartnerSiteResult, type BulkRegisterPartnerSitesParams, type BulkRegisterPartnerSitesResponse, CANONICAL_WEBHOOK_EVENTS, type CanonicalWebhookEventType, type CreatePartnerTeamParams, type CreateWebhookEnvelopeOptions, type DataDetailOptions, type DataQueryOptions, type DateRange, type DeletePartnerUserResponse, type EntityDailySparklineQuery, type EntityDailyTimeseriesQuery, type GscComparisonFilter, type GscdumpAnalysisParams, type GscdumpAnalysisPreset, type GscdumpAnalysisResponse, type GscdumpAnalysisSourcesResponse, type GscdumpAvailableSite, type GscdumpCanonicalMismatchesResponse, type GscdumpDataDetailResponse, type GscdumpDataResponse, type GscdumpDataRow, type GscdumpDateRangeParams, type GscdumpIndexPercentResponse, type GscdumpIndexingDiagnosticsResponse, type GscdumpIndexingResponse, type GscdumpIndexingUrlStatus, type GscdumpIndexingUrlsResponse, type GscdumpKeywordSparklinesParams, type GscdumpKeywordSparklinesResponse, type GscdumpMeta, type GscdumpPermissionRecovery, type GscdumpQueryTrendParams, type GscdumpQueryTrendResponse, type GscdumpSiteRegistration, type GscdumpSitemap, type GscdumpSitemapChangesResponse, type GscdumpSitemapHistory, type GscdumpSitemapsResponse, type GscdumpSyncStatusResponse, type GscdumpTeamMemberRow, type GscdumpTeamRow, type GscdumpTopAssociationParams, type GscdumpTopAssociationResponse, type GscdumpTotals, type GscdumpUserRegistration, type GscdumpUserSettings, type GscdumpUserSite, type GscdumpUserStatus, type GscdumpUserTokenUpdate, type IndexingUrlsParams, type InspectionHistoryResponse, type InspectionIndex, type MultiSeriesStackedDailyQuery, PartnerApiError, type PartnerClient, type PartnerClientOptions, type PartnerErrorInfo, type PartnerErrorKind, type PartnerFetch, type PartnerFetchOptions, type PartnerHeaders, type PartnerLifecycleAccount, type PartnerLifecycleResponse, type PartnerLifecycleSite, type PartnerRealtimeClient, type PartnerRealtimeEvent, type PartnerRealtimeEventType, type PartnerRealtimeHandler, type PartnerRealtimeMessage, type PartnerRealtimeOptions, type PartnerRealtimeScope, type PartnerRealtimeStatus, type PartnerWebSocketConstructor, type PartnerWebSocketLike, type PartnerWebhookData, type PartnerWebhookHeaders, type PresetAnalyzerQuery, type QueryArchetype, type RealtimeAuthFailedEvent, type RealtimeAuthRequiredMessage, type RealtimeConnectedMessage, type RealtimeEnrichmentCompleteEvent, type RealtimeErrorMessage, type RealtimeJobFailedEvent, type RealtimeNeedsReauthEvent, type RealtimePongMessage, type RealtimeSiteAddedEvent, type RealtimeSiteRemovedEvent, type RealtimeSubscribedMessage, type RealtimeSyncCompleteEvent, type RealtimeSyncFailedEvent, type RealtimeSyncJobCompleteEvent, type RealtimeSyncProgressEvent, type RealtimeSyncSiteCompleteEvent, type RegisterPartnerSiteParams, type RegisterPartnerUserParams, type ResolvedArchetypeQuery, type RollupEnvelope, type SingleRowLookupQuery, type SiteDailyTimeseriesQuery, type TopNBreakdownQuery, type TwoDimensionDetailQuery, type UpdatePartnerUserTokensParams, VALID_WEBHOOK_EVENTS, WEBHOOK_CONTRACT_VERSION, WEBHOOK_CONTRACT_VERSION_HEADER, WEBHOOK_DELIVERY_HEADER, WEBHOOK_EVENT_HEADER, WEBHOOK_SIGNATURE_HEADER, WEBHOOK_TIMESTAMP_HEADER, type WebhookEnvelope, type WebhookEventType, type WhoamiResponse, analyticsStatusToSyncStatus, createAnalyticsClient, createGscdumpClient, createGscdumpRealtimeClient, createPartnerClient, createPartnerRealtimeClient, findLifecycleSite, lifecycleSiteToSyncStatus, lifecycleSiteToUserSite, parseWebhookPayload, readWebhookHeaders, serializeWebhookPayload, toPartnerError, verifyWebhookSignature };
671
+ export { ARCHETYPE_EXECUTION_CLASS, type AddPartnerTeamMemberParams, type AnalyticsClient, type AnalyticsClientOptions, type AnalyticsFetch, type AnalyticsFetchOptions, type AnalyticsHeaders, type ArbitrarySqlQuery, type ArchetypeExecutionClass, type ArchetypeQuery, type ArchetypeQueryBase, type ArchetypeResult, type ArchetypeResultRow, type ArchetypeResultSource, type AuxCloudOnlyQuery, type BackfillRange, type BackfillResponse, type BindPartnerSiteTeamParams, type BuilderState, type BulkRegisterPartnerSiteResult, type BulkRegisterPartnerSitesParams, type BulkRegisterPartnerSitesResponse, CANONICAL_WEBHOOK_EVENTS, COMPARE_OPTIONS, COUNTRY_NAMES, CWV_GOOD_CLS, CWV_GOOD_INP, CWV_GOOD_LCP, CWV_POOR_CLS, CWV_POOR_INP, CWV_POOR_LCP, type CalendarPeriod, type CanonicalDailyRow, type CanonicalWebhookEventType, type ClassifySearchConsoleStageInput, type CompareMode, type CreatePartnerTeamParams, type CreateWebhookEnvelopeOptions, type CustomPeriod, type CwvBucket, type DailyAnonInput, type DataDetailOptions, type DataQueryOptions, type DateRange, type DateRangeResult, type DeletePartnerUserResponse, type EntityDailySparklineQuery, type EntityDailyTimeseriesQuery, GSC_COLUMN_OPTIONS, GSC_PERIOD_OPTIONS, GSC_PERIOD_OPTIONS_LONG, GSC_STABLE_LATENCY_DAYS, type GscAnalyzerAccent, type GscAnalyzerCapabilities, type GscAnalyzerCapability, type GscAnalyzerDefinition, type GscAnalyzerDefinitionWithCapability, type GscAnalyzerInsightCard, type GscAnalyzerKind, type GscAnalyzerPanelResult, type GscAnalyzerPanelSpec, type GscAnalyzerStatTile, type GscClassifiedError, type GscColumn, type GscColumnOption, type GscComparisonFilter, type GscConsoleUrlOpts, type GscDailySummary, type GscErrorStatus, type GscRowTotals, type GscdumpAnalysisParams, type GscdumpAnalysisPreset, type GscdumpAnalysisResponse, type GscdumpAnalysisSourcesResponse, type GscdumpAvailableSite, type GscdumpCanonicalMismatchesResponse, type GscdumpDataDetailResponse, type GscdumpDataResponse, type GscdumpDataRow, type GscdumpDateRangeParams, type GscdumpIndexPercentResponse, type GscdumpIndexingDiagnosticsResponse, type GscdumpIndexingResponse, type GscdumpIndexingUrlStatus, type GscdumpIndexingUrlsResponse, type GscdumpKeywordSparklinesParams, type GscdumpKeywordSparklinesResponse, type GscdumpMeta, type GscdumpPermissionRecovery, type GscdumpQueryTrendParams, type GscdumpQueryTrendResponse, type GscdumpSiteRegistration, type GscdumpSitemap, type GscdumpSitemapChangesResponse, type GscdumpSitemapHistory, type GscdumpSitemapsResponse, type GscdumpSyncStatusResponse, type GscdumpTeamMemberRow, type GscdumpTeamRow, type GscdumpTopAssociationParams, type GscdumpTopAssociationResponse, type GscdumpTotals, type GscdumpUserRegistration, type GscdumpUserSettings, type GscdumpUserSite, type GscdumpUserStatus, type GscdumpUserTokenUpdate, type IndexingIssue, type IndexingIssueDetail, type IndexingUrlsParams, type InspectionHistoryResponse, type InspectionIndex, type IssueGroup, type IssueSeverity, type MultiSeriesStackedDailyQuery, PERIOD_PRESETS, PartnerApiError, type PartnerClient, type PartnerClientOptions, type PartnerErrorInfo, type PartnerErrorKind, type PartnerFetch, type PartnerFetchOptions, type PartnerHeaders, type PartnerLifecycleAccount, type PartnerLifecycleResponse, type PartnerLifecycleSite, type PartnerRealtimeClient, type PartnerRealtimeEvent, type PartnerRealtimeEventType, type PartnerRealtimeHandler, type PartnerRealtimeMessage, type PartnerRealtimeOptions, type PartnerRealtimeScope, type PartnerRealtimeStatus, type PartnerWebSocketConstructor, type PartnerWebSocketLike, type PartnerWebhookData, type PartnerWebhookHeaders, type Period, type PeriodPreset, type PresetAnalyzerQuery, type QueryArchetype, type RawDailyRow, type RealtimeAuthFailedEvent, type RealtimeAuthRequiredMessage, type RealtimeConnectedMessage, type RealtimeEnrichmentCompleteEvent, type RealtimeErrorMessage, type RealtimeJobFailedEvent, type RealtimeNeedsReauthEvent, type RealtimePongMessage, type RealtimeSiteAddedEvent, type RealtimeSiteRemovedEvent, type RealtimeSubscribedMessage, type RealtimeSyncCompleteEvent, type RealtimeSyncFailedEvent, type RealtimeSyncJobCompleteEvent, type RealtimeSyncProgressEvent, type RealtimeSyncSiteCompleteEvent, type RegisterPartnerSiteParams, type RegisterPartnerUserParams, type ResolvedArchetypeQuery, type RollingPeriod, type RollupEnvelope, type SearchConsoleStage, type SearchConsoleStageEvidence, type SearchConsoleStageIssue, type SearchConsoleStageKey, type SearchConsoleStagePage, type SearchConsoleStageSeverity, type SearchConsoleStageSitemap, type SearchConsoleStageSummary, type SingleRowLookupQuery, type SiteDailyTimeseriesQuery, type TopNBreakdownQuery, type TwoDimensionDetailQuery, type UpdatePartnerUserTokensParams, VALID_WEBHOOK_EVENTS, WEBHOOK_CONTRACT_VERSION, WEBHOOK_CONTRACT_VERSION_HEADER, WEBHOOK_DELIVERY_HEADER, WEBHOOK_EVENT_HEADER, WEBHOOK_SIGNATURE_HEADER, WEBHOOK_TIMESTAMP_HEADER, type WebhookEnvelope, type WebhookEventType, type WhoamiResponse, analyticsStatusToSyncStatus, andFilter, classifyGscError, classifySearchConsoleStage, coerceRowMetrics, compareRange, countryName, coverageLabel, coverageLabels, createAnalyticsClient, createGscdumpClient, createGscdumpRealtimeClient, createPartnerClient, createPartnerRealtimeClient, cwvBucket, dateFilter, defineGscAnalyzer, enrichIssueDetails, findLifecycleSite, getGscUnstableCutoffDate, gscConsoleUrl, investigationStatusConfig, isCustomPeriod, issueDetails, issueGroups, issueTypeToGroup, lifecycleSiteToSyncStatus, lifecycleSiteToUserSite, nuxtSeoTips, parseCustomPeriod, parseWebhookPayload, periodToDateRange, periodToDays, positionFor, readWebhookHeaders, serializeWebhookPayload, severityOrder, siteUrlToHostname, splitOpportunityTitle, summarizeDailyRows, toPartnerError, truncateQuery, verifyWebhookSignature, weightedAnonPct };