UNPKG

@aws-sdk/client-lambda

Version:

AWS SDK for JavaScript Lambda Client for Node.js, Browser and React Native

1,304 lines (1,303 loc) 235 kB
import { ExceptionOptionType as __ExceptionOptionType } from "@smithy/smithy-client"; import { StreamingBlobTypes } from "@smithy/types"; import { LambdaServiceException as __BaseException } from "./LambdaServiceException"; /** * <p>Limits that are related to concurrency and storage. All file and storage sizes are in bytes.</p> * @public */ export interface AccountLimit { /** * <p>The amount of storage space that you can use for all deployment packages and layer archives.</p> * @public */ TotalCodeSize?: number; /** * <p>The maximum size of a function's deployment package and layers when they're extracted.</p> * @public */ CodeSizeUnzipped?: number; /** * <p>The maximum size of a deployment package when it's uploaded directly to Lambda. Use Amazon S3 for larger * files.</p> * @public */ CodeSizeZipped?: number; /** * <p>The maximum number of simultaneous function executions.</p> * @public */ ConcurrentExecutions?: number; /** * <p>The maximum number of simultaneous function executions, minus the capacity that's reserved for individual * functions with <a>PutFunctionConcurrency</a>.</p> * @public */ UnreservedConcurrentExecutions?: number; } /** * <p>The number of functions and amount of storage in use.</p> * @public */ export interface AccountUsage { /** * <p>The amount of storage space, in bytes, that's being used by deployment packages and layer archives.</p> * @public */ TotalCodeSize?: number; /** * <p>The number of Lambda functions.</p> * @public */ FunctionCount?: number; } /** * @public */ export interface AddLayerVersionPermissionRequest { /** * <p>The name or Amazon Resource Name (ARN) of the layer.</p> * @public */ LayerName: string | undefined; /** * <p>The version number.</p> * @public */ VersionNumber: number | undefined; /** * <p>An identifier that distinguishes the policy from others on the same layer version.</p> * @public */ StatementId: string | undefined; /** * <p>The API action that grants access to the layer. For example, <code>lambda:GetLayerVersion</code>.</p> * @public */ Action: string | undefined; /** * <p>An account ID, or <code>*</code> to grant layer usage permission to all * accounts in an organization, or all Amazon Web Services accounts (if <code>organizationId</code> is not specified). * For the last case, make sure that you really do want all Amazon Web Services accounts to have usage permission to this layer. * </p> * @public */ Principal: string | undefined; /** * <p>With the principal set to <code>*</code>, grant permission to all accounts in the specified * organization.</p> * @public */ OrganizationId?: string; /** * <p>Only update the policy if the revision ID matches the ID specified. Use this option to avoid modifying a * policy that has changed since you last read it.</p> * @public */ RevisionId?: string; } /** * @public */ export interface AddLayerVersionPermissionResponse { /** * <p>The permission statement.</p> * @public */ Statement?: string; /** * <p>A unique identifier for the current revision of the policy.</p> * @public */ RevisionId?: string; } /** * <p>One of the parameters in the request is not valid.</p> * @public */ export declare class InvalidParameterValueException extends __BaseException { readonly name: "InvalidParameterValueException"; readonly $fault: "client"; /** * <p>The exception type.</p> * @public */ Type?: string; /** * @internal */ constructor(opts: __ExceptionOptionType<InvalidParameterValueException, __BaseException>); } /** * <p>The permissions policy for the resource is too large. For more information, see <a href="https://docs.aws.amazon.com/lambda/latest/dg/gettingstarted-limits.html">Lambda quotas</a>.</p> * @public */ export declare class PolicyLengthExceededException extends __BaseException { readonly name: "PolicyLengthExceededException"; readonly $fault: "client"; Type?: string; /** * @internal */ constructor(opts: __ExceptionOptionType<PolicyLengthExceededException, __BaseException>); } /** * <p>The RevisionId provided does not match the latest RevisionId for the Lambda function or alias.</p> * <ul> * <li> * <p> * <b>For AddPermission and RemovePermission API operations:</b> Call <code>GetPolicy</code> to retrieve the latest RevisionId for your resource.</p> * </li> * <li> * <p> * <b>For all other API operations:</b> Call <code>GetFunction</code> or <code>GetAlias</code> to retrieve the latest RevisionId for your resource.</p> * </li> * </ul> * @public */ export declare class PreconditionFailedException extends __BaseException { readonly name: "PreconditionFailedException"; readonly $fault: "client"; /** * <p>The exception type.</p> * @public */ Type?: string; /** * @internal */ constructor(opts: __ExceptionOptionType<PreconditionFailedException, __BaseException>); } /** * <p>The resource already exists, or another operation is in progress.</p> * @public */ export declare class ResourceConflictException extends __BaseException { readonly name: "ResourceConflictException"; readonly $fault: "client"; /** * <p>The exception type.</p> * @public */ Type?: string; /** * @internal */ constructor(opts: __ExceptionOptionType<ResourceConflictException, __BaseException>); } /** * <p>The resource specified in the request does not exist.</p> * @public */ export declare class ResourceNotFoundException extends __BaseException { readonly name: "ResourceNotFoundException"; readonly $fault: "client"; Type?: string; Message?: string; /** * @internal */ constructor(opts: __ExceptionOptionType<ResourceNotFoundException, __BaseException>); } /** * <p>The Lambda service encountered an internal error.</p> * @public */ export declare class ServiceException extends __BaseException { readonly name: "ServiceException"; readonly $fault: "server"; Type?: string; Message?: string; /** * @internal */ constructor(opts: __ExceptionOptionType<ServiceException, __BaseException>); } /** * @public * @enum */ export declare const ThrottleReason: { readonly CallerRateLimitExceeded: "CallerRateLimitExceeded"; readonly ConcurrentInvocationLimitExceeded: "ConcurrentInvocationLimitExceeded"; readonly ConcurrentSnapshotCreateLimitExceeded: "ConcurrentSnapshotCreateLimitExceeded"; readonly FunctionInvocationRateLimitExceeded: "FunctionInvocationRateLimitExceeded"; readonly ReservedFunctionConcurrentInvocationLimitExceeded: "ReservedFunctionConcurrentInvocationLimitExceeded"; readonly ReservedFunctionInvocationRateLimitExceeded: "ReservedFunctionInvocationRateLimitExceeded"; }; /** * @public */ export type ThrottleReason = (typeof ThrottleReason)[keyof typeof ThrottleReason]; /** * <p>The request throughput limit was exceeded. For more information, see <a href="https://docs.aws.amazon.com/lambda/latest/dg/gettingstarted-limits.html#api-requests">Lambda quotas</a>.</p> * @public */ export declare class TooManyRequestsException extends __BaseException { readonly name: "TooManyRequestsException"; readonly $fault: "client"; /** * <p>The number of seconds the caller should wait before retrying.</p> * @public */ retryAfterSeconds?: string; Type?: string; Reason?: ThrottleReason; /** * @internal */ constructor(opts: __ExceptionOptionType<TooManyRequestsException, __BaseException>); } /** * @public * @enum */ export declare const FunctionUrlAuthType: { readonly AWS_IAM: "AWS_IAM"; readonly NONE: "NONE"; }; /** * @public */ export type FunctionUrlAuthType = (typeof FunctionUrlAuthType)[keyof typeof FunctionUrlAuthType]; /** * @public */ export interface AddPermissionRequest { /** * <p>The name or ARN of the Lambda function, version, or alias.</p> * <p class="title"> * <b>Name formats</b> * </p> * <ul> * <li> * <p> * <b>Function name</b> – <code>my-function</code> (name-only), <code>my-function:v1</code> (with alias).</p> * </li> * <li> * <p> * <b>Function ARN</b> – <code>arn:aws:lambda:us-west-2:123456789012:function:my-function</code>.</p> * </li> * <li> * <p> * <b>Partial ARN</b> – <code>123456789012:function:my-function</code>.</p> * </li> * </ul> * <p>You can append a version number or alias to any of the formats. The length constraint applies only to the full ARN. * If you specify only the function name, it is limited to 64 characters in length.</p> * @public */ FunctionName: string | undefined; /** * <p>A statement identifier that differentiates the statement from others in the same policy.</p> * @public */ StatementId: string | undefined; /** * <p>The action that the principal can use on the function. For example, <code>lambda:InvokeFunction</code> or * <code>lambda:GetFunction</code>.</p> * @public */ Action: string | undefined; /** * <p>The Amazon Web Servicesservice or Amazon Web Services account that invokes the function. If you specify a * service, use <code>SourceArn</code> or <code>SourceAccount</code> to limit who can invoke the function through * that service.</p> * @public */ Principal: string | undefined; /** * <p>For Amazon Web Servicesservices, the ARN of the Amazon Web Services resource that invokes the function. For * example, an Amazon S3 bucket or Amazon SNS topic.</p> * <p>Note that Lambda configures the comparison using the <code>StringLike</code> operator.</p> * @public */ SourceArn?: string; /** * <p>For Amazon Web Servicesservice, the ID of the Amazon Web Services account that owns the resource. Use this * together with <code>SourceArn</code> to ensure that the specified account owns the resource. It is possible for an * Amazon S3 bucket to be deleted by its owner and recreated by another account.</p> * @public */ SourceAccount?: string; /** * <p>For Alexa Smart Home functions, a token that the invoker must supply.</p> * @public */ EventSourceToken?: string; /** * <p>Specify a version or alias to add permissions to a published version of the function.</p> * @public */ Qualifier?: string; /** * <p>Update the policy only if the revision ID matches the ID that's specified. Use this option to avoid modifying a * policy that has changed since you last read it.</p> * @public */ RevisionId?: string; /** * <p>The identifier for your organization in Organizations. Use this to grant permissions to all the * Amazon Web Services accounts under this organization.</p> * @public */ PrincipalOrgID?: string; /** * <p>The type of authentication that your function URL uses. Set to <code>AWS_IAM</code> if you want to restrict access to authenticated * users only. Set to <code>NONE</code> if you want to bypass IAM authentication to create a public endpoint. For more information, * see <a href="https://docs.aws.amazon.com/lambda/latest/dg/urls-auth.html">Security and auth model for Lambda function URLs</a>.</p> * @public */ FunctionUrlAuthType?: FunctionUrlAuthType; } /** * @public */ export interface AddPermissionResponse { /** * <p>The permission statement that's added to the function policy.</p> * @public */ Statement?: string; } /** * <p>The <a href="https://docs.aws.amazon.com/lambda/latest/dg/lambda-traffic-shifting-using-aliases.html">traffic-shifting</a> configuration of a Lambda function alias.</p> * @public */ export interface AliasRoutingConfiguration { /** * <p>The second version, and the percentage of traffic that's routed to it.</p> * @public */ AdditionalVersionWeights?: Record<string, number>; } /** * <p>Provides configuration information about a Lambda function <a href="https://docs.aws.amazon.com/lambda/latest/dg/configuration-aliases.html">alias</a>.</p> * @public */ export interface AliasConfiguration { /** * <p>The Amazon Resource Name (ARN) of the alias.</p> * @public */ AliasArn?: string; /** * <p>The name of the alias.</p> * @public */ Name?: string; /** * <p>The function version that the alias invokes.</p> * @public */ FunctionVersion?: string; /** * <p>A description of the alias.</p> * @public */ Description?: string; /** * <p>The <a href="https://docs.aws.amazon.com/lambda/latest/dg/lambda-traffic-shifting-using-aliases.html">routing * configuration</a> of the alias.</p> * @public */ RoutingConfig?: AliasRoutingConfiguration; /** * <p>A unique identifier that changes when you update the alias.</p> * @public */ RevisionId?: string; } /** * <p>List of signing profiles that can sign a code package. </p> * @public */ export interface AllowedPublishers { /** * <p>The Amazon Resource Name (ARN) for each of the signing profiles. A signing profile defines a trusted user * who can sign a code package. </p> * @public */ SigningProfileVersionArns: string[] | undefined; } /** * <p>Specific configuration settings for an Amazon Managed Streaming for Apache Kafka (Amazon MSK) event source.</p> * @public */ export interface AmazonManagedKafkaEventSourceConfig { /** * <p>The identifier for the Kafka consumer group to join. The consumer group ID must be unique among all your Kafka event sources. * After creating a Kafka event source mapping with the consumer group ID specified, you cannot update this value. For more information, see * <a href="https://docs.aws.amazon.com/lambda/latest/dg/with-msk.html#services-msk-consumer-group-id">Customizable consumer group ID</a>.</p> * @public */ ConsumerGroupId?: string; } /** * @public * @enum */ export declare const ApplicationLogLevel: { readonly Debug: "DEBUG"; readonly Error: "ERROR"; readonly Fatal: "FATAL"; readonly Info: "INFO"; readonly Trace: "TRACE"; readonly Warn: "WARN"; }; /** * @public */ export type ApplicationLogLevel = (typeof ApplicationLogLevel)[keyof typeof ApplicationLogLevel]; /** * @public * @enum */ export declare const Architecture: { readonly arm64: "arm64"; readonly x86_64: "x86_64"; }; /** * @public */ export type Architecture = (typeof Architecture)[keyof typeof Architecture]; /** * @public */ export interface CreateAliasRequest { /** * <p>The name or ARN of the Lambda function.</p> * <p class="title"> * <b>Name formats</b> * </p> * <ul> * <li> * <p> * <b>Function name</b> - <code>MyFunction</code>.</p> * </li> * <li> * <p> * <b>Function ARN</b> - <code>arn:aws:lambda:us-west-2:123456789012:function:MyFunction</code>.</p> * </li> * <li> * <p> * <b>Partial ARN</b> - <code>123456789012:function:MyFunction</code>.</p> * </li> * </ul> * <p>The length constraint applies only to the full ARN. If you specify only the function name, it is limited to 64 * characters in length.</p> * @public */ FunctionName: string | undefined; /** * <p>The name of the alias.</p> * @public */ Name: string | undefined; /** * <p>The function version that the alias invokes.</p> * @public */ FunctionVersion: string | undefined; /** * <p>A description of the alias.</p> * @public */ Description?: string; /** * <p>The <a href="https://docs.aws.amazon.com/lambda/latest/dg/configuration-aliases.html#configuring-alias-routing">routing * configuration</a> of the alias.</p> * @public */ RoutingConfig?: AliasRoutingConfiguration; } /** * @public * @enum */ export declare const CodeSigningPolicy: { readonly Enforce: "Enforce"; readonly Warn: "Warn"; }; /** * @public */ export type CodeSigningPolicy = (typeof CodeSigningPolicy)[keyof typeof CodeSigningPolicy]; /** * <p>Code signing configuration <a href="https://docs.aws.amazon.com/lambda/latest/dg/configuration-codesigning.html#config-codesigning-policies">policies</a> specify the validation failure action for signature mismatch or * expiry.</p> * @public */ export interface CodeSigningPolicies { /** * <p>Code signing configuration policy for deployment validation failure. If you set the policy to * <code>Enforce</code>, Lambda blocks the deployment request if signature validation checks fail. If you set the * policy to <code>Warn</code>, Lambda allows the deployment and creates a CloudWatch log. </p> * <p>Default value: <code>Warn</code> * </p> * @public */ UntrustedArtifactOnDeployment?: CodeSigningPolicy; } /** * @public */ export interface CreateCodeSigningConfigRequest { /** * <p>Descriptive name for this code signing configuration.</p> * @public */ Description?: string; /** * <p>Signing profiles for this code signing configuration.</p> * @public */ AllowedPublishers: AllowedPublishers | undefined; /** * <p>The code signing policies define the actions to take if the validation checks fail. </p> * @public */ CodeSigningPolicies?: CodeSigningPolicies; } /** * <p>Details about a <a href="https://docs.aws.amazon.com/lambda/latest/dg/configuration-codesigning.html">Code signing configuration</a>. </p> * @public */ export interface CodeSigningConfig { /** * <p>Unique identifer for the Code signing configuration.</p> * @public */ CodeSigningConfigId: string | undefined; /** * <p>The Amazon Resource Name (ARN) of the Code signing configuration.</p> * @public */ CodeSigningConfigArn: string | undefined; /** * <p>Code signing configuration description.</p> * @public */ Description?: string; /** * <p>List of allowed publishers.</p> * @public */ AllowedPublishers: AllowedPublishers | undefined; /** * <p>The code signing policy controls the validation failure action for signature mismatch or expiry.</p> * @public */ CodeSigningPolicies: CodeSigningPolicies | undefined; /** * <p>The date and time that the Code signing configuration was last modified, in ISO-8601 format (YYYY-MM-DDThh:mm:ss.sTZD). </p> * @public */ LastModified: string | undefined; } /** * @public */ export interface CreateCodeSigningConfigResponse { /** * <p>The code signing configuration.</p> * @public */ CodeSigningConfig: CodeSigningConfig | undefined; } /** * <p>A destination for events that failed processing.</p> * @public */ export interface OnFailure { /** * <p>The Amazon Resource Name (ARN) of the destination resource.</p> * <p>To retain records of <a href="https://docs.aws.amazon.com/lambda/latest/dg/invocation-async.html#invocation-async-destinations">asynchronous invocations</a>, * you can configure an Amazon SNS topic, Amazon SQS queue, Lambda function, * or Amazon EventBridge event bus as the destination.</p> * <p>To retain records of failed invocations from <a href="https://docs.aws.amazon.com/lambda/latest/dg/invocation-eventsourcemapping.html#event-source-mapping-destinations">Kinesis and * DynamoDB event sources</a>, you can configure an Amazon SNS topic or * Amazon SQS queue as the destination.</p> * <p>To retain records of failed invocations from <a href="https://docs.aws.amazon.com/lambda/latest/dg/with-kafka.html#services-smaa-onfailure-destination">self-managed Kafka</a> or * <a href="https://docs.aws.amazon.com/lambda/latest/dg/with-msk.html#services-msk-onfailure-destination">Amazon MSK</a>, * you can configure an Amazon SNS topic, Amazon SQS queue, or Amazon S3 bucket as the destination.</p> * @public */ Destination?: string; } /** * <p>A destination for events that were processed successfully.</p> * @public */ export interface OnSuccess { /** * <p>The Amazon Resource Name (ARN) of the destination resource.</p> * @public */ Destination?: string; } /** * <p>A configuration object that specifies the destination of an event after Lambda processes it.</p> * @public */ export interface DestinationConfig { /** * <p>The destination configuration for successful invocations.</p> * @public */ OnSuccess?: OnSuccess; /** * <p>The destination configuration for failed invocations.</p> * @public */ OnFailure?: OnFailure; } /** * @public * @enum */ export declare const FullDocument: { readonly Default: "Default"; readonly UpdateLookup: "UpdateLookup"; }; /** * @public */ export type FullDocument = (typeof FullDocument)[keyof typeof FullDocument]; /** * <p> * Specific configuration settings for a DocumentDB event source. * </p> * @public */ export interface DocumentDBEventSourceConfig { /** * <p> * The name of the database to consume within the DocumentDB cluster. * </p> * @public */ DatabaseName?: string; /** * <p> * The name of the collection to consume within the database. If you do not specify a collection, Lambda consumes all collections. * </p> * @public */ CollectionName?: string; /** * <p> * Determines what DocumentDB sends to your event stream during document update operations. If set to UpdateLookup, DocumentDB sends a delta describing the changes, along with a copy of the entire document. Otherwise, DocumentDB sends only a partial document that contains the changes. * </p> * @public */ FullDocument?: FullDocument; } /** * <p> * A structure within a <code>FilterCriteria</code> object that defines an event filtering pattern. * </p> * @public */ export interface Filter { /** * <p> * A filter pattern. For more information on the syntax of a filter pattern, see * <a href="https://docs.aws.amazon.com/lambda/latest/dg/invocation-eventfiltering.html#filtering-syntax"> * Filter rule syntax</a>. * </p> * @public */ Pattern?: string; } /** * <p> * An object that contains the filters for an event source. * </p> * @public */ export interface FilterCriteria { /** * <p> * A list of filters. * </p> * @public */ Filters?: Filter[]; } /** * @public * @enum */ export declare const FunctionResponseType: { readonly ReportBatchItemFailures: "ReportBatchItemFailures"; }; /** * @public */ export type FunctionResponseType = (typeof FunctionResponseType)[keyof typeof FunctionResponseType]; /** * <p>(Amazon SQS only) The scaling configuration for the event source. To remove the configuration, pass an empty value.</p> * @public */ export interface ScalingConfig { /** * <p>Limits the number of concurrent instances that the Amazon SQS event source can invoke.</p> * @public */ MaximumConcurrency?: number; } /** * @public * @enum */ export declare const EndPointType: { readonly KAFKA_BOOTSTRAP_SERVERS: "KAFKA_BOOTSTRAP_SERVERS"; }; /** * @public */ export type EndPointType = (typeof EndPointType)[keyof typeof EndPointType]; /** * <p>The self-managed Apache Kafka cluster for your event source.</p> * @public */ export interface SelfManagedEventSource { /** * <p>The list of bootstrap servers for your Kafka brokers in the following format: <code>"KAFKA_BOOTSTRAP_SERVERS": * ["abc.xyz.com:xxxx","abc2.xyz.com:xxxx"]</code>.</p> * @public */ Endpoints?: Partial<Record<EndPointType, string[]>>; } /** * <p>Specific configuration settings for a self-managed Apache Kafka event source.</p> * @public */ export interface SelfManagedKafkaEventSourceConfig { /** * <p>The identifier for the Kafka consumer group to join. The consumer group ID must be unique among all your Kafka event sources. * After creating a Kafka event source mapping with the consumer group ID specified, you cannot update this value. For more information, see * <a href="https://docs.aws.amazon.com/lambda/latest/dg/with-msk.html#services-msk-consumer-group-id">Customizable consumer group ID</a>.</p> * @public */ ConsumerGroupId?: string; } /** * @public * @enum */ export declare const SourceAccessType: { readonly BASIC_AUTH: "BASIC_AUTH"; readonly CLIENT_CERTIFICATE_TLS_AUTH: "CLIENT_CERTIFICATE_TLS_AUTH"; readonly SASL_SCRAM_256_AUTH: "SASL_SCRAM_256_AUTH"; readonly SASL_SCRAM_512_AUTH: "SASL_SCRAM_512_AUTH"; readonly SERVER_ROOT_CA_CERTIFICATE: "SERVER_ROOT_CA_CERTIFICATE"; readonly VIRTUAL_HOST: "VIRTUAL_HOST"; readonly VPC_SECURITY_GROUP: "VPC_SECURITY_GROUP"; readonly VPC_SUBNET: "VPC_SUBNET"; }; /** * @public */ export type SourceAccessType = (typeof SourceAccessType)[keyof typeof SourceAccessType]; /** * <p>To secure and define access to your event source, you can specify the authentication protocol, VPC components, or virtual host.</p> * @public */ export interface SourceAccessConfiguration { /** * <p>The type of authentication protocol, VPC components, or virtual host for your event source. For example: <code>"Type":"SASL_SCRAM_512_AUTH"</code>.</p> * <ul> * <li> * <p> * <code>BASIC_AUTH</code> – (Amazon MQ) The Secrets Manager secret that stores your broker credentials.</p> * </li> * <li> * <p> * <code>BASIC_AUTH</code> – (Self-managed Apache Kafka) The Secrets Manager ARN of your secret key used for SASL/PLAIN authentication of your Apache Kafka brokers.</p> * </li> * <li> * <p> * <code>VPC_SUBNET</code> – (Self-managed Apache Kafka) The subnets associated with your VPC. Lambda connects to these subnets to fetch data from your self-managed Apache Kafka cluster.</p> * </li> * <li> * <p> * <code>VPC_SECURITY_GROUP</code> – (Self-managed Apache Kafka) The VPC security group used to manage access to your self-managed Apache Kafka brokers.</p> * </li> * <li> * <p> * <code>SASL_SCRAM_256_AUTH</code> – (Self-managed Apache Kafka) The Secrets Manager ARN of your secret key used for SASL SCRAM-256 authentication of your self-managed Apache Kafka brokers.</p> * </li> * <li> * <p> * <code>SASL_SCRAM_512_AUTH</code> – (Amazon MSK, Self-managed Apache Kafka) The Secrets Manager ARN of your secret key used for SASL SCRAM-512 authentication of your self-managed Apache Kafka brokers.</p> * </li> * <li> * <p> * <code>VIRTUAL_HOST</code> –- (RabbitMQ) The name of the virtual host in your RabbitMQ broker. Lambda uses this RabbitMQ host as the event source. * This property cannot be specified in an UpdateEventSourceMapping API call.</p> * </li> * <li> * <p> * <code>CLIENT_CERTIFICATE_TLS_AUTH</code> – (Amazon MSK, self-managed Apache Kafka) The Secrets Manager ARN of your secret key containing the certificate chain (X.509 PEM), * private key (PKCS#8 PEM), and private key password (optional) used for mutual TLS authentication of your MSK/Apache Kafka brokers.</p> * </li> * <li> * <p> * <code>SERVER_ROOT_CA_CERTIFICATE</code> – (Self-managed Apache Kafka) The Secrets Manager ARN of your secret key containing the root CA certificate (X.509 PEM) used for TLS encryption of your Apache Kafka brokers. * </p> * </li> * </ul> * @public */ Type?: SourceAccessType; /** * <p>The value for your chosen configuration in <code>Type</code>. For example: <code>"URI": "arn:aws:secretsmanager:us-east-1:01234567890:secret:MyBrokerSecretName"</code>.</p> * @public */ URI?: string; } /** * @public * @enum */ export declare const EventSourcePosition: { readonly AT_TIMESTAMP: "AT_TIMESTAMP"; readonly LATEST: "LATEST"; readonly TRIM_HORIZON: "TRIM_HORIZON"; }; /** * @public */ export type EventSourcePosition = (typeof EventSourcePosition)[keyof typeof EventSourcePosition]; /** * @public */ export interface CreateEventSourceMappingRequest { /** * <p>The Amazon Resource Name (ARN) of the event source.</p> * <ul> * <li> * <p> * <b>Amazon Kinesis</b> – The ARN of the data stream or a stream consumer.</p> * </li> * <li> * <p> * <b>Amazon DynamoDB Streams</b> – The ARN of the stream.</p> * </li> * <li> * <p> * <b>Amazon Simple Queue Service</b> – The ARN of the queue.</p> * </li> * <li> * <p> * <b>Amazon Managed Streaming for Apache Kafka</b> – The ARN of the cluster or the ARN of the VPC connection (for <a href="https://docs.aws.amazon.com/lambda/latest/dg/with-msk.html#msk-multi-vpc">cross-account event source mappings</a>).</p> * </li> * <li> * <p> * <b>Amazon MQ</b> – The ARN of the broker.</p> * </li> * <li> * <p> * <b>Amazon DocumentDB</b> – The ARN of the DocumentDB change stream.</p> * </li> * </ul> * @public */ EventSourceArn?: string; /** * <p>The name or ARN of the Lambda function.</p> * <p class="title"> * <b>Name formats</b> * </p> * <ul> * <li> * <p> * <b>Function name</b> – <code>MyFunction</code>.</p> * </li> * <li> * <p> * <b>Function ARN</b> – <code>arn:aws:lambda:us-west-2:123456789012:function:MyFunction</code>.</p> * </li> * <li> * <p> * <b>Version or Alias ARN</b> – <code>arn:aws:lambda:us-west-2:123456789012:function:MyFunction:PROD</code>.</p> * </li> * <li> * <p> * <b>Partial ARN</b> – <code>123456789012:function:MyFunction</code>.</p> * </li> * </ul> * <p>The length constraint applies only to the full ARN. If you specify only the function name, it's limited to 64 * characters in length.</p> * @public */ FunctionName: string | undefined; /** * <p>When true, the event source mapping is active. When false, Lambda pauses polling and invocation.</p> * <p>Default: True</p> * @public */ Enabled?: boolean; /** * <p>The maximum number of records in each batch that Lambda pulls from your stream or queue and sends to your function. Lambda passes all of the records in the batch to the function in a single call, up to the payload limit for synchronous invocation * (6 MB).</p> * <ul> * <li> * <p> * <b>Amazon Kinesis</b> – Default 100. Max 10,000.</p> * </li> * <li> * <p> * <b>Amazon DynamoDB Streams</b> – Default 100. Max 10,000.</p> * </li> * <li> * <p> * <b>Amazon Simple Queue Service</b> – Default 10. For standard queues the max is 10,000. For FIFO queues the max is 10.</p> * </li> * <li> * <p> * <b>Amazon Managed Streaming for Apache Kafka</b> – Default 100. Max 10,000.</p> * </li> * <li> * <p> * <b>Self-managed Apache Kafka</b> – Default 100. Max 10,000.</p> * </li> * <li> * <p> * <b>Amazon MQ (ActiveMQ and RabbitMQ)</b> – Default 100. Max 10,000.</p> * </li> * <li> * <p> * <b>DocumentDB</b> – Default 100. Max 10,000.</p> * </li> * </ul> * @public */ BatchSize?: number; /** * <p>An object that defines the filter criteria that * determine whether Lambda should process an event. For more information, see <a href="https://docs.aws.amazon.com/lambda/latest/dg/invocation-eventfiltering.html">Lambda event filtering</a>.</p> * @public */ FilterCriteria?: FilterCriteria; /** * <p>The maximum amount of time, in seconds, that Lambda spends gathering records before invoking the function. * You can configure <code>MaximumBatchingWindowInSeconds</code> to any value from 0 seconds to 300 seconds in increments of seconds.</p> * <p>For Kinesis, DynamoDB, and Amazon SQS event sources, the default batching window is 0 seconds. For Amazon MSK, Self-managed Apache Kafka, Amazon MQ, and DocumentDB event sources, the default * batching window is 500 ms. Note that because you can only change <code>MaximumBatchingWindowInSeconds</code> in increments of seconds, you cannot revert back to the 500 ms default batching window after you have changed it. * To restore the default batching window, you must create a new event source mapping.</p> * <p>Related setting: For Kinesis, DynamoDB, and Amazon SQS event sources, when you set <code>BatchSize</code> to a value greater than 10, you must set <code>MaximumBatchingWindowInSeconds</code> to at least 1.</p> * @public */ MaximumBatchingWindowInSeconds?: number; /** * <p>(Kinesis and DynamoDB Streams only) The number of batches to process from each shard concurrently.</p> * @public */ ParallelizationFactor?: number; /** * <p>The position in a stream from which to start reading. Required for Amazon Kinesis and * Amazon DynamoDB Stream event sources. <code>AT_TIMESTAMP</code> is supported only for * Amazon Kinesis streams, Amazon DocumentDB, Amazon MSK, and self-managed Apache Kafka.</p> * @public */ StartingPosition?: EventSourcePosition; /** * <p>With <code>StartingPosition</code> set to <code>AT_TIMESTAMP</code>, the time from which to start * reading. <code>StartingPositionTimestamp</code> cannot be in the future.</p> * @public */ StartingPositionTimestamp?: Date; /** * <p>(Kinesis, DynamoDB Streams, Amazon MSK, and self-managed Kafka only) A configuration object that specifies the destination of an event after Lambda processes it.</p> * @public */ DestinationConfig?: DestinationConfig; /** * <p>(Kinesis and DynamoDB Streams only) Discard records older than the specified age. The default value is infinite (-1).</p> * @public */ MaximumRecordAgeInSeconds?: number; /** * <p>(Kinesis and DynamoDB Streams only) If the function returns an error, split the batch in two and retry.</p> * @public */ BisectBatchOnFunctionError?: boolean; /** * <p>(Kinesis and DynamoDB Streams only) Discard records after the specified number of retries. The default value is infinite (-1). When set to infinite (-1), failed records are retried until the record expires.</p> * @public */ MaximumRetryAttempts?: number; /** * <p>(Kinesis and DynamoDB Streams only) The duration in seconds of a processing window for DynamoDB and Kinesis Streams event sources. A value of 0 seconds indicates no tumbling window.</p> * @public */ TumblingWindowInSeconds?: number; /** * <p>The name of the Kafka topic.</p> * @public */ Topics?: string[]; /** * <p> (MQ) The name of the Amazon MQ broker destination queue to consume. </p> * @public */ Queues?: string[]; /** * <p>An array of authentication protocols or VPC components required to secure your event source.</p> * @public */ SourceAccessConfigurations?: SourceAccessConfiguration[]; /** * <p>The self-managed Apache Kafka cluster to receive records from.</p> * @public */ SelfManagedEventSource?: SelfManagedEventSource; /** * <p>(Kinesis, DynamoDB Streams, and Amazon SQS) A list of current response type enums applied to the event source mapping.</p> * @public */ FunctionResponseTypes?: FunctionResponseType[]; /** * <p>Specific configuration settings for an Amazon Managed Streaming for Apache Kafka (Amazon MSK) event source.</p> * @public */ AmazonManagedKafkaEventSourceConfig?: AmazonManagedKafkaEventSourceConfig; /** * <p>Specific configuration settings for a self-managed Apache Kafka event source.</p> * @public */ SelfManagedKafkaEventSourceConfig?: SelfManagedKafkaEventSourceConfig; /** * <p>(Amazon SQS only) The scaling configuration for the event source. For more information, see <a href="https://docs.aws.amazon.com/lambda/latest/dg/with-sqs.html#events-sqs-max-concurrency">Configuring maximum concurrency for Amazon SQS event sources</a>.</p> * @public */ ScalingConfig?: ScalingConfig; /** * <p>Specific configuration settings for a DocumentDB event source.</p> * @public */ DocumentDBEventSourceConfig?: DocumentDBEventSourceConfig; /** * <p> * The ARN of the Key Management Service (KMS) customer managed key that Lambda * uses to encrypt your function's <a href="https://docs.aws.amazon.com/lambda/latest/dg/invocation-eventfiltering.html#filtering-basics">filter criteria</a>. * By default, Lambda does not encrypt your filter criteria object. Specify this * property to encrypt data using your own customer managed key. * </p> * @public */ KMSKeyArn?: string; } /** * <p>An object that contains details about an error related to filter criteria encryption.</p> * @public */ export interface FilterCriteriaError { /** * <p>The KMS exception that resulted from filter criteria encryption or decryption.</p> * @public */ ErrorCode?: string; /** * <p>The error message.</p> * @public */ Message?: string; } /** * <p>A mapping between an Amazon Web Services resource and a Lambda function. For details, see <a>CreateEventSourceMapping</a>.</p> * @public */ export interface EventSourceMappingConfiguration { /** * <p>The identifier of the event source mapping.</p> * @public */ UUID?: string; /** * <p>The position in a stream from which to start reading. Required for Amazon Kinesis and * Amazon DynamoDB Stream event sources. <code>AT_TIMESTAMP</code> is supported only for * Amazon Kinesis streams, Amazon DocumentDB, Amazon MSK, and self-managed Apache Kafka.</p> * @public */ StartingPosition?: EventSourcePosition; /** * <p>With <code>StartingPosition</code> set to <code>AT_TIMESTAMP</code>, the time from which to start * reading. <code>StartingPositionTimestamp</code> cannot be in the future.</p> * @public */ StartingPositionTimestamp?: Date; /** * <p>The maximum number of records in each batch that Lambda pulls from your stream or queue and sends to your function. Lambda passes all of the records in the batch to the function in a single call, up to the payload limit for synchronous invocation (6 MB).</p> * <p>Default value: Varies by service. For Amazon SQS, the default is 10. For all other services, the default is 100.</p> * <p>Related setting: When you set <code>BatchSize</code> to a value greater than 10, you must set <code>MaximumBatchingWindowInSeconds</code> to at least 1.</p> * @public */ BatchSize?: number; /** * <p>The maximum amount of time, in seconds, that Lambda spends gathering records before invoking the function. * You can configure <code>MaximumBatchingWindowInSeconds</code> to any value from 0 seconds to 300 seconds in increments of seconds.</p> * <p>For streams and Amazon SQS event sources, the default batching window is 0 seconds. For Amazon MSK, Self-managed Apache Kafka, Amazon MQ, and DocumentDB event sources, the default * batching window is 500 ms. Note that because you can only change <code>MaximumBatchingWindowInSeconds</code> in increments of seconds, you cannot revert back to the 500 ms default batching window after you have changed it. * To restore the default batching window, you must create a new event source mapping.</p> * <p>Related setting: For streams and Amazon SQS event sources, when you set <code>BatchSize</code> to a value greater than 10, you must set <code>MaximumBatchingWindowInSeconds</code> to at least 1.</p> * @public */ MaximumBatchingWindowInSeconds?: number; /** * <p>(Kinesis and DynamoDB Streams only) The number of batches to process concurrently from each shard. The default value is 1.</p> * @public */ ParallelizationFactor?: number; /** * <p>The Amazon Resource Name (ARN) of the event source.</p> * @public */ EventSourceArn?: string; /** * <p>An object that defines the filter criteria that * determine whether Lambda should process an event. For more information, see <a href="https://docs.aws.amazon.com/lambda/latest/dg/invocation-eventfiltering.html">Lambda event filtering</a>.</p> * <p>If filter criteria is encrypted, this field shows up as <code>null</code> in the response * of ListEventSourceMapping API calls. You can view this field in plaintext in the response of * GetEventSourceMapping and DeleteEventSourceMapping calls if you have * <code>kms:Decrypt</code> permissions for the correct KMS key.</p> * @public */ FilterCriteria?: FilterCriteria; /** * <p>The ARN of the Lambda function.</p> * @public */ FunctionArn?: string; /** * <p>The date that the event source mapping was last updated or that its state changed.</p> * @public */ LastModified?: Date; /** * <p>The result of the last Lambda invocation of your function.</p> * @public */ LastProcessingResult?: string; /** * <p>The state of the event source mapping. It can be one of the following: <code>Creating</code>, * <code>Enabling</code>, <code>Enabled</code>, <code>Disabling</code>, <code>Disabled</code>, * <code>Updating</code>, or <code>Deleting</code>.</p> * @public */ State?: string; /** * <p>Indicates whether a user or Lambda made the last change to the event source mapping.</p> * @public */ StateTransitionReason?: string; /** * <p>(Kinesis, DynamoDB Streams, Amazon MSK, and self-managed Apache Kafka event sources only) A configuration object that specifies the destination of an event after Lambda processes it.</p> * @public */ DestinationConfig?: DestinationConfig; /** * <p>The name of the Kafka topic.</p> * @public */ Topics?: string[]; /** * <p> (Amazon MQ) The name of the Amazon MQ broker destination queue to consume.</p> * @public */ Queues?: string[]; /** * <p>An array of the authentication protocol, VPC components, or virtual host to secure and define your event source.</p> * @public */ SourceAccessConfigurations?: SourceAccessConfiguration[]; /** * <p>The self-managed Apache Kafka cluster for your event source.</p> * @public */ SelfManagedEventSource?: SelfManagedEventSource; /** * <p>(Kinesis and DynamoDB Streams only) Discard records older than the specified age. The default value is -1, * which sets the maximum age to infinite. When the value is set to infinite, Lambda never discards old records.</p> * <note> * <p>The minimum valid value for maximum record age is 60s. Although values less than 60 and greater than -1 fall within the parameter's absolute range, they are not allowed</p> * </note> * @public */ MaximumRecordAgeInSeconds?: number; /** * <p>(Kinesis and DynamoDB Streams only) If the function returns an error, split the batch in two and retry. The default value is false.</p> * @public */ BisectBatchOnFunctionError?: boolean; /** * <p>(Kinesis and DynamoDB Streams only) Discard records after the specified number of retries. The default value is -1, * which sets the maximum number of retries to infinite. When MaximumRetryAttempts is infinite, Lambda retries failed records until the record expires in the event source.</p> * @public */ MaximumRetryAttempts?: number; /** * <p>(Kinesis and DynamoDB Streams only) The duration in seconds of a processing window for DynamoDB and Kinesis Streams event sources. A value of 0 seconds indicates no tumbling window.</p> * @public */ TumblingWindowInSeconds?: number; /** * <p>(Kinesis, DynamoDB Streams, and Amazon SQS) A list of current response type enums applied to the event source mapping.</p> * @public */ FunctionResponseTypes?: FunctionResponseType[]; /** * <p>Specific configuration settings for an Amazon Managed Streaming for Apache Kafka (Amazon MSK) event source.</p> * @public */ AmazonManagedKafkaEventSourceConfig?: AmazonManagedKafkaEventSourceConfig; /** * <p>Specific configuration settings for a self-managed Apache Kafka event source.</p> * @public */ SelfManagedKafkaEventSourceConfig?: SelfManagedKafkaEventSourceConfig; /** * <p>(Amazon SQS only) The scaling configuration for the event source. For more information, see <a href="https://docs.aws.amazon.com/lambda/latest/dg/with-sqs.html#events-sqs-max-concurrency">Configuring maximum concurrency for Amazon SQS event sources</a>.</p> * @public */ ScalingConfig?: ScalingConfig; /** * <p>Specific configuration settings for a DocumentDB event source.</p> * @public */ DocumentDBEventSourceConfig?: DocumentDBEventSourceConfig; /** * <p> * The ARN of the Key Management Service (KMS) customer managed key that Lambda * uses to encrypt your function's <a href="https://docs.aws.amazon.com/lambda/latest/dg/invocation-eventfiltering.html#filtering-basics">filter criteria</a>.</p> * @public */ KMSKeyArn?: string; /** * <p>An object that contains details about an error related to filter criteria encryption.</p> * @public */ FilterCriteriaError?: FilterCriteriaError; } /** * <p>The specified code signing configuration does not exist.</p> * @public */ export declare class CodeSigningConfigNotFoundException extends __BaseException { readonly name: "CodeSigningConfigNotFoundException"; readonly $fault: "client"; Type?: string; Message?: string; /** * @internal */ constructor(opts: __ExceptionOptionType<CodeSigningConfigNotFoundException, __BaseException>); } /** * <p>Your Amazon Web Services account has exceeded its maximum total code size. For more information, see <a href="https://docs.aws.amazon.com/lambda/latest/dg/gettingstarted-limits.html">Lambda quotas</a>.</p> * @public */ export declare class CodeStorageExceededException extends __BaseException { readonly name: "CodeStorageExceededException";