@spacefast/common 0.0.26 → 0.2.2
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/agents/connect-targets.d.ts +6 -146
- package/dist/agents/connect-targets.js +63 -295
- package/dist/agents/private-key-oauth.d.ts +31 -1
- package/dist/agents/private-key-oauth.js +124 -33
- package/dist/agents/registry/core.d.ts +292 -0
- package/dist/agents/registry/core.js +1388 -0
- package/dist/agents/registry/deeplink-probes.d.ts +23 -0
- package/dist/agents/registry/deeplink-probes.js +18 -0
- package/dist/agents/registry/node.d.ts +56 -0
- package/dist/agents/registry/node.js +339 -0
- package/dist/brand-assets-build.js +1 -2
- package/dist/brand-assets.js +4 -7
- package/dist/brand.d.ts +17 -0
- package/dist/brand.js +24 -4
- package/dist/config/domains.d.ts +55 -28
- package/dist/config/domains.js +85 -41
- package/dist/config/index.js +1 -2
- package/dist/contracts/abuse.js +9 -24
- package/dist/contracts/access-profiles.d.ts +86 -0
- package/dist/contracts/access-profiles.js +89 -0
- package/dist/contracts/access.d.ts +21 -27
- package/dist/contracts/access.js +33 -64
- package/dist/contracts/activity.d.ts +18 -1
- package/dist/contracts/activity.js +70 -26
- package/dist/contracts/analytics.js +8 -10
- package/dist/contracts/api-keys.d.ts +77 -52
- package/dist/contracts/api-keys.js +44 -24
- package/dist/contracts/application-journal.d.ts +216 -0
- package/dist/contracts/application-journal.js +167 -0
- package/dist/contracts/auth.d.ts +90 -17
- package/dist/contracts/auth.js +86 -17
- package/dist/contracts/beta.d.ts +9 -4
- package/dist/contracts/beta.js +20 -16
- package/dist/contracts/billing.js +7 -11
- package/dist/contracts/bootstrap.d.ts +791 -0
- package/dist/contracts/bootstrap.js +51 -0
- package/dist/contracts/builds.d.ts +192 -7
- package/dist/contracts/builds.js +84 -21
- package/dist/contracts/channels.d.ts +43 -0
- package/dist/contracts/channels.js +25 -9
- package/dist/contracts/cli.d.ts +7 -0
- package/dist/contracts/cli.js +6 -0
- package/dist/contracts/collab-public.d.ts +1 -1
- package/dist/contracts/collab-public.js +5 -8
- package/dist/contracts/comments.d.ts +45 -35
- package/dist/contracts/comments.js +107 -77
- package/dist/contracts/commerce.d.ts +165 -0
- package/dist/contracts/commerce.js +146 -0
- package/dist/contracts/common.d.ts +3 -3
- package/dist/contracts/common.js +18 -29
- package/dist/contracts/content-contract-verification.d.ts +521 -0
- package/dist/contracts/content-contract-verification.js +320 -0
- package/dist/contracts/content-platform-fixture.d.ts +1278 -0
- package/dist/contracts/content-platform-fixture.js +44 -0
- package/dist/contracts/content-program.d.ts +994 -0
- package/dist/contracts/content-program.js +658 -0
- package/dist/contracts/content-sync.d.ts +290 -0
- package/dist/contracts/content-sync.js +167 -0
- package/dist/contracts/content.d.ts +432 -0
- package/dist/contracts/content.js +303 -0
- package/dist/contracts/continuation.d.ts +17 -1
- package/dist/contracts/continuation.js +23 -23
- package/dist/contracts/countries.js +3 -4
- package/dist/contracts/crons.d.ts +17 -0
- package/dist/contracts/crons.js +33 -15
- package/dist/contracts/dashboard-prefs.d.ts +56 -0
- package/dist/contracts/dashboard-prefs.js +51 -0
- package/dist/contracts/device-auth.d.ts +234 -37
- package/dist/contracts/device-auth.js +267 -53
- package/dist/contracts/docs.d.ts +6 -10
- package/dist/contracts/docs.js +5 -13
- package/dist/contracts/domains.d.ts +499 -102
- package/dist/contracts/domains.js +169 -58
- package/dist/contracts/email-preferences.d.ts +3 -3
- package/dist/contracts/email-preferences.js +6 -7
- package/dist/contracts/enums.d.ts +26 -26
- package/dist/contracts/enums.js +61 -54
- package/dist/contracts/error-code-meta.d.ts +273 -7
- package/dist/contracts/error-code-meta.js +81 -5
- package/dist/contracts/error-codes.d.ts +5 -5
- package/dist/contracts/error-codes.js +79 -16
- package/dist/contracts/events.d.ts +100 -20
- package/dist/contracts/events.js +107 -20
- package/dist/contracts/execution.d.ts +47 -66
- package/dist/contracts/execution.js +51 -64
- package/dist/contracts/feature-lifecycle.d.ts +70 -14
- package/dist/contracts/feature-lifecycle.js +86 -15
- package/dist/contracts/features.d.ts +100 -37
- package/dist/contracts/features.js +21 -27
- package/dist/contracts/fixtures/content-platform-v1.json +1108 -0
- package/dist/contracts/frame-session.d.ts +192 -0
- package/dist/contracts/frame-session.js +164 -0
- package/dist/contracts/functions.d.ts +218 -211
- package/dist/contracts/functions.js +273 -260
- package/dist/contracts/grant-copy.d.ts +43 -0
- package/dist/contracts/grant-copy.js +44 -0
- package/dist/contracts/grants.d.ts +64 -56
- package/dist/contracts/grants.js +124 -23
- package/dist/contracts/ids.d.ts +4 -1
- package/dist/contracts/ids.js +4 -1
- package/dist/contracts/internal.d.ts +5 -4
- package/dist/contracts/internal.js +12 -3
- package/dist/contracts/mcp.d.ts +17 -0
- package/dist/contracts/mcp.js +23 -0
- package/dist/contracts/me.d.ts +6 -1
- package/dist/contracts/me.js +12 -6
- package/dist/contracts/notifications.d.ts +27 -29
- package/dist/contracts/notifications.js +9 -4
- package/dist/contracts/oauth-resources.d.ts +121 -10
- package/dist/contracts/oauth-resources.js +130 -11
- package/dist/contracts/oauth-scope-actions.d.ts +90 -0
- package/dist/contracts/oauth-scope-actions.js +126 -0
- package/dist/contracts/operations.d.ts +27 -4
- package/dist/contracts/operations.js +11 -5
- package/dist/contracts/pages.d.ts +29 -5
- package/dist/contracts/pages.js +22 -5
- package/dist/contracts/partner-notifications.d.ts +3 -0
- package/dist/contracts/partner-notifications.js +65 -0
- package/dist/contracts/{platform.d.ts → partner.d.ts} +29 -42
- package/dist/contracts/{platform.js → partner.js} +27 -40
- package/dist/contracts/plan-policy.d.ts +1 -1
- package/dist/contracts/principal-assertion.d.ts +43 -0
- package/dist/contracts/principal-assertion.js +67 -0
- package/dist/contracts/principals.d.ts +73 -0
- package/dist/contracts/principals.js +59 -0
- package/dist/contracts/privacy.d.ts +11 -0
- package/dist/contracts/privacy.js +17 -0
- package/dist/contracts/problem-document.js +3 -4
- package/dist/contracts/publish-archive.d.ts +116 -18
- package/dist/contracts/publish-archive.js +6 -3
- package/dist/contracts/push-new.d.ts +4 -4
- package/dist/contracts/quotas.js +3 -3
- package/dist/contracts/realtime.d.ts +52 -0
- package/dist/contracts/realtime.js +54 -0
- package/dist/contracts/repository-connections.d.ts +1 -1
- package/dist/contracts/repository-connections.js +6 -2
- package/dist/contracts/resources.d.ts +105 -14
- package/dist/contracts/resources.js +145 -21
- package/dist/contracts/route-inventory.d.ts +358 -0
- package/dist/contracts/route-inventory.js +141 -0
- package/dist/contracts/runtime-api.d.ts +112 -35
- package/dist/contracts/runtime-api.js +86 -66
- package/dist/contracts/runtime-app.d.ts +11 -21
- package/dist/contracts/runtime-app.js +39 -24
- package/dist/contracts/runtime-components.d.ts +143 -0
- package/dist/contracts/runtime-components.js +199 -0
- package/dist/contracts/runtime-db.d.ts +45 -19
- package/dist/contracts/runtime-db.js +85 -20
- package/dist/contracts/runtime-purge.js +3 -5
- package/dist/contracts/runtime-services.d.ts +43 -75
- package/dist/contracts/runtime-services.js +29 -49
- package/dist/contracts/runtime-storage.d.ts +14 -14
- package/dist/contracts/runtime-storage.js +28 -13
- package/dist/contracts/sf-config-v1.d.ts +14 -18
- package/dist/contracts/slugs.js +13 -4
- package/dist/contracts/space-config.d.ts +235 -28
- package/dist/contracts/space-config.js +246 -91
- package/dist/contracts/spaces.d.ts +360 -255
- package/dist/contracts/spaces.js +190 -122
- package/dist/contracts/superadmin-activity.d.ts +3 -43
- package/dist/contracts/superadmin-activity.js +6 -30
- package/dist/contracts/superadmin-emails.d.ts +1 -0
- package/dist/contracts/superadmin-emails.js +17 -1
- package/dist/contracts/superadmin-runtime.d.ts +199 -0
- package/dist/contracts/superadmin-runtime.js +141 -0
- package/dist/contracts/superadmin-search.d.ts +22 -2
- package/dist/contracts/superadmin-search.js +14 -6
- package/dist/contracts/superadmin-spaces.d.ts +435 -186
- package/dist/contracts/superadmin-spaces.js +131 -25
- package/dist/contracts/superadmin-teams.d.ts +3 -0
- package/dist/contracts/superadmin-teams.js +1 -2
- package/dist/contracts/superadmin-tenants.d.ts +627 -6
- package/dist/contracts/superadmin-tenants.js +32 -7
- package/dist/contracts/superadmin.d.ts +98 -16
- package/dist/contracts/superadmin.js +63 -10
- package/dist/contracts/tags.d.ts +85 -58
- package/dist/contracts/tags.js +44 -34
- package/dist/contracts/teams.d.ts +72 -9
- package/dist/contracts/teams.js +84 -25
- package/dist/contracts/tenants.d.ts +135 -0
- package/dist/contracts/tenants.js +120 -0
- package/dist/contracts/test-triggers.d.ts +70 -0
- package/dist/contracts/test-triggers.js +116 -0
- package/dist/contracts/theme-json.js +3 -8
- package/dist/contracts/transfers.d.ts +1 -0
- package/dist/contracts/transfers.js +1 -0
- package/dist/contracts/usage.d.ts +209 -0
- package/dist/contracts/usage.js +124 -12
- package/dist/contracts/variables.d.ts +2 -2
- package/dist/contracts/variables.js +9 -13
- package/dist/contracts/webhooks.d.ts +13 -5
- package/dist/contracts/webhooks.js +3 -1
- package/dist/contracts/zero.d.ts +57 -64
- package/dist/contracts/zero.js +68 -66
- package/dist/dashboard-paths/index.d.ts +24 -21
- package/dist/dashboard-paths/index.js +35 -47
- package/dist/dashboard-paths/route-reservations.generated.d.ts +2 -0
- package/dist/dashboard-paths/route-reservations.generated.js +36 -0
- package/dist/docs/agent-arrival.d.ts +92 -0
- package/dist/docs/agent-arrival.js +227 -0
- package/dist/docs/agent-output-policy.d.ts +6 -0
- package/dist/docs/agent-output-policy.js +22 -0
- package/dist/docs/agent-prose.d.ts +11 -17
- package/dist/docs/agent-prose.js +62 -37
- package/dist/docs/agent-setup.d.ts +72 -41
- package/dist/docs/agent-setup.js +336 -436
- package/dist/docs/catalog.d.ts +147 -89
- package/dist/docs/catalog.js +157 -42
- package/dist/docs/error-docs.d.ts +2102 -1
- package/dist/docs/error-docs.js +285 -16
- package/dist/docs/index-build.d.ts +0 -1
- package/dist/docs/index-build.js +2 -3
- package/dist/docs/page-context-prompt.d.ts +77 -0
- package/dist/docs/page-context-prompt.js +131 -0
- package/dist/docs/reference-urls.d.ts +46 -0
- package/dist/docs/reference-urls.js +79 -0
- package/dist/docs/search.d.ts +6 -8
- package/dist/docs/search.js +10 -13
- package/dist/docs/skill-distribution.d.ts +4 -1
- package/dist/docs/skill-distribution.js +10 -5
- package/dist/docs/skills.d.ts +117 -117
- package/dist/docs/skills.js +120 -72
- package/dist/docs/start-prompts.d.ts +45 -0
- package/dist/docs/start-prompts.js +62 -0
- package/dist/domain-exploration.js +9 -13
- package/dist/og-template.d.ts +56 -0
- package/dist/og-template.js +56 -0
- package/dist/slug-policy/index.js +5 -11
- package/dist/utils/browser-credential.d.ts +13 -6
- package/dist/utils/browser-credential.js +14 -7
- package/dist/utils/build-settings.d.ts +16 -0
- package/dist/utils/build-settings.js +63 -17
- package/dist/utils/canonical-json.d.ts +3 -5
- package/dist/utils/canonical-json.js +3 -5
- package/dist/utils/cast-transport.d.ts +5 -17
- package/dist/utils/cast-transport.js +6 -19
- package/dist/utils/claim-token.js +1 -2
- package/dist/utils/comment-avatars.js +4 -6
- package/dist/utils/concurrency.js +2 -3
- package/dist/utils/content-type.d.ts +7 -6
- package/dist/utils/content-type.js +73 -51
- package/dist/utils/credential-policy.d.ts +50 -6
- package/dist/utils/credential-policy.js +123 -57
- package/dist/utils/egress-policy.fixtures.json +1 -1
- package/dist/utils/generate-space-name.d.ts +3 -8
- package/dist/utils/generate-space-name.js +3 -8
- package/dist/utils/grants.d.ts +0 -1
- package/dist/utils/grants.js +4 -7
- package/dist/utils/gravatar.d.ts +2 -4
- package/dist/utils/gravatar.js +6 -12
- package/dist/utils/id-hints.js +14 -23
- package/dist/utils/idempotency.d.ts +3 -3
- package/dist/utils/idempotency.js +6 -7
- package/dist/utils/local-space-state.d.ts +15 -15
- package/dist/utils/local-space-state.js +34 -23
- package/dist/utils/oauth-signed-query.d.ts +3 -5
- package/dist/utils/oauth-signed-query.js +6 -9
- package/dist/utils/one-shot-replay.d.ts +3 -5
- package/dist/utils/one-shot-replay.js +3 -5
- package/dist/utils/page-colors.d.ts +4 -10
- package/dist/utils/page-colors.js +11 -35
- package/dist/utils/page-fonts.js +6 -11
- package/dist/utils/page-preview.d.ts +0 -1
- package/dist/utils/page-preview.js +0 -1
- package/dist/utils/pages.d.ts +22 -11
- package/dist/utils/pages.js +70 -30
- package/dist/utils/privacy-regions.d.ts +19 -0
- package/dist/utils/privacy-regions.js +91 -0
- package/dist/utils/publish-form-data.d.ts +4 -5
- package/dist/utils/publish-form-data.js +2 -3
- package/dist/utils/publish-policy.d.ts +10 -23
- package/dist/utils/publish-policy.js +63 -116
- package/dist/utils/query-client.d.ts +2 -0
- package/dist/utils/query-client.js +10 -1
- package/dist/utils/runtime-paths.d.ts +4 -4
- package/dist/utils/runtime-paths.js +6 -8
- package/dist/utils/runtime-upload.d.ts +4 -0
- package/dist/utils/runtime-upload.js +5 -0
- package/dist/utils/secure-local-file.d.ts +3 -3
- package/dist/utils/secure-local-file.js +18 -24
- package/dist/utils/space-config.d.ts +11 -14
- package/dist/utils/space-config.js +10 -16
- package/dist/utils/static-runtime-policy.d.ts +5 -8
- package/dist/utils/static-runtime-policy.generated.d.ts +16 -0
- package/dist/utils/static-runtime-policy.generated.js +70 -0
- package/dist/utils/static-runtime-policy.js +17 -84
- package/dist/utils/storage-policy.js +1 -2
- package/dist/utils/upload-session.js +8 -14
- package/dist/utils/version-path.js +11 -19
- package/dist/utils/wpcom-auth-redirects.d.ts +5 -14
- package/dist/utils/wpcom-auth-redirects.js +1 -4
- package/dist/vocabulary.d.ts +7 -7
- package/dist/vocabulary.js +30 -16
- package/package.json +14 -2
- package/dist/agents/client-registry.d.ts +0 -22
- package/dist/agents/client-registry.js +0 -41
- package/dist/docs/agent-handoff-document.d.ts +0 -15
- package/dist/docs/agent-handoff-document.js +0 -180
- package/dist/docs/agent-solutions.d.ts +0 -110
- package/dist/docs/agent-solutions.js +0 -183
- package/dist/utils/query-keys.d.ts +0 -84
- package/dist/utils/query-keys.js +0 -108
|
@@ -39,6 +39,7 @@ export const ERROR_CODE_META = {
|
|
|
39
39
|
api_key_scope_underivable: { retryable: false, recovery: "fix_input" },
|
|
40
40
|
archive_too_large: { retryable: false, recovery: "fix_input" },
|
|
41
41
|
auth_code_required: { retryable: false, recovery: "re_auth" },
|
|
42
|
+
authorization_level_not_allowed: { retryable: false, recovery: "contact_support" },
|
|
42
43
|
authorization_pending: { retryable: true, recovery: "wait" },
|
|
43
44
|
blob_gate_record_missing: { retryable: false, recovery: "fix_input" },
|
|
44
45
|
blob_gate_token_invalid: { retryable: false, recovery: "re_auth" },
|
|
@@ -76,6 +77,19 @@ export const ERROR_CODE_META = {
|
|
|
76
77
|
config_runtime_entry_missing: { retryable: false, recovery: "fix_input" },
|
|
77
78
|
config_runtime_invalid_kind: { retryable: false, recovery: "fix_input" },
|
|
78
79
|
config_templates_over_limit: { retryable: false, recovery: "fix_input" },
|
|
80
|
+
confirmation_denied: { retryable: false, recovery: "contact_support" },
|
|
81
|
+
confirmation_expired: { retryable: false, recovery: "fix_input" },
|
|
82
|
+
confirmation_mismatch: { retryable: false, recovery: "fix_input" },
|
|
83
|
+
confirmation_required: {
|
|
84
|
+
retryable: false,
|
|
85
|
+
recovery: "wait",
|
|
86
|
+
next: [
|
|
87
|
+
"Open the `url` in the error details so a person can approve or deny it",
|
|
88
|
+
"POST the `continuationToken` to /v1/actions/resume every 5 seconds",
|
|
89
|
+
"Give up after 10 minutes, report to your human, and stop",
|
|
90
|
+
],
|
|
91
|
+
},
|
|
92
|
+
confirmation_token_required: { retryable: false, recovery: "fix_input" },
|
|
79
93
|
continuation_unavailable: {
|
|
80
94
|
retryable: false,
|
|
81
95
|
recovery: "re_auth",
|
|
@@ -98,10 +112,20 @@ export const ERROR_CODE_META = {
|
|
|
98
112
|
credential_not_yet_valid: { retryable: true, recovery: "wait" },
|
|
99
113
|
credential_retired: { retryable: false, recovery: "re_auth" },
|
|
100
114
|
credential_revoked: { retryable: false, recovery: "re_auth" },
|
|
115
|
+
credential_sponsor_inactive: { retryable: false, recovery: "contact_support" },
|
|
101
116
|
csam_blocked: { retryable: false, recovery: "contact_support" },
|
|
102
117
|
csam_policy_floor: { retryable: false, recovery: "contact_support" },
|
|
118
|
+
dashboard_prefs_key_invalid: { retryable: false, recovery: "fix_input" },
|
|
119
|
+
dashboard_prefs_too_large: { retryable: false, recovery: "fix_input" },
|
|
120
|
+
dashboard_prefs_too_many_keys: { retryable: false, recovery: "fix_input" },
|
|
103
121
|
data_location_immutable: { retryable: false, recovery: "fix_input" },
|
|
104
122
|
db_not_available: { retryable: false, recovery: "fix_input" },
|
|
123
|
+
decision_execution_lost: { retryable: false, recovery: "fix_input" },
|
|
124
|
+
decision_in_progress: {
|
|
125
|
+
retryable: true,
|
|
126
|
+
recovery: "wait",
|
|
127
|
+
next: ["POST the continuationToken to /v1/actions/resume"],
|
|
128
|
+
},
|
|
105
129
|
device_authorization_failed: { retryable: false, recovery: "re_auth" },
|
|
106
130
|
device_verification_rate_limited: {
|
|
107
131
|
retryable: true,
|
|
@@ -167,6 +191,9 @@ export const ERROR_CODE_META = {
|
|
|
167
191
|
domain_wildcard_not_enabled: { retryable: false, recovery: "fix_input" },
|
|
168
192
|
download_required: { retryable: false, recovery: "fix_input" },
|
|
169
193
|
duplicate_version_path: { retryable: false, recovery: "fix_input" },
|
|
194
|
+
elevation_not_required: { retryable: false, recovery: "fix_input" },
|
|
195
|
+
email_already_claimed: { retryable: false, recovery: "fix_input" },
|
|
196
|
+
email_verification_code_invalid: { retryable: false, recovery: "fix_input" },
|
|
170
197
|
enforcement_policy_overlap: { retryable: false, recovery: "fix_input" },
|
|
171
198
|
event_payload_too_large: { retryable: false, recovery: "fix_input" },
|
|
172
199
|
event_rate_limited: {
|
|
@@ -185,13 +212,16 @@ export const ERROR_CODE_META = {
|
|
|
185
212
|
inject_invalid: { retryable: false, recovery: "fix_input" },
|
|
186
213
|
inject_snippet_too_large: { retryable: false, recovery: "fix_input" },
|
|
187
214
|
ingest_admission_exceeded: { retryable: true, recovery: "wait" },
|
|
215
|
+
insufficient_scope: { retryable: false, recovery: "re_auth" },
|
|
188
216
|
internal_error: { retryable: true, recovery: "retry" },
|
|
189
217
|
invalid_claim_token: { retryable: false, recovery: "re_auth" },
|
|
190
218
|
invalid_continuation_token: { retryable: false, recovery: "re_auth" },
|
|
191
219
|
invalid_data_location: { retryable: false, recovery: "fix_input" },
|
|
220
|
+
invalid_decision_state: { retryable: false, recovery: "contact_support" },
|
|
192
221
|
invalid_device_code: { retryable: false, recovery: "re_auth" },
|
|
193
222
|
invalid_domain: { retryable: false, recovery: "fix_input" },
|
|
194
223
|
invalid_domain_name: { retryable: false, recovery: "fix_input" },
|
|
224
|
+
invalid_elevation_request: { retryable: false, recovery: "fix_input" },
|
|
195
225
|
invalid_file_path: { retryable: false, recovery: "fix_input" },
|
|
196
226
|
invalid_grant: { retryable: false, recovery: "re_auth" },
|
|
197
227
|
invalid_idempotency_key: { retryable: false, recovery: "fix_input" },
|
|
@@ -203,6 +233,9 @@ export const ERROR_CODE_META = {
|
|
|
203
233
|
invalid_space: { retryable: false, recovery: "fix_input" },
|
|
204
234
|
invalid_space_mode: { retryable: false, recovery: "fix_input" },
|
|
205
235
|
invalid_user_code: { retryable: false, recovery: "re_auth" },
|
|
236
|
+
invalid_usage_bucket: { retryable: false, recovery: "fix_input" },
|
|
237
|
+
invalid_usage_correction: { retryable: false, recovery: "fix_input" },
|
|
238
|
+
invalid_usage_window: { retryable: false, recovery: "fix_input" },
|
|
206
239
|
invalid_version_path: { retryable: false, recovery: "fix_input" },
|
|
207
240
|
invalid_webhook_events: { retryable: false, recovery: "fix_input" },
|
|
208
241
|
invalid_webhook_payload: { retryable: false, recovery: "fix_input" },
|
|
@@ -215,6 +248,11 @@ export const ERROR_CODE_META = {
|
|
|
215
248
|
invitation_expired: { retryable: false, recovery: "fix_input" },
|
|
216
249
|
invitation_not_pending: { retryable: false, recovery: "fix_input" },
|
|
217
250
|
ip_blocked: { retryable: false, recovery: "contact_support" },
|
|
251
|
+
issuer_exists: { retryable: false, recovery: "fix_input" },
|
|
252
|
+
issuer_not_active: { retryable: false, recovery: "re_auth" },
|
|
253
|
+
issuer_proof_invalid: { retryable: false, recovery: "fix_input" },
|
|
254
|
+
issuer_tenant_occupied: { retryable: false, recovery: "fix_input" },
|
|
255
|
+
issuer_unknown: { retryable: false, recovery: "re_auth" },
|
|
218
256
|
job_not_found: { retryable: false, recovery: "fix_input" },
|
|
219
257
|
job_not_promotable: { retryable: false, recovery: "fix_input" },
|
|
220
258
|
job_not_removable: { retryable: true, recovery: "wait" },
|
|
@@ -239,15 +277,21 @@ export const ERROR_CODE_META = {
|
|
|
239
277
|
name_managed_by_config: { retryable: false, recovery: "fix_input" },
|
|
240
278
|
nameserver_delegation_required: { retryable: false, recovery: "fix_input" },
|
|
241
279
|
nameserver_divergence: { retryable: false, recovery: "fix_input" },
|
|
280
|
+
next_version_unsupported: { retryable: false, recovery: "fix_input" },
|
|
281
|
+
no_space_selected: { retryable: false, recovery: "fix_input" },
|
|
242
282
|
noop_publish: { retryable: false, recovery: "fix_input" },
|
|
243
283
|
not_enrolled: { retryable: false, recovery: "fix_input" },
|
|
244
284
|
not_found: { retryable: false, recovery: "fix_input" },
|
|
285
|
+
partner_preset_not_grantable: { retryable: false, recovery: "fix_input" },
|
|
286
|
+
partner_tenant_immutable_client: { retryable: false, recovery: "fix_input" },
|
|
287
|
+
password_already_set: { retryable: false, recovery: "fix_input" },
|
|
288
|
+
password_compromised: { retryable: false, recovery: "fix_input" },
|
|
245
289
|
path_case_collision: { retryable: false, recovery: "fix_input" },
|
|
246
290
|
path_too_long: { retryable: false, recovery: "fix_input" },
|
|
247
291
|
plan_grant_already_active: { retryable: false, recovery: "fix_input" },
|
|
248
292
|
plan_grant_already_revoked: { retryable: false, recovery: "fix_input" },
|
|
293
|
+
plan_unknown: { retryable: false, recovery: "fix_input" },
|
|
249
294
|
placement_invalid_burstable: { retryable: false, recovery: "fix_input" },
|
|
250
|
-
platform_tenant_immutable_client: { retryable: false, recovery: "fix_input" },
|
|
251
295
|
policy_exceeds_grantor: { retryable: false, recovery: "fix_input" },
|
|
252
296
|
prebuilt_metadata_invalid: {
|
|
253
297
|
retryable: false,
|
|
@@ -257,7 +301,13 @@ export const ERROR_CODE_META = {
|
|
|
257
301
|
"Delete the archive's .meta.json sidecar if the archive contains plain files",
|
|
258
302
|
],
|
|
259
303
|
},
|
|
304
|
+
primary_email_not_removable: { retryable: false, recovery: "fix_input" },
|
|
305
|
+
principal_closed: { retryable: false, recovery: "contact_support" },
|
|
306
|
+
principal_has_active_spaces: { retryable: false, recovery: "fix_input" },
|
|
307
|
+
principal_not_found: { retryable: false, recovery: "fix_input" },
|
|
260
308
|
principal_space_mismatch: { retryable: false, recovery: "fix_input" },
|
|
309
|
+
principal_suspended: { retryable: false, recovery: "contact_support" },
|
|
310
|
+
principal_suspension_locked: { retryable: false, recovery: "contact_support" },
|
|
261
311
|
provider_error: { retryable: true, recovery: "retry" },
|
|
262
312
|
provider_job_failed: { retryable: true, recovery: "retry" },
|
|
263
313
|
provider_job_timeout: { retryable: true, recovery: "retry" },
|
|
@@ -265,6 +315,13 @@ export const ERROR_CODE_META = {
|
|
|
265
315
|
provider_runtime_feature_unsupported: { retryable: false, recovery: "fix_input" },
|
|
266
316
|
provider_site_id_required: { retryable: false, recovery: "fix_input" },
|
|
267
317
|
promote_admission_exceeded: { retryable: true, recovery: "wait" },
|
|
318
|
+
promotion_live_content_missing: { retryable: false, recovery: "fix_input" },
|
|
319
|
+
promotion_live_system_space_invalid: { retryable: false, recovery: "fix_input" },
|
|
320
|
+
promotion_live_system_space_not_designated: { retryable: false, recovery: "fix_input" },
|
|
321
|
+
promotion_not_live_tenant: { retryable: false, recovery: "fix_input" },
|
|
322
|
+
promotion_nothing_to_promote: { retryable: false, recovery: "fix_input" },
|
|
323
|
+
promotion_runtime_publish_incomplete: { retryable: true, recovery: "retry" },
|
|
324
|
+
promotion_test_twin_missing: { retryable: false, recovery: "fix_input" },
|
|
268
325
|
proxy_upstream_denied: { retryable: false, recovery: "fix_input" },
|
|
269
326
|
proxy_upstream_unresolved: { retryable: false, recovery: "fix_input" },
|
|
270
327
|
publish_archive_compression_ratio_exceeded: { retryable: false, recovery: "fix_input" },
|
|
@@ -287,6 +344,7 @@ export const ERROR_CODE_META = {
|
|
|
287
344
|
publish_upload_failed: { retryable: true, recovery: "retry" },
|
|
288
345
|
publish_verification_failed: { retryable: true, recovery: "retry" },
|
|
289
346
|
queue_not_found: { retryable: false, recovery: "fix_input" },
|
|
347
|
+
quota_exceeded: { retryable: false, recovery: "fix_input" },
|
|
290
348
|
rate_limited: {
|
|
291
349
|
retryable: true,
|
|
292
350
|
recovery: "wait",
|
|
@@ -329,6 +387,7 @@ export const ERROR_CODE_META = {
|
|
|
329
387
|
next: ["Retry after the Retry-After seconds"],
|
|
330
388
|
},
|
|
331
389
|
service_signature_invalid: { retryable: false, recovery: "re_auth" },
|
|
390
|
+
session_not_fresh: { retryable: false, recovery: "re_auth" },
|
|
332
391
|
site_already_deleted: { retryable: false, recovery: "fix_input" },
|
|
333
392
|
site_has_live_spaces: { retryable: false, recovery: "fix_input" },
|
|
334
393
|
site_not_static: { retryable: false, recovery: "fix_input" },
|
|
@@ -373,6 +432,7 @@ export const ERROR_CODE_META = {
|
|
|
373
432
|
space_person_self_invite: { retryable: false, recovery: "fix_input" },
|
|
374
433
|
space_ref_ambiguous: { retryable: false, recovery: "fix_input" },
|
|
375
434
|
space_ref_required: { retryable: false, recovery: "fix_input" },
|
|
435
|
+
space_selection_conflict: { retryable: false, recovery: "fix_input" },
|
|
376
436
|
space_transferring: { retryable: false, recovery: "fix_input" },
|
|
377
437
|
space_unclaimed: { retryable: false, recovery: "fix_input" },
|
|
378
438
|
ssl_renewal_blocked: { retryable: false, recovery: "fix_input" },
|
|
@@ -392,11 +452,16 @@ export const ERROR_CODE_META = {
|
|
|
392
452
|
storage_quota_exceeded: { retryable: false, recovery: "fix_input" },
|
|
393
453
|
storage_unavailable: { retryable: true, recovery: "retry" },
|
|
394
454
|
stripe_error: { retryable: true, recovery: "retry" },
|
|
455
|
+
superadmin_two_factor_required: { retryable: false, recovery: "fix_input" },
|
|
456
|
+
superadmin_wpcom_account_required: { retryable: false, recovery: "fix_input" },
|
|
395
457
|
superseded_by_publish: { retryable: false, recovery: "fix_input" },
|
|
458
|
+
system_space_conflict: { retryable: false, recovery: "fix_input" },
|
|
459
|
+
system_space_invalid: { retryable: false, recovery: "fix_input" },
|
|
396
460
|
takeover_notice_window: { retryable: true, recovery: "wait" },
|
|
397
461
|
team_member_quota_exceeded: { retryable: false, recovery: "fix_input" },
|
|
398
462
|
team_ref_required: { retryable: false, recovery: "fix_input" },
|
|
399
463
|
team_required: { retryable: false, recovery: "fix_input" },
|
|
464
|
+
team_scope_mismatch: { retryable: false, recovery: "fix_input" },
|
|
400
465
|
team_slug_conflict: { retryable: false, recovery: "fix_input" },
|
|
401
466
|
template_file_too_large: { retryable: false, recovery: "fix_input" },
|
|
402
467
|
template_not_in_version: { retryable: false, recovery: "fix_input" },
|
|
@@ -408,6 +473,15 @@ export const ERROR_CODE_META = {
|
|
|
408
473
|
tenant_selection_required: { retryable: false, recovery: "fix_input" },
|
|
409
474
|
tenant_suspended: { retryable: false, recovery: "contact_support" },
|
|
410
475
|
theme_value_invalid: { retryable: false, recovery: "fix_input" },
|
|
476
|
+
token_alg_invalid: { retryable: false, recovery: "re_auth" },
|
|
477
|
+
token_audience_mismatch: { retryable: false, recovery: "re_auth" },
|
|
478
|
+
token_claims_invalid: { retryable: false, recovery: "re_auth" },
|
|
479
|
+
token_header_forbidden: { retryable: false, recovery: "re_auth" },
|
|
480
|
+
token_malformed: { retryable: false, recovery: "re_auth" },
|
|
481
|
+
token_signature_invalid: { retryable: false, recovery: "re_auth" },
|
|
482
|
+
token_subject_invalid: { retryable: false, recovery: "re_auth" },
|
|
483
|
+
token_ttl_invalid: { retryable: false, recovery: "re_auth" },
|
|
484
|
+
token_type_invalid: { retryable: false, recovery: "re_auth" },
|
|
411
485
|
transfer_cross_tenant_unsupported: { retryable: false, recovery: "fix_input" },
|
|
412
486
|
transfer_not_cancelable: { retryable: false, recovery: "fix_input" },
|
|
413
487
|
transfer_push_failed: { retryable: true, recovery: "retry" },
|
|
@@ -420,6 +494,7 @@ export const ERROR_CODE_META = {
|
|
|
420
494
|
upload_path_not_canonical: { retryable: false, recovery: "fix_input" },
|
|
421
495
|
upload_path_not_declared: { retryable: false, recovery: "fix_input" },
|
|
422
496
|
upload_size_mismatch: { retryable: false, recovery: "fix_input" },
|
|
497
|
+
usage_period_not_found: { retryable: false, recovery: "fix_input" },
|
|
423
498
|
user_banned: { retryable: false, recovery: "contact_support" },
|
|
424
499
|
validation_error: { retryable: false, recovery: "fix_input" },
|
|
425
500
|
verification_required: { retryable: false, recovery: "re_auth" },
|
|
@@ -445,6 +520,7 @@ export const ERROR_CODE_META = {
|
|
|
445
520
|
version_quota_exceeded: { retryable: false, recovery: "fix_input" },
|
|
446
521
|
version_total_bytes_exceeded: { retryable: false, recovery: "fix_input" },
|
|
447
522
|
webhook_delivery_budget_exceeded: { retryable: false, recovery: "fix_input" },
|
|
523
|
+
webhook_managed_by_manifest: { retryable: false, recovery: "fix_input" },
|
|
448
524
|
whois_unavailable: { retryable: true, recovery: "retry" },
|
|
449
525
|
wp_cloud_assignment_kind_mismatch: { retryable: false, recovery: "fix_input" },
|
|
450
526
|
wp_cloud_assignment_space_mismatch: { retryable: false, recovery: "fix_input" },
|
|
@@ -513,7 +589,9 @@ export const ERROR_CODE_META = {
|
|
|
513
589
|
zero_endpoint_not_found: { retryable: false, recovery: "fix_input" },
|
|
514
590
|
zero_endpoints_invalid: { retryable: false, recovery: "fix_input" },
|
|
515
591
|
zero_endpoints_too_many: { retryable: false, recovery: "fix_input" },
|
|
592
|
+
zero_email_unavailable: { retryable: false, recovery: "fix_input" },
|
|
516
593
|
zero_envelope_encode_failed: { retryable: true, recovery: "retry" },
|
|
594
|
+
zero_gravatar_unavailable: { retryable: false, recovery: "fix_input" },
|
|
517
595
|
zero_js_context_init_failed: { retryable: true, recovery: "retry" },
|
|
518
596
|
zero_js_execution_failed: { retryable: false, recovery: "fix_input" },
|
|
519
597
|
zero_js_execution_timeout: { retryable: false, recovery: "fix_input" },
|
|
@@ -555,12 +633,10 @@ export const ERROR_CODE_META = {
|
|
|
555
633
|
zero_runner_unavailable: { retryable: false, recovery: "fix_input" },
|
|
556
634
|
zero_runs_invalid: { retryable: false, recovery: "fix_input" },
|
|
557
635
|
zero_runs_require_runtime_compiler: { retryable: false, recovery: "fix_input" },
|
|
636
|
+
zero_spam_unavailable: { retryable: false, recovery: "fix_input" },
|
|
558
637
|
zero_runs_too_many: { retryable: false, recovery: "fix_input" },
|
|
559
638
|
};
|
|
560
|
-
/**
|
|
561
|
-
* Resolve the metadata for an error code, degrading to a safe `contact_support` default for
|
|
562
|
-
* codes outside the table (dynamic provider passthrough, codes from a newer control plane).
|
|
563
|
-
*/
|
|
639
|
+
/** Metadata for an error code, or `DEFAULT_ERROR_CODE_META` when it is outside the table. */
|
|
564
640
|
export function errorCodeMeta(code) {
|
|
565
641
|
return ERROR_CODE_META[code] ?? DEFAULT_ERROR_CODE_META;
|
|
566
642
|
}
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
export declare const ERROR_DOCS_BASE_URL: string;
|
|
2
2
|
/** Media type of every 4xx/5xx response body (RFC 9457 problem details). */
|
|
3
3
|
export declare const PROBLEM_CONTENT_TYPE = "application/problem+json";
|
|
4
|
-
/** Problem `type` URI
|
|
4
|
+
/** Problem `type` URI: docs origin + `/{code}`. Asserted by the conformance suite. */
|
|
5
5
|
export declare function errorDocsUrl(code: string): string;
|
|
6
|
-
/** Problem `title
|
|
6
|
+
/** Problem `title`: the snake_case code as a sentence ("version_not_found" -> "Version not found"). */
|
|
7
7
|
export declare function errorTitle(code: string): string;
|
|
8
|
-
export declare const ERROR_CODES: readonly ["abuse_report_invalid_transition", "abuse_report_rate_limited", "abuse_takedown", "access_denied", "account_suspended", "agent_handoff_declined", "agent_handoff_limit_reached", "agent_handoff_origin_unsupported", "ambiguous_space_slug", "anonymous_expired", "anonymous_publish_rate_limited", "anonymous_space_limit_reached", "api_key_scope_underivable", "archive_too_large", "auth_code_required", "authorization_pending", "blob_gate_record_missing", "blob_gate_token_invalid", "build_command_missing", "build_execution_unavailable", "build_failed", "build_install_failed", "build_no_index_html", "build_not_created", "build_oom", "build_output_contains_server_bundle", "build_output_dir_missing", "build_timeout", "cache_purge_domain_required", "cache_purge_path_required", "channel_name_reserved", "channel_pointer_moved", "channel_unsupported", "claim_blocked_takedown", "claim_target_not_found", "claimed_space_quota_exceeded", "cli_upgrade_required", "config_file_too_large", "config_functions_key_removed", "config_invalid", "config_meta_too_long", "config_name_too_long", "config_runtime_entry_missing", "config_runtime_invalid_kind", "config_templates_over_limit", "continuation_unavailable", "continuation_used", "credential_expired", "credential_not_yet_valid", "credential_retired", "credential_revoked", "csam_blocked", "csam_policy_floor", "data_location_immutable", "db_not_available", "device_authorization_failed", "device_verification_rate_limited", "dns_export_required", "dns_field_conflict", "dns_field_not_applicable", "dns_import_partial_visibility", "dns_provider_auth_expired", "dns_provider_batch_unsupported", "dns_provider_change_pending", "dns_provider_conflict", "dns_provider_connection_in_use", "dns_provider_connection_unavailable", "dns_provider_controlled_desired_state", "dns_provider_credentials_expired", "dns_provider_feature_descriptors", "dns_provider_feature_unavailable", "dns_provider_field_unsupported", "dns_provider_future_authoritative_backend", "dns_provider_missing_permission", "dns_provider_not_connected", "dns_provider_operation_failed", "dns_provider_permission_denied", "dns_provider_rate_limited", "dns_provider_replace_all_requires_fresh_plan", "dns_provider_replace_all_write_strategy", "dns_provider_snapshot_stale", "dns_provider_snapshot_unavailable", "dns_provider_temporarily_unavailable", "dns_provider_timeout", "dns_provider_validation_failed", "dns_provider_workflow_templates", "dns_provider_zone_not_found", "dns_record_conflicts_with_managed", "dns_record_managed", "dns_record_not_found", "domain_already_exists", "domain_bound", "domain_facet_already_managed", "domain_facet_external", "domain_facet_not_applicable", "domain_hostname_site_mismatch", "domain_in_use", "domain_lookup_rate_limited", "domain_not_bound", "domain_quota_exceeded", "domain_registration_active", "domain_registration_not_renewable", "domain_reserved_suffix", "domain_transfer_active", "domain_wildcard_label", "domain_wildcard_not_enabled", "download_required", "duplicate_version_path", "enforcement_policy_overlap", "event_payload_too_large", "event_rate_limited", "expired_token", "feature_unavailable", "files_mode_does_not_support_spa", "forbidden", "free_external_proxy_disabled", "idempotency_conflict_in_progress", "idempotency_key_reused", "incumbent_controls_dns", "ingest_admission_exceeded", "inject_invalid", "inject_snippet_too_large", "internal_error", "invalid_claim_token", "invalid_continuation_token", "invalid_data_location", "invalid_device_code", "invalid_domain", "invalid_domain_name", "invalid_file_path", "invalid_grant", "invalid_idempotency_key", "invalid_publish_archive", "invalid_publish_path", "invalid_publish_payload", "invalid_request", "invalid_runtime_event", "invalid_space", "invalid_space_mode", "invalid_user_code", "invalid_version_path", "invalid_webhook_events", "invalid_webhook_payload", "invalid_webhook_signature", "invalid_webhook_url", "invalid_zero_realtime_event", "invalid_zero_realtime_replay_query", "invitation_already_exists", "invitation_email_mismatch", "invitation_expired", "invitation_not_pending", "ip_blocked", "job_not_found", "job_not_promotable", "job_not_removable", "job_not_retryable", "last_owner", "log_retention_clamped", "lost_domain_control", "maintenance_in_progress", "malware_detected", "managed_domain_protected", "manifest_body_too_large", "manifest_duplicate_path", "manifest_too_many_files", "member_already_exists", "method_not_allowed", "missing_route_param", "move_target_capacity_lost", "name_managed_by_config", "nameserver_delegation_required", "nameserver_divergence", "noop_publish", "not_enrolled", "not_found", "path_case_collision", "path_too_long", "placement_invalid_burstable", "plan_grant_already_active", "plan_grant_already_revoked", "platform_tenant_immutable_client", "policy_exceeds_grantor", "prebuilt_metadata_invalid", "principal_space_mismatch", "promote_admission_exceeded", "provider_error", "provider_job_failed", "provider_job_timeout", "provider_privilege", "provider_runtime_feature_unsupported", "provider_site_id_required", "proxy_upstream_denied", "proxy_upstream_unresolved", "publish_archive_compression_ratio_exceeded", "publish_archive_expanded_size_exceeded", "publish_archive_file_count_exceeded", "publish_archive_too_large", "publish_base_changed", "publish_bytes_missing", "publish_config_unsupported", "publish_failed", "publish_file_missing", "publish_hash_mismatch", "publish_inline_limit_exceeded", "publish_not_cancelable", "publish_path_collision", "publish_path_invalid", "publish_session_expired", "publish_setup_failed", "publish_snapshot_empty", "publish_upload_failed", "publish_verification_failed", "queue_not_found", "rate_limited", "registration_expired", "registration_expiring", "resource_revision_changed", "response_headers_unservable", "response_table_too_large", "review_item_claimed", "routing_rules_over_plan", "runtime_action_forbidden", "runtime_api_not_found", "runtime_callback_forbidden", "runtime_dev_unsupported", "runtime_hostname_unassigned", "runtime_instance_mismatch", "runtime_jti_missing", "runtime_jti_replayed", "runtime_jwks_key_missing", "runtime_kind_mismatch", "runtime_management_unavailable", "runtime_not_provisioned", "runtime_operation_missing", "runtime_purge_failed", "runtime_release_unverifiable", "runtime_scope_forbidden", "runtime_token_bad_signature", "runtime_token_expired", "runtime_token_invalid", "runtime_unauthorized", "runtime_upload_operation_not_supported", "runtime_upload_required", "scan_pending", "secret_variable_in_template", "service_booting", "service_signature_invalid", "site_already_deleted", "site_has_live_spaces", "site_not_static", "site_required", "site_suspended", "slow_down", "slug_invalid", "slug_reserved", "slug_unavailable", "source_archive_decompression_timeout", "source_archive_expansion_ratio_exceeded", "source_archive_validation_busy", "space_already_claimed", "space_claim_unavailable", "space_claimed_credential_available", "space_disabled", "space_expired", "space_has_active_publish", "space_has_active_version", "space_hostname_identity_missing", "space_no_live_version", "space_not_disabled", "space_not_restorable", "space_person_already_member", "space_person_invitation_pending", "space_person_self_invite", "space_ref_ambiguous", "space_ref_required", "space_transferring", "space_unclaimed", "ssl_renewal_blocked", "static_control_file_not_supported", "static_runtime_control_path_not_supported", "static_runtime_required", "storage_auth_required", "storage_bucket_unavailable", "storage_content_blocked", "storage_delete_forbidden", "storage_empty_file", "storage_file_too_large", "storage_key_invalid", "storage_object_not_found", "storage_quota_already_unlimited", "storage_quota_decrease_not_supported", "storage_quota_exceeded", "storage_unavailable", "stripe_error", "superseded_by_publish", "takeover_notice_window", "team_member_quota_exceeded", "team_ref_required", "team_required", "team_slug_conflict", "template_file_too_large", "template_not_in_version", "template_variable_unresolved", "tenant_id_mismatch", "tenant_not_found", "tenant_not_granted", "tenant_past_due", "tenant_selection_required", "tenant_suspended", "theme_value_invalid", "transfer_cross_tenant_unsupported", "transfer_not_cancelable", "transfer_push_failed", "transfer_source_changed", "transfer_target_same_as_source", "transfer_verify_failed", "unauthorized", "unsupported_publish_media_type", "upload_hash_mismatch", "upload_path_not_canonical", "upload_path_not_declared", "upload_size_mismatch", "user_banned", "validation_error", "verification_required", "version_already_live", "version_artifact_not_found", "version_busy", "version_canceled", "version_closed", "version_expired", "version_failed", "version_file_count_exceeded", "version_file_not_found", "version_file_too_large", "version_files_missing", "version_in_use", "version_live", "version_no_publishable_files", "version_not_finalizable", "version_not_found", "version_not_prepared", "version_not_promotable", "version_not_ready", "version_quota_exceeded", "version_total_bytes_exceeded", "webhook_delivery_budget_exceeded", "whois_unavailable", "wp_cloud_assignment_kind_mismatch", "wp_cloud_assignment_space_mismatch", "wp_cloud_assignment_team_mismatch", "wp_cloud_client_in_use", "wp_cloud_client_not_found", "wp_cloud_site_still_assigned", "wp_cloud_team_shared_site_exists", "wp_cloud_webhook_secret_not_configured", "zero_ai_unavailable", "zero_artifact_abi_mismatch", "zero_artifact_invalid", "zero_artifact_malformed", "zero_artifact_path_invalid", "zero_artifact_unreadable", "zero_auth_unavailable", "zero_blob_key_invalid", "zero_blob_store_full", "zero_blob_too_large", "zero_blob_value_invalid", "zero_bootstrap_encode_failed", "zero_bytecode_hash_mismatch", "zero_bytecode_invalid", "zero_bytecode_path_invalid", "zero_bytecode_unreadable", "zero_capabilities_encode_failed", "zero_client_bundle_not_loaded", "zero_db_connect_failed", "zero_db_execute_failed", "zero_db_export_cursor_invalid", "zero_db_export_failed", "zero_db_export_page_too_large", "zero_db_export_query_invalid", "zero_db_export_schema_changed", "zero_db_export_schema_unavailable", "zero_db_host_install_failed", "zero_db_operation_invalid", "zero_db_operation_too_large", "zero_db_param_invalid", "zero_db_query_failed", "zero_db_row_invalid", "zero_db_sql_invalid", "zero_db_target_denied", "zero_db_tls_required", "zero_db_too_many_params", "zero_db_transaction_active", "zero_db_transaction_commit_failed", "zero_db_transaction_invalid", "zero_db_transaction_missing", "zero_db_transaction_rollback_failed", "zero_db_transaction_start_failed", "zero_db_url_invalid", "zero_db_url_missing", "zero_dev_endpoint_failed", "zero_dump_query_invalid", "zero_endpoint_compile_failed", "zero_endpoint_conflict", "zero_endpoint_duplicate", "zero_endpoint_id_duplicate", "zero_endpoint_index_invalid", "zero_endpoint_index_malformed", "zero_endpoint_index_path_invalid", "zero_endpoint_index_unreadable", "zero_endpoint_invalid", "zero_endpoint_mismatch", "zero_endpoint_not_found", "zero_endpoints_invalid", "zero_endpoints_too_many", "zero_envelope_encode_failed", "zero_js_context_init_failed", "zero_js_execution_failed", "zero_js_execution_timeout", "zero_js_globals_failed", "zero_js_response_malformed", "zero_js_runtime_init_failed", "zero_log_query_invalid", "zero_method_not_allowed", "zero_migration_failed", "zero_query_name_missing", "zero_realtime_forbidden", "zero_realtime_message_invalid", "zero_realtime_operation_unsupported", "zero_realtime_query_invalid", "zero_realtime_space_required", "zero_realtime_unavailable", "zero_realtime_websocket_forbidden", "zero_replay_failed", "zero_replay_query_invalid", "zero_replay_unavailable", "zero_request_body_too_large", "zero_response_header_forbidden", "zero_response_header_invalid", "zero_response_too_large", "zero_routes_invalid", "zero_run_compile_failed", "zero_run_duplicate", "zero_run_invalid", "zero_run_operation_unsupported", "zero_runner_envelope_invalid", "zero_runner_failed", "zero_runner_invalid_body", "zero_runner_invalid_response", "zero_runner_invalid_status", "zero_runner_protocol_unsupported", "zero_runner_response_encode_failed", "zero_runner_stdin_invalid", "zero_runner_stdin_too_large", "zero_runner_unavailable", "zero_runs_invalid", "zero_runs_require_runtime_compiler", "zero_runs_too_many"];
|
|
8
|
+
export declare const ERROR_CODES: readonly ["abuse_report_invalid_transition", "abuse_report_rate_limited", "abuse_takedown", "access_denied", "account_suspended", "agent_handoff_declined", "agent_handoff_limit_reached", "agent_handoff_origin_unsupported", "ambiguous_space_slug", "anonymous_expired", "anonymous_publish_rate_limited", "anonymous_space_limit_reached", "api_key_scope_underivable", "archive_too_large", "auth_code_required", "authorization_level_not_allowed", "authorization_pending", "blob_gate_record_missing", "blob_gate_token_invalid", "build_command_missing", "build_execution_unavailable", "build_failed", "build_install_failed", "build_no_index_html", "build_not_created", "build_oom", "build_output_contains_server_bundle", "build_output_dir_missing", "build_timeout", "cache_purge_domain_required", "cache_purge_path_required", "channel_name_reserved", "channel_pointer_moved", "channel_unsupported", "claim_blocked_takedown", "claim_target_not_found", "claimed_space_quota_exceeded", "cli_upgrade_required", "config_file_too_large", "config_functions_key_removed", "config_invalid", "config_meta_too_long", "config_name_too_long", "config_runtime_entry_missing", "config_runtime_invalid_kind", "config_templates_over_limit", "confirmation_denied", "confirmation_expired", "confirmation_mismatch", "confirmation_required", "confirmation_token_required", "continuation_unavailable", "continuation_used", "credential_expired", "credential_not_yet_valid", "credential_retired", "credential_revoked", "credential_sponsor_inactive", "csam_blocked", "csam_policy_floor", "dashboard_prefs_key_invalid", "dashboard_prefs_too_large", "dashboard_prefs_too_many_keys", "data_location_immutable", "db_not_available", "decision_execution_lost", "decision_in_progress", "device_authorization_failed", "device_verification_rate_limited", "dns_export_required", "dns_field_conflict", "dns_field_not_applicable", "dns_import_partial_visibility", "dns_provider_auth_expired", "dns_provider_batch_unsupported", "dns_provider_change_pending", "dns_provider_conflict", "dns_provider_connection_in_use", "dns_provider_connection_unavailable", "dns_provider_controlled_desired_state", "dns_provider_credentials_expired", "dns_provider_feature_descriptors", "dns_provider_feature_unavailable", "dns_provider_field_unsupported", "dns_provider_future_authoritative_backend", "dns_provider_missing_permission", "dns_provider_not_connected", "dns_provider_operation_failed", "dns_provider_permission_denied", "dns_provider_rate_limited", "dns_provider_replace_all_requires_fresh_plan", "dns_provider_replace_all_write_strategy", "dns_provider_snapshot_stale", "dns_provider_snapshot_unavailable", "dns_provider_temporarily_unavailable", "dns_provider_timeout", "dns_provider_validation_failed", "dns_provider_workflow_templates", "dns_provider_zone_not_found", "dns_record_conflicts_with_managed", "dns_record_managed", "dns_record_not_found", "domain_already_exists", "domain_bound", "domain_facet_already_managed", "domain_facet_external", "domain_facet_not_applicable", "domain_hostname_site_mismatch", "domain_in_use", "domain_lookup_rate_limited", "domain_not_bound", "domain_quota_exceeded", "domain_registration_active", "domain_registration_not_renewable", "domain_reserved_suffix", "domain_transfer_active", "domain_wildcard_label", "domain_wildcard_not_enabled", "download_required", "duplicate_version_path", "elevation_not_required", "email_already_claimed", "email_verification_code_invalid", "enforcement_policy_overlap", "event_payload_too_large", "event_rate_limited", "expired_token", "feature_unavailable", "files_mode_does_not_support_spa", "forbidden", "free_external_proxy_disabled", "idempotency_conflict_in_progress", "idempotency_key_reused", "incumbent_controls_dns", "ingest_admission_exceeded", "inject_invalid", "inject_snippet_too_large", "insufficient_scope", "internal_error", "invalid_claim_token", "invalid_continuation_token", "invalid_data_location", "invalid_decision_state", "invalid_device_code", "invalid_domain", "invalid_domain_name", "invalid_elevation_request", "invalid_file_path", "invalid_grant", "invalid_idempotency_key", "invalid_publish_archive", "invalid_publish_path", "invalid_publish_payload", "invalid_request", "invalid_runtime_event", "invalid_space", "invalid_space_mode", "invalid_usage_bucket", "invalid_usage_correction", "invalid_usage_window", "invalid_user_code", "invalid_version_path", "invalid_webhook_events", "invalid_webhook_payload", "invalid_webhook_signature", "invalid_webhook_url", "invalid_zero_realtime_event", "invalid_zero_realtime_replay_query", "invitation_already_exists", "invitation_email_mismatch", "invitation_expired", "invitation_not_pending", "ip_blocked", "issuer_exists", "issuer_not_active", "issuer_proof_invalid", "issuer_tenant_occupied", "issuer_unknown", "job_not_found", "job_not_promotable", "job_not_removable", "job_not_retryable", "last_owner", "log_retention_clamped", "lost_domain_control", "maintenance_in_progress", "malware_detected", "managed_domain_protected", "manifest_body_too_large", "manifest_duplicate_path", "manifest_too_many_files", "member_already_exists", "method_not_allowed", "missing_route_param", "move_target_capacity_lost", "name_managed_by_config", "nameserver_delegation_required", "nameserver_divergence", "next_version_unsupported", "no_space_selected", "noop_publish", "not_enrolled", "not_found", "partner_preset_not_grantable", "partner_tenant_immutable_client", "password_already_set", "password_compromised", "path_case_collision", "path_too_long", "placement_invalid_burstable", "plan_grant_already_active", "plan_grant_already_revoked", "plan_unknown", "policy_exceeds_grantor", "prebuilt_metadata_invalid", "primary_email_not_removable", "principal_closed", "principal_has_active_spaces", "principal_not_found", "principal_space_mismatch", "principal_suspended", "principal_suspension_locked", "promote_admission_exceeded", "promotion_live_content_missing", "promotion_live_system_space_invalid", "promotion_live_system_space_not_designated", "promotion_not_live_tenant", "promotion_nothing_to_promote", "promotion_runtime_publish_incomplete", "promotion_test_twin_missing", "provider_error", "provider_job_failed", "provider_job_timeout", "provider_privilege", "provider_runtime_feature_unsupported", "provider_site_id_required", "proxy_upstream_denied", "proxy_upstream_unresolved", "publish_archive_compression_ratio_exceeded", "publish_archive_expanded_size_exceeded", "publish_archive_file_count_exceeded", "publish_archive_too_large", "publish_base_changed", "publish_bytes_missing", "publish_config_unsupported", "publish_failed", "publish_file_missing", "publish_hash_mismatch", "publish_inline_limit_exceeded", "publish_not_cancelable", "publish_path_collision", "publish_path_invalid", "publish_session_expired", "publish_setup_failed", "publish_snapshot_empty", "publish_upload_failed", "publish_verification_failed", "queue_not_found", "quota_exceeded", "rate_limited", "registration_expired", "registration_expiring", "resource_revision_changed", "response_headers_unservable", "response_table_too_large", "review_item_claimed", "routing_rules_over_plan", "runtime_action_forbidden", "runtime_api_not_found", "runtime_callback_forbidden", "runtime_dev_unsupported", "runtime_hostname_unassigned", "runtime_instance_mismatch", "runtime_jti_missing", "runtime_jti_replayed", "runtime_jwks_key_missing", "runtime_kind_mismatch", "runtime_management_unavailable", "runtime_not_provisioned", "runtime_operation_missing", "runtime_purge_failed", "runtime_release_unverifiable", "runtime_scope_forbidden", "runtime_token_bad_signature", "runtime_token_expired", "runtime_token_invalid", "runtime_unauthorized", "runtime_upload_operation_not_supported", "runtime_upload_required", "scan_pending", "secret_variable_in_template", "service_booting", "service_signature_invalid", "session_not_fresh", "site_already_deleted", "site_has_live_spaces", "site_not_static", "site_required", "site_suspended", "slow_down", "slug_invalid", "slug_reserved", "slug_unavailable", "source_archive_decompression_timeout", "source_archive_expansion_ratio_exceeded", "source_archive_validation_busy", "space_already_claimed", "space_claim_unavailable", "space_claimed_credential_available", "space_disabled", "space_expired", "space_has_active_publish", "space_has_active_version", "space_hostname_identity_missing", "space_no_live_version", "space_not_disabled", "space_not_restorable", "space_person_already_member", "space_person_invitation_pending", "space_person_self_invite", "space_ref_ambiguous", "space_ref_required", "space_selection_conflict", "space_transferring", "space_unclaimed", "ssl_renewal_blocked", "static_control_file_not_supported", "static_runtime_control_path_not_supported", "static_runtime_required", "storage_auth_required", "storage_bucket_unavailable", "storage_content_blocked", "storage_delete_forbidden", "storage_empty_file", "storage_file_too_large", "storage_key_invalid", "storage_object_not_found", "storage_quota_already_unlimited", "storage_quota_decrease_not_supported", "storage_quota_exceeded", "storage_unavailable", "stripe_error", "superadmin_two_factor_required", "superadmin_wpcom_account_required", "superseded_by_publish", "system_space_conflict", "system_space_invalid", "takeover_notice_window", "team_member_quota_exceeded", "team_ref_required", "team_required", "team_scope_mismatch", "team_slug_conflict", "template_file_too_large", "template_not_in_version", "template_variable_unresolved", "tenant_id_mismatch", "tenant_not_found", "tenant_not_granted", "tenant_past_due", "tenant_selection_required", "tenant_suspended", "theme_value_invalid", "token_alg_invalid", "token_audience_mismatch", "token_claims_invalid", "token_header_forbidden", "token_malformed", "token_signature_invalid", "token_subject_invalid", "token_ttl_invalid", "token_type_invalid", "transfer_cross_tenant_unsupported", "transfer_not_cancelable", "transfer_push_failed", "transfer_source_changed", "transfer_target_same_as_source", "transfer_verify_failed", "unauthorized", "unsupported_publish_media_type", "upload_hash_mismatch", "upload_path_not_canonical", "upload_path_not_declared", "upload_size_mismatch", "usage_period_not_found", "user_banned", "validation_error", "verification_required", "version_already_live", "version_artifact_not_found", "version_busy", "version_canceled", "version_closed", "version_expired", "version_failed", "version_file_count_exceeded", "version_file_not_found", "version_file_too_large", "version_files_missing", "version_in_use", "version_live", "version_no_publishable_files", "version_not_finalizable", "version_not_found", "version_not_prepared", "version_not_promotable", "version_not_ready", "version_quota_exceeded", "version_total_bytes_exceeded", "webhook_delivery_budget_exceeded", "webhook_managed_by_manifest", "whois_unavailable", "wp_cloud_assignment_kind_mismatch", "wp_cloud_assignment_space_mismatch", "wp_cloud_assignment_team_mismatch", "wp_cloud_client_in_use", "wp_cloud_client_not_found", "wp_cloud_site_still_assigned", "wp_cloud_team_shared_site_exists", "wp_cloud_webhook_secret_not_configured", "zero_ai_unavailable", "zero_artifact_abi_mismatch", "zero_artifact_invalid", "zero_artifact_malformed", "zero_artifact_path_invalid", "zero_artifact_unreadable", "zero_auth_unavailable", "zero_blob_key_invalid", "zero_blob_store_full", "zero_blob_too_large", "zero_blob_value_invalid", "zero_bootstrap_encode_failed", "zero_bytecode_hash_mismatch", "zero_bytecode_invalid", "zero_bytecode_path_invalid", "zero_bytecode_unreadable", "zero_capabilities_encode_failed", "zero_client_bundle_not_loaded", "zero_db_connect_failed", "zero_db_execute_failed", "zero_db_export_cursor_invalid", "zero_db_export_failed", "zero_db_export_page_too_large", "zero_db_export_query_invalid", "zero_db_export_schema_changed", "zero_db_export_schema_unavailable", "zero_db_host_install_failed", "zero_db_operation_invalid", "zero_db_operation_too_large", "zero_db_param_invalid", "zero_db_query_failed", "zero_db_row_invalid", "zero_db_sql_invalid", "zero_db_target_denied", "zero_db_tls_required", "zero_db_too_many_params", "zero_db_transaction_active", "zero_db_transaction_commit_failed", "zero_db_transaction_invalid", "zero_db_transaction_missing", "zero_db_transaction_rollback_failed", "zero_db_transaction_start_failed", "zero_db_url_invalid", "zero_db_url_missing", "zero_dev_endpoint_failed", "zero_dump_query_invalid", "zero_email_unavailable", "zero_endpoint_compile_failed", "zero_endpoint_conflict", "zero_endpoint_duplicate", "zero_endpoint_id_duplicate", "zero_endpoint_index_invalid", "zero_endpoint_index_malformed", "zero_endpoint_index_path_invalid", "zero_endpoint_index_unreadable", "zero_endpoint_invalid", "zero_endpoint_mismatch", "zero_endpoint_not_found", "zero_endpoints_invalid", "zero_endpoints_too_many", "zero_envelope_encode_failed", "zero_gravatar_unavailable", "zero_js_context_init_failed", "zero_js_execution_failed", "zero_js_execution_timeout", "zero_js_globals_failed", "zero_js_response_malformed", "zero_js_runtime_init_failed", "zero_log_query_invalid", "zero_method_not_allowed", "zero_migration_failed", "zero_query_name_missing", "zero_realtime_forbidden", "zero_realtime_message_invalid", "zero_realtime_operation_unsupported", "zero_realtime_query_invalid", "zero_realtime_space_required", "zero_realtime_unavailable", "zero_realtime_websocket_forbidden", "zero_replay_failed", "zero_replay_query_invalid", "zero_replay_unavailable", "zero_request_body_too_large", "zero_response_header_forbidden", "zero_response_header_invalid", "zero_response_too_large", "zero_routes_invalid", "zero_run_compile_failed", "zero_run_duplicate", "zero_run_invalid", "zero_run_operation_unsupported", "zero_runner_envelope_invalid", "zero_runner_failed", "zero_runner_invalid_body", "zero_runner_invalid_response", "zero_runner_invalid_status", "zero_runner_protocol_unsupported", "zero_runner_response_encode_failed", "zero_runner_stdin_invalid", "zero_runner_stdin_too_large", "zero_runner_unavailable", "zero_runs_invalid", "zero_runs_require_runtime_compiler", "zero_runs_too_many", "zero_spam_unavailable"];
|
|
9
9
|
export type ErrorCode = (typeof ERROR_CODES)[number];
|
|
10
10
|
export declare function isErrorCode(value: string): value is ErrorCode;
|
|
11
11
|
/**
|
|
12
12
|
* Narrow a dynamically-sourced code (diagnostic conversions, provider passthrough) into the
|
|
13
|
-
* table, degrading to `fallback` for codes outside it. Literal constructions
|
|
14
|
-
*
|
|
13
|
+
* table, degrading to `fallback` for codes outside it. Literal constructions are typed
|
|
14
|
+
* against `ErrorCode` directly and never use this.
|
|
15
15
|
*/
|
|
16
16
|
export declare function toErrorCode(value: string | null | undefined, fallback: ErrorCode): ErrorCode;
|
|
@@ -1,24 +1,20 @@
|
|
|
1
1
|
// The single error-code table (the platform spec "Global API Conventions").
|
|
2
|
-
// Every problem document `code` the control plane emits is a member of this
|
|
3
|
-
//
|
|
4
|
-
//
|
|
5
|
-
//
|
|
6
|
-
//
|
|
7
|
-
//
|
|
8
|
-
//
|
|
9
|
-
// passthrough) fold into the typed problem document in the F2 envelope chunk.
|
|
10
|
-
// A code's meaning stays stable while it can be emitted. Retiring an API surface removes
|
|
11
|
-
// its dead codes and generated references together. Diagnostic codes share this table so
|
|
12
|
-
// every current diagnostic also carries a resolvable docs link.
|
|
2
|
+
// Every problem document `code` the control plane emits is a member of this
|
|
3
|
+
// table, and error docs pages are generated from it. Control-plane error
|
|
4
|
+
// constructors are typed against `ErrorCode`, so emitting a code outside the
|
|
5
|
+
// table is a typecheck failure. A code's meaning stays stable while it can be
|
|
6
|
+
// emitted; retiring an API surface removes its dead codes and generated
|
|
7
|
+
// references together. Diagnostic codes share this table, so every diagnostic
|
|
8
|
+
// carries a resolvable docs link.
|
|
13
9
|
import { DOCS_BASE_URL } from "../config/domains.js";
|
|
14
10
|
export const ERROR_DOCS_BASE_URL = `${DOCS_BASE_URL}/errors`;
|
|
15
11
|
/** Media type of every 4xx/5xx response body (RFC 9457 problem details). */
|
|
16
12
|
export const PROBLEM_CONTENT_TYPE = "application/problem+json";
|
|
17
|
-
/** Problem `type` URI
|
|
13
|
+
/** Problem `type` URI: docs origin + `/{code}`. Asserted by the conformance suite. */
|
|
18
14
|
export function errorDocsUrl(code) {
|
|
19
15
|
return `${ERROR_DOCS_BASE_URL}/${code}`;
|
|
20
16
|
}
|
|
21
|
-
/** Problem `title
|
|
17
|
+
/** Problem `title`: the snake_case code as a sentence ("version_not_found" -> "Version not found"). */
|
|
22
18
|
export function errorTitle(code) {
|
|
23
19
|
const words = code.replaceAll("_", " ");
|
|
24
20
|
return words.charAt(0).toUpperCase() + words.slice(1);
|
|
@@ -39,6 +35,7 @@ export const ERROR_CODES = [
|
|
|
39
35
|
"api_key_scope_underivable",
|
|
40
36
|
"archive_too_large",
|
|
41
37
|
"auth_code_required",
|
|
38
|
+
"authorization_level_not_allowed",
|
|
42
39
|
"authorization_pending",
|
|
43
40
|
"blob_gate_record_missing",
|
|
44
41
|
"blob_gate_token_invalid",
|
|
@@ -69,16 +66,27 @@ export const ERROR_CODES = [
|
|
|
69
66
|
"config_runtime_entry_missing",
|
|
70
67
|
"config_runtime_invalid_kind",
|
|
71
68
|
"config_templates_over_limit",
|
|
69
|
+
"confirmation_denied",
|
|
70
|
+
"confirmation_expired",
|
|
71
|
+
"confirmation_mismatch",
|
|
72
|
+
"confirmation_required",
|
|
73
|
+
"confirmation_token_required",
|
|
72
74
|
"continuation_unavailable",
|
|
73
75
|
"continuation_used",
|
|
74
76
|
"credential_expired",
|
|
75
77
|
"credential_not_yet_valid",
|
|
76
78
|
"credential_retired",
|
|
77
79
|
"credential_revoked",
|
|
80
|
+
"credential_sponsor_inactive",
|
|
78
81
|
"csam_blocked",
|
|
79
82
|
"csam_policy_floor",
|
|
83
|
+
"dashboard_prefs_key_invalid",
|
|
84
|
+
"dashboard_prefs_too_large",
|
|
85
|
+
"dashboard_prefs_too_many_keys",
|
|
80
86
|
"data_location_immutable",
|
|
81
87
|
"db_not_available",
|
|
88
|
+
"decision_execution_lost",
|
|
89
|
+
"decision_in_progress",
|
|
82
90
|
"device_authorization_failed",
|
|
83
91
|
"device_verification_rate_limited",
|
|
84
92
|
"dns_export_required",
|
|
@@ -132,6 +140,9 @@ export const ERROR_CODES = [
|
|
|
132
140
|
"domain_wildcard_not_enabled",
|
|
133
141
|
"download_required",
|
|
134
142
|
"duplicate_version_path",
|
|
143
|
+
"elevation_not_required",
|
|
144
|
+
"email_already_claimed",
|
|
145
|
+
"email_verification_code_invalid",
|
|
135
146
|
"enforcement_policy_overlap",
|
|
136
147
|
"event_payload_too_large",
|
|
137
148
|
"event_rate_limited",
|
|
@@ -146,13 +157,16 @@ export const ERROR_CODES = [
|
|
|
146
157
|
"ingest_admission_exceeded",
|
|
147
158
|
"inject_invalid",
|
|
148
159
|
"inject_snippet_too_large",
|
|
160
|
+
"insufficient_scope",
|
|
149
161
|
"internal_error",
|
|
150
162
|
"invalid_claim_token",
|
|
151
163
|
"invalid_continuation_token",
|
|
152
164
|
"invalid_data_location",
|
|
165
|
+
"invalid_decision_state",
|
|
153
166
|
"invalid_device_code",
|
|
154
167
|
"invalid_domain",
|
|
155
168
|
"invalid_domain_name",
|
|
169
|
+
"invalid_elevation_request",
|
|
156
170
|
"invalid_file_path",
|
|
157
171
|
"invalid_grant",
|
|
158
172
|
"invalid_idempotency_key",
|
|
@@ -163,6 +177,9 @@ export const ERROR_CODES = [
|
|
|
163
177
|
"invalid_runtime_event",
|
|
164
178
|
"invalid_space",
|
|
165
179
|
"invalid_space_mode",
|
|
180
|
+
"invalid_usage_bucket",
|
|
181
|
+
"invalid_usage_correction",
|
|
182
|
+
"invalid_usage_window",
|
|
166
183
|
"invalid_user_code",
|
|
167
184
|
"invalid_version_path",
|
|
168
185
|
"invalid_webhook_events",
|
|
@@ -176,6 +193,11 @@ export const ERROR_CODES = [
|
|
|
176
193
|
"invitation_expired",
|
|
177
194
|
"invitation_not_pending",
|
|
178
195
|
"ip_blocked",
|
|
196
|
+
"issuer_exists",
|
|
197
|
+
"issuer_not_active",
|
|
198
|
+
"issuer_proof_invalid",
|
|
199
|
+
"issuer_tenant_occupied",
|
|
200
|
+
"issuer_unknown",
|
|
179
201
|
"job_not_found",
|
|
180
202
|
"job_not_promotable",
|
|
181
203
|
"job_not_removable",
|
|
@@ -196,19 +218,38 @@ export const ERROR_CODES = [
|
|
|
196
218
|
"name_managed_by_config",
|
|
197
219
|
"nameserver_delegation_required",
|
|
198
220
|
"nameserver_divergence",
|
|
221
|
+
"next_version_unsupported",
|
|
222
|
+
"no_space_selected",
|
|
199
223
|
"noop_publish",
|
|
200
224
|
"not_enrolled",
|
|
201
225
|
"not_found",
|
|
226
|
+
"partner_preset_not_grantable",
|
|
227
|
+
"partner_tenant_immutable_client",
|
|
228
|
+
"password_already_set",
|
|
229
|
+
"password_compromised",
|
|
202
230
|
"path_case_collision",
|
|
203
231
|
"path_too_long",
|
|
204
232
|
"placement_invalid_burstable",
|
|
205
233
|
"plan_grant_already_active",
|
|
206
234
|
"plan_grant_already_revoked",
|
|
207
|
-
"
|
|
235
|
+
"plan_unknown",
|
|
208
236
|
"policy_exceeds_grantor",
|
|
209
237
|
"prebuilt_metadata_invalid",
|
|
238
|
+
"primary_email_not_removable",
|
|
239
|
+
"principal_closed",
|
|
240
|
+
"principal_has_active_spaces",
|
|
241
|
+
"principal_not_found",
|
|
210
242
|
"principal_space_mismatch",
|
|
243
|
+
"principal_suspended",
|
|
244
|
+
"principal_suspension_locked",
|
|
211
245
|
"promote_admission_exceeded",
|
|
246
|
+
"promotion_live_content_missing",
|
|
247
|
+
"promotion_live_system_space_invalid",
|
|
248
|
+
"promotion_live_system_space_not_designated",
|
|
249
|
+
"promotion_not_live_tenant",
|
|
250
|
+
"promotion_nothing_to_promote",
|
|
251
|
+
"promotion_runtime_publish_incomplete",
|
|
252
|
+
"promotion_test_twin_missing",
|
|
212
253
|
"provider_error",
|
|
213
254
|
"provider_job_failed",
|
|
214
255
|
"provider_job_timeout",
|
|
@@ -237,6 +278,7 @@ export const ERROR_CODES = [
|
|
|
237
278
|
"publish_upload_failed",
|
|
238
279
|
"publish_verification_failed",
|
|
239
280
|
"queue_not_found",
|
|
281
|
+
"quota_exceeded",
|
|
240
282
|
"rate_limited",
|
|
241
283
|
"registration_expired",
|
|
242
284
|
"registration_expiring",
|
|
@@ -271,6 +313,7 @@ export const ERROR_CODES = [
|
|
|
271
313
|
"secret_variable_in_template",
|
|
272
314
|
"service_booting",
|
|
273
315
|
"service_signature_invalid",
|
|
316
|
+
"session_not_fresh",
|
|
274
317
|
"site_already_deleted",
|
|
275
318
|
"site_has_live_spaces",
|
|
276
319
|
"site_not_static",
|
|
@@ -299,6 +342,7 @@ export const ERROR_CODES = [
|
|
|
299
342
|
"space_person_self_invite",
|
|
300
343
|
"space_ref_ambiguous",
|
|
301
344
|
"space_ref_required",
|
|
345
|
+
"space_selection_conflict",
|
|
302
346
|
"space_transferring",
|
|
303
347
|
"space_unclaimed",
|
|
304
348
|
"ssl_renewal_blocked",
|
|
@@ -318,11 +362,16 @@ export const ERROR_CODES = [
|
|
|
318
362
|
"storage_quota_exceeded",
|
|
319
363
|
"storage_unavailable",
|
|
320
364
|
"stripe_error",
|
|
365
|
+
"superadmin_two_factor_required",
|
|
366
|
+
"superadmin_wpcom_account_required",
|
|
321
367
|
"superseded_by_publish",
|
|
368
|
+
"system_space_conflict",
|
|
369
|
+
"system_space_invalid",
|
|
322
370
|
"takeover_notice_window",
|
|
323
371
|
"team_member_quota_exceeded",
|
|
324
372
|
"team_ref_required",
|
|
325
373
|
"team_required",
|
|
374
|
+
"team_scope_mismatch",
|
|
326
375
|
"team_slug_conflict",
|
|
327
376
|
"template_file_too_large",
|
|
328
377
|
"template_not_in_version",
|
|
@@ -334,6 +383,15 @@ export const ERROR_CODES = [
|
|
|
334
383
|
"tenant_selection_required",
|
|
335
384
|
"tenant_suspended",
|
|
336
385
|
"theme_value_invalid",
|
|
386
|
+
"token_alg_invalid",
|
|
387
|
+
"token_audience_mismatch",
|
|
388
|
+
"token_claims_invalid",
|
|
389
|
+
"token_header_forbidden",
|
|
390
|
+
"token_malformed",
|
|
391
|
+
"token_signature_invalid",
|
|
392
|
+
"token_subject_invalid",
|
|
393
|
+
"token_ttl_invalid",
|
|
394
|
+
"token_type_invalid",
|
|
337
395
|
"transfer_cross_tenant_unsupported",
|
|
338
396
|
"transfer_not_cancelable",
|
|
339
397
|
"transfer_push_failed",
|
|
@@ -346,6 +404,7 @@ export const ERROR_CODES = [
|
|
|
346
404
|
"upload_path_not_canonical",
|
|
347
405
|
"upload_path_not_declared",
|
|
348
406
|
"upload_size_mismatch",
|
|
407
|
+
"usage_period_not_found",
|
|
349
408
|
"user_banned",
|
|
350
409
|
"validation_error",
|
|
351
410
|
"verification_required",
|
|
@@ -371,6 +430,7 @@ export const ERROR_CODES = [
|
|
|
371
430
|
"version_quota_exceeded",
|
|
372
431
|
"version_total_bytes_exceeded",
|
|
373
432
|
"webhook_delivery_budget_exceeded",
|
|
433
|
+
"webhook_managed_by_manifest",
|
|
374
434
|
"whois_unavailable",
|
|
375
435
|
"wp_cloud_assignment_kind_mismatch",
|
|
376
436
|
"wp_cloud_assignment_space_mismatch",
|
|
@@ -426,6 +486,7 @@ export const ERROR_CODES = [
|
|
|
426
486
|
"zero_db_url_missing",
|
|
427
487
|
"zero_dev_endpoint_failed",
|
|
428
488
|
"zero_dump_query_invalid",
|
|
489
|
+
"zero_email_unavailable",
|
|
429
490
|
"zero_endpoint_compile_failed",
|
|
430
491
|
"zero_endpoint_conflict",
|
|
431
492
|
"zero_endpoint_duplicate",
|
|
@@ -440,6 +501,7 @@ export const ERROR_CODES = [
|
|
|
440
501
|
"zero_endpoints_invalid",
|
|
441
502
|
"zero_endpoints_too_many",
|
|
442
503
|
"zero_envelope_encode_failed",
|
|
504
|
+
"zero_gravatar_unavailable",
|
|
443
505
|
"zero_js_context_init_failed",
|
|
444
506
|
"zero_js_execution_failed",
|
|
445
507
|
"zero_js_execution_timeout",
|
|
@@ -482,6 +544,7 @@ export const ERROR_CODES = [
|
|
|
482
544
|
"zero_runs_invalid",
|
|
483
545
|
"zero_runs_require_runtime_compiler",
|
|
484
546
|
"zero_runs_too_many",
|
|
547
|
+
"zero_spam_unavailable",
|
|
485
548
|
];
|
|
486
549
|
const ERROR_CODE_SET = new Set(ERROR_CODES);
|
|
487
550
|
export function isErrorCode(value) {
|
|
@@ -489,8 +552,8 @@ export function isErrorCode(value) {
|
|
|
489
552
|
}
|
|
490
553
|
/**
|
|
491
554
|
* Narrow a dynamically-sourced code (diagnostic conversions, provider passthrough) into the
|
|
492
|
-
* table, degrading to `fallback` for codes outside it. Literal constructions
|
|
493
|
-
*
|
|
555
|
+
* table, degrading to `fallback` for codes outside it. Literal constructions are typed
|
|
556
|
+
* against `ErrorCode` directly and never use this.
|
|
494
557
|
*/
|
|
495
558
|
export function toErrorCode(value, fallback) {
|
|
496
559
|
return value && isErrorCode(value) ? value : fallback;
|