@tunasand/sdk 0.0.0-stage → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +106 -0
- package/README.md +506 -2
- package/dist/analytics.d.ts +1 -0
- package/dist/analytics.js +43 -0
- package/dist/app.d.ts +1 -0
- package/dist/app.js +825 -0
- package/dist/apps-9u4XMi7E.js +114 -0
- package/dist/body.d.ts +1 -0
- package/dist/body.js +455 -0
- package/dist/bridge-DYAYGV7t.js +74 -0
- package/dist/bridge.d.ts +1 -0
- package/dist/bridge.js +189 -0
- package/dist/cli.d.ts +1 -0
- package/dist/cli.js +283 -0
- package/dist/client-Derrexwr.js +159 -0
- package/dist/customers-C_vJY2_v.js +84 -0
- package/dist/customers.d.ts +1 -0
- package/dist/customers.js +185 -0
- package/dist/declared-C_GvPiGF.js +397 -0
- package/dist/delivery.d.ts +1 -0
- package/dist/delivery.js +348 -0
- package/dist/dev.d.ts +1 -0
- package/dist/dev.js +93 -0
- package/dist/embed-R-OvDYAw.js +90 -0
- package/dist/errorLabels-BcyRbv_i.js +1510 -0
- package/dist/i18n.d.ts +1 -0
- package/dist/i18n.js +4 -0
- package/dist/integrations.d.ts +1 -0
- package/dist/integrations.js +62 -0
- package/dist/ja-C1HEWWTQ.js +241 -0
- package/dist/ja-C6lX0CeJ.js +213 -0
- package/dist/model-pmXzGX12.js +152 -0
- package/dist/model.d.ts +1 -0
- package/dist/model.js +345 -0
- package/dist/page-E_cYgZx-.js +138 -0
- package/dist/preview.d.ts +1 -0
- package/dist/preview.js +1 -0
- package/dist/profile-D6t1QMQh.js +223 -0
- package/dist/schema-BPHL7Qr-.js +115 -0
- package/dist/schema-UQJWRyfJ.js +995 -0
- package/dist/schema.d.ts +1 -0
- package/dist/schema.js +1 -0
- package/dist/src-sazhzYui.js +71 -0
- package/dist/types/access/src/handoff.d.ts +52 -0
- package/dist/types/access/src/index.d.ts +5 -0
- package/dist/types/access/src/jws.d.ts +5 -0
- package/dist/types/access/src/jwt.d.ts +35 -0
- package/dist/types/access/src/oidc.d.ts +50 -0
- package/dist/types/access/src/signed.d.ts +15 -0
- package/dist/types/analytics/src/day.d.ts +2 -0
- package/dist/types/analytics/src/index.d.ts +5 -0
- package/dist/types/analytics/src/schedule.d.ts +2 -0
- package/dist/types/analytics/src/shared.d.ts +21 -0
- package/dist/types/analytics/src/source.d.ts +19 -0
- package/dist/types/analytics/src/store.d.ts +24 -0
- package/dist/types/analytics/src/view.d.ts +33 -0
- package/dist/types/body/src/components.d.ts +25 -0
- package/dist/types/body/src/declared.d.ts +34 -0
- package/dist/types/body/src/derive.d.ts +13 -0
- package/dist/types/body/src/description.d.ts +8 -0
- package/dist/types/body/src/embed.d.ts +16 -0
- package/dist/types/body/src/href.d.ts +4 -0
- package/dist/types/body/src/html.d.ts +30 -0
- package/dist/types/body/src/index.d.ts +19 -0
- package/dist/types/body/src/inline.d.ts +20 -0
- package/dist/types/body/src/labels/en.d.ts +90 -0
- package/dist/types/body/src/labels/ja.d.ts +153 -0
- package/dist/types/body/src/library.d.ts +113 -0
- package/dist/types/body/src/markdown.d.ts +14 -0
- package/dist/types/body/src/normalize.d.ts +5 -0
- package/dist/types/body/src/problems.d.ts +103 -0
- package/dist/types/body/src/profile.d.ts +80 -0
- package/dist/types/body/src/render.d.ts +29 -0
- package/dist/types/body/src/schema.d.ts +6 -0
- package/dist/types/body/src/standard.d.ts +20 -0
- package/dist/types/body/src/types.d.ts +140 -0
- package/dist/types/cms-contract/src/apiKeys.d.ts +41 -0
- package/dist/types/cms-contract/src/app.d.ts +35 -0
- package/dist/types/cms-contract/src/appDependencies.d.ts +265 -0
- package/dist/types/cms-contract/src/appProblems.d.ts +22 -0
- package/dist/types/cms-contract/src/apps.d.ts +195 -0
- package/dist/types/cms-contract/src/assets.d.ts +12 -0
- package/dist/types/cms-contract/src/authorize.d.ts +146 -0
- package/dist/types/cms-contract/src/bridge.d.ts +318 -0
- package/dist/types/cms-contract/src/consents.d.ts +97 -0
- package/dist/types/cms-contract/src/customerLabels.d.ts +33 -0
- package/dist/types/cms-contract/src/customers.d.ts +266 -0
- package/dist/types/cms-contract/src/embeds.d.ts +165 -0
- package/dist/types/cms-contract/src/errorLabels.d.ts +269 -0
- package/dist/types/cms-contract/src/errorLabelsEn.d.ts +228 -0
- package/dist/types/cms-contract/src/errors.d.ts +105 -0
- package/dist/types/cms-contract/src/failureStatus.d.ts +124 -0
- package/dist/types/cms-contract/src/functionLabels.d.ts +5 -0
- package/dist/types/cms-contract/src/functions.d.ts +144 -0
- package/dist/types/cms-contract/src/identifiers.d.ts +117 -0
- package/dist/types/cms-contract/src/import.d.ts +277 -0
- package/dist/types/cms-contract/src/issueLabels.d.ts +435 -0
- package/dist/types/cms-contract/src/issueLabelsEn.d.ts +217 -0
- package/dist/types/cms-contract/src/migration.d.ts +103 -0
- package/dist/types/cms-contract/src/paths.d.ts +23 -0
- package/dist/types/cms-contract/src/permissionLabels.d.ts +8 -0
- package/dist/types/cms-contract/src/permissions.d.ts +77 -0
- package/dist/types/cms-contract/src/problems.d.ts +34 -0
- package/dist/types/cms-contract/src/roles.d.ts +57 -0
- package/dist/types/cms-contract/src/settingProblems.d.ts +13 -0
- package/dist/types/cms-contract/src/settings.d.ts +19 -0
- package/dist/types/cms-contract/src/siteArtifact.d.ts +45 -0
- package/dist/types/cms-contract/src/siteDeclaration.d.ts +70 -0
- package/dist/types/cms-contract/src/transfer.d.ts +57 -0
- package/dist/types/cms-contract/src/views.d.ts +21 -0
- package/dist/types/cms-contract/src/webhookLabels.d.ts +7 -0
- package/dist/types/cms-contract/src/webhooks.d.ts +139 -0
- package/dist/types/i18n/src/index.d.ts +50 -0
- package/dist/types/i18n/src/problems.d.ts +21 -0
- package/dist/types/model/src/asset.d.ts +111 -0
- package/dist/types/model/src/audience.d.ts +38 -0
- package/dist/types/model/src/brand.d.ts +25 -0
- package/dist/types/model/src/capabilities.d.ts +28 -0
- package/dist/types/model/src/changes.d.ts +34 -0
- package/dist/types/model/src/check.d.ts +15 -0
- package/dist/types/model/src/contact.d.ts +22 -0
- package/dist/types/model/src/image.d.ts +38 -0
- package/dist/types/model/src/index.d.ts +26 -0
- package/dist/types/model/src/input.d.ts +26 -0
- package/dist/types/model/src/integrity.d.ts +79 -0
- package/dist/types/model/src/json.d.ts +2 -0
- package/dist/types/model/src/labels/en.d.ts +169 -0
- package/dist/types/model/src/labels/ja.d.ts +198 -0
- package/dist/types/model/src/legacy.d.ts +2 -0
- package/dist/types/model/src/media.d.ts +5 -0
- package/dist/types/model/src/mediaUrl.d.ts +67 -0
- package/dist/types/model/src/model.d.ts +415 -0
- package/dist/types/model/src/page.d.ts +52 -0
- package/dist/types/model/src/problems.d.ts +184 -0
- package/dist/types/model/src/refs.d.ts +27 -0
- package/dist/types/model/src/rules.d.ts +15 -0
- package/dist/types/model/src/schema.d.ts +58 -0
- package/dist/types/model/src/screens.d.ts +76 -0
- package/dist/types/model/src/selfOps.d.ts +30 -0
- package/dist/types/model/src/time.d.ts +25 -0
- package/dist/types/model/src/typesSource.d.ts +8 -0
- package/dist/types/model/src/values.d.ts +24 -0
- package/dist/types/platform/src/defaultModel.d.ts +8 -0
- package/dist/types/sdk/src/analytics.d.ts +2 -0
- package/dist/types/sdk/src/app.d.ts +20 -0
- package/dist/types/sdk/src/body.d.ts +2 -0
- package/dist/types/sdk/src/bridge.d.ts +92 -0
- package/dist/types/sdk/src/cli.d.ts +2 -0
- package/dist/types/sdk/src/customers.d.ts +190 -0
- package/dist/types/sdk/src/delivery/cache.d.ts +18 -0
- package/dist/types/sdk/src/delivery/changes.d.ts +28 -0
- package/dist/types/sdk/src/delivery/client.d.ts +90 -0
- package/dist/types/sdk/src/delivery/fields.d.ts +48 -0
- package/dist/types/sdk/src/delivery/index.d.ts +9 -0
- package/dist/types/sdk/src/delivery/media.d.ts +14 -0
- package/dist/types/sdk/src/delivery/query.d.ts +85 -0
- package/dist/types/sdk/src/delivery/schema.d.ts +19 -0
- package/dist/types/sdk/src/delivery/values.d.ts +82 -0
- package/dist/types/sdk/src/delivery.d.ts +3 -0
- package/dist/types/sdk/src/dev.d.ts +29 -0
- package/dist/types/sdk/src/i18n.d.ts +12 -0
- package/dist/types/sdk/src/integrations.d.ts +33 -0
- package/dist/types/sdk/src/model.d.ts +5 -0
- package/dist/types/sdk/src/preview.d.ts +1 -0
- package/dist/types/sdk/src/schema.d.ts +21 -0
- package/dist/types/sdk/src/site.d.ts +43 -0
- package/dist/typesSource-bO0jFw1I.js +88 -0
- package/package.json +86 -3
|
@@ -0,0 +1,269 @@
|
|
|
1
|
+
import { type Catalog, type Locale } from '../../i18n/src/index.js';
|
|
2
|
+
import { type ErrorBody, type ErrorCode, type ErrorParams, type ErrorTarget } from './errors.js';
|
|
3
|
+
export declare const ERROR_MESSAGES: {
|
|
4
|
+
/** コアの対象の表示名(エラーの文と操作の履歴で共通、モジュールの対象は ModuleManifest の targets) */
|
|
5
|
+
readonly targets: {
|
|
6
|
+
readonly request: "作成の依頼";
|
|
7
|
+
readonly role: "ロール";
|
|
8
|
+
readonly media: "メディア";
|
|
9
|
+
readonly record: "マスタ";
|
|
10
|
+
readonly asset: "画像";
|
|
11
|
+
readonly mcp: "MCP";
|
|
12
|
+
readonly version: "バージョン";
|
|
13
|
+
readonly profile: "プロフィール";
|
|
14
|
+
readonly portrait: "顔の画像";
|
|
15
|
+
readonly extension: "アプリの機能";
|
|
16
|
+
readonly account: "アカウント";
|
|
17
|
+
readonly comment: "コメント";
|
|
18
|
+
readonly view: "ビュー";
|
|
19
|
+
readonly webhook: "Webhook";
|
|
20
|
+
readonly external_function: "カスタム検証";
|
|
21
|
+
readonly external_screen: "カスタム画面";
|
|
22
|
+
readonly api_key: "API キー";
|
|
23
|
+
readonly preview: "プレビューの署名シークレット";
|
|
24
|
+
readonly trash: "ゴミ箱";
|
|
25
|
+
readonly customer: "顧客";
|
|
26
|
+
readonly customer_identity: "顧客の結び付け";
|
|
27
|
+
readonly customer_grant: "顧客の権利";
|
|
28
|
+
readonly app: "アプリ";
|
|
29
|
+
readonly installation: "インストール";
|
|
30
|
+
readonly invitation: "招待";
|
|
31
|
+
readonly environment: "環境";
|
|
32
|
+
};
|
|
33
|
+
/** コードごとの文 */
|
|
34
|
+
readonly codes: {
|
|
35
|
+
readonly invalid_input: "入力に誤りがあります。内容を確かめて直してください。";
|
|
36
|
+
readonly submit_unmet: "レビューを依頼する条件を満たしていません。各フィールドの理由を確かめて直してください。";
|
|
37
|
+
readonly publish_unmet: "公開の条件を満たしていません。各フィールドの理由を確かめて直してください。";
|
|
38
|
+
readonly save_unmet: "保存の条件を満たしていません。各フィールドの理由を確かめて直してください。";
|
|
39
|
+
readonly version_required: "元にしたバージョン(version)が必要です。画面を読み込み直してから、もう一度保存してください。";
|
|
40
|
+
readonly file_required: "画像のファイルを選んでください。";
|
|
41
|
+
readonly file_too_large: "画像は{assetMaxMB, number}MBまでです。";
|
|
42
|
+
readonly unsupported_image: "対応していない画像の形式です(PNG・JPEG・GIF・WebP)。";
|
|
43
|
+
readonly unsupported_file: "対応していないファイルの形式です(PDF・ZIP・テキスト・CSV・Word・Excel・PowerPoint)。";
|
|
44
|
+
readonly invalid_dimensions: "画像の寸法を読み取れません。別の画像を選んでください。";
|
|
45
|
+
readonly https_required: "https の URL を指定してください。";
|
|
46
|
+
readonly invalid_style: "絵のタッチの ID が不正です(styles から選択)。";
|
|
47
|
+
readonly login_required: "ログインが必要です。ログインしてから、もう一度操作してください。";
|
|
48
|
+
readonly invalid_mcp_token: "MCP からの呼び出しを確認できません。AI のコネクタから接続し直してください。";
|
|
49
|
+
readonly mcp_signature_invalid: "MCP のサーバーからの呼び出しを確認できません。運営者に連絡してください。";
|
|
50
|
+
readonly invalid_account_token: "アプリのアカウントの資格のトークンが無効です。画面のトークンで替え直してください。";
|
|
51
|
+
readonly preview_token_required: "下書きの取得にはプレビューの署名が必要です。設定のプレビューとデプロイで、署名シークレットをサイトに設定してください。";
|
|
52
|
+
readonly invalid_preview_token: "プレビューの署名が一致しません。設定のプレビューとデプロイで、サイトの署名シークレットが今のものか確かめてください。";
|
|
53
|
+
readonly api_key_required: "API キーが必要です。リクエストの Authorization: Bearer に API キーを付けてください。";
|
|
54
|
+
readonly invalid_api_key: "API キーが無効です。設定の API キーで、失効していないキーを確かめてください。";
|
|
55
|
+
readonly invalid_id_token: "ID トークンが無効です。取り直してから送ってください。";
|
|
56
|
+
readonly invalid_app_token: "アプリの資格が無効です。アプリの JWT かインストールのトークンを取り直してから送ってください。";
|
|
57
|
+
readonly api_key_forbidden: "{target, select, none {API キーにこの取得の権限がありません。} other {API キーに「{target}」を取得する権限がありません。}}設定の API キーで、キーの権限を見直してください。";
|
|
58
|
+
readonly account_not_found: "{name, select, none {} other {{name}}} のアカウントがありません。管理者にアカウントの登録を依頼してください。";
|
|
59
|
+
readonly mcp_not_allowed: "MCP からは操作できません。スタジオから操作してください。";
|
|
60
|
+
readonly insufficient_scope: "AI の接続で許した範囲ではこの操作はできません。接続し直して{scope, select, content_publish {「公開まで」} other {必要な範囲}}を許してください。";
|
|
61
|
+
readonly admin_only: "管理者だけの操作です。必要なときは、管理者に依頼してください。";
|
|
62
|
+
readonly operator_read_only: "サポートのアクセスの許可が閲覧だけのため、変更できません。変更が要るときは、プロジェクトの管理者に許可の範囲の変更を依頼してください。";
|
|
63
|
+
readonly not_trial: "検証用のフラグのプロジェクトだけの操作です。";
|
|
64
|
+
readonly not_live: "本番の環境だけでできる操作です。本番の環境の管理画面から操作してください。";
|
|
65
|
+
readonly operator_closed: "サポートのアクセスでは変更できない操作です(アカウント、ロール、連携、アプリ、顧客の ID、許可など)。プロジェクトの管理者に依頼してください。";
|
|
66
|
+
readonly forbidden: "{target, select, none {この操作の権限がありません。} other {{target}のこの操作の権限がありません。}}必要なときは、管理者にロールの見直しを依頼してください。";
|
|
67
|
+
readonly editorial_only: "{target, select, none {対象} other {{target}}}は、公開の権限があるアカウントだけが作成できます。公開の権限があるメンバーに作成を依頼してください。";
|
|
68
|
+
readonly no_linked_record: "{name}が結び付いていないアカウントは操作できません。管理者に、ユーザーと権限でアカウントと{name}を結び付けるよう依頼してください。";
|
|
69
|
+
readonly own_only: "自分の{target, select, none {もの} other {{target}}}だけを操作できます。";
|
|
70
|
+
readonly not_visible: "ほかの人の公開前の{target, select, none {対象} other {{target}}}は閲覧できません。";
|
|
71
|
+
readonly published_admin_only: "公開中のレコードの編集には、公開の権限が必要です。公開の権限があるメンバーに編集を依頼してください。";
|
|
72
|
+
readonly cannot_remove_self: "自分を結び付きから外すことはできません。ほかの管理者に依頼してください。";
|
|
73
|
+
readonly cannot_change_owner: "本人を示すフィールドの値は変更できません。";
|
|
74
|
+
readonly not_found: "{target, select, none {対象} other {{target}}}が見つかりません。削除された可能性があります。画面を読み込み直してください。";
|
|
75
|
+
readonly method_not_allowed: "この経路はこのメソッドを受け付けません。";
|
|
76
|
+
readonly customer_not_linked: "このアカウントに結び付く顧客がいません。管理者に、顧客とアカウントの結び付けを依頼してください。";
|
|
77
|
+
readonly customer_pending: "このアカウントの結び付けは、運営の確認の後に使えます。確認が終わるまでお待ちください。";
|
|
78
|
+
readonly in_use: "{by, select, uses {{count, number}件で使用中のため、削除できません。} places {{count, number}か所で使用中のため、削除できません。} outputs {{count, number}件の企画の成果物で使用中のため、削除できません。} record {{name, select, none {ほかの内容} other {{name}}}で使用中のため、削除できません。} writers {{count, number}件のレコードに結び付いているため、削除できません。} customers {{count, number}件のレコードが所属しているため、削除できません。} accounts {{count, number}件のアカウントがこのロールのため、削除できません。} module {{count, number}件の{name, select, none {アプリのデータ} other {{name}}}から参照されているため、削除できません。} other {使用中のため、削除できません。}}使っている所から外してから、もう一度削除してください。";
|
|
79
|
+
readonly duplicate_name: "同じ名前がすでにあります。別の名前を付けてください。";
|
|
80
|
+
readonly duplicate_email: "同じメールアドレスのアカウントがすでにあります。一覧のそのアカウントを編集してください。";
|
|
81
|
+
readonly duplicate_id: "この ID はすでに使用されています。別の ID を指定してください。";
|
|
82
|
+
readonly duplicate_slug: "このスラッグはすでに使用されています。別のスラッグを指定してください。";
|
|
83
|
+
readonly version_conflict: "ほかの更新と重なりました。最新のバージョンを読み込んでやり直してください。";
|
|
84
|
+
readonly article_editing: "{name, select, none {ほかの人} other {{name}}}が CMS で編集中のため、保存できません。編集画面を閉じるか別のタブに切り替えると、2分以内に保存できるようになります。";
|
|
85
|
+
readonly invalid_state: "今の状態ではこの操作はできません。画面を読み込み直して、状態を確かめてください。";
|
|
86
|
+
readonly unpublish_first: "公開中のレコードは、非公開にしてから削除してください。";
|
|
87
|
+
readonly last_admin: "最後の管理者は、外すことも管理者のロールから降ろすこともできません。先にほかの人を管理者にしてください。";
|
|
88
|
+
readonly exceeds_own: "自分のロールより広い権限は付けられません。広い権限が要るときは、管理者に依頼してください。";
|
|
89
|
+
readonly reauth_required: "承認の前に、もう一度ログインしてください。";
|
|
90
|
+
readonly approval_required: "本番に届く変更のため、申請と承認が必要です。申請を出し、組織の管理者の承認を待ってください。";
|
|
91
|
+
readonly stale: "申請の後に内容が変わりました。もう一度申請してください。";
|
|
92
|
+
readonly approval_closed: "この申請はもう承認できません(反映済み、却下、取り下げ、期限切れのいずれか)。必要なときは、もう一度申請してください。";
|
|
93
|
+
readonly cursor_expired: "変更の記録の保存の期間を過ぎました。cursor なしで全件を取り直してください。";
|
|
94
|
+
readonly already_linked: "{reason, select, identity {このアカウントは、すでにほかの顧客に結び付いています。} other {この顧客は、すでに同じ発行者のアカウントに結び付いています。}}結び付けを替えるときは、先に今の結び付けを外してください。";
|
|
95
|
+
readonly run_done: "この取り込みの実行は完了済みです。新しい実行でやり直してください。";
|
|
96
|
+
readonly invalid_invite: "{reason, select, expired {招待の期限が過ぎています。} used {招待はすでに使われています。} other {招待が見つかりません。}}招待した人に、招待の送り直しを依頼してください。";
|
|
97
|
+
readonly body_too_large: "送信する内容は{bodyMaxMB, number}MBまでです。内容を分けて送ってください。";
|
|
98
|
+
readonly rate_limited: "呼び出しの回数が上限を超えました。しばらく待ってからお試しください。";
|
|
99
|
+
readonly upstream_failed: "{resource, select, image {画像を取得できませんでした。} webhook {Webhook へ送れませんでした。} file {ファイルを取得できませんでした。} source {移行元からコンテンツを取得できませんでした。接続の情報(サービスの ID と API キーなど)を確認してください。} hosting {サイトをホスティングするサイトの場所へ上げられませんでした。} other {ページを取得できませんでした。}}";
|
|
100
|
+
readonly not_configured: "{name, select, none {この操作に要る設定がありません。必要なときは、管理者が運営に相談してください。} other {{name}}}";
|
|
101
|
+
readonly unavailable: "一時的に処理できませんでした。しばらく待ってからお試しください。";
|
|
102
|
+
readonly writes_paused: "デプロイ中のため、保存を一時停止しています。数分後にもう一度お試しください。";
|
|
103
|
+
readonly environment_frozen: "この環境は保存を止めています(本番の切り替えの間か、本番から外れた環境です)。読み取りはできます。保存は本番の環境で行ってください。";
|
|
104
|
+
readonly job_failed: "処理が失敗しました。{name, select, none {} other {{name}}}時間をおいて、もう一度お試しください。";
|
|
105
|
+
readonly internal_error: "サーバーの処理に失敗しました。もう一度お試しください。";
|
|
106
|
+
readonly network_error: "通信に失敗しました。接続を確認して、もう一度お試しください。";
|
|
107
|
+
};
|
|
108
|
+
/** invalid_state の理由ごとの文 */
|
|
109
|
+
readonly states: {
|
|
110
|
+
readonly not_draft: "下書きではありません。画面を読み込み直してください。";
|
|
111
|
+
readonly no_draft: "公開中のバージョンと別の未公開の変更がありません。";
|
|
112
|
+
readonly not_in_review: "レビュー待ちではありません。画面を読み込み直してください。";
|
|
113
|
+
readonly request_handled: "この依頼はすでに対応済みです。";
|
|
114
|
+
readonly deleted: "すでに削除されています。";
|
|
115
|
+
readonly not_deleted: "削除されていないため、復元できません。";
|
|
116
|
+
readonly schema_confirm: "影響のある変更を含みます。件数を確認してから保存してください。";
|
|
117
|
+
readonly no_publishing: "このコレクションにはワークフローがありません。";
|
|
118
|
+
readonly no_review: "このコレクションのワークフローにはレビューがありません。";
|
|
119
|
+
readonly not_published: "公開中・予約中ではありません。";
|
|
120
|
+
readonly collection_rows: "レコードが残っています。件数を確認してから削除してください。";
|
|
121
|
+
readonly restore_conflict: "{name, select, none {同じ内容} other {{name}}}がすでにあるため、復元できません。先に今あるものを変更するか削除してください。";
|
|
122
|
+
readonly collection_exists: "同じ ID のコレクションがすでにあるため、復元できません。先にそのコレクションの ID を変更してください。";
|
|
123
|
+
readonly collection_missing: "コレクションが削除されているため、復元できません。先にコレクションを復元してください。";
|
|
124
|
+
readonly not_restorable: "本人の削除の求めか退会の保持の後の削除のため、復元できません。";
|
|
125
|
+
readonly installation_state: "今のインストールの状態ではこの操作はできません。画面を読み込み直して、状態を確かめてください。";
|
|
126
|
+
readonly site_deploy: "今はサイトを上げられません。ほかのアップロードの最中か、サイトが止められているか外されています。少し待ってから上げ直し、続くときは運営者に連絡してください。";
|
|
127
|
+
readonly site_stopped_by_check: "上げた直後の確認で外れたため、サイトを止めました。直したものを上げた後、運営者に戻してもらってください。";
|
|
128
|
+
readonly required_module: "必須の機能は無効にも削除にもできません。";
|
|
129
|
+
readonly app_installed: "アプリは1つのプロジェクトに1つだけインストールできます。";
|
|
130
|
+
readonly app_dependencies: "依存のアプリをそろえられません。アプリの詳細で、足りないアプリと合わないアプリを確かめてください。";
|
|
131
|
+
readonly app_reinstalled: "同じアプリを入れ直したインストールがあるため、古いインストールのデータは消せません。";
|
|
132
|
+
readonly app_managed: "アプリのインストールが管理する登録です。変更はアプリの新しいバージョンの同意で行います。";
|
|
133
|
+
readonly request_key_reused: "同じ重複を除くキーで、別の人かチャネルか目的の記録がすでにあります。別のキーで送ってください。";
|
|
134
|
+
readonly no_tenant: "組織に属していないプロジェクトのため、招待できません。運営者に組織への所属を頼んでください。";
|
|
135
|
+
readonly schema_changed: "スキーマが変更されたため、保存できませんでした。画面を読み込み直してください。";
|
|
136
|
+
readonly customer_inactive: "この顧客は停止中か退会済みのため、操作できません。顧客の画面で状態を確かめてください。";
|
|
137
|
+
readonly self_limit: "1人あたりのレコードの数の上限に達しています。不要なレコードを削除してから作成してください。";
|
|
138
|
+
readonly already_live: "この環境はすでに本番です。";
|
|
139
|
+
readonly target_live: "本番の環境は削除できません。先にほかの環境へ切り替えてください。";
|
|
140
|
+
readonly target_synthetic: "合成のデータの環境は本番にできません。本番にする環境を選び直してください。";
|
|
141
|
+
readonly no_changes: "本番との差がありません。";
|
|
142
|
+
readonly schema_values: "値のある項目を消す変更を含むため、反映できません。本番で値を移してからやり直してください。";
|
|
143
|
+
readonly environment_limit: "環境の数がプランの上限に達しています。不要な環境を削除してから作成してください。";
|
|
144
|
+
readonly environment_busy: "この環境はほかの操作の途中です。少し待ってからやり直してください。";
|
|
145
|
+
readonly unregistered_table: "個人の情報の扱いが決まっていない表があるため、コピーできません。運営者に連絡してください。";
|
|
146
|
+
readonly not_frozen: "本番の書き込みは止まっていません。";
|
|
147
|
+
readonly approval_running: "承認した操作の実行中です。少し待ってからやり直してください。";
|
|
148
|
+
};
|
|
149
|
+
/** own_only の対象ごとの文(モジュールの文は manifest の messages) */
|
|
150
|
+
readonly own: {
|
|
151
|
+
readonly profile: "自分のプロフィールだけを編集できます。";
|
|
152
|
+
readonly portrait: "自分の顔の画像だけを変更できます。";
|
|
153
|
+
};
|
|
154
|
+
/** no_linked_record の対象ごとの文(name は結び付くコレクションの表示名) */
|
|
155
|
+
readonly noLink: {
|
|
156
|
+
readonly mcp: "{name}が結び付いていないアカウントは、MCP を使用できません。管理者に、ユーザーと権限でアカウントと{name}を結び付けるよう依頼してください。";
|
|
157
|
+
};
|
|
158
|
+
/** no_linked_record の name が無いときの語 */
|
|
159
|
+
readonly linkedRecord: "レコード";
|
|
160
|
+
/** コードごとの見出し */
|
|
161
|
+
readonly titles: {
|
|
162
|
+
readonly invalid_input: "入力エラー";
|
|
163
|
+
readonly submit_unmet: "レビューを依頼できません";
|
|
164
|
+
readonly publish_unmet: "公開できません";
|
|
165
|
+
readonly save_unmet: "保存できません";
|
|
166
|
+
readonly version_required: "入力エラー";
|
|
167
|
+
readonly file_required: "入力エラー";
|
|
168
|
+
readonly file_too_large: "入力エラー";
|
|
169
|
+
readonly unsupported_image: "入力エラー";
|
|
170
|
+
readonly unsupported_file: "入力エラー";
|
|
171
|
+
readonly invalid_dimensions: "入力エラー";
|
|
172
|
+
readonly https_required: "入力エラー";
|
|
173
|
+
readonly invalid_style: "入力エラー";
|
|
174
|
+
readonly login_required: "ログインエラー";
|
|
175
|
+
readonly invalid_mcp_token: "ログインエラー";
|
|
176
|
+
readonly mcp_signature_invalid: "ログインエラー";
|
|
177
|
+
readonly invalid_account_token: "ログインエラー";
|
|
178
|
+
readonly preview_token_required: "ログインエラー";
|
|
179
|
+
readonly invalid_preview_token: "ログインエラー";
|
|
180
|
+
readonly api_key_required: "ログインエラー";
|
|
181
|
+
readonly invalid_api_key: "ログインエラー";
|
|
182
|
+
readonly invalid_id_token: "ログインエラー";
|
|
183
|
+
readonly invalid_app_token: "ログインエラー";
|
|
184
|
+
readonly api_key_forbidden: "権限がありません";
|
|
185
|
+
readonly account_not_found: "ログインエラー";
|
|
186
|
+
readonly mcp_not_allowed: "権限がありません";
|
|
187
|
+
readonly insufficient_scope: "権限がありません";
|
|
188
|
+
readonly admin_only: "権限がありません";
|
|
189
|
+
readonly operator_read_only: "権限がありません";
|
|
190
|
+
readonly operator_closed: "権限がありません";
|
|
191
|
+
readonly not_trial: "権限がありません";
|
|
192
|
+
readonly not_live: "本番の環境だけの操作です";
|
|
193
|
+
readonly forbidden: "権限がありません";
|
|
194
|
+
readonly editorial_only: "権限がありません";
|
|
195
|
+
readonly no_linked_record: "権限がありません";
|
|
196
|
+
readonly own_only: "権限がありません";
|
|
197
|
+
readonly not_visible: "権限がありません";
|
|
198
|
+
readonly published_admin_only: "権限がありません";
|
|
199
|
+
readonly cannot_remove_self: "権限がありません";
|
|
200
|
+
readonly cannot_change_owner: "権限がありません";
|
|
201
|
+
readonly not_found: "見つかりません";
|
|
202
|
+
readonly method_not_allowed: "操作できません";
|
|
203
|
+
readonly customer_not_linked: "見つかりません";
|
|
204
|
+
readonly customer_pending: "確認待ちです";
|
|
205
|
+
readonly in_use: "削除できません";
|
|
206
|
+
readonly duplicate_name: "重複しています";
|
|
207
|
+
readonly duplicate_email: "重複しています";
|
|
208
|
+
readonly duplicate_id: "重複しています";
|
|
209
|
+
readonly duplicate_slug: "重複しています";
|
|
210
|
+
readonly version_conflict: "更新が重なりました";
|
|
211
|
+
readonly article_editing: "編集中です";
|
|
212
|
+
readonly invalid_state: "操作できません";
|
|
213
|
+
readonly unpublish_first: "削除できません";
|
|
214
|
+
readonly last_admin: "操作できません";
|
|
215
|
+
readonly exceeds_own: "権限がありません";
|
|
216
|
+
readonly reauth_required: "再認証が必要";
|
|
217
|
+
readonly approval_required: "承認が必要";
|
|
218
|
+
readonly stale: "内容が変わった申請";
|
|
219
|
+
readonly approval_closed: "承認できない申請";
|
|
220
|
+
readonly cursor_expired: "取り直しが必要です";
|
|
221
|
+
readonly already_linked: "結び付け済みです";
|
|
222
|
+
readonly invalid_invite: "招待を使えません";
|
|
223
|
+
readonly run_done: "完了済みの実行";
|
|
224
|
+
readonly body_too_large: "入力エラー";
|
|
225
|
+
readonly rate_limited: "回数の制限";
|
|
226
|
+
readonly upstream_failed: "取得エラー";
|
|
227
|
+
readonly not_configured: "設定エラー";
|
|
228
|
+
readonly unavailable: "一時的なエラー";
|
|
229
|
+
readonly writes_paused: "保存の一時停止";
|
|
230
|
+
readonly environment_frozen: "保存を止めている環境";
|
|
231
|
+
readonly job_failed: "処理の失敗";
|
|
232
|
+
readonly internal_error: "サーバーエラー";
|
|
233
|
+
readonly network_error: "通信エラー";
|
|
234
|
+
};
|
|
235
|
+
/** 項目ごとの理由がすべて未入力のときの見出し */
|
|
236
|
+
readonly requiredTitle: "必須項目の入力エラー";
|
|
237
|
+
};
|
|
238
|
+
/** エラーの文言のカタログ(ほかの言語の表の形) */
|
|
239
|
+
export type ErrorCatalog = Catalog<typeof ERROR_MESSAGES>;
|
|
240
|
+
/** コアの対象の表示名 */
|
|
241
|
+
export declare const TARGET_LABELS: Readonly<Record<ErrorTarget, string>>;
|
|
242
|
+
/** コレクションの id・マスタの種類からエラーの対象(対象の一覧になければ fallback) */
|
|
243
|
+
export declare const targetOf: (id: string, fallback: ErrorTarget) => ErrorTarget;
|
|
244
|
+
/**
|
|
245
|
+
* 対象ごとの文の追加(モジュールの manifest の messages、キーは対象の id、値は ICU MessageFormat)
|
|
246
|
+
* - own: 自分のものだけを操作できるときの文
|
|
247
|
+
* - noLink: 結び付くレコードがないアカウントの文、{name} は結び付くコレクションの表示名
|
|
248
|
+
*/
|
|
249
|
+
export type TargetMessages = Readonly<{
|
|
250
|
+
own?: Readonly<Record<string, string>>;
|
|
251
|
+
noLink?: Readonly<Record<string, string>>;
|
|
252
|
+
}>;
|
|
253
|
+
/** エラーの画面の文(targets は対象の表示名、messages は対象ごとの文の追加、画面はモジュールの対象と文とコレクションの表示名を含めた表。problems は name に入る問題の文) */
|
|
254
|
+
export declare function errorLabel(code: ErrorCode, params?: ErrorParams, targets?: Readonly<Record<string, string>>, messages?: TargetMessages, catalog?: ErrorCatalog, problems?: Readonly<Record<string, string>>, locale?: Locale): string;
|
|
255
|
+
/** 応答のエラーの英語の文(targets はコレクションの表示名、コアの対象は英語の表、モジュールの対象と文は使わない) */
|
|
256
|
+
export declare const errorText: (code: ErrorCode, params?: ErrorParams, targets?: Readonly<Record<string, string>>) => string;
|
|
257
|
+
/** 応答のエラーの文をカタログから作る(対象の表示名はカタログの表、ほかの言語の画面とアプリ向け) */
|
|
258
|
+
export declare const errorMessageOf: (error: Readonly<{
|
|
259
|
+
code: ErrorCode;
|
|
260
|
+
params?: ErrorParams;
|
|
261
|
+
}>, catalog?: ErrorCatalog) => string;
|
|
262
|
+
/** プロジェクトの文脈の外(受け皿の Worker・台帳・アプリ)のエラーの本文(requestId は要求の x-request-id、message は英語の文) */
|
|
263
|
+
export declare const errorBodyFor: (code: Exclude<ErrorCode, "network_error">, requestId: string, params?: ErrorParams) => ErrorBody;
|
|
264
|
+
/** モジュールの対象ごとの文をまとめる(同じ対象はあとのモジュールの文) */
|
|
265
|
+
export declare const mergeMessages: (list: readonly (TargetMessages | undefined)[]) => TargetMessages;
|
|
266
|
+
/** エラーのトーストの見出し(項目ごとの理由がすべて未入力なら必須項目のエラー、スキーマの文は「〜が未入力」で統一) */
|
|
267
|
+
export declare const errorTitle: (code: ErrorCode, issues?: readonly {
|
|
268
|
+
message: string;
|
|
269
|
+
}[], catalog?: ErrorCatalog) => string;
|
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
/** エラーの英語のカタログ */
|
|
2
|
+
export declare const ERROR_MESSAGES_EN: {
|
|
3
|
+
readonly targets: {
|
|
4
|
+
readonly request: "creation request";
|
|
5
|
+
readonly role: "role";
|
|
6
|
+
readonly media: "media";
|
|
7
|
+
readonly record: "master";
|
|
8
|
+
readonly asset: "image";
|
|
9
|
+
readonly mcp: "MCP";
|
|
10
|
+
readonly version: "version";
|
|
11
|
+
readonly profile: "profile";
|
|
12
|
+
readonly portrait: "portrait";
|
|
13
|
+
readonly extension: "extension";
|
|
14
|
+
readonly account: "account";
|
|
15
|
+
readonly comment: "comment";
|
|
16
|
+
readonly view: "view";
|
|
17
|
+
readonly webhook: "webhook";
|
|
18
|
+
readonly external_function: "external function";
|
|
19
|
+
readonly external_screen: "external screen";
|
|
20
|
+
readonly api_key: "API key";
|
|
21
|
+
readonly preview: "preview signing key";
|
|
22
|
+
readonly trash: "trash";
|
|
23
|
+
readonly customer: "customer";
|
|
24
|
+
readonly customer_identity: "customer identity";
|
|
25
|
+
readonly customer_grant: "customer grant";
|
|
26
|
+
readonly app: "app";
|
|
27
|
+
readonly installation: "installation";
|
|
28
|
+
readonly invitation: "invitation";
|
|
29
|
+
readonly environment: "environment";
|
|
30
|
+
};
|
|
31
|
+
readonly codes: {
|
|
32
|
+
readonly invalid_input: "The input is invalid.";
|
|
33
|
+
readonly submit_unmet: "The submission requirements are not met.";
|
|
34
|
+
readonly publish_unmet: "The publishing requirements are not met.";
|
|
35
|
+
readonly save_unmet: "The saving requirements are not met.";
|
|
36
|
+
readonly version_required: "The base version (version) is required.";
|
|
37
|
+
readonly file_required: "Choose an image file.";
|
|
38
|
+
readonly file_too_large: "Images must be at most {assetMaxMB, number} MB.";
|
|
39
|
+
readonly unsupported_image: "Unsupported image format (PNG, JPEG, GIF, WebP).";
|
|
40
|
+
readonly unsupported_file: "Unsupported file format (PDF, ZIP, text, CSV, Word, Excel, PowerPoint).";
|
|
41
|
+
readonly invalid_dimensions: "The image dimensions are invalid.";
|
|
42
|
+
readonly https_required: "Specify an https URL.";
|
|
43
|
+
readonly invalid_style: "Invalid art style ID (choose from styles).";
|
|
44
|
+
readonly login_required: "Login is required.";
|
|
45
|
+
readonly invalid_mcp_token: "The call from MCP is invalid.";
|
|
46
|
+
readonly mcp_signature_invalid: "Cannot verify the call from the MCP server. Contact the operator.";
|
|
47
|
+
readonly invalid_account_token: "The app account credential token is invalid. Replace it with the token shown on the screen.";
|
|
48
|
+
readonly preview_token_required: "A preview signature is required to get drafts.";
|
|
49
|
+
readonly invalid_preview_token: "The preview signature does not match.";
|
|
50
|
+
readonly api_key_required: "An API key is required (Authorization: Bearer).";
|
|
51
|
+
readonly invalid_api_key: "The API key is invalid.";
|
|
52
|
+
readonly invalid_id_token: "The ID token is invalid. Get a new one and send it again.";
|
|
53
|
+
readonly invalid_app_token: "The app credential is invalid. Get a new app JWT or installation token and send it again.";
|
|
54
|
+
readonly api_key_forbidden: "{target, select, none {The API key is not allowed to get this.} other {The API key is not allowed to get {target}.}}";
|
|
55
|
+
readonly account_not_found: "There is no account{name, select, none {} other { for {name}}}. Ask an administrator to register the account.";
|
|
56
|
+
readonly mcp_not_allowed: "This operation is not available from MCP.";
|
|
57
|
+
readonly insufficient_scope: "The scope allowed for the AI connection does not permit this operation. Reconnect and allow {scope, select, content_publish {\"up to publishing\"} other {the required scope}}.";
|
|
58
|
+
readonly admin_only: "Only administrators can do this.";
|
|
59
|
+
readonly operator_read_only: "The operator support access is read-only, so changes are not allowed.";
|
|
60
|
+
readonly not_trial: "This operation is only for projects with the trial flag.";
|
|
61
|
+
readonly not_live: "This operation is only available in the live environment. Use the admin screen of the live environment.";
|
|
62
|
+
readonly operator_closed: "This operation is outside what operator support access allows (accounts, roles, integrations, apps, customer IDs, permissions and so on).";
|
|
63
|
+
readonly forbidden: "{target, select, none {You do not have permission for this operation.} other {You do not have permission for this operation on {target}.}}";
|
|
64
|
+
readonly editorial_only: "{target, select, none {This} other {The {target}}} can only be created by accounts with publishing permission.";
|
|
65
|
+
readonly no_linked_record: "Accounts without a linked {name} cannot do this.";
|
|
66
|
+
readonly own_only: "You can only operate on your own {target, select, none {items} other {{target}}}.";
|
|
67
|
+
readonly not_visible: "You cannot view unpublished {target, select, none {items} other {{target}}} of other people.";
|
|
68
|
+
readonly published_admin_only: "Editing published records requires publishing permission.";
|
|
69
|
+
readonly cannot_remove_self: "You cannot remove yourself from the link.";
|
|
70
|
+
readonly cannot_change_owner: "The owner cannot be changed.";
|
|
71
|
+
readonly not_found: "{target, select, none {The target} other {The {target}}} was not found.";
|
|
72
|
+
readonly method_not_allowed: "This path does not accept this method.";
|
|
73
|
+
readonly customer_not_linked: "No customer is linked to this account.";
|
|
74
|
+
readonly customer_pending: "The link of this account becomes usable after review by the operator.";
|
|
75
|
+
readonly in_use: "{by, select, uses {Cannot delete because it is used in {count, number} items.} places {Cannot delete because it is used in {count, number} places.} outputs {Cannot delete because it is used by {count, number} planning outputs.} record {Cannot delete because it is used by {name, select, none {other content} other {{name}}}.} writers {Cannot delete because it is linked to {count, number} records.} customers {Cannot delete because {count, number} records belong to it.} accounts {Cannot delete because {count, number} accounts have this role.} module {Cannot delete because it is referenced by {count, number} {name, select, none {extension records} other {{name}}}.} other {Cannot delete because it is in use.}}";
|
|
76
|
+
readonly duplicate_name: "The same name already exists.";
|
|
77
|
+
readonly duplicate_email: "An account with the same email address already exists.";
|
|
78
|
+
readonly duplicate_id: "This ID is already in use.";
|
|
79
|
+
readonly duplicate_slug: "This slug is already in use.";
|
|
80
|
+
readonly version_conflict: "This conflicted with another update. Load the latest version and try again.";
|
|
81
|
+
readonly article_editing: "{name, select, none {Someone else} other {{name}}} is editing this in the CMS, so it cannot be saved. Saving becomes possible within 2 minutes after the editor is closed or another tab is selected.";
|
|
82
|
+
readonly invalid_state: "This operation is not possible in the current state.";
|
|
83
|
+
readonly unpublish_first: "Unpublish published records before deleting them.";
|
|
84
|
+
readonly last_admin: "The last administrator cannot be removed or demoted from the administrator role.";
|
|
85
|
+
readonly exceeds_own: "You cannot grant permissions wider than your own role.";
|
|
86
|
+
readonly reauth_required: "Log in again before approving.";
|
|
87
|
+
readonly approval_required: "This change reaches production, so it needs a request and approval.";
|
|
88
|
+
readonly stale: "The content changed after the request. Request again.";
|
|
89
|
+
readonly approval_closed: "This request can no longer be approved (applied, rejected, withdrawn or expired).";
|
|
90
|
+
readonly cursor_expired: "The change log retention period has passed. Get all items again without cursor.";
|
|
91
|
+
readonly already_linked: "{reason, select, identity {This account is already linked to another customer.} other {This customer is already linked to an account of the same issuer.}}";
|
|
92
|
+
readonly run_done: "This import run is already complete. Start a new run.";
|
|
93
|
+
readonly invalid_invite: "{reason, select, expired {The invitation has expired.} used {The invitation has already been used.} other {The invitation was not found.}}";
|
|
94
|
+
readonly body_too_large: "The request body must be at most {bodyMaxMB, number} MB.";
|
|
95
|
+
readonly rate_limited: "Too many calls. Wait a while and try again.";
|
|
96
|
+
readonly upstream_failed: "{resource, select, image {Could not fetch the image.} webhook {Could not send to the webhook.} file {Could not fetch the file.} source {Could not fetch content from the source. Check the connection details (service ID, API key and so on).} hosting {Could not upload the site to the hosting location.} other {Could not fetch the page.}}";
|
|
97
|
+
readonly not_configured: "Configuration is missing.{name, select, none {} other { {name}}}";
|
|
98
|
+
readonly unavailable: "Temporarily unable to process. Wait a while and try again.";
|
|
99
|
+
readonly writes_paused: "Saving is paused during a deployment. Try again in a few minutes.";
|
|
100
|
+
readonly environment_frozen: "This environment has stopped saving (during a live switch, or it is no longer live). Reading is possible.";
|
|
101
|
+
readonly job_failed: "The job failed.{name, select, none {} other { {name}}}";
|
|
102
|
+
readonly internal_error: "The server failed to process the request. Try again.";
|
|
103
|
+
readonly network_error: "Communication failed. Check the connection and try again.";
|
|
104
|
+
};
|
|
105
|
+
readonly states: {
|
|
106
|
+
readonly not_draft: "Not a draft.";
|
|
107
|
+
readonly no_draft: "There are no unpublished changes apart from the published version.";
|
|
108
|
+
readonly not_in_review: "Not in review.";
|
|
109
|
+
readonly request_handled: "This request has already been handled.";
|
|
110
|
+
readonly deleted: "Already deleted.";
|
|
111
|
+
readonly not_deleted: "Cannot restore because it is not deleted.";
|
|
112
|
+
readonly schema_confirm: "This includes changes with impact. Check the counts before saving.";
|
|
113
|
+
readonly no_publishing: "This collection has no workflow.";
|
|
114
|
+
readonly no_review: "The workflow of this collection has no review.";
|
|
115
|
+
readonly not_published: "Not published or scheduled.";
|
|
116
|
+
readonly collection_rows: "Records remain. Check the counts before deleting.";
|
|
117
|
+
readonly restore_conflict: "Cannot restore because {name, select, none {the same content} other {{name}}} already exists.";
|
|
118
|
+
readonly collection_exists: "Cannot restore because a collection with the same id already exists.";
|
|
119
|
+
readonly collection_missing: "Cannot restore because the collection is deleted. Restore the collection first.";
|
|
120
|
+
readonly not_restorable: "Cannot restore because it was deleted by a personal deletion request or after the retention of a closed customer.";
|
|
121
|
+
readonly installation_state: "This operation is not possible in the current installation state.";
|
|
122
|
+
readonly site_deploy: "The site cannot be uploaded now. Another upload is in progress, or the site is stopped or removed.";
|
|
123
|
+
readonly site_stopped_by_check: "The site was stopped because the check right after the upload failed. Upload a fix and ask the operator to restore it.";
|
|
124
|
+
readonly required_module: "Required extensions cannot be stopped or removed.";
|
|
125
|
+
readonly app_installed: "An app can be installed only once per project.";
|
|
126
|
+
readonly app_dependencies: "Cannot satisfy the app dependencies. Check the reasons in conflicts.";
|
|
127
|
+
readonly app_reinstalled: "The data of the old installation cannot be deleted because the same app has been reinstalled.";
|
|
128
|
+
readonly app_managed: "This registration is managed by an app installation. Change it by consenting to a new app version.";
|
|
129
|
+
readonly request_key_reused: "A record with another person, channel or purpose already exists for the same deduplication key.";
|
|
130
|
+
readonly no_tenant: "Cannot invite because the project does not belong to an organization. Ask the operator to add it to an organization.";
|
|
131
|
+
readonly schema_changed: "Could not save because the schema changed. Reload the screen.";
|
|
132
|
+
readonly customer_inactive: "This customer is suspended or closed, so the operation is not possible.";
|
|
133
|
+
readonly self_limit: "The limit of records per person has been reached.";
|
|
134
|
+
readonly already_live: "This environment is already live.";
|
|
135
|
+
readonly target_live: "The live environment cannot be deleted. Switch to another environment first.";
|
|
136
|
+
readonly target_synthetic: "An environment with synthetic data cannot become live.";
|
|
137
|
+
readonly no_changes: "There are no differences from live.";
|
|
138
|
+
readonly schema_values: "Cannot apply because the changes remove fields with values. Move the values in live and try again.";
|
|
139
|
+
readonly environment_limit: "The number of environments has reached the plan limit.";
|
|
140
|
+
readonly environment_busy: "This environment is in the middle of another operation. Wait a moment and try again.";
|
|
141
|
+
readonly unregistered_table: "Cannot copy because some tables have no decided handling of personal information.";
|
|
142
|
+
readonly not_frozen: "Writes to live are not stopped.";
|
|
143
|
+
readonly approval_running: "An approved operation is running. Wait a moment and try again.";
|
|
144
|
+
};
|
|
145
|
+
readonly own: {
|
|
146
|
+
readonly profile: "You can only edit your own profile.";
|
|
147
|
+
readonly portrait: "You can only change your own portrait.";
|
|
148
|
+
};
|
|
149
|
+
readonly noLink: {
|
|
150
|
+
readonly mcp: "Accounts without a linked {name} cannot use MCP.";
|
|
151
|
+
};
|
|
152
|
+
readonly linkedRecord: "record";
|
|
153
|
+
readonly titles: {
|
|
154
|
+
readonly invalid_input: "Input error";
|
|
155
|
+
readonly submit_unmet: "Cannot submit";
|
|
156
|
+
readonly publish_unmet: "Cannot publish";
|
|
157
|
+
readonly save_unmet: "Cannot save";
|
|
158
|
+
readonly version_required: "Input error";
|
|
159
|
+
readonly file_required: "Input error";
|
|
160
|
+
readonly file_too_large: "Input error";
|
|
161
|
+
readonly unsupported_image: "Input error";
|
|
162
|
+
readonly unsupported_file: "Input error";
|
|
163
|
+
readonly invalid_dimensions: "Input error";
|
|
164
|
+
readonly https_required: "Input error";
|
|
165
|
+
readonly invalid_style: "Input error";
|
|
166
|
+
readonly login_required: "Login error";
|
|
167
|
+
readonly invalid_mcp_token: "Login error";
|
|
168
|
+
readonly mcp_signature_invalid: "Login error";
|
|
169
|
+
readonly invalid_account_token: "Login error";
|
|
170
|
+
readonly preview_token_required: "Login error";
|
|
171
|
+
readonly invalid_preview_token: "Login error";
|
|
172
|
+
readonly api_key_required: "Login error";
|
|
173
|
+
readonly invalid_api_key: "Login error";
|
|
174
|
+
readonly invalid_id_token: "Login error";
|
|
175
|
+
readonly invalid_app_token: "Login error";
|
|
176
|
+
readonly api_key_forbidden: "Not allowed";
|
|
177
|
+
readonly account_not_found: "Login error";
|
|
178
|
+
readonly mcp_not_allowed: "Not allowed";
|
|
179
|
+
readonly insufficient_scope: "Not allowed";
|
|
180
|
+
readonly admin_only: "Not allowed";
|
|
181
|
+
readonly operator_read_only: "Not allowed";
|
|
182
|
+
readonly operator_closed: "Not allowed";
|
|
183
|
+
readonly not_trial: "Not allowed";
|
|
184
|
+
readonly not_live: "Live environment only";
|
|
185
|
+
readonly forbidden: "Not allowed";
|
|
186
|
+
readonly editorial_only: "Not allowed";
|
|
187
|
+
readonly no_linked_record: "Not allowed";
|
|
188
|
+
readonly own_only: "Not allowed";
|
|
189
|
+
readonly not_visible: "Not allowed";
|
|
190
|
+
readonly published_admin_only: "Not allowed";
|
|
191
|
+
readonly cannot_remove_self: "Not allowed";
|
|
192
|
+
readonly cannot_change_owner: "Not allowed";
|
|
193
|
+
readonly not_found: "Not found";
|
|
194
|
+
readonly method_not_allowed: "Not possible";
|
|
195
|
+
readonly customer_not_linked: "Not found";
|
|
196
|
+
readonly customer_pending: "Pending review";
|
|
197
|
+
readonly in_use: "Cannot delete";
|
|
198
|
+
readonly duplicate_name: "Duplicate";
|
|
199
|
+
readonly duplicate_email: "Duplicate";
|
|
200
|
+
readonly duplicate_id: "Duplicate";
|
|
201
|
+
readonly duplicate_slug: "Duplicate";
|
|
202
|
+
readonly version_conflict: "Update conflict";
|
|
203
|
+
readonly article_editing: "Being edited";
|
|
204
|
+
readonly invalid_state: "Not possible";
|
|
205
|
+
readonly unpublish_first: "Cannot delete";
|
|
206
|
+
readonly last_admin: "Not possible";
|
|
207
|
+
readonly exceeds_own: "Not allowed";
|
|
208
|
+
readonly reauth_required: "Log in again";
|
|
209
|
+
readonly approval_required: "Approval required";
|
|
210
|
+
readonly stale: "Request changed";
|
|
211
|
+
readonly approval_closed: "Cannot approve";
|
|
212
|
+
readonly cursor_expired: "Reload required";
|
|
213
|
+
readonly already_linked: "Already linked";
|
|
214
|
+
readonly invalid_invite: "Invitation unusable";
|
|
215
|
+
readonly run_done: "Run complete";
|
|
216
|
+
readonly body_too_large: "Input error";
|
|
217
|
+
readonly rate_limited: "Rate limited";
|
|
218
|
+
readonly upstream_failed: "Fetch error";
|
|
219
|
+
readonly not_configured: "Configuration error";
|
|
220
|
+
readonly unavailable: "Temporary error";
|
|
221
|
+
readonly writes_paused: "Saving paused";
|
|
222
|
+
readonly environment_frozen: "Saving stopped";
|
|
223
|
+
readonly job_failed: "Job failed";
|
|
224
|
+
readonly internal_error: "Server error";
|
|
225
|
+
readonly network_error: "Network error";
|
|
226
|
+
};
|
|
227
|
+
readonly requiredTitle: "Required fields missing";
|
|
228
|
+
};
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import type { ManagementOperation, Operation, TenantRole } from './authorize.js';
|
|
2
|
+
import { FAILURE_STATUS } from './failureStatus.js';
|
|
3
|
+
/** 変更の操作で受け付ける本文の大きさ(/api、バイト数、multipart のアップロードは ASSET_SIZE_MAX) */
|
|
4
|
+
export declare const JSON_BODY_MAX: number;
|
|
5
|
+
/** 画面の側だけのコード(通信の失敗と JSON でない応答。HTTP の状態を持たない) */
|
|
6
|
+
declare const NETWORK_ERROR = "network_error";
|
|
7
|
+
/** CMS の API のエラーのコード(状態は failureStatus.ts の表) */
|
|
8
|
+
declare const ERROR_CODES: readonly ["invalid_input", "submit_unmet", "publish_unmet", "save_unmet", "version_required", "file_required", "file_too_large", "unsupported_image", "unsupported_file", "invalid_dimensions", "https_required", "invalid_style", "login_required", "invalid_mcp_token", "mcp_signature_invalid", "invalid_account_token", "preview_token_required", "api_key_required", "invalid_api_key", "invalid_id_token", "invalid_app_token", "account_not_found", "invalid_preview_token", "api_key_forbidden", "mcp_not_allowed", "insufficient_scope", "admin_only", "operator_read_only", "operator_closed", "not_trial", "not_live", "forbidden", "editorial_only", "no_linked_record", "own_only", "not_visible", "published_admin_only", "cannot_remove_self", "cannot_change_owner", "not_found", "customer_not_linked", "customer_pending", "method_not_allowed", "in_use", "duplicate_name", "duplicate_email", "duplicate_id", "duplicate_slug", "version_conflict", "article_editing", "invalid_state", "unpublish_first", "last_admin", "exceeds_own", "reauth_required", "approval_required", "stale", "approval_closed", "already_linked", "invalid_invite", "run_done", "cursor_expired", "body_too_large", "rate_limited", "upstream_failed", "not_configured", "unavailable", "writes_paused", "environment_frozen", "job_failed", "internal_error", "network_error"];
|
|
9
|
+
/** エラーのコード */
|
|
10
|
+
export type ErrorCode = (typeof ERROR_CODES)[number];
|
|
11
|
+
/** やり直せば通りうるエラー(画面はこれだけに再試行のボタンを出す) */
|
|
12
|
+
export declare const RETRYABLE_ERRORS: readonly ["rate_limited", "upstream_failed", "unavailable", "writes_paused", "job_failed", "internal_error", "network_error"];
|
|
13
|
+
/** サーバーが返すエラーのコード */
|
|
14
|
+
type ServerErrorCode = Exclude<ErrorCode, typeof NETWORK_ERROR>;
|
|
15
|
+
/** エラーのコードと HTTP の状態(failureStatus.ts の表の CMS の API の部分) */
|
|
16
|
+
export declare const ERROR_STATUS: { readonly [K in ServerErrorCode]: (typeof FAILURE_STATUS)[K]; };
|
|
17
|
+
/**
|
|
18
|
+
* コアの操作や表示の対象(not_found・own_only などの params.target)
|
|
19
|
+
* - コレクションの対象: コレクションの id、表示名はスキーマ
|
|
20
|
+
* - モジュールの対象: ModuleManifest の targets
|
|
21
|
+
*/
|
|
22
|
+
export type ErrorTarget = 'request' | 'role' | 'media' | 'record' | 'asset' | 'mcp' | 'version' | 'profile' | 'portrait' | 'extension' | 'account' | 'comment' | 'view' | 'webhook' | 'external_function' | 'external_screen' | 'api_key' | 'preview' | 'trash' | 'customer' | 'customer_identity' | 'customer_grant' | 'app' | 'installation' | 'invitation' | 'environment';
|
|
23
|
+
/** 状態の不一致の理由(invalid_state) */
|
|
24
|
+
export type InvalidStateReason = 'not_draft' | 'no_draft' | 'not_in_review' | 'request_handled' | 'deleted' | 'not_deleted' | 'schema_confirm' | 'no_publishing' | 'no_review' | 'not_published' | 'collection_rows' | 'restore_conflict' | 'collection_exists' | 'collection_missing' | 'not_restorable' | 'installation_state' | 'required_module' | 'app_installed' | 'app_dependencies' | 'app_reinstalled' | 'app_managed' | 'request_key_reused' | 'no_tenant' | 'schema_changed' | 'site_deploy' | 'site_stopped_by_check' | 'customer_inactive' | 'self_limit' | 'already_live' | 'target_live' | 'target_synthetic' | 'no_changes' | 'schema_values' | 'environment_limit' | 'environment_busy' | 'unregistered_table' | 'not_frozen' | 'approval_running';
|
|
25
|
+
/**
|
|
26
|
+
* 権限の拒否で足りないもの(403 forbidden の params.required)
|
|
27
|
+
* - operation: 拒んだ操作(Operation か、プロジェクトの管理の操作 ManagementOperation)
|
|
28
|
+
* - roles: その操作を持つロール(ロールで決まる操作だけ。管理の操作はテナントのロール)
|
|
29
|
+
* - capability: 足りない能力(アプリ・インストールの能力の文字列、例 `op:<コレクション>:read_customers`)
|
|
30
|
+
*/
|
|
31
|
+
export type ErrorRequired = Readonly<{
|
|
32
|
+
operation: Operation | ManagementOperation;
|
|
33
|
+
roles?: readonly (string | TenantRole)[];
|
|
34
|
+
capability?: string;
|
|
35
|
+
}>;
|
|
36
|
+
/** エラーの補足の値(コードごとに使用する項目だけ) */
|
|
37
|
+
export type ErrorParams = {
|
|
38
|
+
/**
|
|
39
|
+
* 対象: not_found・own_only・forbidden・not_visible・no_linked_record・editorial_only・api_key_forbidden
|
|
40
|
+
* - 文字列: モジュールの対象・コレクションの id
|
|
41
|
+
*/
|
|
42
|
+
target?: ErrorTarget | (string & {});
|
|
43
|
+
/** 件数: in_use */
|
|
44
|
+
count?: number;
|
|
45
|
+
/** 使用先: in_use */
|
|
46
|
+
by?: 'uses' | 'places' | 'outputs' | 'record' | 'writers' | 'customers' | 'accounts' | 'module';
|
|
47
|
+
/**
|
|
48
|
+
* 理由: invalid_state(InvalidStateReason)、already_linked(identity は相手の ID、customer は顧客)
|
|
49
|
+
* - invalid_invite: not_found・expired・used
|
|
50
|
+
*/
|
|
51
|
+
reason?: InvalidStateReason | 'identity' | 'customer' | 'not_found' | 'expired' | 'used';
|
|
52
|
+
/** 取得の対象: upstream_failed */
|
|
53
|
+
resource?: 'page' | 'image' | 'webhook' | 'source' | 'file' | 'hosting';
|
|
54
|
+
/**
|
|
55
|
+
* 名前
|
|
56
|
+
* - no_linked_record: 結び付くコレクションの表示名、account_not_found: メールアドレス
|
|
57
|
+
* - not_configured: 設定の名前、job_failed: 失敗の理由、in_use の record: 参照するコレクションと項目、
|
|
58
|
+
* in_use の module: 参照するモジュールの表の表示名
|
|
59
|
+
* - invalid_state の restore_conflict: 戻すレコードとぶつかるレコードの表示名
|
|
60
|
+
*/
|
|
61
|
+
name?: string;
|
|
62
|
+
/** 権限の拒否で足りないもの: forbidden */
|
|
63
|
+
required?: ErrorRequired;
|
|
64
|
+
/** MCP の接続に足りない範囲: insufficient_scope(MCP の Worker が403の WWW-Authenticate の scope に写す) */
|
|
65
|
+
scope?: string;
|
|
66
|
+
};
|
|
67
|
+
/**
|
|
68
|
+
* エラーの応答の本文
|
|
69
|
+
* - message: 英語の定型の文(画面は code と params で引く)、requestId: 相関の ID(すべてのエラー)
|
|
70
|
+
* - login: ログインなしのとき、CMS 自身が受け持つログインの入り口
|
|
71
|
+
* - capability: アプリの主体の閲覧の拒否で、足りない能力(顧客だけの項目を持つコレクションの `op:<コレクション>:read_customers`)
|
|
72
|
+
*/
|
|
73
|
+
/** 検査の結果の重さ(error は保存・提出・取り込みを止め、warning は止めない) */
|
|
74
|
+
export declare const ISSUE_SEVERITIES: readonly ["error", "warning"];
|
|
75
|
+
export type IssueSeverity = (typeof ISSUE_SEVERITIES)[number];
|
|
76
|
+
/**
|
|
77
|
+
* 検査の結果の1件(エラーの応答の issues と、検査が目的の操作の200の issues で同じ形、path は項目の key をドットで連結)
|
|
78
|
+
* - code: 検査の問題のコード(コンテンツスキーマ、本文、編集)、入力の形の誤りは zod の issue の code、ほかは invalid
|
|
79
|
+
* - message: 英語の既定の文、params: 差し込み(画面は code と params を文言の表で引く)
|
|
80
|
+
*/
|
|
81
|
+
export type Issue = {
|
|
82
|
+
path: string;
|
|
83
|
+
code: string;
|
|
84
|
+
message: string;
|
|
85
|
+
params?: Readonly<Record<string, string | number>>;
|
|
86
|
+
severity: IssueSeverity;
|
|
87
|
+
};
|
|
88
|
+
/** 検査の結果を作るときの形(code と severity は省けて、応答の手前で決まる) */
|
|
89
|
+
export type IssueInput = Readonly<{
|
|
90
|
+
path: string;
|
|
91
|
+
message: string;
|
|
92
|
+
code?: string;
|
|
93
|
+
params?: Issue['params'];
|
|
94
|
+
severity?: IssueSeverity;
|
|
95
|
+
}>;
|
|
96
|
+
export type ErrorBody = {
|
|
97
|
+
code: ErrorCode;
|
|
98
|
+
message: string;
|
|
99
|
+
params?: ErrorParams;
|
|
100
|
+
issues?: Issue[];
|
|
101
|
+
login?: string;
|
|
102
|
+
requestId: string;
|
|
103
|
+
capability?: string;
|
|
104
|
+
};
|
|
105
|
+
export {};
|