@flowcore/sdk 1.51.0 → 1.53.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +21 -0
- package/README.md +2 -2
- package/esm/commands/adapter/reset-adapter.d.ts +2 -2
- package/esm/commands/adapter/reset-adapter.d.ts.map +1 -1
- package/esm/commands/adapter/reset-adapter.js +1 -1
- package/esm/commands/iam/permissions/get-user-permissions.d.ts +1 -1
- package/esm/commands/iam/permissions/get-user-permissions.d.ts.map +1 -1
- package/esm/commands/iam/permissions/get-user-permissions.js +2 -1
- package/esm/commands/iam/policies/create-policy.d.ts +1 -1
- package/esm/commands/iam/policies/create-policy.d.ts.map +1 -1
- package/esm/commands/iam/policies/create-policy.js +2 -1
- package/esm/commands/iam/policies/get-policy.d.ts +1 -1
- package/esm/commands/iam/policies/get-policy.d.ts.map +1 -1
- package/esm/commands/iam/policies/get-policy.js +2 -1
- package/esm/commands/iam/policies/id/archive-policy.d.ts +1 -1
- package/esm/commands/iam/policies/id/archive-policy.d.ts.map +1 -1
- package/esm/commands/iam/policies/id/archive-policy.js +2 -1
- package/esm/commands/iam/policies/id/get-policy.d.ts +1 -1
- package/esm/commands/iam/policies/id/get-policy.d.ts.map +1 -1
- package/esm/commands/iam/policies/id/get-policy.js +2 -1
- package/esm/commands/iam/policies/id/update-policy.d.ts +1 -1
- package/esm/commands/iam/policies/id/update-policy.d.ts.map +1 -1
- package/esm/commands/iam/policies/id/update-policy.js +2 -1
- package/esm/commands/iam/policy-associations/get-key-policies.d.ts +1 -1
- package/esm/commands/iam/policy-associations/get-key-policies.d.ts.map +1 -1
- package/esm/commands/iam/policy-associations/get-key-policies.js +2 -1
- package/esm/commands/iam/policy-associations/get-organization-policies.d.ts +1 -1
- package/esm/commands/iam/policy-associations/get-organization-policies.d.ts.map +1 -1
- package/esm/commands/iam/policy-associations/get-organization-policies.js +2 -1
- package/esm/commands/iam/policy-associations/get-policy-associations.d.ts +1 -1
- package/esm/commands/iam/policy-associations/get-policy-associations.d.ts.map +1 -1
- package/esm/commands/iam/policy-associations/get-policy-associations.js +2 -1
- package/esm/commands/iam/policy-associations/get-role-policies.d.ts +1 -1
- package/esm/commands/iam/policy-associations/get-role-policies.d.ts.map +1 -1
- package/esm/commands/iam/policy-associations/get-role-policies.js +2 -1
- package/esm/commands/iam/policy-associations/get-user-policies.d.ts +1 -1
- package/esm/commands/iam/policy-associations/get-user-policies.d.ts.map +1 -1
- package/esm/commands/iam/policy-associations/get-user-policies.js +2 -1
- package/esm/commands/iam/policy-associations/link-key-policy.d.ts +1 -1
- package/esm/commands/iam/policy-associations/link-key-policy.d.ts.map +1 -1
- package/esm/commands/iam/policy-associations/link-key-policy.js +2 -1
- package/esm/commands/iam/policy-associations/link-role-policy.d.ts +1 -1
- package/esm/commands/iam/policy-associations/link-role-policy.d.ts.map +1 -1
- package/esm/commands/iam/policy-associations/link-role-policy.js +2 -1
- package/esm/commands/iam/policy-associations/link-user-policy.d.ts +1 -1
- package/esm/commands/iam/policy-associations/link-user-policy.d.ts.map +1 -1
- package/esm/commands/iam/policy-associations/link-user-policy.js +2 -1
- package/esm/commands/iam/policy-associations/unlink-key-policy.d.ts +1 -1
- package/esm/commands/iam/policy-associations/unlink-key-policy.d.ts.map +1 -1
- package/esm/commands/iam/policy-associations/unlink-key-policy.js +2 -1
- package/esm/commands/iam/policy-associations/unlink-role-policy.d.ts +1 -1
- package/esm/commands/iam/policy-associations/unlink-role-policy.d.ts.map +1 -1
- package/esm/commands/iam/policy-associations/unlink-role-policy.js +2 -1
- package/esm/commands/iam/policy-associations/unlink-user-policy.d.ts +1 -1
- package/esm/commands/iam/policy-associations/unlink-user-policy.d.ts.map +1 -1
- package/esm/commands/iam/policy-associations/unlink-user-policy.js +2 -1
- package/esm/commands/iam/role-associations/get-key-roles.d.ts +1 -1
- package/esm/commands/iam/role-associations/get-key-roles.d.ts.map +1 -1
- package/esm/commands/iam/role-associations/get-key-roles.js +2 -1
- package/esm/commands/iam/role-associations/get-organization-roles.d.ts +1 -1
- package/esm/commands/iam/role-associations/get-organization-roles.d.ts.map +1 -1
- package/esm/commands/iam/role-associations/get-organization-roles.js +2 -1
- package/esm/commands/iam/role-associations/get-role-associations.d.ts +1 -1
- package/esm/commands/iam/role-associations/get-role-associations.d.ts.map +1 -1
- package/esm/commands/iam/role-associations/get-role-associations.js +2 -1
- package/esm/commands/iam/role-associations/get-user-roles.d.ts +1 -1
- package/esm/commands/iam/role-associations/get-user-roles.d.ts.map +1 -1
- package/esm/commands/iam/role-associations/get-user-roles.js +2 -1
- package/esm/commands/iam/role-associations/link-key-role.d.ts +1 -1
- package/esm/commands/iam/role-associations/link-key-role.d.ts.map +1 -1
- package/esm/commands/iam/role-associations/link-key-role.js +2 -1
- package/esm/commands/iam/role-associations/link-user-role.d.ts +1 -1
- package/esm/commands/iam/role-associations/link-user-role.d.ts.map +1 -1
- package/esm/commands/iam/role-associations/link-user-role.js +2 -1
- package/esm/commands/iam/role-associations/unlink-key-role.d.ts +1 -1
- package/esm/commands/iam/role-associations/unlink-key-role.d.ts.map +1 -1
- package/esm/commands/iam/role-associations/unlink-key-role.js +2 -1
- package/esm/commands/iam/role-associations/unlink-user-role.d.ts +1 -1
- package/esm/commands/iam/role-associations/unlink-user-role.d.ts.map +1 -1
- package/esm/commands/iam/role-associations/unlink-user-role.js +2 -1
- package/esm/commands/iam/roles/create-role.d.ts +1 -1
- package/esm/commands/iam/roles/create-role.d.ts.map +1 -1
- package/esm/commands/iam/roles/create-role.js +2 -1
- package/esm/commands/iam/roles/get-roles.d.ts +1 -1
- package/esm/commands/iam/roles/get-roles.d.ts.map +1 -1
- package/esm/commands/iam/roles/get-roles.js +2 -1
- package/esm/commands/iam/roles/id/archive-role.d.ts +1 -1
- package/esm/commands/iam/roles/id/archive-role.d.ts.map +1 -1
- package/esm/commands/iam/roles/id/archive-role.js +2 -1
- package/esm/commands/iam/roles/id/get-role.d.ts +1 -1
- package/esm/commands/iam/roles/id/get-role.d.ts.map +1 -1
- package/esm/commands/iam/roles/id/get-role.js +2 -1
- package/esm/commands/iam/roles/id/update-role.d.ts +1 -1
- package/esm/commands/iam/roles/id/update-role.d.ts.map +1 -1
- package/esm/commands/iam/roles/id/update-role.js +2 -1
- package/esm/commands/iam/tenant-iam-audit/get-audit-for-tenant.d.ts +1 -1
- package/esm/commands/iam/tenant-iam-audit/get-audit-for-tenant.d.ts.map +1 -1
- package/esm/commands/iam/tenant-iam-audit/get-audit-for-tenant.js +2 -1
- package/esm/commands/iam/validate/validate-key.d.ts +1 -1
- package/esm/commands/iam/validate/validate-key.d.ts.map +1 -1
- package/esm/commands/iam/validate/validate-key.js +2 -1
- package/esm/commands/iam/validate/validate-user.d.ts +1 -1
- package/esm/commands/iam/validate/validate-user.d.ts.map +1 -1
- package/esm/commands/iam/validate/validate-user.js +2 -1
- package/esm/commands/index.d.ts +2 -0
- package/esm/commands/index.d.ts.map +1 -1
- package/esm/commands/index.js +2 -0
- package/esm/commands/secret/secret.create.d.ts +23 -8
- package/esm/commands/secret/secret.create.d.ts.map +1 -1
- package/esm/commands/secret/secret.create.js +27 -39
- package/esm/commands/secret/secret.delete.d.ts +20 -8
- package/esm/commands/secret/secret.delete.d.ts.map +1 -1
- package/esm/commands/secret/secret.delete.js +27 -41
- package/esm/commands/secret/secret.edit.d.ts +45 -0
- package/esm/commands/secret/secret.edit.d.ts.map +1 -0
- package/esm/commands/secret/secret.edit.js +40 -0
- package/esm/commands/secret/secret.list.d.ts +20 -7
- package/esm/commands/secret/secret.list.d.ts.map +1 -1
- package/esm/commands/secret/secret.list.js +27 -41
- package/esm/commands/variable/variable.create.d.ts +21 -7
- package/esm/commands/variable/variable.create.d.ts.map +1 -1
- package/esm/commands/variable/variable.create.js +26 -44
- package/esm/commands/variable/variable.delete.d.ts +20 -8
- package/esm/commands/variable/variable.delete.d.ts.map +1 -1
- package/esm/commands/variable/variable.delete.js +27 -44
- package/esm/commands/variable/variable.edit.d.ts +45 -0
- package/esm/commands/variable/variable.edit.d.ts.map +1 -0
- package/esm/commands/variable/variable.edit.js +40 -0
- package/esm/commands/variable/variable.list.d.ts +19 -7
- package/esm/commands/variable/variable.list.d.ts.map +1 -1
- package/esm/commands/variable/variable.list.js +27 -47
- package/esm/contracts/secret.d.ts +16 -0
- package/esm/contracts/secret.d.ts.map +1 -0
- package/esm/contracts/secret.js +11 -0
- package/esm/contracts/variable.d.ts +5 -1
- package/esm/contracts/variable.d.ts.map +1 -1
- package/esm/contracts/variable.js +4 -0
- package/package.json +1 -1
- package/script/commands/adapter/reset-adapter.d.ts +2 -2
- package/script/commands/adapter/reset-adapter.d.ts.map +1 -1
- package/script/commands/adapter/reset-adapter.js +2 -2
- package/script/commands/iam/permissions/get-user-permissions.d.ts +1 -1
- package/script/commands/iam/permissions/get-user-permissions.d.ts.map +1 -1
- package/script/commands/iam/permissions/get-user-permissions.js +4 -3
- package/script/commands/iam/policies/create-policy.d.ts +1 -1
- package/script/commands/iam/policies/create-policy.d.ts.map +1 -1
- package/script/commands/iam/policies/create-policy.js +4 -3
- package/script/commands/iam/policies/get-policy.d.ts +1 -1
- package/script/commands/iam/policies/get-policy.d.ts.map +1 -1
- package/script/commands/iam/policies/get-policy.js +4 -3
- package/script/commands/iam/policies/id/archive-policy.d.ts +1 -1
- package/script/commands/iam/policies/id/archive-policy.d.ts.map +1 -1
- package/script/commands/iam/policies/id/archive-policy.js +4 -3
- package/script/commands/iam/policies/id/get-policy.d.ts +1 -1
- package/script/commands/iam/policies/id/get-policy.d.ts.map +1 -1
- package/script/commands/iam/policies/id/get-policy.js +4 -3
- package/script/commands/iam/policies/id/update-policy.d.ts +1 -1
- package/script/commands/iam/policies/id/update-policy.d.ts.map +1 -1
- package/script/commands/iam/policies/id/update-policy.js +4 -3
- package/script/commands/iam/policy-associations/get-key-policies.d.ts +1 -1
- package/script/commands/iam/policy-associations/get-key-policies.d.ts.map +1 -1
- package/script/commands/iam/policy-associations/get-key-policies.js +5 -4
- package/script/commands/iam/policy-associations/get-organization-policies.d.ts +1 -1
- package/script/commands/iam/policy-associations/get-organization-policies.d.ts.map +1 -1
- package/script/commands/iam/policy-associations/get-organization-policies.js +5 -4
- package/script/commands/iam/policy-associations/get-policy-associations.d.ts +1 -1
- package/script/commands/iam/policy-associations/get-policy-associations.d.ts.map +1 -1
- package/script/commands/iam/policy-associations/get-policy-associations.js +7 -6
- package/script/commands/iam/policy-associations/get-role-policies.d.ts +1 -1
- package/script/commands/iam/policy-associations/get-role-policies.d.ts.map +1 -1
- package/script/commands/iam/policy-associations/get-role-policies.js +5 -4
- package/script/commands/iam/policy-associations/get-user-policies.d.ts +1 -1
- package/script/commands/iam/policy-associations/get-user-policies.d.ts.map +1 -1
- package/script/commands/iam/policy-associations/get-user-policies.js +4 -3
- package/script/commands/iam/policy-associations/link-key-policy.d.ts +1 -1
- package/script/commands/iam/policy-associations/link-key-policy.d.ts.map +1 -1
- package/script/commands/iam/policy-associations/link-key-policy.js +4 -3
- package/script/commands/iam/policy-associations/link-role-policy.d.ts +1 -1
- package/script/commands/iam/policy-associations/link-role-policy.d.ts.map +1 -1
- package/script/commands/iam/policy-associations/link-role-policy.js +4 -3
- package/script/commands/iam/policy-associations/link-user-policy.d.ts +1 -1
- package/script/commands/iam/policy-associations/link-user-policy.d.ts.map +1 -1
- package/script/commands/iam/policy-associations/link-user-policy.js +4 -3
- package/script/commands/iam/policy-associations/unlink-key-policy.d.ts +1 -1
- package/script/commands/iam/policy-associations/unlink-key-policy.d.ts.map +1 -1
- package/script/commands/iam/policy-associations/unlink-key-policy.js +4 -3
- package/script/commands/iam/policy-associations/unlink-role-policy.d.ts +1 -1
- package/script/commands/iam/policy-associations/unlink-role-policy.d.ts.map +1 -1
- package/script/commands/iam/policy-associations/unlink-role-policy.js +4 -3
- package/script/commands/iam/policy-associations/unlink-user-policy.d.ts +1 -1
- package/script/commands/iam/policy-associations/unlink-user-policy.d.ts.map +1 -1
- package/script/commands/iam/policy-associations/unlink-user-policy.js +4 -3
- package/script/commands/iam/role-associations/get-key-roles.d.ts +1 -1
- package/script/commands/iam/role-associations/get-key-roles.d.ts.map +1 -1
- package/script/commands/iam/role-associations/get-key-roles.js +4 -3
- package/script/commands/iam/role-associations/get-organization-roles.d.ts +1 -1
- package/script/commands/iam/role-associations/get-organization-roles.d.ts.map +1 -1
- package/script/commands/iam/role-associations/get-organization-roles.js +4 -3
- package/script/commands/iam/role-associations/get-role-associations.d.ts +1 -1
- package/script/commands/iam/role-associations/get-role-associations.d.ts.map +1 -1
- package/script/commands/iam/role-associations/get-role-associations.js +4 -3
- package/script/commands/iam/role-associations/get-user-roles.d.ts +1 -1
- package/script/commands/iam/role-associations/get-user-roles.d.ts.map +1 -1
- package/script/commands/iam/role-associations/get-user-roles.js +4 -3
- package/script/commands/iam/role-associations/link-key-role.d.ts +1 -1
- package/script/commands/iam/role-associations/link-key-role.d.ts.map +1 -1
- package/script/commands/iam/role-associations/link-key-role.js +4 -3
- package/script/commands/iam/role-associations/link-user-role.d.ts +1 -1
- package/script/commands/iam/role-associations/link-user-role.d.ts.map +1 -1
- package/script/commands/iam/role-associations/link-user-role.js +4 -3
- package/script/commands/iam/role-associations/unlink-key-role.d.ts +1 -1
- package/script/commands/iam/role-associations/unlink-key-role.d.ts.map +1 -1
- package/script/commands/iam/role-associations/unlink-key-role.js +4 -3
- package/script/commands/iam/role-associations/unlink-user-role.d.ts +1 -1
- package/script/commands/iam/role-associations/unlink-user-role.d.ts.map +1 -1
- package/script/commands/iam/role-associations/unlink-user-role.js +4 -3
- package/script/commands/iam/roles/create-role.d.ts +1 -1
- package/script/commands/iam/roles/create-role.d.ts.map +1 -1
- package/script/commands/iam/roles/create-role.js +4 -3
- package/script/commands/iam/roles/get-roles.d.ts +1 -1
- package/script/commands/iam/roles/get-roles.d.ts.map +1 -1
- package/script/commands/iam/roles/get-roles.js +4 -3
- package/script/commands/iam/roles/id/archive-role.d.ts +1 -1
- package/script/commands/iam/roles/id/archive-role.d.ts.map +1 -1
- package/script/commands/iam/roles/id/archive-role.js +4 -3
- package/script/commands/iam/roles/id/get-role.d.ts +1 -1
- package/script/commands/iam/roles/id/get-role.d.ts.map +1 -1
- package/script/commands/iam/roles/id/get-role.js +4 -3
- package/script/commands/iam/roles/id/update-role.d.ts +1 -1
- package/script/commands/iam/roles/id/update-role.d.ts.map +1 -1
- package/script/commands/iam/roles/id/update-role.js +4 -3
- package/script/commands/iam/tenant-iam-audit/get-audit-for-tenant.d.ts +1 -1
- package/script/commands/iam/tenant-iam-audit/get-audit-for-tenant.d.ts.map +1 -1
- package/script/commands/iam/tenant-iam-audit/get-audit-for-tenant.js +4 -3
- package/script/commands/iam/validate/validate-key.d.ts +1 -1
- package/script/commands/iam/validate/validate-key.d.ts.map +1 -1
- package/script/commands/iam/validate/validate-key.js +4 -3
- package/script/commands/iam/validate/validate-user.d.ts +1 -1
- package/script/commands/iam/validate/validate-user.d.ts.map +1 -1
- package/script/commands/iam/validate/validate-user.js +4 -3
- package/script/commands/index.d.ts +2 -0
- package/script/commands/index.d.ts.map +1 -1
- package/script/commands/index.js +2 -0
- package/script/commands/secret/secret.create.d.ts +23 -8
- package/script/commands/secret/secret.create.d.ts.map +1 -1
- package/script/commands/secret/secret.create.js +27 -39
- package/script/commands/secret/secret.delete.d.ts +20 -8
- package/script/commands/secret/secret.delete.d.ts.map +1 -1
- package/script/commands/secret/secret.delete.js +27 -41
- package/script/commands/secret/secret.edit.d.ts +45 -0
- package/script/commands/secret/secret.edit.d.ts.map +1 -0
- package/script/commands/secret/secret.edit.js +44 -0
- package/script/commands/secret/secret.list.d.ts +20 -7
- package/script/commands/secret/secret.list.d.ts.map +1 -1
- package/script/commands/secret/secret.list.js +27 -41
- package/script/commands/variable/variable.create.d.ts +21 -7
- package/script/commands/variable/variable.create.d.ts.map +1 -1
- package/script/commands/variable/variable.create.js +26 -44
- package/script/commands/variable/variable.delete.d.ts +20 -8
- package/script/commands/variable/variable.delete.d.ts.map +1 -1
- package/script/commands/variable/variable.delete.js +27 -44
- package/script/commands/variable/variable.edit.d.ts +45 -0
- package/script/commands/variable/variable.edit.d.ts.map +1 -0
- package/script/commands/variable/variable.edit.js +44 -0
- package/script/commands/variable/variable.list.d.ts +19 -7
- package/script/commands/variable/variable.list.d.ts.map +1 -1
- package/script/commands/variable/variable.list.js +27 -47
- package/script/contracts/secret.d.ts +16 -0
- package/script/contracts/secret.d.ts.map +1 -0
- package/script/contracts/secret.js +14 -0
- package/script/contracts/variable.d.ts +5 -1
- package/script/contracts/variable.d.ts.map +1 -1
- package/script/contracts/variable.js +4 -0
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { Command } from "../../common/command.js";
|
|
2
|
+
import { type Variable } from "../../contracts/variable.js";
|
|
3
|
+
/**
|
|
4
|
+
* The input for the variable edit command
|
|
5
|
+
*/
|
|
6
|
+
export interface VariableEditInput {
|
|
7
|
+
/** The tenant id */
|
|
8
|
+
tenantId: string;
|
|
9
|
+
/** The key of the variable */
|
|
10
|
+
key: string;
|
|
11
|
+
/** The value of the variable */
|
|
12
|
+
value?: string;
|
|
13
|
+
/** The description of the variable */
|
|
14
|
+
description?: string;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Edit a variable
|
|
18
|
+
*/
|
|
19
|
+
export declare class VariableEditCommand extends Command<VariableEditInput, Variable> {
|
|
20
|
+
/**
|
|
21
|
+
* Whether the command should retry on failure
|
|
22
|
+
*/
|
|
23
|
+
protected retryOnFailure: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Get the method
|
|
26
|
+
*/
|
|
27
|
+
protected getMethod(): string;
|
|
28
|
+
/**
|
|
29
|
+
* Get the base url
|
|
30
|
+
*/
|
|
31
|
+
protected getBaseUrl(): string;
|
|
32
|
+
/**
|
|
33
|
+
* Get the path
|
|
34
|
+
*/
|
|
35
|
+
protected getPath(): string;
|
|
36
|
+
/**
|
|
37
|
+
* The allowed modes for the command
|
|
38
|
+
*/
|
|
39
|
+
protected allowedModes: ("apiKey" | "bearer")[];
|
|
40
|
+
/**
|
|
41
|
+
* Parse the response
|
|
42
|
+
*/
|
|
43
|
+
protected parseResponse(rawResponse: unknown): Variable;
|
|
44
|
+
}
|
|
45
|
+
//# sourceMappingURL=variable.edit.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"variable.edit.d.ts","sourceRoot":"","sources":["../../../src/commands/variable/variable.edit.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAA;AAEjD,OAAO,EAAE,KAAK,QAAQ,EAAkB,MAAM,6BAA6B,CAAA;AAE3E;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,oBAAoB;IACpB,QAAQ,EAAE,MAAM,CAAA;IAChB,8BAA8B;IAC9B,GAAG,EAAE,MAAM,CAAA;IACX,gCAAgC;IAChC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,sCAAsC;IACtC,WAAW,CAAC,EAAE,MAAM,CAAA;CACrB;AAED;;GAEG;AACH,qBAAa,mBAAoB,SAAQ,OAAO,CAAC,iBAAiB,EAAE,QAAQ,CAAC;IAC3E;;OAEG;IACH,UAAmB,cAAc,EAAE,OAAO,CAAQ;IAElD;;OAEG;cACgB,SAAS,IAAI,MAAM;IAGtC;;OAEG;cACgB,UAAU,IAAI,MAAM;IAIvC;;OAEG;cACgB,OAAO,IAAI,MAAM;IAIpC;;OAEG;IACH,UAAmB,YAAY,EAAE,CAAC,QAAQ,GAAG,QAAQ,CAAC,EAAE,CAAa;IAErE;;OAEG;cACgB,aAAa,CAAC,WAAW,EAAE,OAAO,GAAG,QAAQ;CAGjE"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.VariableEditCommand = void 0;
|
|
4
|
+
const command_js_1 = require("../../common/command.js");
|
|
5
|
+
const parse_response_helper_js_1 = require("../../utils/parse-response-helper.js");
|
|
6
|
+
const variable_js_1 = require("../../contracts/variable.js");
|
|
7
|
+
/**
|
|
8
|
+
* Edit a variable
|
|
9
|
+
*/
|
|
10
|
+
class VariableEditCommand extends command_js_1.Command {
|
|
11
|
+
/**
|
|
12
|
+
* Whether the command should retry on failure
|
|
13
|
+
*/
|
|
14
|
+
retryOnFailure = false;
|
|
15
|
+
/**
|
|
16
|
+
* Get the method
|
|
17
|
+
*/
|
|
18
|
+
getMethod() {
|
|
19
|
+
return "PATCH";
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Get the base url
|
|
23
|
+
*/
|
|
24
|
+
getBaseUrl() {
|
|
25
|
+
return "https://tenant-store.api.flowcore.io";
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Get the path
|
|
29
|
+
*/
|
|
30
|
+
getPath() {
|
|
31
|
+
return `/api/v1/tenants/${this.input.tenantId}/variables/${this.input.key}`;
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* The allowed modes for the command
|
|
35
|
+
*/
|
|
36
|
+
allowedModes = ["bearer"];
|
|
37
|
+
/**
|
|
38
|
+
* Parse the response
|
|
39
|
+
*/
|
|
40
|
+
parseResponse(rawResponse) {
|
|
41
|
+
return (0, parse_response_helper_js_1.parseResponseHelper)(variable_js_1.VariableSchema, rawResponse);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
exports.VariableEditCommand = VariableEditCommand;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import type
|
|
1
|
+
import { Command } from "../../common/command.js";
|
|
2
|
+
import { type Variable } from "../../contracts/variable.js";
|
|
3
3
|
/**
|
|
4
4
|
* The input for the variable list command
|
|
5
5
|
*/
|
|
@@ -10,7 +10,23 @@ export interface VariableListInput {
|
|
|
10
10
|
/**
|
|
11
11
|
* List variables
|
|
12
12
|
*/
|
|
13
|
-
export declare class VariableListCommand extends
|
|
13
|
+
export declare class VariableListCommand extends Command<VariableListInput, Variable[]> {
|
|
14
|
+
/**
|
|
15
|
+
* Whether the command should retry on failure
|
|
16
|
+
*/
|
|
17
|
+
protected retryOnFailure: boolean;
|
|
18
|
+
/**
|
|
19
|
+
* Get the method
|
|
20
|
+
*/
|
|
21
|
+
protected getMethod(): string;
|
|
22
|
+
/**
|
|
23
|
+
* Get the base url
|
|
24
|
+
*/
|
|
25
|
+
protected getBaseUrl(): string;
|
|
26
|
+
/**
|
|
27
|
+
* Get the path
|
|
28
|
+
*/
|
|
29
|
+
protected getPath(): string;
|
|
14
30
|
/**
|
|
15
31
|
* The allowed modes for the command
|
|
16
32
|
*/
|
|
@@ -19,9 +35,5 @@ export declare class VariableListCommand extends GraphQlCommand<VariableListInpu
|
|
|
19
35
|
* Parse the response
|
|
20
36
|
*/
|
|
21
37
|
protected parseResponse(rawResponse: unknown): Variable[];
|
|
22
|
-
/**
|
|
23
|
-
* Get the body for the request
|
|
24
|
-
*/
|
|
25
|
-
protected getBody(): Record<string, unknown>;
|
|
26
38
|
}
|
|
27
39
|
//# sourceMappingURL=variable.list.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"variable.list.d.ts","sourceRoot":"","sources":["../../../src/commands/variable/variable.list.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"variable.list.d.ts","sourceRoot":"","sources":["../../../src/commands/variable/variable.list.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAA;AAEjD,OAAO,EAAE,KAAK,QAAQ,EAAkB,MAAM,6BAA6B,CAAA;AAG3E;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,oBAAoB;IACpB,QAAQ,EAAE,MAAM,CAAA;CACjB;AAED;;GAEG;AACH,qBAAa,mBAAoB,SAAQ,OAAO,CAAC,iBAAiB,EAAE,QAAQ,EAAE,CAAC;IAC7E;;OAEG;IACH,UAAmB,cAAc,EAAE,OAAO,CAAQ;IAElD;;OAEG;cACgB,SAAS,IAAI,MAAM;IAGtC;;OAEG;cACgB,UAAU,IAAI,MAAM;IAIvC;;OAEG;cACgB,OAAO,IAAI,MAAM;IAIpC;;OAEG;IACH,UAAmB,YAAY,EAAE,CAAC,QAAQ,GAAG,QAAQ,CAAC,EAAE,CAAa;IAErE;;OAEG;cACgB,aAAa,CAAC,WAAW,EAAE,OAAO,GAAG,QAAQ,EAAE;CAGnE"}
|
|
@@ -1,40 +1,36 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.VariableListCommand = void 0;
|
|
4
|
-
const
|
|
5
|
-
const command_graphql_js_1 = require("../../common/command-graphql.js");
|
|
4
|
+
const command_js_1 = require("../../common/command.js");
|
|
6
5
|
const parse_response_helper_js_1 = require("../../utils/parse-response-helper.js");
|
|
7
|
-
const
|
|
8
|
-
const
|
|
9
|
-
query FLOWCORE_SDK_VARIABLE_LIST($tenantId: ID!) {
|
|
10
|
-
organization(search: {id: $tenantId}) {
|
|
11
|
-
variables {
|
|
12
|
-
key
|
|
13
|
-
value
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
`;
|
|
18
|
-
const responseSchema = typebox_1.Type.Object({
|
|
19
|
-
errors: typebox_1.Type.Optional(typebox_1.Type.Array(typebox_1.Type.Object({
|
|
20
|
-
message: typebox_1.Type.String(),
|
|
21
|
-
}))),
|
|
22
|
-
data: typebox_1.Type.Union([
|
|
23
|
-
typebox_1.Type.Object({
|
|
24
|
-
organization: typebox_1.Type.Object({
|
|
25
|
-
variables: typebox_1.Type.Array(typebox_1.Type.Object({
|
|
26
|
-
key: typebox_1.Type.String(),
|
|
27
|
-
value: typebox_1.Type.String(),
|
|
28
|
-
})),
|
|
29
|
-
}),
|
|
30
|
-
}),
|
|
31
|
-
typebox_1.Type.Null(),
|
|
32
|
-
]),
|
|
33
|
-
});
|
|
6
|
+
const variable_js_1 = require("../../contracts/variable.js");
|
|
7
|
+
const typebox_1 = require("@sinclair/typebox");
|
|
34
8
|
/**
|
|
35
9
|
* List variables
|
|
36
10
|
*/
|
|
37
|
-
class VariableListCommand extends
|
|
11
|
+
class VariableListCommand extends command_js_1.Command {
|
|
12
|
+
/**
|
|
13
|
+
* Whether the command should retry on failure
|
|
14
|
+
*/
|
|
15
|
+
retryOnFailure = false;
|
|
16
|
+
/**
|
|
17
|
+
* Get the method
|
|
18
|
+
*/
|
|
19
|
+
getMethod() {
|
|
20
|
+
return "GET";
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Get the base url
|
|
24
|
+
*/
|
|
25
|
+
getBaseUrl() {
|
|
26
|
+
return "https://tenant-store.api.flowcore.io";
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Get the path
|
|
30
|
+
*/
|
|
31
|
+
getPath() {
|
|
32
|
+
return `/api/v1/tenants/${this.input.tenantId}/variables`;
|
|
33
|
+
}
|
|
38
34
|
/**
|
|
39
35
|
* The allowed modes for the command
|
|
40
36
|
*/
|
|
@@ -43,23 +39,7 @@ class VariableListCommand extends command_graphql_js_1.GraphQlCommand {
|
|
|
43
39
|
* Parse the response
|
|
44
40
|
*/
|
|
45
41
|
parseResponse(rawResponse) {
|
|
46
|
-
|
|
47
|
-
if (response.errors) {
|
|
48
|
-
throw new command_error_js_1.CommandError(this.constructor.name, response.errors[0].message);
|
|
49
|
-
}
|
|
50
|
-
if (!response.data) {
|
|
51
|
-
throw new command_error_js_1.CommandError(this.constructor.name, "Failed to list variables");
|
|
52
|
-
}
|
|
53
|
-
return response.data.organization.variables;
|
|
54
|
-
}
|
|
55
|
-
/**
|
|
56
|
-
* Get the body for the request
|
|
57
|
-
*/
|
|
58
|
-
getBody() {
|
|
59
|
-
return {
|
|
60
|
-
query: graphQlQueryById,
|
|
61
|
-
variables: this.input,
|
|
62
|
-
};
|
|
42
|
+
return (0, parse_response_helper_js_1.parseResponseHelper)(typebox_1.Type.Array(variable_js_1.VariableSchema), rawResponse);
|
|
63
43
|
}
|
|
64
44
|
}
|
|
65
45
|
exports.VariableListCommand = VariableListCommand;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type Static, type TNull, type TObject, type TString, type TUnion } from "@sinclair/typebox";
|
|
2
|
+
/**
|
|
3
|
+
* The schema for a secret
|
|
4
|
+
*/
|
|
5
|
+
export declare const SecretSchema: TObject<{
|
|
6
|
+
tenantId: TString;
|
|
7
|
+
key: TString;
|
|
8
|
+
description: TString;
|
|
9
|
+
createdAt: TString;
|
|
10
|
+
updatedAt: TUnion<[TString, TNull]>;
|
|
11
|
+
}>;
|
|
12
|
+
/**
|
|
13
|
+
* The type for a secret
|
|
14
|
+
*/
|
|
15
|
+
export type Secret = Static<typeof SecretSchema>;
|
|
16
|
+
//# sourceMappingURL=secret.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"secret.d.ts","sourceRoot":"","sources":["../../src/contracts/secret.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,KAAK,EAAE,KAAK,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,MAAM,EAAQ,MAAM,mBAAmB,CAAA;AAE1G;;GAEG;AACH,eAAO,MAAM,YAAY,EAAE,OAAO,CAAC;IACjC,QAAQ,EAAE,OAAO,CAAA;IACjB,GAAG,EAAE,OAAO,CAAA;IACZ,WAAW,EAAE,OAAO,CAAA;IACpB,SAAS,EAAE,OAAO,CAAA;IAClB,SAAS,EAAE,MAAM,CAAC,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,CAAA;CACpC,CAMC,CAAA;AAEF;;GAEG;AACH,MAAM,MAAM,MAAM,GAAG,MAAM,CAAC,OAAO,YAAY,CAAC,CAAA"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SecretSchema = void 0;
|
|
4
|
+
const typebox_1 = require("@sinclair/typebox");
|
|
5
|
+
/**
|
|
6
|
+
* The schema for a secret
|
|
7
|
+
*/
|
|
8
|
+
exports.SecretSchema = typebox_1.Type.Object({
|
|
9
|
+
tenantId: typebox_1.Type.String(),
|
|
10
|
+
key: typebox_1.Type.String(),
|
|
11
|
+
description: typebox_1.Type.String(),
|
|
12
|
+
createdAt: typebox_1.Type.String(),
|
|
13
|
+
updatedAt: typebox_1.Type.Union([typebox_1.Type.String(), typebox_1.Type.Null()]),
|
|
14
|
+
});
|
|
@@ -1,10 +1,14 @@
|
|
|
1
|
-
import { type Static, type TObject, type TString } from "@sinclair/typebox";
|
|
1
|
+
import { type Static, type TNull, type TObject, type TString, type TUnion } from "@sinclair/typebox";
|
|
2
2
|
/**
|
|
3
3
|
* The schema for a variable
|
|
4
4
|
*/
|
|
5
5
|
export declare const VariableSchema: TObject<{
|
|
6
|
+
tenantId: TString;
|
|
6
7
|
key: TString;
|
|
8
|
+
description: TString;
|
|
7
9
|
value: TString;
|
|
10
|
+
createdAt: TString;
|
|
11
|
+
updatedAt: TUnion<[TString, TNull]>;
|
|
8
12
|
}>;
|
|
9
13
|
/**
|
|
10
14
|
* The type for a variable
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"variable.d.ts","sourceRoot":"","sources":["../../src/contracts/variable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,OAAO,EAAE,KAAK,OAAO,EAAQ,MAAM,mBAAmB,CAAA;
|
|
1
|
+
{"version":3,"file":"variable.d.ts","sourceRoot":"","sources":["../../src/contracts/variable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,KAAK,EAAE,KAAK,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,MAAM,EAAQ,MAAM,mBAAmB,CAAA;AAE1G;;GAEG;AACH,eAAO,MAAM,cAAc,EAAE,OAAO,CAAC;IACnC,QAAQ,EAAE,OAAO,CAAA;IACjB,GAAG,EAAE,OAAO,CAAA;IACZ,WAAW,EAAE,OAAO,CAAA;IACpB,KAAK,EAAE,OAAO,CAAA;IACd,SAAS,EAAE,OAAO,CAAA;IAClB,SAAS,EAAE,MAAM,CAAC,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,CAAA;CACpC,CAOC,CAAA;AAEF;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC,OAAO,cAAc,CAAC,CAAA"}
|
|
@@ -6,6 +6,10 @@ const typebox_1 = require("@sinclair/typebox");
|
|
|
6
6
|
* The schema for a variable
|
|
7
7
|
*/
|
|
8
8
|
exports.VariableSchema = typebox_1.Type.Object({
|
|
9
|
+
tenantId: typebox_1.Type.String(),
|
|
9
10
|
key: typebox_1.Type.String(),
|
|
11
|
+
description: typebox_1.Type.String(),
|
|
10
12
|
value: typebox_1.Type.String(),
|
|
13
|
+
createdAt: typebox_1.Type.String(),
|
|
14
|
+
updatedAt: typebox_1.Type.Union([typebox_1.Type.String(), typebox_1.Type.Null()]),
|
|
11
15
|
});
|