aws-cdk-lib.aws_ec2.MultipartBodyOptions

interface MultipartBodyOptions

LanguageType name
.NETAmazon.CDK.AWS.EC2.MultipartBodyOptions
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awsec2#MultipartBodyOptions
Javasoftware.amazon.awscdk.services.ec2.MultipartBodyOptions
Pythonaws_cdk.aws_ec2.MultipartBodyOptions
TypeScript (source)aws-cdk-lib » aws_ec2 » MultipartBodyOptions

Options when creating MultipartBody.

Example

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_ec2 as ec2 } from 'aws-cdk-lib';
const multipartBodyOptions: ec2.MultipartBodyOptions = {
  contentType: 'contentType',

  // the properties below are optional
  body: 'body',
  transferEncoding: 'transferEncoding',
};

Properties

NameTypeDescription
contentTypestringContent-Type header of this part.
body?stringThe body of message.
transferEncoding?stringContent-Transfer-Encoding header specifying part encoding.

contentType

Type: string

Content-Type header of this part.

Some examples of content types:

  • text/x-shellscript; charset="utf-8" (shell script)
  • text/cloud-boothook; charset="utf-8" (shell script executed during boot phase)

For Linux shell scripts use text/x-shellscript.


body?

Type: string (optional, default: undefined - body will not be added to part)

The body of message.


transferEncoding?

Type: string (optional, default: undefined - body is not encoded)

Content-Transfer-Encoding header specifying part encoding.