windmill-client 1.815.0 → 1.817.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/dist/core/OpenAPI.mjs +1 -1
- package/dist/index.js +197 -20
- package/dist/services.gen.d.ts +101 -12
- package/dist/services.gen.mjs +196 -19
- package/dist/types.gen.d.ts +503 -35
- package/package.json +1 -1
package/dist/core/OpenAPI.mjs
CHANGED
package/dist/index.js
CHANGED
|
@@ -126,7 +126,7 @@ const OpenAPI = {
|
|
|
126
126
|
PASSWORD: void 0,
|
|
127
127
|
TOKEN: getEnv$1("WM_TOKEN"),
|
|
128
128
|
USERNAME: void 0,
|
|
129
|
-
VERSION: "1.
|
|
129
|
+
VERSION: "1.817.0",
|
|
130
130
|
WITH_CREDENTIALS: !getEnv$1("WM_RAW_APP"),
|
|
131
131
|
interceptors: {
|
|
132
132
|
request: new Interceptors(),
|
|
@@ -725,20 +725,6 @@ var UserService = class {
|
|
|
725
725
|
});
|
|
726
726
|
}
|
|
727
727
|
/**
|
|
728
|
-
* consume a single-use login link from its confirmation page, set the session cookie and answer where to go
|
|
729
|
-
* @param data The data for the request.
|
|
730
|
-
* @param data.token
|
|
731
|
-
* @returns unknown the post-login destination, or /user/login_link_expired when the link is used, expired or unknown
|
|
732
|
-
* @throws ApiError
|
|
733
|
-
*/
|
|
734
|
-
static confirmLoginLink(data) {
|
|
735
|
-
return request(OpenAPI, {
|
|
736
|
-
method: "POST",
|
|
737
|
-
url: "/auth/login_link/{token}",
|
|
738
|
-
path: { token: data.token }
|
|
739
|
-
});
|
|
740
|
-
}
|
|
741
|
-
/**
|
|
742
728
|
* reset password using token
|
|
743
729
|
* @param data The data for the request.
|
|
744
730
|
* @param data.requestBody token and new password
|
|
@@ -2585,6 +2571,77 @@ var WorkspaceService = class {
|
|
|
2585
2571
|
});
|
|
2586
2572
|
}
|
|
2587
2573
|
/**
|
|
2574
|
+
* get the workspace's deploy target on another instance, and the caller's connection to it
|
|
2575
|
+
* Once connected, deploy calls aimed at the target go through
|
|
2576
|
+
* `/w/{workspace}/remote_deploy/proxy/{proxy_key}/{route}`, which forwards any method to
|
|
2577
|
+
* `{base_url}/api/w/{target workspace}/{route}` with the caller's stored token.
|
|
2578
|
+
*
|
|
2579
|
+
* @param data The data for the request.
|
|
2580
|
+
* @param data.workspace
|
|
2581
|
+
* @returns RemoteDeployStatus remote deploy target and the caller's connection to it
|
|
2582
|
+
* @throws ApiError
|
|
2583
|
+
*/
|
|
2584
|
+
static getRemoteDeployTarget(data) {
|
|
2585
|
+
return request(OpenAPI, {
|
|
2586
|
+
method: "GET",
|
|
2587
|
+
url: "/w/{workspace}/remote_deploy/target",
|
|
2588
|
+
path: { workspace: data.workspace }
|
|
2589
|
+
});
|
|
2590
|
+
}
|
|
2591
|
+
/**
|
|
2592
|
+
* set or clear the workspace's deploy target on another instance
|
|
2593
|
+
* Changing the target drops every token stored for the previous one.
|
|
2594
|
+
* @param data The data for the request.
|
|
2595
|
+
* @param data.workspace
|
|
2596
|
+
* @param data.requestBody
|
|
2597
|
+
* @returns string status
|
|
2598
|
+
* @throws ApiError
|
|
2599
|
+
*/
|
|
2600
|
+
static setRemoteDeployTarget(data) {
|
|
2601
|
+
return request(OpenAPI, {
|
|
2602
|
+
method: "POST",
|
|
2603
|
+
url: "/w/{workspace}/remote_deploy/target",
|
|
2604
|
+
path: { workspace: data.workspace },
|
|
2605
|
+
body: data.requestBody,
|
|
2606
|
+
mediaType: "application/json"
|
|
2607
|
+
});
|
|
2608
|
+
}
|
|
2609
|
+
/**
|
|
2610
|
+
* store the caller's own token for the remote deploy target
|
|
2611
|
+
* The token is checked against the target's whoami before it is stored. `target` names the
|
|
2612
|
+
* target the token was obtained for, and the request is refused if the workspace now points
|
|
2613
|
+
* elsewhere, so a token is never sent to an instance it was not meant for.
|
|
2614
|
+
*
|
|
2615
|
+
* @param data The data for the request.
|
|
2616
|
+
* @param data.workspace
|
|
2617
|
+
* @param data.requestBody
|
|
2618
|
+
* @returns RemoteDeployConnection the stored connection
|
|
2619
|
+
* @throws ApiError
|
|
2620
|
+
*/
|
|
2621
|
+
static connectRemoteDeploy(data) {
|
|
2622
|
+
return request(OpenAPI, {
|
|
2623
|
+
method: "POST",
|
|
2624
|
+
url: "/w/{workspace}/remote_deploy/connect",
|
|
2625
|
+
path: { workspace: data.workspace },
|
|
2626
|
+
body: data.requestBody,
|
|
2627
|
+
mediaType: "application/json"
|
|
2628
|
+
});
|
|
2629
|
+
}
|
|
2630
|
+
/**
|
|
2631
|
+
* forget the caller's token for the remote deploy target
|
|
2632
|
+
* @param data The data for the request.
|
|
2633
|
+
* @param data.workspace
|
|
2634
|
+
* @returns string status
|
|
2635
|
+
* @throws ApiError
|
|
2636
|
+
*/
|
|
2637
|
+
static disconnectRemoteDeploy(data) {
|
|
2638
|
+
return request(OpenAPI, {
|
|
2639
|
+
method: "POST",
|
|
2640
|
+
url: "/w/{workspace}/remote_deploy/disconnect",
|
|
2641
|
+
path: { workspace: data.workspace }
|
|
2642
|
+
});
|
|
2643
|
+
}
|
|
2644
|
+
/**
|
|
2588
2645
|
* get if workspace is premium
|
|
2589
2646
|
* @param data The data for the request.
|
|
2590
2647
|
* @param data.workspace
|
|
@@ -3155,6 +3212,74 @@ var WorkspaceService = class {
|
|
|
3155
3212
|
});
|
|
3156
3213
|
}
|
|
3157
3214
|
/**
|
|
3215
|
+
* read the owner and grants of an instance data table's database, schema or table
|
|
3216
|
+
* @param data The data for the request.
|
|
3217
|
+
* @param data.workspace
|
|
3218
|
+
* @param data.datatableName
|
|
3219
|
+
* @param data.kind
|
|
3220
|
+
* @param data.schema
|
|
3221
|
+
* @param data.table
|
|
3222
|
+
* @returns DatatableAclInfo owner and grants
|
|
3223
|
+
* @throws ApiError
|
|
3224
|
+
*/
|
|
3225
|
+
static getDatatableAcl(data) {
|
|
3226
|
+
return request(OpenAPI, {
|
|
3227
|
+
method: "GET",
|
|
3228
|
+
url: "/w/{workspace}/workspaces/datatable_acl/{datatable_name}",
|
|
3229
|
+
path: {
|
|
3230
|
+
workspace: data.workspace,
|
|
3231
|
+
datatable_name: data.datatableName
|
|
3232
|
+
},
|
|
3233
|
+
query: {
|
|
3234
|
+
kind: data.kind,
|
|
3235
|
+
schema: data.schema,
|
|
3236
|
+
table: data.table
|
|
3237
|
+
}
|
|
3238
|
+
});
|
|
3239
|
+
}
|
|
3240
|
+
/**
|
|
3241
|
+
* preview the SQL an ownership or grant change would run (data table administrators only)
|
|
3242
|
+
* @param data The data for the request.
|
|
3243
|
+
* @param data.workspace
|
|
3244
|
+
* @param data.datatableName
|
|
3245
|
+
* @param data.requestBody
|
|
3246
|
+
* @returns AclPlan statements that would run, in a single transaction
|
|
3247
|
+
* @throws ApiError
|
|
3248
|
+
*/
|
|
3249
|
+
static planDatatableAcl(data) {
|
|
3250
|
+
return request(OpenAPI, {
|
|
3251
|
+
method: "POST",
|
|
3252
|
+
url: "/w/{workspace}/workspaces/datatable_acl/{datatable_name}/plan",
|
|
3253
|
+
path: {
|
|
3254
|
+
workspace: data.workspace,
|
|
3255
|
+
datatable_name: data.datatableName
|
|
3256
|
+
},
|
|
3257
|
+
body: data.requestBody,
|
|
3258
|
+
mediaType: "application/json"
|
|
3259
|
+
});
|
|
3260
|
+
}
|
|
3261
|
+
/**
|
|
3262
|
+
* run an ownership or grant change exactly as planned (data table administrators only)
|
|
3263
|
+
* @param data The data for the request.
|
|
3264
|
+
* @param data.workspace
|
|
3265
|
+
* @param data.datatableName
|
|
3266
|
+
* @param data.requestBody
|
|
3267
|
+
* @returns string change applied
|
|
3268
|
+
* @throws ApiError
|
|
3269
|
+
*/
|
|
3270
|
+
static applyDatatableAcl(data) {
|
|
3271
|
+
return request(OpenAPI, {
|
|
3272
|
+
method: "POST",
|
|
3273
|
+
url: "/w/{workspace}/workspaces/datatable_acl/{datatable_name}/apply",
|
|
3274
|
+
path: {
|
|
3275
|
+
workspace: data.workspace,
|
|
3276
|
+
datatable_name: data.datatableName
|
|
3277
|
+
},
|
|
3278
|
+
body: data.requestBody,
|
|
3279
|
+
mediaType: "application/json"
|
|
3280
|
+
});
|
|
3281
|
+
}
|
|
3282
|
+
/**
|
|
3158
3283
|
* list the data table roles the caller may connect as
|
|
3159
3284
|
* @param data The data for the request.
|
|
3160
3285
|
* @param data.workspace
|
|
@@ -3208,6 +3333,9 @@ var WorkspaceService = class {
|
|
|
3208
3333
|
* list tables of all connected Datatables
|
|
3209
3334
|
* @param data The data for the request.
|
|
3210
3335
|
* @param data.workspace
|
|
3336
|
+
* @param data.datatableName list only this data table; each listed data table opens a connection to its database
|
|
3337
|
+
* @param data.roleFor the data table `role` applies to; every other one is listed as its default role
|
|
3338
|
+
* @param data.role the role to list `role_for` as; refused, in that entry's `error`, if the caller may not use it
|
|
3211
3339
|
* @returns DataTableTables table metadata of all datatables
|
|
3212
3340
|
* @throws ApiError
|
|
3213
3341
|
*/
|
|
@@ -3215,7 +3343,12 @@ var WorkspaceService = class {
|
|
|
3215
3343
|
return request(OpenAPI, {
|
|
3216
3344
|
method: "GET",
|
|
3217
3345
|
url: "/w/{workspace}/workspaces/list_datatable_tables",
|
|
3218
|
-
path: { workspace: data.workspace }
|
|
3346
|
+
path: { workspace: data.workspace },
|
|
3347
|
+
query: {
|
|
3348
|
+
datatable_name: data.datatableName,
|
|
3349
|
+
role_for: data.roleFor,
|
|
3350
|
+
role: data.role
|
|
3351
|
+
}
|
|
3219
3352
|
});
|
|
3220
3353
|
}
|
|
3221
3354
|
/**
|
|
@@ -3225,6 +3358,7 @@ var WorkspaceService = class {
|
|
|
3225
3358
|
* @param data.datatableName
|
|
3226
3359
|
* @param data.schemaName
|
|
3227
3360
|
* @param data.tableName
|
|
3361
|
+
* @param data.role the data table role to read the table as; defaults to the data table's default role
|
|
3228
3362
|
* @returns DataTableTableSchema schema of one datatable table
|
|
3229
3363
|
* @throws ApiError
|
|
3230
3364
|
*/
|
|
@@ -3236,7 +3370,8 @@ var WorkspaceService = class {
|
|
|
3236
3370
|
query: {
|
|
3237
3371
|
datatable_name: data.datatableName,
|
|
3238
3372
|
schema_name: data.schemaName,
|
|
3239
|
-
table_name: data.tableName
|
|
3373
|
+
table_name: data.tableName,
|
|
3374
|
+
role: data.role
|
|
3240
3375
|
}
|
|
3241
3376
|
});
|
|
3242
3377
|
}
|
|
@@ -6397,6 +6532,8 @@ var FlowService = class {
|
|
|
6397
6532
|
* @param data The data for the request.
|
|
6398
6533
|
* @param data.workspace
|
|
6399
6534
|
* @param data.path
|
|
6535
|
+
* @param data.page which page to return (start at 1, default 1)
|
|
6536
|
+
* @param data.perPage number of items to return for a given page (default 30, max 100)
|
|
6400
6537
|
* @returns FlowVersion Flow history
|
|
6401
6538
|
* @throws ApiError
|
|
6402
6539
|
*/
|
|
@@ -6407,6 +6544,10 @@ var FlowService = class {
|
|
|
6407
6544
|
path: {
|
|
6408
6545
|
workspace: data.workspace,
|
|
6409
6546
|
path: data.path
|
|
6547
|
+
},
|
|
6548
|
+
query: {
|
|
6549
|
+
page: data.page,
|
|
6550
|
+
per_page: data.perPage
|
|
6410
6551
|
}
|
|
6411
6552
|
});
|
|
6412
6553
|
}
|
|
@@ -7006,6 +7147,8 @@ var AppService = class {
|
|
|
7006
7147
|
* @param data The data for the request.
|
|
7007
7148
|
* @param data.workspace
|
|
7008
7149
|
* @param data.path
|
|
7150
|
+
* @param data.page which page to return (start at 1, default 1)
|
|
7151
|
+
* @param data.perPage number of items to return for a given page (default 30, max 100)
|
|
7009
7152
|
* @returns AppHistory app history
|
|
7010
7153
|
* @throws ApiError
|
|
7011
7154
|
*/
|
|
@@ -7016,6 +7159,10 @@ var AppService = class {
|
|
|
7016
7159
|
path: {
|
|
7017
7160
|
workspace: data.workspace,
|
|
7018
7161
|
path: data.path
|
|
7162
|
+
},
|
|
7163
|
+
query: {
|
|
7164
|
+
page: data.page,
|
|
7165
|
+
per_page: data.perPage
|
|
7019
7166
|
}
|
|
7020
7167
|
});
|
|
7021
7168
|
}
|
|
@@ -7234,7 +7381,7 @@ var AppService = class {
|
|
|
7234
7381
|
* @param data.workspace
|
|
7235
7382
|
* @param data.path
|
|
7236
7383
|
* @param data.requestBody update app
|
|
7237
|
-
* @returns
|
|
7384
|
+
* @returns AppDeployed app updated
|
|
7238
7385
|
* @throws ApiError
|
|
7239
7386
|
*/
|
|
7240
7387
|
static updateApp(data) {
|
|
@@ -7272,7 +7419,7 @@ var AppService = class {
|
|
|
7272
7419
|
* @param data.workspace
|
|
7273
7420
|
* @param data.path
|
|
7274
7421
|
* @param data.requestBody raw app sources to bundle and deploy
|
|
7275
|
-
* @returns
|
|
7422
|
+
* @returns AppDeployed app updated
|
|
7276
7423
|
* @throws ApiError
|
|
7277
7424
|
*/
|
|
7278
7425
|
static updateAppRawSource(data) {
|
|
@@ -7293,7 +7440,7 @@ var AppService = class {
|
|
|
7293
7440
|
* @param data.workspace
|
|
7294
7441
|
* @param data.path
|
|
7295
7442
|
* @param data.formData update app
|
|
7296
|
-
* @returns
|
|
7443
|
+
* @returns AppDeployed app updated
|
|
7297
7444
|
* @throws ApiError
|
|
7298
7445
|
*/
|
|
7299
7446
|
static updateAppRaw(data) {
|
|
@@ -8053,6 +8200,8 @@ var ScriptService = class {
|
|
|
8053
8200
|
* @param data The data for the request.
|
|
8054
8201
|
* @param data.workspace
|
|
8055
8202
|
* @param data.path
|
|
8203
|
+
* @param data.page which page to return (start at 1, default 1)
|
|
8204
|
+
* @param data.perPage number of items to return for a given page (default 30, max 100)
|
|
8056
8205
|
* @returns ScriptHistory script history
|
|
8057
8206
|
* @throws ApiError
|
|
8058
8207
|
*/
|
|
@@ -8063,6 +8212,10 @@ var ScriptService = class {
|
|
|
8063
8212
|
path: {
|
|
8064
8213
|
workspace: data.workspace,
|
|
8065
8214
|
path: data.path
|
|
8215
|
+
},
|
|
8216
|
+
query: {
|
|
8217
|
+
page: data.page,
|
|
8218
|
+
per_page: data.perPage
|
|
8066
8219
|
}
|
|
8067
8220
|
});
|
|
8068
8221
|
}
|
|
@@ -8499,6 +8652,30 @@ var DraftService = class {
|
|
|
8499
8652
|
});
|
|
8500
8653
|
}
|
|
8501
8654
|
/**
|
|
8655
|
+
* move the current user's draft-only item to another path
|
|
8656
|
+
* Relocates the authed user's own draft row, along with both path keys inside its value (the typed path and the mirror the editors keep beside it). Only for draft-only items — a deployed item must be moved through its own deploy endpoint, which carries every draft with it. Restricted to script, flow, app and raw_app; any other kind is rejected with 400, because only these keep their deploy target where this endpoint rewrites it.
|
|
8657
|
+
* @param data The data for the request.
|
|
8658
|
+
* @param data.workspace
|
|
8659
|
+
* @param data.kind script, flow, app or raw_app only.
|
|
8660
|
+
* @param data.path
|
|
8661
|
+
* @param data.requestBody
|
|
8662
|
+
* @returns string move result
|
|
8663
|
+
* @throws ApiError
|
|
8664
|
+
*/
|
|
8665
|
+
static moveDraft(data) {
|
|
8666
|
+
return request(OpenAPI, {
|
|
8667
|
+
method: "POST",
|
|
8668
|
+
url: "/w/{workspace}/drafts/move/{kind}/{path}",
|
|
8669
|
+
path: {
|
|
8670
|
+
workspace: data.workspace,
|
|
8671
|
+
kind: data.kind,
|
|
8672
|
+
path: data.path
|
|
8673
|
+
},
|
|
8674
|
+
body: data.requestBody,
|
|
8675
|
+
mediaType: "application/json"
|
|
8676
|
+
});
|
|
8677
|
+
}
|
|
8678
|
+
/**
|
|
8502
8679
|
* resolve a legacy (workspace-level) draft (admin only)
|
|
8503
8680
|
* Delete a legacy draft (email NULL) or assign it to the authed admin as a per-user draft. Workspace admins / superadmins only.
|
|
8504
8681
|
* @param data The data for the request.
|