# StringAttributeConstraintsProperty

The minimum and maximum length values of an attribute that is of the string type, for example `custom:department` .

- Source: Generated at build time
- Type last changed: v2.93.0 · 23 Aug 2023

## Example

TypeScript:

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_cognito as cognito } from 'aws-cdk-lib';
const stringAttributeConstraintsProperty: cognito.CfnUserPool.StringAttributeConstraintsProperty = {
  maxLength: 'maxLength',
  minLength: 'minLength',
};
```

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_cognito as cognito

string_attribute_constraints_property = cognito.CfnUserPool.StringAttributeConstraintsProperty(
    max_length="maxLength",
    min_length="minLength"
)
```

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.cognito.*;

StringAttributeConstraintsProperty stringAttributeConstraintsProperty = StringAttributeConstraintsProperty.builder()
        .maxLength("maxLength")
        .minLength("minLength")
        .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.Cognito;

var stringAttributeConstraintsProperty = new StringAttributeConstraintsProperty {
    MaxLength = "maxLength",
    MinLength = "minLength"
};
```

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"

stringAttributeConstraintsProperty := &StringAttributeConstraintsProperty{
	MaxLength: jsii.String("maxLength"),
	MinLength: jsii.String("minLength"),
}
```

## Properties

- `maxLength`: string — The maximum length of a string attribute value.

  Must be a number less than or equal to `2^1023` , represented as a string with a length of 131072 characters or fewer.

- `minLength`: string — The minimum length of a string attribute value.
