@major-tech/resource-client 0.2.11 → 0.2.13
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/bin/generate-clients.mjs +4 -3
- package/dist/clients/lambda.cjs +86 -0
- package/dist/clients/lambda.cjs.map +7 -0
- package/dist/clients/lambda.d.ts +90 -0
- package/dist/clients/lambda.d.ts.map +1 -0
- package/dist/clients/lambda.js +59 -0
- package/dist/clients/lambda.js.map +1 -0
- package/dist/index.cjs +2 -0
- package/dist/index.cjs.map +2 -2
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/schemas/index.cjs +1 -0
- package/dist/schemas/index.cjs.map +2 -2
- package/dist/schemas/index.d.ts +3 -1
- package/dist/schemas/index.d.ts.map +1 -1
- package/dist/schemas/index.js +1 -0
- package/dist/schemas/index.js.map +1 -1
- package/dist/schemas/lambda.cjs +17 -0
- package/dist/schemas/lambda.cjs.map +7 -0
- package/dist/schemas/lambda.d.ts +107 -0
- package/dist/schemas/lambda.d.ts.map +1 -0
- package/dist/schemas/lambda.js +2 -0
- package/dist/schemas/lambda.js.map +1 -0
- package/dist/schemas/response.d.ts +6 -1
- package/dist/schemas/response.d.ts.map +1 -1
- package/package.json +1 -1
package/bin/generate-clients.mjs
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
* npx @major-tech/resource-client remove <name>
|
|
9
9
|
* npx @major-tech/resource-client list
|
|
10
10
|
*
|
|
11
|
-
* Types: database-postgresql | database-mssql | database-dynamodb | database-cosmosdb | database-snowflake | api-hubspot | api-googlesheets | api-custom | storage-s3
|
|
11
|
+
* Types: database-postgresql | database-mssql | database-dynamodb | database-cosmosdb | database-snowflake | api-hubspot | api-googlesheets | api-custom | api-lambda | storage-s3
|
|
12
12
|
*
|
|
13
13
|
* Examples:
|
|
14
14
|
* npx @major-tech/resource-client add "abc-123" "orders-db" "database-postgresql" "Orders database" "app-123"
|
|
@@ -148,6 +148,7 @@ function getClientClass(type) {
|
|
|
148
148
|
'api-custom': 'CustomApiResourceClient',
|
|
149
149
|
'api-hubspot': 'HubSpotResourceClient',
|
|
150
150
|
'api-googlesheets': 'GoogleSheetsResourceClient',
|
|
151
|
+
'api-lambda': 'LambdaResourceClient',
|
|
151
152
|
'storage-s3': 'S3ResourceClient',
|
|
152
153
|
};
|
|
153
154
|
return typeMap[type] || 'PostgresResourceClient';
|
|
@@ -182,7 +183,7 @@ function generateIndexFile(resources) {
|
|
|
182
183
|
}
|
|
183
184
|
|
|
184
185
|
function addResource(resourceId, name, type, description, applicationId, framework) {
|
|
185
|
-
const validTypes = ['database-postgresql', 'database-mssql', 'database-dynamodb', 'database-cosmosdb', 'database-snowflake', 'api-hubspot', 'api-googlesheets', 'api-custom', 'storage-s3'];
|
|
186
|
+
const validTypes = ['database-postgresql', 'database-mssql', 'database-dynamodb', 'database-cosmosdb', 'database-snowflake', 'api-hubspot', 'api-googlesheets', 'api-custom', 'api-lambda', 'storage-s3'];
|
|
186
187
|
if (!validTypes.includes(type)) {
|
|
187
188
|
console.error(`❌ Invalid type: ${type}`);
|
|
188
189
|
console.error(` Valid types: ${validTypes.join(', ')}`);
|
|
@@ -319,7 +320,7 @@ function main() {
|
|
|
319
320
|
console.log(' npx @major-tech/resource-client add <resource_id> <name> <type> <description> <application_id> [--framework <nextjs|vite>]');
|
|
320
321
|
console.log(' npx @major-tech/resource-client remove <name> [--framework <nextjs|vite>]');
|
|
321
322
|
console.log(' npx @major-tech/resource-client list');
|
|
322
|
-
console.log('\nTypes: database-postgresql | database-mssql | database-dynamodb | database-cosmosdb | database-snowflake | api-hubspot | api-googlesheets | api-custom | storage-s3');
|
|
323
|
+
console.log('\nTypes: database-postgresql | database-mssql | database-dynamodb | database-cosmosdb | database-snowflake | api-hubspot | api-googlesheets | api-custom | api-lambda | storage-s3');
|
|
323
324
|
return;
|
|
324
325
|
}
|
|
325
326
|
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
7
|
+
var __export = (target, all) => {
|
|
8
|
+
for (var name in all)
|
|
9
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
10
|
+
};
|
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
13
|
+
for (let key of __getOwnPropNames(from))
|
|
14
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
15
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
16
|
+
}
|
|
17
|
+
return to;
|
|
18
|
+
};
|
|
19
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
20
|
+
var lambda_exports = {};
|
|
21
|
+
__export(lambda_exports, {
|
|
22
|
+
LambdaResourceClient: () => LambdaResourceClient
|
|
23
|
+
});
|
|
24
|
+
module.exports = __toCommonJS(lambda_exports);
|
|
25
|
+
var import_base = require("../base");
|
|
26
|
+
class LambdaResourceClient extends import_base.BaseResourceClient {
|
|
27
|
+
static {
|
|
28
|
+
__name(this, "LambdaResourceClient");
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Invoke a Lambda function
|
|
32
|
+
*
|
|
33
|
+
* @param functionName - The name, ARN, or partial ARN of the Lambda function
|
|
34
|
+
* @param payload - The JSON input for the Lambda function (optional)
|
|
35
|
+
* @param invocationKey - A unique key for tracking this invocation
|
|
36
|
+
* @param options - Additional invocation options
|
|
37
|
+
* @returns The Lambda invocation result
|
|
38
|
+
*
|
|
39
|
+
* @example
|
|
40
|
+
* ```typescript
|
|
41
|
+
* // Simple synchronous invocation
|
|
42
|
+
* const result = await lambdaClient.invoke(
|
|
43
|
+
* "my-function",
|
|
44
|
+
* { key: "value" },
|
|
45
|
+
* "process-data"
|
|
46
|
+
* );
|
|
47
|
+
*
|
|
48
|
+
* if (result.ok) {
|
|
49
|
+
* console.log("Response:", result.result.Payload);
|
|
50
|
+
* }
|
|
51
|
+
*
|
|
52
|
+
* // Asynchronous invocation
|
|
53
|
+
* const asyncResult = await lambdaClient.invoke(
|
|
54
|
+
* "my-function",
|
|
55
|
+
* { key: "value" },
|
|
56
|
+
* "async-process",
|
|
57
|
+
* { InvocationType: "Event" }
|
|
58
|
+
* );
|
|
59
|
+
*
|
|
60
|
+
* // With execution logs
|
|
61
|
+
* const debugResult = await lambdaClient.invoke(
|
|
62
|
+
* "my-function",
|
|
63
|
+
* { key: "value" },
|
|
64
|
+
* "debug-invocation",
|
|
65
|
+
* { LogType: "Tail" }
|
|
66
|
+
* );
|
|
67
|
+
*
|
|
68
|
+
* if (debugResult.ok) {
|
|
69
|
+
* // LogResult is base64 encoded
|
|
70
|
+
* const logs = atob(debugResult.result.LogResult || "");
|
|
71
|
+
* console.log("Execution logs:", logs);
|
|
72
|
+
* }
|
|
73
|
+
* ```
|
|
74
|
+
*/
|
|
75
|
+
async invoke(functionName, payload, invocationKey, options = {}) {
|
|
76
|
+
const invokePayload = {
|
|
77
|
+
type: "api",
|
|
78
|
+
subtype: "lambda",
|
|
79
|
+
FunctionName: functionName,
|
|
80
|
+
Payload: payload,
|
|
81
|
+
...options
|
|
82
|
+
};
|
|
83
|
+
return this.invokeRaw(invokePayload, invocationKey);
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
//# sourceMappingURL=lambda.cjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/clients/lambda.ts"],
|
|
4
|
+
"sourcesContent": ["import type {\n ApiLambdaPayload,\n ApiLambdaResult,\n LambdaInvocationType,\n LambdaLogType,\n} from \"../schemas\";\nimport type { BaseInvokeSuccess, InvokeFailure } from \"../schemas/response\";\nimport { BaseResourceClient } from \"../base\";\n\n/**\n * Options for Lambda invocation\n */\nexport interface LambdaInvokeOptions {\n /**\n * The invocation mode.\n * - RequestResponse (default): Synchronous invocation\n * - Event: Asynchronous invocation\n * - DryRun: Validate parameters and permissions only\n */\n InvocationType?: LambdaInvocationType;\n\n /**\n * Controls execution log inclusion in the response.\n * - None (default): Don't include logs\n * - Tail: Include the last 4 KB of execution log (sync only)\n */\n LogType?: LambdaLogType;\n\n /**\n * Specifies a version or alias to invoke.\n * If not specified, invokes $LATEST.\n */\n Qualifier?: string;\n\n /**\n * Up to 3,583 bytes of base64-encoded data about the invoking client\n * to pass to the function. Only for synchronous invocations.\n */\n ClientContext?: string;\n\n /**\n * A unique name for durable execution.\n * Length: 1-64 characters. Pattern: [a-zA-Z0-9-_]+\n */\n DurableExecutionName?: string;\n\n /**\n * The identifier for tenant in multi-tenant Lambda function.\n * Length: 1-256 characters.\n */\n TenantId?: string;\n}\n\nexport class LambdaResourceClient extends BaseResourceClient {\n /**\n * Invoke a Lambda function\n *\n * @param functionName - The name, ARN, or partial ARN of the Lambda function\n * @param payload - The JSON input for the Lambda function (optional)\n * @param invocationKey - A unique key for tracking this invocation\n * @param options - Additional invocation options\n * @returns The Lambda invocation result\n *\n * @example\n * ```typescript\n * // Simple synchronous invocation\n * const result = await lambdaClient.invoke(\n * \"my-function\",\n * { key: \"value\" },\n * \"process-data\"\n * );\n *\n * if (result.ok) {\n * console.log(\"Response:\", result.result.Payload);\n * }\n *\n * // Asynchronous invocation\n * const asyncResult = await lambdaClient.invoke(\n * \"my-function\",\n * { key: \"value\" },\n * \"async-process\",\n * { InvocationType: \"Event\" }\n * );\n *\n * // With execution logs\n * const debugResult = await lambdaClient.invoke(\n * \"my-function\",\n * { key: \"value\" },\n * \"debug-invocation\",\n * { LogType: \"Tail\" }\n * );\n *\n * if (debugResult.ok) {\n * // LogResult is base64 encoded\n * const logs = atob(debugResult.result.LogResult || \"\");\n * console.log(\"Execution logs:\", logs);\n * }\n * ```\n */\n async invoke(\n functionName: string,\n payload: unknown,\n invocationKey: string,\n options: LambdaInvokeOptions = {},\n ): Promise<BaseInvokeSuccess<ApiLambdaResult> | InvokeFailure> {\n const invokePayload: ApiLambdaPayload = {\n type: \"api\",\n subtype: \"lambda\",\n FunctionName: functionName,\n Payload: payload,\n ...options,\n };\n\n return this.invokeRaw(invokePayload, invocationKey) as Promise<\n BaseInvokeSuccess<ApiLambdaResult> | InvokeFailure\n >;\n }\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;AAOA;;;;;AAAA,kBAAmC;AA8C7B,MAAO,6BAA6B,+BAAkB;EA9C5D,OA8C4D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA8C1D,MAAM,OACJ,cACA,SACA,eACA,UAA+B,CAAA,GAAE;AAEjC,UAAM,gBAAkC;MACtC,MAAM;MACN,SAAS;MACT,cAAc;MACd,SAAS;MACT,GAAG;;AAGL,WAAO,KAAK,UAAU,eAAe,aAAa;EAGpD;;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import type { ApiLambdaResult, LambdaInvocationType, LambdaLogType } from "../schemas";
|
|
2
|
+
import type { BaseInvokeSuccess, InvokeFailure } from "../schemas/response";
|
|
3
|
+
import { BaseResourceClient } from "../base";
|
|
4
|
+
/**
|
|
5
|
+
* Options for Lambda invocation
|
|
6
|
+
*/
|
|
7
|
+
export interface LambdaInvokeOptions {
|
|
8
|
+
/**
|
|
9
|
+
* The invocation mode.
|
|
10
|
+
* - RequestResponse (default): Synchronous invocation
|
|
11
|
+
* - Event: Asynchronous invocation
|
|
12
|
+
* - DryRun: Validate parameters and permissions only
|
|
13
|
+
*/
|
|
14
|
+
InvocationType?: LambdaInvocationType;
|
|
15
|
+
/**
|
|
16
|
+
* Controls execution log inclusion in the response.
|
|
17
|
+
* - None (default): Don't include logs
|
|
18
|
+
* - Tail: Include the last 4 KB of execution log (sync only)
|
|
19
|
+
*/
|
|
20
|
+
LogType?: LambdaLogType;
|
|
21
|
+
/**
|
|
22
|
+
* Specifies a version or alias to invoke.
|
|
23
|
+
* If not specified, invokes $LATEST.
|
|
24
|
+
*/
|
|
25
|
+
Qualifier?: string;
|
|
26
|
+
/**
|
|
27
|
+
* Up to 3,583 bytes of base64-encoded data about the invoking client
|
|
28
|
+
* to pass to the function. Only for synchronous invocations.
|
|
29
|
+
*/
|
|
30
|
+
ClientContext?: string;
|
|
31
|
+
/**
|
|
32
|
+
* A unique name for durable execution.
|
|
33
|
+
* Length: 1-64 characters. Pattern: [a-zA-Z0-9-_]+
|
|
34
|
+
*/
|
|
35
|
+
DurableExecutionName?: string;
|
|
36
|
+
/**
|
|
37
|
+
* The identifier for tenant in multi-tenant Lambda function.
|
|
38
|
+
* Length: 1-256 characters.
|
|
39
|
+
*/
|
|
40
|
+
TenantId?: string;
|
|
41
|
+
}
|
|
42
|
+
export declare class LambdaResourceClient extends BaseResourceClient {
|
|
43
|
+
/**
|
|
44
|
+
* Invoke a Lambda function
|
|
45
|
+
*
|
|
46
|
+
* @param functionName - The name, ARN, or partial ARN of the Lambda function
|
|
47
|
+
* @param payload - The JSON input for the Lambda function (optional)
|
|
48
|
+
* @param invocationKey - A unique key for tracking this invocation
|
|
49
|
+
* @param options - Additional invocation options
|
|
50
|
+
* @returns The Lambda invocation result
|
|
51
|
+
*
|
|
52
|
+
* @example
|
|
53
|
+
* ```typescript
|
|
54
|
+
* // Simple synchronous invocation
|
|
55
|
+
* const result = await lambdaClient.invoke(
|
|
56
|
+
* "my-function",
|
|
57
|
+
* { key: "value" },
|
|
58
|
+
* "process-data"
|
|
59
|
+
* );
|
|
60
|
+
*
|
|
61
|
+
* if (result.ok) {
|
|
62
|
+
* console.log("Response:", result.result.Payload);
|
|
63
|
+
* }
|
|
64
|
+
*
|
|
65
|
+
* // Asynchronous invocation
|
|
66
|
+
* const asyncResult = await lambdaClient.invoke(
|
|
67
|
+
* "my-function",
|
|
68
|
+
* { key: "value" },
|
|
69
|
+
* "async-process",
|
|
70
|
+
* { InvocationType: "Event" }
|
|
71
|
+
* );
|
|
72
|
+
*
|
|
73
|
+
* // With execution logs
|
|
74
|
+
* const debugResult = await lambdaClient.invoke(
|
|
75
|
+
* "my-function",
|
|
76
|
+
* { key: "value" },
|
|
77
|
+
* "debug-invocation",
|
|
78
|
+
* { LogType: "Tail" }
|
|
79
|
+
* );
|
|
80
|
+
*
|
|
81
|
+
* if (debugResult.ok) {
|
|
82
|
+
* // LogResult is base64 encoded
|
|
83
|
+
* const logs = atob(debugResult.result.LogResult || "");
|
|
84
|
+
* console.log("Execution logs:", logs);
|
|
85
|
+
* }
|
|
86
|
+
* ```
|
|
87
|
+
*/
|
|
88
|
+
invoke(functionName: string, payload: unknown, invocationKey: string, options?: LambdaInvokeOptions): Promise<BaseInvokeSuccess<ApiLambdaResult> | InvokeFailure>;
|
|
89
|
+
}
|
|
90
|
+
//# sourceMappingURL=lambda.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lambda.d.ts","sourceRoot":"","sources":["../../src/clients/lambda.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAEV,eAAe,EACf,oBAAoB,EACpB,aAAa,EACd,MAAM,YAAY,CAAC;AACpB,OAAO,KAAK,EAAE,iBAAiB,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAC5E,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAE7C;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC;;;;;OAKG;IACH,cAAc,CAAC,EAAE,oBAAoB,CAAC;IAEtC;;;;OAIG;IACH,OAAO,CAAC,EAAE,aAAa,CAAC;IAExB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;;OAGG;IACH,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAE9B;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,qBAAa,oBAAqB,SAAQ,kBAAkB;IAC1D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA4CG;IACG,MAAM,CACV,YAAY,EAAE,MAAM,EACpB,OAAO,EAAE,OAAO,EAChB,aAAa,EAAE,MAAM,EACrB,OAAO,GAAE,mBAAwB,GAChC,OAAO,CAAC,iBAAiB,CAAC,eAAe,CAAC,GAAG,aAAa,CAAC;CAa/D"}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { BaseResourceClient } from "../base";
|
|
2
|
+
export class LambdaResourceClient extends BaseResourceClient {
|
|
3
|
+
/**
|
|
4
|
+
* Invoke a Lambda function
|
|
5
|
+
*
|
|
6
|
+
* @param functionName - The name, ARN, or partial ARN of the Lambda function
|
|
7
|
+
* @param payload - The JSON input for the Lambda function (optional)
|
|
8
|
+
* @param invocationKey - A unique key for tracking this invocation
|
|
9
|
+
* @param options - Additional invocation options
|
|
10
|
+
* @returns The Lambda invocation result
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* ```typescript
|
|
14
|
+
* // Simple synchronous invocation
|
|
15
|
+
* const result = await lambdaClient.invoke(
|
|
16
|
+
* "my-function",
|
|
17
|
+
* { key: "value" },
|
|
18
|
+
* "process-data"
|
|
19
|
+
* );
|
|
20
|
+
*
|
|
21
|
+
* if (result.ok) {
|
|
22
|
+
* console.log("Response:", result.result.Payload);
|
|
23
|
+
* }
|
|
24
|
+
*
|
|
25
|
+
* // Asynchronous invocation
|
|
26
|
+
* const asyncResult = await lambdaClient.invoke(
|
|
27
|
+
* "my-function",
|
|
28
|
+
* { key: "value" },
|
|
29
|
+
* "async-process",
|
|
30
|
+
* { InvocationType: "Event" }
|
|
31
|
+
* );
|
|
32
|
+
*
|
|
33
|
+
* // With execution logs
|
|
34
|
+
* const debugResult = await lambdaClient.invoke(
|
|
35
|
+
* "my-function",
|
|
36
|
+
* { key: "value" },
|
|
37
|
+
* "debug-invocation",
|
|
38
|
+
* { LogType: "Tail" }
|
|
39
|
+
* );
|
|
40
|
+
*
|
|
41
|
+
* if (debugResult.ok) {
|
|
42
|
+
* // LogResult is base64 encoded
|
|
43
|
+
* const logs = atob(debugResult.result.LogResult || "");
|
|
44
|
+
* console.log("Execution logs:", logs);
|
|
45
|
+
* }
|
|
46
|
+
* ```
|
|
47
|
+
*/
|
|
48
|
+
async invoke(functionName, payload, invocationKey, options = {}) {
|
|
49
|
+
const invokePayload = {
|
|
50
|
+
type: "api",
|
|
51
|
+
subtype: "lambda",
|
|
52
|
+
FunctionName: functionName,
|
|
53
|
+
Payload: payload,
|
|
54
|
+
...options,
|
|
55
|
+
};
|
|
56
|
+
return this.invokeRaw(invokePayload, invocationKey);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
//# sourceMappingURL=lambda.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lambda.js","sourceRoot":"","sources":["../../src/clients/lambda.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AA8C7C,MAAM,OAAO,oBAAqB,SAAQ,kBAAkB;IAC1D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA4CG;IACH,KAAK,CAAC,MAAM,CACV,YAAoB,EACpB,OAAgB,EAChB,aAAqB,EACrB,UAA+B,EAAE;QAEjC,MAAM,aAAa,GAAqB;YACtC,IAAI,EAAE,KAAK;YACX,OAAO,EAAE,QAAQ;YACjB,YAAY,EAAE,YAAY;YAC1B,OAAO,EAAE,OAAO;YAChB,GAAG,OAAO;SACX,CAAC;QAEF,OAAO,IAAI,CAAC,SAAS,CAAC,aAAa,EAAE,aAAa,CAEjD,CAAC;IACJ,CAAC;CACF"}
|
package/dist/index.cjs
CHANGED
|
@@ -25,6 +25,7 @@ __export(index_exports, {
|
|
|
25
25
|
DynamoDBResourceClient: () => import_dynamodb.DynamoDBResourceClient,
|
|
26
26
|
GoogleSheetsResourceClient: () => import_googlesheets.GoogleSheetsResourceClient,
|
|
27
27
|
HubSpotResourceClient: () => import_hubspot.HubSpotResourceClient,
|
|
28
|
+
LambdaResourceClient: () => import_lambda.LambdaResourceClient,
|
|
28
29
|
MssqlResourceClient: () => import_mssql.MssqlResourceClient,
|
|
29
30
|
PostgresResourceClient: () => import_postgres.PostgresResourceClient,
|
|
30
31
|
ResourceInvokeError: () => import_errors.ResourceInvokeError,
|
|
@@ -44,4 +45,5 @@ var import_api_custom = require("./clients/api-custom");
|
|
|
44
45
|
var import_hubspot = require("./clients/hubspot");
|
|
45
46
|
var import_googlesheets = require("./clients/googlesheets");
|
|
46
47
|
var import_s3 = require("./clients/s3");
|
|
48
|
+
var import_lambda = require("./clients/lambda");
|
|
47
49
|
//# sourceMappingURL=index.cjs.map
|
package/dist/index.cjs.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/index.ts"],
|
|
4
|
-
"sourcesContent": ["// Export all schemas and types\nexport * from \"./schemas\";\n\n// Export base client and config\nexport { BaseResourceClient, type BaseClientConfig } from \"./base\";\n\n// Export errors\nexport { ResourceInvokeError } from \"./errors\";\n\n// Export individual clients\nexport { PostgresResourceClient } from \"./clients/postgres\";\nexport { MssqlResourceClient } from \"./clients/mssql\";\nexport { DynamoDBResourceClient } from \"./clients/dynamodb\";\nexport { CosmosDBResourceClient } from \"./clients/cosmosdb\";\nexport { SnowflakeResourceClient } from \"./clients/snowflake\";\nexport { CustomApiResourceClient } from \"./clients/api-custom\";\nexport { HubSpotResourceClient } from \"./clients/hubspot\";\nexport { GoogleSheetsResourceClient } from \"./clients/googlesheets\";\nexport { S3ResourceClient } from \"./clients/s3\";\n\n// Re-export common response types for convenience\nexport type {\n DatabaseInvokeResponse,\n DynamoDBInvokeResponse,\n CosmosDBInvokeResponse,\n SnowflakeInvokeResponse,\n ApiInvokeResponse,\n StorageInvokeResponse,\n BaseInvokeSuccess,\n} from \"./schemas/response\";\n\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;AAAA
|
|
4
|
+
"sourcesContent": ["// Export all schemas and types\nexport * from \"./schemas\";\n\n// Export base client and config\nexport { BaseResourceClient, type BaseClientConfig } from \"./base\";\n\n// Export errors\nexport { ResourceInvokeError } from \"./errors\";\n\n// Export individual clients\nexport { PostgresResourceClient } from \"./clients/postgres\";\nexport { MssqlResourceClient } from \"./clients/mssql\";\nexport { DynamoDBResourceClient } from \"./clients/dynamodb\";\nexport { CosmosDBResourceClient } from \"./clients/cosmosdb\";\nexport { SnowflakeResourceClient } from \"./clients/snowflake\";\nexport { CustomApiResourceClient } from \"./clients/api-custom\";\nexport { HubSpotResourceClient } from \"./clients/hubspot\";\nexport { GoogleSheetsResourceClient } from \"./clients/googlesheets\";\nexport { S3ResourceClient } from \"./clients/s3\";\nexport { LambdaResourceClient } from \"./clients/lambda\";\n\n// Re-export common response types for convenience\nexport type {\n DatabaseInvokeResponse,\n DynamoDBInvokeResponse,\n CosmosDBInvokeResponse,\n SnowflakeInvokeResponse,\n ApiInvokeResponse,\n StorageInvokeResponse,\n LambdaInvokeResponse,\n BaseInvokeSuccess,\n} from \"./schemas/response\";\n\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;;;;;;;AACA,0BAAc,sBADd;AAIA,kBAA0D;AAG1D,oBAAoC;AAGpC,sBAAuC;AACvC,mBAAoC;AACpC,sBAAuC;AACvC,sBAAuC;AACvC,uBAAwC;AACxC,wBAAwC;AACxC,qBAAsC;AACtC,0BAA2C;AAC3C,gBAAiC;AACjC,oBAAqC;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -10,5 +10,6 @@ export { CustomApiResourceClient } from "./clients/api-custom";
|
|
|
10
10
|
export { HubSpotResourceClient } from "./clients/hubspot";
|
|
11
11
|
export { GoogleSheetsResourceClient } from "./clients/googlesheets";
|
|
12
12
|
export { S3ResourceClient } from "./clients/s3";
|
|
13
|
-
export
|
|
13
|
+
export { LambdaResourceClient } from "./clients/lambda";
|
|
14
|
+
export type { DatabaseInvokeResponse, DynamoDBInvokeResponse, CosmosDBInvokeResponse, SnowflakeInvokeResponse, ApiInvokeResponse, StorageInvokeResponse, LambdaInvokeResponse, BaseInvokeSuccess, } from "./schemas/response";
|
|
14
15
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,cAAc,WAAW,CAAC;AAG1B,OAAO,EAAE,kBAAkB,EAAE,KAAK,gBAAgB,EAAE,MAAM,QAAQ,CAAC;AAGnE,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAG/C,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,EAAE,qBAAqB,EAAE,MAAM,mBAAmB,CAAC;AAC1D,OAAO,EAAE,0BAA0B,EAAE,MAAM,wBAAwB,CAAC;AACpE,OAAO,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,cAAc,WAAW,CAAC;AAG1B,OAAO,EAAE,kBAAkB,EAAE,KAAK,gBAAgB,EAAE,MAAM,QAAQ,CAAC;AAGnE,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAG/C,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,EAAE,qBAAqB,EAAE,MAAM,mBAAmB,CAAC;AAC1D,OAAO,EAAE,0BAA0B,EAAE,MAAM,wBAAwB,CAAC;AACpE,OAAO,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAChD,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAGxD,YAAY,EACV,sBAAsB,EACtB,sBAAsB,EACtB,sBAAsB,EACtB,uBAAuB,EACvB,iBAAiB,EACjB,qBAAqB,EACrB,oBAAoB,EACpB,iBAAiB,GAClB,MAAM,oBAAoB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -14,4 +14,5 @@ export { CustomApiResourceClient } from "./clients/api-custom";
|
|
|
14
14
|
export { HubSpotResourceClient } from "./clients/hubspot";
|
|
15
15
|
export { GoogleSheetsResourceClient } from "./clients/googlesheets";
|
|
16
16
|
export { S3ResourceClient } from "./clients/s3";
|
|
17
|
+
export { LambdaResourceClient } from "./clients/lambda";
|
|
17
18
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":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M,qBAAqB,CAAC;AAC9D,OAAO,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,EAAE,qBAAqB,EAAE,MAAM,mBAAmB,CAAC;AAC1D,OAAO,EAAE,0BAA0B,EAAE,MAAM,wBAAwB,CAAC;AACpE,OAAO,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAChD,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC"}
|
package/dist/schemas/index.cjs
CHANGED
|
@@ -25,6 +25,7 @@ __reExport(index_exports, require("./s3"), module.exports);
|
|
|
25
25
|
__reExport(index_exports, require("./api-custom"), module.exports);
|
|
26
26
|
__reExport(index_exports, require("./api-hubspot"), module.exports);
|
|
27
27
|
__reExport(index_exports, require("./api-googlesheets"), module.exports);
|
|
28
|
+
__reExport(index_exports, require("./lambda"), module.exports);
|
|
28
29
|
__reExport(index_exports, require("./request"), module.exports);
|
|
29
30
|
__reExport(index_exports, require("./response"), module.exports);
|
|
30
31
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/schemas/index.ts"],
|
|
4
|
-
"sourcesContent": ["// Re-export all types\nexport * from \"./common\";\nexport * from \"./postgres\";\nexport * from \"./mssql\";\nexport * from \"./dynamodb\";\nexport * from \"./cosmosdb\";\nexport * from \"./snowflake\";\nexport * from \"./s3\";\nexport * from \"./api-custom\";\nexport * from \"./api-hubspot\";\nexport * from \"./api-googlesheets\";\nexport * from \"./request\";\nexport * from \"./response\";\n\n// Import for discriminated union\nimport type { ApiCustomPayload } from \"./api-custom\";\nimport type { ApiHubSpotPayload } from \"./api-hubspot\";\nimport type { ApiGoogleSheetsPayload } from \"./api-googlesheets\";\nimport type { DbPostgresPayload } from \"./postgres\";\nimport type { DbMssqlPayload } from \"./mssql\";\nimport type { DbDynamoDBPayload } from \"./dynamodb\";\nimport type { DbCosmosDBPayload } from \"./cosmosdb\";\nimport type { DbSnowflakePayload } from \"./snowflake\";\nimport type { StorageS3Payload } from \"./s3\";\n\n/**\n * Discriminated union of all resource payload types\n * Use the 'subtype' field to narrow the type\n */\nexport type ResourceInvokePayload =\n | ApiCustomPayload\n | DbPostgresPayload\n | DbMssqlPayload\n | DbDynamoDBPayload\n | DbCosmosDBPayload\n | DbSnowflakePayload\n | ApiHubSpotPayload\n | ApiGoogleSheetsPayload\n | StorageS3Payload;\n\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;AAAA;;AACA,0BAAc,qBADd;AAEA,0BAAc,uBAFd;AAGA,0BAAc,oBAHd;AAIA,0BAAc,uBAJd;AAKA,0BAAc,uBALd;AAMA,0BAAc,wBANd;AAOA,0BAAc,iBAPd;AAQA,0BAAc,yBARd;AASA,0BAAc,0BATd;AAUA,0BAAc,+BAVd;AAWA,0BAAc,
|
|
4
|
+
"sourcesContent": ["// Re-export all types\nexport * from \"./common\";\nexport * from \"./postgres\";\nexport * from \"./mssql\";\nexport * from \"./dynamodb\";\nexport * from \"./cosmosdb\";\nexport * from \"./snowflake\";\nexport * from \"./s3\";\nexport * from \"./api-custom\";\nexport * from \"./api-hubspot\";\nexport * from \"./api-googlesheets\";\nexport * from \"./lambda\";\nexport * from \"./request\";\nexport * from \"./response\";\n\n// Import for discriminated union\nimport type { ApiCustomPayload } from \"./api-custom\";\nimport type { ApiHubSpotPayload } from \"./api-hubspot\";\nimport type { ApiGoogleSheetsPayload } from \"./api-googlesheets\";\nimport type { DbPostgresPayload } from \"./postgres\";\nimport type { DbMssqlPayload } from \"./mssql\";\nimport type { DbDynamoDBPayload } from \"./dynamodb\";\nimport type { DbCosmosDBPayload } from \"./cosmosdb\";\nimport type { DbSnowflakePayload } from \"./snowflake\";\nimport type { StorageS3Payload } from \"./s3\";\nimport type { ApiLambdaPayload } from \"./lambda\";\n\n/**\n * Discriminated union of all resource payload types\n * Use the 'subtype' field to narrow the type\n */\nexport type ResourceInvokePayload =\n | ApiCustomPayload\n | DbPostgresPayload\n | DbMssqlPayload\n | DbDynamoDBPayload\n | DbCosmosDBPayload\n | DbSnowflakePayload\n | ApiHubSpotPayload\n | ApiGoogleSheetsPayload\n | StorageS3Payload\n | ApiLambdaPayload;\n\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;AAAA;;AACA,0BAAc,qBADd;AAEA,0BAAc,uBAFd;AAGA,0BAAc,oBAHd;AAIA,0BAAc,uBAJd;AAKA,0BAAc,uBALd;AAMA,0BAAc,wBANd;AAOA,0BAAc,iBAPd;AAQA,0BAAc,yBARd;AASA,0BAAc,0BATd;AAUA,0BAAc,+BAVd;AAWA,0BAAc,qBAXd;AAYA,0BAAc,sBAZd;AAaA,0BAAc,uBAbd;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/schemas/index.d.ts
CHANGED
|
@@ -8,6 +8,7 @@ export * from "./s3";
|
|
|
8
8
|
export * from "./api-custom";
|
|
9
9
|
export * from "./api-hubspot";
|
|
10
10
|
export * from "./api-googlesheets";
|
|
11
|
+
export * from "./lambda";
|
|
11
12
|
export * from "./request";
|
|
12
13
|
export * from "./response";
|
|
13
14
|
import type { ApiCustomPayload } from "./api-custom";
|
|
@@ -19,9 +20,10 @@ import type { DbDynamoDBPayload } from "./dynamodb";
|
|
|
19
20
|
import type { DbCosmosDBPayload } from "./cosmosdb";
|
|
20
21
|
import type { DbSnowflakePayload } from "./snowflake";
|
|
21
22
|
import type { StorageS3Payload } from "./s3";
|
|
23
|
+
import type { ApiLambdaPayload } from "./lambda";
|
|
22
24
|
/**
|
|
23
25
|
* Discriminated union of all resource payload types
|
|
24
26
|
* Use the 'subtype' field to narrow the type
|
|
25
27
|
*/
|
|
26
|
-
export type ResourceInvokePayload = ApiCustomPayload | DbPostgresPayload | DbMssqlPayload | DbDynamoDBPayload | DbCosmosDBPayload | DbSnowflakePayload | ApiHubSpotPayload | ApiGoogleSheetsPayload | StorageS3Payload;
|
|
28
|
+
export type ResourceInvokePayload = ApiCustomPayload | DbPostgresPayload | DbMssqlPayload | DbDynamoDBPayload | DbCosmosDBPayload | DbSnowflakePayload | ApiHubSpotPayload | ApiGoogleSheetsPayload | StorageS3Payload | ApiLambdaPayload;
|
|
27
29
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/schemas/index.ts"],"names":[],"mappings":"AACA,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC;AACxB,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,MAAM,CAAC;AACrB,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAG3B,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AACrD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AACjE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AACpD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAC9C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AACpD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AACpD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AACtD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/schemas/index.ts"],"names":[],"mappings":"AACA,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc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ACxB,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,MAAM,CAAC;AACrB,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/schemas/index.ts"],"names":[],"mappings":"AAAA,sBAAsB;AACtB,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC;AACxB,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,MAAM,CAAC;AACrB,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __copyProps = (to, from, except, desc) => {
|
|
7
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
8
|
+
for (let key of __getOwnPropNames(from))
|
|
9
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
10
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
11
|
+
}
|
|
12
|
+
return to;
|
|
13
|
+
};
|
|
14
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
15
|
+
var lambda_exports = {};
|
|
16
|
+
module.exports = __toCommonJS(lambda_exports);
|
|
17
|
+
//# sourceMappingURL=lambda.cjs.map
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Lambda invocation type
|
|
3
|
+
* - RequestResponse (default): Synchronous invocation
|
|
4
|
+
* - Event: Asynchronous invocation
|
|
5
|
+
* - DryRun: Validate parameters and permissions only
|
|
6
|
+
*/
|
|
7
|
+
export type LambdaInvocationType = "RequestResponse" | "Event" | "DryRun";
|
|
8
|
+
/**
|
|
9
|
+
* Lambda log type
|
|
10
|
+
* - None (default): Don't include logs
|
|
11
|
+
* - Tail: Include the last 4 KB of execution log (sync only)
|
|
12
|
+
*/
|
|
13
|
+
export type LambdaLogType = "None" | "Tail";
|
|
14
|
+
/**
|
|
15
|
+
* Payload for invoking a Lambda resource
|
|
16
|
+
* Matches the backend LambdaInvokePayload structure in go-common/resourcetypes/lambda.go
|
|
17
|
+
*/
|
|
18
|
+
export interface ApiLambdaPayload {
|
|
19
|
+
type: "api";
|
|
20
|
+
subtype: "lambda";
|
|
21
|
+
/**
|
|
22
|
+
* The name, ARN, or partial ARN of the Lambda function.
|
|
23
|
+
* Formats:
|
|
24
|
+
* - Function name: my-function
|
|
25
|
+
* - Function ARN: arn:aws:lambda:us-west-2:123456789012:function:my-function
|
|
26
|
+
* - Partial ARN: 123456789012:function:my-function
|
|
27
|
+
* You can append a version number or alias to any of the formats.
|
|
28
|
+
*/
|
|
29
|
+
FunctionName: string;
|
|
30
|
+
/**
|
|
31
|
+
* The JSON input for the Lambda function.
|
|
32
|
+
* Max 6 MB for synchronous invocations, 1 MB for asynchronous.
|
|
33
|
+
*/
|
|
34
|
+
Payload?: unknown;
|
|
35
|
+
/**
|
|
36
|
+
* The invocation mode.
|
|
37
|
+
* - RequestResponse (default): Synchronous invocation
|
|
38
|
+
* - Event: Asynchronous invocation
|
|
39
|
+
* - DryRun: Validate parameters and permissions only
|
|
40
|
+
*/
|
|
41
|
+
InvocationType?: LambdaInvocationType;
|
|
42
|
+
/**
|
|
43
|
+
* Controls execution log inclusion in the response.
|
|
44
|
+
* - None (default): Don't include logs
|
|
45
|
+
* - Tail: Include the last 4 KB of execution log (sync only)
|
|
46
|
+
*/
|
|
47
|
+
LogType?: LambdaLogType;
|
|
48
|
+
/**
|
|
49
|
+
* Specifies a version or alias to invoke.
|
|
50
|
+
* If not specified, invokes $LATEST.
|
|
51
|
+
*/
|
|
52
|
+
Qualifier?: string;
|
|
53
|
+
/**
|
|
54
|
+
* Up to 3,583 bytes of base64-encoded data about the invoking client
|
|
55
|
+
* to pass to the function. Only for synchronous invocations.
|
|
56
|
+
*/
|
|
57
|
+
ClientContext?: string;
|
|
58
|
+
/**
|
|
59
|
+
* A unique name for durable execution.
|
|
60
|
+
* Length: 1-64 characters. Pattern: [a-zA-Z0-9-_]+
|
|
61
|
+
*/
|
|
62
|
+
DurableExecutionName?: string;
|
|
63
|
+
/**
|
|
64
|
+
* The identifier for tenant in multi-tenant Lambda function.
|
|
65
|
+
* Length: 1-256 characters.
|
|
66
|
+
*/
|
|
67
|
+
TenantId?: string;
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Result from a Lambda invocation
|
|
71
|
+
* Matches the backend LambdaInvokeResult structure in go-common/resourcetypes/lambda.go
|
|
72
|
+
*/
|
|
73
|
+
export interface ApiLambdaResult {
|
|
74
|
+
kind: "lambda";
|
|
75
|
+
/**
|
|
76
|
+
* The HTTP status code for the invocation:
|
|
77
|
+
* - 200: RequestResponse success
|
|
78
|
+
* - 202: Event success (async)
|
|
79
|
+
* - 204: DryRun success
|
|
80
|
+
*/
|
|
81
|
+
StatusCode: number;
|
|
82
|
+
/**
|
|
83
|
+
* The response from the Lambda function.
|
|
84
|
+
* For RequestResponse, contains the function's return value.
|
|
85
|
+
* For Event and DryRun, this is empty.
|
|
86
|
+
*/
|
|
87
|
+
Payload?: unknown;
|
|
88
|
+
/**
|
|
89
|
+
* Indicates if there was an error during function execution.
|
|
90
|
+
* Values: "Handled" or "Unhandled"
|
|
91
|
+
*/
|
|
92
|
+
FunctionError?: string;
|
|
93
|
+
/**
|
|
94
|
+
* The last 4 KB of execution log (base64-encoded).
|
|
95
|
+
* Only populated when LogType is "Tail".
|
|
96
|
+
*/
|
|
97
|
+
LogResult?: string;
|
|
98
|
+
/**
|
|
99
|
+
* The version of the function that was executed.
|
|
100
|
+
*/
|
|
101
|
+
ExecutedVersion?: string;
|
|
102
|
+
/**
|
|
103
|
+
* The ARN of the started durable execution.
|
|
104
|
+
*/
|
|
105
|
+
DurableExecutionArn?: string;
|
|
106
|
+
}
|
|
107
|
+
//# sourceMappingURL=lambda.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lambda.d.ts","sourceRoot":"","sources":["../../src/schemas/lambda.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,MAAM,MAAM,oBAAoB,GAAG,iBAAiB,GAAG,OAAO,GAAG,QAAQ,CAAC;AAE1E;;;;GAIG;AACH,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,MAAM,CAAC;AAE5C;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,KAAK,CAAC;IACZ,OAAO,EAAE,QAAQ,CAAC;IAElB;;;;;;;OAOG;IACH,YAAY,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;;;OAKG;IACH,cAAc,CAAC,EAAE,oBAAoB,CAAC;IAEtC;;;;OAIG;IACH,OAAO,CAAC,EAAE,aAAa,CAAC;IAExB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;;OAGG;IACH,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAE9B;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;;GAGG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,QAAQ,CAAC;IAEf;;;;;OAKG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;OAEG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lambda.js","sourceRoot":"","sources":["../../src/schemas/lambda.ts"],"names":[],"mappings":""}
|
|
@@ -4,10 +4,11 @@ import type { StorageS3Result } from "./s3";
|
|
|
4
4
|
import type { DbDynamoDBResult } from "./dynamodb";
|
|
5
5
|
import type { DbCosmosDBResult, DbCosmosDBResultGeneric } from "./cosmosdb";
|
|
6
6
|
import type { DbSnowflakeResult } from "./snowflake";
|
|
7
|
+
import type { ApiLambdaResult } from "./lambda";
|
|
7
8
|
/**
|
|
8
9
|
* Union of all possible resource invocation result types
|
|
9
10
|
*/
|
|
10
|
-
export type ResourceInvokeSuccess = ApiResult | DbResult | StorageS3Result | DbDynamoDBResult | DbCosmosDBResult | DbSnowflakeResult;
|
|
11
|
+
export type ResourceInvokeSuccess = ApiResult | DbResult | StorageS3Result | DbDynamoDBResult | DbCosmosDBResult | DbSnowflakeResult | ApiLambdaResult;
|
|
11
12
|
/**
|
|
12
13
|
* Base successful invocation response - generic over result type
|
|
13
14
|
*/
|
|
@@ -63,4 +64,8 @@ export type CosmosDBInvokeResponse<T = Record<string, unknown>> = BaseInvokeSucc
|
|
|
63
64
|
* Response from Snowflake database resource invocation
|
|
64
65
|
*/
|
|
65
66
|
export type SnowflakeInvokeResponse = BaseInvokeSuccess<DbSnowflakeResult> | InvokeFailure;
|
|
67
|
+
/**
|
|
68
|
+
* Response from Lambda resource invocation
|
|
69
|
+
*/
|
|
70
|
+
export type LambdaInvokeResponse = BaseInvokeSuccess<ApiLambdaResult> | InvokeFailure;
|
|
66
71
|
//# sourceMappingURL=response.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"response.d.ts","sourceRoot":"","sources":["../../src/schemas/response.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAC1C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAC3C,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,MAAM,CAAC;AAC5C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AACnD,OAAO,KAAK,EAAE,gBAAgB,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAC5E,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"response.d.ts","sourceRoot":"","sources":["../../src/schemas/response.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAC1C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAC3C,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,MAAM,CAAC;AAC5C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AACnD,OAAO,KAAK,EAAE,gBAAgB,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAC5E,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AACrD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAEhD;;GAEG;AACH,MAAM,MAAM,qBAAqB,GAAG,SAAS,GAAG,QAAQ,GAAG,eAAe,GAAG,gBAAgB,GAAG,gBAAgB,GAAG,iBAAiB,GAAG,eAAe,CAAC;AAEvJ;;GAEG;AACH,MAAM,WAAW,iBAAiB,CAA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