chatbot-nc 1.0.41 → 1.0.42

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.
@@ -7,6 +7,9 @@ export declare const AWS: {
7
7
  getS3FileStream: (bucket: string, file: string) => Promise<import("@aws-sdk/types").SdkStream<Blob | ReadableStream<any> | import("stream").Readable | undefined> | undefined>;
8
8
  getS3File: (bucket: string, file: string) => Promise<string | undefined>;
9
9
  };
10
+ Lambda: {
11
+ listFunctions: () => Promise<import("@aws-sdk/client-lambda").FunctionConfiguration[] | undefined>;
12
+ };
10
13
  LexRuntime: {
11
14
  recognizeText: (lexParams: import("@aws-sdk/client-lex-runtime-v2").RecognizeTextCommandInput) => Promise<import("@aws-sdk/client-lex-runtime-v2").RecognizeTextCommandOutput>;
12
15
  };
@@ -22,8 +22,10 @@ const AWSSTS_1 = require("./services/AWSSTS");
22
22
  const AWSGateway_1 = require("./services/AWSGateway");
23
23
  const AWSCodepipeline_1 = require("./services/AWSCodepipeline");
24
24
  const AWSTranslate_1 = require("./services/AWSTranslate");
25
+ const AWSLambda_1 = require("./services/AWSLambda");
25
26
  exports.AWS = {
26
27
  S3: AWSS3_1.S3,
28
+ Lambda: AWSLambda_1.Lambda,
27
29
  LexRuntime: AWSLexRuntime_1.LexRuntime,
28
30
  LexModel: AWSLexModel_1.LexModel,
29
31
  DynamoDb: AWSDynamoDb_1.DynamoDb,
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../aws/index.ts"],"names":[],"mappings":";;;AAAA,4CAAsC;AACtC,4DAAsD;AACtD,wDAAkD;AAClD,8CAAwC;AACxC,8CAAwC;AACxC,4EAAuD;AACvD,wDAAkD;AAClD,wDAAkD;AAClD,wEAAkE;AAClE,sDAAgD;AAChD,4EAAsE;AACtE,0EAAoE;AACpE,8CAAwC;AACxC,4DAAuD;AACvD,wEAAkE;AAClE,gEAA2D;AAC3D,gEAAoD;AACpD,8CAAwC;AACxC,sD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G;IACH,QAAQ,EAAR,sBAAQ;IACR,gBAAgB,EAAhB,sCAAgB;IAChB,OAAO,EAAP,oBAAO;IACP,kBAAkB,EAAlB,0CAAkB;IAClB,iBAAiB,EAAjB,wCAAiB;IACjB,UAAU,EAAV,0BAAU;IACV,eAAe,EAAf,qCAAe;IACf,YAAY,EAAZ,8BAAY;IACZ,KAAK,EAAL,uBAAK;IACL,GAAG,EAAH,YAAG;IACH,OAAO,EAAP,oBAAO;IACP,YAAY,EAAZ,8BAAY;IACZ,SAAS,EAAT,wBAAS;CACZ,CAAA"}
@@ -0,0 +1,3 @@
1
+ export declare const Lambda: {
2
+ listFunctions: () => Promise<import("@aws-sdk/client-lambda").FunctionConfiguration[] | undefined>;
3
+ };
@@ -0,0 +1,34 @@
1
+ "use strict";
2
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
+ return new (P || (P = Promise))(function (resolve, reject) {
5
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
9
+ });
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.Lambda = void 0;
13
+ // const log = require('../../Logger').getLogger();
14
+ const client_lambda_1 = require("@aws-sdk/client-lambda"); // ES Modules import
15
+ const awsRegion = process.env.AWS_DEFAULT_REGION || 'us-east-1';
16
+ const client = new client_lambda_1.LambdaClient({ region: awsRegion });
17
+ /**
18
+ * Get List of Functions
19
+ * @returns
20
+ */
21
+ const listFunctions = () => __awaiter(void 0, void 0, void 0, function* () {
22
+ try {
23
+ const command = yield new client_lambda_1.ListFunctionsCommand({});
24
+ let response = yield client.send(command);
25
+ return response.Functions;
26
+ }
27
+ catch (error) {
28
+ throw error;
29
+ }
30
+ });
31
+ exports.Lambda = {
32
+ listFunctions
33
+ };
34
+ //# sourceMappingURL=AWSLambda.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AWSLambda.js","sourceRoot":"","sources":["../../../../aws/services/AWSLambda.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,mDAAmD;AACnD,0DAA4E,CAAC,oBAAoB;AAEjG,MAAM,SAAS,GAAG,OAAO,CAAC,GAAG,CAAC,kBAAkB,IAAI,WAAW,CAAC;AAChE,MAAM,MAAM,GAAG,IAAI,4BAAY,CAAC,EAAE,MAAM,EAAE,SAAS,EAAE,CAAC,CAAC;AAEvD;;;GAGG;AACH,MAAM,aAAa,GAAG,GAAO,EAAE;IAC7B,IAAI;QACE,MAAM,OAAO,GAAG,MAAM,IAAI,oCAAoB,CAAC,EAAE,CAAC,CAAC;QACnD,IAAI,QAAQ,GAAG,MAAM,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QAC1C,OAAO,QAAQ,CAAC,SAAS,CAAC;KAC/B;IAAC,OAAO,KAAK,EAAE;QACZ,MAAO,KAAK,CAAC;KAChB;AACH,CAAC,CAAA,CAAA;AAEY,QAAA,MAAM,GAAG;IACjB,aAAa;CACjB,CAAA"}
@@ -7,6 +7,9 @@ export declare const AWS: {
7
7
  getS3FileStream: (bucket: string, file: string) => Promise<import("@aws-sdk/types").SdkStream<Blob | ReadableStream<any> | import("stream").Readable | undefined> | undefined>;
8
8
  getS3File: (bucket: string, file: string) => Promise<string | undefined>;
9
9
  };
10
+ Lambda: {
11
+ listFunctions: () => Promise<import("@aws-sdk/client-lambda").FunctionConfiguration[] | undefined>;
12
+ };
10
13
  LexRuntime: {
11
14
  recognizeText: (lexParams: import("@aws-sdk/client-lex-runtime-v2").RecognizeTextCommandInput) => Promise<import("@aws-sdk/client-lex-runtime-v2").RecognizeTextCommandOutput>;
12
15
  };
@@ -19,8 +19,10 @@ import { STS } from "./services/AWSSTS";
19
19
  import { Gateway } from "./services/AWSGateway";
20
20
  import { CodePipeline } from "./services/AWSCodepipeline";
21
21
  import { Translate } from "./services/AWSTranslate";
22
+ import { Lambda } from "./services/AWSLambda";
22
23
  export const AWS = {
23
24
  S3,
25
+ Lambda,
24
26
  LexRuntime,
25
27
  LexModel,
26
28
  DynamoDb,
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../aws/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,kBAAkB,CAAC;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AACtD,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,GAAG,EAAE,MAAM,kCAAkC,CAAC;AACvD,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAC;AAClE,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAChD,OAAO,EAAE,kBAAkB,EAAE,MAAM,kCAAkC,CAAC;AACtE,OAAO,EAAE,iBAAiB,EAAE,MAAM,iCAAiC,CAAC;AACpE,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAO,0BAA0B,CAAC;AACvD,OAAO,EAAE,eAAe,EAAE,MAAO,gCAAgC,CAAC;AAClE,OAAO,EAAE,YAAY,EAAE,MAAO,4BAA4B,CAAC;AAC3D,OAAO,EAAE,KAAK,EAAE,MAAO,4BAA4B,CAAC;AACpD,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MA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AO,gCAAgC,CAAC;AAClE,OAAO,EAAE,YAAY,EAAE,MAAO,4BAA4B,CAAC;AAC3D,OAAO,EAAE,KAAK,EAAE,MAAO,4BAA4B,CAAC;AACpD,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAChD,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAC;AACpD,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAG9C,MAAM,CAAC,MAAM,GAAG,GAAG;IACf,EAAE;IACF,MAAM;IACN,UAAU;IACV,QAAQ;IACR,QAAQ;IACR,GAAG;IACH,GAAG;IACH,GAAG;IACH,GAAG;IACH,QAAQ;IACR,gBAAgB;IAChB,OAAO;IACP,kBAAkB;IAClB,iBAAiB;IACjB,UAAU;IACV,eAAe;IACf,YAAY;IACZ,KAAK;IACL,GAAG;IACH,OAAO;IACP,YAAY;IACZ,SAAS;CACZ,CAAA"}
@@ -0,0 +1,3 @@
1
+ export declare const Lambda: {
2
+ listFunctions: () => Promise<import("@aws-sdk/client-lambda").FunctionConfiguration[] | undefined>;
3
+ };
@@ -0,0 +1,31 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ // const log = require('../../Logger').getLogger();
11
+ import { LambdaClient, ListFunctionsCommand } from "@aws-sdk/client-lambda"; // ES Modules import
12
+ const awsRegion = process.env.AWS_DEFAULT_REGION || 'us-east-1';
13
+ const client = new LambdaClient({ region: awsRegion });
14
+ /**
15
+ * Get List of Functions
16
+ * @returns
17
+ */
18
+ const listFunctions = () => __awaiter(void 0, void 0, void 0, function* () {
19
+ try {
20
+ const command = yield new ListFunctionsCommand({});
21
+ let response = yield client.send(command);
22
+ return response.Functions;
23
+ }
24
+ catch (error) {
25
+ throw error;
26
+ }
27
+ });
28
+ export const Lambda = {
29
+ listFunctions
30
+ };
31
+ //# sourceMappingURL=AWSLambda.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AWSLambda.js","sourceRoot":"","sources":["../../../../aws/services/AWSLambda.ts"],"names":[],"mappings":";;;;;;;;;AAAA,mDAAmD;AACnD,OAAO,EAAE,YAAY,EAAC,oBAAoB,EAAG,MAAM,wBAAwB,CAAC,CAAC,oBAAoB;AAEjG,MAAM,SAAS,GAAG,OAAO,CAAC,GAAG,CAAC,kBAAkB,IAAI,WAAW,CAAC;AAChE,MAAM,MAAM,GAAG,IAAI,YAAY,CAAC,EAAE,MAAM,EAAE,SAAS,EAAE,CAAC,CAAC;AAEvD;;;GAGG;AACH,MAAM,aAAa,GAAG,GAAO,EAAE;IAC7B,IAAI;QACE,MAAM,OAAO,GAAG,MAAM,IAAI,oBAAoB,CAAC,EAAE,CAAC,CAAC;QACnD,IAAI,QAAQ,GAAG,MAAM,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QAC1C,OAAO,QAAQ,CAAC,SAAS,CAAC;KAC/B;IAAC,OAAO,KAAK,EAAE;QACZ,MAAO,KAAK,CAAC;KAChB;AACH,CAAC,CAAA,CAAA;AAED,MAAM,CAAC,MAAM,MAAM,GAAG;IACjB,aAAa;CACjB,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "chatbot-nc",
3
- "version": "1.0.41",
3
+ "version": "1.0.42",
4
4
  "description": "",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",