aws-toolkit-vscode / packages /core /src /shared /sam /debugger /awsSamDebugConfiguration.gen.ts
AbdulElahGwaith's picture
Upload folder using huggingface_hub
6582e08 verified
Raw
History Blame Contribute Delete
6.04 kB
/*!
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0
*/
/**
* This file is not generated from the core library. Please regenerate from
* 'packages/toolkit', e.g. `npm run generateConfigurationAttributes -w packages/toolkit`
*/
/**
* This file was automatically generated by json-schema-to-typescript.
* DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,
* and run json-schema-to-typescript to regenerate this file.
*/
import * as vscode from "vscode";
export interface AwsSamDebuggerConfiguration extends vscode.DebugConfiguration {
aws?: AWSConnection;
invokeTarget: TemplateTargetProperties | CodeTargetProperties | APITargetProperties;
lambda?: LambdaProperties;
sam?: SAMCLIProperties;
api?: APIGatewayProperties;
}
/**
* AWS connection details
*/
export interface AWSConnection {
/**
* The AWS credentials provider and name to use during the invocation. Example: credential profile "default" would be entered as `profile:default`.
*/
credentials?: string;
/**
* AWS region to use during the invocation.
*/
region?: string;
}
/**
* Configures the application to launch
*/
export interface TemplateTargetProperties {
/**
* Path to the CFN/SAM template.
*/
templatePath: string;
/**
* Resource name of an AWS::Lambda::Function or AWS::Serverless::Function to invoke.
*/
logicalId: string;
/**
* The type of invocation to launch. Possible values:
* * `template` uses a CFN/SAM Template as an entrypoint
* * `code` invokes Lambda code directly.
* * `api` uses the CFN/SAM Template to emulate API Gateway
*/
target: "template";
}
/**
* Configures the application to launch
*/
export interface CodeTargetProperties {
/**
* Lambda Function handler to invoke.
*/
lambdaHandler: string;
/**
* The root of the project, used to determine where in the file-system to locate the lambdaHandler.
*/
projectRoot: string;
/**
* The type of invocation to launch. Possible values:
* * `template` uses a CFN/SAM Template as an entrypoint
* * `code` invokes Lambda code directly.
* * `api` uses the CFN/SAM Template to emulate API Gateway
*/
target: "code";
/**
* Architecture used for local SAM Lambda emulation
*/
architecture?: "x86_64" | "arm64";
}
/**
* Configures the application to launch
*/
export interface APITargetProperties {
/**
* Path to the CFN/SAM template.
*/
templatePath: string;
/**
* Resource name of an AWS::Lambda::Function or AWS::Serverless::Function to invoke.
*/
logicalId: string;
/**
* The type of invocation to launch. Possible values:
* * `template` uses a CFN/SAM Template as an entrypoint
* * `code` invokes Lambda code directly.
* * `api` uses the CFN/SAM Template to emulate API Gateway
*/
target: "api";
}
/**
* Lambda specific details of the invocation
*/
export interface LambdaProperties {
/**
* Environment variables to pass to the function invocation (replaces template variables).
*/
environmentVariables?: {
[k: string]: string;
};
/**
* Event payload to pass to the Lambda invocation.
* Must specify one of 'json' or 'path'.
*/
payload?: {
/**
* JSON definition to use as the event payload
*/
json?: {
[k: string]: unknown;
};
/**
* Path to a file to use as the event payload
*/
path?: string;
};
/**
* The amount of memory (in Mb) the Lambda function has access to.
*/
memoryMb?: number;
/**
* The Lambda Function's runtime
*/
runtime?: string;
/**
* The amount of time (in seconds) that Lambda allows a function to run before stopping it.
*/
timeoutSec?: number;
pathMappings?: PathMapping[];
}
export interface PathMapping {
localRoot: string;
remoteRoot: string;
}
/**
* SAM CLI specific configurations
*/
export interface SAMCLIProperties {
/**
* Additional arguments to pass to the `sam build` command.
*/
buildArguments?: string[];
/**
* Base directory to build and run the application.
* A temporary directory will be created if not specified.
*/
buildDir?: string;
/**
* Whether to build inside a container (default: false).
*/
containerBuild?: boolean;
/**
* Specifies the name or id of an existing Docker network that Lambda Docker containers should connect to.
*/
dockerNetwork?: string;
/**
* Additional arguments to pass to the `sam local` command.
*/
localArguments?: string[];
/**
* Specifies whether the command should skip pulling down the latest Docker image for Lambda runtime (default: false).
*/
skipNewImageCheck?: boolean;
/**
* Values to override in the template
*/
template?: {
/**
* Key:value mappings for SAM template parameter overrides. More information can be found here: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/stackinstances-override.html#stackinstances-override-cli
*/
parameters?: {
[k: string]: string | number;
};
};
}
/**
* API Gateway configuration
*/
export interface APIGatewayProperties {
/**
* The path to the api (must start with /)
*/
path: string;
/**
* The HTTP message method that will be used
*/
httpMethod: "delete" | "get" | "head" | "options" | "patch" | "post" | "put";
/**
* Event payload to pass to the Lambda invocation.
* Must specify one of 'json' or 'path'.
*/
payload?: {
/**
* JSON definition to use as the event payload
*/
json?: {
[k: string]: unknown;
};
/**
* Path to a file to use as the event payload
*/
path?: string;
};
/**
* Additional HTTP headers
*/
headers?: {
[k: string]: string;
};
/**
* URL query string (e.g. key=foo&value=bar)
*/
querystring?: string;
/**
* key-value map of API Gateway stage variables
*/
stageVariables?: {
[k: string]: string;
};
/**
* The API Gateway client certificate ID
*/
clientCertificateId?: string;
}