@super-protocol/sp-cli 0.0.2 → 0.0.4-beta.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/README.md +217 -263
- package/bin/dev.js +1 -1
- package/dist/commands/account/get-sppi.d.ts +8 -0
- package/dist/commands/account/get-sppi.js +23 -0
- package/dist/commands/account/info.d.ts +22 -0
- package/dist/commands/account/info.js +46 -0
- package/dist/commands/auth/login.d.ts +6 -11
- package/dist/commands/auth/login.js +28 -76
- package/dist/commands/base.d.ts +2 -4
- package/dist/commands/base.js +8 -10
- package/dist/commands/config/add.js +1 -12
- package/dist/commands/config/base.d.ts +5 -3
- package/dist/commands/config/base.js +30 -14
- package/dist/commands/config/create.js +1 -11
- package/dist/commands/config/list.js +20 -19
- package/dist/commands/config/use.js +5 -3
- package/dist/commands/files/download.d.ts +15 -0
- package/dist/commands/files/download.js +55 -0
- package/dist/commands/files/upload.d.ts +18 -0
- package/dist/commands/files/upload.js +79 -0
- package/dist/commands/storage/base.d.ts +13 -0
- package/dist/commands/storage/base.js +125 -0
- package/dist/commands/storage/create.d.ts +11 -0
- package/dist/commands/storage/create.js +53 -0
- package/dist/commands/storage/select.d.ts +9 -0
- package/dist/commands/storage/select.js +40 -0
- package/dist/commands/storage/show.d.ts +17 -0
- package/dist/commands/storage/show.js +36 -0
- package/dist/commands/storage/update.d.ts +14 -0
- package/dist/commands/storage/update.js +187 -0
- package/dist/commands/workflows/extend-lease.d.ts +17 -0
- package/dist/commands/workflows/extend-lease.js +94 -0
- package/dist/config/config-file.schema.d.ts +4 -4
- package/dist/config/config-file.schema.js +1 -1
- package/dist/config/config.schema.d.ts +25 -15
- package/dist/config/config.schema.js +7 -10
- package/dist/constants.d.ts +5 -0
- package/dist/constants.js +5 -0
- package/dist/errors.d.ts +2 -0
- package/dist/errors.js +2 -0
- package/dist/hooks/finally/shutdown-blockchain.d.ts +3 -0
- package/dist/hooks/finally/shutdown-blockchain.js +8 -0
- package/dist/lib/container.d.ts +7 -7
- package/dist/lib/container.js +48 -26
- package/dist/managers/account-manager.d.ts +4 -1
- package/dist/managers/account-manager.js +29 -30
- package/dist/managers/config-file-manager.d.ts +2 -2
- package/dist/managers/config-file-manager.js +29 -12
- package/dist/middlewares/auth-middleware.js +5 -1
- package/dist/services/auth.service.d.ts +24 -0
- package/dist/services/auth.service.js +93 -0
- package/dist/services/storage.service.d.ts +73 -0
- package/dist/services/storage.service.js +351 -0
- package/dist/utils/helper.d.ts +6 -0
- package/dist/utils/helper.js +23 -0
- package/dist/utils/progress.d.ts +8 -0
- package/dist/utils/progress.js +35 -0
- package/oclif.manifest.json +432 -156
- package/package.json +19 -9
package/oclif.manifest.json
CHANGED
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"commands": {
|
|
3
|
-
"
|
|
3
|
+
"account:get-sppi": {
|
|
4
4
|
"aliases": [],
|
|
5
5
|
"args": {},
|
|
6
|
+
"description": "Get SPPI (Super Protocol incentive tokens) ",
|
|
7
|
+
"examples": [
|
|
8
|
+
"<%= config.bin %> <%= command.id %>"
|
|
9
|
+
],
|
|
6
10
|
"flags": {
|
|
7
11
|
"json": {
|
|
8
12
|
"description": "Format output as json.",
|
|
@@ -19,12 +23,41 @@
|
|
|
19
23
|
"hasDynamicHelp": false,
|
|
20
24
|
"multiple": false,
|
|
21
25
|
"type": "option"
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"hasDynamicHelp": false,
|
|
29
|
+
"hiddenAliases": [],
|
|
30
|
+
"id": "account:get-sppi",
|
|
31
|
+
"pluginAlias": "@super-protocol/sp-cli",
|
|
32
|
+
"pluginName": "@super-protocol/sp-cli",
|
|
33
|
+
"pluginType": "core",
|
|
34
|
+
"strict": true,
|
|
35
|
+
"enableJsonFlag": true,
|
|
36
|
+
"isESM": true,
|
|
37
|
+
"relativePath": [
|
|
38
|
+
"dist",
|
|
39
|
+
"commands",
|
|
40
|
+
"account",
|
|
41
|
+
"get-sppi.js"
|
|
42
|
+
]
|
|
43
|
+
},
|
|
44
|
+
"account:info": {
|
|
45
|
+
"aliases": [],
|
|
46
|
+
"args": {},
|
|
47
|
+
"description": "Information about current authorized user",
|
|
48
|
+
"flags": {
|
|
49
|
+
"json": {
|
|
50
|
+
"description": "Format output as json.",
|
|
51
|
+
"helpGroup": "GLOBAL",
|
|
52
|
+
"name": "json",
|
|
53
|
+
"allowNo": false,
|
|
54
|
+
"type": "boolean"
|
|
22
55
|
},
|
|
23
|
-
"
|
|
56
|
+
"config": {
|
|
24
57
|
"helpGroup": "GLOBAL",
|
|
25
|
-
"name": "
|
|
58
|
+
"name": "config",
|
|
26
59
|
"required": false,
|
|
27
|
-
"summary": "Specify
|
|
60
|
+
"summary": "Specify config file.",
|
|
28
61
|
"hasDynamicHelp": false,
|
|
29
62
|
"multiple": false,
|
|
30
63
|
"type": "option"
|
|
@@ -32,7 +65,7 @@
|
|
|
32
65
|
},
|
|
33
66
|
"hasDynamicHelp": false,
|
|
34
67
|
"hiddenAliases": [],
|
|
35
|
-
"id": "
|
|
68
|
+
"id": "account:info",
|
|
36
69
|
"pluginAlias": "@super-protocol/sp-cli",
|
|
37
70
|
"pluginName": "@super-protocol/sp-cli",
|
|
38
71
|
"pluginType": "core",
|
|
@@ -42,13 +75,16 @@
|
|
|
42
75
|
"relativePath": [
|
|
43
76
|
"dist",
|
|
44
77
|
"commands",
|
|
45
|
-
"
|
|
78
|
+
"account",
|
|
79
|
+
"info.js"
|
|
46
80
|
]
|
|
47
81
|
},
|
|
48
82
|
"auth:login": {
|
|
49
|
-
"aliases": [
|
|
83
|
+
"aliases": [
|
|
84
|
+
"login"
|
|
85
|
+
],
|
|
50
86
|
"args": {},
|
|
51
|
-
"description": "
|
|
87
|
+
"description": "Login to SuperProtocol (sign up or sign in).",
|
|
52
88
|
"examples": [
|
|
53
89
|
"<%= config.bin %> <%= command.id %>\n"
|
|
54
90
|
],
|
|
@@ -68,15 +104,6 @@
|
|
|
68
104
|
"hasDynamicHelp": false,
|
|
69
105
|
"multiple": false,
|
|
70
106
|
"type": "option"
|
|
71
|
-
},
|
|
72
|
-
"url": {
|
|
73
|
-
"helpGroup": "GLOBAL",
|
|
74
|
-
"name": "url",
|
|
75
|
-
"required": false,
|
|
76
|
-
"summary": "Specify provider base URL.",
|
|
77
|
-
"hasDynamicHelp": false,
|
|
78
|
-
"multiple": false,
|
|
79
|
-
"type": "option"
|
|
80
107
|
}
|
|
81
108
|
},
|
|
82
109
|
"hasDynamicHelp": false,
|
|
@@ -114,15 +141,6 @@
|
|
|
114
141
|
"hasDynamicHelp": false,
|
|
115
142
|
"multiple": false,
|
|
116
143
|
"type": "option"
|
|
117
|
-
},
|
|
118
|
-
"url": {
|
|
119
|
-
"helpGroup": "GLOBAL",
|
|
120
|
-
"name": "url",
|
|
121
|
-
"required": false,
|
|
122
|
-
"summary": "Specify provider base URL.",
|
|
123
|
-
"hasDynamicHelp": false,
|
|
124
|
-
"multiple": false,
|
|
125
|
-
"type": "option"
|
|
126
144
|
}
|
|
127
145
|
},
|
|
128
146
|
"hasDynamicHelp": false,
|
|
@@ -164,24 +182,6 @@
|
|
|
164
182
|
"allowNo": false,
|
|
165
183
|
"type": "boolean"
|
|
166
184
|
},
|
|
167
|
-
"config": {
|
|
168
|
-
"helpGroup": "GLOBAL",
|
|
169
|
-
"name": "config",
|
|
170
|
-
"required": false,
|
|
171
|
-
"summary": "Specify config file.",
|
|
172
|
-
"hasDynamicHelp": false,
|
|
173
|
-
"multiple": false,
|
|
174
|
-
"type": "option"
|
|
175
|
-
},
|
|
176
|
-
"url": {
|
|
177
|
-
"helpGroup": "GLOBAL",
|
|
178
|
-
"name": "url",
|
|
179
|
-
"required": false,
|
|
180
|
-
"summary": "Specify provider base URL.",
|
|
181
|
-
"hasDynamicHelp": false,
|
|
182
|
-
"multiple": false,
|
|
183
|
-
"type": "option"
|
|
184
|
-
},
|
|
185
185
|
"name": {
|
|
186
186
|
"char": "n",
|
|
187
187
|
"description": "Custom name for the imported configuration",
|
|
@@ -214,9 +214,14 @@
|
|
|
214
214
|
"add.js"
|
|
215
215
|
]
|
|
216
216
|
},
|
|
217
|
-
"config:
|
|
217
|
+
"config:create": {
|
|
218
218
|
"aliases": [],
|
|
219
219
|
"args": {},
|
|
220
|
+
"description": "Create a new configuration",
|
|
221
|
+
"examples": [
|
|
222
|
+
"<%= config.bin %> <%= command.id %> --name \"My Config\"",
|
|
223
|
+
"<%= config.bin %> <%= command.id %> --name \"Production\" --url \"https://api.dp.superprotocol.com\""
|
|
224
|
+
],
|
|
220
225
|
"flags": {
|
|
221
226
|
"json": {
|
|
222
227
|
"description": "Format output as json.",
|
|
@@ -225,28 +230,34 @@
|
|
|
225
230
|
"allowNo": false,
|
|
226
231
|
"type": "boolean"
|
|
227
232
|
},
|
|
228
|
-
"
|
|
229
|
-
"
|
|
230
|
-
"
|
|
231
|
-
"
|
|
232
|
-
"
|
|
233
|
+
"name": {
|
|
234
|
+
"char": "n",
|
|
235
|
+
"description": "Configuration name",
|
|
236
|
+
"name": "name",
|
|
237
|
+
"required": true,
|
|
233
238
|
"hasDynamicHelp": false,
|
|
234
239
|
"multiple": false,
|
|
235
240
|
"type": "option"
|
|
236
241
|
},
|
|
237
242
|
"url": {
|
|
238
|
-
"
|
|
243
|
+
"char": "u",
|
|
244
|
+
"description": "Provider base URL",
|
|
239
245
|
"name": "url",
|
|
240
|
-
"required": false,
|
|
241
|
-
"summary": "Specify provider base URL.",
|
|
242
246
|
"hasDynamicHelp": false,
|
|
243
247
|
"multiple": false,
|
|
244
248
|
"type": "option"
|
|
249
|
+
},
|
|
250
|
+
"yes": {
|
|
251
|
+
"char": "y",
|
|
252
|
+
"description": "Switch to new config",
|
|
253
|
+
"name": "yes",
|
|
254
|
+
"allowNo": false,
|
|
255
|
+
"type": "boolean"
|
|
245
256
|
}
|
|
246
257
|
},
|
|
247
258
|
"hasDynamicHelp": false,
|
|
248
259
|
"hiddenAliases": [],
|
|
249
|
-
"id": "config:
|
|
260
|
+
"id": "config:create",
|
|
250
261
|
"pluginAlias": "@super-protocol/sp-cli",
|
|
251
262
|
"pluginName": "@super-protocol/sp-cli",
|
|
252
263
|
"pluginType": "core",
|
|
@@ -257,16 +268,17 @@
|
|
|
257
268
|
"dist",
|
|
258
269
|
"commands",
|
|
259
270
|
"config",
|
|
260
|
-
"
|
|
271
|
+
"create.js"
|
|
261
272
|
]
|
|
262
273
|
},
|
|
263
|
-
"config:
|
|
274
|
+
"config:delete": {
|
|
264
275
|
"aliases": [],
|
|
265
276
|
"args": {},
|
|
266
|
-
"description": "
|
|
277
|
+
"description": "Delete a configuration file",
|
|
267
278
|
"examples": [
|
|
279
|
+
"<%= config.bin %> <%= command.id %>",
|
|
268
280
|
"<%= config.bin %> <%= command.id %> --name \"My Config\"",
|
|
269
|
-
"<%= config.bin %> <%= command.id %> --name \"
|
|
281
|
+
"<%= config.bin %> <%= command.id %> --name \"My Config\" --force"
|
|
270
282
|
],
|
|
271
283
|
"flags": {
|
|
272
284
|
"json": {
|
|
@@ -276,43 +288,62 @@
|
|
|
276
288
|
"allowNo": false,
|
|
277
289
|
"type": "boolean"
|
|
278
290
|
},
|
|
279
|
-
"
|
|
280
|
-
"
|
|
281
|
-
"
|
|
282
|
-
"
|
|
283
|
-
"
|
|
284
|
-
"
|
|
285
|
-
"multiple": false,
|
|
286
|
-
"type": "option"
|
|
287
|
-
},
|
|
288
|
-
"url": {
|
|
289
|
-
"char": "u",
|
|
290
|
-
"description": "Provider base URL",
|
|
291
|
-
"name": "url",
|
|
292
|
-
"hasDynamicHelp": false,
|
|
293
|
-
"multiple": false,
|
|
294
|
-
"type": "option"
|
|
291
|
+
"force": {
|
|
292
|
+
"char": "f",
|
|
293
|
+
"description": "Force deletion without confirmation",
|
|
294
|
+
"name": "force",
|
|
295
|
+
"allowNo": false,
|
|
296
|
+
"type": "boolean"
|
|
295
297
|
},
|
|
296
298
|
"name": {
|
|
297
299
|
"char": "n",
|
|
298
|
-
"description": "Configuration name",
|
|
300
|
+
"description": "Configuration name to delete",
|
|
299
301
|
"name": "name",
|
|
300
|
-
"required": true,
|
|
301
302
|
"hasDynamicHelp": false,
|
|
302
303
|
"multiple": false,
|
|
303
304
|
"type": "option"
|
|
304
|
-
}
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
305
|
+
}
|
|
306
|
+
},
|
|
307
|
+
"hasDynamicHelp": false,
|
|
308
|
+
"hiddenAliases": [],
|
|
309
|
+
"id": "config:delete",
|
|
310
|
+
"pluginAlias": "@super-protocol/sp-cli",
|
|
311
|
+
"pluginName": "@super-protocol/sp-cli",
|
|
312
|
+
"pluginType": "core",
|
|
313
|
+
"strict": true,
|
|
314
|
+
"enableJsonFlag": true,
|
|
315
|
+
"isESM": true,
|
|
316
|
+
"relativePath": [
|
|
317
|
+
"dist",
|
|
318
|
+
"commands",
|
|
319
|
+
"config",
|
|
320
|
+
"delete.js"
|
|
321
|
+
]
|
|
322
|
+
},
|
|
323
|
+
"config": {
|
|
324
|
+
"aliases": [],
|
|
325
|
+
"args": {},
|
|
326
|
+
"description": "Manage configuration configs",
|
|
327
|
+
"examples": [
|
|
328
|
+
"<%= config.bin %> <%= command.id %> show - Show current configuration details",
|
|
329
|
+
"<%= config.bin %> <%= command.id %> list - List all configurations",
|
|
330
|
+
"<%= config.bin %> <%= command.id %> use - Switch to a configuration",
|
|
331
|
+
"<%= config.bin %> <%= command.id %> create --name \"My Config\" - Create new configuration",
|
|
332
|
+
"<%= config.bin %> <%= command.id %> add ./config.json - Import configuration from file",
|
|
333
|
+
"<%= config.bin %> <%= command.id %> delete - Delete a configuration"
|
|
334
|
+
],
|
|
335
|
+
"flags": {
|
|
336
|
+
"json": {
|
|
337
|
+
"description": "Format output as json.",
|
|
338
|
+
"helpGroup": "GLOBAL",
|
|
339
|
+
"name": "json",
|
|
309
340
|
"allowNo": false,
|
|
310
341
|
"type": "boolean"
|
|
311
342
|
}
|
|
312
343
|
},
|
|
313
344
|
"hasDynamicHelp": false,
|
|
314
345
|
"hiddenAliases": [],
|
|
315
|
-
"id": "config
|
|
346
|
+
"id": "config",
|
|
316
347
|
"pluginAlias": "@super-protocol/sp-cli",
|
|
317
348
|
"pluginName": "@super-protocol/sp-cli",
|
|
318
349
|
"pluginType": "core",
|
|
@@ -323,17 +354,122 @@
|
|
|
323
354
|
"dist",
|
|
324
355
|
"commands",
|
|
325
356
|
"config",
|
|
326
|
-
"
|
|
357
|
+
"index.js"
|
|
327
358
|
]
|
|
328
359
|
},
|
|
329
|
-
"config:
|
|
360
|
+
"config:list": {
|
|
330
361
|
"aliases": [],
|
|
331
362
|
"args": {},
|
|
332
|
-
"description": "
|
|
363
|
+
"description": "List all configurations",
|
|
333
364
|
"examples": [
|
|
334
|
-
"<%= config.bin %> <%= command.id %>"
|
|
335
|
-
|
|
336
|
-
|
|
365
|
+
"<%= config.bin %> <%= command.id %>"
|
|
366
|
+
],
|
|
367
|
+
"flags": {
|
|
368
|
+
"json": {
|
|
369
|
+
"description": "Format output as json.",
|
|
370
|
+
"helpGroup": "GLOBAL",
|
|
371
|
+
"name": "json",
|
|
372
|
+
"allowNo": false,
|
|
373
|
+
"type": "boolean"
|
|
374
|
+
}
|
|
375
|
+
},
|
|
376
|
+
"hasDynamicHelp": false,
|
|
377
|
+
"hiddenAliases": [],
|
|
378
|
+
"id": "config:list",
|
|
379
|
+
"pluginAlias": "@super-protocol/sp-cli",
|
|
380
|
+
"pluginName": "@super-protocol/sp-cli",
|
|
381
|
+
"pluginType": "core",
|
|
382
|
+
"strict": true,
|
|
383
|
+
"enableJsonFlag": true,
|
|
384
|
+
"isESM": true,
|
|
385
|
+
"relativePath": [
|
|
386
|
+
"dist",
|
|
387
|
+
"commands",
|
|
388
|
+
"config",
|
|
389
|
+
"list.js"
|
|
390
|
+
]
|
|
391
|
+
},
|
|
392
|
+
"config:show": {
|
|
393
|
+
"aliases": [],
|
|
394
|
+
"args": {},
|
|
395
|
+
"description": "Show current configuration",
|
|
396
|
+
"examples": [
|
|
397
|
+
"<%= config.bin %> <%= command.id %>"
|
|
398
|
+
],
|
|
399
|
+
"flags": {
|
|
400
|
+
"json": {
|
|
401
|
+
"description": "Format output as json.",
|
|
402
|
+
"helpGroup": "GLOBAL",
|
|
403
|
+
"name": "json",
|
|
404
|
+
"allowNo": false,
|
|
405
|
+
"type": "boolean"
|
|
406
|
+
}
|
|
407
|
+
},
|
|
408
|
+
"hasDynamicHelp": false,
|
|
409
|
+
"hiddenAliases": [],
|
|
410
|
+
"id": "config:show",
|
|
411
|
+
"pluginAlias": "@super-protocol/sp-cli",
|
|
412
|
+
"pluginName": "@super-protocol/sp-cli",
|
|
413
|
+
"pluginType": "core",
|
|
414
|
+
"strict": true,
|
|
415
|
+
"enableJsonFlag": true,
|
|
416
|
+
"isESM": true,
|
|
417
|
+
"relativePath": [
|
|
418
|
+
"dist",
|
|
419
|
+
"commands",
|
|
420
|
+
"config",
|
|
421
|
+
"show.js"
|
|
422
|
+
]
|
|
423
|
+
},
|
|
424
|
+
"config:use": {
|
|
425
|
+
"aliases": [],
|
|
426
|
+
"args": {},
|
|
427
|
+
"description": "Switch to a different configuration file",
|
|
428
|
+
"examples": [
|
|
429
|
+
"<%= config.bin %> <%= command.id %>"
|
|
430
|
+
],
|
|
431
|
+
"flags": {
|
|
432
|
+
"json": {
|
|
433
|
+
"description": "Format output as json.",
|
|
434
|
+
"helpGroup": "GLOBAL",
|
|
435
|
+
"name": "json",
|
|
436
|
+
"allowNo": false,
|
|
437
|
+
"type": "boolean"
|
|
438
|
+
}
|
|
439
|
+
},
|
|
440
|
+
"hasDynamicHelp": false,
|
|
441
|
+
"hiddenAliases": [],
|
|
442
|
+
"id": "config:use",
|
|
443
|
+
"pluginAlias": "@super-protocol/sp-cli",
|
|
444
|
+
"pluginName": "@super-protocol/sp-cli",
|
|
445
|
+
"pluginType": "core",
|
|
446
|
+
"strict": true,
|
|
447
|
+
"enableJsonFlag": true,
|
|
448
|
+
"isESM": true,
|
|
449
|
+
"relativePath": [
|
|
450
|
+
"dist",
|
|
451
|
+
"commands",
|
|
452
|
+
"config",
|
|
453
|
+
"use.js"
|
|
454
|
+
]
|
|
455
|
+
},
|
|
456
|
+
"files:download": {
|
|
457
|
+
"aliases": [],
|
|
458
|
+
"args": {
|
|
459
|
+
"resourceFile": {
|
|
460
|
+
"description": "Path to a resource file",
|
|
461
|
+
"name": "resourceFile",
|
|
462
|
+
"required": true
|
|
463
|
+
},
|
|
464
|
+
"localDirectory": {
|
|
465
|
+
"description": "Path to save downloaded file",
|
|
466
|
+
"name": "localDirectory",
|
|
467
|
+
"required": true
|
|
468
|
+
}
|
|
469
|
+
},
|
|
470
|
+
"description": "Download file or directory described in resource file",
|
|
471
|
+
"examples": [
|
|
472
|
+
"<%= config.bin %> <%= command.id %> ./resource.json ./pathToDownload "
|
|
337
473
|
],
|
|
338
474
|
"flags": {
|
|
339
475
|
"json": {
|
|
@@ -352,34 +488,113 @@
|
|
|
352
488
|
"multiple": false,
|
|
353
489
|
"type": "option"
|
|
354
490
|
},
|
|
355
|
-
"
|
|
491
|
+
"maximum-concurrent": {
|
|
492
|
+
"description": "Maximum concurrent pieces to download at once per transfer",
|
|
493
|
+
"name": "maximum-concurrent",
|
|
494
|
+
"default": 1,
|
|
495
|
+
"hasDynamicHelp": false,
|
|
496
|
+
"multiple": false,
|
|
497
|
+
"type": "option"
|
|
498
|
+
}
|
|
499
|
+
},
|
|
500
|
+
"hasDynamicHelp": false,
|
|
501
|
+
"hiddenAliases": [],
|
|
502
|
+
"id": "files:download",
|
|
503
|
+
"pluginAlias": "@super-protocol/sp-cli",
|
|
504
|
+
"pluginName": "@super-protocol/sp-cli",
|
|
505
|
+
"pluginType": "core",
|
|
506
|
+
"strict": true,
|
|
507
|
+
"enableJsonFlag": true,
|
|
508
|
+
"help": "Download and decrypt a file from the remote storage to <localPath> using resource file <resourcePath>",
|
|
509
|
+
"isESM": true,
|
|
510
|
+
"relativePath": [
|
|
511
|
+
"dist",
|
|
512
|
+
"commands",
|
|
513
|
+
"files",
|
|
514
|
+
"download.js"
|
|
515
|
+
]
|
|
516
|
+
},
|
|
517
|
+
"files:upload": {
|
|
518
|
+
"aliases": [],
|
|
519
|
+
"args": {
|
|
520
|
+
"path": {
|
|
521
|
+
"description": "file or directory to upload",
|
|
522
|
+
"name": "path",
|
|
523
|
+
"required": true
|
|
524
|
+
}
|
|
525
|
+
},
|
|
526
|
+
"description": "Upload file or directory to remote storage",
|
|
527
|
+
"examples": [
|
|
528
|
+
"<%= config.bin %> <%= command.id %> ./file.txt"
|
|
529
|
+
],
|
|
530
|
+
"flags": {
|
|
531
|
+
"json": {
|
|
532
|
+
"description": "Format output as json.",
|
|
356
533
|
"helpGroup": "GLOBAL",
|
|
357
|
-
"name": "
|
|
534
|
+
"name": "json",
|
|
535
|
+
"allowNo": false,
|
|
536
|
+
"type": "boolean"
|
|
537
|
+
},
|
|
538
|
+
"config": {
|
|
539
|
+
"helpGroup": "GLOBAL",
|
|
540
|
+
"name": "config",
|
|
358
541
|
"required": false,
|
|
359
|
-
"summary": "Specify
|
|
542
|
+
"summary": "Specify config file.",
|
|
360
543
|
"hasDynamicHelp": false,
|
|
361
544
|
"multiple": false,
|
|
362
545
|
"type": "option"
|
|
363
546
|
},
|
|
364
|
-
"
|
|
365
|
-
"
|
|
366
|
-
"
|
|
367
|
-
"
|
|
368
|
-
"
|
|
369
|
-
"
|
|
547
|
+
"filename": {
|
|
548
|
+
"description": "The name of the resulting file/directory in the storage",
|
|
549
|
+
"name": "filename",
|
|
550
|
+
"required": false,
|
|
551
|
+
"hasDynamicHelp": false,
|
|
552
|
+
"multiple": false,
|
|
553
|
+
"type": "option"
|
|
370
554
|
},
|
|
371
|
-
"
|
|
372
|
-
"
|
|
373
|
-
"
|
|
374
|
-
"
|
|
555
|
+
"maximum-concurrent": {
|
|
556
|
+
"description": "Maximum concurrent pieces to upload at once per transfer",
|
|
557
|
+
"name": "maximum-concurrent",
|
|
558
|
+
"default": 1,
|
|
559
|
+
"hasDynamicHelp": false,
|
|
560
|
+
"multiple": false,
|
|
561
|
+
"type": "option"
|
|
562
|
+
},
|
|
563
|
+
"metadata": {
|
|
564
|
+
"description": "Path to a metadata file for adding fields to the resource file",
|
|
565
|
+
"name": "metadata",
|
|
566
|
+
"required": false,
|
|
567
|
+
"hasDynamicHelp": false,
|
|
568
|
+
"multiple": false,
|
|
569
|
+
"type": "option"
|
|
570
|
+
},
|
|
571
|
+
"output": {
|
|
572
|
+
"description": "Path to save resource file that is used to access the uploaded file",
|
|
573
|
+
"name": "output",
|
|
574
|
+
"required": false,
|
|
575
|
+
"default": "resource.json",
|
|
375
576
|
"hasDynamicHelp": false,
|
|
376
577
|
"multiple": false,
|
|
377
578
|
"type": "option"
|
|
579
|
+
},
|
|
580
|
+
"skip-encryption": {
|
|
581
|
+
"description": "Skip file encryption before upload",
|
|
582
|
+
"name": "skip-encryption",
|
|
583
|
+
"required": false,
|
|
584
|
+
"allowNo": false,
|
|
585
|
+
"type": "boolean"
|
|
586
|
+
},
|
|
587
|
+
"sync": {
|
|
588
|
+
"description": "Sync mode: delete files in target that don't exist in source",
|
|
589
|
+
"name": "sync",
|
|
590
|
+
"required": false,
|
|
591
|
+
"allowNo": false,
|
|
592
|
+
"type": "boolean"
|
|
378
593
|
}
|
|
379
594
|
},
|
|
380
595
|
"hasDynamicHelp": false,
|
|
381
596
|
"hiddenAliases": [],
|
|
382
|
-
"id": "
|
|
597
|
+
"id": "files:upload",
|
|
383
598
|
"pluginAlias": "@super-protocol/sp-cli",
|
|
384
599
|
"pluginName": "@super-protocol/sp-cli",
|
|
385
600
|
"pluginType": "core",
|
|
@@ -389,21 +604,18 @@
|
|
|
389
604
|
"relativePath": [
|
|
390
605
|
"dist",
|
|
391
606
|
"commands",
|
|
392
|
-
"
|
|
393
|
-
"
|
|
607
|
+
"files",
|
|
608
|
+
"upload.js"
|
|
394
609
|
]
|
|
395
610
|
},
|
|
396
|
-
"
|
|
611
|
+
"storage:create": {
|
|
397
612
|
"aliases": [],
|
|
398
613
|
"args": {},
|
|
399
|
-
"description": "
|
|
614
|
+
"description": "Create a new storage entry from file or interactive prompts.",
|
|
400
615
|
"examples": [
|
|
401
|
-
"<%= config.bin %>
|
|
402
|
-
"<%= config.bin %>
|
|
403
|
-
"<%= config.bin %>
|
|
404
|
-
"<%= config.bin %> <%= command.id %> create --name \"My Config\" - Create new configuration",
|
|
405
|
-
"<%= config.bin %> <%= command.id %> add ./config.json - Import configuration from file",
|
|
406
|
-
"<%= config.bin %> <%= command.id %> delete - Delete a configuration"
|
|
616
|
+
"<%= config.bin %> storage create",
|
|
617
|
+
"<%= config.bin %> storage create --fromFile ./storage.json",
|
|
618
|
+
"<%= config.bin %> storage create --not-default"
|
|
407
619
|
],
|
|
408
620
|
"flags": {
|
|
409
621
|
"json": {
|
|
@@ -422,38 +634,45 @@
|
|
|
422
634
|
"multiple": false,
|
|
423
635
|
"type": "option"
|
|
424
636
|
},
|
|
425
|
-
"
|
|
426
|
-
"
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
"
|
|
637
|
+
"fromFile": {
|
|
638
|
+
"aliases": [
|
|
639
|
+
"fromFile"
|
|
640
|
+
],
|
|
641
|
+
"char": "f",
|
|
642
|
+
"description": "Path to a JSON file that contains AddStorageDto payload.",
|
|
643
|
+
"name": "fromFile",
|
|
430
644
|
"hasDynamicHelp": false,
|
|
431
645
|
"multiple": false,
|
|
432
646
|
"type": "option"
|
|
647
|
+
},
|
|
648
|
+
"notDefault": {
|
|
649
|
+
"description": "Skip setting the created storage as default.",
|
|
650
|
+
"name": "notDefault",
|
|
651
|
+
"allowNo": false,
|
|
652
|
+
"type": "boolean"
|
|
433
653
|
}
|
|
434
654
|
},
|
|
435
655
|
"hasDynamicHelp": false,
|
|
436
656
|
"hiddenAliases": [],
|
|
437
|
-
"id": "
|
|
657
|
+
"id": "storage:create",
|
|
438
658
|
"pluginAlias": "@super-protocol/sp-cli",
|
|
439
659
|
"pluginName": "@super-protocol/sp-cli",
|
|
440
660
|
"pluginType": "core",
|
|
441
661
|
"strict": true,
|
|
442
|
-
"enableJsonFlag": true,
|
|
443
662
|
"isESM": true,
|
|
444
663
|
"relativePath": [
|
|
445
664
|
"dist",
|
|
446
665
|
"commands",
|
|
447
|
-
"
|
|
448
|
-
"
|
|
666
|
+
"storage",
|
|
667
|
+
"create.js"
|
|
449
668
|
]
|
|
450
669
|
},
|
|
451
|
-
"
|
|
670
|
+
"storage:select": {
|
|
452
671
|
"aliases": [],
|
|
453
672
|
"args": {},
|
|
454
|
-
"description": "
|
|
673
|
+
"description": "Select a storage that will be used by subsequent commands.",
|
|
455
674
|
"examples": [
|
|
456
|
-
"<%= config.bin %>
|
|
675
|
+
"<%= config.bin %> storage select"
|
|
457
676
|
],
|
|
458
677
|
"flags": {
|
|
459
678
|
"json": {
|
|
@@ -471,12 +690,43 @@
|
|
|
471
690
|
"hasDynamicHelp": false,
|
|
472
691
|
"multiple": false,
|
|
473
692
|
"type": "option"
|
|
693
|
+
}
|
|
694
|
+
},
|
|
695
|
+
"hasDynamicHelp": false,
|
|
696
|
+
"hiddenAliases": [],
|
|
697
|
+
"id": "storage:select",
|
|
698
|
+
"pluginAlias": "@super-protocol/sp-cli",
|
|
699
|
+
"pluginName": "@super-protocol/sp-cli",
|
|
700
|
+
"pluginType": "core",
|
|
701
|
+
"strict": true,
|
|
702
|
+
"isESM": true,
|
|
703
|
+
"relativePath": [
|
|
704
|
+
"dist",
|
|
705
|
+
"commands",
|
|
706
|
+
"storage",
|
|
707
|
+
"select.js"
|
|
708
|
+
]
|
|
709
|
+
},
|
|
710
|
+
"storage:show": {
|
|
711
|
+
"aliases": [],
|
|
712
|
+
"args": {},
|
|
713
|
+
"description": "Show current selected storage",
|
|
714
|
+
"examples": [
|
|
715
|
+
"<%= config.bin %> <%= command.id %>"
|
|
716
|
+
],
|
|
717
|
+
"flags": {
|
|
718
|
+
"json": {
|
|
719
|
+
"description": "Format output as json.",
|
|
720
|
+
"helpGroup": "GLOBAL",
|
|
721
|
+
"name": "json",
|
|
722
|
+
"allowNo": false,
|
|
723
|
+
"type": "boolean"
|
|
474
724
|
},
|
|
475
|
-
"
|
|
725
|
+
"config": {
|
|
476
726
|
"helpGroup": "GLOBAL",
|
|
477
|
-
"name": "
|
|
727
|
+
"name": "config",
|
|
478
728
|
"required": false,
|
|
479
|
-
"summary": "Specify
|
|
729
|
+
"summary": "Specify config file.",
|
|
480
730
|
"hasDynamicHelp": false,
|
|
481
731
|
"multiple": false,
|
|
482
732
|
"type": "option"
|
|
@@ -484,26 +734,26 @@
|
|
|
484
734
|
},
|
|
485
735
|
"hasDynamicHelp": false,
|
|
486
736
|
"hiddenAliases": [],
|
|
487
|
-
"id": "
|
|
737
|
+
"id": "storage:show",
|
|
488
738
|
"pluginAlias": "@super-protocol/sp-cli",
|
|
489
739
|
"pluginName": "@super-protocol/sp-cli",
|
|
490
740
|
"pluginType": "core",
|
|
491
741
|
"strict": true,
|
|
492
|
-
"enableJsonFlag": true,
|
|
493
742
|
"isESM": true,
|
|
494
743
|
"relativePath": [
|
|
495
744
|
"dist",
|
|
496
745
|
"commands",
|
|
497
|
-
"
|
|
498
|
-
"
|
|
746
|
+
"storage",
|
|
747
|
+
"show.js"
|
|
499
748
|
]
|
|
500
749
|
},
|
|
501
|
-
"
|
|
750
|
+
"storage:update": {
|
|
502
751
|
"aliases": [],
|
|
503
752
|
"args": {},
|
|
504
|
-
"description": "
|
|
753
|
+
"description": "Update the configuration of an existing storage.",
|
|
505
754
|
"examples": [
|
|
506
|
-
"<%= config.bin %>
|
|
755
|
+
"<%= config.bin %> storage update --id=2de3e3a4-0000-1111-2222-333344445555 --fromFile ./storage-update.json",
|
|
756
|
+
"<%= config.bin %> storage update --id=2de3e3a4-0000-1111-2222-333344445555"
|
|
507
757
|
],
|
|
508
758
|
"flags": {
|
|
509
759
|
"json": {
|
|
@@ -522,11 +772,18 @@
|
|
|
522
772
|
"multiple": false,
|
|
523
773
|
"type": "option"
|
|
524
774
|
},
|
|
525
|
-
"
|
|
526
|
-
"
|
|
527
|
-
"
|
|
528
|
-
"
|
|
529
|
-
"
|
|
775
|
+
"fromFile": {
|
|
776
|
+
"char": "f",
|
|
777
|
+
"description": "Path to a JSON file that contains UpdateStorageDto payload.",
|
|
778
|
+
"name": "fromFile",
|
|
779
|
+
"hasDynamicHelp": false,
|
|
780
|
+
"multiple": false,
|
|
781
|
+
"type": "option"
|
|
782
|
+
},
|
|
783
|
+
"id": {
|
|
784
|
+
"char": "i",
|
|
785
|
+
"description": "Storage ID to update",
|
|
786
|
+
"name": "id",
|
|
530
787
|
"hasDynamicHelp": false,
|
|
531
788
|
"multiple": false,
|
|
532
789
|
"type": "option"
|
|
@@ -534,26 +791,33 @@
|
|
|
534
791
|
},
|
|
535
792
|
"hasDynamicHelp": false,
|
|
536
793
|
"hiddenAliases": [],
|
|
537
|
-
"id": "
|
|
794
|
+
"id": "storage:update",
|
|
538
795
|
"pluginAlias": "@super-protocol/sp-cli",
|
|
539
796
|
"pluginName": "@super-protocol/sp-cli",
|
|
540
797
|
"pluginType": "core",
|
|
541
798
|
"strict": true,
|
|
542
|
-
"enableJsonFlag": true,
|
|
543
799
|
"isESM": true,
|
|
544
800
|
"relativePath": [
|
|
545
801
|
"dist",
|
|
546
802
|
"commands",
|
|
547
|
-
"
|
|
548
|
-
"
|
|
803
|
+
"storage",
|
|
804
|
+
"update.js"
|
|
549
805
|
]
|
|
550
806
|
},
|
|
551
|
-
"
|
|
807
|
+
"workflows:extend-lease": {
|
|
552
808
|
"aliases": [],
|
|
553
|
-
"args": {
|
|
554
|
-
|
|
809
|
+
"args": {
|
|
810
|
+
"orderId": {
|
|
811
|
+
"description": "Order ID",
|
|
812
|
+
"name": "orderId",
|
|
813
|
+
"required": true
|
|
814
|
+
}
|
|
815
|
+
},
|
|
816
|
+
"description": "Replenish deposit for a workflow to extend its lease time",
|
|
555
817
|
"examples": [
|
|
556
|
-
"<%= config.bin %> <%= command.id %>"
|
|
818
|
+
"<%= config.bin %> <%= command.id %> <orderId> --sppi 1.5",
|
|
819
|
+
"<%= config.bin %> <%= command.id %> <orderId> --minutes 120",
|
|
820
|
+
"<%= config.bin %> <%= command.id %> <orderId> --sppi 2 --yes"
|
|
557
821
|
],
|
|
558
822
|
"flags": {
|
|
559
823
|
"json": {
|
|
@@ -572,19 +836,31 @@
|
|
|
572
836
|
"multiple": false,
|
|
573
837
|
"type": "option"
|
|
574
838
|
},
|
|
575
|
-
"
|
|
576
|
-
"
|
|
577
|
-
"name": "
|
|
578
|
-
"required": false,
|
|
579
|
-
"summary": "Specify provider base URL.",
|
|
839
|
+
"minutes": {
|
|
840
|
+
"description": "Time to extend order in minutes (automatically calculates tokens)",
|
|
841
|
+
"name": "minutes",
|
|
580
842
|
"hasDynamicHelp": false,
|
|
581
843
|
"multiple": false,
|
|
582
844
|
"type": "option"
|
|
845
|
+
},
|
|
846
|
+
"sppi": {
|
|
847
|
+
"description": "SPPI token amount to add to the order",
|
|
848
|
+
"name": "sppi",
|
|
849
|
+
"hasDynamicHelp": false,
|
|
850
|
+
"multiple": false,
|
|
851
|
+
"type": "option"
|
|
852
|
+
},
|
|
853
|
+
"yes": {
|
|
854
|
+
"char": "y",
|
|
855
|
+
"description": "Skip confirmation prompt",
|
|
856
|
+
"name": "yes",
|
|
857
|
+
"allowNo": false,
|
|
858
|
+
"type": "boolean"
|
|
583
859
|
}
|
|
584
860
|
},
|
|
585
861
|
"hasDynamicHelp": false,
|
|
586
862
|
"hiddenAliases": [],
|
|
587
|
-
"id": "
|
|
863
|
+
"id": "workflows:extend-lease",
|
|
588
864
|
"pluginAlias": "@super-protocol/sp-cli",
|
|
589
865
|
"pluginName": "@super-protocol/sp-cli",
|
|
590
866
|
"pluginType": "core",
|
|
@@ -594,10 +870,10 @@
|
|
|
594
870
|
"relativePath": [
|
|
595
871
|
"dist",
|
|
596
872
|
"commands",
|
|
597
|
-
"
|
|
598
|
-
"
|
|
873
|
+
"workflows",
|
|
874
|
+
"extend-lease.js"
|
|
599
875
|
]
|
|
600
876
|
}
|
|
601
877
|
},
|
|
602
|
-
"version": "0.0.
|
|
878
|
+
"version": "0.0.4-beta.0"
|
|
603
879
|
}
|