Skip to content

CloudFront  >  Operations  >  create_public_key

create_public_key

Operation

create_public_key async

create_public_key(input: CreatePublicKeyInput, plugins: list[Plugin] | None = None) -> CreatePublicKeyOutput

Uploads a public key to CloudFront that you can use with signed URLs and signed cookies, or with field-level encryption.

Parameters:

Name Type Description Default
input CreatePublicKeyInput

An instance of CreatePublicKeyInput.

required
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None

Returns:

Type Description
CreatePublicKeyOutput

An instance of CreatePublicKeyOutput.

Input

CreatePublicKeyInput dataclass

Bases: _SerdeShape

Dataclass for CreatePublicKeyInput structure.

Attributes

public_key_config class-attribute instance-attribute
public_key_config: PublicKeyConfig | None = ...

A CloudFront public key configuration.

Output

CreatePublicKeyOutput dataclass

Bases: _SerdeShape

Dataclass for CreatePublicKeyOutput structure.

Attributes

e_tag class-attribute instance-attribute
e_tag: str | None = ...

The identifier for this version of the public key.

location class-attribute instance-attribute
location: str | None = ...

The URL of the public key.

public_key class-attribute instance-attribute
public_key: PublicKey | None = ...

The public key.

response_metadata class-attribute instance-attribute
response_metadata: ResponseMetadata = ...

Metadata about the response that produced this output. Use this to recover the request identifiers a service's support team needs in order to investigate a call. Members of the metadata are individually optional.