AWS SDK Version 3 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

Container for the parameters to the PublishPackageVersion operation. Creates a new package version containing one or more assets (or files).

The unfinished flag can be used to keep the package version in the Unfinished state until all of its assets have been uploaded (see Package version status in the CodeArtifact user guide). To set the package version’s status to Published, omit the unfinished flag when uploading the final asset, or set the status using UpdatePackageVersionStatus. Once a package version’s status is set to Published, it cannot change back to Unfinished.

Only generic packages can be published using this API. For more information, see Using generic packages in the CodeArtifact User Guide.

Inheritance Hierarchy

System.Object
  Amazon.Runtime.AmazonWebServiceRequest
    Amazon.CodeArtifact.AmazonCodeArtifactRequest
      Amazon.CodeArtifact.Model.PublishPackageVersionRequest

Namespace: Amazon.CodeArtifact.Model
Assembly: AWSSDK.CodeArtifact.dll
Version: 3.x.y.z

Syntax

C#
public class PublishPackageVersionRequest : AmazonCodeArtifactRequest
         IAmazonWebServiceRequest

The PublishPackageVersionRequest type exposes the following members

Constructors

Properties

NameTypeDescription
Public Property AssetContent System.IO.Stream

Gets and sets the property AssetContent.

The content of the asset to publish.

Public Property AssetName System.String

Gets and sets the property AssetName.

The name of the asset to publish. Asset names can include Unicode letters and numbers, and the following special characters: ~ ! @ ^ & ( ) - ` _ + [ ] { } ; , . `

Public Property AssetSHA256 System.String

Gets and sets the property AssetSHA256.

The SHA256 hash of the assetContent to publish. This value must be calculated by the caller and provided with the request (see Publishing a generic package in the CodeArtifact User Guide).

This value is used as an integrity check to verify that the assetContent has not changed after it was originally sent.

Public Property Domain System.String

Gets and sets the property Domain.

The name of the domain that contains the repository that contains the package version to publish.

Public Property DomainOwner System.String

Gets and sets the property DomainOwner.

The 12-digit account number of the AWS account that owns the domain. It does not include dashes or spaces.

Public Property Format Amazon.CodeArtifact.PackageFormat

Gets and sets the property Format.

A format that specifies the type of the package version with the requested asset file.

The only supported value is generic.

Public Property Namespace System.String

Gets and sets the property Namespace.

The namespace of the package version to publish.

Public Property Package System.String

Gets and sets the property Package.

The name of the package version to publish.

Public Property PackageVersion System.String

Gets and sets the property PackageVersion.

The package version to publish (for example, 3.5.2).

Public Property Repository System.String

Gets and sets the property Repository.

The name of the repository that the package version will be published to.

Public Property Unfinished System.Boolean

Gets and sets the property Unfinished.

Specifies whether the package version should remain in the unfinished state. If omitted, the package version status will be set to Published (see Package version status in the CodeArtifact User Guide).

Valid values: unfinished

Version Information

.NET Core App:
Supported in: 3.1

.NET Standard:
Supported in: 2.0

.NET Framework:
Supported in: 4.5, 4.0, 3.5