Parameter Store
When working with AWSBaseSettings, you can work with multiple parameters living in the same account and region, or with multiple accounts / regions.
The only restriction if for Secrets Manager. You can only use one secret / client / account / region at a time.
Simplest way
The only required setting is your secret's name. All other configurations you can leave to boto3 to deal.
In this case, pydantic-settings-aws will leave to boto3 to try to identify how he can connect to AWS.
Structured exceptions
pydantic-settings-aws wraps errors into its own exception hierarchy so you can catch them precisely:
SecretNotFoundError— the secret does not exist in Secrets ManagerSecretContentError— the secret exists but its content is empty or cannot be decodedSecretDecodeError— the secret content is not valid JSONParameterNotFoundError— the parameter does not exist in Parameter StoreAWSClientError— a boto3 session or client could not be createdAWSSettingsConfigError— the settings configuration is invalid or missing required fields
All of these inherit from PydanticSettingsAWSError, so you can catch them at any level.
Unrecognised boto3 / botocore errors are re-raised as-is.