@gscdump/contracts 2.0.6 → 2.1.1
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.
- package/dist/endpoints.d.mts +4 -4
- package/dist/onboarding.d.mts +1 -1
- package/dist/onboarding.mjs +1 -1
- package/dist/schemas.d.mts +14 -14
- package/dist/schemas.mjs +2 -2
- package/dist/types.d.mts +3 -3
- package/dist/v1/browser.d.mts +2 -2
- package/dist/v1/browser.mjs +47 -44
- package/dist/v1/operations.d.mts +12 -311
- package/dist/v1/operations.mjs +3 -141
- package/package.json +1 -1
package/dist/endpoints.d.mts
CHANGED
|
@@ -732,7 +732,7 @@ declare const partnerEndpoints: {
|
|
|
732
732
|
code: import("zod").ZodEnum<{
|
|
733
733
|
missing_refresh_token: "missing_refresh_token";
|
|
734
734
|
missing_analytics_scope: "missing_analytics_scope";
|
|
735
|
-
|
|
735
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
736
736
|
token_refresh_failed: "token_refresh_failed";
|
|
737
737
|
permission_lost: "permission_lost";
|
|
738
738
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -851,7 +851,7 @@ declare const partnerEndpoints: {
|
|
|
851
851
|
existing: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
852
852
|
indexingEligible: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
853
853
|
indexingIneligibleReason: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
854
|
-
|
|
854
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
855
855
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
856
856
|
free_plan: "free_plan";
|
|
857
857
|
}>>;
|
|
@@ -969,7 +969,7 @@ declare const partnerEndpoints: {
|
|
|
969
969
|
code: import("zod").ZodEnum<{
|
|
970
970
|
missing_refresh_token: "missing_refresh_token";
|
|
971
971
|
missing_analytics_scope: "missing_analytics_scope";
|
|
972
|
-
|
|
972
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
973
973
|
token_refresh_failed: "token_refresh_failed";
|
|
974
974
|
permission_lost: "permission_lost";
|
|
975
975
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -1034,7 +1034,7 @@ declare const partnerEndpoints: {
|
|
|
1034
1034
|
site: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnknown>>>;
|
|
1035
1035
|
indexingEligible: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
1036
1036
|
indexingIneligibleReason: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
1037
|
-
|
|
1037
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
1038
1038
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
1039
1039
|
free_plan: "free_plan";
|
|
1040
1040
|
}>>;
|
package/dist/onboarding.d.mts
CHANGED
|
@@ -14,7 +14,7 @@ declare const sitemapStatuses: readonly ["unknown", "discovering", "none_found",
|
|
|
14
14
|
declare const sitemapNextActions: readonly ["submit_sitemap", "wait_for_sitemaps", "retry_sitemaps", "none"];
|
|
15
15
|
declare const indexingStatuses: readonly ["not_requested", "missing_scope", "insufficient_permission", "waiting_for_sitemaps", "discovering", "checking", "ready", "budget_exhausted", "no_urls", "failed"];
|
|
16
16
|
declare const indexingNextActions: readonly ["reconnect_google", "fix_gsc_permission", "wait_for_sitemaps", "wait_for_indexing", "retry_indexing", "none"];
|
|
17
|
-
declare const lifecycleErrorCodes: readonly ["missing_refresh_token", "missing_analytics_scope", "
|
|
17
|
+
declare const lifecycleErrorCodes: readonly ["missing_refresh_token", "missing_analytics_scope", "missing_gsc_read_scope", "token_refresh_failed", "permission_lost", "insufficient_gsc_permission", "gsc_property_not_found", "gsc_property_unverified", "user_database_not_provisioned", "sync_failed", "sitemap_sync_failed", "indexing_failed"];
|
|
18
18
|
type AccountStatus = typeof accountStatuses[number];
|
|
19
19
|
type AccountNextAction = typeof accountNextActions[number];
|
|
20
20
|
type PropertyStatus = typeof propertyStatuses[number];
|
package/dist/onboarding.mjs
CHANGED
|
@@ -92,7 +92,7 @@ const indexingNextActions = [
|
|
|
92
92
|
const lifecycleErrorCodes = [
|
|
93
93
|
"missing_refresh_token",
|
|
94
94
|
"missing_analytics_scope",
|
|
95
|
-
"
|
|
95
|
+
"missing_gsc_read_scope",
|
|
96
96
|
"token_refresh_failed",
|
|
97
97
|
"permission_lost",
|
|
98
98
|
"insufficient_gsc_permission",
|
package/dist/schemas.d.mts
CHANGED
|
@@ -786,7 +786,7 @@ declare const lifecycleErrorSchema: z.ZodObject<{
|
|
|
786
786
|
code: z.ZodEnum<{
|
|
787
787
|
missing_refresh_token: "missing_refresh_token";
|
|
788
788
|
missing_analytics_scope: "missing_analytics_scope";
|
|
789
|
-
|
|
789
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
790
790
|
token_refresh_failed: "token_refresh_failed";
|
|
791
791
|
permission_lost: "permission_lost";
|
|
792
792
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -931,7 +931,7 @@ declare const partnerLifecycleSiteSchema: z.ZodObject<{
|
|
|
931
931
|
code: z.ZodEnum<{
|
|
932
932
|
missing_refresh_token: "missing_refresh_token";
|
|
933
933
|
missing_analytics_scope: "missing_analytics_scope";
|
|
934
|
-
|
|
934
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
935
935
|
token_refresh_failed: "token_refresh_failed";
|
|
936
936
|
permission_lost: "permission_lost";
|
|
937
937
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -1084,7 +1084,7 @@ declare const partnerLifecycleResponseSchema: z.ZodObject<{
|
|
|
1084
1084
|
code: z.ZodEnum<{
|
|
1085
1085
|
missing_refresh_token: "missing_refresh_token";
|
|
1086
1086
|
missing_analytics_scope: "missing_analytics_scope";
|
|
1087
|
-
|
|
1087
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
1088
1088
|
token_refresh_failed: "token_refresh_failed";
|
|
1089
1089
|
permission_lost: "permission_lost";
|
|
1090
1090
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -1153,7 +1153,7 @@ declare const gscdumpSiteRegistrationSchema: z.ZodObject<{
|
|
|
1153
1153
|
existing: z.ZodOptional<z.ZodBoolean>;
|
|
1154
1154
|
indexingEligible: z.ZodOptional<z.ZodBoolean>;
|
|
1155
1155
|
indexingIneligibleReason: z.ZodOptional<z.ZodEnum<{
|
|
1156
|
-
|
|
1156
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
1157
1157
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
1158
1158
|
free_plan: "free_plan";
|
|
1159
1159
|
}>>;
|
|
@@ -1271,7 +1271,7 @@ declare const gscdumpSiteRegistrationSchema: z.ZodObject<{
|
|
|
1271
1271
|
code: z.ZodEnum<{
|
|
1272
1272
|
missing_refresh_token: "missing_refresh_token";
|
|
1273
1273
|
missing_analytics_scope: "missing_analytics_scope";
|
|
1274
|
-
|
|
1274
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
1275
1275
|
token_refresh_failed: "token_refresh_failed";
|
|
1276
1276
|
permission_lost: "permission_lost";
|
|
1277
1277
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -1358,7 +1358,7 @@ declare const bulkRegisterPartnerSitesResponseSchema: z.ZodObject<{
|
|
|
1358
1358
|
site: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
1359
1359
|
indexingEligible: z.ZodOptional<z.ZodBoolean>;
|
|
1360
1360
|
indexingIneligibleReason: z.ZodOptional<z.ZodEnum<{
|
|
1361
|
-
|
|
1361
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
1362
1362
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
1363
1363
|
free_plan: "free_plan";
|
|
1364
1364
|
}>>;
|
|
@@ -3748,7 +3748,7 @@ declare const partnerControlEndpointSchemas: {
|
|
|
3748
3748
|
code: z.ZodEnum<{
|
|
3749
3749
|
missing_refresh_token: "missing_refresh_token";
|
|
3750
3750
|
missing_analytics_scope: "missing_analytics_scope";
|
|
3751
|
-
|
|
3751
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
3752
3752
|
token_refresh_failed: "token_refresh_failed";
|
|
3753
3753
|
permission_lost: "permission_lost";
|
|
3754
3754
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -3854,7 +3854,7 @@ declare const partnerControlEndpointSchemas: {
|
|
|
3854
3854
|
existing: z.ZodOptional<z.ZodBoolean>;
|
|
3855
3855
|
indexingEligible: z.ZodOptional<z.ZodBoolean>;
|
|
3856
3856
|
indexingIneligibleReason: z.ZodOptional<z.ZodEnum<{
|
|
3857
|
-
|
|
3857
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
3858
3858
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
3859
3859
|
free_plan: "free_plan";
|
|
3860
3860
|
}>>;
|
|
@@ -3972,7 +3972,7 @@ declare const partnerControlEndpointSchemas: {
|
|
|
3972
3972
|
code: z.ZodEnum<{
|
|
3973
3973
|
missing_refresh_token: "missing_refresh_token";
|
|
3974
3974
|
missing_analytics_scope: "missing_analytics_scope";
|
|
3975
|
-
|
|
3975
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
3976
3976
|
token_refresh_failed: "token_refresh_failed";
|
|
3977
3977
|
permission_lost: "permission_lost";
|
|
3978
3978
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -4034,7 +4034,7 @@ declare const partnerControlEndpointSchemas: {
|
|
|
4034
4034
|
site: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
4035
4035
|
indexingEligible: z.ZodOptional<z.ZodBoolean>;
|
|
4036
4036
|
indexingIneligibleReason: z.ZodOptional<z.ZodEnum<{
|
|
4037
|
-
|
|
4037
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
4038
4038
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
4039
4039
|
free_plan: "free_plan";
|
|
4040
4040
|
}>>;
|
|
@@ -5447,7 +5447,7 @@ declare const partnerEndpointSchemas: {
|
|
|
5447
5447
|
code: z.ZodEnum<{
|
|
5448
5448
|
missing_refresh_token: "missing_refresh_token";
|
|
5449
5449
|
missing_analytics_scope: "missing_analytics_scope";
|
|
5450
|
-
|
|
5450
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
5451
5451
|
token_refresh_failed: "token_refresh_failed";
|
|
5452
5452
|
permission_lost: "permission_lost";
|
|
5453
5453
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -5553,7 +5553,7 @@ declare const partnerEndpointSchemas: {
|
|
|
5553
5553
|
existing: z.ZodOptional<z.ZodBoolean>;
|
|
5554
5554
|
indexingEligible: z.ZodOptional<z.ZodBoolean>;
|
|
5555
5555
|
indexingIneligibleReason: z.ZodOptional<z.ZodEnum<{
|
|
5556
|
-
|
|
5556
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
5557
5557
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
5558
5558
|
free_plan: "free_plan";
|
|
5559
5559
|
}>>;
|
|
@@ -5671,7 +5671,7 @@ declare const partnerEndpointSchemas: {
|
|
|
5671
5671
|
code: z.ZodEnum<{
|
|
5672
5672
|
missing_refresh_token: "missing_refresh_token";
|
|
5673
5673
|
missing_analytics_scope: "missing_analytics_scope";
|
|
5674
|
-
|
|
5674
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
5675
5675
|
token_refresh_failed: "token_refresh_failed";
|
|
5676
5676
|
permission_lost: "permission_lost";
|
|
5677
5677
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -5733,7 +5733,7 @@ declare const partnerEndpointSchemas: {
|
|
|
5733
5733
|
site: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
5734
5734
|
indexingEligible: z.ZodOptional<z.ZodBoolean>;
|
|
5735
5735
|
indexingIneligibleReason: z.ZodOptional<z.ZodEnum<{
|
|
5736
|
-
|
|
5736
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
5737
5737
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
5738
5738
|
free_plan: "free_plan";
|
|
5739
5739
|
}>>;
|
package/dist/schemas.mjs
CHANGED
|
@@ -533,7 +533,7 @@ const gscdumpSiteRegistrationSchema = z.object({
|
|
|
533
533
|
indexingEligible: z.boolean().optional(),
|
|
534
534
|
indexingIneligibleReason: z.enum([
|
|
535
535
|
"free_plan",
|
|
536
|
-
"
|
|
536
|
+
"missing_gsc_read_scope",
|
|
537
537
|
"insufficient_gsc_permission"
|
|
538
538
|
]).optional(),
|
|
539
539
|
indexingPermissionLevel: z.string().nullable().optional(),
|
|
@@ -582,7 +582,7 @@ const bulkRegisterPartnerSitesResponseSchema = z.object({
|
|
|
582
582
|
indexingEligible: z.boolean().optional(),
|
|
583
583
|
indexingIneligibleReason: z.enum([
|
|
584
584
|
"free_plan",
|
|
585
|
-
"
|
|
585
|
+
"missing_gsc_read_scope",
|
|
586
586
|
"insufficient_gsc_permission"
|
|
587
587
|
]).optional(),
|
|
588
588
|
indexingPermissionLevel: z.string().nullable().optional(),
|
package/dist/types.d.mts
CHANGED
|
@@ -471,7 +471,7 @@ interface GscdumpSiteRegistration {
|
|
|
471
471
|
message?: string;
|
|
472
472
|
existing?: boolean;
|
|
473
473
|
indexingEligible?: boolean;
|
|
474
|
-
indexingIneligibleReason?: 'free_plan' | '
|
|
474
|
+
indexingIneligibleReason?: 'free_plan' | 'missing_gsc_read_scope' | 'insufficient_gsc_permission';
|
|
475
475
|
indexingPermissionLevel?: string | null;
|
|
476
476
|
grantedScopes?: string[];
|
|
477
477
|
site?: PartnerLifecycleSite | null;
|
|
@@ -524,7 +524,7 @@ interface GscdumpUserSite {
|
|
|
524
524
|
percent: number;
|
|
525
525
|
};
|
|
526
526
|
indexingEligible?: boolean;
|
|
527
|
-
indexingIneligibleReason?: 'free_plan' | '
|
|
527
|
+
indexingIneligibleReason?: 'free_plan' | 'missing_gsc_read_scope' | 'insufficient_gsc_permission';
|
|
528
528
|
indexingPermissionLevel?: string | null;
|
|
529
529
|
grantedScopes?: string[];
|
|
530
530
|
indexingStatus?: 'not_started' | 'indexing' | 'complete';
|
|
@@ -980,7 +980,7 @@ interface BulkRegisterPartnerSiteResult {
|
|
|
980
980
|
error?: string;
|
|
981
981
|
site?: PartnerLifecycleSite | null;
|
|
982
982
|
indexingEligible?: boolean;
|
|
983
|
-
indexingIneligibleReason?: 'free_plan' | '
|
|
983
|
+
indexingIneligibleReason?: 'free_plan' | 'missing_gsc_read_scope' | 'insufficient_gsc_permission';
|
|
984
984
|
indexingPermissionLevel?: string | null;
|
|
985
985
|
grantedScopes?: string[];
|
|
986
986
|
}
|
package/dist/v1/browser.d.mts
CHANGED
|
@@ -262,7 +262,7 @@ declare function createGscdumpV1BrowserSchemas(realtimeSchemas?: RealtimeV1Schem
|
|
|
262
262
|
readonly code: z.ZodEnum<{
|
|
263
263
|
missing_refresh_token: "missing_refresh_token";
|
|
264
264
|
missing_analytics_scope: "missing_analytics_scope";
|
|
265
|
-
|
|
265
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
266
266
|
token_refresh_failed: "token_refresh_failed";
|
|
267
267
|
permission_lost: "permission_lost";
|
|
268
268
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -418,7 +418,7 @@ declare function createGscdumpV1BrowserSchemas(realtimeSchemas?: RealtimeV1Schem
|
|
|
418
418
|
readonly code: z.ZodEnum<{
|
|
419
419
|
missing_refresh_token: "missing_refresh_token";
|
|
420
420
|
missing_analytics_scope: "missing_analytics_scope";
|
|
421
|
-
|
|
421
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
422
422
|
token_refresh_failed: "token_refresh_failed";
|
|
423
423
|
permission_lost: "permission_lost";
|
|
424
424
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
package/dist/v1/browser.mjs
CHANGED
|
@@ -171,51 +171,54 @@ function createGscdumpV1BrowserSchemas(realtimeSchemas = createRealtimeV1Schemas
|
|
|
171
171
|
_nestedGroups: z.array(normalizedFilter).min(1),
|
|
172
172
|
_groupType: z.enum(["and", "or"]).optional()
|
|
173
173
|
})]));
|
|
174
|
+
const analyticsRowsRequest = z.strictObject({
|
|
175
|
+
dimensions: z.array(z.enum(dimensions)).min(1),
|
|
176
|
+
metrics: z.array(z.enum(metrics)).optional(),
|
|
177
|
+
filter: normalizedFilter.optional(),
|
|
178
|
+
prefilter: normalizedFilter.optional(),
|
|
179
|
+
orderBy: z.strictObject({
|
|
180
|
+
column: z.enum([...metrics, "date"]),
|
|
181
|
+
dir: z.enum(["asc", "desc"])
|
|
182
|
+
}).optional(),
|
|
183
|
+
rowLimit: z.number().int().positive().max(25e3).optional(),
|
|
184
|
+
startRow: z.number().int().nonnegative().optional(),
|
|
185
|
+
dataState: z.enum([
|
|
186
|
+
"final",
|
|
187
|
+
"all",
|
|
188
|
+
"hourly_all"
|
|
189
|
+
]).optional(),
|
|
190
|
+
aggregationType: z.enum([
|
|
191
|
+
"auto",
|
|
192
|
+
"byPage",
|
|
193
|
+
"byProperty",
|
|
194
|
+
"byNewsShowcasePanel"
|
|
195
|
+
]).optional(),
|
|
196
|
+
searchType: z.enum([
|
|
197
|
+
"web",
|
|
198
|
+
"image",
|
|
199
|
+
"video",
|
|
200
|
+
"news",
|
|
201
|
+
"discover",
|
|
202
|
+
"googleNews"
|
|
203
|
+
]).optional()
|
|
204
|
+
});
|
|
205
|
+
const analyticsRowData = defineResponseObject({ rows: z.array(z.record(z.string(), z.union([
|
|
206
|
+
z.string(),
|
|
207
|
+
z.number(),
|
|
208
|
+
z.boolean(),
|
|
209
|
+
z.null()
|
|
210
|
+
]))) });
|
|
211
|
+
const analyticsMeta = defineResponseObject({
|
|
212
|
+
requestId: realtimeSchemas.publicRequestId,
|
|
213
|
+
surface: z.literal("analytics"),
|
|
214
|
+
version: z.literal("1.0"),
|
|
215
|
+
sourceName: z.string().min(1),
|
|
216
|
+
sourceKind: z.enum(["row", "sql"]),
|
|
217
|
+
queryMs: z.number().nonnegative()
|
|
218
|
+
});
|
|
174
219
|
return {
|
|
175
|
-
analyticsRowsRequest
|
|
176
|
-
|
|
177
|
-
metrics: z.array(z.enum(metrics)).optional(),
|
|
178
|
-
filter: normalizedFilter.optional(),
|
|
179
|
-
prefilter: normalizedFilter.optional(),
|
|
180
|
-
orderBy: z.strictObject({
|
|
181
|
-
column: z.enum([...metrics, "date"]),
|
|
182
|
-
dir: z.enum(["asc", "desc"])
|
|
183
|
-
}).optional(),
|
|
184
|
-
rowLimit: z.number().int().positive().max(25e3).optional(),
|
|
185
|
-
startRow: z.number().int().nonnegative().optional(),
|
|
186
|
-
dataState: z.enum([
|
|
187
|
-
"final",
|
|
188
|
-
"all",
|
|
189
|
-
"hourly_all"
|
|
190
|
-
]).optional(),
|
|
191
|
-
aggregationType: z.enum([
|
|
192
|
-
"auto",
|
|
193
|
-
"byPage",
|
|
194
|
-
"byProperty",
|
|
195
|
-
"byNewsShowcasePanel"
|
|
196
|
-
]).optional(),
|
|
197
|
-
searchType: z.enum([
|
|
198
|
-
"web",
|
|
199
|
-
"image",
|
|
200
|
-
"video",
|
|
201
|
-
"news",
|
|
202
|
-
"discover",
|
|
203
|
-
"googleNews"
|
|
204
|
-
]).optional()
|
|
205
|
-
}),
|
|
206
|
-
analyticsRowsResponse: defineSuccessResponse(defineResponseObject({ rows: z.array(z.record(z.string(), z.union([
|
|
207
|
-
z.string(),
|
|
208
|
-
z.number(),
|
|
209
|
-
z.boolean(),
|
|
210
|
-
z.null()
|
|
211
|
-
]))) }), defineResponseObject({
|
|
212
|
-
requestId: realtimeSchemas.publicRequestId,
|
|
213
|
-
surface: z.literal("analytics"),
|
|
214
|
-
version: z.literal("1.0"),
|
|
215
|
-
sourceName: z.string().min(1),
|
|
216
|
-
sourceKind: z.enum(["row", "sql"]),
|
|
217
|
-
queryMs: z.number().nonnegative()
|
|
218
|
-
})),
|
|
220
|
+
analyticsRowsRequest,
|
|
221
|
+
analyticsRowsResponse: defineSuccessResponse(analyticsRowData, analyticsMeta),
|
|
219
222
|
keywordEnrichmentRequest,
|
|
220
223
|
keywordEnrichmentResponse,
|
|
221
224
|
lifecycleResponse,
|
package/dist/v1/operations.d.mts
CHANGED
|
@@ -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;
|
|
@@ -2005,7 +1975,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
2005
1975
|
readonly code: z.ZodEnum<{
|
|
2006
1976
|
missing_refresh_token: "missing_refresh_token";
|
|
2007
1977
|
missing_analytics_scope: "missing_analytics_scope";
|
|
2008
|
-
|
|
1978
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
2009
1979
|
token_refresh_failed: "token_refresh_failed";
|
|
2010
1980
|
permission_lost: "permission_lost";
|
|
2011
1981
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -2161,7 +2131,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
2161
2131
|
readonly code: z.ZodEnum<{
|
|
2162
2132
|
missing_refresh_token: "missing_refresh_token";
|
|
2163
2133
|
missing_analytics_scope: "missing_analytics_scope";
|
|
2164
|
-
|
|
2134
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
2165
2135
|
token_refresh_failed: "token_refresh_failed";
|
|
2166
2136
|
permission_lost: "permission_lost";
|
|
2167
2137
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -2513,7 +2483,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
2513
2483
|
existing: z.ZodOptional<z.ZodBoolean>;
|
|
2514
2484
|
indexingEligible: z.ZodOptional<z.ZodBoolean>;
|
|
2515
2485
|
indexingIneligibleReason: z.ZodOptional<z.ZodEnum<{
|
|
2516
|
-
|
|
2486
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
2517
2487
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
2518
2488
|
free_plan: "free_plan";
|
|
2519
2489
|
}>>;
|
|
@@ -2631,7 +2601,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
2631
2601
|
code: z.ZodEnum<{
|
|
2632
2602
|
missing_refresh_token: "missing_refresh_token";
|
|
2633
2603
|
missing_analytics_scope: "missing_analytics_scope";
|
|
2634
|
-
|
|
2604
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
2635
2605
|
token_refresh_failed: "token_refresh_failed";
|
|
2636
2606
|
permission_lost: "permission_lost";
|
|
2637
2607
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -2670,7 +2640,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
2670
2640
|
existing: z.ZodOptional<z.ZodBoolean>;
|
|
2671
2641
|
indexingEligible: z.ZodOptional<z.ZodBoolean>;
|
|
2672
2642
|
indexingIneligibleReason: z.ZodOptional<z.ZodEnum<{
|
|
2673
|
-
|
|
2643
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
2674
2644
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
2675
2645
|
free_plan: "free_plan";
|
|
2676
2646
|
}>>;
|
|
@@ -2788,7 +2758,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
2788
2758
|
code: z.ZodEnum<{
|
|
2789
2759
|
missing_refresh_token: "missing_refresh_token";
|
|
2790
2760
|
missing_analytics_scope: "missing_analytics_scope";
|
|
2791
|
-
|
|
2761
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
2792
2762
|
token_refresh_failed: "token_refresh_failed";
|
|
2793
2763
|
permission_lost: "permission_lost";
|
|
2794
2764
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -3144,7 +3114,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
3144
3114
|
readonly code: z.ZodEnum<{
|
|
3145
3115
|
missing_refresh_token: "missing_refresh_token";
|
|
3146
3116
|
missing_analytics_scope: "missing_analytics_scope";
|
|
3147
|
-
|
|
3117
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
3148
3118
|
token_refresh_failed: "token_refresh_failed";
|
|
3149
3119
|
permission_lost: "permission_lost";
|
|
3150
3120
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -3300,7 +3270,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
3300
3270
|
readonly code: z.ZodEnum<{
|
|
3301
3271
|
missing_refresh_token: "missing_refresh_token";
|
|
3302
3272
|
missing_analytics_scope: "missing_analytics_scope";
|
|
3303
|
-
|
|
3273
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
3304
3274
|
token_refresh_failed: "token_refresh_failed";
|
|
3305
3275
|
permission_lost: "permission_lost";
|
|
3306
3276
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -3646,7 +3616,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
3646
3616
|
existing: z.ZodOptional<z.ZodBoolean>;
|
|
3647
3617
|
indexingEligible: z.ZodOptional<z.ZodBoolean>;
|
|
3648
3618
|
indexingIneligibleReason: z.ZodOptional<z.ZodEnum<{
|
|
3649
|
-
|
|
3619
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
3650
3620
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
3651
3621
|
free_plan: "free_plan";
|
|
3652
3622
|
}>>;
|
|
@@ -3764,7 +3734,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
3764
3734
|
code: z.ZodEnum<{
|
|
3765
3735
|
missing_refresh_token: "missing_refresh_token";
|
|
3766
3736
|
missing_analytics_scope: "missing_analytics_scope";
|
|
3767
|
-
|
|
3737
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
3768
3738
|
token_refresh_failed: "token_refresh_failed";
|
|
3769
3739
|
permission_lost: "permission_lost";
|
|
3770
3740
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -3803,7 +3773,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
3803
3773
|
existing: z.ZodOptional<z.ZodBoolean>;
|
|
3804
3774
|
indexingEligible: z.ZodOptional<z.ZodBoolean>;
|
|
3805
3775
|
indexingIneligibleReason: z.ZodOptional<z.ZodEnum<{
|
|
3806
|
-
|
|
3776
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
3807
3777
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
3808
3778
|
free_plan: "free_plan";
|
|
3809
3779
|
}>>;
|
|
@@ -3921,7 +3891,7 @@ declare function createGscdumpV1Protocol(): {
|
|
|
3921
3891
|
code: z.ZodEnum<{
|
|
3922
3892
|
missing_refresh_token: "missing_refresh_token";
|
|
3923
3893
|
missing_analytics_scope: "missing_analytics_scope";
|
|
3924
|
-
|
|
3894
|
+
missing_gsc_read_scope: "missing_gsc_read_scope";
|
|
3925
3895
|
token_refresh_failed: "token_refresh_failed";
|
|
3926
3896
|
permission_lost: "permission_lost";
|
|
3927
3897
|
insufficient_gsc_permission: "insufficient_gsc_permission";
|
|
@@ -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: {
|
package/dist/v1/operations.mjs
CHANGED
|
@@ -53,7 +53,7 @@ function createGscdumpV1Protocol() {
|
|
|
53
53
|
});
|
|
54
54
|
const requestHeaders = z.strictObject({ "x-request-id": realtimeSchemas.publicRequestId.optional() });
|
|
55
55
|
const errorEnvelope = errorEnvelopeSchemas(HTTP_V1_ERROR_CODES, realtimeSchemas.publicRequestId);
|
|
56
|
-
const { analyticsRowsRequest, analyticsRowsResponse,
|
|
56
|
+
const { analyticsRowsRequest, analyticsRowsResponse, lifecycleResponse } = browserSchemas;
|
|
57
57
|
const dimensions = GSCDUMP_V1_ANALYTICS_DIMENSIONS;
|
|
58
58
|
const analyticsMeta = defineResponseObject({
|
|
59
59
|
requestId: realtimeSchemas.publicRequestId,
|
|
@@ -562,26 +562,12 @@ function createGscdumpV1Protocol() {
|
|
|
562
562
|
verified: z.literal(true),
|
|
563
563
|
owners: z.array(z.string()).optional()
|
|
564
564
|
}), partnerResponseMeta);
|
|
565
|
-
const crossSourceRequest = z.strictObject({
|
|
566
|
-
queryKey: z.enum([
|
|
567
|
-
"crawl-error-losing-impressions",
|
|
568
|
-
"declining-clicks-poor-lcp",
|
|
569
|
-
"striking-distance-slow-pages",
|
|
570
|
-
"top-impressions-low-performance"
|
|
571
|
-
]),
|
|
572
|
-
rangeDays: z.number().int().positive().max(180).optional(),
|
|
573
|
-
limit: z.number().int().positive().max(500).optional()
|
|
574
|
-
});
|
|
575
|
-
const crossSourceResponse = defineSuccessResponse(defineResponseObject({
|
|
576
|
-
reason: z.string().optional(),
|
|
577
|
-
sources: z.array(z.string()),
|
|
578
|
-
rows: z.array(z.record(z.string(), z.json()))
|
|
579
|
-
}), partnerResponseMeta);
|
|
580
565
|
const responseStreamHead = defineResponseObject({
|
|
581
566
|
streamId: realtimeSchemas.streamId,
|
|
582
567
|
sequence: realtimeSchemas.sequence
|
|
583
568
|
});
|
|
584
|
-
const
|
|
569
|
+
const headData = defineResponseObject({ head: responseStreamHead.producer }, { head: responseStreamHead.client });
|
|
570
|
+
const headResponse = defineSuccessResponse(headData, realtimeResponseMeta);
|
|
585
571
|
const ticketDataProducerShape = {
|
|
586
572
|
socketUrl: z.url().refine((value) => value.startsWith("wss://"), "socketUrl must use wss."),
|
|
587
573
|
protocol: z.literal(GSCDUMP_REALTIME_SUBPROTOCOL),
|
|
@@ -3869,128 +3855,6 @@ function createGscdumpV1Protocol() {
|
|
|
3869
3855
|
}
|
|
3870
3856
|
}
|
|
3871
3857
|
}
|
|
3872
|
-
}),
|
|
3873
|
-
queryCrossSource: defineHttpOperation({
|
|
3874
|
-
id: "partner.sites.cross.source.query",
|
|
3875
|
-
method: "POST",
|
|
3876
|
-
path: "/sites/{siteId}/cross-source",
|
|
3877
|
-
visibility: "public",
|
|
3878
|
-
semantics: {
|
|
3879
|
-
kind: "query",
|
|
3880
|
-
sideEffects: "none",
|
|
3881
|
-
idempotent: true,
|
|
3882
|
-
retry: "idempotent",
|
|
3883
|
-
readConsistency: "primary"
|
|
3884
|
-
},
|
|
3885
|
-
auth: {
|
|
3886
|
-
credentials: ["partner_key"],
|
|
3887
|
-
scopes: ["analytics:read"],
|
|
3888
|
-
ownership: [{
|
|
3889
|
-
credential: "partner_key",
|
|
3890
|
-
rule: "authorized_site"
|
|
3891
|
-
}]
|
|
3892
|
-
},
|
|
3893
|
-
request: {
|
|
3894
|
-
params: z.strictObject({ siteId: realtimeSchemas.publicSiteId }),
|
|
3895
|
-
query: null,
|
|
3896
|
-
headers: requestHeaders,
|
|
3897
|
-
body: crossSourceRequest
|
|
3898
|
-
},
|
|
3899
|
-
responses: { 200: crossSourceResponse },
|
|
3900
|
-
errors: partnerSiteErrors,
|
|
3901
|
-
errorResponse: errorEnvelopeSchemas(partnerSiteErrors, realtimeSchemas.publicRequestId),
|
|
3902
|
-
resources: {
|
|
3903
|
-
reads: [{
|
|
3904
|
-
type: "site.analytics",
|
|
3905
|
-
idFrom: "params.siteId"
|
|
3906
|
-
}],
|
|
3907
|
-
changes: []
|
|
3908
|
-
},
|
|
3909
|
-
lifecycle: { introduced: "1.3.0" },
|
|
3910
|
-
docs: {
|
|
3911
|
-
summary: "Query cross-source analysis",
|
|
3912
|
-
description: "Runs one predefined cross-source query joining crawl, CWV, and GSC signals for a site.",
|
|
3913
|
-
tags: ["Analytics"],
|
|
3914
|
-
examples: {
|
|
3915
|
-
request: {
|
|
3916
|
-
params: { siteId: "s_01" },
|
|
3917
|
-
body: {
|
|
3918
|
-
queryKey: "crawl-error-losing-impressions",
|
|
3919
|
-
rangeDays: 28,
|
|
3920
|
-
limit: 50
|
|
3921
|
-
}
|
|
3922
|
-
},
|
|
3923
|
-
response: {
|
|
3924
|
-
data: {
|
|
3925
|
-
sources: ["crawl", "gsc"],
|
|
3926
|
-
rows: []
|
|
3927
|
-
},
|
|
3928
|
-
meta: {
|
|
3929
|
-
requestId: "req_01",
|
|
3930
|
-
surface: "partner",
|
|
3931
|
-
version: "1.0"
|
|
3932
|
-
}
|
|
3933
|
-
}
|
|
3934
|
-
}
|
|
3935
|
-
}
|
|
3936
|
-
}),
|
|
3937
|
-
enrichKeywords: defineHttpOperation({
|
|
3938
|
-
id: "partner.keywords.enrich.query",
|
|
3939
|
-
method: "POST",
|
|
3940
|
-
path: "/keywords/enrich",
|
|
3941
|
-
visibility: "public",
|
|
3942
|
-
semantics: {
|
|
3943
|
-
kind: "query",
|
|
3944
|
-
sideEffects: "none",
|
|
3945
|
-
idempotent: true,
|
|
3946
|
-
retry: "idempotent",
|
|
3947
|
-
readConsistency: "primary"
|
|
3948
|
-
},
|
|
3949
|
-
auth: {
|
|
3950
|
-
credentials: ["user_key", "partner_key"],
|
|
3951
|
-
scopes: ["analytics:read"],
|
|
3952
|
-
ownership: [{
|
|
3953
|
-
credential: "user_key",
|
|
3954
|
-
rule: "self"
|
|
3955
|
-
}, {
|
|
3956
|
-
credential: "partner_key",
|
|
3957
|
-
rule: "partner_tenant"
|
|
3958
|
-
}]
|
|
3959
|
-
},
|
|
3960
|
-
request: {
|
|
3961
|
-
params: null,
|
|
3962
|
-
query: null,
|
|
3963
|
-
headers: requestHeaders,
|
|
3964
|
-
body: keywordEnrichmentRequest
|
|
3965
|
-
},
|
|
3966
|
-
responses: { 200: keywordEnrichmentResponse },
|
|
3967
|
-
errors: partnerUserErrors,
|
|
3968
|
-
errorResponse: errorEnvelopeSchemas(partnerUserErrors, realtimeSchemas.publicRequestId),
|
|
3969
|
-
resources: {
|
|
3970
|
-
reads: [],
|
|
3971
|
-
changes: []
|
|
3972
|
-
},
|
|
3973
|
-
lifecycle: { introduced: "1.3.0" },
|
|
3974
|
-
docs: {
|
|
3975
|
-
summary: "Enrich keywords with metrics",
|
|
3976
|
-
description: "Returns difficulty, search volume, and CPC estimates for up to 500 keywords.",
|
|
3977
|
-
tags: ["Analytics"],
|
|
3978
|
-
examples: {
|
|
3979
|
-
request: { body: { keywords: ["nuxt seo"] } },
|
|
3980
|
-
response: {
|
|
3981
|
-
data: { metrics: { "nuxt seo": {
|
|
3982
|
-
difficulty: 40,
|
|
3983
|
-
searchVolume: 100,
|
|
3984
|
-
cpc: 1.2
|
|
3985
|
-
} } },
|
|
3986
|
-
meta: {
|
|
3987
|
-
requestId: "req_01",
|
|
3988
|
-
surface: "partner",
|
|
3989
|
-
version: "1.0"
|
|
3990
|
-
}
|
|
3991
|
-
}
|
|
3992
|
-
}
|
|
3993
|
-
}
|
|
3994
3858
|
})
|
|
3995
3859
|
}
|
|
3996
3860
|
});
|
|
@@ -4405,8 +4269,6 @@ function createGscdumpV1Protocol() {
|
|
|
4405
4269
|
indexingTransitionsResponse,
|
|
4406
4270
|
indexingUrlsQuery,
|
|
4407
4271
|
indexingUrlsResponse,
|
|
4408
|
-
keywordEnrichmentRequest,
|
|
4409
|
-
keywordEnrichmentResponse,
|
|
4410
4272
|
lifecycleResponse,
|
|
4411
4273
|
registerSiteRequest,
|
|
4412
4274
|
sitemapChangesQuery,
|