@constructive-sdk/cli 1.21.4 → 1.21.6
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/admin/cli/commands/provision-bucket.js +1 -1
- package/admin/cli/commands.js +1 -1
- package/admin/orm/input-types.d.ts +4 -4
- package/admin/orm/mutation/index.d.ts +5 -4
- package/agent/cli/commands/provision-bucket.js +1 -1
- package/agent/cli/commands.js +1 -1
- package/agent/orm/input-types.d.ts +4 -4
- package/agent/orm/mutation/index.d.ts +5 -4
- package/api/cli/commands/{route-binding.d.ts → create-function-from-source.d.ts} +1 -1
- package/api/cli/commands/create-function-from-source.js +36 -0
- package/api/cli/commands/{hostname-binding.d.ts → email-shared-account.d.ts} +1 -1
- package/api/cli/commands/email-shared-account.js +21 -0
- package/api/cli/commands/managed-domain.js +22 -0
- package/api/cli/commands/platform-managed-domain.js +22 -0
- package/api/cli/commands/provision-bucket.js +1 -1
- package/api/cli/commands/unique-constraint.js +22 -0
- package/{esm/api/cli/commands/route-binding.d.ts → api/cli/commands/update-function-from-source.d.ts} +1 -1
- package/api/cli/commands/update-function-from-source.js +36 -0
- package/api/cli/commands.js +7 -5
- package/api/cli/executor.d.ts +15 -2
- package/api/orm/index.d.ts +15 -4
- package/api/orm/index.js +0 -4
- package/api/orm/input-types.d.ts +96 -439
- package/api/orm/models/index.d.ts +0 -2
- package/api/orm/models/index.js +2 -6
- package/api/orm/mutation/index.d.ts +30 -5
- package/api/orm/mutation/index.js +24 -0
- package/api/orm/query/index.d.ts +5 -0
- package/api/orm/query/index.js +7 -0
- package/auth/cli/commands/provision-bucket.js +1 -1
- package/auth/cli/commands.js +1 -1
- package/auth/orm/input-types.d.ts +5 -29
- package/auth/orm/mutation/index.d.ts +5 -4
- package/compute/cli/commands/function-invocation.js +44 -0
- package/compute/cli/commands/platform-function-invocation.js +44 -0
- package/compute/cli/commands/provision-bucket.js +1 -1
- package/compute/cli/commands.js +1 -1
- package/compute/orm/input-types.d.ts +50 -6
- package/compute/orm/mutation/index.d.ts +5 -4
- package/config/cli/commands/provision-bucket.js +1 -1
- package/config/cli/commands.js +1 -1
- package/config/orm/input-types.d.ts +4 -4
- package/config/orm/mutation/index.d.ts +5 -4
- package/esm/admin/cli/commands/provision-bucket.js +1 -1
- package/esm/admin/cli/commands.js +1 -1
- package/esm/admin/orm/input-types.d.ts +4 -4
- package/esm/admin/orm/mutation/index.d.ts +5 -4
- package/esm/agent/cli/commands/provision-bucket.js +1 -1
- package/esm/agent/cli/commands.js +1 -1
- package/esm/agent/orm/input-types.d.ts +4 -4
- package/esm/agent/orm/mutation/index.d.ts +5 -4
- package/esm/api/cli/commands/create-function-from-source.d.ts +8 -0
- package/esm/api/cli/commands/create-function-from-source.js +34 -0
- package/esm/api/cli/commands/{hostname-binding.d.ts → email-shared-account.d.ts} +1 -1
- package/esm/api/cli/commands/email-shared-account.js +19 -0
- package/esm/api/cli/commands/managed-domain.js +22 -0
- package/esm/api/cli/commands/platform-managed-domain.js +22 -0
- package/esm/api/cli/commands/provision-bucket.js +1 -1
- package/esm/api/cli/commands/unique-constraint.js +22 -0
- package/esm/api/cli/commands/update-function-from-source.d.ts +8 -0
- package/esm/api/cli/commands/update-function-from-source.js +34 -0
- package/esm/api/cli/commands.js +7 -5
- package/esm/api/cli/executor.d.ts +15 -2
- package/esm/api/orm/index.d.ts +15 -4
- package/esm/api/orm/index.js +0 -4
- package/esm/api/orm/input-types.d.ts +96 -439
- package/esm/api/orm/models/index.d.ts +0 -2
- package/esm/api/orm/models/index.js +0 -2
- package/esm/api/orm/mutation/index.d.ts +30 -5
- package/esm/api/orm/mutation/index.js +24 -0
- package/esm/api/orm/query/index.d.ts +5 -0
- package/esm/api/orm/query/index.js +7 -0
- package/esm/auth/cli/commands/provision-bucket.js +1 -1
- package/esm/auth/cli/commands.js +1 -1
- package/esm/auth/orm/input-types.d.ts +5 -29
- package/esm/auth/orm/mutation/index.d.ts +5 -4
- package/esm/compute/cli/commands/function-invocation.js +44 -0
- package/esm/compute/cli/commands/platform-function-invocation.js +44 -0
- package/esm/compute/cli/commands/provision-bucket.js +1 -1
- package/esm/compute/cli/commands.js +1 -1
- package/esm/compute/orm/input-types.d.ts +50 -6
- package/esm/compute/orm/mutation/index.d.ts +5 -4
- package/esm/config/cli/commands/provision-bucket.js +1 -1
- package/esm/config/cli/commands.js +1 -1
- package/esm/config/orm/input-types.d.ts +4 -4
- package/esm/config/orm/mutation/index.d.ts +5 -4
- package/esm/infra/cli/commands/provision-bucket.js +1 -1
- package/esm/infra/cli/commands.js +1 -1
- package/esm/infra/orm/input-types.d.ts +4 -4
- package/esm/infra/orm/mutation/index.d.ts +5 -4
- package/esm/modules/cli/commands/billing-provider-module.js +110 -0
- package/esm/modules/cli/commands/blueprint-construction.js +0 -22
- package/esm/modules/cli/commands/catalog-module.js +44 -0
- package/esm/modules/cli/commands/construct-blueprint.js +1 -1
- package/esm/modules/cli/commands/provision-bucket.js +1 -1
- package/esm/modules/cli/commands/storage-module.js +22 -0
- package/esm/modules/cli/commands.js +1 -1
- package/esm/modules/orm/input-types.d.ts +72 -21
- package/esm/modules/orm/mutation/index.d.ts +6 -5
- package/esm/objects/cli/commands/provision-bucket.js +1 -1
- package/esm/objects/cli/commands.js +1 -1
- package/esm/objects/orm/input-types.d.ts +4 -4
- package/esm/objects/orm/mutation/index.d.ts +5 -4
- package/esm/remote/cli/commands/provision-bucket.js +1 -1
- package/esm/remote/cli/commands.js +1 -1
- package/esm/remote/orm/input-types.d.ts +4 -4
- package/esm/remote/orm/mutation/index.d.ts +5 -4
- package/esm/storage/cli/commands/bucket.js +23 -0
- package/esm/storage/cli/commands/platform-bucket.js +23 -0
- package/esm/storage/cli/commands/provision-bucket.js +1 -1
- package/esm/storage/cli/commands/upload-files.js +1 -1
- package/esm/storage/cli/commands/upload-platform-files.js +1 -1
- package/esm/storage/cli/commands.js +1 -1
- package/esm/storage/orm/input-types.d.ts +34 -6
- package/esm/storage/orm/mutation/index.d.ts +7 -6
- package/esm/usage/cli/commands/provision-bucket.js +1 -1
- package/esm/usage/cli/commands.js +1 -1
- package/esm/usage/orm/input-types.d.ts +4 -4
- package/esm/usage/orm/mutation/index.d.ts +5 -4
- package/infra/cli/commands/provision-bucket.js +1 -1
- package/infra/cli/commands.js +1 -1
- package/infra/orm/input-types.d.ts +4 -4
- package/infra/orm/mutation/index.d.ts +5 -4
- package/modules/cli/commands/billing-provider-module.js +110 -0
- package/modules/cli/commands/blueprint-construction.js +0 -22
- package/modules/cli/commands/catalog-module.js +44 -0
- package/modules/cli/commands/construct-blueprint.js +1 -1
- package/modules/cli/commands/provision-bucket.js +1 -1
- package/modules/cli/commands/storage-module.js +22 -0
- package/modules/cli/commands.js +1 -1
- package/modules/orm/input-types.d.ts +72 -21
- package/modules/orm/mutation/index.d.ts +6 -5
- package/objects/cli/commands/provision-bucket.js +1 -1
- package/objects/cli/commands.js +1 -1
- package/objects/orm/input-types.d.ts +4 -4
- package/objects/orm/mutation/index.d.ts +5 -4
- package/package.json +4 -4
- package/remote/cli/commands/provision-bucket.js +1 -1
- package/remote/cli/commands.js +1 -1
- package/remote/orm/input-types.d.ts +4 -4
- package/remote/orm/mutation/index.d.ts +5 -4
- package/storage/cli/commands/bucket.js +23 -0
- package/storage/cli/commands/platform-bucket.js +23 -0
- package/storage/cli/commands/provision-bucket.js +1 -1
- package/storage/cli/commands/upload-files.js +1 -1
- package/storage/cli/commands/upload-platform-files.js +1 -1
- package/storage/cli/commands.js +1 -1
- package/storage/orm/input-types.d.ts +34 -6
- package/storage/orm/mutation/index.d.ts +7 -6
- package/usage/cli/commands/provision-bucket.js +1 -1
- package/usage/cli/commands.js +1 -1
- package/usage/orm/input-types.d.ts +4 -4
- package/usage/orm/mutation/index.d.ts +5 -4
- package/api/cli/commands/hostname-binding.js +0 -388
- package/api/cli/commands/route-binding.js +0 -476
- package/api/orm/models/hostnameBinding.d.ts +0 -54
- package/api/orm/models/hostnameBinding.js +0 -104
- package/api/orm/models/routeBinding.d.ts +0 -54
- package/api/orm/models/routeBinding.js +0 -104
- package/esm/api/cli/commands/hostname-binding.js +0 -386
- package/esm/api/cli/commands/route-binding.js +0 -474
- package/esm/api/orm/models/hostnameBinding.d.ts +0 -54
- package/esm/api/orm/models/hostnameBinding.js +0 -100
- package/esm/api/orm/models/routeBinding.d.ts +0 -54
- package/esm/api/orm/models/routeBinding.js +0 -100
|
@@ -19,10 +19,11 @@ export interface InsertNodesAtPathsVariables {
|
|
|
19
19
|
/**
|
|
20
20
|
* Variables for provisionBucket
|
|
21
21
|
* Reconcile an S3 bucket for a logical bucket in the database.
|
|
22
|
-
|
|
23
|
-
storage:provision_bucket job used
|
|
24
|
-
|
|
25
|
-
GraphQL
|
|
22
|
+
Records the request on the bucket row via RLS; the bucket's job
|
|
23
|
+
trigger then enqueues the same storage:provision_bucket job used on
|
|
24
|
+
INSERT, and repeated requests collapse into one pending job. This is
|
|
25
|
+
idempotent for an already-reconciled bucket; failures become GraphQL
|
|
26
|
+
errors.
|
|
26
27
|
*/
|
|
27
28
|
export interface ProvisionBucketVariables {
|
|
28
29
|
input: ProvisionBucketInput;
|
|
@@ -3,7 +3,7 @@ import { unflattenDotNotation, buildSelectFromPaths } from '../utils';
|
|
|
3
3
|
export default async (argv, prompter, _options) => {
|
|
4
4
|
try {
|
|
5
5
|
if (argv.help || argv.h) {
|
|
6
|
-
console.log(
|
|
6
|
+
console.log("provision-bucket - Reconcile an S3 bucket for a logical bucket in the database.\nRecords the request on the bucket row via RLS; the bucket's job\ntrigger then enqueues the same storage:provision_bucket job used on\nINSERT, and repeated requests collapse into one pending job. This is\nidempotent for an already-reconciled bucket; failures become GraphQL\nerrors.\n\nUsage: provision-bucket [OPTIONS]\n");
|
|
7
7
|
process.exit(0);
|
|
8
8
|
}
|
|
9
9
|
const answers = await prompter.prompt(argv, [
|
|
@@ -20,7 +20,7 @@ const createCommandMap = () => ({
|
|
|
20
20
|
'machines-enroll': machinesEnrollCmd,
|
|
21
21
|
'provision-bucket': provisionBucketCmd,
|
|
22
22
|
});
|
|
23
|
-
const usage =
|
|
23
|
+
const usage = "\ncsdk <command>\n\nCommands:\n context Manage API contexts\n auth Manage authentication\n machine machine CRUD operations\n machine-message machineMessage CRUD operations\n machine-session machineSession CRUD operations\n machines-enroll machinesEnroll\n provision-bucket Reconcile an S3 bucket for a logical bucket in the database.\nRecords the request on the bucket row via RLS; the bucket's job\ntrigger then enqueues the same storage:provision_bucket job used on\nINSERT, and repeated requests collapse into one pending job. This is\nidempotent for an already-reconciled bucket; failures become GraphQL\nerrors.\n\n --help, -h Show this help message\n --version, -v Show version\n";
|
|
24
24
|
export const commands = async (argv, prompter, options) => {
|
|
25
25
|
if (argv.help || argv.h) {
|
|
26
26
|
console.log(usage);
|
|
@@ -1307,19 +1307,19 @@ export type MachinesEnrollPayloadSelect = {
|
|
|
1307
1307
|
result?: boolean;
|
|
1308
1308
|
};
|
|
1309
1309
|
export interface ProvisionBucketPayload {
|
|
1310
|
-
/** The logical bucket row
|
|
1310
|
+
/** The logical bucket row whose reconciliation was requested. */
|
|
1311
1311
|
bucketId: string;
|
|
1312
1312
|
bucketKey: string;
|
|
1313
|
-
/** The reconciler job enqueued to provision this bucket. */
|
|
1314
|
-
jobId: string;
|
|
1315
1313
|
/** The physical bucket name already recorded, or null when reconciliation has not completed. */
|
|
1316
1314
|
physicalName?: string | null;
|
|
1315
|
+
/** When reconciliation was last requested for this bucket. */
|
|
1316
|
+
provisionRequestedAt: string;
|
|
1317
1317
|
}
|
|
1318
1318
|
export type ProvisionBucketPayloadSelect = {
|
|
1319
1319
|
bucketId?: boolean;
|
|
1320
1320
|
bucketKey?: boolean;
|
|
1321
|
-
jobId?: boolean;
|
|
1322
1321
|
physicalName?: boolean;
|
|
1322
|
+
provisionRequestedAt?: boolean;
|
|
1323
1323
|
};
|
|
1324
1324
|
export interface CreateMachinePayload {
|
|
1325
1325
|
clientMutationId?: string | null;
|
|
@@ -13,10 +13,11 @@ export interface MachinesEnrollVariables {
|
|
|
13
13
|
/**
|
|
14
14
|
* Variables for provisionBucket
|
|
15
15
|
* Reconcile an S3 bucket for a logical bucket in the database.
|
|
16
|
-
|
|
17
|
-
storage:provision_bucket job used
|
|
18
|
-
|
|
19
|
-
GraphQL
|
|
16
|
+
Records the request on the bucket row via RLS; the bucket's job
|
|
17
|
+
trigger then enqueues the same storage:provision_bucket job used on
|
|
18
|
+
INSERT, and repeated requests collapse into one pending job. This is
|
|
19
|
+
idempotent for an already-reconciled bucket; failures become GraphQL
|
|
20
|
+
errors.
|
|
20
21
|
*/
|
|
21
22
|
export interface ProvisionBucketVariables {
|
|
22
23
|
input: ProvisionBucketInput;
|
|
@@ -18,8 +18,10 @@ const fieldSchema = {
|
|
|
18
18
|
id: 'uuid',
|
|
19
19
|
isPublic: 'boolean',
|
|
20
20
|
key: 'string',
|
|
21
|
+
maxBulkFiles: 'int',
|
|
21
22
|
maxFileSize: 'int',
|
|
22
23
|
physicalName: 'string',
|
|
24
|
+
provisionRequestedAt: 'string',
|
|
23
25
|
stagingTtl: 'string',
|
|
24
26
|
tags: 'string',
|
|
25
27
|
type: 'string',
|
|
@@ -80,6 +82,7 @@ async function handleList(argv, _prompter) {
|
|
|
80
82
|
key: true,
|
|
81
83
|
maxFileSize: true,
|
|
82
84
|
physicalName: true,
|
|
85
|
+
provisionRequestedAt: true,
|
|
83
86
|
stagingTtl: true,
|
|
84
87
|
tags: true,
|
|
85
88
|
type: true,
|
|
@@ -114,6 +117,7 @@ async function handleFindFirst(argv, _prompter) {
|
|
|
114
117
|
key: true,
|
|
115
118
|
maxFileSize: true,
|
|
116
119
|
physicalName: true,
|
|
120
|
+
provisionRequestedAt: true,
|
|
117
121
|
stagingTtl: true,
|
|
118
122
|
tags: true,
|
|
119
123
|
type: true,
|
|
@@ -160,6 +164,7 @@ async function handleGet(argv, prompter) {
|
|
|
160
164
|
key: true,
|
|
161
165
|
maxFileSize: true,
|
|
162
166
|
physicalName: true,
|
|
167
|
+
provisionRequestedAt: true,
|
|
163
168
|
stagingTtl: true,
|
|
164
169
|
tags: true,
|
|
165
170
|
type: true,
|
|
@@ -254,6 +259,13 @@ async function handleCreate(argv, prompter) {
|
|
|
254
259
|
required: false,
|
|
255
260
|
skipPrompt: true,
|
|
256
261
|
},
|
|
262
|
+
{
|
|
263
|
+
type: 'text',
|
|
264
|
+
name: 'provisionRequestedAt',
|
|
265
|
+
message: 'provisionRequestedAt',
|
|
266
|
+
required: false,
|
|
267
|
+
skipPrompt: true,
|
|
268
|
+
},
|
|
257
269
|
{
|
|
258
270
|
type: 'text',
|
|
259
271
|
name: 'stagingTtl',
|
|
@@ -293,6 +305,7 @@ async function handleCreate(argv, prompter) {
|
|
|
293
305
|
key: cleanedData.key,
|
|
294
306
|
maxFileSize: cleanedData.maxFileSize,
|
|
295
307
|
physicalName: cleanedData.physicalName,
|
|
308
|
+
provisionRequestedAt: cleanedData.provisionRequestedAt,
|
|
296
309
|
stagingTtl: cleanedData.stagingTtl,
|
|
297
310
|
tags: cleanedData.tags,
|
|
298
311
|
type: cleanedData.type,
|
|
@@ -311,6 +324,7 @@ async function handleCreate(argv, prompter) {
|
|
|
311
324
|
key: true,
|
|
312
325
|
maxFileSize: true,
|
|
313
326
|
physicalName: true,
|
|
327
|
+
provisionRequestedAt: true,
|
|
314
328
|
stagingTtl: true,
|
|
315
329
|
tags: true,
|
|
316
330
|
type: true,
|
|
@@ -411,6 +425,13 @@ async function handleUpdate(argv, prompter) {
|
|
|
411
425
|
required: false,
|
|
412
426
|
skipPrompt: true,
|
|
413
427
|
},
|
|
428
|
+
{
|
|
429
|
+
type: 'text',
|
|
430
|
+
name: 'provisionRequestedAt',
|
|
431
|
+
message: 'provisionRequestedAt',
|
|
432
|
+
required: false,
|
|
433
|
+
skipPrompt: true,
|
|
434
|
+
},
|
|
414
435
|
{
|
|
415
436
|
type: 'text',
|
|
416
437
|
name: 'stagingTtl',
|
|
@@ -453,6 +474,7 @@ async function handleUpdate(argv, prompter) {
|
|
|
453
474
|
key: cleanedData.key,
|
|
454
475
|
maxFileSize: cleanedData.maxFileSize,
|
|
455
476
|
physicalName: cleanedData.physicalName,
|
|
477
|
+
provisionRequestedAt: cleanedData.provisionRequestedAt,
|
|
456
478
|
stagingTtl: cleanedData.stagingTtl,
|
|
457
479
|
tags: cleanedData.tags,
|
|
458
480
|
type: cleanedData.type,
|
|
@@ -471,6 +493,7 @@ async function handleUpdate(argv, prompter) {
|
|
|
471
493
|
key: true,
|
|
472
494
|
maxFileSize: true,
|
|
473
495
|
physicalName: true,
|
|
496
|
+
provisionRequestedAt: true,
|
|
474
497
|
stagingTtl: true,
|
|
475
498
|
tags: true,
|
|
476
499
|
type: true,
|
|
@@ -17,8 +17,10 @@ const fieldSchema = {
|
|
|
17
17
|
id: 'uuid',
|
|
18
18
|
isPublic: 'boolean',
|
|
19
19
|
key: 'string',
|
|
20
|
+
maxBulkFiles: 'int',
|
|
20
21
|
maxFileSize: 'int',
|
|
21
22
|
physicalName: 'string',
|
|
23
|
+
provisionRequestedAt: 'string',
|
|
22
24
|
stagingTtl: 'string',
|
|
23
25
|
tags: 'string',
|
|
24
26
|
type: 'string',
|
|
@@ -78,6 +80,7 @@ async function handleList(argv, _prompter) {
|
|
|
78
80
|
key: true,
|
|
79
81
|
maxFileSize: true,
|
|
80
82
|
physicalName: true,
|
|
83
|
+
provisionRequestedAt: true,
|
|
81
84
|
stagingTtl: true,
|
|
82
85
|
tags: true,
|
|
83
86
|
type: true,
|
|
@@ -111,6 +114,7 @@ async function handleFindFirst(argv, _prompter) {
|
|
|
111
114
|
key: true,
|
|
112
115
|
maxFileSize: true,
|
|
113
116
|
physicalName: true,
|
|
117
|
+
provisionRequestedAt: true,
|
|
114
118
|
stagingTtl: true,
|
|
115
119
|
tags: true,
|
|
116
120
|
type: true,
|
|
@@ -156,6 +160,7 @@ async function handleGet(argv, prompter) {
|
|
|
156
160
|
key: true,
|
|
157
161
|
maxFileSize: true,
|
|
158
162
|
physicalName: true,
|
|
163
|
+
provisionRequestedAt: true,
|
|
159
164
|
stagingTtl: true,
|
|
160
165
|
tags: true,
|
|
161
166
|
type: true,
|
|
@@ -244,6 +249,13 @@ async function handleCreate(argv, prompter) {
|
|
|
244
249
|
required: false,
|
|
245
250
|
skipPrompt: true,
|
|
246
251
|
},
|
|
252
|
+
{
|
|
253
|
+
type: 'text',
|
|
254
|
+
name: 'provisionRequestedAt',
|
|
255
|
+
message: 'provisionRequestedAt',
|
|
256
|
+
required: false,
|
|
257
|
+
skipPrompt: true,
|
|
258
|
+
},
|
|
247
259
|
{
|
|
248
260
|
type: 'text',
|
|
249
261
|
name: 'stagingTtl',
|
|
@@ -282,6 +294,7 @@ async function handleCreate(argv, prompter) {
|
|
|
282
294
|
key: cleanedData.key,
|
|
283
295
|
maxFileSize: cleanedData.maxFileSize,
|
|
284
296
|
physicalName: cleanedData.physicalName,
|
|
297
|
+
provisionRequestedAt: cleanedData.provisionRequestedAt,
|
|
285
298
|
stagingTtl: cleanedData.stagingTtl,
|
|
286
299
|
tags: cleanedData.tags,
|
|
287
300
|
type: cleanedData.type,
|
|
@@ -299,6 +312,7 @@ async function handleCreate(argv, prompter) {
|
|
|
299
312
|
key: true,
|
|
300
313
|
maxFileSize: true,
|
|
301
314
|
physicalName: true,
|
|
315
|
+
provisionRequestedAt: true,
|
|
302
316
|
stagingTtl: true,
|
|
303
317
|
tags: true,
|
|
304
318
|
type: true,
|
|
@@ -393,6 +407,13 @@ async function handleUpdate(argv, prompter) {
|
|
|
393
407
|
required: false,
|
|
394
408
|
skipPrompt: true,
|
|
395
409
|
},
|
|
410
|
+
{
|
|
411
|
+
type: 'text',
|
|
412
|
+
name: 'provisionRequestedAt',
|
|
413
|
+
message: 'provisionRequestedAt',
|
|
414
|
+
required: false,
|
|
415
|
+
skipPrompt: true,
|
|
416
|
+
},
|
|
396
417
|
{
|
|
397
418
|
type: 'text',
|
|
398
419
|
name: 'stagingTtl',
|
|
@@ -434,6 +455,7 @@ async function handleUpdate(argv, prompter) {
|
|
|
434
455
|
key: cleanedData.key,
|
|
435
456
|
maxFileSize: cleanedData.maxFileSize,
|
|
436
457
|
physicalName: cleanedData.physicalName,
|
|
458
|
+
provisionRequestedAt: cleanedData.provisionRequestedAt,
|
|
437
459
|
stagingTtl: cleanedData.stagingTtl,
|
|
438
460
|
tags: cleanedData.tags,
|
|
439
461
|
type: cleanedData.type,
|
|
@@ -451,6 +473,7 @@ async function handleUpdate(argv, prompter) {
|
|
|
451
473
|
key: true,
|
|
452
474
|
maxFileSize: true,
|
|
453
475
|
physicalName: true,
|
|
476
|
+
provisionRequestedAt: true,
|
|
454
477
|
stagingTtl: true,
|
|
455
478
|
tags: true,
|
|
456
479
|
type: true,
|
|
@@ -3,7 +3,7 @@ import { unflattenDotNotation, buildSelectFromPaths } from '../utils';
|
|
|
3
3
|
export default async (argv, prompter, _options) => {
|
|
4
4
|
try {
|
|
5
5
|
if (argv.help || argv.h) {
|
|
6
|
-
console.log(
|
|
6
|
+
console.log("provision-bucket - Reconcile an S3 bucket for a logical bucket in the database.\nRecords the request on the bucket row via RLS; the bucket's job\ntrigger then enqueues the same storage:provision_bucket job used on\nINSERT, and repeated requests collapse into one pending job. This is\nidempotent for an already-reconciled bucket; failures become GraphQL\nerrors.\n\nUsage: provision-bucket [OPTIONS]\n");
|
|
7
7
|
process.exit(0);
|
|
8
8
|
}
|
|
9
9
|
const answers = await prompter.prompt(argv, [
|
|
@@ -3,7 +3,7 @@ import { unflattenDotNotation, buildSelectFromPaths } from '../utils';
|
|
|
3
3
|
export default async (argv, prompter, _options) => {
|
|
4
4
|
try {
|
|
5
5
|
if (argv.help || argv.h) {
|
|
6
|
-
console.log(
|
|
6
|
+
console.log("upload-files - Upload multiple files: resolves the bucket by key, creates file rows, and returns presigned PUT URLs for each. Accepts at most the bucket's `maxBulkFiles` files per call.\n\nUsage: upload-files [OPTIONS]\n");
|
|
7
7
|
process.exit(0);
|
|
8
8
|
}
|
|
9
9
|
const answers = await prompter.prompt(argv, [
|
|
@@ -3,7 +3,7 @@ import { unflattenDotNotation, buildSelectFromPaths } from '../utils';
|
|
|
3
3
|
export default async (argv, prompter, _options) => {
|
|
4
4
|
try {
|
|
5
5
|
if (argv.help || argv.h) {
|
|
6
|
-
console.log(
|
|
6
|
+
console.log("upload-platform-files - Upload multiple files: resolves the bucket by key, creates file rows, and returns presigned PUT URLs for each. Accepts at most the bucket's `maxBulkFiles` files per call.\n\nUsage: upload-platform-files [OPTIONS]\n");
|
|
7
7
|
process.exit(0);
|
|
8
8
|
}
|
|
9
9
|
const answers = await prompter.prompt(argv, [
|
|
@@ -32,7 +32,7 @@ const createCommandMap = () => ({
|
|
|
32
32
|
'upload-platform-file': uploadPlatformFileCmd,
|
|
33
33
|
'upload-platform-files': uploadPlatformFilesCmd,
|
|
34
34
|
});
|
|
35
|
-
const usage =
|
|
35
|
+
const usage = "\ncsdk <command>\n\nCommands:\n context Manage API contexts\n auth Manage authentication\n bucket bucket CRUD operations\n file file CRUD operations\n platform-bucket platformBucket CRUD operations\n platform-file platformFile CRUD operations\n files-rename filesRename\n platform-files-rename platformFilesRename\n provision-bucket Reconcile an S3 bucket for a logical bucket in the database.\nRecords the request on the bucket row via RLS; the bucket's job\ntrigger then enqueues the same storage:provision_bucket job used on\nINSERT, and repeated requests collapse into one pending job. This is\nidempotent for an already-reconciled bucket; failures become GraphQL\nerrors.\n upload-file Upload a file: resolves the bucket by key, creates the file row, and returns a presigned PUT URL.\n upload-files Upload multiple files: resolves the bucket by key, creates file rows, and returns presigned PUT URLs for each. Accepts at most the bucket's `maxBulkFiles` files per call.\n upload-platform-file Upload a file: resolves the bucket by key, creates the file row, and returns a presigned PUT URL.\n upload-platform-files Upload multiple files: resolves the bucket by key, creates file rows, and returns presigned PUT URLs for each. Accepts at most the bucket's `maxBulkFiles` files per call.\n\n --help, -h Show this help message\n --version, -v Show version\n";
|
|
36
36
|
export const commands = async (argv, prompter, options) => {
|
|
37
37
|
if (argv.help || argv.h) {
|
|
38
38
|
console.log(usage);
|
|
@@ -254,10 +254,14 @@ export interface Bucket {
|
|
|
254
254
|
isPublic?: boolean | null;
|
|
255
255
|
/** Unique bucket identifier used in S3 key paths (e.g. avatars, documents, temp) */
|
|
256
256
|
key?: string | null;
|
|
257
|
+
/** The most files one bulk-upload call accepts for this bucket. Batches larger than this are refused with BULK_UPLOAD_FILES_EXCEEDED. */
|
|
258
|
+
maxBulkFiles?: number | null;
|
|
257
259
|
/** Maximum file size in bytes allowed in this bucket (NULL = no limit, enforcement deferred) */
|
|
258
260
|
maxFileSize?: string | null;
|
|
259
261
|
/** Physical S3/MinIO bucket name recorded at provision time (NULL until the physical bucket exists) */
|
|
260
262
|
physicalName?: string | null;
|
|
263
|
+
/** When re-provisioning was last requested (provisionBucket); NULL until requested */
|
|
264
|
+
provisionRequestedAt?: string | null;
|
|
261
265
|
/** For a temp bucket, how long an unpromoted staged file survives before it is eligible for expiry. NULL on non-temp buckets; required on temp buckets. */
|
|
262
266
|
stagingTtl?: string | null;
|
|
263
267
|
/** Selector labels for capability resolution and grouping (e.g. uploads, variants, exports). A function's required bucket key is matched against these plus type. */
|
|
@@ -325,10 +329,14 @@ export interface PlatformBucket {
|
|
|
325
329
|
isPublic?: boolean | null;
|
|
326
330
|
/** Unique bucket identifier used in S3 key paths (e.g. avatars, documents, temp) */
|
|
327
331
|
key?: string | null;
|
|
332
|
+
/** The most files one bulk-upload call accepts for this bucket. Batches larger than this are refused with BULK_UPLOAD_FILES_EXCEEDED. */
|
|
333
|
+
maxBulkFiles?: number | null;
|
|
328
334
|
/** Maximum file size in bytes allowed in this bucket (NULL = no limit, enforcement deferred) */
|
|
329
335
|
maxFileSize?: string | null;
|
|
330
336
|
/** Physical S3/MinIO bucket name recorded at provision time (NULL until the physical bucket exists) */
|
|
331
337
|
physicalName?: string | null;
|
|
338
|
+
/** When re-provisioning was last requested (provisionBucket); NULL until requested */
|
|
339
|
+
provisionRequestedAt?: string | null;
|
|
332
340
|
/** For a temp bucket, how long an unpromoted staged file survives before it is eligible for expiry. NULL on non-temp buckets; required on temp buckets. */
|
|
333
341
|
stagingTtl?: string | null;
|
|
334
342
|
/** Selector labels for capability resolution and grouping (e.g. uploads, variants, exports). A function's required bucket key is matched against these plus type. */
|
|
@@ -417,8 +425,10 @@ export type BucketSelect = {
|
|
|
417
425
|
id?: boolean;
|
|
418
426
|
isPublic?: boolean;
|
|
419
427
|
key?: boolean;
|
|
428
|
+
maxBulkFiles?: boolean;
|
|
420
429
|
maxFileSize?: boolean;
|
|
421
430
|
physicalName?: boolean;
|
|
431
|
+
provisionRequestedAt?: boolean;
|
|
422
432
|
stagingTtl?: boolean;
|
|
423
433
|
tags?: boolean;
|
|
424
434
|
type?: boolean;
|
|
@@ -475,8 +485,10 @@ export type PlatformBucketSelect = {
|
|
|
475
485
|
id?: boolean;
|
|
476
486
|
isPublic?: boolean;
|
|
477
487
|
key?: boolean;
|
|
488
|
+
maxBulkFiles?: boolean;
|
|
478
489
|
maxFileSize?: boolean;
|
|
479
490
|
physicalName?: boolean;
|
|
491
|
+
provisionRequestedAt?: boolean;
|
|
480
492
|
stagingTtl?: boolean;
|
|
481
493
|
tags?: boolean;
|
|
482
494
|
type?: boolean;
|
|
@@ -566,6 +578,8 @@ export interface BucketFilter {
|
|
|
566
578
|
or?: BucketFilter[];
|
|
567
579
|
/** Filter by the object’s `physicalName` field. */
|
|
568
580
|
physicalName?: StringFilter;
|
|
581
|
+
/** Filter by the object’s `provisionRequestedAt` field. */
|
|
582
|
+
provisionRequestedAt?: DatetimeFilter;
|
|
569
583
|
/** Filter by the object’s `stagingTtl` field. */
|
|
570
584
|
stagingTtl?: IntervalFilter;
|
|
571
585
|
/** Filter by the object’s `tags` field. */
|
|
@@ -664,6 +678,8 @@ export interface PlatformBucketFilter {
|
|
|
664
678
|
platformFilesByBucketId?: PlatformBucketToManyPlatformFileFilter;
|
|
665
679
|
/** `platformFilesByBucketId` exist. */
|
|
666
680
|
platformFilesByBucketIdExist?: boolean;
|
|
681
|
+
/** Filter by the object’s `provisionRequestedAt` field. */
|
|
682
|
+
provisionRequestedAt?: DatetimeFilter;
|
|
667
683
|
/** Filter by the object’s `stagingTtl` field. */
|
|
668
684
|
stagingTtl?: IntervalFilter;
|
|
669
685
|
/** Filter by the object’s `tags` field. */
|
|
@@ -717,9 +733,9 @@ export interface PlatformFileFilter {
|
|
|
717
733
|
/** Filter by the object’s `upload` field. */
|
|
718
734
|
upload?: ConstructiveInternalTypeUploadFilter;
|
|
719
735
|
}
|
|
720
|
-
export type BucketOrderBy = 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' | 'ALLOWED_MIME_TYPES_ASC' | 'ALLOWED_MIME_TYPES_DESC' | 'ALLOWED_ORIGINS_ASC' | 'ALLOWED_ORIGINS_DESC' | 'ALLOW_CUSTOM_KEYS_ASC' | 'ALLOW_CUSTOM_KEYS_DESC' | 'CREATED_AT_ASC' | 'CREATED_AT_DESC' | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' | 'DESCRIPTION_ASC' | 'DESCRIPTION_DESC' | 'DESTINATION_BUCKET_ID_ASC' | 'DESTINATION_BUCKET_ID_DESC' | 'ID_ASC' | 'ID_DESC' | 'IS_PUBLIC_ASC' | 'IS_PUBLIC_DESC' | 'KEY_ASC' | 'KEY_DESC' | 'MAX_FILE_SIZE_ASC' | 'MAX_FILE_SIZE_DESC' | 'NATURAL' | 'PHYSICAL_NAME_ASC' | 'PHYSICAL_NAME_DESC' | 'PRIMARY_KEY_ASC' | 'PRIMARY_KEY_DESC' | 'STAGING_TTL_ASC' | 'STAGING_TTL_DESC' | 'TAGS_ASC' | 'TAGS_DESC' | 'TYPE_ASC' | 'TYPE_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC';
|
|
736
|
+
export type BucketOrderBy = 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' | 'ALLOWED_MIME_TYPES_ASC' | 'ALLOWED_MIME_TYPES_DESC' | 'ALLOWED_ORIGINS_ASC' | 'ALLOWED_ORIGINS_DESC' | 'ALLOW_CUSTOM_KEYS_ASC' | 'ALLOW_CUSTOM_KEYS_DESC' | 'CREATED_AT_ASC' | 'CREATED_AT_DESC' | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' | 'DESCRIPTION_ASC' | 'DESCRIPTION_DESC' | 'DESTINATION_BUCKET_ID_ASC' | 'DESTINATION_BUCKET_ID_DESC' | 'ID_ASC' | 'ID_DESC' | 'IS_PUBLIC_ASC' | 'IS_PUBLIC_DESC' | 'KEY_ASC' | 'KEY_DESC' | 'MAX_FILE_SIZE_ASC' | 'MAX_FILE_SIZE_DESC' | 'NATURAL' | 'PHYSICAL_NAME_ASC' | 'PHYSICAL_NAME_DESC' | 'PRIMARY_KEY_ASC' | 'PRIMARY_KEY_DESC' | 'PROVISION_REQUESTED_AT_ASC' | 'PROVISION_REQUESTED_AT_DESC' | 'STAGING_TTL_ASC' | 'STAGING_TTL_DESC' | 'TAGS_ASC' | 'TAGS_DESC' | 'TYPE_ASC' | 'TYPE_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC';
|
|
721
737
|
export type FileOrderBy = 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' | 'BUCKET_ID_ASC' | 'BUCKET_ID_DESC' | 'CONTENT_HASH_ASC' | 'CONTENT_HASH_DESC' | 'CREATED_AT_ASC' | 'CREATED_AT_DESC' | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' | 'DESCRIPTION_ASC' | 'DESCRIPTION_DESC' | 'EXPIRY_ENQUEUED_AT_ASC' | 'EXPIRY_ENQUEUED_AT_DESC' | 'FILENAME_ASC' | 'FILENAME_DESC' | 'ID_ASC' | 'ID_DESC' | 'IS_PUBLIC_ASC' | 'IS_PUBLIC_DESC' | 'KEY_ASC' | 'KEY_DESC' | 'MIME_TYPE_ASC' | 'MIME_TYPE_DESC' | 'NATURAL' | 'PRIMARY_KEY_ASC' | 'PRIMARY_KEY_DESC' | 'PROMOTED_AT_ASC' | 'PROMOTED_AT_DESC' | 'SIZE_ASC' | 'SIZE_DESC' | 'STATUS_ASC' | 'STATUS_DESC' | 'TAGS_ASC' | 'TAGS_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC' | 'UPLOAD_ASC' | 'UPLOAD_DESC';
|
|
722
|
-
export type PlatformBucketOrderBy = 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' | 'ALLOWED_MIME_TYPES_ASC' | 'ALLOWED_MIME_TYPES_DESC' | 'ALLOWED_ORIGINS_ASC' | 'ALLOWED_ORIGINS_DESC' | 'ALLOW_CUSTOM_KEYS_ASC' | 'ALLOW_CUSTOM_KEYS_DESC' | 'CREATED_AT_ASC' | 'CREATED_AT_DESC' | 'DESCRIPTION_ASC' | 'DESCRIPTION_DESC' | 'DESTINATION_BUCKET_ID_ASC' | 'DESTINATION_BUCKET_ID_DESC' | 'ID_ASC' | 'ID_DESC' | 'IS_PUBLIC_ASC' | 'IS_PUBLIC_DESC' | 'KEY_ASC' | 'KEY_DESC' | 'MAX_FILE_SIZE_ASC' | 'MAX_FILE_SIZE_DESC' | 'NATURAL' | 'PHYSICAL_NAME_ASC' | 'PHYSICAL_NAME_DESC' | 'PRIMARY_KEY_ASC' | 'PRIMARY_KEY_DESC' | 'STAGING_TTL_ASC' | 'STAGING_TTL_DESC' | 'TAGS_ASC' | 'TAGS_DESC' | 'TYPE_ASC' | 'TYPE_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC';
|
|
738
|
+
export type PlatformBucketOrderBy = 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' | 'ALLOWED_MIME_TYPES_ASC' | 'ALLOWED_MIME_TYPES_DESC' | 'ALLOWED_ORIGINS_ASC' | 'ALLOWED_ORIGINS_DESC' | 'ALLOW_CUSTOM_KEYS_ASC' | 'ALLOW_CUSTOM_KEYS_DESC' | 'CREATED_AT_ASC' | 'CREATED_AT_DESC' | 'DESCRIPTION_ASC' | 'DESCRIPTION_DESC' | 'DESTINATION_BUCKET_ID_ASC' | 'DESTINATION_BUCKET_ID_DESC' | 'ID_ASC' | 'ID_DESC' | 'IS_PUBLIC_ASC' | 'IS_PUBLIC_DESC' | 'KEY_ASC' | 'KEY_DESC' | 'MAX_FILE_SIZE_ASC' | 'MAX_FILE_SIZE_DESC' | 'NATURAL' | 'PHYSICAL_NAME_ASC' | 'PHYSICAL_NAME_DESC' | 'PRIMARY_KEY_ASC' | 'PRIMARY_KEY_DESC' | 'PROVISION_REQUESTED_AT_ASC' | 'PROVISION_REQUESTED_AT_DESC' | 'STAGING_TTL_ASC' | 'STAGING_TTL_DESC' | 'TAGS_ASC' | 'TAGS_DESC' | 'TYPE_ASC' | 'TYPE_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC';
|
|
723
739
|
export type PlatformFileOrderBy = 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' | 'BUCKET_ID_ASC' | 'BUCKET_ID_DESC' | 'CONTENT_HASH_ASC' | 'CONTENT_HASH_DESC' | 'CREATED_AT_ASC' | 'CREATED_AT_DESC' | 'DESCRIPTION_ASC' | 'DESCRIPTION_DESC' | 'EXPIRY_ENQUEUED_AT_ASC' | 'EXPIRY_ENQUEUED_AT_DESC' | 'FILENAME_ASC' | 'FILENAME_DESC' | 'ID_ASC' | 'ID_DESC' | 'IS_PUBLIC_ASC' | 'IS_PUBLIC_DESC' | 'KEY_ASC' | 'KEY_DESC' | 'MIME_TYPE_ASC' | 'MIME_TYPE_DESC' | 'NATURAL' | 'PRIMARY_KEY_ASC' | 'PRIMARY_KEY_DESC' | 'PROMOTED_AT_ASC' | 'PROMOTED_AT_DESC' | 'SIZE_ASC' | 'SIZE_DESC' | 'STATUS_ASC' | 'STATUS_DESC' | 'TAGS_ASC' | 'TAGS_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC' | 'UPLOAD_ASC' | 'UPLOAD_DESC';
|
|
724
740
|
export interface CreateBucketInput {
|
|
725
741
|
clientMutationId?: string;
|
|
@@ -735,6 +751,7 @@ export interface CreateBucketInput {
|
|
|
735
751
|
key: string;
|
|
736
752
|
maxFileSize?: string;
|
|
737
753
|
physicalName?: string;
|
|
754
|
+
provisionRequestedAt?: string;
|
|
738
755
|
stagingTtl?: IntervalInput;
|
|
739
756
|
tags?: string[];
|
|
740
757
|
type?: BucketType;
|
|
@@ -752,6 +769,7 @@ export interface BucketPatch {
|
|
|
752
769
|
key?: string | null;
|
|
753
770
|
maxFileSize?: string | null;
|
|
754
771
|
physicalName?: string | null;
|
|
772
|
+
provisionRequestedAt?: string | null;
|
|
755
773
|
stagingTtl?: IntervalInput | null;
|
|
756
774
|
tags?: string[] | null;
|
|
757
775
|
type?: BucketType | null;
|
|
@@ -823,6 +841,7 @@ export interface CreatePlatformBucketInput {
|
|
|
823
841
|
key: string;
|
|
824
842
|
maxFileSize?: string;
|
|
825
843
|
physicalName?: string;
|
|
844
|
+
provisionRequestedAt?: string;
|
|
826
845
|
stagingTtl?: IntervalInput;
|
|
827
846
|
tags?: string[];
|
|
828
847
|
type?: BucketType;
|
|
@@ -839,6 +858,7 @@ export interface PlatformBucketPatch {
|
|
|
839
858
|
key?: string | null;
|
|
840
859
|
maxFileSize?: string | null;
|
|
841
860
|
physicalName?: string | null;
|
|
861
|
+
provisionRequestedAt?: string | null;
|
|
842
862
|
stagingTtl?: IntervalInput | null;
|
|
843
863
|
tags?: string[] | null;
|
|
844
864
|
type?: BucketType | null;
|
|
@@ -1136,6 +1156,8 @@ export interface BucketInput {
|
|
|
1136
1156
|
maxFileSize?: string;
|
|
1137
1157
|
/** Physical S3/MinIO bucket name recorded at provision time (NULL until the physical bucket exists) */
|
|
1138
1158
|
physicalName?: string;
|
|
1159
|
+
/** When re-provisioning was last requested (provisionBucket); NULL until requested */
|
|
1160
|
+
provisionRequestedAt?: string;
|
|
1139
1161
|
/** For a temp bucket, how long an unpromoted staged file survives before it is eligible for expiry. NULL on non-temp buckets; required on temp buckets. */
|
|
1140
1162
|
stagingTtl?: IntervalInput;
|
|
1141
1163
|
/** Selector labels for capability resolution and grouping (e.g. uploads, variants, exports). A function's required bucket key is matched against these plus type. */
|
|
@@ -1219,6 +1241,8 @@ export interface PlatformBucketInput {
|
|
|
1219
1241
|
maxFileSize?: string;
|
|
1220
1242
|
/** Physical S3/MinIO bucket name recorded at provision time (NULL until the physical bucket exists) */
|
|
1221
1243
|
physicalName?: string;
|
|
1244
|
+
/** When re-provisioning was last requested (provisionBucket); NULL until requested */
|
|
1245
|
+
provisionRequestedAt?: string;
|
|
1222
1246
|
/** For a temp bucket, how long an unpromoted staged file survives before it is eligible for expiry. NULL on non-temp buckets; required on temp buckets. */
|
|
1223
1247
|
stagingTtl?: IntervalInput;
|
|
1224
1248
|
/** Selector labels for capability resolution and grouping (e.g. uploads, variants, exports). A function's required bucket key is matched against these plus type. */
|
|
@@ -1329,6 +1353,8 @@ export interface BucketFilter {
|
|
|
1329
1353
|
or?: BucketFilter[];
|
|
1330
1354
|
/** Filter by the object’s `physicalName` field. */
|
|
1331
1355
|
physicalName?: StringFilter;
|
|
1356
|
+
/** Filter by the object’s `provisionRequestedAt` field. */
|
|
1357
|
+
provisionRequestedAt?: DatetimeFilter;
|
|
1332
1358
|
/** Filter by the object’s `stagingTtl` field. */
|
|
1333
1359
|
stagingTtl?: IntervalFilter;
|
|
1334
1360
|
/** Filter by the object’s `tags` field. */
|
|
@@ -1429,6 +1455,8 @@ export interface PlatformBucketFilter {
|
|
|
1429
1455
|
platformFilesByBucketId?: PlatformBucketToManyPlatformFileFilter;
|
|
1430
1456
|
/** `platformFilesByBucketId` exist. */
|
|
1431
1457
|
platformFilesByBucketIdExist?: boolean;
|
|
1458
|
+
/** Filter by the object’s `provisionRequestedAt` field. */
|
|
1459
|
+
provisionRequestedAt?: DatetimeFilter;
|
|
1432
1460
|
/** Filter by the object’s `stagingTtl` field. */
|
|
1433
1461
|
stagingTtl?: IntervalFilter;
|
|
1434
1462
|
/** Filter by the object’s `tags` field. */
|
|
@@ -1728,19 +1756,19 @@ export type PlatformFilesRenamePayloadSelect = {
|
|
|
1728
1756
|
};
|
|
1729
1757
|
};
|
|
1730
1758
|
export interface ProvisionBucketPayload {
|
|
1731
|
-
/** The logical bucket row
|
|
1759
|
+
/** The logical bucket row whose reconciliation was requested. */
|
|
1732
1760
|
bucketId: string;
|
|
1733
1761
|
bucketKey: string;
|
|
1734
|
-
/** The reconciler job enqueued to provision this bucket. */
|
|
1735
|
-
jobId: string;
|
|
1736
1762
|
/** The physical bucket name already recorded, or null when reconciliation has not completed. */
|
|
1737
1763
|
physicalName?: string | null;
|
|
1764
|
+
/** When reconciliation was last requested for this bucket. */
|
|
1765
|
+
provisionRequestedAt: string;
|
|
1738
1766
|
}
|
|
1739
1767
|
export type ProvisionBucketPayloadSelect = {
|
|
1740
1768
|
bucketId?: boolean;
|
|
1741
1769
|
bucketKey?: boolean;
|
|
1742
|
-
jobId?: boolean;
|
|
1743
1770
|
physicalName?: boolean;
|
|
1771
|
+
provisionRequestedAt?: boolean;
|
|
1744
1772
|
};
|
|
1745
1773
|
export interface UploadFilePayload {
|
|
1746
1774
|
/** Whether this file was deduplicated (content already exists) */
|
|
@@ -16,10 +16,11 @@ export interface PlatformFilesRenameVariables {
|
|
|
16
16
|
/**
|
|
17
17
|
* Variables for provisionBucket
|
|
18
18
|
* Reconcile an S3 bucket for a logical bucket in the database.
|
|
19
|
-
|
|
20
|
-
storage:provision_bucket job used
|
|
21
|
-
|
|
22
|
-
GraphQL
|
|
19
|
+
Records the request on the bucket row via RLS; the bucket's job
|
|
20
|
+
trigger then enqueues the same storage:provision_bucket job used on
|
|
21
|
+
INSERT, and repeated requests collapse into one pending job. This is
|
|
22
|
+
idempotent for an already-reconciled bucket; failures become GraphQL
|
|
23
|
+
errors.
|
|
23
24
|
*/
|
|
24
25
|
export interface ProvisionBucketVariables {
|
|
25
26
|
input: ProvisionBucketInput;
|
|
@@ -33,7 +34,7 @@ export interface UploadFileVariables {
|
|
|
33
34
|
}
|
|
34
35
|
/**
|
|
35
36
|
* Variables for uploadFiles
|
|
36
|
-
* Upload multiple files: resolves the bucket by key, creates file rows, and returns presigned PUT URLs for each.
|
|
37
|
+
* Upload multiple files: resolves the bucket by key, creates file rows, and returns presigned PUT URLs for each. Accepts at most the bucket's `maxBulkFiles` files per call.
|
|
37
38
|
*/
|
|
38
39
|
export interface UploadFilesVariables {
|
|
39
40
|
input: UploadFileBulkInput;
|
|
@@ -47,7 +48,7 @@ export interface UploadPlatformFileVariables {
|
|
|
47
48
|
}
|
|
48
49
|
/**
|
|
49
50
|
* Variables for uploadPlatformFiles
|
|
50
|
-
* Upload multiple files: resolves the bucket by key, creates file rows, and returns presigned PUT URLs for each.
|
|
51
|
+
* Upload multiple files: resolves the bucket by key, creates file rows, and returns presigned PUT URLs for each. Accepts at most the bucket's `maxBulkFiles` files per call.
|
|
51
52
|
*/
|
|
52
53
|
export interface UploadPlatformFilesVariables {
|
|
53
54
|
input: UploadPlatformFileBulkInput;
|
|
@@ -3,7 +3,7 @@ import { unflattenDotNotation, buildSelectFromPaths } from '../utils';
|
|
|
3
3
|
export default async (argv, prompter, _options) => {
|
|
4
4
|
try {
|
|
5
5
|
if (argv.help || argv.h) {
|
|
6
|
-
console.log(
|
|
6
|
+
console.log("provision-bucket - Reconcile an S3 bucket for a logical bucket in the database.\nRecords the request on the bucket row via RLS; the bucket's job\ntrigger then enqueues the same storage:provision_bucket job used on\nINSERT, and repeated requests collapse into one pending job. This is\nidempotent for an already-reconciled bucket; failures become GraphQL\nerrors.\n\nUsage: provision-bucket [OPTIONS]\n");
|
|
7
7
|
process.exit(0);
|
|
8
8
|
}
|
|
9
9
|
const answers = await prompter.prompt(argv, [
|
|
@@ -60,7 +60,7 @@ const createCommandMap = () => ({
|
|
|
60
60
|
'seed-org-limit-caps-defaults': seedOrgLimitCapsDefaultsCmd,
|
|
61
61
|
'seed-org-limit-defaults': seedOrgLimitDefaultsCmd,
|
|
62
62
|
});
|
|
63
|
-
const usage =
|
|
63
|
+
const usage = "\ncsdk <command>\n\nCommands:\n context Manage API contexts\n auth Manage authentication\n app-limit-cap appLimitCap CRUD operations\n app-limit-caps-default appLimitCapsDefault CRUD operations\n app-limit appLimit CRUD operations\n app-limit-credit-code appLimitCreditCode CRUD operations\n app-limit-credit-code-item appLimitCreditCodeItem CRUD operations\n app-limit-credit appLimitCredit CRUD operations\n app-limit-credit-redemption appLimitCreditRedemption CRUD operations\n app-limit-default appLimitDefault CRUD operations\n app-limit-event appLimitEvent CRUD operations\n app-limit-warning appLimitWarning CRUD operations\n org-limit-aggregate orgLimitAggregate CRUD operations\n org-limit-cap orgLimitCap CRUD operations\n org-limit-caps-default orgLimitCapsDefault CRUD operations\n org-limit orgLimit CRUD operations\n org-limit-credit orgLimitCredit CRUD operations\n org-limit-default orgLimitDefault CRUD operations\n org-limit-event orgLimitEvent CRUD operations\n org-limit-warning orgLimitWarning CRUD operations\n capture-app-limit-defaults captureAppLimitDefaults\n capture-org-limit-defaults captureOrgLimitDefaults\n provision-bucket Reconcile an S3 bucket for a logical bucket in the database.\nRecords the request on the bucket row via RLS; the bucket's job\ntrigger then enqueues the same storage:provision_bucket job used on\nINSERT, and repeated requests collapse into one pending job. This is\nidempotent for an already-reconciled bucket; failures become GraphQL\nerrors.\n seed-app-limit-caps-defaults seedAppLimitCapsDefaults\n seed-app-limit-defaults seedAppLimitDefaults\n seed-org-limit-caps-defaults seedOrgLimitCapsDefaults\n seed-org-limit-defaults seedOrgLimitDefaults\n\n --help, -h Show this help message\n --version, -v Show version\n";
|
|
64
64
|
export const commands = async (argv, prompter, options) => {
|
|
65
65
|
if (argv.help || argv.h) {
|
|
66
66
|
console.log(usage);
|
|
@@ -2527,19 +2527,19 @@ export interface DatetimeFilter {
|
|
|
2527
2527
|
notIn?: string[];
|
|
2528
2528
|
}
|
|
2529
2529
|
export interface ProvisionBucketPayload {
|
|
2530
|
-
/** The logical bucket row
|
|
2530
|
+
/** The logical bucket row whose reconciliation was requested. */
|
|
2531
2531
|
bucketId: string;
|
|
2532
2532
|
bucketKey: string;
|
|
2533
|
-
/** The reconciler job enqueued to provision this bucket. */
|
|
2534
|
-
jobId: string;
|
|
2535
2533
|
/** The physical bucket name already recorded, or null when reconciliation has not completed. */
|
|
2536
2534
|
physicalName?: string | null;
|
|
2535
|
+
/** When reconciliation was last requested for this bucket. */
|
|
2536
|
+
provisionRequestedAt: string;
|
|
2537
2537
|
}
|
|
2538
2538
|
export type ProvisionBucketPayloadSelect = {
|
|
2539
2539
|
bucketId?: boolean;
|
|
2540
2540
|
bucketKey?: boolean;
|
|
2541
|
-
jobId?: boolean;
|
|
2542
2541
|
physicalName?: boolean;
|
|
2542
|
+
provisionRequestedAt?: boolean;
|
|
2543
2543
|
};
|
|
2544
2544
|
export interface SeedAppLimitCapsDefaultsPayload {
|
|
2545
2545
|
clientMutationId?: string | null;
|
|
@@ -10,10 +10,11 @@ import type { ProvisionBucketInput, SeedAppLimitCapsDefaultsInput, SeedAppLimitD
|
|
|
10
10
|
/**
|
|
11
11
|
* Variables for provisionBucket
|
|
12
12
|
* Reconcile an S3 bucket for a logical bucket in the database.
|
|
13
|
-
|
|
14
|
-
storage:provision_bucket job used
|
|
15
|
-
|
|
16
|
-
GraphQL
|
|
13
|
+
Records the request on the bucket row via RLS; the bucket's job
|
|
14
|
+
trigger then enqueues the same storage:provision_bucket job used on
|
|
15
|
+
INSERT, and repeated requests collapse into one pending job. This is
|
|
16
|
+
idempotent for an already-reconciled bucket; failures become GraphQL
|
|
17
|
+
errors.
|
|
17
18
|
*/
|
|
18
19
|
export interface ProvisionBucketVariables {
|
|
19
20
|
input: ProvisionBucketInput;
|
|
@@ -5,7 +5,7 @@ const utils_1 = require("../utils");
|
|
|
5
5
|
exports.default = async (argv, prompter, _options) => {
|
|
6
6
|
try {
|
|
7
7
|
if (argv.help || argv.h) {
|
|
8
|
-
console.log(
|
|
8
|
+
console.log("provision-bucket - Reconcile an S3 bucket for a logical bucket in the database.\nRecords the request on the bucket row via RLS; the bucket's job\ntrigger then enqueues the same storage:provision_bucket job used on\nINSERT, and repeated requests collapse into one pending job. This is\nidempotent for an already-reconciled bucket; failures become GraphQL\nerrors.\n\nUsage: provision-bucket [OPTIONS]\n");
|
|
9
9
|
process.exit(0);
|
|
10
10
|
}
|
|
11
11
|
const answers = await prompter.prompt(argv, [
|
package/infra/cli/commands.js
CHANGED
|
@@ -52,7 +52,7 @@ const createCommandMap = () => ({
|
|
|
52
52
|
'platform-infra-set-many-and-commit': platform_infra_set_many_and_commit_1.default,
|
|
53
53
|
'provision-bucket': provision_bucket_1.default,
|
|
54
54
|
});
|
|
55
|
-
const usage =
|
|
55
|
+
const usage = "\ncsdk <command>\n\nCommands:\n context Manage API contexts\n auth Manage authentication\n content-preset contentPreset CRUD operations\n db-preset dbPreset CRUD operations\n namespace namespace CRUD operations\n namespace-event namespaceEvent CRUD operations\n platform-infra-commit platformInfraCommit CRUD operations\n platform-infra-get-all-tree-nodes-record platformInfraGetAllTreeNodesRecord CRUD operations\n platform-infra-object platformInfraObject CRUD operations\n platform-infra-ref platformInfraRef CRUD operations\n platform-infra-store platformInfraStore CRUD operations\n platform-namespace platformNamespace CRUD operations\n platform-namespace-event platformNamespaceEvent CRUD operations\n platform-infra-init-empty-repo platformInfraInitEmptyRepo\n platform-infra-insert-node-at-path platformInfraInsertNodeAtPath\n platform-infra-insert-nodes-at-paths platformInfraInsertNodesAtPaths\n platform-infra-set-and-commit platformInfraSetAndCommit\n platform-infra-set-data-at-path platformInfraSetDataAtPath\n platform-infra-set-many-and-commit platformInfraSetManyAndCommit\n provision-bucket Reconcile an S3 bucket for a logical bucket in the database.\nRecords the request on the bucket row via RLS; the bucket's job\ntrigger then enqueues the same storage:provision_bucket job used on\nINSERT, and repeated requests collapse into one pending job. This is\nidempotent for an already-reconciled bucket; failures become GraphQL\nerrors.\n\n --help, -h Show this help message\n --version, -v Show version\n";
|
|
56
56
|
const commands = async (argv, prompter, options) => {
|
|
57
57
|
if (argv.help || argv.h) {
|
|
58
58
|
console.log(usage);
|