# CapacityProviderAttributes

Attributes for importing an existing Lambda capacity provider.

- Source: [`aws-lambda/lib/capacity-provider.ts`](https://github.com/aws/aws-cdk/blob/v2.277.0/packages/aws-cdk-lib/aws-lambda/lib/capacity-provider.ts#L326)
- Type last changed: v2.231.0 · 1 Dec 2025

## Example

TypeScript:

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_lambda as lambda } from 'aws-cdk-lib';
const capacityProviderAttributes: lambda.CapacityProviderAttributes = {
  capacityProviderArn: 'capacityProviderArn',
};
```

Python:

```python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_lambda as lambda_

capacity_provider_attributes = lambda.CapacityProviderAttributes(
    capacity_provider_arn="capacityProviderArn"
)
```

Java:

```java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.lambda.*;

CapacityProviderAttributes capacityProviderAttributes = CapacityProviderAttributes.builder()
        .capacityProviderArn("capacityProviderArn")
        .build();
```

C# / .NET:

```csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Lambda;

var capacityProviderAttributes = new CapacityProviderAttributes {
    CapacityProviderArn = "capacityProviderArn"
};
```

Golang:

```go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

capacityProviderAttributes := &CapacityProviderAttributes{
	CapacityProviderArn: jsii.String("capacityProviderArn"),
}
```

## Properties

- `capacityProviderArn`: string (required) — The Amazon Resource Name (ARN) of the capacity provider.

  Format: arn:<partition>:lambda:<region>:<account-id>:capacity-provider:<capacity-provider-name>
