namirasoft-credential 1.4.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/NamirasoftCredentialServer.d.ts +17 -0
- package/dist/NamirasoftCredentialServer.js +24 -0
- package/dist/NamirasoftCredentialServer.js.map +1 -0
- package/dist/NamirasoftCredentialServerAWS.d.ts +18 -0
- package/dist/NamirasoftCredentialServerAWS.js +64 -0
- package/dist/NamirasoftCredentialServerAWS.js.map +1 -0
- package/dist/NamirasoftCredentialServerAWSCategory.d.ts +16 -0
- package/dist/NamirasoftCredentialServerAWSCategory.js +56 -0
- package/dist/NamirasoftCredentialServerAWSCategory.js.map +1 -0
- package/dist/NamirasoftCredentialServerAWSField.d.ts +17 -0
- package/dist/NamirasoftCredentialServerAWSField.js +64 -0
- package/dist/NamirasoftCredentialServerAWSField.js.map +1 -0
- package/dist/NamirasoftCredentialServerAWSTag.d.ts +17 -0
- package/dist/NamirasoftCredentialServerAWSTag.js +64 -0
- package/dist/NamirasoftCredentialServerAWSTag.js.map +1 -0
- package/dist/NamirasoftCredentialServerBase.d.ts +5 -0
- package/dist/NamirasoftCredentialServerBase.js +11 -0
- package/dist/NamirasoftCredentialServerBase.js.map +1 -0
- package/dist/NamirasoftCredentialServerHealthz.d.ts +6 -0
- package/dist/NamirasoftCredentialServerHealthz.js +28 -0
- package/dist/NamirasoftCredentialServerHealthz.js.map +1 -0
- package/dist/NamirasoftCredentialServerValue.d.ts +6 -0
- package/dist/NamirasoftCredentialServerValue.js +29 -0
- package/dist/NamirasoftCredentialServerValue.js.map +1 -0
- package/dist/command/AWSCategoryCommand.d.ts +4 -0
- package/dist/command/AWSCategoryCommand.js +21 -0
- package/dist/command/AWSCategoryCommand.js.map +1 -0
- package/dist/command/AWSCategoryCreateCommand.d.ts +5 -0
- package/dist/command/AWSCategoryCreateCommand.js +49 -0
- package/dist/command/AWSCategoryCreateCommand.js.map +1 -0
- package/dist/command/AWSCategoryDeleteCommand.d.ts +5 -0
- package/dist/command/AWSCategoryDeleteCommand.js +38 -0
- package/dist/command/AWSCategoryDeleteCommand.js.map +1 -0
- package/dist/command/AWSCategoryGetCommand.d.ts +5 -0
- package/dist/command/AWSCategoryGetCommand.js +38 -0
- package/dist/command/AWSCategoryGetCommand.js.map +1 -0
- package/dist/command/AWSCategoryListCommand.d.ts +5 -0
- package/dist/command/AWSCategoryListCommand.js +38 -0
- package/dist/command/AWSCategoryListCommand.js.map +1 -0
- package/dist/command/AWSCommand.d.ts +4 -0
- package/dist/command/AWSCommand.js +23 -0
- package/dist/command/AWSCommand.js.map +1 -0
- package/dist/command/AWSCreateCommand.d.ts +5 -0
- package/dist/command/AWSCreateCommand.js +112 -0
- package/dist/command/AWSCreateCommand.js.map +1 -0
- package/dist/command/AWSDeleteCommand.d.ts +5 -0
- package/dist/command/AWSDeleteCommand.js +38 -0
- package/dist/command/AWSDeleteCommand.js.map +1 -0
- package/dist/command/AWSFieldCommand.d.ts +4 -0
- package/dist/command/AWSFieldCommand.js +23 -0
- package/dist/command/AWSFieldCommand.js.map +1 -0
- package/dist/command/AWSFieldCreateCommand.d.ts +5 -0
- package/dist/command/AWSFieldCreateCommand.js +58 -0
- package/dist/command/AWSFieldCreateCommand.js.map +1 -0
- package/dist/command/AWSFieldDeleteCommand.d.ts +5 -0
- package/dist/command/AWSFieldDeleteCommand.js +38 -0
- package/dist/command/AWSFieldDeleteCommand.js.map +1 -0
- package/dist/command/AWSFieldGetCommand.d.ts +5 -0
- package/dist/command/AWSFieldGetCommand.js +38 -0
- package/dist/command/AWSFieldGetCommand.js.map +1 -0
- package/dist/command/AWSFieldListCommand.d.ts +5 -0
- package/dist/command/AWSFieldListCommand.js +38 -0
- package/dist/command/AWSFieldListCommand.js.map +1 -0
- package/dist/command/AWSFieldUpdateCommand.d.ts +5 -0
- package/dist/command/AWSFieldUpdateCommand.js +58 -0
- package/dist/command/AWSFieldUpdateCommand.js.map +1 -0
- package/dist/command/AWSGetCommand.d.ts +5 -0
- package/dist/command/AWSGetCommand.js +38 -0
- package/dist/command/AWSGetCommand.js.map +1 -0
- package/dist/command/AWSListCommand.d.ts +5 -0
- package/dist/command/AWSListCommand.js +38 -0
- package/dist/command/AWSListCommand.js.map +1 -0
- package/dist/command/AWSTagCommand.d.ts +4 -0
- package/dist/command/AWSTagCommand.js +23 -0
- package/dist/command/AWSTagCommand.js.map +1 -0
- package/dist/command/AWSTagCreateCommand.d.ts +5 -0
- package/dist/command/AWSTagCreateCommand.js +58 -0
- package/dist/command/AWSTagCreateCommand.js.map +1 -0
- package/dist/command/AWSTagDeleteCommand.d.ts +5 -0
- package/dist/command/AWSTagDeleteCommand.js +38 -0
- package/dist/command/AWSTagDeleteCommand.js.map +1 -0
- package/dist/command/AWSTagGetCommand.d.ts +5 -0
- package/dist/command/AWSTagGetCommand.js +38 -0
- package/dist/command/AWSTagGetCommand.js.map +1 -0
- package/dist/command/AWSTagListCommand.d.ts +5 -0
- package/dist/command/AWSTagListCommand.js +38 -0
- package/dist/command/AWSTagListCommand.js.map +1 -0
- package/dist/command/AWSTagUpdateCommand.d.ts +5 -0
- package/dist/command/AWSTagUpdateCommand.js +58 -0
- package/dist/command/AWSTagUpdateCommand.js.map +1 -0
- package/dist/command/AWSUpdateCommand.d.ts +5 -0
- package/dist/command/AWSUpdateCommand.js +112 -0
- package/dist/command/AWSUpdateCommand.js.map +1 -0
- package/dist/command/HealthzCommand.d.ts +4 -0
- package/dist/command/HealthzCommand.js +15 -0
- package/dist/command/HealthzCommand.js.map +1 -0
- package/dist/command/HealthzGetCommand.d.ts +5 -0
- package/dist/command/HealthzGetCommand.js +38 -0
- package/dist/command/HealthzGetCommand.js.map +1 -0
- package/dist/command/ValueCommand.d.ts +4 -0
- package/dist/command/ValueCommand.js +15 -0
- package/dist/command/ValueCommand.js.map +1 -0
- package/dist/command/ValueListCommand.d.ts +5 -0
- package/dist/command/ValueListCommand.js +38 -0
- package/dist/command/ValueListCommand.js.map +1 -0
- package/dist/command/cli.d.ts +2 -0
- package/dist/command/cli.js +24 -0
- package/dist/command/cli.js.map +1 -0
- package/dist/index.d.ts +49 -0
- package/dist/index.js +66 -0
- package/dist/index.js.map +1 -0
- package/dist/meta/AWSCategoryMetaTable.d.ts +15 -0
- package/dist/meta/AWSCategoryMetaTable.js +38 -0
- package/dist/meta/AWSCategoryMetaTable.js.map +1 -0
- package/dist/meta/AWSFieldMetaTable.d.ts +16 -0
- package/dist/meta/AWSFieldMetaTable.js +39 -0
- package/dist/meta/AWSFieldMetaTable.js.map +1 -0
- package/dist/meta/AWSMetaTable.d.ts +18 -0
- package/dist/meta/AWSMetaTable.js +41 -0
- package/dist/meta/AWSMetaTable.js.map +1 -0
- package/dist/meta/AWSTagMetaTable.d.ts +16 -0
- package/dist/meta/AWSTagMetaTable.js +39 -0
- package/dist/meta/AWSTagMetaTable.js.map +1 -0
- package/dist/meta/NamirasoftCredentialMetaDatabase.d.ts +19 -0
- package/dist/meta/NamirasoftCredentialMetaDatabase.js +33 -0
- package/dist/meta/NamirasoftCredentialMetaDatabase.js.map +1 -0
- package/dist/row/AWSCategoryRow.d.ts +8 -0
- package/dist/row/AWSCategoryRow.js +3 -0
- package/dist/row/AWSCategoryRow.js.map +1 -0
- package/dist/row/AWSFieldRow.d.ts +9 -0
- package/dist/row/AWSFieldRow.js +3 -0
- package/dist/row/AWSFieldRow.js.map +1 -0
- package/dist/row/AWSFullRow.d.ts +17 -0
- package/dist/row/AWSFullRow.js +3 -0
- package/dist/row/AWSFullRow.js.map +1 -0
- package/dist/row/AWSInputRow.d.ts +13 -0
- package/dist/row/AWSInputRow.js +3 -0
- package/dist/row/AWSInputRow.js.map +1 -0
- package/dist/row/AWSRow.d.ts +11 -0
- package/dist/row/AWSRow.js +3 -0
- package/dist/row/AWSRow.js.map +1 -0
- package/dist/row/AWSTagRow.d.ts +9 -0
- package/dist/row/AWSTagRow.js +3 -0
- package/dist/row/AWSTagRow.js.map +1 -0
- package/dist/row/EntityCategoryInputRow.d.ts +3 -0
- package/dist/row/EntityCategoryInputRow.js +3 -0
- package/dist/row/EntityCategoryInputRow.js.map +1 -0
- package/dist/row/EntityFieldInputRow.d.ts +4 -0
- package/dist/row/EntityFieldInputRow.js +3 -0
- package/dist/row/EntityFieldInputRow.js.map +1 -0
- package/dist/row/EntityTagInputRow.d.ts +4 -0
- package/dist/row/EntityTagInputRow.js +3 -0
- package/dist/row/EntityTagInputRow.js.map +1 -0
- package/logo.png +0 -0
- package/package.json +28 -0
- package/src/NamirasoftCredentialServer.ts +48 -0
- package/src/NamirasoftCredentialServerAWS.ts +71 -0
- package/src/NamirasoftCredentialServerAWSCategory.ts +63 -0
- package/src/NamirasoftCredentialServerAWSField.ts +70 -0
- package/src/NamirasoftCredentialServerAWSTag.ts +70 -0
- package/src/NamirasoftCredentialServerBase.ts +30 -0
- package/src/NamirasoftCredentialServerHealthz.ts +36 -0
- package/src/NamirasoftCredentialServerValue.ts +37 -0
- package/src/command/AWSCategoryCommand.ts +38 -0
- package/src/command/AWSCategoryCreateCommand.ts +56 -0
- package/src/command/AWSCategoryDeleteCommand.ts +45 -0
- package/src/command/AWSCategoryGetCommand.ts +45 -0
- package/src/command/AWSCategoryListCommand.ts +45 -0
- package/src/command/AWSCommand.ts +40 -0
- package/src/command/AWSCreateCommand.ts +119 -0
- package/src/command/AWSDeleteCommand.ts +45 -0
- package/src/command/AWSFieldCommand.ts +40 -0
- package/src/command/AWSFieldCreateCommand.ts +65 -0
- package/src/command/AWSFieldDeleteCommand.ts +45 -0
- package/src/command/AWSFieldGetCommand.ts +45 -0
- package/src/command/AWSFieldListCommand.ts +45 -0
- package/src/command/AWSFieldUpdateCommand.ts +65 -0
- package/src/command/AWSGetCommand.ts +45 -0
- package/src/command/AWSListCommand.ts +45 -0
- package/src/command/AWSTagCommand.ts +40 -0
- package/src/command/AWSTagCreateCommand.ts +65 -0
- package/src/command/AWSTagDeleteCommand.ts +45 -0
- package/src/command/AWSTagGetCommand.ts +45 -0
- package/src/command/AWSTagListCommand.ts +45 -0
- package/src/command/AWSTagUpdateCommand.ts +65 -0
- package/src/command/AWSUpdateCommand.ts +119 -0
- package/src/command/HealthzCommand.ts +32 -0
- package/src/command/HealthzGetCommand.ts +45 -0
- package/src/command/ValueCommand.ts +32 -0
- package/src/command/ValueListCommand.ts +45 -0
- package/src/command/cli.ts +43 -0
- package/src/index.ts +69 -0
- package/src/meta/AWSCategoryMetaTable.ts +58 -0
- package/src/meta/AWSFieldMetaTable.ts +60 -0
- package/src/meta/AWSMetaTable.ts +64 -0
- package/src/meta/AWSTagMetaTable.ts +60 -0
- package/src/meta/NamirasoftCredentialMetaDatabase.ts +60 -0
- package/src/row/AWSCategoryRow.ts +29 -0
- package/src/row/AWSFieldRow.ts +30 -0
- package/src/row/AWSFullRow.ts +39 -0
- package/src/row/AWSInputRow.ts +35 -0
- package/src/row/AWSRow.ts +32 -0
- package/src/row/AWSTagRow.ts +30 -0
- package/src/row/EntityCategoryInputRow.ts +24 -0
- package/src/row/EntityFieldInputRow.ts +25 -0
- package/src/row/EntityTagInputRow.ts +25 -0
- package/tsconfig.json +42 -0
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemory } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftCredentialServer } from "../NamirasoftCredentialServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class AWSFieldListCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, ["filters", "page", "size", "sorts"], []);
|
|
31
|
+
}
|
|
32
|
+
override async exec()
|
|
33
|
+
{
|
|
34
|
+
let token = this.app.storage.getNSAToken();
|
|
35
|
+
if (token == null)
|
|
36
|
+
throw new Error("Token is not available. Please login first using:\nns-credential account config \nor \nns-credential account login.");
|
|
37
|
+
let storage = new IStorageMemory();
|
|
38
|
+
let manager = new TokenManager(storage, () => { });
|
|
39
|
+
manager.setValue(token, false);
|
|
40
|
+
let url = this.app.storage.getItem("ns-credential-server-url");
|
|
41
|
+
let server = new NamirasoftCredentialServer(url, manager, e => this.app.logger.error(e.message));
|
|
42
|
+
let ans = await server.a_w_s_field.List(this.arg_values[0], this.arg_values[1], this.arg_values[2], this.arg_values[3]);
|
|
43
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
44
|
+
}
|
|
45
|
+
};
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemory } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftCredentialServer } from "../NamirasoftCredentialServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class AWSFieldUpdateCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, ["entity_id", "id"], [
|
|
31
|
+
{
|
|
32
|
+
name: "field_id",
|
|
33
|
+
short: "",
|
|
34
|
+
description: "Provides the value of 'field_id' in body",
|
|
35
|
+
optional: false,
|
|
36
|
+
args: ["field_id"],
|
|
37
|
+
defaults: [""]
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
name: "value",
|
|
41
|
+
short: "",
|
|
42
|
+
description: "Provides the value of 'value' in body",
|
|
43
|
+
optional: true,
|
|
44
|
+
args: ["value"],
|
|
45
|
+
defaults: [""]
|
|
46
|
+
}
|
|
47
|
+
]);
|
|
48
|
+
}
|
|
49
|
+
override async exec()
|
|
50
|
+
{
|
|
51
|
+
let token = this.app.storage.getNSAToken();
|
|
52
|
+
if (token == null)
|
|
53
|
+
throw new Error("Token is not available. Please login first using:\nns-credential account config \nor \nns-credential account login.");
|
|
54
|
+
let storage = new IStorageMemory();
|
|
55
|
+
let manager = new TokenManager(storage, () => { });
|
|
56
|
+
manager.setValue(token, false);
|
|
57
|
+
let url = this.app.storage.getItem("ns-credential-server-url");
|
|
58
|
+
let server = new NamirasoftCredentialServer(url, manager, e => this.app.logger.error(e.message));
|
|
59
|
+
let ans = await server.a_w_s_field.Update(this.arg_values[0], this.arg_values[1], {
|
|
60
|
+
field_id: this.option_values.field_id,
|
|
61
|
+
value: this.option_values.value
|
|
62
|
+
});
|
|
63
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
64
|
+
}
|
|
65
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemory } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftCredentialServer } from "../NamirasoftCredentialServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class AWSGetCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, ["id"], []);
|
|
31
|
+
}
|
|
32
|
+
override async exec()
|
|
33
|
+
{
|
|
34
|
+
let token = this.app.storage.getNSAToken();
|
|
35
|
+
if (token == null)
|
|
36
|
+
throw new Error("Token is not available. Please login first using:\nns-credential account config \nor \nns-credential account login.");
|
|
37
|
+
let storage = new IStorageMemory();
|
|
38
|
+
let manager = new TokenManager(storage, () => { });
|
|
39
|
+
manager.setValue(token, false);
|
|
40
|
+
let url = this.app.storage.getItem("ns-credential-server-url");
|
|
41
|
+
let server = new NamirasoftCredentialServer(url, manager, e => this.app.logger.error(e.message));
|
|
42
|
+
let ans = await server.aws.Get(this.arg_values[0]);
|
|
43
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
44
|
+
}
|
|
45
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemory } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftCredentialServer } from "../NamirasoftCredentialServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class AWSListCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, ["filters", "page", "size", "sorts"], []);
|
|
31
|
+
}
|
|
32
|
+
override async exec()
|
|
33
|
+
{
|
|
34
|
+
let token = this.app.storage.getNSAToken();
|
|
35
|
+
if (token == null)
|
|
36
|
+
throw new Error("Token is not available. Please login first using:\nns-credential account config \nor \nns-credential account login.");
|
|
37
|
+
let storage = new IStorageMemory();
|
|
38
|
+
let manager = new TokenManager(storage, () => { });
|
|
39
|
+
manager.setValue(token, false);
|
|
40
|
+
let url = this.app.storage.getItem("ns-credential-server-url");
|
|
41
|
+
let server = new NamirasoftCredentialServer(url, manager, e => this.app.logger.error(e.message));
|
|
42
|
+
let ans = await server.aws.List(this.arg_values[0], this.arg_values[1], this.arg_values[2], this.arg_values[3]);
|
|
43
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
44
|
+
}
|
|
45
|
+
};
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { AWSTagCreateCommand } from "./AWSTagCreateCommand";
|
|
22
|
+
import { AWSTagDeleteCommand } from "./AWSTagDeleteCommand";
|
|
23
|
+
import { AWSTagGetCommand } from "./AWSTagGetCommand";
|
|
24
|
+
import { AWSTagListCommand } from "./AWSTagListCommand";
|
|
25
|
+
import { AWSTagUpdateCommand } from "./AWSTagUpdateCommand";
|
|
26
|
+
import { BaseNavigatorCommand } from "namirasoft-node-cli";
|
|
27
|
+
|
|
28
|
+
export class AWSTagCommand extends BaseNavigatorCommand
|
|
29
|
+
{
|
|
30
|
+
constructor(argv: string[])
|
|
31
|
+
{
|
|
32
|
+
super(argv, {
|
|
33
|
+
"list": AWSTagListCommand,
|
|
34
|
+
"get": AWSTagGetCommand,
|
|
35
|
+
"create": AWSTagCreateCommand,
|
|
36
|
+
"update": AWSTagUpdateCommand,
|
|
37
|
+
"delete": AWSTagDeleteCommand,
|
|
38
|
+
});
|
|
39
|
+
}
|
|
40
|
+
};
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemory } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftCredentialServer } from "../NamirasoftCredentialServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class AWSTagCreateCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, ["entity_id"], [
|
|
31
|
+
{
|
|
32
|
+
name: "name",
|
|
33
|
+
short: "",
|
|
34
|
+
description: "Provides the value of 'name' in body",
|
|
35
|
+
optional: false,
|
|
36
|
+
args: ["name"],
|
|
37
|
+
defaults: [""]
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
name: "value",
|
|
41
|
+
short: "",
|
|
42
|
+
description: "Provides the value of 'value' in body",
|
|
43
|
+
optional: true,
|
|
44
|
+
args: ["value"],
|
|
45
|
+
defaults: [""]
|
|
46
|
+
}
|
|
47
|
+
]);
|
|
48
|
+
}
|
|
49
|
+
override async exec()
|
|
50
|
+
{
|
|
51
|
+
let token = this.app.storage.getNSAToken();
|
|
52
|
+
if (token == null)
|
|
53
|
+
throw new Error("Token is not available. Please login first using:\nns-credential account config \nor \nns-credential account login.");
|
|
54
|
+
let storage = new IStorageMemory();
|
|
55
|
+
let manager = new TokenManager(storage, () => { });
|
|
56
|
+
manager.setValue(token, false);
|
|
57
|
+
let url = this.app.storage.getItem("ns-credential-server-url");
|
|
58
|
+
let server = new NamirasoftCredentialServer(url, manager, e => this.app.logger.error(e.message));
|
|
59
|
+
let ans = await server.a_w_s_tag.Create(this.arg_values[0], {
|
|
60
|
+
name: this.option_values.name,
|
|
61
|
+
value: this.option_values.value
|
|
62
|
+
});
|
|
63
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
64
|
+
}
|
|
65
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemory } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftCredentialServer } from "../NamirasoftCredentialServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class AWSTagDeleteCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, ["entity_id", "id"], []);
|
|
31
|
+
}
|
|
32
|
+
override async exec()
|
|
33
|
+
{
|
|
34
|
+
let token = this.app.storage.getNSAToken();
|
|
35
|
+
if (token == null)
|
|
36
|
+
throw new Error("Token is not available. Please login first using:\nns-credential account config \nor \nns-credential account login.");
|
|
37
|
+
let storage = new IStorageMemory();
|
|
38
|
+
let manager = new TokenManager(storage, () => { });
|
|
39
|
+
manager.setValue(token, false);
|
|
40
|
+
let url = this.app.storage.getItem("ns-credential-server-url");
|
|
41
|
+
let server = new NamirasoftCredentialServer(url, manager, e => this.app.logger.error(e.message));
|
|
42
|
+
let ans = await server.a_w_s_tag.Delete(this.arg_values[0], this.arg_values[1]);
|
|
43
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
44
|
+
}
|
|
45
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemory } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftCredentialServer } from "../NamirasoftCredentialServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class AWSTagGetCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, ["id"], []);
|
|
31
|
+
}
|
|
32
|
+
override async exec()
|
|
33
|
+
{
|
|
34
|
+
let token = this.app.storage.getNSAToken();
|
|
35
|
+
if (token == null)
|
|
36
|
+
throw new Error("Token is not available. Please login first using:\nns-credential account config \nor \nns-credential account login.");
|
|
37
|
+
let storage = new IStorageMemory();
|
|
38
|
+
let manager = new TokenManager(storage, () => { });
|
|
39
|
+
manager.setValue(token, false);
|
|
40
|
+
let url = this.app.storage.getItem("ns-credential-server-url");
|
|
41
|
+
let server = new NamirasoftCredentialServer(url, manager, e => this.app.logger.error(e.message));
|
|
42
|
+
let ans = await server.a_w_s_tag.Get(this.arg_values[0]);
|
|
43
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
44
|
+
}
|
|
45
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemory } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftCredentialServer } from "../NamirasoftCredentialServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class AWSTagListCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, ["filters", "page", "size", "sorts"], []);
|
|
31
|
+
}
|
|
32
|
+
override async exec()
|
|
33
|
+
{
|
|
34
|
+
let token = this.app.storage.getNSAToken();
|
|
35
|
+
if (token == null)
|
|
36
|
+
throw new Error("Token is not available. Please login first using:\nns-credential account config \nor \nns-credential account login.");
|
|
37
|
+
let storage = new IStorageMemory();
|
|
38
|
+
let manager = new TokenManager(storage, () => { });
|
|
39
|
+
manager.setValue(token, false);
|
|
40
|
+
let url = this.app.storage.getItem("ns-credential-server-url");
|
|
41
|
+
let server = new NamirasoftCredentialServer(url, manager, e => this.app.logger.error(e.message));
|
|
42
|
+
let ans = await server.a_w_s_tag.List(this.arg_values[0], this.arg_values[1], this.arg_values[2], this.arg_values[3]);
|
|
43
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
44
|
+
}
|
|
45
|
+
};
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemory } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftCredentialServer } from "../NamirasoftCredentialServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class AWSTagUpdateCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, ["entity_id", "id"], [
|
|
31
|
+
{
|
|
32
|
+
name: "name",
|
|
33
|
+
short: "",
|
|
34
|
+
description: "Provides the value of 'name' in body",
|
|
35
|
+
optional: false,
|
|
36
|
+
args: ["name"],
|
|
37
|
+
defaults: [""]
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
name: "value",
|
|
41
|
+
short: "",
|
|
42
|
+
description: "Provides the value of 'value' in body",
|
|
43
|
+
optional: true,
|
|
44
|
+
args: ["value"],
|
|
45
|
+
defaults: [""]
|
|
46
|
+
}
|
|
47
|
+
]);
|
|
48
|
+
}
|
|
49
|
+
override async exec()
|
|
50
|
+
{
|
|
51
|
+
let token = this.app.storage.getNSAToken();
|
|
52
|
+
if (token == null)
|
|
53
|
+
throw new Error("Token is not available. Please login first using:\nns-credential account config \nor \nns-credential account login.");
|
|
54
|
+
let storage = new IStorageMemory();
|
|
55
|
+
let manager = new TokenManager(storage, () => { });
|
|
56
|
+
manager.setValue(token, false);
|
|
57
|
+
let url = this.app.storage.getItem("ns-credential-server-url");
|
|
58
|
+
let server = new NamirasoftCredentialServer(url, manager, e => this.app.logger.error(e.message));
|
|
59
|
+
let ans = await server.a_w_s_tag.Update(this.arg_values[0], this.arg_values[1], {
|
|
60
|
+
name: this.option_values.name,
|
|
61
|
+
value: this.option_values.value
|
|
62
|
+
});
|
|
63
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
64
|
+
}
|
|
65
|
+
};
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemory } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftCredentialServer } from "../NamirasoftCredentialServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class AWSUpdateCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, ["id"], [
|
|
31
|
+
{
|
|
32
|
+
name: "workspace_id",
|
|
33
|
+
short: "",
|
|
34
|
+
description: "Provides the value of 'workspace_id' in body",
|
|
35
|
+
optional: true,
|
|
36
|
+
args: ["workspace_id"],
|
|
37
|
+
defaults: [""]
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
name: "name",
|
|
41
|
+
short: "",
|
|
42
|
+
description: "Provides the value of 'name' in body",
|
|
43
|
+
optional: false,
|
|
44
|
+
args: ["name"],
|
|
45
|
+
defaults: [""]
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
name: "access_key",
|
|
49
|
+
short: "",
|
|
50
|
+
description: "Provides the value of 'access_key' in body",
|
|
51
|
+
optional: false,
|
|
52
|
+
args: ["access_key"],
|
|
53
|
+
defaults: [""]
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
name: "secret_key",
|
|
57
|
+
short: "",
|
|
58
|
+
description: "Provides the value of 'secret_key' in body",
|
|
59
|
+
optional: false,
|
|
60
|
+
args: ["secret_key"],
|
|
61
|
+
defaults: [""]
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
name: "description",
|
|
65
|
+
short: "",
|
|
66
|
+
description: "Provides the value of 'description' in body",
|
|
67
|
+
optional: false,
|
|
68
|
+
args: ["description"],
|
|
69
|
+
defaults: [""]
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
name: "aws_category",
|
|
73
|
+
short: "",
|
|
74
|
+
description: "Provides the value of 'aws_category' in body",
|
|
75
|
+
optional: false,
|
|
76
|
+
args: ["aws_category"],
|
|
77
|
+
defaults: [""]
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
name: "aws_field",
|
|
81
|
+
short: "",
|
|
82
|
+
description: "Provides the value of 'aws_field' in body",
|
|
83
|
+
optional: false,
|
|
84
|
+
args: ["aws_field"],
|
|
85
|
+
defaults: [""]
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
name: "aws_tag",
|
|
89
|
+
short: "",
|
|
90
|
+
description: "Provides the value of 'aws_tag' in body",
|
|
91
|
+
optional: false,
|
|
92
|
+
args: ["aws_tag"],
|
|
93
|
+
defaults: [""]
|
|
94
|
+
}
|
|
95
|
+
]);
|
|
96
|
+
}
|
|
97
|
+
override async exec()
|
|
98
|
+
{
|
|
99
|
+
let token = this.app.storage.getNSAToken();
|
|
100
|
+
if (token == null)
|
|
101
|
+
throw new Error("Token is not available. Please login first using:\nns-credential account config \nor \nns-credential account login.");
|
|
102
|
+
let storage = new IStorageMemory();
|
|
103
|
+
let manager = new TokenManager(storage, () => { });
|
|
104
|
+
manager.setValue(token, false);
|
|
105
|
+
let url = this.app.storage.getItem("ns-credential-server-url");
|
|
106
|
+
let server = new NamirasoftCredentialServer(url, manager, e => this.app.logger.error(e.message));
|
|
107
|
+
let ans = await server.aws.Update(this.arg_values[0], {
|
|
108
|
+
workspace_id: this.option_values.workspace_id,
|
|
109
|
+
name: this.option_values.name,
|
|
110
|
+
access_key: this.option_values.access_key,
|
|
111
|
+
secret_key: this.option_values.secret_key,
|
|
112
|
+
description: this.option_values.description,
|
|
113
|
+
aws_category: this.option_values.aws_category,
|
|
114
|
+
aws_field: this.option_values.aws_field,
|
|
115
|
+
aws_tag: this.option_values.aws_tag
|
|
116
|
+
});
|
|
117
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
118
|
+
}
|
|
119
|
+
};
|