@spacefast/common 0.0.23 → 0.0.26
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/brand-assets/LICENSE-Haskoy.txt +93 -0
- package/brand-assets/haskoy-latin-variable.woff2 +0 -0
- package/brand-assets/spacefast-favicon.svg +4 -4
- package/brand-assets/spacefast-sf-full-bleed.svg +3 -3
- package/brand-assets/spacefast-wordmark.svg +2 -4
- package/dist/agents/connect-targets.js +1 -1
- package/dist/agents/private-key-oauth.d.ts +0 -1
- package/dist/agents/private-key-oauth.js +46 -63
- package/dist/brand-assets-build.js +4 -6
- package/dist/brand-assets.d.ts +5 -15
- package/dist/brand-assets.js +15 -14
- package/dist/config/domains.d.ts +47 -7
- package/dist/config/domains.js +66 -10
- package/dist/config/index.d.ts +0 -1
- package/dist/config/index.js +0 -1
- package/dist/contracts/abuse.d.ts +2 -0
- package/dist/contracts/abuse.js +12 -0
- package/dist/contracts/access.d.ts +124 -12
- package/dist/contracts/access.js +73 -9
- package/dist/contracts/activity.d.ts +1 -1
- package/dist/contracts/activity.js +5 -12
- package/dist/contracts/api-keys.d.ts +21 -21
- package/dist/contracts/api-keys.js +2 -2
- package/dist/contracts/beta.js +1 -1
- package/dist/contracts/billing.d.ts +3 -35
- package/dist/contracts/billing.js +33 -52
- package/dist/contracts/builds.d.ts +30 -18
- package/dist/contracts/builds.js +28 -9
- package/dist/contracts/channels.js +1 -1
- package/dist/contracts/cli.d.ts +10 -0
- package/dist/contracts/cli.js +10 -0
- package/dist/contracts/collab-public.d.ts +63 -0
- package/dist/contracts/collab-public.js +46 -0
- package/dist/contracts/comments.d.ts +282 -53
- package/dist/contracts/comments.js +173 -52
- package/dist/contracts/common.d.ts +3 -3
- package/dist/contracts/common.js +5 -5
- package/dist/contracts/crons.d.ts +35 -0
- package/dist/contracts/crons.js +42 -0
- package/dist/contracts/device-auth.d.ts +6 -6
- package/dist/contracts/device-auth.js +2 -2
- package/dist/contracts/docs.js +2 -2
- package/dist/contracts/domains.d.ts +38 -27
- package/dist/contracts/domains.js +29 -2
- package/dist/contracts/enums.d.ts +34 -30
- package/dist/contracts/enums.js +62 -48
- package/dist/contracts/error-code-meta.d.ts +50 -125
- package/dist/contracts/error-code-meta.js +29 -41
- package/dist/contracts/error-codes.d.ts +1 -1
- package/dist/contracts/error-codes.js +14 -33
- package/dist/contracts/execution.d.ts +47 -66
- package/dist/contracts/execution.js +53 -49
- package/dist/contracts/feature-lifecycle-core.d.ts +0 -6
- package/dist/contracts/feature-lifecycle-core.js +2 -31
- package/dist/contracts/feature-lifecycle.d.ts +12 -52
- package/dist/contracts/feature-lifecycle.js +16 -59
- package/dist/contracts/features.d.ts +48 -60
- package/dist/contracts/features.js +59 -51
- package/dist/contracts/functions.d.ts +266 -72
- package/dist/contracts/functions.js +260 -37
- package/dist/contracts/git.d.ts +28 -34
- package/dist/contracts/git.js +10 -11
- package/dist/contracts/grants.d.ts +9 -5
- package/dist/contracts/grants.js +18 -9
- package/dist/contracts/ids.js +2 -2
- package/dist/contracts/internal.d.ts +8 -6
- package/dist/contracts/internal.js +12 -12
- package/dist/contracts/mcp.d.ts +11 -0
- package/dist/contracts/mcp.js +5 -0
- package/dist/contracts/me.js +1 -1
- package/dist/contracts/oauth-resources.d.ts +4 -3
- package/dist/contracts/oauth-resources.js +12 -3
- package/dist/contracts/operations.d.ts +90 -5
- package/dist/contracts/operations.js +77 -3
- package/dist/contracts/pages.d.ts +12 -7
- package/dist/contracts/pages.js +24 -1
- package/dist/contracts/plan-policy.d.ts +0 -2
- package/dist/contracts/plan-policy.js +2 -3
- package/dist/contracts/platform.d.ts +61 -148
- package/dist/contracts/platform.js +70 -126
- package/dist/contracts/publish-archive.d.ts +508 -0
- package/dist/contracts/publish-archive.js +32 -0
- package/dist/contracts/push-new.d.ts +4 -4
- package/dist/contracts/quotas.js +2 -2
- package/dist/contracts/repository-connections.d.ts +43 -30
- package/dist/contracts/repository-connections.js +11 -3
- package/dist/contracts/resources.d.ts +12 -24
- package/dist/contracts/resources.js +36 -16
- package/dist/contracts/runtime-api.d.ts +433 -192
- package/dist/contracts/runtime-api.js +421 -356
- package/dist/contracts/runtime-app.d.ts +127 -120
- package/dist/contracts/runtime-app.js +19 -10
- package/dist/contracts/runtime-db.d.ts +5 -5
- package/dist/contracts/runtime-db.js +2 -2
- package/dist/contracts/runtime-purge.d.ts +8 -0
- package/dist/contracts/runtime-purge.js +7 -0
- package/dist/contracts/runtime-services.d.ts +219 -0
- package/dist/contracts/runtime-services.js +437 -0
- package/dist/contracts/runtime-storage.d.ts +46 -32
- package/dist/contracts/runtime-storage.js +31 -8
- package/dist/contracts/sf-config-v1.d.ts +48 -10
- package/dist/contracts/space-config.d.ts +69 -18
- package/dist/contracts/space-config.js +226 -27
- package/dist/contracts/spaces.d.ts +236 -450
- package/dist/contracts/spaces.js +131 -151
- package/dist/contracts/superadmin-activity.d.ts +57 -4
- package/dist/contracts/superadmin-activity.js +48 -2
- package/dist/contracts/superadmin-search.d.ts +126 -0
- package/dist/contracts/superadmin-search.js +61 -0
- package/dist/contracts/superadmin-spaces.d.ts +361 -92
- package/dist/contracts/superadmin-spaces.js +97 -24
- package/dist/contracts/superadmin-teams.d.ts +28 -10
- package/dist/contracts/superadmin-teams.js +5 -8
- package/dist/contracts/superadmin-tenants.d.ts +0 -6
- package/dist/contracts/superadmin-tenants.js +1 -7
- package/dist/contracts/superadmin.d.ts +135 -54
- package/dist/contracts/superadmin.js +46 -23
- package/dist/contracts/tags.d.ts +12 -12
- package/dist/contracts/tags.js +3 -3
- package/dist/contracts/teams.d.ts +49 -14
- package/dist/contracts/teams.js +40 -22
- package/dist/contracts/transfers.d.ts +0 -49
- package/dist/contracts/transfers.js +4 -8
- package/dist/contracts/usage.d.ts +61 -0
- package/dist/contracts/usage.js +64 -0
- package/dist/contracts/variables.d.ts +2 -7
- package/dist/contracts/variables.js +9 -8
- package/dist/contracts/webhooks.d.ts +2 -2
- package/dist/contracts/zero.d.ts +102 -73
- package/dist/contracts/zero.js +94 -32
- package/dist/dashboard-paths/index.d.ts +1 -1
- package/dist/dashboard-paths/index.js +1 -0
- package/dist/docs/agent-prose.d.ts +2 -2
- package/dist/docs/agent-prose.js +63 -70
- package/dist/docs/agent-setup.js +45 -15
- package/dist/docs/catalog.d.ts +24 -24
- package/dist/docs/catalog.js +35 -24
- package/dist/docs/error-docs.js +194 -270
- package/dist/docs/skills.d.ts +12 -12
- package/dist/docs/skills.js +4 -4
- package/dist/test-helpers/fetch-stub.d.ts +16 -0
- package/dist/test-helpers/fetch-stub.js +25 -0
- package/dist/utils/build-settings.d.ts +5 -1
- package/dist/utils/build-settings.js +91 -13
- package/dist/utils/canonical-json.d.ts +10 -0
- package/dist/utils/canonical-json.js +22 -0
- package/dist/utils/cast-transport.d.ts +28 -0
- package/dist/utils/cast-transport.js +52 -0
- package/dist/utils/claim-token.d.ts +0 -8
- package/dist/utils/claim-token.js +3 -15
- package/dist/utils/concurrency.js +1 -0
- package/dist/utils/credential-policy.d.ts +1 -1
- package/dist/utils/credential-policy.js +4 -3
- package/dist/utils/dns-instructions.js +9 -9
- package/dist/utils/env-file.d.ts +17 -0
- package/dist/utils/env-file.js +96 -0
- package/dist/utils/error-code.d.ts +2 -0
- package/dist/utils/error-code.js +8 -0
- package/dist/utils/generate-space-name.d.ts +8 -10
- package/dist/utils/generate-space-name.js +206 -21
- package/dist/utils/grant-decision.fixtures.json +2938 -0
- package/dist/utils/grants.d.ts +2 -0
- package/dist/utils/grants.js +26 -1
- package/dist/utils/gravatar.d.ts +9 -0
- package/dist/utils/gravatar.js +31 -0
- package/dist/utils/idempotency.d.ts +6 -0
- package/dist/utils/idempotency.js +28 -0
- package/dist/utils/local-space-state.d.ts +9 -16
- package/dist/utils/local-space-state.js +20 -50
- package/dist/utils/one-shot-replay.d.ts +4 -1
- package/dist/utils/page-colors.d.ts +14 -12
- package/dist/utils/page-colors.js +15 -13
- package/dist/utils/page-fonts.d.ts +2 -2
- package/dist/utils/page-fonts.js +15 -4
- package/dist/utils/pages.d.ts +21 -3
- package/dist/utils/pages.js +42 -13
- package/dist/utils/publish-form-data.d.ts +12 -0
- package/dist/utils/publish-form-data.js +10 -0
- package/dist/utils/publish-policy.d.ts +27 -0
- package/dist/utils/publish-policy.fixtures.json +403 -0
- package/dist/utils/publish-policy.js +45 -20
- package/dist/utils/push-new.d.ts +7 -0
- package/dist/utils/push-new.js +7 -0
- package/dist/utils/query-keys.d.ts +4 -5
- package/dist/utils/query-keys.js +2 -3
- package/dist/utils/runtime-paths.d.ts +5 -0
- package/dist/utils/runtime-paths.js +5 -0
- package/dist/utils/runtime-upload-batch.d.ts +0 -5
- package/dist/utils/runtime-upload-batch.js +1 -27
- package/dist/utils/runtime-upload.d.ts +6 -11
- package/dist/utils/runtime-upload.js +10 -13
- package/dist/utils/secure-local-file.js +5 -16
- package/dist/utils/space-config.d.ts +1 -34
- package/dist/utils/space-config.js +8 -326
- package/dist/utils/static-runtime-policy.d.ts +9 -3
- package/dist/utils/static-runtime-policy.fixtures.json +38 -41
- package/dist/utils/static-runtime-policy.js +22 -56
- package/dist/utils/storage-policy.d.ts +1 -1
- package/dist/utils/storage-policy.js +3 -1
- package/dist/utils/structured-error.d.ts +14 -0
- package/dist/utils/structured-error.js +22 -0
- package/dist/utils/upload-session.d.ts +4 -1
- package/dist/utils/upload-session.js +33 -5
- package/dist/utils/version-path.js +13 -4
- package/dist/vocabulary.d.ts +13 -11
- package/dist/vocabulary.js +42 -28
- package/package.json +7 -17
- package/dist/config/postgres-budget.d.ts +0 -129
- package/dist/config/postgres-budget.js +0 -140
- package/dist/config/postgres-budget.json +0 -51
- package/dist/contracts/archives.d.ts +0 -331
- package/dist/contracts/archives.js +0 -120
- package/dist/contracts/deployments.d.ts +0 -574
- package/dist/contracts/deployments.js +0 -97
- package/dist/contracts/sites.d.ts +0 -416
- package/dist/contracts/sites.js +0 -168
- package/dist/contracts/superadmin-queues.d.ts +0 -414
- package/dist/contracts/superadmin-queues.js +0 -202
- package/dist/contracts/superadmin-runtime.d.ts +0 -27
- package/dist/contracts/superadmin-runtime.js +0 -38
- package/dist/index.d.ts +0 -1
- package/dist/index.js +0 -1
- package/dist/utils/api.d.ts +0 -4
- package/dist/utils/api.js +0 -13
|
@@ -98,7 +98,7 @@ export declare const domainVerificationSchema: z.ZodObject<{
|
|
|
98
98
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
99
99
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
100
100
|
registrar: "registrar";
|
|
101
|
-
|
|
101
|
+
infra: "infra";
|
|
102
102
|
dns: "dns";
|
|
103
103
|
runtime: "runtime";
|
|
104
104
|
}>>>;
|
|
@@ -225,6 +225,7 @@ export declare const domainRedirectTargetSchema: z.ZodUnion<readonly [z.ZodObjec
|
|
|
225
225
|
path: z.ZodOptional<z.ZodString>;
|
|
226
226
|
}, z.core.$strip>]>;
|
|
227
227
|
export declare const domainRedirectStatusSchema: z.ZodUnion<readonly [z.ZodLiteral<301>, z.ZodLiteral<302>, z.ZodLiteral<307>, z.ZodLiteral<308>]>;
|
|
228
|
+
export type DomainRedirectStatus = z.infer<typeof domainRedirectStatusSchema>;
|
|
228
229
|
export declare const domainRedirectSchema: z.ZodObject<{
|
|
229
230
|
to: z.ZodUnion<readonly [z.ZodObject<{
|
|
230
231
|
url: z.ZodString;
|
|
@@ -363,7 +364,7 @@ export declare const DomainSchema: z.ZodObject<{
|
|
|
363
364
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
364
365
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
365
366
|
registrar: "registrar";
|
|
366
|
-
|
|
367
|
+
infra: "infra";
|
|
367
368
|
dns: "dns";
|
|
368
369
|
runtime: "runtime";
|
|
369
370
|
}>>>;
|
|
@@ -621,7 +622,7 @@ export declare const domainListResponseSchema: z.ZodObject<{
|
|
|
621
622
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
622
623
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
623
624
|
registrar: "registrar";
|
|
624
|
-
|
|
625
|
+
infra: "infra";
|
|
625
626
|
dns: "dns";
|
|
626
627
|
runtime: "runtime";
|
|
627
628
|
}>>>;
|
|
@@ -876,7 +877,7 @@ export declare const spaceCustomDomainSchema: z.ZodObject<{
|
|
|
876
877
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
877
878
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
878
879
|
registrar: "registrar";
|
|
879
|
-
|
|
880
|
+
infra: "infra";
|
|
880
881
|
dns: "dns";
|
|
881
882
|
runtime: "runtime";
|
|
882
883
|
}>>>;
|
|
@@ -1045,7 +1046,7 @@ export declare const spaceManagedDomainSchema: z.ZodObject<{
|
|
|
1045
1046
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1046
1047
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
1047
1048
|
registrar: "registrar";
|
|
1048
|
-
|
|
1049
|
+
infra: "infra";
|
|
1049
1050
|
dns: "dns";
|
|
1050
1051
|
runtime: "runtime";
|
|
1051
1052
|
}>>>;
|
|
@@ -1100,7 +1101,7 @@ export declare const spaceDomainSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
1100
1101
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1101
1102
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
1102
1103
|
registrar: "registrar";
|
|
1103
|
-
|
|
1104
|
+
infra: "infra";
|
|
1104
1105
|
dns: "dns";
|
|
1105
1106
|
runtime: "runtime";
|
|
1106
1107
|
}>>>;
|
|
@@ -1240,7 +1241,7 @@ export declare const spaceDomainSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
1240
1241
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1241
1242
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
1242
1243
|
registrar: "registrar";
|
|
1243
|
-
|
|
1244
|
+
infra: "infra";
|
|
1244
1245
|
dns: "dns";
|
|
1245
1246
|
runtime: "runtime";
|
|
1246
1247
|
}>>>;
|
|
@@ -1411,7 +1412,7 @@ export declare const spaceDomainListResponseSchema: z.ZodObject<{
|
|
|
1411
1412
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1412
1413
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
1413
1414
|
registrar: "registrar";
|
|
1414
|
-
|
|
1415
|
+
infra: "infra";
|
|
1415
1416
|
dns: "dns";
|
|
1416
1417
|
runtime: "runtime";
|
|
1417
1418
|
}>>>;
|
|
@@ -1551,7 +1552,7 @@ export declare const spaceDomainListResponseSchema: z.ZodObject<{
|
|
|
1551
1552
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1552
1553
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
1553
1554
|
registrar: "registrar";
|
|
1554
|
-
|
|
1555
|
+
infra: "infra";
|
|
1555
1556
|
dns: "dns";
|
|
1556
1557
|
runtime: "runtime";
|
|
1557
1558
|
}>>>;
|
|
@@ -1725,7 +1726,7 @@ export declare const teamManagedDomainSchema: z.ZodObject<{
|
|
|
1725
1726
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1726
1727
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
1727
1728
|
registrar: "registrar";
|
|
1728
|
-
|
|
1729
|
+
infra: "infra";
|
|
1729
1730
|
dns: "dns";
|
|
1730
1731
|
runtime: "runtime";
|
|
1731
1732
|
}>>>;
|
|
@@ -1785,7 +1786,7 @@ export declare const teamManagedDomainListResponseSchema: z.ZodObject<{
|
|
|
1785
1786
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1786
1787
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
1787
1788
|
registrar: "registrar";
|
|
1788
|
-
|
|
1789
|
+
infra: "infra";
|
|
1789
1790
|
dns: "dns";
|
|
1790
1791
|
runtime: "runtime";
|
|
1791
1792
|
}>>>;
|
|
@@ -1806,6 +1807,16 @@ export declare const teamManagedDomainListResponseSchema: z.ZodObject<{
|
|
|
1806
1807
|
hasMore: z.ZodBoolean;
|
|
1807
1808
|
}, z.core.$strip>;
|
|
1808
1809
|
}, z.core.$strip>;
|
|
1810
|
+
export declare const domainPreflightQuerySchema: z.ZodObject<{
|
|
1811
|
+
name: z.ZodString;
|
|
1812
|
+
}, z.core.$strip>;
|
|
1813
|
+
export declare const domainPreflightSchema: z.ZodObject<{
|
|
1814
|
+
name: z.ZodString;
|
|
1815
|
+
unicodeName: z.ZodOptional<z.ZodString>;
|
|
1816
|
+
canHost: z.ZodNullable<z.ZodBoolean>;
|
|
1817
|
+
providerMessage: z.ZodNullable<z.ZodString>;
|
|
1818
|
+
}, z.core.$strip>;
|
|
1819
|
+
export type DomainPreflight = z.infer<typeof domainPreflightSchema>;
|
|
1809
1820
|
export declare const domainCreateRequestSchema: z.ZodObject<{
|
|
1810
1821
|
name: z.ZodString;
|
|
1811
1822
|
teamId: z.ZodOptional<z.ZodString>;
|
|
@@ -1906,7 +1917,7 @@ export declare const domainRegistrationActionResponseSchema: z.ZodObject<{
|
|
|
1906
1917
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1907
1918
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
1908
1919
|
registrar: "registrar";
|
|
1909
|
-
|
|
1920
|
+
infra: "infra";
|
|
1910
1921
|
dns: "dns";
|
|
1911
1922
|
runtime: "runtime";
|
|
1912
1923
|
}>>>;
|
|
@@ -1949,7 +1960,7 @@ export declare const domainNameserverResponseSchema: z.ZodObject<{
|
|
|
1949
1960
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1950
1961
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
1951
1962
|
registrar: "registrar";
|
|
1952
|
-
|
|
1963
|
+
infra: "infra";
|
|
1953
1964
|
dns: "dns";
|
|
1954
1965
|
runtime: "runtime";
|
|
1955
1966
|
}>>>;
|
|
@@ -2098,7 +2109,7 @@ export declare const domainDnsModeResponseSchema: z.ZodObject<{
|
|
|
2098
2109
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2099
2110
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
2100
2111
|
registrar: "registrar";
|
|
2101
|
-
|
|
2112
|
+
infra: "infra";
|
|
2102
2113
|
dns: "dns";
|
|
2103
2114
|
runtime: "runtime";
|
|
2104
2115
|
}>>>;
|
|
@@ -2231,7 +2242,7 @@ export declare const domainDnsModeResponseSchema: z.ZodObject<{
|
|
|
2231
2242
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2232
2243
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
2233
2244
|
registrar: "registrar";
|
|
2234
|
-
|
|
2245
|
+
infra: "infra";
|
|
2235
2246
|
dns: "dns";
|
|
2236
2247
|
runtime: "runtime";
|
|
2237
2248
|
}>>>;
|
|
@@ -2299,7 +2310,7 @@ export declare const domainDnsModeResponseSchema: z.ZodObject<{
|
|
|
2299
2310
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2300
2311
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
2301
2312
|
registrar: "registrar";
|
|
2302
|
-
|
|
2313
|
+
infra: "infra";
|
|
2303
2314
|
dns: "dns";
|
|
2304
2315
|
runtime: "runtime";
|
|
2305
2316
|
}>>>;
|
|
@@ -2798,7 +2809,7 @@ export declare const domainDnsCapabilitiesSchema: z.ZodPipe<z.ZodObject<{
|
|
|
2798
2809
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2799
2810
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
2800
2811
|
registrar: "registrar";
|
|
2801
|
-
|
|
2812
|
+
infra: "infra";
|
|
2802
2813
|
dns: "dns";
|
|
2803
2814
|
runtime: "runtime";
|
|
2804
2815
|
}>>>;
|
|
@@ -2943,7 +2954,7 @@ export declare const domainDnsCapabilitiesSchema: z.ZodPipe<z.ZodObject<{
|
|
|
2943
2954
|
severity: "info" | "error" | "warning";
|
|
2944
2955
|
message: string;
|
|
2945
2956
|
path?: string | null | undefined;
|
|
2946
|
-
provider?: "registrar" | "
|
|
2957
|
+
provider?: "registrar" | "infra" | "dns" | "runtime" | null | undefined;
|
|
2947
2958
|
details?: Record<string, unknown> | null | undefined;
|
|
2948
2959
|
fix?: string | null | undefined;
|
|
2949
2960
|
retryable?: boolean | null | undefined;
|
|
@@ -3084,7 +3095,7 @@ export declare const domainDnsCapabilitiesSchema: z.ZodPipe<z.ZodObject<{
|
|
|
3084
3095
|
severity: "info" | "error" | "warning";
|
|
3085
3096
|
message: string;
|
|
3086
3097
|
path?: string | null | undefined;
|
|
3087
|
-
provider?: "registrar" | "
|
|
3098
|
+
provider?: "registrar" | "infra" | "dns" | "runtime" | null | undefined;
|
|
3088
3099
|
details?: Record<string, unknown> | null | undefined;
|
|
3089
3100
|
fix?: string | null | undefined;
|
|
3090
3101
|
retryable?: boolean | null | undefined;
|
|
@@ -3354,7 +3365,7 @@ export declare const domainProviderSnapshotRefreshResponseSchema: z.ZodObject<{
|
|
|
3354
3365
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
3355
3366
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
3356
3367
|
registrar: "registrar";
|
|
3357
|
-
|
|
3368
|
+
infra: "infra";
|
|
3358
3369
|
dns: "dns";
|
|
3359
3370
|
runtime: "runtime";
|
|
3360
3371
|
}>>>;
|
|
@@ -3426,7 +3437,7 @@ export declare const domainDnsOperationSchema: z.ZodObject<{
|
|
|
3426
3437
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
3427
3438
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
3428
3439
|
registrar: "registrar";
|
|
3429
|
-
|
|
3440
|
+
infra: "infra";
|
|
3430
3441
|
dns: "dns";
|
|
3431
3442
|
runtime: "runtime";
|
|
3432
3443
|
}>>>;
|
|
@@ -3627,7 +3638,7 @@ export declare const domainDnsOperationListResponseSchema: z.ZodObject<{
|
|
|
3627
3638
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
3628
3639
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
3629
3640
|
registrar: "registrar";
|
|
3630
|
-
|
|
3641
|
+
infra: "infra";
|
|
3631
3642
|
dns: "dns";
|
|
3632
3643
|
runtime: "runtime";
|
|
3633
3644
|
}>>>;
|
|
@@ -4160,7 +4171,7 @@ export declare const domainActionMutationResponseSchema: z.ZodObject<{
|
|
|
4160
4171
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
4161
4172
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
4162
4173
|
registrar: "registrar";
|
|
4163
|
-
|
|
4174
|
+
infra: "infra";
|
|
4164
4175
|
dns: "dns";
|
|
4165
4176
|
runtime: "runtime";
|
|
4166
4177
|
}>>>;
|
|
@@ -4490,7 +4501,7 @@ export declare const domainDnsRecordListResponseSchema: z.ZodObject<{
|
|
|
4490
4501
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
4491
4502
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
4492
4503
|
registrar: "registrar";
|
|
4493
|
-
|
|
4504
|
+
infra: "infra";
|
|
4494
4505
|
dns: "dns";
|
|
4495
4506
|
runtime: "runtime";
|
|
4496
4507
|
}>>>;
|
|
@@ -4635,7 +4646,7 @@ export declare const domainDnsRecordListResponseSchema: z.ZodObject<{
|
|
|
4635
4646
|
severity: "info" | "error" | "warning";
|
|
4636
4647
|
message: string;
|
|
4637
4648
|
path?: string | null | undefined;
|
|
4638
|
-
provider?: "registrar" | "
|
|
4649
|
+
provider?: "registrar" | "infra" | "dns" | "runtime" | null | undefined;
|
|
4639
4650
|
details?: Record<string, unknown> | null | undefined;
|
|
4640
4651
|
fix?: string | null | undefined;
|
|
4641
4652
|
retryable?: boolean | null | undefined;
|
|
@@ -4776,7 +4787,7 @@ export declare const domainDnsRecordListResponseSchema: z.ZodObject<{
|
|
|
4776
4787
|
severity: "info" | "error" | "warning";
|
|
4777
4788
|
message: string;
|
|
4778
4789
|
path?: string | null | undefined;
|
|
4779
|
-
provider?: "registrar" | "
|
|
4790
|
+
provider?: "registrar" | "infra" | "dns" | "runtime" | null | undefined;
|
|
4780
4791
|
details?: Record<string, unknown> | null | undefined;
|
|
4781
4792
|
fix?: string | null | undefined;
|
|
4782
4793
|
retryable?: boolean | null | undefined;
|
|
@@ -5004,7 +5015,7 @@ export declare const domainDiagnosticsResponseSchema: z.ZodObject<{
|
|
|
5004
5015
|
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
5005
5016
|
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
5006
5017
|
registrar: "registrar";
|
|
5007
|
-
|
|
5018
|
+
infra: "infra";
|
|
5008
5019
|
dns: "dns";
|
|
5009
5020
|
runtime: "runtime";
|
|
5010
5021
|
}>>>;
|
|
@@ -2,7 +2,7 @@ import { z } from "zod";
|
|
|
2
2
|
import { AnyObjectSchema, baseDiagnosticSchema, CursorPaginationSchema, cursorListQuerySchema, DnsInstructionSchema, mutationEnvelope, requiredActionsSchema, } from "./common.js";
|
|
3
3
|
import { PrincipalRefSchema } from "./resources.js";
|
|
4
4
|
// ---------------------------------------------------------------------------
|
|
5
|
-
// Domain resource (
|
|
5
|
+
// Domain resource (the platform spec). A canonical name
|
|
6
6
|
// owned by a tenant-local principal, plus its registrar/DNS facets and THE
|
|
7
7
|
// serving pointer/whole-host redirect intent.
|
|
8
8
|
// ---------------------------------------------------------------------------
|
|
@@ -52,7 +52,7 @@ export const domainDnsFacetSchema = z.object({
|
|
|
52
52
|
assignedNameservers: z
|
|
53
53
|
.array(z.string())
|
|
54
54
|
.optional()
|
|
55
|
-
.describe(
|
|
55
|
+
.describe("Managed-zone delegation set the registrar should point at (mode `stattic`)."),
|
|
56
56
|
observedNameservers: z
|
|
57
57
|
.array(z.string())
|
|
58
58
|
.optional()
|
|
@@ -270,6 +270,33 @@ export const teamManagedDomainListResponseSchema = z.object({
|
|
|
270
270
|
data: z.array(teamManagedDomainSchema),
|
|
271
271
|
pagination: CursorPaginationSchema,
|
|
272
272
|
});
|
|
273
|
+
// Pre-add advisory check. `canHost` mirrors the hosting provider's
|
|
274
|
+
// hostability verdict: `false` often means the domain is blocklisted or
|
|
275
|
+
// already attached to other provider infrastructure (which a later TXT
|
|
276
|
+
// ownership proof can still claim), so clients warn — they never hard-block.
|
|
277
|
+
export const domainPreflightQuerySchema = z.object({
|
|
278
|
+
name: z
|
|
279
|
+
.string()
|
|
280
|
+
.trim()
|
|
281
|
+
.min(1)
|
|
282
|
+
.max(253)
|
|
283
|
+
.describe("Apex or concrete hostname to preflight; canonicalized server-side."),
|
|
284
|
+
});
|
|
285
|
+
export const domainPreflightSchema = z.object({
|
|
286
|
+
name: z.string().describe("Canonical lowercase ASCII form of the requested hostname."),
|
|
287
|
+
unicodeName: z
|
|
288
|
+
.string()
|
|
289
|
+
.optional()
|
|
290
|
+
.describe("Read-only U-label form, present only when it differs from `name`."),
|
|
291
|
+
canHost: z
|
|
292
|
+
.boolean()
|
|
293
|
+
.nullable()
|
|
294
|
+
.describe("Provider hostability verdict. `null` when the provider check was unavailable; treat as unknown, not as failure."),
|
|
295
|
+
providerMessage: z
|
|
296
|
+
.string()
|
|
297
|
+
.nullable()
|
|
298
|
+
.describe("Provider-reported reason when the verdict is negative."),
|
|
299
|
+
});
|
|
273
300
|
export const domainCreateRequestSchema = z.object({
|
|
274
301
|
name: z
|
|
275
302
|
.string()
|
|
@@ -1,33 +1,27 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
export declare const spaceStatusValues: readonly ["provisioning", "active", "updating", "
|
|
2
|
+
export declare const spaceStatusValues: readonly ["provisioning", "active", "updating", "deleting", "failed"];
|
|
3
3
|
export declare const spaceStatus: z.ZodEnum<{
|
|
4
4
|
active: "active";
|
|
5
5
|
provisioning: "provisioning";
|
|
6
6
|
updating: "updating";
|
|
7
|
-
moving: "moving";
|
|
8
7
|
deleting: "deleting";
|
|
9
8
|
failed: "failed";
|
|
10
9
|
}>;
|
|
11
|
-
export declare const spaceDisabledReasonCodeValues: readonly ["anonymous_expired", "abuse_takedown", "tenant_suspended", "site_suspended"];
|
|
10
|
+
export declare const spaceDisabledReasonCodeValues: readonly ["anonymous_expired", "abuse_takedown", "tenant_suspended", "site_suspended", "author_removed"];
|
|
12
11
|
export declare const spaceDisabledReasonCode: z.ZodEnum<{
|
|
13
12
|
anonymous_expired: "anonymous_expired";
|
|
14
13
|
abuse_takedown: "abuse_takedown";
|
|
15
14
|
tenant_suspended: "tenant_suspended";
|
|
16
15
|
site_suspended: "site_suspended";
|
|
16
|
+
author_removed: "author_removed";
|
|
17
17
|
}>;
|
|
18
|
-
export declare const spaceTransferStatusValues: readonly ["pending_confirmation", "
|
|
18
|
+
export declare const spaceTransferStatusValues: readonly ["pending_confirmation", "completed", "canceled", "expired"];
|
|
19
19
|
export declare const spaceTransferStatus: z.ZodEnum<{
|
|
20
20
|
pending_confirmation: "pending_confirmation";
|
|
21
|
-
confirming_domains: "confirming_domains";
|
|
22
21
|
completed: "completed";
|
|
23
22
|
canceled: "canceled";
|
|
24
23
|
expired: "expired";
|
|
25
24
|
}>;
|
|
26
|
-
export declare const siteIsolationValues: readonly ["site", "space"];
|
|
27
|
-
export declare const siteIsolation: z.ZodEnum<{
|
|
28
|
-
site: "site";
|
|
29
|
-
space: "space";
|
|
30
|
-
}>;
|
|
31
25
|
export declare const tenantKindValues: readonly ["main", "platform", "partner", "internal"];
|
|
32
26
|
export declare const tenantKind: z.ZodEnum<{
|
|
33
27
|
internal: "internal";
|
|
@@ -51,6 +45,11 @@ export declare const siteKindValues: readonly ["static_runtime"];
|
|
|
51
45
|
export declare const siteKind: z.ZodEnum<{
|
|
52
46
|
static_runtime: "static_runtime";
|
|
53
47
|
}>;
|
|
48
|
+
export declare const siteIsolationValues: readonly ["site", "space"];
|
|
49
|
+
export declare const siteIsolation: z.ZodEnum<{
|
|
50
|
+
site: "site";
|
|
51
|
+
space: "space";
|
|
52
|
+
}>;
|
|
54
53
|
export declare const siteStatusValues: readonly ["ready_pool", "active", "provisioning", "degraded", "suspended", "deleted"];
|
|
55
54
|
export declare const siteStatus: z.ZodEnum<{
|
|
56
55
|
active: "active";
|
|
@@ -60,22 +59,13 @@ export declare const siteStatus: z.ZodEnum<{
|
|
|
60
59
|
ready_pool: "ready_pool";
|
|
61
60
|
degraded: "degraded";
|
|
62
61
|
}>;
|
|
63
|
-
export declare const
|
|
64
|
-
export declare const
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
}>;
|
|
71
|
-
export declare const normalizedSiteClassValues: readonly ["shared", "dedicated"];
|
|
72
|
-
export declare const normalizedSiteClass: z.ZodEnum<{
|
|
73
|
-
shared: "shared";
|
|
74
|
-
dedicated: "dedicated";
|
|
75
|
-
}>;
|
|
76
|
-
export declare function normalizeSiteClass(value: SiteClass): NormalizedSiteClass;
|
|
77
|
-
export declare function siteClassIsShared(value: SiteClass): boolean;
|
|
78
|
-
export declare function siteClassIsDedicated(value: SiteClass): boolean;
|
|
62
|
+
export declare const poolSiteStatusValues: readonly ["provisioning", "ready_pool", "degraded", "retired"];
|
|
63
|
+
export declare const poolSiteStatus: z.ZodEnum<{
|
|
64
|
+
provisioning: "provisioning";
|
|
65
|
+
ready_pool: "ready_pool";
|
|
66
|
+
degraded: "degraded";
|
|
67
|
+
retired: "retired";
|
|
68
|
+
}>;
|
|
79
69
|
export declare const publishSourceKindValues: readonly ["direct_upload", "cli", "dashboard", "api", "git", "import", "agent", "build", "variable_update", "config_update"];
|
|
80
70
|
export declare const publishSourceKind: z.ZodEnum<{
|
|
81
71
|
build: "build";
|
|
@@ -121,6 +111,7 @@ export declare const buildStatus: z.ZodEnum<{
|
|
|
121
111
|
succeeded: "succeeded";
|
|
122
112
|
skipped: "skipped";
|
|
123
113
|
}>;
|
|
114
|
+
export type BuildStatus = z.infer<typeof buildStatus>;
|
|
124
115
|
export declare const diagnosticSeverity: z.ZodEnum<{
|
|
125
116
|
info: "info";
|
|
126
117
|
error: "error";
|
|
@@ -128,7 +119,7 @@ export declare const diagnosticSeverity: z.ZodEnum<{
|
|
|
128
119
|
}>;
|
|
129
120
|
export declare const diagnosticProvider: z.ZodEnum<{
|
|
130
121
|
registrar: "registrar";
|
|
131
|
-
|
|
122
|
+
infra: "infra";
|
|
132
123
|
dns: "dns";
|
|
133
124
|
runtime: "runtime";
|
|
134
125
|
}>;
|
|
@@ -152,6 +143,19 @@ export declare const safetyCategory: z.ZodEnum<{
|
|
|
152
143
|
compromised_account: "compromised_account";
|
|
153
144
|
other_violation: "other_violation";
|
|
154
145
|
}>;
|
|
146
|
+
export declare const safetyResolutionReasonValues: readonly ["malware_confirmed", "phishing_confirmed", "csam_escalated", "spam_confirmed", "copyright_takedown", "false_positive", "test_detection", "duplicate", "insufficient_evidence", "other"];
|
|
147
|
+
export declare const safetyResolutionReason: z.ZodEnum<{
|
|
148
|
+
malware_confirmed: "malware_confirmed";
|
|
149
|
+
phishing_confirmed: "phishing_confirmed";
|
|
150
|
+
csam_escalated: "csam_escalated";
|
|
151
|
+
spam_confirmed: "spam_confirmed";
|
|
152
|
+
copyright_takedown: "copyright_takedown";
|
|
153
|
+
false_positive: "false_positive";
|
|
154
|
+
test_detection: "test_detection";
|
|
155
|
+
duplicate: "duplicate";
|
|
156
|
+
insufficient_evidence: "insufficient_evidence";
|
|
157
|
+
other: "other";
|
|
158
|
+
}>;
|
|
155
159
|
export declare const SAFETY_SEVERITY: {
|
|
156
160
|
readonly suspicious: 1;
|
|
157
161
|
readonly low: 2;
|
|
@@ -175,11 +179,11 @@ export declare const operationStatus: z.ZodEnum<{
|
|
|
175
179
|
}>;
|
|
176
180
|
export type GitProvider = z.infer<typeof gitProvider>;
|
|
177
181
|
export type PublishSourceKind = z.infer<typeof publishSourceKind>;
|
|
182
|
+
export type PoolSiteStatus = z.infer<typeof poolSiteStatus>;
|
|
183
|
+
export type SiteKind = z.infer<typeof siteKind>;
|
|
178
184
|
export type SiteIsolation = z.infer<typeof siteIsolation>;
|
|
179
185
|
export type TenantStatus = z.infer<typeof tenantStatus>;
|
|
180
|
-
export type SiteKind = z.infer<typeof siteKind>;
|
|
181
|
-
export type SiteClass = z.infer<typeof siteClass>;
|
|
182
|
-
export type NormalizedSiteClass = z.infer<typeof normalizedSiteClass>;
|
|
183
186
|
export type OperationStatus = z.infer<typeof operationStatus>;
|
|
184
187
|
export type SafetyCategory = z.infer<typeof safetyCategory>;
|
|
188
|
+
export type SafetyResolutionReason = z.infer<typeof safetyResolutionReason>;
|
|
185
189
|
export type EnforcementTier = z.infer<typeof enforcementTier>;
|
package/dist/contracts/enums.js
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
// Space operation-lifecycle axis (
|
|
3
|
-
// these
|
|
4
|
-
// a disabled space can still be updating
|
|
2
|
+
// Space operation-lifecycle axis (the platform spec "Space"): exactly
|
|
3
|
+
// these five. Serving (disabled) and deletion (deletedAt) are separate axes —
|
|
4
|
+
// a disabled space can still be updating. There is no `moving`: a space IS a
|
|
5
|
+
// site, so ownership changes commit in place and nothing relocates.
|
|
5
6
|
export const spaceStatusValues = [
|
|
6
7
|
"provisioning",
|
|
7
8
|
"active",
|
|
8
9
|
"updating",
|
|
9
|
-
"moving",
|
|
10
10
|
"deleting",
|
|
11
11
|
"failed",
|
|
12
12
|
];
|
|
13
13
|
export const spaceStatus = z.enum(spaceStatusValues);
|
|
14
|
-
// Serving-axis disable reasons (
|
|
14
|
+
// Serving-axis disable reasons (the platform spec "Space"). Confirmed
|
|
15
15
|
// scan takedowns use `abuse_takedown`; infected state and claim invalidation
|
|
16
16
|
// are explicit enforcement effects, not reason metadata.
|
|
17
17
|
export const spaceDisabledReasonCodeValues = [
|
|
@@ -19,27 +19,26 @@ export const spaceDisabledReasonCodeValues = [
|
|
|
19
19
|
"abuse_takedown",
|
|
20
20
|
"tenant_suspended",
|
|
21
21
|
"site_suspended",
|
|
22
|
+
// Space-key author delete, phase one: the holder of an unclaimed space's key
|
|
23
|
+
// took the site dark. The key survives, so the same key can restore (or
|
|
24
|
+
// claim) until the claim window expires; expiry then hard-deletes as usual.
|
|
25
|
+
"author_removed",
|
|
22
26
|
];
|
|
23
27
|
export const spaceDisabledReasonCode = z.enum(spaceDisabledReasonCodeValues);
|
|
24
|
-
// SpaceTransfer status machine (
|
|
25
|
-
// semantics"), stored directly — there is no separate DB vocabulary.
|
|
26
|
-
//
|
|
27
|
-
//
|
|
28
|
-
//
|
|
29
|
-
// on `canceled`.
|
|
28
|
+
// SpaceTransfer status machine (the platform spec "Transfer
|
|
29
|
+
// semantics"), stored directly — there is no separate DB vocabulary. A
|
|
30
|
+
// transfer is a request that the receiving side accepts; accepting moves
|
|
31
|
+
// ownership in one database transaction, so there is no intermediate moving
|
|
32
|
+
// state and no `failed` state. Withdraw (from-side) and decline (to-side)
|
|
33
|
+
// both land on `canceled`.
|
|
30
34
|
export const spaceTransferStatusValues = [
|
|
31
35
|
"pending_confirmation",
|
|
32
|
-
"confirming_domains",
|
|
33
36
|
"completed",
|
|
34
37
|
"canceled",
|
|
35
38
|
"expired",
|
|
36
39
|
];
|
|
37
40
|
export const spaceTransferStatus = z.enum(spaceTransferStatusValues);
|
|
38
|
-
//
|
|
39
|
-
// whether settings/access default to the site or to each space.
|
|
40
|
-
export const siteIsolationValues = ["site", "space"];
|
|
41
|
-
export const siteIsolation = z.enum(siteIsolationValues);
|
|
42
|
-
// A tenant is the platform-account boundary that owns every resource (internal-docs/platform.md
|
|
41
|
+
// A tenant is the platform-account boundary that owns every resource (the platform spec
|
|
43
42
|
// "Tenant -> Site -> Space"), Stripe-style. `main` is the single well-known
|
|
44
43
|
// Stattic account (`ten_main`) all self-serve teams/users live under;
|
|
45
44
|
// `platform` and `partner` are host integrations with their own user
|
|
@@ -56,12 +55,21 @@ export const tenantStatus = z.enum(tenantStatusValues);
|
|
|
56
55
|
// (operator-only resource, `pvc_` prefix).
|
|
57
56
|
export const providerClientStatusValues = ["active", "disabled"];
|
|
58
57
|
export const providerClientStatus = z.enum(providerClientStatusValues);
|
|
59
|
-
//
|
|
60
|
-
//
|
|
58
|
+
// The only site shape there is. Kept as a named vocabulary because the sites
|
|
59
|
+
// table spells it as an enum column; a dead-code sweep removed it while that
|
|
60
|
+
// column still referenced it.
|
|
61
61
|
export const siteKindValues = ["static_runtime"];
|
|
62
62
|
export const siteKind = z.enum(siteKindValues);
|
|
63
|
-
//
|
|
64
|
-
//
|
|
63
|
+
// Whether settings and access default to the site or to each space. Same story
|
|
64
|
+
// as the two vocabularies around it: a dead-code sweep took it while the
|
|
65
|
+
// `sites` table's own column still named it.
|
|
66
|
+
export const siteIsolationValues = ["site", "space"];
|
|
67
|
+
export const siteIsolation = z.enum(siteIsolationValues);
|
|
68
|
+
// Site lifecycle. A dead-code sweep removed this vocabulary while two live
|
|
69
|
+
// consumers still needed it: the `sites` table's own status column and the
|
|
70
|
+
// superadmin provider-site search result. `ready_pool` is a pre-provisioned
|
|
71
|
+
// warm site waiting to be claimed — load-bearing now that every space draws
|
|
72
|
+
// its own site from the pool.
|
|
65
73
|
export const siteStatusValues = [
|
|
66
74
|
"ready_pool",
|
|
67
75
|
"active",
|
|
@@ -71,28 +79,16 @@ export const siteStatusValues = [
|
|
|
71
79
|
"deleted",
|
|
72
80
|
];
|
|
73
81
|
export const siteStatus = z.enum(siteStatusValues);
|
|
74
|
-
//
|
|
75
|
-
//
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
export const normalizedSiteClassValues = ["shared", "dedicated"];
|
|
85
|
-
export const normalizedSiteClass = z.enum(normalizedSiteClassValues);
|
|
86
|
-
export function normalizeSiteClass(value) {
|
|
87
|
-
return value === "dedicated" || value === "dedicated_space" ? "dedicated" : "shared";
|
|
88
|
-
}
|
|
89
|
-
export function siteClassIsShared(value) {
|
|
90
|
-
return normalizeSiteClass(value) === "shared";
|
|
91
|
-
}
|
|
92
|
-
export function siteClassIsDedicated(value) {
|
|
93
|
-
return normalizeSiteClass(value) === "dedicated";
|
|
94
|
-
}
|
|
95
|
-
// PublishSource.kind (internal-docs/platform.md "PublishSource"): the single
|
|
82
|
+
// Warm-pool inventory (`site_pool`): provider sites provisioned ahead of
|
|
83
|
+
// demand, with no owner yet. A space IS a site, so these statuses are the
|
|
84
|
+
// whole lifecycle a row can have before a space adopts it and the row is
|
|
85
|
+
// deleted — `active`/`suspended`/`deleted` were live-space states and now live
|
|
86
|
+
// on the space's own axes. `retired` holds a drained space=site migration
|
|
87
|
+
// source box: not adoptable, not reapable, kept permanently — migration
|
|
88
|
+
// tooling never deletes a wp.cloud site (owner ruling 2026-08-11).
|
|
89
|
+
export const poolSiteStatusValues = ["provisioning", "ready_pool", "degraded", "retired"];
|
|
90
|
+
export const poolSiteStatus = z.enum(poolSiteStatusValues);
|
|
91
|
+
// PublishSource.kind (the platform spec "PublishSource"): the single
|
|
96
92
|
// provenance axis for how a version came to exist. `variable_update` and
|
|
97
93
|
// `config_update` versions are minted by cascades/config regeneration.
|
|
98
94
|
export const publishSourceKindValues = [
|
|
@@ -109,7 +105,7 @@ export const publishSourceKindValues = [
|
|
|
109
105
|
];
|
|
110
106
|
export const publishSourceKind = z.enum(publishSourceKindValues);
|
|
111
107
|
export const versionStatusValues = [
|
|
112
|
-
// Spec state machine (
|
|
108
|
+
// Spec state machine (the platform spec "Upload Contract"):
|
|
113
109
|
// created -> uploading -> uploaded -> finalizing -> ready, with terminal
|
|
114
110
|
// failed/canceled/expired. Build runs are tracked on the Build resource;
|
|
115
111
|
// a building version stays `created` until upload starts.
|
|
@@ -137,7 +133,7 @@ export const VERSION_IN_FLIGHT_STATUSES = [
|
|
|
137
133
|
"uploaded",
|
|
138
134
|
"finalizing",
|
|
139
135
|
];
|
|
140
|
-
// Build resource statuses (
|
|
136
|
+
// Build resource statuses (the platform spec "Build", `bld_`).
|
|
141
137
|
export const buildStatusValues = [
|
|
142
138
|
"waiting_for_source",
|
|
143
139
|
"uploading_source",
|
|
@@ -150,9 +146,9 @@ export const buildStatusValues = [
|
|
|
150
146
|
];
|
|
151
147
|
export const buildStatus = z.enum(buildStatusValues);
|
|
152
148
|
export const diagnosticSeverity = z.enum(["info", "warning", "error"]);
|
|
153
|
-
// Upstream system a Diagnostic originated from
|
|
154
|
-
//
|
|
155
|
-
export const diagnosticProvider = z.enum(["
|
|
149
|
+
// Upstream system a Diagnostic originated from. Absent when the diagnostic is
|
|
150
|
+
// Stattic's own (validation, routing compile, upload policy, ...).
|
|
151
|
+
export const diagnosticProvider = z.enum(["infra", "dns", "registrar", "runtime"]);
|
|
156
152
|
// Internal domain DB-column vocabularies (consumed by the control-plane schema;
|
|
157
153
|
// never part of the public Domain contract, which lives in contracts/domains.ts).
|
|
158
154
|
export const domainOwnershipTypeValues = [
|
|
@@ -202,6 +198,24 @@ export const safetyCategoryValues = [
|
|
|
202
198
|
"other_violation",
|
|
203
199
|
];
|
|
204
200
|
export const safetyCategory = z.enum(safetyCategoryValues);
|
|
201
|
+
// Why a review item was closed (or a space taken down): the operator's verdict
|
|
202
|
+
// in one word, so enforcement quality is measurable without parsing notes.
|
|
203
|
+
// Confirmed-* reasons say the detection was right; the tail says it wasn't
|
|
204
|
+
// (false_positive, test_detection) or the item never needed its own verdict
|
|
205
|
+
// (duplicate, insufficient_evidence, other).
|
|
206
|
+
export const safetyResolutionReasonValues = [
|
|
207
|
+
"malware_confirmed",
|
|
208
|
+
"phishing_confirmed",
|
|
209
|
+
"csam_escalated",
|
|
210
|
+
"spam_confirmed",
|
|
211
|
+
"copyright_takedown",
|
|
212
|
+
"false_positive",
|
|
213
|
+
"test_detection",
|
|
214
|
+
"duplicate",
|
|
215
|
+
"insufficient_evidence",
|
|
216
|
+
"other",
|
|
217
|
+
];
|
|
218
|
+
export const safetyResolutionReason = z.enum(safetyResolutionReasonValues);
|
|
205
219
|
// 1 = suspicious, 2 = low, 3 = medium, 4 = high, 5 = critical.
|
|
206
220
|
export const SAFETY_SEVERITY = {
|
|
207
221
|
suspicious: 1,
|