# VpcOriginConfigProperty

An Amazon CloudFront VPC origin configuration.

- Source: Generated at build time
- Type last changed: v2.223.0 · 10 Nov 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_cloudfront as cloudfront } from 'aws-cdk-lib';
const vpcOriginConfigProperty: cloudfront.CfnDistribution.VpcOriginConfigProperty = {
  vpcOriginId: 'vpcOriginId',

  // the properties below are optional
  originKeepaliveTimeout: 123,
  originReadTimeout: 123,
  ownerAccountId: 'ownerAccountId',
};
```

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_cloudfront as cloudfront

vpc_origin_config_property = cloudfront.CfnDistribution.VpcOriginConfigProperty(
    vpc_origin_id="vpcOriginId",

    # the properties below are optional
    origin_keepalive_timeout=123,
    origin_read_timeout=123,
    owner_account_id="ownerAccountId"
)
```

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

VpcOriginConfigProperty vpcOriginConfigProperty = VpcOriginConfigProperty.builder()
        .vpcOriginId("vpcOriginId")

        // the properties below are optional
        .originKeepaliveTimeout(123)
        .originReadTimeout(123)
        .ownerAccountId("ownerAccountId")
        .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.CloudFront;

var vpcOriginConfigProperty = new VpcOriginConfigProperty {
    VpcOriginId = "vpcOriginId",

    // the properties below are optional
    OriginKeepaliveTimeout = 123,
    OriginReadTimeout = 123,
    OwnerAccountId = "ownerAccountId"
};
```

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"

vpcOriginConfigProperty := &VpcOriginConfigProperty{
	VpcOriginId: jsii.String("vpcOriginId"),

	// the properties below are optional
	OriginKeepaliveTimeout: jsii.Number(123),
	OriginReadTimeout: jsii.Number(123),
	OwnerAccountId: jsii.String("ownerAccountId"),
}
```

## Properties

- `originKeepaliveTimeout`: number = 5 — Specifies how long, in seconds, CloudFront persists its connection to the origin.

  The minimum timeout is 1 second, the maximum is 120 seconds, and the default (if you don't specify otherwise) is 5 seconds.

  For more information, see [Keep-alive timeout (custom origins only)](https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/DownloadDistValuesOrigin.html#DownloadDistValuesOriginKeepaliveTimeout) in the *Amazon CloudFront Developer Guide* .

- `originReadTimeout`: number = 30 — Specifies how long, in seconds, CloudFront waits for a response from the origin.

  This is also known as the *origin response timeout* . The minimum timeout is 1 second, the maximum is 120 seconds, and the default (if you don't specify otherwise) is 30 seconds.

  For more information, see [Response timeout](https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/DownloadDistValuesOrigin.html#DownloadDistValuesOriginResponseTimeout) in the *Amazon CloudFront Developer Guide* .

- `ownerAccountId`: string — The account ID of the AWS account that owns the VPC origin.

- `vpcOriginId`: string (required) — The VPC origin ID.
