@deepdynamic/cli 0.0.0-stage → 0.1.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.
Files changed (82) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +32 -2
  3. package/THIRD_PARTY_NOTICES.txt +102 -0
  4. package/dist/agents/content.js +12 -0
  5. package/dist/agents/edit.js +140 -0
  6. package/dist/agents/install.js +180 -0
  7. package/dist/agents/setup.js +29 -0
  8. package/dist/agents/targets.js +91 -0
  9. package/dist/auth/credentials.js +63 -0
  10. package/dist/auth/session.js +49 -0
  11. package/dist/cli.js +198 -0
  12. package/dist/commands/account.js +96 -0
  13. package/dist/commands/activity.js +80 -0
  14. package/dist/commands/blocked.js +89 -0
  15. package/dist/commands/deploy/agents.js +11 -0
  16. package/dist/commands/deploy/files.js +62 -0
  17. package/dist/commands/deploy/index.js +95 -0
  18. package/dist/commands/deploy/manifest.js +24 -0
  19. package/dist/commands/deploy/minify.js +27 -0
  20. package/dist/commands/deploy/progress.js +85 -0
  21. package/dist/commands/deploy/ship.js +117 -0
  22. package/dist/commands/deploy/upload.js +125 -0
  23. package/dist/commands/deployments.js +59 -0
  24. package/dist/commands/dns.js +791 -0
  25. package/dist/commands/domains.js +711 -0
  26. package/dist/commands/emails.js +74 -0
  27. package/dist/commands/env.js +194 -0
  28. package/dist/commands/help.js +149 -0
  29. package/dist/commands/keys.js +269 -0
  30. package/dist/commands/login/flow.js +155 -0
  31. package/dist/commands/login/index.js +26 -0
  32. package/dist/commands/logout.js +71 -0
  33. package/dist/commands/mail.js +241 -0
  34. package/dist/commands/notifications.js +132 -0
  35. package/dist/commands/plan.js +371 -0
  36. package/dist/commands/projects.js +836 -0
  37. package/dist/commands/reference.js +2180 -0
  38. package/dist/commands/search.js +75 -0
  39. package/dist/commands/server.js +314 -0
  40. package/dist/commands/sessions.js +120 -0
  41. package/dist/commands/sites.js +102 -0
  42. package/dist/commands/sms.js +65 -0
  43. package/dist/commands/status.js +87 -0
  44. package/dist/commands/support.js +115 -0
  45. package/dist/commands/update.js +98 -0
  46. package/dist/commands/usage.js +51 -0
  47. package/dist/commands/verify.js +149 -0
  48. package/dist/commands/version.js +6 -0
  49. package/dist/guide.js +76 -0
  50. package/dist/http/call.js +6 -0
  51. package/dist/http/request.js +54 -0
  52. package/dist/index.js +11 -0
  53. package/dist/metadata.js +4 -0
  54. package/dist/output.js +9 -0
  55. package/dist/pretty.js +70 -0
  56. package/dist/registry.js +760 -0
  57. package/dist/runtime/browser.js +15 -0
  58. package/dist/runtime/card-request.js +55 -0
  59. package/dist/runtime/confirm.js +21 -0
  60. package/dist/runtime/development.js +13 -0
  61. package/dist/runtime/domain-name.js +5 -0
  62. package/dist/runtime/dry-run.js +28 -0
  63. package/dist/runtime/env-file.js +58 -0
  64. package/dist/runtime/error-hints.js +26 -0
  65. package/dist/runtime/flags.js +50 -0
  66. package/dist/runtime/login-screen.js +78 -0
  67. package/dist/runtime/page.js +18 -0
  68. package/dist/runtime/project-name.js +1 -0
  69. package/dist/runtime/run-mode.js +7 -0
  70. package/dist/runtime/server-options.js +32 -0
  71. package/dist/runtime/spinner.js +15 -0
  72. package/dist/runtime/suggest.js +22 -0
  73. package/dist/runtime/support.js +14 -0
  74. package/dist/runtime/text-file.js +20 -0
  75. package/dist/runtime/timeout.js +22 -0
  76. package/dist/runtime/update-check.js +124 -0
  77. package/dist/runtime/update-install.js +50 -0
  78. package/dist/runtime/usage-error.js +9 -0
  79. package/dist/setup-agents.js +8 -0
  80. package/dist/site.js +1 -0
  81. package/dist/update-refresh.js +5 -0
  82. package/package.json +46 -3
