aws_sdk_codeartifact/client/publish_package_version.rs
1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3 /// Constructs a fluent builder for the [`PublishPackageVersion`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder) operation.
4 ///
5 /// - The fluent builder is configurable:
6 /// - [`domain(impl Into<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::domain) / [`set_domain(Option<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::set_domain):<br>required: **true**<br><p>The name of the domain that contains the repository that contains the package version to publish.</p><br>
7 /// - [`domain_owner(impl Into<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::domain_owner) / [`set_domain_owner(Option<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::set_domain_owner):<br>required: **false**<br><p>The 12-digit account number of the AWS account that owns the domain. It does not include dashes or spaces.</p><br>
8 /// - [`repository(impl Into<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::repository) / [`set_repository(Option<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::set_repository):<br>required: **true**<br><p>The name of the repository that the package version will be published to.</p><br>
9 /// - [`format(PackageFormat)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::format) / [`set_format(Option<PackageFormat>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::set_format):<br>required: **true**<br><p>A format that specifies the type of the package version with the requested asset file.</p> <p>The only supported value is <code>generic</code>.</p><br>
10 /// - [`namespace(impl Into<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::namespace) / [`set_namespace(Option<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::set_namespace):<br>required: **false**<br><p>The namespace of the package version to publish.</p><br>
11 /// - [`package(impl Into<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::package) / [`set_package(Option<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::set_package):<br>required: **true**<br><p>The name of the package version to publish.</p><br>
12 /// - [`package_version(impl Into<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::package_version) / [`set_package_version(Option<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::set_package_version):<br>required: **true**<br><p>The package version to publish (for example, <code>3.5.2</code>).</p><br>
13 /// - [`asset_content(ByteStream)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::asset_content) / [`set_asset_content(ByteStream)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::set_asset_content):<br>required: **true**<br><p>The content of the asset to publish.</p><br>
14 /// - [`asset_name(impl Into<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::asset_name) / [`set_asset_name(Option<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::set_asset_name):<br>required: **true**<br><p>The name of the asset to publish. Asset names can include Unicode letters and numbers, and the following special characters: <code>~ ! @ ^ & ( ) - ` _ + \[ \] { } ; , . `</code></p><br>
15 /// - [`asset_sha256(impl Into<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::asset_sha256) / [`set_asset_sha256(Option<String>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::set_asset_sha256):<br>required: **true**<br><p>The SHA256 hash of the <code>assetContent</code> to publish. This value must be calculated by the caller and provided with the request (see <a href="https://docs.aws.amazon.com/codeartifact/latest/ug/using-generic.html#publishing-generic-packages">Publishing a generic package</a> in the <i>CodeArtifact User Guide</i>).</p> <p>This value is used as an integrity check to verify that the <code>assetContent</code> has not changed after it was originally sent.</p><br>
16 /// - [`unfinished(bool)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::unfinished) / [`set_unfinished(Option<bool>)`](crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::set_unfinished):<br>required: **false**<br><p>Specifies whether the package version should remain in the <code>unfinished</code> state. If omitted, the package version status will be set to <code>Published</code> (see <a href="https://docs.aws.amazon.com/codeartifact/latest/ug/packages-overview.html#package-version-status">Package version status</a> in the <i>CodeArtifact User Guide</i>).</p> <p>Valid values: <code>unfinished</code></p><br>
17 /// - On success, responds with [`PublishPackageVersionOutput`](crate::operation::publish_package_version::PublishPackageVersionOutput) with field(s):
18 /// - [`format(Option<PackageFormat>)`](crate::operation::publish_package_version::PublishPackageVersionOutput::format): <p>The format of the package version.</p>
19 /// - [`namespace(Option<String>)`](crate::operation::publish_package_version::PublishPackageVersionOutput::namespace): <p>The namespace of the package version.</p>
20 /// - [`package(Option<String>)`](crate::operation::publish_package_version::PublishPackageVersionOutput::package): <p>The name of the package.</p>
21 /// - [`version(Option<String>)`](crate::operation::publish_package_version::PublishPackageVersionOutput::version): <p>The version of the package.</p>
22 /// - [`version_revision(Option<String>)`](crate::operation::publish_package_version::PublishPackageVersionOutput::version_revision): <p>The revision of the package version.</p>
23 /// - [`status(Option<PackageVersionStatus>)`](crate::operation::publish_package_version::PublishPackageVersionOutput::status): <p>A string that contains the status of the package version. For more information, see <a href="https://docs.aws.amazon.com/codeartifact/latest/ug/packages-overview.html#package-version-status.html#package-version-status">Package version status</a> in the <i>CodeArtifact User Guide</i>.</p>
24 /// - [`asset(Option<AssetSummary>)`](crate::operation::publish_package_version::PublishPackageVersionOutput::asset): <p>An <a href="https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_AssetSummary.html">AssetSummary</a> for the published asset.</p>
25 /// - On failure, responds with [`SdkError<PublishPackageVersionError>`](crate::operation::publish_package_version::PublishPackageVersionError)
26 pub fn publish_package_version(&self) -> crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder {
27 crate::operation::publish_package_version::builders::PublishPackageVersionFluentBuilder::new(self.handle.clone())
28 }
29}