# ConfigurationSource

Defines the integrated configuration sources.

- Source: [`aws-appconfig/lib/configuration.ts`](https://github.com/aws/aws-cdk/blob/v2.275.0/packages/aws-cdk-lib/aws-appconfig/lib/configuration.ts#L974)
- Type last changed: v2.234.0 · 8 Jan 2026

## Example

```ts
declare const application: appconfig.Application;
declare const bucket: s3.Bucket;

new appconfig.SourcedConfiguration(this, 'MySourcedConfiguration', {
  application,
  location: appconfig.ConfigurationSource.fromBucket(bucket, 'path/to/file.json'),
  type: appconfig.ConfigurationType.FEATURE_FLAGS,
  name: 'MyConfig',
  description: 'This is my sourced configuration from CDK.',
});
```

## Initializer

```ts
new ConfigurationSource()
```

## Properties

- `key`: [IKey](/cdk/api/v2/docs/aws-cdk-lib.aws_kms.IKey.html) — The KMS Key that encrypts the configuration.

- `locationUri`: string — The URI of the configuration source.

- `type`: [ConfigurationSourceType](/cdk/api/v2/docs/aws-cdk-lib.aws_appconfig.ConfigurationSourceType.html) — The type of the configuration source.

## Methods

- `fromBucket(bucket: IBucket, objectKey: string, key?: IKey): ConfigurationSource // chainable` (static) — Defines configuration content from an Amazon S3 bucket.

  **Parameters**

  - `bucket` — The S3 bucket where the configuration is stored.
  - `objectKey` — The path to the configuration.
  - `key` — The KMS Key that the bucket is encrypted with.

- `fromCfnDocument(document: CfnDocument): ConfigurationSource // chainable` (static) — Defines configuration content from a Systems Manager (SSM) document.

  **Parameters**

  - `document` — The SSM document where the configuration is stored.

- `fromParameter(parameter: IParameter, key?: IKey): ConfigurationSource // chainable` (static) — Defines configuration content from a Systems Manager (SSM) Parameter Store parameter.

  **Parameters**

  - `parameter` — The parameter where the configuration is stored.
  - `key` — The KMS Key that the secure string is encrypted with.

- `fromPipeline(pipeline: IPipelineRef): ConfigurationSource // chainable` (static) — Defines configuration content from AWS CodePipeline.

  **Parameters**

  - `pipeline` — The pipeline where the configuration is stored.

- `fromSecret(secret: ISecret): ConfigurationSource // chainable` (static) — Defines configuration content from an AWS Secrets Manager secret.

  **Parameters**

  - `secret` — The secret where the configuration is stored.