@@ -0,0 +1,760 @@
1
+ export const commands = [
2
+ {
3
+ name: 'login',
4
+ usage: 'deepdynamic login [--server <http(s)://host>] [--dry-run]',
5
+ prettyUsage: 'deepdynamic login [--server <http(s)://주소>] [--dry-run]',
6
+ summary: '계정 로그인',
7
+ description: 'Log in through browser approval and save credentials locally.',
8
+ effect: 'write',
9
+ requiresLogin: false,
10
+ requiresBrowser: true,
11
+ dryRun: 'local'
12
+ },
13
+ {
14
+ name: 'logout',
15
+ usage: 'deepdynamic logout [--dry-run]',
16
+ prettyUsage: 'deepdynamic logout [--dry-run]',
17
+ summary: '계정 로그아웃',
18
+ description: 'Revoke the saved access token on the server and delete the local credentials.',
19
+ effect: 'write',
20
+ requiresLogin: false,
21
+ dryRun: 'local'
22
+ },
23
+ {
24
+ name: 'account get',
25
+ usage: 'deepdynamic account get [--dry-run]',
26
+ prettyUsage: 'deepdynamic account get [--dry-run]',
27
+ summary: '로그인한 계정과 안내 보기',
28
+ description: 'Show the signed-in account and the guide for talking to this user. Run it before other commands.',
29
+ effect: 'read',
30
+ requiresLogin: false,
31
+ dryRun: 'local'
32
+ },
33
+ {
34
+ name: 'account activity',
35
+ usage: 'deepdynamic account activity [--page <number>] [--kind login|change] [--date YYYY-MM-DD] [--source web|cli] [--dry-run]',
36
+ prettyUsage: 'deepdynamic account activity [--page <번호>] [--kind login|change] [--date YYYY-MM-DD] [--source web|cli] [--dry-run]',
37
+ summary: '계정 기록 확인',
38
+ description: "List the account's sign-in and settings-change records, newest first, 10 per page.",
39
+ effect: 'read',
40
+ requiresLogin: true,
41
+ dryRun: 'local'
42
+ },
43
+ {
44
+ name: 'account notifications',
45
+ usage: 'deepdynamic account notifications [--unread] [--limit <number>] [--dry-run]',
46
+ prettyUsage: 'deepdynamic account notifications [--unread] [--limit <개수>] [--dry-run]',
47
+ summary: '알림함 보기',
48
+ description: "List the account's notifications (failed payments, certificate and domain expiry, autopilot limit), newest first.",
49
+ effect: 'read',
50
+ requiresLogin: true,
51
+ dryRun: 'local'
52
+ },
53
+ {
54
+ name: 'account notifications read',
55
+ usage: 'deepdynamic account notifications read (<notification-id>... | --all) [--dry-run]',
56
+ prettyUsage: 'deepdynamic account notifications read (<알림 ID>... | --all) [--dry-run]',
57
+ summary: '알림 읽음 표시',
58
+ description: 'Mark the given notifications, or all of them with --all, as read.',
59
+ effect: 'write',
60
+ requiresLogin: true,
61
+ dryRun: 'local'
62
+ },
63
+ {
64
+ name: 'account delete',
65
+ usage: 'deepdynamic account delete [--dry-run]',
66
+ prettyUsage: 'deepdynamic account delete [--dry-run]',
67
+ summary: '계정 삭제 조건 확인·요청 화면 열기',
68
+ description: 'Show what blocks deleting the account and open the web page where the user requests deletion.',
69
+ effect: 'read',
70
+ requiresLogin: true,
71
+ requiresBrowser: true,
72
+ dryRun: 'local'
73
+ },
74
+ {
75
+ name: 'system status',
76
+ usage: 'deepdynamic system status [--server <http(s)://host>] [--dry-run]',
77
+ prettyUsage: 'deepdynamic system status [--server <http(s)://주소>] [--dry-run]',
78
+ summary: '배포 서버 연결 확인',
79
+ description: 'Check that the deployment server and its services respond.',
80
+ effect: 'read',
81
+ requiresLogin: false,
82
+ dryRun: 'local'
83
+ },
84
+ {
85
+ name: 'verify',
86
+ usage: 'deepdynamic verify [--save <path>] [--file <path>] [--server <http(s)://host>] [--dry-run]',
87
+ prettyUsage: 'deepdynamic verify [--save <경로>] [--file <경로>] [--server <http(s)://주소>] [--dry-run]',
88
+ summary: '메트릭 스크립트 확인·내려받기',
89
+ description: 'Download ddn.js, compare its SHA-384 hash with the published manifest and optionally save it.',
90
+ effect: 'read',
91
+ requiresLogin: false,
92
+ dryRun: 'local'
93
+ },
94
+ {
95
+ name: 'help',
96
+ usage: 'deepdynamic help [--all]',
97
+ prettyUsage: 'deepdynamic help [--all]',
98
+ summary: '도움말 보기',
99
+ description: 'Show the command list and the global options. With --all, return the full command tree like deepdynamic commands.',
100
+ effect: 'read',
101
+ requiresLogin: false
102
+ },
103
+ {
104
+ name: 'commands',
105
+ usage: 'deepdynamic commands',
106
+ prettyUsage: 'deepdynamic commands',
107
+ summary: '전체 명령 트리 보기',
108
+ description: 'Return every command in one tree with its usage, effect, login, --dry-run and --yes.',
109
+ effect: 'read',
110
+ requiresLogin: false
111
+ },
112
+ {
113
+ name: 'update',
114
+ usage: 'deepdynamic update [--yes] [--dry-run]',
115
+ prettyUsage: 'deepdynamic update [--yes] [--dry-run]',
116
+ summary: 'CLI 새 버전 확인·설치',
117
+ description: 'Check npm for a newer CLI version and install it globally with the package manager that installed the CLI.',
118
+ effect: 'write',
119
+ requiresLogin: false,
120
+ dryRun: 'local',
121
+ confirm: 'conditional'
122
+ },
123
+ {
124
+ name: 'sites',
125
+ usage: 'deepdynamic sites [--page <number>] [--server <http(s)://host>] [--dry-run]',
126
+ prettyUsage: 'deepdynamic sites [--page <번호>] [--server <http(s)://주소>] [--dry-run]',
127
+ summary: '공개된 배포 사이트 보기',
128
+ description: 'List the public sites deployed with DeepDynamic Cloud, 10 per page, each with a short summary.',
129
+ effect: 'read',
130
+ requiresLogin: false,
131
+ dryRun: 'local'
132
+ },
133
+ {
134
+ name: 'sites blocked',
135
+ usage: 'deepdynamic sites blocked [--page <number>] [--ray <id>] [--host <host>] [--date YYYY-MM-DD] [--dry-run]',
136
+ prettyUsage: 'deepdynamic sites blocked [--page <번호>] [--ray <ID>] [--host <호스트>] [--date YYYY-MM-DD] [--dry-run]',
137
+ summary: '사이트 차단 기록 보기',
138
+ description: 'List blocked requests to your sites that got the 403 page (ID, time, IP, method, path), newest first, 20 per page.',
139
+ effect: 'read',
140
+ requiresLogin: true,
141
+ dryRun: 'local'
142
+ },
143
+ {
144
+ name: 'search',
145
+ usage: 'deepdynamic search <page> [--server <http(s)://host>] [--dry-run]',
146
+ prettyUsage: 'deepdynamic search <페이지> [--server <http(s)://주소>] [--dry-run]',
147
+ summary: '웹사이트 페이지 정보 보기',
148
+ description: 'Look up the information one page of the DeepDynamic Cloud website provides, as Korean markdown.',
149
+ effect: 'read',
150
+ requiresLogin: false,
151
+ dryRun: 'local'
152
+ },
153
+ {
154
+ name: 'support qa',
155
+ usage: 'deepdynamic support qa [--server <http(s)://host>] [--dry-run]',
156
+ prettyUsage: 'deepdynamic support qa [--server <http(s)://주소>] [--dry-run]',
157
+ summary: '자주 묻는 질문 보기',
158
+ description: 'Show the FAQ and the guidelines for writing a support inquiry. Read this before deepdynamic support contact.',
159
+ effect: 'read',
160
+ requiresLogin: false,
161
+ dryRun: 'local'
162
+ },
163
+ {
164
+ name: 'support contact',
165
+ usage: 'deepdynamic support contact (--message <text> | --message-file <path>) [--team <email>]... [--dry-run]',
166
+ prettyUsage: 'deepdynamic support contact (--message <내용> | --message-file <경로>) [--team <이메일>]... [--dry-run]',
167
+ summary: '고객지원에 문의 보내기',
168
+ description: 'Send a support inquiry to DeepDynamic staff as the logged-in account.',
169
+ effect: 'write',
170
+ requiresLogin: true,
171
+ dryRun: 'server'
172
+ },
173
+ {
174
+ name: 'emails send',
175
+ usage: 'deepdynamic emails send --to <email> --title <text> (--body <text> | --body-file <path>) [--dry-run]',
176
+ prettyUsage: 'deepdynamic emails send --to <이메일> --title <제목> (--body <본문> | --body-file <경로>) [--dry-run]',
177
+ summary: '계정 이름으로 메일 보내기',
178
+ description: 'Send a plain-text email on behalf of the logged-in account.',
179
+ effect: 'write',
180
+ requiresLogin: true,
181
+ dryRun: 'server'
182
+ },
183
+ {
184
+ name: 'sms send',
185
+ usage: 'deepdynamic sms send --to <phone> (--body <text> | --body-file <path>) [--dry-run]',
186
+ prettyUsage: 'deepdynamic sms send --to <휴대폰 번호> (--body <본문> | --body-file <경로>) [--dry-run]',
187
+ summary: '문자 보내기',
188
+ description: 'Send a single SMS to a Korean mobile number as the logged-in account.',
189
+ effect: 'write',
190
+ requiresLogin: true,
191
+ dryRun: 'server'
192
+ },
193
+ {
194
+ name: 'projects',
195
+ usage: 'deepdynamic projects [--page <number>] [--dry-run]',
196
+ prettyUsage: 'deepdynamic projects [--page <번호>] [--dry-run]',
197
+ summary: '내 프로젝트 목록 보기',
198
+ description: 'List the projects of the logged-in account, most recently active first, with deploy status.',
199
+ effect: 'read',
200
+ requiresLogin: true,
201
+ dryRun: 'local'
202
+ },
203
+ {
204
+ name: 'projects create',
205
+ usage: 'deepdynamic projects create <name> [--timeout <seconds>] [--dry-run]',
206
+ prettyUsage: 'deepdynamic projects create <이름> [--timeout <초>] [--dry-run]',
207
+ summary: '프로젝트와 전용 서버 만들기',
208
+ description: 'Create a project and its dedicated server. Required once before the first deploy of that project name.',
209
+ effect: 'write',
210
+ requiresLogin: true,
211
+ dryRun: 'server'
212
+ },
213
+ {
214
+ name: 'projects status',
215
+ usage: 'deepdynamic projects status <name> [--dry-run]',
216
+ prettyUsage: 'deepdynamic projects status <이름> [--dry-run]',
217
+ summary: '프로젝트 서버 상태 보기',
218
+ description: 'Show whether the dedicated server of one of your projects is ready.',
219
+ effect: 'read',
220
+ requiresLogin: true,
221
+ dryRun: 'local'
222
+ },
223
+ {
224
+ name: 'projects metric',
225
+ usage: 'deepdynamic projects metric <name> [--period 24h|7d|30d] [--dry-run]',
226
+ prettyUsage: 'deepdynamic projects metric <이름> [--period 24h|7d|30d] [--dry-run]',
227
+ summary: '사이트 방문 통계 보기',
228
+ description: 'Show the visit statistics of one of your projects for the last 24 hours, 7 days or 30 days in Korea time.',
229
+ effect: 'read',
230
+ requiresLogin: true,
231
+ dryRun: 'local'
232
+ },
233
+ {
234
+ name: 'projects photocard',
235
+ usage: 'deepdynamic projects photocard <name> [--out <directory>] [--dry-run]',
236
+ prettyUsage: 'deepdynamic projects photocard <이름> [--out <폴더>] [--dry-run]',
237
+ summary: '포토카드 이미지 저장',
238
+ description: 'Render the photocard of one of your projects on the server and save its front and back as two PNG files.',
239
+ effect: 'read',
240
+ requiresLogin: true,
241
+ dryRun: 'local'
242
+ },
243
+ {
244
+ name: 'projects deploy',
245
+ usage: 'deepdynamic projects deploy <name> <directory> --agent <code> [--timeout <seconds>] [--dry-run]',
246
+ prettyUsage: 'deepdynamic projects deploy <이름> <폴더> --agent <코드> [--timeout <초>] [--dry-run]',
247
+ summary: '정적·동적 사이트 배포',
248
+ description: 'Upload a site to the project repository, then build and publish it on the project server.',
249
+ effect: 'write',
250
+ requiresLogin: true,
251
+ dryRun: 'local'
252
+ },
253
+ {
254
+ name: 'projects env push',
255
+ usage: 'deepdynamic projects env push <name> [<file>] [--dry-run]',
256
+ prettyUsage: 'deepdynamic projects env push <이름> [<파일>] [--dry-run]',
257
+ summary: '환경변수 봉인해 저장',
258
+ description: 'Seal a .env file with the server key and store it for a project. It applies from the next deploy.',
259
+ effect: 'write',
260
+ requiresLogin: true,
261
+ dryRun: 'local'
262
+ },
263
+ {
264
+ name: 'projects env list',
265
+ usage: 'deepdynamic projects env list <name> [--dry-run]',
266
+ prettyUsage: 'deepdynamic projects env list <이름> [--dry-run]',
267
+ summary: '저장한 환경변수 이름 보기',
268
+ description: 'List the names of the environment variables stored for a project. Values are never shown.',
269
+ effect: 'read',
270
+ requiresLogin: true,
271
+ dryRun: 'local'
272
+ },
273
+ {
274
+ name: 'projects env clear',
275
+ usage: 'deepdynamic projects env clear <name> --yes [--dry-run]',
276
+ prettyUsage: 'deepdynamic projects env clear <이름> --yes [--dry-run]',
277
+ summary: '환경변수 모두 지우기',
278
+ description: 'Remove every stored environment variable of a project. The next deploy builds and runs without them.',
279
+ effect: 'write',
280
+ requiresLogin: true,
281
+ dryRun: 'local',
282
+ confirm: 'required'
283
+ },
284
+ {
285
+ name: 'deployments',
286
+ usage: 'deepdynamic deployments <id> [--dry-run]',
287
+ prettyUsage: 'deepdynamic deployments <배포 ID> [--dry-run]',
288
+ summary: '배포 진행 상황 보기',
289
+ description: 'Read the progress of one deploy or rollback once and return right away. Each call also moves the deploy forward.',
290
+ effect: 'read',
291
+ requiresLogin: true,
292
+ dryRun: 'local'
293
+ },
294
+ {
295
+ name: 'projects history',
296
+ usage: 'deepdynamic projects history <name> [--dry-run]',
297
+ prettyUsage: 'deepdynamic projects history <이름> [--dry-run]',
298
+ summary: '게시된 배포 이력 보기',
299
+ description: 'List the published deployments of one of your projects, newest first. Use it to pick a rollback target.',
300
+ effect: 'read',
301
+ requiresLogin: true,
302
+ dryRun: 'local'
303
+ },
304
+ {
305
+ name: 'projects rollback',
306
+ usage: 'deepdynamic projects rollback <name> [--to <commit>] [--timeout <seconds>] --yes [--dry-run]',
307
+ prettyUsage: 'deepdynamic projects rollback <이름> [--to <커밋>] [--timeout <초>] --yes [--dry-run]',
308
+ summary: '이전 배포로 되돌리기',
309
+ description: 'Publish an earlier deployment of your project again; without --to, the one before the live deployment.',
310
+ effect: 'write',
311
+ requiresLogin: true,
312
+ dryRun: 'local',
313
+ confirm: 'required'
314
+ },
315
+ {
316
+ name: 'projects rename',
317
+ usage: 'deepdynamic projects rename <name> <new-name> [--dry-run]',
318
+ prettyUsage: 'deepdynamic projects rename <이름> <새 이름> [--dry-run]',
319
+ summary: '프로젝트 이름 바꾸기',
320
+ description: 'Rename one of your projects, for example from a generic name such as demo-site to one that fits the site source.',
321
+ effect: 'write',
322
+ requiresLogin: true,
323
+ dryRun: 'server'
324
+ },
325
+ {
326
+ name: 'projects pwa',
327
+ usage: 'deepdynamic projects pwa <name> [on|off] [--dry-run]',
328
+ prettyUsage: 'deepdynamic projects pwa <이름> [on|off] [--dry-run]',
329
+ summary: '앱 설치(PWA) 켜고 끄기',
330
+ description: 'Show or set whether the site is advertised as an installable PWA (web app manifest).',
331
+ effect: 'write',
332
+ requiresLogin: true,
333
+ dryRun: 'local'
334
+ },
335
+ {
336
+ name: 'projects stop',
337
+ usage: 'deepdynamic projects stop <name> --yes [--dry-run]',
338
+ prettyUsage: 'deepdynamic projects stop <이름> --yes [--dry-run]',
339
+ summary: '배포 중단하고 서버 끄기',
340
+ description: 'Stop serving one of your projects: cancel its running deploys and turn its project server off.',
341
+ effect: 'write',
342
+ requiresLogin: true,
343
+ dryRun: 'local',
344
+ confirm: 'required'
345
+ },
346
+ {
347
+ name: 'projects delete',
348
+ usage: 'deepdynamic projects delete <name> --yes [--dry-run]',
349
+ prettyUsage: 'deepdynamic projects delete <이름> --yes [--dry-run]',
350
+ summary: '프로젝트와 서버 삭제',
351
+ description: 'Delete one of your projects permanently together with its project server, Git repository and deploy history.',
352
+ effect: 'destructive',
353
+ requiresLogin: true,
354
+ dryRun: 'local',
355
+ confirm: 'required'
356
+ },
357
+ {
358
+ name: 'domains',
359
+ usage: 'deepdynamic domains [--page <number>] [--dry-run]',
360
+ prettyUsage: 'deepdynamic domains [--page <번호>] [--dry-run]',
361
+ summary: '보유 도메인 목록',
362
+ description: 'List the domains you bought or connected from elsewhere, with their project, connection status and expiry.',
363
+ effect: 'read',
364
+ requiresLogin: true,
365
+ dryRun: 'local'
366
+ },
367
+ {
368
+ name: 'domains search',
369
+ usage: 'deepdynamic domains search <name> [--tlds <tld,...>] [--dry-run]',
370
+ prettyUsage: 'deepdynamic domains search <이름> [--tlds <TLD,...>] [--dry-run]',
371
+ summary: '도메인 등록 가능 여부 검색',
372
+ description: 'Check whether a name can be registered, with KRW prices; without --tlds it checks the nine recommended TLDs.',
373
+ effect: 'read',
374
+ requiresLogin: false,
375
+ dryRun: 'local'
376
+ },
377
+ {
378
+ name: 'domains tlds',
379
+ usage: 'deepdynamic domains tlds [--dry-run]',
380
+ prettyUsage: 'deepdynamic domains tlds [--dry-run]',
381
+ summary: '지원 TLD 목록',
382
+ description: 'List the TLDs that can be bought, with list prices in KRW.',
383
+ effect: 'read',
384
+ requiresLogin: false,
385
+ dryRun: 'local'
386
+ },
387
+ {
388
+ name: 'domains buy',
389
+ usage: 'deepdynamic domains buy <domain> [--project <project>] [--years 1|2|3] [--no-auto-renew] [--yes --total <won>] [--dry-run]',
390
+ prettyUsage: 'deepdynamic domains buy <도메인> [--project <프로젝트>] [--years 1|2|3] [--no-auto-renew] [--yes --total <원>] [--dry-run]',
391
+ summary: '도메인 구입',
392
+ description: 'Buy a domain for one of your projects after the user agrees to the total in KRW.',
393
+ effect: 'billing',
394
+ requiresLogin: true,
395
+ dryRun: 'server',
396
+ confirm: 'required'
397
+ },
398
+ {
399
+ name: 'domains register',
400
+ usage: 'deepdynamic domains register <domain> [--project <project>] [--dns ns|cname] [--site <label|@>] [--dry-run]',
401
+ prettyUsage: 'deepdynamic domains register <도메인> [--project <프로젝트>] [--dns ns|cname] [--site <이름|@>] [--dry-run]',
402
+ summary: '다른 곳에서 산 도메인 등록',
403
+ description: 'Register a domain bought elsewhere for one of your projects and get the TXT record that proves ownership.',
404
+ effect: 'write',
405
+ requiresLogin: true,
406
+ dryRun: 'local'
407
+ },
408
+ {
409
+ name: 'domains verify',
410
+ usage: 'deepdynamic domains verify <domain> [--dry-run]',
411
+ prettyUsage: 'deepdynamic domains verify <도메인> [--dry-run]',
412
+ summary: '도메인 소유·연결 확인',
413
+ description: 'Check the ownership TXT record of a registered domain and connect it, or re-check its nameservers or CNAMEs.',
414
+ effect: 'write',
415
+ requiresLogin: true,
416
+ dryRun: 'local'
417
+ },
418
+ {
419
+ name: 'domains remove',
420
+ usage: 'deepdynamic domains remove <domain> --yes [--dry-run]',
421
+ prettyUsage: 'deepdynamic domains remove <도메인> --yes [--dry-run]',
422
+ summary: '다른 곳에서 산 도메인 연결 해제',
423
+ description: 'Disconnect a domain registered with deepdynamic domains register, deleting its DNS zone and HTTPS certificate.',
424
+ effect: 'write',
425
+ requiresLogin: true,
426
+ dryRun: 'local',
427
+ confirm: 'required'
428
+ },
429
+ {
430
+ name: 'domains auto-renew',
431
+ usage: 'deepdynamic domains auto-renew <domain> <on|off> [--yes] [--dry-run]',
432
+ prettyUsage: 'deepdynamic domains auto-renew <도메인> <on|off> [--yes] [--dry-run]',
433
+ summary: '도메인 자동 갱신 변경',
434
+ description: 'Turn auto-renew on or off for a domain bought with deepdynamic domains buy.',
435
+ effect: 'write',
436
+ requiresLogin: true,
437
+ dryRun: 'local',
438
+ confirm: 'conditional'
439
+ },
440
+ {
441
+ name: 'dns',
442
+ usage: 'deepdynamic dns [--page <number>] [--dry-run]',
443
+ prettyUsage: 'deepdynamic dns [--page <번호>] [--dry-run]',
444
+ summary: 'DNS 관리 도메인 목록',
445
+ description: 'List the domains whose DNS the account manages, with their records and DNS status.',
446
+ effect: 'read',
447
+ requiresLogin: true,
448
+ dryRun: 'local'
449
+ },
450
+ {
451
+ name: 'dns records',
452
+ usage: 'deepdynamic dns records <domain> [--dry-run]',
453
+ prettyUsage: 'deepdynamic dns records <도메인> [--dry-run]',
454
+ summary: 'DNS 레코드 목록',
455
+ description: 'Show the DNS records of one managed domain.',
456
+ effect: 'read',
457
+ requiresLogin: true,
458
+ dryRun: 'local'
459
+ },
460
+ {
461
+ name: 'dns add',
462
+ usage: 'deepdynamic dns add <domain> --type <type> --name <name> --value <value> [--ttl auto|300|3600|86400] [--priority <0-65535>] [--dry-run]',
463
+ prettyUsage: 'deepdynamic dns add <도메인> --type <종류> --name <이름> --value <값> [--ttl auto|300|3600|86400] [--priority <0-65535>] [--dry-run]',
464
+ summary: 'DNS 레코드 추가',
465
+ description: 'Add a DNS record to a managed domain.',
466
+ effect: 'write',
467
+ requiresLogin: true,
468
+ dryRun: 'local'
469
+ },
470
+ {
471
+ name: 'dns update',
472
+ usage: 'deepdynamic dns update <domain> <record-id> --type <type> --name <name> --value <value> [--ttl auto|300|3600|86400] [--priority <0-65535>] [--dry-run]',
473
+ prettyUsage: 'deepdynamic dns update <도메인> <레코드 ID> --type <종류> --name <이름> --value <값> [--ttl auto|300|3600|86400] [--priority <0-65535>] [--dry-run]',
474
+ summary: 'DNS 레코드 수정',
475
+ description: 'Replace an existing DNS record of a managed domain.',
476
+ effect: 'write',
477
+ requiresLogin: true,
478
+ dryRun: 'local'
479
+ },
480
+ {
481
+ name: 'dns delete',
482
+ usage: 'deepdynamic dns delete <domain> <record-id> --yes [--dry-run]',
483
+ prettyUsage: 'deepdynamic dns delete <도메인> <레코드 ID> --yes [--dry-run]',
484
+ summary: 'DNS 레코드 삭제',
485
+ description: 'Delete a DNS record of a managed domain.',
486
+ effect: 'destructive',
487
+ requiresLogin: true,
488
+ dryRun: 'local',
489
+ confirm: 'required'
490
+ },
491
+ {
492
+ name: 'dns restore',
493
+ usage: 'deepdynamic dns restore <domain> --project <name> [--name <host>] --yes [--dry-run]',
494
+ prettyUsage: 'deepdynamic dns restore <도메인> --project <프로젝트> [--name <호스트, 기본 www>] --yes [--dry-run]',
495
+ summary: '사이트 연결 CNAME 복구',
496
+ description: 'Recreate the CNAME that connects a domain host to a project site.',
497
+ effect: 'write',
498
+ requiresLogin: true,
499
+ dryRun: 'local',
500
+ confirm: 'required'
501
+ },
502
+ {
503
+ name: 'dns sync',
504
+ usage: 'deepdynamic dns sync <domain> --yes [--dry-run]',
505
+ prettyUsage: 'deepdynamic dns sync <도메인> --yes [--dry-run]',
506
+ summary: 'DNS 서버 동기화',
507
+ description: 'Apply the saved DNS records of a managed domain to its DNS servers right now.',
508
+ effect: 'destructive',
509
+ requiresLogin: true,
510
+ dryRun: 'local',
511
+ confirm: 'required'
512
+ },
513
+ {
514
+ name: 'dns dnssec',
515
+ usage: 'deepdynamic dns dnssec <domain> <on|off> --yes [--dry-run]',
516
+ prettyUsage: 'deepdynamic dns dnssec <도메인> <on|off> --yes [--dry-run]',
517
+ summary: 'DNSSEC 켜기·끄기',
518
+ description: 'Turn DNSSEC on or off for a domain bought through DeepDynamic: zone signing and the DS record at the registrar.',
519
+ effect: 'write',
520
+ requiresLogin: true,
521
+ dryRun: 'local',
522
+ confirm: 'required'
523
+ },
524
+ {
525
+ name: 'dns google',
526
+ usage: 'deepdynamic dns google <domain> [--dry-run]',
527
+ prettyUsage: 'deepdynamic dns google <도메인> [--dry-run]',
528
+ summary: 'Google Search Console 등록 주소 발급',
529
+ description: 'Get a Google consent URL that verifies a managed domain and adds it to Google Search Console.',
530
+ effect: 'write',
531
+ requiresLogin: true,
532
+ dryRun: 'local'
533
+ },
534
+ {
535
+ name: 'dns analytics',
536
+ usage: 'deepdynamic dns analytics <domain> [off] [--yes] [--dry-run]',
537
+ prettyUsage: 'deepdynamic dns analytics <도메인> [off] [--yes] [--dry-run]',
538
+ summary: 'Google Analytics(GA4) 등록 주소 발급·해제',
539
+ description: 'Get a Google consent URL that creates a GA4 property and adds its tag to the site, or remove the tag with off.',
540
+ effect: 'write',
541
+ requiresLogin: true,
542
+ dryRun: 'local',
543
+ confirm: 'conditional'
544
+ },
545
+ {
546
+ name: 'server',
547
+ usage: 'deepdynamic server [--dry-run]',
548
+ prettyUsage: 'deepdynamic server [--dry-run]',
549
+ summary: '서버 사양 목록',
550
+ description: 'List the CPU, RAM, usage and monthly extra charge of each project server and the autopilot state.',
551
+ effect: 'read',
552
+ requiresLogin: true,
553
+ dryRun: 'local'
554
+ },
555
+ {
556
+ name: 'server set',
557
+ usage: 'deepdynamic server set <project> [--cores 1|2|4|8] [--memory 1|2|4|8] [--yes] [--dry-run]',
558
+ prettyUsage: 'deepdynamic server set <프로젝트> [--cores 1|2|4|8] [--memory 1|2|4|8] [--yes] [--dry-run]',
559
+ summary: 'CPU·RAM 변경',
560
+ description: 'Change the CPU cores and RAM of one project server, which restarts it briefly.',
561
+ effect: 'billing',
562
+ requiresLogin: true,
563
+ dryRun: 'local',
564
+ confirm: 'conditional'
565
+ },
566
+ {
567
+ name: 'server autopilot',
568
+ usage: 'deepdynamic server autopilot <on|off> [--limit 50000|100000|200000|300000] [--dry-run]',
569
+ prettyUsage: 'deepdynamic server autopilot <on|off> [--limit 50000|100000|200000|300000] [--dry-run]',
570
+ summary: '오토파일럿 켜기·끄기',
571
+ description: 'Turn autopilot on or off. It scales CPU and RAM of every project server within a monthly limit.',
572
+ effect: 'billing',
573
+ requiresLogin: true,
574
+ dryRun: 'local'
575
+ },
576
+ {
577
+ name: 'plan',
578
+ usage: 'deepdynamic plan [--dry-run]',
579
+ prettyUsage: 'deepdynamic plan [--dry-run]',
580
+ summary: '요금제·구독·결제 카드 보기',
581
+ description: 'Show the current plan (free, pro or team), the paid subscription, the billing card and recent charges.',
582
+ effect: 'read',
583
+ requiresLogin: true,
584
+ dryRun: 'local'
585
+ },
586
+ {
587
+ name: 'plan subscribe',
588
+ usage: 'deepdynamic plan subscribe <pro|team> [--yes] [--dry-run]',
589
+ prettyUsage: 'deepdynamic plan subscribe <pro|team> [--yes] [--dry-run]',
590
+ summary: '유료 요금제 구독·변경',
591
+ description: 'Subscribe to the pro or team plan or switch between them. Subscribing and upgrading charge the card at once.',
592
+ effect: 'billing',
593
+ requiresLogin: true,
594
+ dryRun: 'local',
595
+ confirm: 'conditional'
596
+ },
597
+ {
598
+ name: 'plan cancel',
599
+ usage: 'deepdynamic plan cancel --yes [--dry-run]',
600
+ prettyUsage: 'deepdynamic plan cancel --yes [--dry-run]',
601
+ summary: '유료 요금제 해지',
602
+ description: "Cancel the paid plan. It stays until the end of this month (KST), or ends now if this month's charge is unpaid.",
603
+ effect: 'write',
604
+ requiresLogin: true,
605
+ dryRun: 'local',
606
+ confirm: 'required'
607
+ },
608
+ {
609
+ name: 'plan resume',
610
+ usage: 'deepdynamic plan resume [--dry-run]',
611
+ prettyUsage: 'deepdynamic plan resume [--dry-run]',
612
+ summary: '해지 예약 취소',
613
+ description: 'Undo a scheduled cancellation so the paid plan keeps renewing every month.',
614
+ effect: 'billing',
615
+ requiresLogin: true,
616
+ dryRun: 'local'
617
+ },
618
+ {
619
+ name: 'plan pay',
620
+ usage: 'deepdynamic plan pay --yes [--dry-run]',
621
+ prettyUsage: 'deepdynamic plan pay --yes [--dry-run]',
622
+ summary: '미결제 요금 결제',
623
+ description: 'Pay the monthly charges that failed and are still unpaid, oldest first, with the billing card.',
624
+ effect: 'billing',
625
+ requiresLogin: true,
626
+ dryRun: 'local',
627
+ confirm: 'required'
628
+ },
629
+ {
630
+ name: 'usage',
631
+ usage: 'deepdynamic usage [--dry-run]',
632
+ prettyUsage: 'deepdynamic usage [--dry-run]',
633
+ summary: '이번 달 SMS·이메일 발송 사용량 보기',
634
+ description: 'Show SMS and emails sent this month (KST) against the plan limit, with remaining and daily counts.',
635
+ effect: 'read',
636
+ requiresLogin: true,
637
+ dryRun: 'local'
638
+ },
639
+ {
640
+ name: 'keys',
641
+ usage: 'deepdynamic keys [--page <number>] [--dry-run]',
642
+ prettyUsage: 'deepdynamic keys [--page <번호>] [--dry-run]',
643
+ summary: '발급한 API 키 목록',
644
+ description: 'List the service API keys you have issued (DNS, S3, Pay and custom keys) with their prefix, scopes and expiry.',
645
+ effect: 'read',
646
+ requiresLogin: true,
647
+ dryRun: 'local'
648
+ },
649
+ {
650
+ name: 'keys issue',
651
+ usage: 'deepdynamic keys issue <dns|s3|pay> [--expires 10m|1h|6h|1d] [--yes] [--dry-run]',
652
+ prettyUsage: 'deepdynamic keys issue <dns|s3|pay> [--expires 10m|1h|6h|1d] [--yes] [--dry-run]',
653
+ summary: '서비스별 API 키 발급',
654
+ description: 'Issue a DNS Control, S3 Control or temporary Pay Control API key and print its value once.',
655
+ effect: 'billing',
656
+ requiresLogin: true,
657
+ dryRun: 'local',
658
+ confirm: 'conditional'
659
+ },
660
+ {
661
+ name: 'keys create',
662
+ usage: 'deepdynamic keys create --label <label> --scope <scope> [--scope <scope>]... [--dry-run]',
663
+ prettyUsage: 'deepdynamic keys create --label <이름> --scope <권한> [--scope <권한>]... [--dry-run]',
664
+ summary: '권한 지정 API 키 생성',
665
+ description: 'Create a custom API key with only the scopes you choose and print its value once.',
666
+ effect: 'write',
667
+ requiresLogin: true,
668
+ dryRun: 'local'
669
+ },
670
+ {
671
+ name: 'keys revoke',
672
+ usage: 'deepdynamic keys revoke <key-id> --yes [--dry-run]',
673
+ prettyUsage: 'deepdynamic keys revoke <키 ID> --yes [--dry-run]',
674
+ summary: 'API 키 취소',
675
+ description: 'Revoke one of your API keys so tools using it are blocked at once.',
676
+ effect: 'destructive',
677
+ requiresLogin: true,
678
+ dryRun: 'local',
679
+ confirm: 'required'
680
+ },
681
+ {
682
+ name: 'sessions',
683
+ usage: 'deepdynamic sessions [--dry-run]',
684
+ prettyUsage: 'deepdynamic sessions [--dry-run]',
685
+ summary: '로그인 세션 목록',
686
+ description: "List the account's active sign-ins: browser sessions and CLI login tokens with IP, last activity and the current one.",
687
+ effect: 'read',
688
+ requiresLogin: true,
689
+ dryRun: 'local'
690
+ },
691
+ {
692
+ name: 'sessions revoke',
693
+ usage: 'deepdynamic sessions revoke <session-id> --yes [--dry-run]',
694
+ prettyUsage: 'deepdynamic sessions revoke <세션 ID> --yes [--dry-run]',
695
+ summary: '로그인 세션 회수',
696
+ description: 'Sign out one browser session or deepdynamic login token of the account. The one this CLI is using cannot be revoked.',
697
+ effect: 'destructive',
698
+ requiresLogin: true,
699
+ dryRun: 'local',
700
+ confirm: 'required'
701
+ },
702
+ {
703
+ name: 'mail',
704
+ usage: 'deepdynamic mail [--page <number>] [--dry-run]',
705
+ prettyUsage: 'deepdynamic mail [--page <번호>] [--dry-run]',
706
+ summary: '메일 설정 도메인 목록',
707
+ description: 'List your managed domains with their mail authentication settings (SPF, DKIM, DMARC) read from their DNS records.',
708
+ effect: 'read',
709
+ requiresLogin: true,
710
+ dryRun: 'local'
711
+ },
712
+ {
713
+ name: 'mail show',
714
+ usage: 'deepdynamic mail show <domain> [--dry-run]',
715
+ prettyUsage: 'deepdynamic mail show <도메인> [--dry-run]',
716
+ summary: '도메인 메일 설정 보기',
717
+ description: 'Show the SPF, DKIM and DMARC settings of one managed domain, read from its DNS records.',
718
+ effect: 'read',
719
+ requiresLogin: true,
720
+ dryRun: 'local'
721
+ },
722
+ {
723
+ name: 'mail set',
724
+ usage: 'deepdynamic mail set <domain> [--policy none|quarantine|reject] [--rua <email>] [--spf-include <host>] [--selector <selector> --public-key <base64>] --yes [--dry-run]',
725
+ prettyUsage: 'deepdynamic mail set <도메인> [--policy none|quarantine|reject] [--rua <이메일>] [--spf-include <호스트>] [--selector <선택자> --public-key <공개 키>] --yes [--dry-run]',
726
+ summary: '메일 인증 설정 변경',
727
+ description: 'Set up or change the DMARC policy, report address, SPF sender or DKIM key of a domain by writing its TXT records.',
728
+ effect: 'write',
729
+ requiresLogin: true,
730
+ dryRun: 'local',
731
+ confirm: 'required'
732
+ },
733
+ {
734
+ name: 'mail reset',
735
+ usage: 'deepdynamic mail reset <domain> --yes [--dry-run]',
736
+ prettyUsage: 'deepdynamic mail reset <도메인> --yes [--dry-run]',
737
+ summary: '메일 자동 설정 되돌리기',
738
+ description: 'Return the mail settings of a domain to the automatic setup, or set a fresh domain up with it.',
739
+ effect: 'destructive',
740
+ requiresLogin: true,
741
+ dryRun: 'local',
742
+ confirm: 'required'
743
+ }
744
+ ];
745
+ export function spec(name) {
746
+ return commands.find((entry) => entry.name === name);
747
+ }
748
+ export function requiredUsage(usage) {
749
+ let depth = 0;
750
+ let kept = '';
751
+ for (const char of usage) {
752
+ if (char === '[')
753
+ depth++;
754
+ else if (char === ']')
755
+ depth--;
756
+ else if (depth === 0)
757
+ kept += char;
758
+ }
759
+ return kept.replace(/\s*\.\.\.(?=\s|$)/g, '').replace(/\s+/g, ' ').trim();
760
+ }